Repository navigation
fix(landing): give the slider thumbnails a name and the comparison table keyboard access - #236
Merged
Merged
Conversation
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
axe-core 4.14.0 with the WCAG 2.0/2.1 A and AA plus best-practice tags found two issues:
button-name(critical): the slider thumbnails are built inapp.jswithrole="tab", and their only child is an image with an emptyalt, so neither of them had an accessible name.scrollable-region-focusable(serious, phones only): the comparison table scrolls horizontally and a keyboard user could not reach it.Changes
landing/app.js: each thumbnail getsaria-labelfrom its caption (translated),aria-controlspointing at the viewport, and rovingtabindexso only the active one is in the tab order. Arrow keys, Home and End move between slides and follow the focus.landing/index.html: the viewport is atabpanel, the table wrapper is a namedregionwithtabindex="0", and the cache-bust goes to?v=9.landing/i18n.js:compare.tableLabelin ES and EN.landing/styles.css: visible focus ring on the table wrapper.Verification
aria-controls, single tab stop, ArrowRight, Home and End, focus follows, table focusable and labelled, focus ring, labels switch to English with the language).Already deployed to https://nextsync.cloudless.club/ and verified there.
Closes #235