-
Notifications
You must be signed in to change notification settings - Fork 5.5k
fix: use button for quiz words instead of text-field cp-13.0.0 #34280
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
CLA Signature Action: All authors have signed the CLA. You may need to manually re-run the blocking PR check if it doesn't pass in a few minutes. |
✨ Files requiring CODEOWNER review ✨👨🔧 @MetaMask/web3auth (3 files, +74 -93)
|
Builds ready [120d64c]
UI Startup Metrics (1237 ± 66 ms)
Benchmark value 254 exceeds gate value 10 for chrome browserify home mean backgroundConnect Benchmark value 3 exceeds gate value 1 for chrome browserify home mean initialActions Benchmark value 44 exceeds gate value 41 for chrome browserify home p95 domInteractive Benchmark value 265 exceeds gate value 18 for chrome browserify home p95 backgroundConnect Benchmark value 13 exceeds gate value 1.2 for chrome browserify home p95 initialActions Benchmark value 2377 exceeds gate value 2192 for chrome webpack home mean uiStartup Benchmark value 1761 exceeds gate value 1711 for chrome webpack home mean load Benchmark value 1754 exceeds gate value 1704 for chrome webpack home mean domContentLoaded Benchmark value 237 exceeds gate value 235 for chrome webpack home mean firstReactRender Benchmark value 16 exceeds gate value 7 for chrome webpack home mean initialActions Benchmark value 1749 exceeds gate value 1699 for chrome webpack home mean loadScripts Benchmark value 2865 exceeds gate value 2454 for chrome webpack home p95 uiStartup Benchmark value 2139 exceeds gate value 2030 for chrome webpack home p95 load Benchmark value 2125 exceeds gate value 2005 for chrome webpack home p95 domContentLoaded Benchmark value 64 exceeds gate value 57 for chrome webpack home p95 domInteractive Benchmark value 411 exceeds gate value 370 for chrome webpack home p95 firstReactRender Benchmark value 49 exceeds gate value 7 for chrome webpack home p95 initialActions Benchmark value 2112 exceeds gate value 1970 for chrome webpack home p95 loadScripts Benchmark value 1415 exceeds gate value 1405 for firefox browserify home mean uiStartup Benchmark value 111 exceeds gate value 110 for firefox browserify home mean domInteractive Benchmark value 27 exceeds gate value 25 for firefox browserify home mean backgroundConnect Benchmark value 4 exceeds gate value 1 for firefox browserify home mean initialActions Benchmark value 10 exceeds gate value 9 for firefox browserify home mean setupStore Benchmark value 1729 exceeds gate value 1660 for firefox browserify home p95 uiStartup Benchmark value 293 exceeds gate value 195 for firefox browserify home p95 domInteractive Benchmark value 17 exceeds gate value 2 for firefox browserify home p95 initialActions Benchmark value 1724 exceeds gate value 1615 for firefox webpack home mean uiStartup Benchmark value 1451 exceeds gate value 1380 for firefox webpack home mean load Benchmark value 1451 exceeds gate value 1380 for firefox webpack home mean domContentLoaded Benchmark value 106 exceeds gate value 100 for firefox webpack home mean domInteractive Benchmark value 29 exceeds gate value 26 for firefox webpack home mean backgroundConnect Benchmark value 55 exceeds gate value 38 for firefox webpack home mean firstReactRender Benchmark value 8 exceeds gate value 1 for firefox webpack home mean initialActions Benchmark value 1427 exceeds gate value 1360 for firefox webpack home mean loadScripts Benchmark value 15 exceeds gate value 13 for firefox webpack home mean setupStore Benchmark value 2216 exceeds gate value 1935 for firefox webpack home p95 uiStartup Benchmark value 1867 exceeds gate value 1660 for firefox webpack home p95 load Benchmark value 1867 exceeds gate value 1660 for firefox webpack home p95 domContentLoaded Benchmark value 292 exceeds gate value 156 for firefox webpack home p95 domInteractive Benchmark value 64 exceeds gate value 50 for firefox webpack home p95 firstReactRender Benchmark value 27 exceeds gate value 2 for firefox webpack home p95 initialActions Benchmark value 1838 exceeds gate value 1630 for firefox webpack home p95 loadScripts Benchmark value 51 exceeds gate value 28 for firefox webpack home p95 setupStore Sum of mean exceeds: 965ms | Sum of p95 exceeds: 2416.8ms Sum of all benchmark exceeds: 3381.8ms Bundle size diffs [🚀 Bundle size reduced!]
|
Builds ready [8c139ae]
UI Startup Metrics (1203 ± 58 ms)
Benchmark value 4 exceeds gate value 1 for chrome browserify home mean initialActions Benchmark value 42 exceeds gate value 41 for chrome browserify home p95 domInteractive Benchmark value 262 exceeds gate value 18 for chrome browserify home p95 backgroundConnect Benchmark value 13 exceeds gate value 1.2 for chrome browserify home p95 initialActions Benchmark value 2208 exceeds gate value 2192 for chrome webpack home mean uiStartup Benchmark value 260 exceeds gate value 235 for chrome webpack home mean firstReactRender Benchmark value 8 exceeds gate value 7 for chrome webpack home mean initialActions Benchmark value 2620 exceeds gate value 2454 for chrome webpack home p95 uiStartup Benchmark value 395 exceeds gate value 370 for chrome webpack home p95 firstReactRender Benchmark value 30 exceeds gate value 7 for chrome webpack home p95 initialActions Benchmark value 1410 exceeds gate value 1405 for firefox browserify home mean uiStartup Benchmark value 115 exceeds gate value 110 for firefox browserify home mean domInteractive Benchmark value 26 exceeds gate value 25 for firefox browserify home mean backgroundConnect Benchmark value 13 exceeds gate value 11 for firefox browserify home mean getState Benchmark value 5 exceeds gate value 1 for firefox browserify home mean initialActions Benchmark value 1711 exceeds gate value 1660 for firefox browserify home p95 uiStartup Benchmark value 311 exceeds gate value 195 for firefox browserify home p95 domInteractive Benchmark value 54 exceeds gate value 24 for firefox browserify home p95 getState Benchmark value 20 exceeds gate value 2 for firefox browserify home p95 initialActions Benchmark value 38 exceeds gate value 27 for firefox browserify home p95 setupStore Benchmark value 1736 exceeds gate value 1615 for firefox webpack home mean uiStartup Benchmark value 1465 exceeds gate value 1380 for firefox webpack home mean load Benchmark value 1465 exceeds gate value 1380 for firefox webpack home mean domContentLoaded Benchmark value 107 exceeds gate value 100 for firefox webpack home mean domInteractive Benchmark value 27 exceeds gate value 26 for firefox webpack home mean backgroundConnect Benchmark value 57 exceeds gate value 38 for firefox webpack home mean firstReactRender Benchmark value 11 exceeds gate value 1 for firefox webpack home mean initialActions Benchmark value 1445 exceeds gate value 1360 for firefox webpack home mean loadScripts Benchmark value 14 exceeds gate value 13 for firefox webpack home mean setupStore Benchmark value 2213 exceeds gate value 1935 for firefox webpack home p95 uiStartup Benchmark value 1815 exceeds gate value 1660 for firefox webpack home p95 load Benchmark value 1815 exceeds gate value 1660 for firefox webpack home p95 domContentLoaded Benchmark value 298 exceeds gate value 156 for firefox webpack home p95 domInteractive Benchmark value 50 exceeds gate value 49 for firefox webpack home p95 backgroundConnect Benchmark value 65 exceeds gate value 50 for firefox webpack home p95 firstReactRender Benchmark value 20 exceeds gate value 2 for firefox webpack home p95 initialActions Benchmark value 1780 exceeds gate value 1630 for firefox webpack home p95 loadScripts Benchmark value 58 exceeds gate value 28 for firefox webpack home p95 setupStore Sum of mean exceeds: 718ms | Sum of p95 exceeds: 1640.8ms Sum of all benchmark exceeds: 2358.8ms Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Bug: Recovery Phrase Display Glitches
Multiple issues affect the recovery phrase display:
Boxcomponents rendered in the word list are missing thekey={index}prop, which can cause React rendering issues.- Quiz words appear blank during the non-confirm (review) phase instead of displaying the actual word.
- The
TextFieldcomponent for non-quiz words in the confirm phase is missinginputProps={{ tabIndex: -1 }}. - The
onClickhandler for quiz words allows interaction (setting focus or removing words) outside of the confirm phase, which is unintended.
ui/pages/onboarding-flow/recovery-phrase/recovery-phrase-chips.js#L146-L202
metamask-extension/ui/pages/onboarding-flow/recovery-phrase/recovery-phrase-chips.js
Lines 146 to 202 in 08250b5
| const isTargetIndex = index === indexToFocus; | |
| return isQuizWord || !confirmPhase ? ( | |
| <Box | |
| as={isQuizWord ? 'button' : 'div'} | |
| data-testid={`recovery-phrase-chip-${index}`} | |
| className="recovery-phrase__text" | |
| display={Display.Flex} | |
| alignItems={AlignItems.center} | |
| backgroundColor={BackgroundColor.backgroundDefault} | |
| borderColor={ | |
| isTargetIndex | |
| ? BorderColor.primaryDefault | |
| : BorderColor.borderMuted | |
| } | |
| borderWidth={isTargetIndex ? 2 : 1} | |
| borderRadius={BorderRadius.LG} | |
| paddingInline={2} | |
| paddingTop={1} | |
| paddingBottom={1} | |
| gap={1} | |
| onClick={() => { | |
| if (!isQuizWord) { | |
| return; | |
| } | |
| if (wordToDisplay === '') { | |
| setIndexToFocus(index); | |
| } else { | |
| removeQuizWord(wordToDisplay); | |
| } | |
| }} | |
| > | |
| <Text | |
| color={TextColor.textAlternative} | |
| className="recovery-phrase__word-index" | |
| > | |
| {index + 1}. | |
| </Text> | |
| <Text>{isQuizWord ? wordToDisplay : word}</Text> | |
| </Box> | |
| ) : ( | |
| <TextField | |
| testId={`recovery-phrase-chip-${index}`} | |
| key={index} | |
| value={wordToDisplay} | |
| startAccessory={ | |
| <Text | |
| color={TextColor.textAlternative} | |
| className="recovery-phrase__word-index" | |
| > | |
| {index + 1}. | |
| </Text> | |
| } | |
| type="password" | |
| disabled | |
| readOnly | |
| /> | |
| ); |
Was this report helpful? Give feedback by reacting with 👍 or 👎
Builds ready [08250b5]
UI Startup Metrics (1266 ± 62 ms)
Benchmark value 1086 exceeds gate value 1070 for chrome browserify home mean load Benchmark value 1079 exceeds gate value 1061 for chrome browserify home mean domContentLoaded Benchmark value 214 exceeds gate value 10 for chrome browserify home mean backgroundConnect Benchmark value 4 exceeds gate value 1 for chrome browserify home mean initialActions Benchmark value 873 exceeds gate value 830 for chrome browserify home mean loadScripts Benchmark value 1392 exceeds gate value 1365 for chrome browserify home p95 uiStartup Benchmark value 1185 exceeds gate value 1180 for chrome browserify home p95 domContentLoaded Benchmark value 43 exceeds gate value 41 for chrome browserify home p95 domInteractive Benchmark value 235 exceeds gate value 18 for chrome browserify home p95 backgroundConnect Benchmark value 16 exceeds gate value 1.2 for chrome browserify home p95 initialActions Benchmark value 977 exceeds gate value 940 for chrome browserify home p95 loadScripts Benchmark value 2481 exceeds gate value 2192 for chrome webpack home mean uiStartup Benchmark value 1970 exceeds gate value 1711 for chrome webpack home mean load Benchmark value 1960 exceeds gate value 1704 for chrome webpack home mean domContentLoaded Benchmark value 22 exceeds gate value 21 for chrome webpack home mean domInteractive Benchmark value 15 exceeds gate value 7 for chrome webpack home mean initialActions Benchmark value 1955 exceeds gate value 1699 for chrome webpack home mean loadScripts Benchmark value 2669 exceeds gate value 2454 for chrome webpack home p95 uiStartup Benchmark value 2210 exceeds gate value 2030 for chrome webpack home p95 load Benchmark value 2190 exceeds gate value 2005 for chrome webpack home p95 domContentLoaded Benchmark value 61 exceeds gate value 57 for chrome webpack home p95 domInteractive Benchmark value 36 exceeds gate value 7 for chrome webpack home p95 initialActions Benchmark value 2187 exceeds gate value 1970 for chrome webpack home p95 loadScripts Benchmark value 1442 exceeds gate value 1405 for firefox browserify home mean uiStartup Benchmark value 28 exceeds gate value 25 for firefox browserify home mean backgroundConnect Benchmark value 28 exceeds gate value 25 for firefox browserify home mean firstReactRender Benchmark value 12 exceeds gate value 11 for firefox browserify home mean getState Benchmark value 4 exceeds gate value 1 for firefox browserify home mean initialActions Benchmark value 12 exceeds gate value 9 for firefox browserify home mean setupStore Benchmark value 1760 exceeds gate value 1660 for firefox browserify home p95 uiStartup Benchmark value 218 exceeds gate value 195 for firefox browserify home p95 domInteractive Benchmark value 78 exceeds gate value 70 for firefox browserify home p95 backgroundConnect Benchmark value 57 exceeds gate value 24 for firefox browserify home p95 getState Benchmark value 12 exceeds gate value 2 for firefox browserify home p95 initialActions Benchmark value 50 exceeds gate value 27 for firefox browserify home p95 setupStore Benchmark value 1748 exceeds gate value 1615 for firefox webpack home mean uiStartup Benchmark value 1485 exceeds gate value 1380 for firefox webpack home mean load Benchmark value 1485 exceeds gate value 1380 for firefox webpack home mean domContentLoaded Benchmark value 104 exceeds gate value 100 for firefox webpack home mean domInteractive Benchmark value 29 exceeds gate value 26 for firefox webpack home mean backgroundConnect Benchmark value 53 exceeds gate value 38 for firefox webpack home mean firstReactRender Benchmark value 7 exceeds gate value 1 for firefox webpack home mean initialActions Benchmark value 1462 exceeds gate value 1360 for firefox webpack home mean loadScripts Benchmark value 17 exceeds gate value 13 for firefox webpack home mean setupStore Benchmark value 2176 exceeds gate value 1935 for firefox webpack home p95 uiStartup Benchmark value 1870 exceeds gate value 1660 for firefox webpack home p95 load Benchmark value 1869 exceeds gate value 1660 for firefox webpack home p95 domContentLoaded Benchmark value 302 exceeds gate value 156 for firefox webpack home p95 domInteractive Benchmark value 57 exceeds gate value 49 for firefox webpack home p95 backgroundConnect Benchmark value 65 exceeds gate value 50 for firefox webpack home p95 firstReactRender Benchmark value 21 exceeds gate value 2 for firefox webpack home p95 initialActions Benchmark value 1825 exceeds gate value 1630 for firefox webpack home p95 loadScripts Benchmark value 35 exceeds gate value 28 for firefox webpack home p95 setupStore Sum of mean exceeds: 1912ms | Sum of p95 exceeds: 2379.8ms Sum of all benchmark exceeds: 4291.8ms Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
Description
This fixes firefox showing cursor for srp quiz words. Showing cursor makes user think that they can type on the text fields which are readonly on this case.
Changelog
CHANGELOG entry: Show Confirm SRP quiz words as button
Related issues
Fixes:
Manual testing steps
Screenshots/Recordings
Before
Screenshare.-.2025-07-15.2_14_33.PM.mp4
After
No cursor on Quizwords
https://github.com/user-attachments/assets/3705912b-a8f1-4769-8947-984e5ecf840d
Demo accessibility
https://github.com/user-attachments/assets/80091d04-5110-4499-84fa-bbb09fc9beb0
Pre-merge author checklist
Pre-merge reviewer checklist