ebike-plus-ui/src/style/card-animation.scss
2024-06-16 22:57:26 +08:00

23 lines
590 B
SCSS
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

@keyframes fade-up {
0% {
transform: translateY(60px);
opacity: 0;
}
100% {
transform: translateY(0);
opacity: 1;
}
}
// 卡片过渡动画
// 根据遍历的卡片数量应用动画卡片数量支持20个
@for $i from 0 through 20 {
.animated-fade-up-#{$i} {
opacity: 0; // 初始透明度
animation-name: fade-up; // 应用动画
animation-duration: 0.5s; // 动画持续时间
animation-fill-mode: forwards; // 保持结束后的动画状态
animation-delay: calc($i/10) + s; // 设置延迟-每次延迟0.1s
}
}