Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URL's added here will be added as <link>s in order, and before the CSS in the editor. If you link to another Pen, it will include the CSS from that Pen. If the preprocessor matches, it will attempt to combine them before processing.

+ add another resource

JavaScript

Babel is required to process package imports. If you need a different preprocessor remove all packages first.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource

Behavior

Save Automatically?

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.

HTML

              
                <!--SUCCESS SECTION-->
<section id="success-feedback">
  <div id="success-feedback-box">
    <div id="success-check-container">
     <div id="success-check">
       <div id="success-bar1"></div>
       <div id="success-bar2"></div>
      </div>
    </div>
    <div id="success-text">Success !</div>
    <div id="success-button">Done</div>
  </div>
</section>

<!--ERROR SECTION-->
<section id="error-feedback">
  <div id="error-feedback-box">
    <div id="error-check-container">
     <div id="error-check">
       <div id="error-bar1"></div>
       <div id="error-bar2"></div>
      </div>
    </div>
    <div id="error-text">Error</div>
    <div id="error-button">Done</div>
  </div>
</section>

<!--NO PERMISSION SECTION-->
<section id="noperm-feedback">
  <div id="noperm-feedback-box">
    <div id="noperm-check-container">
     <div id="noperm-check">
       <div id="noperm-bar1"></div>
      </div>
    </div>
    <div id="noperm-text">You don't have the permission !</div>
    <div id="noperm-button">Done</div>
  </div>
</section>


<!--OOPS SECTION-->
<section id="oops-feedback">
  <div id="oops-feedback-box">
    <div id="oops-check-container">
     <div id="oops-check">
       <div id="oops-bar1"></div>
       <div id="oops-point">.</div>
      </div>
    </div>
    <div id="oops-text">Oops :x</div>
    <div id="oops-button">Done</div>
  </div>
</section>



<!--TRIGGER SECTION-->
<div id="trigger-success" class="button">> Click for success <</div>
<div id="trigger-error" class="button">> Click for error <</div>
<div id="trigger-noperm" class="button">> Click for no permission <</div>
<div id="trigger-oops" class="button">> Click for Oops <</div>
  
  
  

<script src="https://code.jquery.com/jquery-3.4.1.min.js"></script>
              
            
!

CSS

              
                body{
  width:100vw;
  height:100vh;
  overflow:hidden;
}


/*SUCCESS*/
#success-feedback{
  width:400px;
  left:calc(50vw - 200px);
  top:-100vh;
  
  position:absolute;
  opacity:0;
  display:none;
}
#success-feedback-box{
  width:100%;
  height:100%;
  
  background-color:white;
  border-radius:5px;
  
  display:flex;
  flex-direction:column;
  justify-content:center;
  align-items:center;
}
#success-check-container{
  width:120px;
  height:120px;
  
  box-sizing:border-box;
  border-radius:50%;
  
  border-top:solid 2px green;
  border-right:solid 2px green;
  border-bottom:solid 2px green;
  border-left:solid 2px green;
  
  position:absolute;
  top:40px;
  
  animation-name:success-border;
  animation-duration:1300ms;
}
#success-bar1{
  height:2px;
  width:40px;
  background-color:green;
  
  transform: scaleX(-1) rotate(135deg);
  transform-origin: left top;
  
  position:absolute;
  top:63px;
  left:26px;
  
  animation-name:success-checkmark;
  animation-duration:500ms;
}
#success-bar2{
  height:2px;
  width:60px;
  background-color:green;
  
  transform:rotate(315deg);
  transform-origin: left bottom;
  
  position:absolute;
  top:90px;
  left:55px;
  animation-name:success-checkmark2;
  animation-duration:1300ms;
}

#success-text{
  color:black;
  font-family:roboto;
  font-size:35px;
  font-weight:bold;
  
  margin-top:170px;
  margin-bottom:10px;
}
#success-button{
  background-color:green;
  color:white;
  font-family:roboto;
  font-size:20px;
  
  padding: 10px 20px;
  margin:10px 0;
  
  border-radius:5px;
  border: solid #1fa608 3px;
}
#success-button:hover{
  cursor:pointer;
  background-color:#00a100;
}

/*END SUCCESS*/



