product-ui-audit

Audits consumer UI code against design system usage rules across seven dimensions.

5|9|Updated Mar 25, 2026
One-click install
npx skills add https://github.com/ajenchen/design-system --skill product-ui-audit-ajenchen
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: product-ui-audit
Source: https://github.com/ajenchen/design-system/tree/main/.agents/skills/product-ui-audit
Command: npx skills add https://github.com/ajenchen/design-system --skill product-ui-audit-ajenchen

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Consumer UI code often drifts from the design system: hardcoded hex colors, misused components, missing aria-labels, and re-implemented layout primitives. This Skill systematically audits product UI code (not the design system itself) to catch token leaks, component misuse, geometry bugs, and accessibility gaps before they reach stakeholders. ## Core Features & Use Cases - 7-Dimension Audit: Checks token hygiene, layout primitive consumption, component correctness, mindset adherence, visual geometry, accessibility, and design principle compliance, each with concrete grep patterns and severity rules. - Severity-Triaged Reports: Classifies findings as P0 (must-fix bugs), P1 (batch fixes), P2E (autonomous engineering fixes), or P2H (product decisions requiring user input), with a structured report template. - Visual Audit Gate: Adds a stakeholder-facing visual layer (WCAG contrast, DOM geometry assertions, screenshot review) on top of the code-level audit. - Use Case: Before merging a new checkout feature, run the audit on src/app/features/checkout/ to catch a hardcoded #3b82f6, an icon-only Button missing aria-label, and a hand-rolled empty state that should use the <Empty> component. ## Quick Start Ask the AI to audit a specific UI folder, for example: audit src/app/features/checkout for design system usage violations.

Frequently Asked Questions about product-ui-audit

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I audit UI code for design system violations?▼

Invoke the audit on a target path such as a feature folder under src/app or src/explorations. It runs seven independent dimension checks covering tokens, layout primitives, components, mindset, geometry, accessibility, and design principles, then produces a severity-triaged findings report.

What is the difference between product-ui-audit and design-system-audit?▼

product-ui-audit checks consumer UI code that uses the design system, such as app and feature code. design-system-audit checks the design system package itself, including spec, cva, and token source-of-truth drift. They have separate scopes and should not be substituted for each other.

What kinds of violations does the token hygiene check catch?▼

It flags hardcoded hex, rgb, and hsl color values, shadcn compatibility aliases like bg-popover or text-muted-foreground, Tailwind default shadows such as shadow-sm, Tailwind v4 [--foo] shorthand that silently fails, and hardcoded pixel values where tokens exist.

Does the audit fix the issues it finds automatically?▼

P0 and P1 findings plus P2E engineering issues are fixed autonomously in per-dimension change sets, then verified with type checks and a re-run of the audit. Only P2H findings, which involve genuine product or UX tradeoffs, are escalated for a user decision.

When should I not use this UI audit?▼

Do not use it to audit the design system package itself, to validate business logic correctness, or as a replacement for final code review. It is a pre-review self-check focused on UI, design system consumption, and design principles.

Why does the audit include a visual inspection phase?▼

Code-level checks can pass while the rendered UI still has contrast failures, overlapping overlays, or cross-OS scrollbar issues. The visual phase runs WCAG contrast checks, DOM geometry assertions, and screenshot review before stakeholder-visible work ships.