WARNING: THIS SITE IS A MIRROR OF GITHUB.COM / IT CANNOT LOGIN OR REGISTER ACCOUNTS / THE CONTENTS ARE PROVIDED AS-IS / THIS SITE ASSUMES NO RESPONSIBILITY FOR ANY DISPLAYED CONTENT OR LINKS / IF YOU FOUND SOMETHING MAY NOT GOOD FOR EVERYONE, CONTACT ADMIN AT ilovescratch@foxmail.com
Skip to content

Commit bed7937

Browse files
committed
コメント追加
1 parent 4347a78 commit bed7937

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

201/src/App.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -138,17 +138,17 @@ function App() {
138138
<button
139139
key={ value }
140140
ref={ ( node ) => {
141-
listRef.current[ i + 1 ] = node;
141+
listRef.current[ i + 1 ] = node; // `i + 1` として自身を判定する
142142
} }
143143
type="button"
144-
tabIndex={ i + 1 === activeIndex ? 0 : - 1 }
144+
tabIndex={ i + 1 === activeIndex ? 0 : - 1 } // `i + 1` として自身を判定する
145145
style={ {
146146
display: "flex",
147147
gap: 8,
148148
width: "100%",
149149
border: 0,
150150
textAlign: "left",
151-
background: i + 1 === activeIndex ? "cyan" : "",
151+
background: i + 1 === activeIndex ? "cyan" : "", // `i + 1` として自身を判定する
152152
} }
153153
{ ...getItemProps( {
154154
onClick() {

0 commit comments

Comments
 (0)