14 background-color: red;
17 background-color: green;
18 /* This timing function has value
0 at inputs of
1/
3 and
2/
3. Chosen because it's very asymmetric about x = y. */
19 -webkit-animation: move
3000000s
2 cubic-bezier(
0.333333,
0.333333,
0.666666, -
0.833333) forwards;
24 -webkit-animation-delay:
0s;
27 -webkit-animation-delay: -
1000000s;
30 -webkit-animation-delay: -
2000000s;
33 -webkit-animation-delay: -
3000000s;
36 -webkit-animation-delay: -
4000000s;
39 -webkit-animation-delay: -
5000000s;
42 -webkit-animation-delay: -
6000000s;
46 transform: translateX(
100px);
48 #normal .expected.delay_six_thirds {
49 transform: translateX(
200px);
51 #alternate .expected.delay_three_thirds {
52 transform: translateX(
200px);
54 #reverse .expected.delay_zero, #reverse .expected.delay_three_thirds {
55 transform: translateX(
200px);
57 #alternate-reverse .expected.delay_zero, #alternate-reverse .expected.delay_six_thirds {
58 transform: translateX(
200px);
62 -webkit-animation-direction: normal;
65 -webkit-animation-direction: alternate;
68 -webkit-animation-direction: reverse;
70 #alternate-reverse div {
71 -webkit-animation-direction: alternate-reverse;
74 @-webkit-keyframes move {
75 from { transform: translateX(
100px); }
76 to { transform: translateX(
200px); }
82 Tests animation direction with timing functions and hardware acceleration.
83 The green boxes use live animations and each should line up with the red box
86 <div class=
"wrapper" id=
"normal">
87 <div class=
"expected delay_zero">normal
</div>
88 <div class=
"animated delay_zero">normal
</div>
89 <div class=
"expected delay_one_third">normal
</div>
90 <div class=
"animated delay_one_third">normal
</div>
91 <div class=
"expected delay_two_thirds">normal
</div>
92 <div class=
"animated delay_two_thirds">normal
</div>
93 <div class=
"expected delay_three_thirds">normal
</div>
94 <div class=
"animated delay_three_thirds">normal
</div>
95 <div class=
"expected delay_four_thirds">normal
</div>
96 <div class=
"animated delay_four_thirds">normal
</div>
97 <div class=
"expected delay_five_thirds">normal
</div>
98 <div class=
"animated delay_five_thirds">normal
</div>
99 <div class=
"expected delay_six_thirds">normal
</div>
100 <div class=
"animated delay_six_thirds">normal
</div>
102 <div class=
"wrapper" id=
"alternate">
103 <div class=
"expected delay_zero">alternate
</div>
104 <div class=
"animated delay_zero">alternate
</div>
105 <div class=
"expected delay_one_third">alternate
</div>
106 <div class=
"animated delay_one_third">alternate
</div>
107 <div class=
"expected delay_two_thirds">alternate
</div>
108 <div class=
"animated delay_two_thirds">alternate
</div>
109 <div class=
"expected delay_three_thirds">alternate
</div>
110 <div class=
"animated delay_three_thirds">alternate
</div>
111 <div class=
"expected delay_four_thirds">alternate
</div>
112 <div class=
"animated delay_four_thirds">alternate
</div>
113 <div class=
"expected delay_five_thirds">alternate
</div>
114 <div class=
"animated delay_five_thirds">alternate
</div>
115 <div class=
"expected delay_six_thirds">alternate
</div>
116 <div class=
"animated delay_six_thirds">alternate
</div>
118 <div class=
"wrapper" id=
"reverse">
119 <div class=
"expected delay_zero">reverse
</div>
120 <div class=
"animated delay_zero">reverse
</div>
121 <div class=
"expected delay_one_third">reverse
</div>
122 <div class=
"animated delay_one_third">reverse
</div>
123 <div class=
"expected delay_two_thirds">reverse
</div>
124 <div class=
"animated delay_two_thirds">reverse
</div>
125 <div class=
"expected delay_three_thirds">reverse
</div>
126 <div class=
"animated delay_three_thirds">reverse
</div>
127 <div class=
"expected delay_four_thirds">reverse
</div>
128 <div class=
"animated delay_four_thirds">reverse
</div>
129 <div class=
"expected delay_five_thirds">reverse
</div>
130 <div class=
"animated delay_five_thirds">reverse
</div>
131 <div class=
"expected delay_six_thirds">reverse
</div>
132 <div class=
"animated delay_six_thirds">reverse
</div>
134 <div class=
"wrapper" id=
"alternate-reverse">
135 <div class=
"expected delay_zero">alternate-reverse
</div>
136 <div class=
"animated delay_zero">alternate-reverse
</div>
137 <div class=
"expected delay_one_third">alternate-reverse
</div>
138 <div class=
"animated delay_one_third">alternate-reverse
</div>
139 <div class=
"expected delay_two_thirds">alternate-reverse
</div>
140 <div class=
"animated delay_two_thirds">alternate-reverse
</div>
141 <div class=
"expected delay_three_thirds">alternate-reverse
</div>
142 <div class=
"animated delay_three_thirds">alternate-reverse
</div>
143 <div class=
"expected delay_four_thirds">alternate-reverse
</div>
144 <div class=
"animated delay_four_thirds">alternate-reverse
</div>
145 <div class=
"expected delay_five_thirds">alternate-reverse
</div>
146 <div class=
"animated delay_five_thirds">alternate-reverse
</div>
147 <div class=
"expected delay_six_thirds">alternate-reverse
</div>
148 <div class=
"animated delay_six_thirds">alternate-reverse
</div>