fix(a11y): align DOM order with visual order in mobile bottom-nav (WCAG 1.3.2)#3441
Open
bilal-karim wants to merge 1 commit into
Open
fix(a11y): align DOM order with visual order in mobile bottom-nav (WCAG 1.3.2)#3441bilal-karim wants to merge 1 commit into
bilal-karim wants to merge 1 commit into
Conversation
…wer (WCAG 1.3.2) The drawer used flex-col-reverse to put the most-important section nearest the user's thumb at the bottom of the screen. Visually correct, but the implementation chose to reverse via CSS rather than data -- so sighted users saw [C, B, A] while screen readers and keyboard tab encountered [A, B, C]. This is the canonical WCAG 1.3.2 Meaningful Sequence failure. Move the reversal from CSS to a $derived in script, then use plain flex-col so DOM order matches visual order. Visual output is identical to today; only DOM, keyboard tab, and screen-reader reading order change. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
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.
Summary
The mobile bottom-nav drawer used
flex-col-reverseto put the most-important section closest to the user's thumb at the bottom of the screen. Visually correct, but the implementation chose to reverse via CSS rather than data:[C, B, A](bottom-up importance)[A, B, C](DOM order)This is the canonical WCAG 1.3.2 Meaningful Sequence failure — visual reading order diverges from programmatic reading order.
Fix
Move the reversal from CSS to a
$derivedin script, then use plainflex-col:Visual output is identical. DOM order, keyboard tab order, and screen-reader reading order now all agree.
Audit context
audit-output/issues/1.3.2-bottom-nav-links-order.md.aria-describedbylinkage) was deferred to the 1.4.13 tooltip remediation. That dependency is already satisfied by PR fix(a11y): make Tooltip keyboard-accessible, dismissible, and hoverable #3429, which adds thearia-describedbywiring.Test plan
<NavSection>elements should appear invisualSectionsorder, not the reversed-by-CSS original.🤖 Generated with Claude Code
A11y-Audit-Ref: 1.3.2-bottom-nav-links-order