Created
February 15, 2017 09:30
-
-
Save yugaego/93db9a85b9ae8ad6d9843a05deb31c76 to your computer and use it in GitHub Desktop.
CSS Animation Loading Indicator (aka Spinner) with Bouncing Dots (Middle Positioned Circles)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div style="display: none" data-selector="spinner" id="spinner"> | |
<div class="nowrap"> | |
<span class="spinner-text text-info">CUSTOM TEXT</span> | |
<div class="spinner"> | |
<div class="bounce1"></div> | |
<div class="bounce2"></div> | |
<div class="bounce3"></div> | |
</div> | |
</div> | |
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** SPINNER **/ | |
.spinner-text { | |
float: left; | |
margin: 3px 5px 3px 0; | |
} | |
.spinner { | |
margin: 3px 0; | |
} | |
.spinner > div { | |
width: 5px; | |
height: 5px; | |
background-color: #31708f; | |
border-radius: 100%; | |
display: inline-block; | |
-webkit-animation: sk-bouncedelay 1.4s infinite ease-in-out both; | |
animation: sk-bouncedelay 1.4s infinite ease-in-out both; | |
} | |
.spinner .bounce1 { | |
-webkit-animation-delay: -0.32s; | |
animation-delay: -0.32s; | |
} | |
.spinner .bounce2 { | |
-webkit-animation-delay: -0.16s; | |
animation-delay: -0.16s; | |
} | |
@-webkit-keyframes sk-bouncedelay { | |
0%, 80%, 100% { | |
-webkit-transform: scale(0) | |
} | |
40% { | |
-webkit-transform: scale(1.0) | |
} | |
} | |
@keyframes sk-bouncedelay { | |
0%, 80%, 100% { | |
-webkit-transform: scale(0); | |
transform: scale(0); | |
} | |
40% { | |
-webkit-transform: scale(1.0); | |
transform: scale(1.0); | |
} | |
} | |
/** END OF SPINNER **/ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment