JSFiddle - React, Tailwind, and code Playground
by Keith Jeter
HTML
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css">
<script src="https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100;0,300;0,400;0,500;0,700;0,900;1,100;1,300;1,400;1,500;1,700;1,900&display=swap"></script>
<div class="bc_full_wrap">
<div class="bc_ani_wrap">
<span class="center_number">5</span>
<div class="fa fa-circle-o-notch fa-spin fa-3x fa-fw"></div>
</div>
<div class="cent_txt">MILES</div>
</div>
CSS
body {
font-family: 'Roboto', sans-serif;
}
.bc_full_ring_wrap {
position: relative;
float: left;
display: block;
overflow: hidden;
width: 80px;
height: 100px;
}
.bc_ring_container {
position: relative;
display: block;
overflow: hidden;
width: 80px;
height: 80px;
}
.circle {
width: 40px;
height: 40px;
background-color: #064c7b;
border-radius: 50%;
position: relative;
margin: auto;
margin-top: 20px;
transform: translate(-50%, -50%);
}
.ringring {
border: 3px solid #428bca;
-webkit-border-radius: 30px;
height: 50px;
width: 50px;
position: absolute;
left: 12px;
top: 12px;
-webkit-animation: pulsate 1.25s ease-out;
-webkit-animation-iteration-count: infinite;
opacity: 0;
}
.nu_numb {
color: #fff;
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
font-size: 18px;
font-weight: bold;
}
.cent_txt {
color: #064c7b;
font-size: 16px;
font-weight: bold;
text-align: center;
margin-top: -10px;
}
@-webkit-keyframes pulsate {
0% { -webkit-transform: scale(0.1, 0.1); opacity: 0; }
50% { opacity: 1; }
100% { -webkit-transform: scale(1.2, 1.2); opacity: 0; }
}
/*-- pulse animation --*/
.bc_animated {
animation-duration: 2.5s;
animation-fill-mode: both;
animation-iteration-count: infinite;
}
@keyframes pulse {
0% { -webkit-transform: scale(0.1, 0.1); }
100% { -webkit-transform: scale(1.2, 1.2); }
}
.bc_pulse {
animation-name: pulse;
animation-duration: 2s;
}
/*-- pulse animation --*/