css - 使用css加载1秒后翻转图像
问题描述
我正在使用 CSS 和 HTML 在悬停时翻转图像,但如何在加载后翻转图像 1 秒?
解决方案
您可以将关键帧动画设置为延迟 1 秒。确保保留动画中的forwards
样式。
.flip {
animation: flip-animation .25s 1s forwards;
-webkit-animation: flip-animation .25s 1s forwards; /* for less modern browsers */
}
@keyframes flip-animation {
// code to flip the
from {}
to{}
}
推荐阅读
- sql - SQL:如何提高视图的 SQL 查询性能?
- java - AbstractProcessor 可以检测带注释的方法是否存在编译错误?
- c - 在 C 中计算大小写字母的问题
- spring-boot - 使用 Spring Boot 和 Heroku 时,H2 数据库在哪里?
- python - Pandas:如何查找范围之间的值的索引
- angular - 带一个输入的切换器的角形
- airflow - Apache Airflow - 在接下来的步骤中使用 python 结果
- java - 在 Android 中的绘制/布局操作错误期间避免对象分配
- java - 如何检查我的 firebaseUser 是否包含任何 displayName?
- transactions - Websphere 上设置的事务超时