forked from patw0929/react-intl-tel-input
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Ramp task: https://ramp.accessibleweb.com/app/websites/83ca83c6265c/tasks/2787246f7ae2 This allows following WAI-ARIA best practices for combobox elements - https://www.w3.org/WAI/ARIA/apg/patterns/combobox/. Changes in this PR mostly correspond to the patw0929#405 Although most of the best practices to improve accessibility were implemented, the role="combobox" was not added neither the to the number input (because the input doesn't show/hide the dropdown), nor to the country code button. Looks like OSx VoiceOver announces everything correctly. Changes: - Add role="listbox" to the countries list - Refer the countries list by its Id in the country code button via aria-controls and aria-owns - Add role="option" to each country list option - Use aria-expanded on the country code button element - Refer focused option by its Id in the country code button element via aria-activedescendant to read focused option while navigating by keyboard - Add aria-selected="true" to the selected list option - Set aria-autocomplete="none" to the country code button element since displayed options do not depend on the number input value - Allow passing arbitrary props to the country code button element via flagDropdownProps prop (for example, "aria-labelledby" property can be passed) Updates dist files (built with node 8.17.0)
- Loading branch information
1 parent
cb3180a
commit 11ade03
Showing
9 changed files
with
45 additions
and
10 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters