September 24, 2016
CSS Circle Loading Spinner

Hi friends in this tutorial, I show you how to create circle loading spinner using CSS. The CSS loading spinner is seemingly the most popular loading spinner you will see, it is made up of 12 circles which spin together in a circle, all of the circles will have different opacity. The spinning effect will come from changing the opacity of all of the loading circle, doing it look like the whole thing is spinning.
index.html
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 |
<!doctype html> <html> <head> <meta charset="UTF-8"> <title>Loading_model_7</title> <style> body{ background-color:#c71254; } .sa-round{ margin: 300px auto; width: 40px; height: 40px; position:relative; } .sa-round .sa-child{ width:100%; height:100%; position: absolute; left: 0; top: 0; } .sa-round .sa-child:before{ content: ''; display:block; margin: 0 auto; width: 15%; height:15%; background-color:#FFF; border-radius: 100%; -webkit-animation: sa-roundBounceDelay 1.3s infinite ease-in-out both; animation: sa-roundBounceDelay 1.3s infinite ease-in-out both; } .sa-round .sa-round_2{ -webkit-transform: rotate(30deg); -ms-transform:rotate(30deg); transform: rotate(30deg); } .sa-round .sa-round_3{ -webkit-transform: rotate(60deg); -ms-transform:rotate(60deg); transform: rotate(60deg); } .sa-round .sa-round_4{ -webkit-transform: rotate(90deg); -ms-transform:rotate(90deg); transform: rotate(90deg); } .sa-round .sa-round_5{ -webkit-transform: rotate(120deg); -ms-transform:rotate(120deg); transform: rotate(120deg); } .sa-round .sa-round_6{ -webkit-transform: rotate(150deg); -ms-transform:rotate(150deg); transform: rotate(150deg); } .sa-round .sa-round_7{ -webkit-transform: rotate(180deg); -ms-transform:rotate(180deg); transform: rotate(180deg); } .sa-round .sa-round_8{ -webkit-transform: rotate(210deg); -ms-transform:rotate(210deg); transform: rotate(210deg); } .sa-round .sa-round_9{ -webkit-transform: rotate(240deg); -ms-transform:rotate(240deg); transform: rotate(240deg); } .sa-round .sa-round_10{ -webkit-transform: rotate(270deg); -ms-transform:rotate(270deg); transform: rotate(270deg); } .sa-round .sa-round_11{ -webkit-transform: rotate(300deg); -ms-transform:rotate(300deg); transform: rotate(300deg); } .sa-round .sa-round_12{ -webkit-transform: rotate(330deg); -ms-transform:rotate(330deg); transform: rotate(330deg); } .sa-round .sa-round_2:before{ -webkit-animation-delay: -1.1s; animation-delay: -1.1s; } .sa-round .sa-round_3:before{ -webkit-animation-delay: -1.0s; animation-delay: -1.0s; } .sa-round .sa-round_4:before{ -webkit-animation-delay: -0.9s; animation-delay: -0.9s; } .sa-round .sa-round_5:before{ -webkit-animation-delay: -0.8s; animation-delay: -0.8s; } .sa-round .sa-round_6:before{ -webkit-animation-delay: -0.7s; animation-delay: -0.7s; } .sa-round .sa-round_7:before{ -webkit-animation-delay: -0.6s; animation-delay: -0.6s; } .sa-round .sa-round_8:before{ -webkit-animation-delay: -0.5s; animation-delay: -0.5s; } .sa-round .sa-round_9:before{ -webkit-animation-delay: -0.4s; animation-delay: -0.4s; } .sa-round .sa-round_10:before{ -webkit-animation-delay: -0.3s; animation-delay: -0.3s; } .sa-round .sa-round_11:before{ -webkit-animation-delay: -0.2s; animation-delay: -0.2s; } .sa-round .sa-round_12:before{ -webkit-animation-delay: -0.1s; animation-delay: -0.1s; } @keyframes sa-roundBounceDelay { 0%, 80%, 100%{ -webkit-transform: scale(0); transform:scale(0); } 40%{ -webkit-transform:scale(1); transform: scale(1); } } @-webkit-keyframes sa-roundBounceDelay{ 0%, 80%, 100%{ -webkit-transform:scale(0); transform: scale(0); } 40%{ -webkit-transform: scale(1); transform: scale(1); } } </style> </head> <body> <div class="sa-round"> <div class="sa-round_1 sa-child"></div> <div class="sa-round_2 sa-child"></div> <div class="sa-round_3 sa-child"></div> <div class="sa-round_4 sa-child"></div> <div class="sa-round_5 sa-child"></div> <div class="sa-round_6 sa-child"></div> <div class="sa-round_7 sa-child"></div> <div class="sa-round_8 sa-child"></div> <div class="sa-round_9 sa-child"></div> <div class="sa-round_10 sa-child"></div> <div class="sa-round_11 sa-child"></div> <div class="sa-round_12 sa-child"></div> </div> </body> </html> |
Download
Mraj
Creative Designer & Developer specialist by the spirit and a loving blogger by thoughts. If you have any questions let me drop an email with the article name to the following email id: [email protected]