fix(breadcrumbs): consistent aria-current placement on content element (navigation-11)#3399
Merged
Merged
Conversation
… the <li> (navigation-11)
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Contributor
PR Analysis Report📚 Storybook PreviewView Storybook for this PR 🧪 Sandbox PreviewView Sandbox for this PR No new or modified components detected. Bundle Size Summary
Accessibility AuditStatus: No accessibility violations detected. Generated by PR Enrichment workflow | Storybook | Sandbox | View full report |
cixzhang
commented
Jul 2, 2026
30 tasks
josephfarina
approved these changes
Jul 2, 2026
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.
Part of the accessibility & keyboard-management program (#3343). Fixes finding
navigation-11.Problem
Breadcrumb
aria-current="page"placement was inconsistent:isCurrent) setaria-currenton the outer<li>viasetAttribute.isCurrentpath renders it on the inner content<span>.aria-current— so screen readers didn't announce the current page on the actual navigation element.Fix
The auto-detect effect now targets the item's content element (the link/button/span rendered after the separator — the
<li>'s last child), matching where the explicit path places it.aria-currentlands on the anchor when the last item is a link, and never on the<li>.Tests
Updates the auto-detect tests to assert placement on the content element (and that the
<li>does not carry it), and adds a case for the last-item-is-a-link scenario (anchor carriesaria-current). Full Breadcrumbs suite green (25 tests), typecheck + lint clean.