Using Claude Code and an automated accessibility checker to build WCAG-tested website components

1 comment

Apps it uses

I built a workflow that turns my brand's colors and fonts into website building blocks that people using screen readers, keyboards, larger text, or high contrast can use with ease. AI does the building, and an automated checker decides whether the work ships. It's for anyone who wants accessibility verified by a tool instead of taken on the AI's word.

  1. Before anything is built, Claude writes a short brief: what we're adding, what already exists, what counts as done, and the accessibility rules each piece must follow.
  2. Claude Code builds from the brief, the way a contractor builds from blueprints. It created menus, tabs, pop-up windows, notifications and a full dark mode this way.
  3. Automated checks run every time Claude finishes something, before I look at it. They test text contrast against WCAG, keyboard-only use, spoken labels on icon-only buttons, tap target size, text scaling when zoomed, whether meaning is conveyed by more than color, and whether reduced-motion settings are respected. If anything fails, the work is blocked. It can’t be added to the tool, so nobody gets it, not me and not anyone who downloads the tool. Claude gets a report showing exactly what failed and why (“this gray text is 3.2 to 1, it needs 4.5 to 1”). It fixes the problem and submits again, and the checks run again from scratch. Only work that passes every check gets in. There’s no override button, not even for me.
  4. I make the final call on whether it looks and feels right, since the accessibility checks have already passed.
  5. Claude reads what was actually built and writes a guide for each piece, including how it works with assistive technology. It's told to describe only what's really there.

The moment that stood out: Claude flagged that my tool only guaranteed color contrast, while a build could still have tiny buttons, text that wouldn't enlarge, or color-only warnings. That update closed those gaps.

The result is a free, open-source tool. Give it your brand's colors and fonts and it produces 18 ready-to-use building blocks, each accessibility-checked and shown in a live showroom with instructions.

🎨 See every piece live: https://main--6a5fc3291d6b2fa47f0cdd53.chromatic.com/ 🔗 The project: https://github.com/benmcosker/design-system-generator 📦 For developers, install it from npm: https://www.npmjs.com/package/@benjaminmcosker/design-system-generator

1 comment

Have a question about this workflow, or a way to improve it?

Log in to comment Create a free account
Brooke Benson Pro The Rundown team

the “no override button, not even for me” rule is the part i keep thinking about. most people let the ai say it’s accessible and move on, and you made a checker the gatekeeper instead. love that claude gets the exact failure back with the contrast numbers and has to resubmit from scratch. and claude being the one to point out that contrast alone wasn’t enough is such a good moment. how did that come up, were you asking it to audit the tool or did it flag it on its own? also curious how many rounds a typical component takes before it passes everything, and whether there’s one check claude keeps tripping on.

Posting guidelines