[Autocomplete] Fix the errors reported by Wave#18283
Conversation
Details of bundle changes.Comparing: 3d393bf...42aa823
|
|
|
||
| .token.boolean, | ||
| .token.number { | ||
| color: #b78eff; |
There was a problem hiding this comment.
Reach AA contrast level. The problem is more visible since the introduction of code previews.
|
|
||
| return ( | ||
| <Autocomplete | ||
| id="asynchronous-demo" |
There was a problem hiding this comment.
Fix id duplication, server-side as reported by https://validator.w3.org/.
| <IconButton | ||
| {...getPopupIndicatorProps()} | ||
| disabled={disabled} | ||
| aria-label={popupOpen ? 'Close popup' : 'Open popup'} |
There was a problem hiding this comment.
Fix a Wave error, not all the screen readers handle title.
| }), | ||
| getInputLabelProps: () => ({ | ||
| id: `${id}-label`, | ||
| htmlFor: id, |
There was a problem hiding this comment.
In case somebody doesn't use our TextField.
| // (autocomplete and autofill) | ||
| autoComplete: 'disabled', | ||
| ref: inputRef, | ||
| autoCorrect: 'off', |
There was a problem hiding this comment.
Invalid HTML attribute and seems legacy for older versions of Safari. I'm eager to try without.
| 'aria-controls': `${id}-popup`, | ||
| // autoComplete: 'off', // Disable browser's suggestion that might overlap with the popup. | ||
| autoComplete: 'disabled', // disable autocomplete and autofill | ||
| 'aria-controls': popupOpen ? `${id}-popup` : null, |
There was a problem hiding this comment.
Fix https://validator.w3.org/ error were aria-controls points to a missing element.
| > | ||
| {renderInput({ | ||
| ref: setAnchorEl, | ||
| id, |
There was a problem hiding this comment.
Used by TextField to link the helper text, input, and label together. Error reported by Wave and https://validator.w3.org/.
59ddd6b to
42aa823
Compare
Closes #18132
Solve most of the errors reported by Wave and https://validator.w3.org/.