JSFiddle - React, Tailwind, and code Playground
HTML
<div class="spinner">
<div class="star1"></div>
<div class="star2"></div>
</div>
CSS
html, body{
background:#000000;
background:rgb(0, 0, 0);
}
.spinner{
height:40px;
width:40px;
margin:0 auto;
position:relative;
text-align:center;
-webkit-animation:rotate 2.0s infinite linear;
animation:rotate 2.0s infinite linear;
}
.star1, .star2{
height:60%;
width:60%;
position:absolute;
background:#ffffff;
background:rgb(255, 255, 255);
-moz-border-radius:100%;
-webkit-border-radius:100%;
border-radius:100%;
display:inline-block;
top:0;
-moz-animation:bounce 2.0s infinite ease-in-out;
-webkit-animation:bounce 2.0s infinite ease-in-out;
animation:bounce 2.0 infinite ease-in-out;
}
.star2{
bottom:0px;
top:auto;
-moz-animation-delay:-1.0s;
-webkit-animation-delay:-1.0s;
animation-delay:-1.0s;
}
@-moz-keyframes rotate{
100%{
-moz-transform:rotate(360deg);
}
}
@-webkit-keyframes rotate{
100%{
-webkit-transform:rotate(360deg);
}
}
@keyframes rotate{
100%{
transfrom:rotate(360deg);
}
}
@-moz-keyframes bounce{
0%, 100%{
-moz-transform:scale(0.0);
}
50%{
-moz-transform:scale(1.0);
}
}
@-webkit-keyframes bounce{
0%, 100%{
-webkit-transform:scale(0.0);
}
50%{
-webkit-transform:scale(1.0);
}
}
@keyframes bounce{
0%, 100%{
transform:scale(0.0);
}
50%{
transform:scale(1.0);
}
}