We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent cb7b712 commit c6865c0Copy full SHA for c6865c0
src/index.tsx
@@ -131,6 +131,7 @@ const ReactInputVerificationCode = ({
131
*/
132
if (eventValue.length > 1) {
133
console.log('RIVC: isOtp');
134
+ console.log('RIVC: isOtp:focusedIndex', focusedIndex, index);
135
136
console.log('RIVC: fillValues(eventValue)', fillValues(eventValue));
137
setValues(fillValues(eventValue));
@@ -245,7 +246,7 @@ const ReactInputVerificationCode = ({
245
246
<div className='ReactInputVerificationCode-container'>
247
{inputsRefs.map((ref, i) => (
248
<input
- autoComplete='one-time-code'
249
+ {...(focusedIndex === i && { autoComplete: 'one-time-code' })}
250
className='ReactInputVerificationCode-item'
251
key={i}
252
onChange={(event) => onInputChange(event, i)}
0 commit comments