agentleFS
bodish-coderbodish-coder/skillator/skills/a11y-toph/SKILL.md

a11y-toph

Skill1 starsChanged 2 months agoMITView on GitHub

Use when accessibility is the subject: an a11y or WCAG audit of existing code, a VPAT or compliance question, or a reported bug — "can't tab to it", "focus ring invisible", "screen reader reads nothing", "the toast never announces", "fails contrast", "no reduced-motion", "tap target too small", "the error is only red". Also for wiring axe, pa11y or Lighthouse into tests or CI. NOT for designing or building an interface — a11y inside a design task is design-arwen's ship gate.

The file

We split this skill into the rules it gives an agent

2 rules. About 0 are common, 1 is distinctive, and 1 is very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈1

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 1

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Every finding: file:line + the reproduction (the exact keystroke sequence, the measured number, or the tool output).

    line 67
  2. Distinctive:

    Run every row. Order matters: static first (cheap, narrows the surface), then the browser passes, then assistive technology.

    line 107

≈ “Common” is an estimate: at least 1 in 5 of the 213,897 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

a11y-toph — accessibility as the subject, proven by running it

NO ACCESSIBILITY CLAIM WITHOUT A RUN CHECK

An accessibility finding is a reproduction, not an opinion about source code. An accessibility fix is the same reproduction, re-run, now passing. Reading the JSX and concluding "this is now keyboard-accessible" is the failure this skill exists to delete — it is exactly what a capable agent does when nobody stops it, and it is wrong often enough to be worthless.

Everything here binds PRACTICE.md §4 (the reproduction is the failing test — record it before you touch a line) and §5 (the evidence gate, unchanged).


1. Scope — and the line against design-arwen

Both skills care about the same floor. They are invoked at different moments and they own different halves, and neither restates the other's mechanics.

design-arwena11y-toph
Owns a11y asa gate inside a design task — a constraint on what it is currently buildinga subject in its own right — invoked against code nobody is redesigning
Triggerbuild / redesign / improve / critique an interfaceaudit, compliance question, filed a11y bug, screen-reader report, CI wiring
Surfacethe design it just produced, on the design's terms (states, both themes, the signature)the whole existing surface, whoever wrote it and however long ago
Outputa shipped design that passed its gateranked findings with reproductions, the minimum fixes, re-run evidence
Changeslayout, palette, type, component structure — freelyonly what accessibility requires — never a redesign

Route to arwen, not here: the work is "build/redesign/improve this UI". Its ship gate covers a11y for what it writes. Do not run this skill in front of it.

Route here, not arwen: the ask names accessibility, a standard, an assistive technology, or a user who can't operate something. Also when arwen's gate finds damage wider than the change it made — hand over the failing pairs and stop.

Hand back to arwen the moment a fix needs a design decision: the palette fails contrast at the token level, a state is distinguished by colour alone with no room for a second signal, the fix costs a layout. Report the failing pairs and the constraint; do not repaint a product's brand inside an audit.

Adjacent: audit-sherlock carries a11y as one lane of a whole-codebase sweep — it routes here for depth. web-perf owns measured vitals.


2. The evidence gate

Automated tools are the floor, not the claim. axe/pa11y/Lighthouse catch the machine-checkable minority — roughly a third of real defects, and none of the classes in §3 marked manual. "axe: 0 violations" is one line of a report, never a verdict.

Every finding: file:line + the reproduction (the exact keystroke sequence, the measured number, or the tool output). Every fix: the same reproduction, re-run. Every report ends with what you did not check.

ClaimRequiresNot sufficient
Keyboard accessibleA recorded Tab transcript: every stop, in order, focus visible, nothing trapped, Escape worksThe elements are <button>s now
Contrast passesComputed colours pulled off the rendered element, ratio printed, per stateToken names, a palette, "roughly 3.3:1", eyeballing
Screen reader announces itThe accessibility tree node (role + name + value) or an SR transcriptaria-label is present in the source
Live region announcesWatched it fire once, with the container in the DOM before the messagearia-live="polite" is on the div
Reduced motion honouredEmulated prefers-reduced-motion: reduce, reloaded, content still visibleA @media block exists
Touch targets passMeasured getBoundingClientRect() on every interactive elementThe component library "handles it"
Fix completeThe whole §3 sweep re-run, not just the class you touchedThe reported symptom looks addressed

Fixes break neighbours — re-sweep, always. In this skill's own baseline run, an agent fixing a keyboard bug shrank a help trigger to 18×18px and introduced a touch-target and a dismissible-content failure while reporting the bug resolved.

Rationalizations, from the baseline runs

It saidReality
"Both files look correct."Correct-looking source has never operated a keyboard. Drive it.
"Every control is now reachable via Tab and activates with Enter/Space" — with no browser openThat is a prediction. Tab through it and paste the transcript.
"Quick and cheap given the deadline, I'll skip anything not keyboard-specific"The scope is the sweep in §3. Deadlines shorten the fix list, never the check list.
"It's a disabled control, so contrast isn't strictly required by WCAG"Exempt from the standard, not from the product. Unreadable disabled text is why users retry a dead button. Measure it and report it.
"~3.3:1, borderline, likely fails"Estimating a ratio you could have computed. Print the number.
"Irrelevant once a real <label> is added"You fixed one class by assuming another. Verify both.
"There's no dev server, so I can't check"Then the deliverable is findings marked unverified, not a completion claim. Or start the server.
"The library is accessible"Libraries ship a11y bugs, and integration is where they surface. Measure the rendered DOM.

Red flags — stop and go run something: writing "now accessible", "resolved", "WCAG AA compliant" · a verdict with no numbers in it · a fix report shorter than its reproduction · "should announce" / "should be focusable" · reporting on classes you only read for · skipping the re-sweep because the change was small.


