پیشنمایش زنده
کد HTML
<div class="loading">
<svg height="48px" width="64px">
<polyline id="back" points="0.157 23.954, 14 23.954, 21.843 48, 43 0, 50 24, 64 24"></polyline>
<polyline id="front" points="0.157 23.954, 14 23.954, 21.843 48, 43 0, 50 24, 64 24"></polyline>
</svg>
</div>
کد CSS
.loading svg polyline {
fill: none;
stroke-width: 3;
stroke-linecap: round;
stroke-linejoin: round;
}
.loading svg polyline#back {
fill: none;
stroke: #e0464b33;
}
.loading svg polyline#front {
fill: none;
stroke: #d2494b;
stroke-dasharray: 48, 144;
stroke-dashoffset: 192;
animation: dash_682 1.4s linear infinite;
}
@keyframes dash_682 {
72.5% {
opacity: 0;
}
to {
stroke-dashoffset: 0;
}
}