Skip to content

Instantly share code, notes, and snippets.

@esundahl
Created November 16, 2012 23:30
Show Gist options
  • Save esundahl/4091891 to your computer and use it in GitHub Desktop.
Save esundahl/4091891 to your computer and use it in GitHub Desktop.
A CodePen by Erik Sundahl. CSS3 Transform Loader
<div class='loading'>!</div>
body {
background: #000;
text-align: center;
margin: 100px
}
.loading {
color: #fff;
border: 5px solid #fff;
border-radius: 20px;
display: inline-block;
font-size: 6em;
height: auto;
text-align: center;
padding: 50px;
margin: 0 auto;
-webkit-animation-name: fade, rotate;
-webkit-animation-duration: 5s;
-webkit-animation-iteration-count: infinite;
-webkit-animation-timing-function: linear;
-webkit-animation-delay: 0;
}
@-webkit-keyframes rotate {
0% {
-webkit-transform: rotate(0deg);
}
100% {
-webkit-transform: rotate(360deg);
}
}
@-webkit-keyframes fade {
0% { opacity: 0; }
50% { opacity: 1; }
100% { opacity: 0; }
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment