Skip to content
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

Fixing non compliant divider in country dropdown #1485

Conversation

stuart-johnson-calendly
Copy link
Contributor

@stuart-johnson-calendly stuart-johnson-calendly commented Dec 6, 2023

Divider li in the country dropdown, between "preferred" countries and the rest of the list, uses the: role='separator' attribute/value. This does not comply with the aria a11y standards, as separators are not allowed in listboxes. I've removed the role, and made the divider aria-hidden='true', to remove it from the a11y tree, since there isn't a particularly good way to implement it that is compliant with a11y standards.

@jackocnr
Copy link
Owner

jackocnr commented Dec 7, 2023

Thanks for putting this together. Can you provide an authoritative source saying that role=separator is not allowed within role=listbox?

@stuart-johnson-calendly
Copy link
Contributor Author

@jackocnr So, I'm having trouble finding a specific statement about it NOT being allowed, but the aria docs/specification seem to infer that it is expected to only be between menuitems specifically, and therefor not allowed between anything else?

This thread here seems to be confident, and it's from the axe-core project:
dequelabs/axe-core#3938

@jackocnr
Copy link
Owner

jackocnr commented Dec 7, 2023

Thanks. I merged your commit manually 👍

@jackocnr jackocnr closed this Dec 7, 2023
@stuart-johnson-calendly
Copy link
Contributor Author

@jackocnr Awesome, thanks! Any chance for a quick patch release with this? I'm in the middle of a big a11y compliance project and this is one of my outstanding issues.

@jackocnr
Copy link
Owner

jackocnr commented Dec 8, 2023

Done

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants