[test] Automate the CSS-dependent WCAG criteria - #48936
Open
michelengelen wants to merge 2 commits into
Open
Conversation
michelengelen
force-pushed
the
a11y/stack/css-layout
branch
from
August 6, 2026 09:42
5587902 to
c3c7ff5
Compare
Deploy previewBundle size
Check out the code infra dashboard for more information about this PR. |
michelengelen
force-pushed
the
a11y/stack/css-layout
branch
2 times, most recently
from
August 6, 2026 10:43
1ea91f9 to
a71dd4e
Compare
michelengelen
marked this pull request as ready for review
August 7, 2026 10:14
michelengelen
force-pushed
the
a11y/stack/css-layout
branch
from
August 7, 2026 11:37
a71dd4e to
9ca0385
Compare
Lets a fixture assert every axe rule it exercises rather than only the CSS-dependent visual ones, which is what the per-component WCAG reports need.
Adds a table-driven Playwright suite covering 1.4.10 Reflow, 1.4.4 Resize Text and 1.4.12 Text Spacing across the assessed components. axe has no rule for any of them, so they were rated Manual on evidence from source review.
michelengelen
force-pushed
the
a11y/stack/css-layout
branch
from
August 7, 2026 13:00
9ca0385 to
ce470aa
Compare
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.
Adds a table-driven Playwright suite covering the CSS-dependent WCAG criteria that axe has no rule for, so they stop resting on source review alone:
11 components are enrolled through one representative demo each, giving 32 assertions. Entries skip routes the current bundle doesn't contain, so the suite is correct regardless of which components have been enrolled yet.
The clip check measures the text range against its box and ignores hidden subtrees, rather than comparing
scrollWidth/clientWidth. That distinction matters: a Switch root clips its ripple and a collapsed Accordion panel isvisibility: hidden— neither loses content, and a naive check flags both.Avatar's 1.4.4 is deliberately excluded. The suite asserts text-only resize; Avatar's fixed 40px box only scales under full-page zoom. Its report already considered this and rates it against page zoom, calling text-only "an author concern", so the rating is left as-is rather than silently downgraded.
Together with the unit tests added in the component PRs, this takes the ⚙️ Automated column from 62/230 to 94/230, and verified evidence from 155/230 to 185/230.
Important
How to review this PR
Layer 2 of 13 in a stacked series (#48915 → #48926). Its branch is built on
a11y/stack/harness(#48915). GitHub cannot chain PR bases across a fork, so every PR in the series targetsmasterinstead.Review only the last commit —
ce470aa. Everything above it belongs to the layers below, and disappears as those merge.Part of the WCAG conformance effort (#14187).