【发布时间】:2021-08-28 04:34:09
【问题描述】:
我之前已经看到过这个讨论,但它通常用于具有 1 个停止点和结束点的动画。由于我的示例中的箭头正在弹跳https://5pshomes.artrageousdemo.com/,我对它的工作原理有点困惑。 如何在动画的每次迭代之间添加几秒钟的延迟,同时保持动画本身 2 秒长?
.fl-icon-wrap{
-moz-animation: bounce 2s infinite;
-webkit-animation: bounce 2s infinite;
animation: bounce 2s infinite;
animation-delay: 2s;
}
@keyframes bounce {
0%, 20%, 50%, 80%, 100% {
transform: translateY(0);
}
40% {
transform: translateY(-30px);
}
60% {
transform: translateY(-15px);
}
}
谢谢,
【问题讨论】:
-
您需要在 15% 和 20% 之间添加一些静态帧,等等。
标签: html css css-animations