JSFiddle - React, Tailwind, and code Playground
by D S
HTML
<div class="effect">
<div class="light"></div>
<div class="point"></div>
<div class="small-point"></div>
</div>
CSS
body{background:black}
.effect{
width:50px;
height:50px;
position:absolute;
}
.point{
width:20px;
height:20px;
background-color:white;
position:absolute;
left:50%;
top:50%;
border-radius:50%;
margin:-10px 0 0 -10px;
}
.small-point{
width:14px;
height:14px;
background-color:blue;
position:absolute;
left:50%;
top:50%;
border-radius:50%;
margin:-7px 0 0 -7px;
-webkit-animation:width 1s ease-in-out infinite forwards;
}
@-webkit-keyframes width {
0% {width:14px; height:14px; margin-left:-7px; margin-top:-7px;}
50% {width:10px; height:10px; margin-left:-5px; margin-top:-05px;}
100% {width:14px; height:14px; margin-left:-7px; margin-top:-7px;}
}
.light{
width:50px;
height:50px;
background-color:blue;
left:300;
top:300;
border-radius:50%;
-webkit-animation:spin 2s linear infinite forwards;
}
@-webkit-keyframes spin {
0% {width:0px; height:0px; margin-left:25px; margin-top:25px; opacity:1;}
100% {width:50px; height:50px; margin-left:0px; margin-top:0px; opacity:0;}
}