博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
css3过渡效果
阅读量:6367 次
发布时间:2019-06-23

本文共 3422 字,大约阅读时间需要 11 分钟。

只需在要使用动效的元素加上class类即可生效(以下是局部class类)

/* 淡入 */

.a-fadein{
-webkit-animation-name:fadein;
-moz-animation-name:fadein;
-ms-animation-name:fadein;
animation-name:fadein;
-webkit-animation-duration: 1000ms;
-ms-animation-duration: 1000ms;
animation-duration: 1000ms;
-webkit-animation-iteration-count: infinite;
-ms-animation-iteration-count: infinite;
animation-iteration-count: infinite;
-webkit-animation-timing-function: ease-in-out;
-ms-animation-timing-function: ease-in-out;
animation-timing-function: ease-in-out;
-webkit-animation-delay: 0s;
-ms-animation-delay: 0s;
animation-delay: 0s;
-webkit-animation-play-state: running;
-ms-animation-play-state: running;
animation-play-state: running
}

/* 淡出 */

.a-fadeout{
-webkit-animation-name:fadeout;
-moz-animation-name:fadeout;
-ms-animation-name:fadeout;
animation-name:fadeout;
-webkit-animation-duration: 1000ms;
-ms-animation-duration: 1000ms;
animation-duration: 1000ms;
-webkit-animation-iteration-count: infinite;
-ms-animation-iteration-count: infinite;
animation-iteration-count: infinite;
-webkit-animation-timing-function: ease-in-out;
-ms-animation-timing-function: ease-in-out;
animation-timing-function: ease-in-out;
-webkit-animation-delay: 0s;
-ms-animation-delay: 0s;
animation-delay: 0s;
-webkit-animation-play-state: running;
-ms-animation-play-state: running;
animation-play-state: running
}

/* 弹跳 */

.a-bounce{
-webkit-animation-name:bounce;
-moz-animation-name:bounce;
-ms-animation-name:bounce;
animation-name:bounce;
-webkit-animation-duration: 1000ms;
-ms-animation-duration: 1000ms;
animation-duration: 1000ms;
-webkit-animation-iteration-count: infinite;
-ms-animation-iteration-count: infinite;
animation-iteration-count: infinite;
-webkit-animation-timing-function: ease-in-out;
-ms-animation-timing-function: ease-in-out;
animation-timing-function: ease-in-out;
-webkit-animation-delay: 0s;
-ms-animation-delay: 0s;
animation-delay: 0s;
-webkit-animation-play-state: running;
-ms-animation-play-state: running;
animation-play-state: running;
}

/* 弹入 */

.a-bouncein{
-webkit-animation-name:bouncein;
-moz-animation-name:bouncein;
-ms-animation-name:bouncein;
animation-name:bouncein;
-webkit-animation-duration: 1000ms;
-ms-animation-duration: 1000ms;
animation-duration: 1000ms;
-webkit-animation-iteration-count: infinite;
-ms-animation-iteration-count: infinite;
animation-iteration-count: infinite;
-webkit-animation-timing-function: ease-in-out;
-ms-animation-timing-function: ease-in-out;
animation-timing-function: ease-in-out;
-webkit-animation-delay: 0s;
-ms-animation-delay: 0s;
animation-delay: 0s;
-webkit-animation-play-state: running;
-ms-animation-play-state: running;
animation-play-state: running;
}

/* 弹出 */

.a-bounceout{
-webkit-animation-name:bounceout;
-moz-animation-name:bounceout;
-ms-animation-name:bounceout;
animation-name:bounceout;
-webkit-animation-duration: 1000ms;
-ms-animation-duration: 1000ms;
animation-duration: 1000ms;
-webkit-animation-iteration-count: infinite;
-ms-animation-iteration-count: infinite;
animation-iteration-count: infinite;
-webkit-animation-timing-function: ease-in-out;
-ms-animation-timing-function: ease-in-out;
animation-timing-function: ease-in-out;
-webkit-animation-delay: 0s;
-ms-animation-delay: 0s;
animation-delay: 0s;
-webkit-animation-play-state: running;
-ms-animation-play-state: running;
animation-play-state: running;
}

转载于:https://www.cnblogs.com/xgxh/p/9812522.html

你可能感兴趣的文章
Android打地鼠游戏的修改和优化
查看>>
Java异常
查看>>
map、reduce、filter、for...of、for...in等总结
查看>>
html2canvas-实现页面截图
查看>>
入门 | 从文本处理到自动驾驶:机器学习最常用的50大免费数据集
查看>>
笔记-从源码角度分析alloc与init的底层
查看>>
消除GitHub上的历史记录
查看>>
自学 JAVA 的几点建议
查看>>
第十三天-企业应用架构模式-对象-关系元数据映射模式
查看>>
k8s与HPA--通过 Prometheus adaptor 来自定义监控指标
查看>>
Python 比特币教程之二: 机器人收发比特币
查看>>
虎牙直播在微服务改造方面的实践和总结
查看>>
怎样将优酷网站下载的视频KUX转MP4格式
查看>>
MongoDB 分组统计
查看>>
二进制状态码
查看>>
Vue 中 CSS 动画原理
查看>>
关于 Promise 的 9 个提示
查看>>
算法复习
查看>>
安卓中高级开发面试知识点之——缓存
查看>>
Java的初始化顺序
查看>>