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

Set role=button on the Layer control #7850

Merged
merged 1 commit into from Dec 10, 2021

Conversation

Malvoz
Copy link
Member

@Malvoz Malvoz commented Dec 9, 2021

Closes #6821 - This PR closes that issue because the WCAG error reported is only applicable to elements with role=link (implicit from <a> in the case of the layer control) and not buttons (which this PR changes)!

Closes #6869 - Unlike that PR, this doesn't set aria-label (in addition to the existing title) as that's not only redundant but would also cause some screen readers to announce "Layers" twice - which is an obvious annoyance to screen reader users.

Fix #7498.

@Falke-Design Falke-Design added the accessibility Anything related to ensuring no barriers exist that prevent interactions or information access label Dec 9, 2021
@mourner mourner merged commit acffb7e into Leaflet:master Dec 10, 2021
@Malvoz Malvoz deleted the layer-control-button branch December 10, 2021 17:16
@vanillajonathan
Copy link
Contributor

Maybe using a button element ought to be considered instead of a a element?

@Malvoz
Copy link
Member Author

Malvoz commented Dec 11, 2021

@vanillajonathan see #7821.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
accessibility Anything related to ensuring no barriers exist that prevent interactions or information access
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Layer control should have role="button" Layers Control has a WCAG Level A Empty Link Error
4 participants