-
Notifications
You must be signed in to change notification settings - Fork 0
/
4html5宣传页常用动画自己写.html
124 lines (117 loc) · 3.08 KB
/
4html5宣传页常用动画自己写.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport"
content="initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0, user-scalable=no, width=device-width"/>
<title>html5宣传页常用动画自己写</title>
<style>
.animated{
-webkit-animation-duration: 1s;
animation-duration: 1s;
-webkit-animation-fill-mode:both;
animation-fill-mode:both;/*在动画播放之前和之后,动画效果可见*/
}
/*渐显效果start*/
@-webkit-keyframes fade-in {
0%{
opacity: 0;
}
to{
opacity: 1;
}
}
@keyframes fade-in {
0%{
opacity: 0;
}
to{
opacity: 1;
}
}
.fadeIn{
-webkit-animation-name:fadeIn;
animation-name:fadeIn;
}
.fadeIn1{
animation-delay: .3s;
}
.fadeIn2{
animation-delay: .6s;
}
/*渐显效果end*/
/*提示向上滑箭头动效start*/
@keyframes btnarrow {
0%{
margin-bottom:0;
}
25%{
margin-bottom:-4px;
}
75%{
margin-bottom:4px;
}
to{
margin-bottom:0;
}
}
.btn-arrow{
animation: btnarrow 1s linear infinite;
}
/*提示向上滑箭头动效end*/
/*左右动start*/
@keyframes plyleft {
0%{
left:0;
}
50%{
left:-8px;
}
to{
left:0;
}
}
.ply-left{
animation: plyleft 1s linear infinite;
}
/*左右动end*/
/*bounceIn start*/
@keyframes bounceIn {
0%,20%,40%,60%,80%,to {
-webkit-animation-timing-function: cubic-bezier(.215,.61,.355,1);
animation-timing-function: cubic-bezier(.215,.61,.355,1)
}
0% {
opacity: 0;
-webkit-transform: scale3d(.3,.3,.3);
transform: scale3d(.3,.3,.3)
}
20% {
-webkit-transform: scale3d(1.1,1.1,1.1);
transform: scale3d(1.1,1.1,1.1)
}
40% {
-webkit-transform: scale3d(.9,.9,.9);
transform: scale3d(.9,.9,.9)
}
60% {
opacity: 1;
-webkit-transform: scale3d(1.03,1.03,1.03);
transform: scale3d(1.03,1.03,1.03)
}
80% {
-webkit-transform: scale3d(.97,.97,.97);
transform: scale3d(.97,.97,.97)
}
to {
opacity: 1;
-webkit-transform: scaleX(1);
transform: scaleX(1)
}
}
/*bounceIn end*/
</style>
</head>
<body>
</body>
</html>