/*KEYFRAME SUCCESS*/
@keyframes success-checkmark {
  0% {
    height: 0;
    width: 0;
    opacity: 1;
    top:30px;
  }
  20% {
    height: 1px;
    width: 10px;
    opacity: 1;
  }
  30% {
    height: 2px;
    width: 10px;
    opacity: 1;
  }
  100% {
    height: 2px;
    width: 40px;
    opacity: 1;
    top:63px;
  }
}
@keyframes success-checkmark2 {
  0% {
    opacity:0;
    width: 0px;
  }
  33% {
    opacity:0;
    width: 0px;
  }
  34% {
    opacity:1;
    width: 0px;
  }
  75% {
    width: 65px;
  }
  100% {
    width: 60px;
  }
}
@keyframes success-border {
  0% {
    border-top:solid 2px #00aa00;
    border-left:solid 2px green;
    border-bottom:solid 2px green;
    border-right:solid 2px green;
  }
  25% {
    border-top:solid 2px green;
    border-left:solid 2px #00aa00;
    border-bottom:solid 2px green;
    border-right:solid 2px green;
  }
  50% {
    border-top:solid 2px green;
    border-left:solid 2px green;
    border-bottom:solid 2px #00aa00;
    border-right:solid 2px green;
  }
  75% {
    border-top:solid 2px green;
    border-left:solid 2px green;
    border-bottom:solid 2px green;
    border-right:solid 2px #00aa00;
  }
  100% {
    border-top:solid 2px green;
    border-left:solid 2px green;
    border-bottom:solid 2px green;
    border-right:solid 2px green;
  }
}
/*END KEYFRAME SUCCESS*/




/*ERROR*/
#error-feedback{
  width:400px;
  left:calc(50vw - 200px);
  top:-100vh;
  
  position:absolute;
  opacity:0;
  display:none;
}
#error-feedback-box{
  width:100%;
  height:100%;
  
  background-color:white;
  border-radius:5px;
  
  display:flex;
  flex-direction:column;
  justify-content:center;
  align-items:center;
}
#error-check-container{
  width:120px;
  height:120px;
  
  box-sizing:border-box;
  border-radius:50%;
  
  border-top:solid 2px #cc0000;
  border-right:solid 2px #cc0000;
  border-bottom:solid 2px #cc0000;
  border-left:solid 2px #cc0000;
  
  position:absolute;
  top:40px;
  
  animation-name:error-border;
  animation-duration:1300ms;
}
#error-bar1{
  height:2px;
  width:60px;
  background-color:#cc0000;
  
  transform: scaleX(-1) rotate(135deg);
  transform-origin: left top;
  
  position:absolute;
  top:40px;
  left:37px;
  
  animation-name:error-checkmark;
  animation-duration:900ms;
}
#error-bar2{
  height:2px;
  width:60px;
  background-color:#cc0000;
  
  transform:rotate(315deg);
  transform-origin: left bottom;
  
  position:absolute;
  top:80px;
  left:37px;
  animation-name:error-checkmark2;
  animation-duration:900ms;
}

#error-text{
  color:black;
  font-family:roboto;
  font-size:35px;
  font-weight:bold;
  
  margin-top:170px;
  margin-bottom:10px;
}
#error-button{
  background-color:#cc0000;
  color:white;
  font-family:roboto;
  font-size:20px;
  
  padding: 10px 20px;
  margin:10px 0;
  
  border-radius:5px;
  border: solid red 3px;
}
#error-button:hover{
  cursor:pointer;
  background-color:red;
}

/*END ERROR*/



/*KEYFRAME ERROR*/
@keyframes error-checkmark {
  0% {
    width: 0px;
    top:10px;
  }
  60% {
    width: 65px;
  }
  100% {
    width: 60px;
    top:40px;
  }
}
@keyframes error-checkmark2 {
  0% {
    top:100px;
    width: 0px;
  }
  60% {
    width: 65px;
  }
  100% {
    top:80px;
    width: 60px;
  }
}
@keyframes error-border {
  0% {
    border-top:solid 2px red;
    border-left:solid 2px #cc0000;
    border-bottom:solid 2px #cc0000;
    border-right:solid 2px #cc0000;
  }
  25% {
    border-top:solid 2px #cc0000;
    border-left:solid 2px red;
    border-bottom:solid 2px #cc0000;
    border-right:solid 2px #cc0000;
  }
  50% {
    border-top:solid 2px #cc0000;
    border-left:solid 2px #cc0000;
    border-bottom:solid 2px red;
    border-right:solid 2px #cc0000;
  }
  75% {
    border-top:solid 2px #cc0000;
    border-left:solid 2px #cc0000;
    border-bottom:solid 2px #cc0000;
    border-right:solid 2px red;
  }
  100% {
    border-top:solid 2px #cc0000;
    border-left:solid 2px #cc0000;
    border-bottom:solid 2px #cc0000;
    border-right:solid 2px #cc0000;
  }
}
/*END KEYFRAME ERROR*/




