css写动态圆点发光成效代码
发布时间:2022-04-20 08:50:50 所属栏目:语言 来源:互联网
导读:使用css我们能够实现很多酷炫有趣的动态效果,这篇文章就给大家分享用CSS3来实现动态发光的圆圈效果,明白css动态圆点的实现,我们还能够举一反三,实现星星发光效果等等。下面是动态发光的圆圈效果,感兴趣的朋友就继续往下看吧。 代码: !DOCTYPE HTML htm
使用css我们能够实现很多酷炫有趣的动态效果,这篇文章就给大家分享用CSS3来实现动态发光的圆圈效果,明白css动态圆点的实现,我们还能够举一反三,实现星星发光效果等等。下面是动态发光的圆圈效果,感兴趣的朋友就继续往下看吧。 代码: <!DOCTYPE HTML> <html> <head> <title>纯CSS3实现圆圈动态发光特效动画</title> <style> body { background-color: #000000; } @keyframes twinkling { 0% { opacity: 0.2; transform: scale(1); } 50% { opacity: 0.5; transform: scale(1.12); } 100% { opacity: 0.2; transform: scale(1); } } .circle-wrap { position: absolute; left: 100px; top: 100px; } .circle { position: relative; width: 24px; height: 24px; } .small-circle { border-radius: 50%; width: 12px; height: 12px; background: #FF0033; position: absolute; } .big-circle { position: absolute; top: -6px; left: -6px; width: 100%; height: 100%; border-radius: 50%; background: #FF0033; animation: twinkling 1s infinite ease-in-out; animation-fill-mode: both; .smallcircle2 { position: absolute; width: 12px; height: 12px; background-color: #ffffff; border-radius: 50%; top: 100px; left: 200px; (编辑:开发网_开封站长网) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |