Design check

From xoai/sage · View interactive version

Design check is an AI agent skill from the GitHub repository xoai/sage. Quick design quality scan of changed frontend files. Checks for hardcoded colors (when design system exists), missing interactive states, and AI slop indicators. Code-only — does not use Lightpanda. Advisory only — never blocks. Invisible when no frontend files in diff.

How to use this skill

Skill file

<!-- sage-metadata

cost-tier: sonnet

activation: auto

tags: [verification, design, quality, frontend]

inputs: [diff]

outputs: [pass-warnings]

requires: []

-->

Design Check (Light Mode)

Quick scan within quality-gates. Catches common design quality issues

in changed frontend files. Code-only — does not require a browser.

Availability Check

FIRST: Check if the diff contains frontend files:

.html, .css, .scss, .less, .jsx, .tsx, .vue, .svelte, .astro

If NO frontend files in diff:

Design System Detection

Scan in order (stop at first match):

  1. Design system skill in sage/skills/ or .claude/skills/
  2. DESIGN.md or design-system.md in project root or .sage/docs/
  3. CSS custom properties pattern (--color-*, --spacing-*, --font-*)

If found → enable token compliance checks.

If not found → skip token checks, still run general quality checks.

Detection is automatic and INVISIBLE — do not announce whether a

design system was found. Just use it (or don't) silently.

What It Checks (15 seconds max)

1. Hardcoded colors (when design system detected)

Scan changed files for raw hex colors (#fff, #333, rgb(), hsl())

that should be design system token references.

Finding: note — "N hardcoded colors in [file] (consider using tokens)"

2. Missing interactive states

Search changed component files for:

Finding: note — "[file] has no :focus style on [element]"

3. AI slop indicators

In new or heavily modified components, check for:

Each indicator: warning (awareness, not judgment)

Report

If findings exist:

✓ Design check: PASS ({N} notes)
  - Note: {finding 1}
  - Note: {finding 2}
  - Warning: {AI slop indicator}

If clean:

✓ Design check: PASS

If no frontend files:

No output. Invisible.

Enforcement

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.