/*NOPERM*/
#noperm-feedback{
  width:400px;
  left:calc(50vw - 200px);
  top:-100vh;
  
  position:absolute;
  opacity:0;
  display:none;
}
#noperm-feedback-box{
  width:100%;
  height:100%;
  
  background-color:white;
  border-radius:5px;
  
  display:flex;
  flex-direction:column;
  justify-content:center;
  align-items:center;
}
#noperm-check-container{
  width:120px;
  height:120px;
  
  box-sizing:border-box;
  border-radius:50%;
  
  border-top:solid 2px #cc0000;
  border-right:solid 2px #cc0000;
  border-bottom:solid 2px #cc0000;
  border-left:solid 2px #cc0000;
  
  position:absolute;
  top:40px;
  
  animation-name:noperm-border;
  animation-duration:1300ms;
}
#noperm-bar1{
  height:3px;
  width:60px;
  background-color:#cc0000;
  
  position:absolute;
  top:60px;
  left:30px;
  
  animation-name:noperm-checkmark;
  animation-duration:900ms;
}

#noperm-text{
  color:black;
  font-family:roboto;
  font-size:35px;
  font-weight:bold;
  text-align:center;
  
  margin-top:170px;
  margin-bottom:10px;
}
#noperm-button{
  background-color:#cc0000;
  color:white;
  font-family:roboto;
  font-size:20px;
  
  padding: 10px 20px;
  margin:10px 0;
  
  border-radius:5px;
  border: solid #e60000 3px;
}
#noperm-button:hover{
  cursor:pointer;
  background-color:#e60000;
}

/*END NOPERM*/



/*KEYFRAME NOPERM*/
@keyframes noperm-checkmark {
  0% {
    left:10px;
    width: 0px;
  }
  60% {
    width: 65px;
  }
  100% {
    left:30px;
    width: 60px;
  }
}
@keyframes noperm-border {
  0% {
    border-top:solid 2px red;
    border-left:solid 2px #cc0000;
    border-bottom:solid 2px #cc0000;
    border-right:solid 2px #cc0000;
  }
  25% {
    border-top:solid 2px #cc0000;
    border-left:solid 2px red;
    border-bottom:solid 2px #cc0000;
    border-right:solid 2px #cc0000;
  }
  50% {
    border-top:solid 2px #cc0000;
    border-left:solid 2px #cc0000;
    border-bottom:solid 2px red;
    border-right:solid 2px #cc0000;
  }
  75% {
    border-top:solid 2px #cc0000;
    border-left:solid 2px #cc0000;
    border-bottom:solid 2px #cc0000;
    border-right:solid 2px red;
  }
  100% {
    border-top:solid 2px #cc0000;
    border-left:solid 2px #cc0000;
    border-bottom:solid 2px #cc0000;
    border-right:solid 2px #cc0000;
  }
}
/*END KEYFRAME NO PERM*/




/*OOPS*/
#oops-feedback{
  width:400px;
  left:calc(50vw - 200px);
  top:-100vh;
  
  position:absolute;
  opacity:0;
  display:none;
}
#oops-feedback-box{
  width:100%;
  height:100%;
  
  background-color:white;
  border-radius:5px;
  
  display:flex;
  flex-direction:column;
  justify-content:center;
  align-items:center;
}
#oops-check-container{
  width:120px;
  height:120px;
  
  box-sizing:border-box;
  border-radius:50%;
  
  border-top:solid 2px #e67300;
  border-right:solid 2px #e67300;
  border-bottom:solid 2px #e67300;
  border-left:solid 2px #e67300;
  
  position:absolute;
  top:40px;
  
  animation-nameoops-border;
  animation-duration:1300ms;
}
#oops-bar1{
  height:3px;
  width:50px;
  background-color:#e67300;
  
  transform:rotate(90deg);
  
  position:absolute;
  top:50px;
  left:35px;
  
  animation-name:oops-checkmark;
  animation-duration:900ms;
}
#oops-point{
  color:#e67300;
  
  font-size:50px;
  
  position:absolute;
  top:50px;
  left:53px;
  
  animation-name:oops-point;
  animation-duration:900ms;
}

