質問編集履歴

1

rightをrigthと書いてました〜。初歩的ミス!!!

2018/11/09 09:51

投稿

akane7744
akane7744

スコア8

test CHANGED
File without changes
test CHANGED
@@ -34,7 +34,7 @@
34
34
 
35
35
  中央のパネル
36
36
 
37
- <span class="btn" id="rigth">
37
+ <span class="btn" id="right">
38
38
 
39
39
  戻る
40
40
 
@@ -46,7 +46,7 @@
46
46
 
47
47
  右のパネル
48
48
 
49
- <span class="btn" id="rigth2">
49
+ <span class="btn" id="right2">
50
50
 
51
51
  戻る
52
52
 
@@ -60,7 +60,7 @@
60
60
 
61
61
  ```
62
62
 
63
- 問題の中央パネルの戻るボタンのidは `rigth` でclassNameを空文字するclickイベントをつけている。
63
+ 問題の中央パネルの戻るボタンのidは `right` でclassNameを空文字するclickイベントをつけている。
64
64
 
65
65
  しかし、実装して見ると `move2` のクラスがついてしまい、先頭に戻らない。
66
66
 
@@ -84,7 +84,7 @@
84
84
 
85
85
  });
86
86
 
87
- rigth2.addEventListener('click',function(){
87
+ right2.addEventListener('click',function(){
88
88
 
89
89
  // 500px動く
90
90
 
@@ -92,7 +92,7 @@
92
92
 
93
93
  });
94
94
 
95
- rigth.addEventListener('click',function(){
95
+ right.addEventListener('click',function(){
96
96
 
97
97
  cards.className = '';
98
98
 
@@ -170,7 +170,7 @@
170
170
 
171
171
  <div class="card2">
172
172
 
173
- <div class="rigth">
173
+ <div class="right">
174
174
 
175
175
  右側のカード
176
176