这个纯CSS实现的Loading特效是一个非常简单而实用的选择,它由三个圆圈横向排列,并不断闪烁。这种动画效果很适合用于页面加载过程中,为用户提供一个愉悦的等待体验。
在这个特效的设计中,使用了CSS的animation属性来实现圆圈的闪烁效果。这个特效的实现并没有用到任何JavaScript,这意味着它可以帮助提升网站的性能,同时也减少了代码的复杂性。
这个特效的视觉效果非常出色,它为用户提供了一个简单而美观的等待界面。如果您正在寻找一个简单而实用的加载动画,那么这个纯CSS实现的3个圆圈横向排列不断闪烁的Loading特效一定会是一个不错的选择。
希望这个特效能够为您的网站增添一些活力和趣味性!
<div class="loading">
<div></div>
<div></div>
<div></div>
</div>
<style>
.loading,
.loading > div {
position: relative;
box-sizing: border-box;
}
.loading {
display: block;
font-size: 0;
color: #000;
}
.loading.la-dark {
color: #333;
}
.loading > div {
display: inline-block;
float: none;
background-color: currentColor;
border: 0 solid currentColor;
}
.loading {
width: 54px;
height: 18px;
}
.loading > div:nth-child(1) {
animation-delay: -200ms;
}
.loading > div:nth-child(2) {
animation-delay: -100ms;
}
.loading > div:nth-child(3) {
animation-delay: 0ms;
}
.loading > div {
width: 10px;
height: 10px;
margin: 4px;
border-radius: 100%;
animation: ball-pulse 1s ease infinite;
}
.loading.la-sm {
width: 26px;
height: 8px;
}
.loading.la-sm > div {
width: 4px;
height: 4px;
margin: 2px;
}
.loading.la-2x {
width: 108px;
height: 36px;
}
.loading.la-2x > div {
width: 20px;
height: 20px;
margin: 8px;
}
.loading.la-3x {
width: 162px;
height: 54px;
}
.loading.la-3x > div {
width: 30px;
height: 30px;
margin: 12px;
}
@keyframes ball-pulse {
0%,
60%,
100% {
opacity: 1;
transform: scale(1);
}
30% {
opacity: 0.1;
transform: scale(0.01);
}
}
</style>