回答編集履歴
2
追記
answer
CHANGED
@@ -36,4 +36,23 @@
|
|
36
36
|
z-index:1;
|
37
37
|
animation-delay:5.2s;
|
38
38
|
}
|
39
|
+
```
|
40
|
+
|
41
|
+
こうすると、見かけ上、1番最初だけ画像が消えるのが早い**気がする**と思うので、その場合は
|
42
|
+
`.slide_animation_1`から`.slide_animation_3`まで`animation-delay`を同じ秒数ずつ伸ばしてやればよいです。
|
43
|
+
|
44
|
+
例)
|
45
|
+
```CSS
|
46
|
+
.slide_animation_1{
|
47
|
+
z-index: 3;
|
48
|
+
animation-delay:1.3s;
|
49
|
+
}
|
50
|
+
.slide_animation_2{
|
51
|
+
z-index: 2;
|
52
|
+
animation-delay:3.9s;
|
53
|
+
}
|
54
|
+
.slide_animation_3{
|
55
|
+
z-index:1;
|
56
|
+
animation-delay:6.5s;
|
57
|
+
}
|
39
58
|
```
|
1
追記
answer
CHANGED
@@ -6,4 +6,34 @@
|
|
6
6
|
|
7
7
|
なので、3枚目→1枚目の長さが他より少し長いですね。
|
8
8
|
|
9
|
-
解決策としては、`animation-duration`を`7.8s`で`.slide_animation_3`を'5.2s'にする感じですかね。
|
9
|
+
解決策としては、`animation-duration`を`7.8s`で`.slide_animation_3`を'5.2s'にする感じですかね。
|
10
|
+
|
11
|
+
## 追記
|
12
|
+
```CSS
|
13
|
+
.slide_animation{
|
14
|
+
animation-name:slide;
|
15
|
+
animation-duration:7.8s; /* 2.6s × 3枚 */
|
16
|
+
animation-iteration-count:infinite;
|
17
|
+
opacity:1;
|
18
|
+
position:absolute;
|
19
|
+
}
|
20
|
+
|
21
|
+
@keyframes slide {
|
22
|
+
0%{opacity:1}
|
23
|
+
33.33333%{opacity:0}
|
24
|
+
66.66666%{opacity:0;}
|
25
|
+
100%{opacity:1;}
|
26
|
+
}
|
27
|
+
.slide_animation_1{
|
28
|
+
z-index: 3;
|
29
|
+
animation-delay:0s;
|
30
|
+
}
|
31
|
+
.slide_animation_2{
|
32
|
+
z-index: 2;
|
33
|
+
animation-delay:2.6s;
|
34
|
+
}
|
35
|
+
.slide_animation_3{
|
36
|
+
z-index:1;
|
37
|
+
animation-delay:5.2s;
|
38
|
+
}
|
39
|
+
```
|