使用CSS指定动画的速度曲线
使用 动画定时功能设置动画的速度曲线。您可以尝试运行以下代码来实现此目的
例
<!DOCTYPE html>
<html>
<head>
<style>
div {
width: 150px;
height: 200px;
position: relative;
background-color: yellow;
animation-name: myanim;
animation-duration: 2s;
animation-direction: alternate-reverse;
animation-iteration-count: 3;
}
@keyframes myanim {
from {left: 100px;}
to {left: 200px;}
}
#demo1 {animation-timing-function: ease;}
#demo2 {animation-timing-function: ease-in;}
</style>
</head>
<body>
<div id = "demo1">ease effect</div>
<div id = "demo2">ease-in effect</div>
</body>
</html>热门推荐
2 邀请函简短祝福语
10 宴会签名祝福语简短
11 园长退休祝福语老师简短
12 卡片老师祝福语简短样式
13 虎年新年短句祝福语简短
14 简短祝福语开业大全
15 医院探望朋友祝福语简短
16 乔迁大吉花束祝福语简短
17 赠朋友文案祝福语简短
18 六一给小孩祝福语简短