Loading...
Loading...
Validate DESIGN.md files against the official Google specification using the `@google/design.md` CLI linter. Works with local files. Use when the user wants to lint a DESIGN.md, check spec compliance, find broken token references, verify WCAG contrast ratios, diff two versions, export tokens to Tailwind or DTCG format, or audit a design system file for structural correctness. Trigger on mentions of "validate DESIGN.md", "lint DESIGN.md", "check my design.md", "design.md spec compliance", "WCAG contrast check", "broken token references", "design token validation", "export design tokens", "diff design systems", "design.md audit", "@google/design.md", "npx design.md lint", "design system validation", "frontmatter tokens", or any request to verify a DESIGN.md file.
npx skill4agent add fabricioctelles/skills design-md-validator@google/design.md| Trigger | Action |
|---|---|
| User has a DESIGN.md file and wants validation | |
| User wants to compare two versions | |
| User wants to export tokens to Tailwind/DTCG | |
| User wants to see the current spec | |
| User shares a URL to a raw DESIGN.md | Download locally first |
| User asks "is my design.md valid?" | |
npx @google/design.mdnpxnpx @google/design.md lint DESIGN.mdfindings[]summary { errors, warnings, infos }npx @google/design.md diff DESIGN.md DESIGN-v2.md012# Tailwind v3 config
npx @google/design.md export --format json-tailwind DESIGN.md
# Tailwind v4 CSS theme
npx @google/design.md export --format css-tailwind DESIGN.md
# W3C Design Tokens (DTCG)
npx @google/design.md export --format dtcg DESIGN.md
# CSS custom properties (optional --prefix)
npx @google/design.md export --format css-vars DESIGN.md
npx @google/design.md export --format css-vars --prefix ds DESIGN.mdcss-varsnpx @google/design.md@0.4.0npxnpx @google/design.md spec
npx @google/design.md spec --rules
npx @google/design.md spec --rules-only --format jsonnpx @google/design.md lint ./DESIGN.mdcat DESIGN.md | npx @google/design.md lint -npx @google/design.md spec --rules-only --format jsonnpx @google/design.md lint --format json DESIGN.md| Severity | Meaning | Action |
|---|---|---|
| Spec violation — file is invalid | Must fix |
| Best practice violation — file is valid but suboptimal | Should fix |
| Informational — suggestions for improvement | Nice to fix |
references/linting-rules.mdreferences/token-schema.md.mddesignmdnpx -p @google/design.md designmd lint DESIGN.mdgoogle-labs-code/stitch-skillsstitch-design-taste| Skill | Plugin | Purpose |
|---|---|---|
| stitch-design | New screens, edits, variants in Stitch |
| stitch-design | DESIGN.md from frontend source |
| stitch-utilities | DESIGN.md from a Stitch project |
| stitch-utilities | Premium / anti-generic DESIGN.md |
npx skills add google-labs-code/stitch-skillsnpxspec --rules-onlyUser: validate my DESIGN.md
Agent:
1. Reads the file
2. Runs: npx @google/design.md spec --rules-only --format json
3. Runs: npx @google/design.md lint --format json DESIGN.md
4. Parses output
5. Reports:
- summary: { errors: 0, warnings: 2, infos: 1 }
- WARNING: contrast-ratio — button textColor on backgroundColor is 3.8:1 (needs 4.5:1)
- WARNING: orphaned-tokens — color "accent-muted" defined but never used
- INFO: token-summary — 5 colors, 3 typography, 2 rounded, 2 spacing
6. Suggests fixes with code
7. Re-runs lint to confirm