#oops-text{
  color:black;
  font-family:roboto;
  font-size:35px;
  font-weight:bold;
  text-align:center;
  
  margin-top:170px;
  margin-bottom:10px;
}
#oops-button{
  background-color:#e67300;
  color:white;
  font-family:roboto;
  font-size:20px;
  
  padding: 10px 20px;
  margin:10px 0;
  
  border-radius:5px;
  border: solid orange 3px;
}
#oops-button:hover{
  cursor:pointer;
  background-color:orange;
}

/*END OOPS*/



/*KEYFRAME OOPS*/
@keyframes oops-checkmark {
  0% {
    top:20px;
    width: 0px;
  }
  60% {
    width: 55px;
  }
  100% {
    top:50px;
    width: 50px;
  }
}
@keyframes oops-point {
  0% {
    font-size:0px;
    opacity:0
  }
  60% {
    opacity:1;
    font-size:50px;
  }
  100% {
  }
}
@keyframes oops-border {
  0% {
    border-top:solid 2px #ff8000;
    border-left:solid 2px #e67300;
    border-bottom:solid 2px #e67300;
    border-right:solid 2px #e67300;
  }
  25% {
    border-top:solid 2px #e67300;
    border-left:solid 2px #ff8000;
    border-bottom:solid 2px #e67300;
    border-right:solid 2px #e67300;
  }
  50% {
    border-top:solid 2px #e67300;
    border-left:solid 2px #e67300;
    border-bottom:solid 2px #ff8000;
    border-right:solid 2px #e67300;
  }
  75% {
    border-top:solid 2px #e67300;
    border-left:solid 2px #e67300;
    border-bottom:solid 2px #e67300;
    border-right:solid 2px #ff8000;
  }
  100% {
    border-top:solid 2px #e67300;
    border-left:solid 2px #e67300;
    border-bottom:solid 2px #e67300;
    border-right:solid 2px #e67300;
  }
}
/*END KEYFRAME OOPS*/



#trigger-success{
  background-color:#007994;
  color:white;
  padding:10px 20px;
  width:150px;
  font-family:roboto;
}
#trigger-success:hover{
  background-color:#058fad;
  cursor:pointer
}
#trigger-error{
  background-color:#cc0000;
  color:white;
  padding:10px 20px;
  width:150px;
  font-family:roboto;
}
#trigger-error:hover{
  background-color:#e60000;
  cursor:pointer
}

#trigger-noperm{
  background-color:#cc0000;
  color:white;
  padding:10px 20px;
  width:150px;
  font-family:roboto;
}
#trigger-noperm:hover{
  background-color:#e60000;
  cursor:pointer
}

#trigger-oops{
  background-color:#e67300;
  color:white;
  padding:10px 20px;
  width:150px;
  font-family:roboto;
}
#trigger-oops:hover{
  background-color:#ff8000;
  cursor:pointer
}
              
            
!

JS

              
                //SUCCESS BUTTON
$("#success-button").click(function(){
  $("#success-feedback").fadeOut(200,function(){
    $("#success-feedback").css({
      display:"none",
      top:"-100vh",
      opacity:"0"
    });
  });
});
//SUCCESS TRIGGER
$("#trigger-success").click(function(){
  $("#success-feedback").css("display","block");
  $("#success-feedback").animate({
    top:"10vh",
    opacity:"1"
  },200);
});


//ERROR BUTTON
$("#error-button").click(function(){
  $("#error-feedback").fadeOut(200,function(){
    $("#error-feedback").css({
      display:"none",
      top:"-100vh",
      opacity:"0"
    });
  });
});
//ERROR TRIGGER
$("#trigger-error").click(function(){
  $("#error-feedback").css("display","block");
  $("#error-feedback").animate({
    top:"10vh",
    opacity:"1"
  },200);
});

//NOPERM BUTTON
$("#noperm-button").click(function(){
  $("#noperm-feedback").fadeOut(200,function(){
    $("#noperm-feedback").css({
      display:"none",
      top:"-100vh",
      opacity:"0"
    });
  });
});
//NOPERM TRIGGER
$("#trigger-noperm").click(function(){
  $("#noperm-feedback").css("display","block");
  $("#noperm-feedback").animate({
    top:"10vh",
    opacity:"1"
  },200);
});

//OOPS BUTTON
$("#oops-button").click(function(){
  $("#oops-feedback").fadeOut(200,function(){
    $("#oops-feedback").css({
      display:"none",
      top:"-100vh",
      opacity:"0"
    });
  });
});
//OOPS TRIGGER
$("#trigger-oops").click(function(){
  $("#oops-feedback").css("display","block");
  $("#oops-feedback").animate({
    top:"10vh",
    opacity:"1"
  },200);
});

              
            
!
999px

Console