3. The sweep

Run every row. Order matters: static first (cheap, narrows the surface), then the browser passes, then assistive technology. Depth, exact commands, snippets and keystrokes: references/checks.md. Correct implementations for the widgets that fail: references/patterns.md.

#ClassWhat actually goes wrong in generated UICheck
1ReachabilityonClick on a div/span; a control behind hover; a custom widget with no tab stopStatic grep, then Tab from the top and count stops against the interactive elements
2Traps & orderModal without inert, focus that escapes behind the overlay, tabindex > 0, DOM order ≠ visual orderTab and Shift+Tab the whole page; dump the focus order; Escape from every overlay (manual)
3Visible focusoutline: none with no replacement; a ring that vanishes on a coloured surface; hover styled, focus notGrep outline; then focus each element and diff computed styles; measure ring contrast ≥3:1
4Name / role / valueA <div role="button"> with no name; aria-expanded that never updates; a cycling button pretending to be a selectAccessibility-tree dump: every interactive node has role + non-empty name, and value tracks state
5Live regionsContainer injected with the message (announces never); a region wrapping a whole list (announces constantly); alert used for routine statusRegion present at load, aria-live correct, watched firing once (manual)
6Contrast in unscreenshotted statesplaceholder, disabled, hover, visited, error text, text on the accent button, the ring against both surfacesForce each state, pull computed colours, compute ratios with alpha resolved. Numbers or it didn't happen
7MotionNo reduced-motion path; content gated behind a reveal transition ships blank; JS/spring animation ignoring the media query; infinite spinnersEmulate reduce, reload, screenshot; grep for matchMedia/useReducedMotion in JS animation
8FormsPlaceholder as label; error not tied by aria-describedby; aria-invalid missing; colour-only error; focus never moved to the failure; no autocompleteSubmit an invalid form for real: name, description, invalidity, announcement, focus
9Headings & landmarksA styled div acting as a heading; levels skipped; no <main>; several <h1>Dump the heading outline and landmark list; compare against what looks like a heading
10Images & iconsalt restating the filename; decorative image with alt text; icon-only button with no name; SVG with neither title nor aria-hiddenAlt audit: flag alt matching the src basename, empty names on interactive elements
11Target size18–32px icon buttons, table row actions, close buttons, adjacent chips with no spacingMeasure every interactive rect: <44×44 CSS px (or 24 with spacing, WCAG 2.2 AA) is a finding
12Mouse-onlyHover-only tooltips and menus, drag-only reordering, title as the only carrier, custom scroll, gestures with no buttonUnplug the mouse. Complete every task by keyboard (manual)
13Zoom & reflowFixed heights that clip, overflow: hidden on text, two-dimensional scrolling at 400%320 CSS px wide (400% zoom) and 200% text-only: no loss, no horizontal scroll

Then one assistive-technology pass on the primary flow — NVDA + Firefox (Windows) or VoiceOver + Safari (macOS/iOS). The tree dump proves the semantics; only the AT proves it is usable.


4. Fixing

  1. Reproduce first, and write it down. The recorded reproduction is this task's failing test (PRACTICE.md §4). No reproduction, no fix.
  2. Native element before role before ARIA. <button> beats <div role="button" tabindex="0" onKeyDown>. ARIA adds semantics, never behaviour: it will not make a div focusable, clickable by Space, or disableable. Bad ARIA is worse than none.
  3. One class at a time, then re-run its reproduction. A batch of eight simultaneous fixes has no evidence attached to any of them.
  4. Fix the source, not the symptom. Ten components with no focus ring is one token or one base style, not ten patches.
  5. Never fix by removing. aria-hidden on a focusable element, tabindex="-1" to silence a warning, and deleting the failing control all clear the scanner and break the user.
  6. Re-sweep §3 after the fix, not just the class you touched.
  7. Leave a regression guard where the project has tests — jest-axe / @axe-core/playwright on the component, plus an explicit keyboard test for the behaviour that broke. Verify red-green: revert the fix, watch it fail.

5. Report

Ranked by user impact, not by rule number. Severity: blocker (a task cannot be completed by some user) · serious (completable but degraded) · minor (friction). A scanner's own severity is an input, not the answer.

Scope: /reports, /reports/:id · Chrome 141 + axe 4.10 · NVDA 2024.4 not run
Automated: axe 7 violations (3 serious) · pa11y clean · Lighthouse a11y 84

BLOCKER  Filters.jsx:32 — panel toggle is a div, no tab stop.
         Repro: Tab from the search field; focus jumps to Apply, panel unreachable.
BLOCKER  Filters.jsx:61 — validation error never announced; no aria-describedby.
         Repro: submit "ab" with NVDA; silence, focus stays on the button.
SERIOUS  filters.css:9 — .btn:focus{outline:none}, no replacement. All buttons.
         Repro: focused Apply, computed outline "none", box-shadow "none".
SERIOUS  filters.css:11 — disabled label #e8f0f8 on #a8c8e8 = 1.4:1 (measured).
MINOR    Filters.jsx:37 — alt="chevron-down.svg" restates the filename.

Not checked: iOS VoiceOver, Windows High Contrast, the /admin routes (no seed data).

The "not checked" line is mandatory. An audit that hides its gaps is how a green report and a broken product coexist.

Related

  • PRACTICE.md §4-5 — the reproduction-as-test law and the evidence gate
  • references/checks.md — commands, snippets, keystrokes
  • references/patterns.md — the widget contracts
  • skillator:design-arwen — a11y as a gate inside a design task (§1)
  • skillator:audit-sherlock — whole-codebase audit; routes here for a11y depth

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.