
Design System
Reverse-engineer colours, typography, components, spacing, and atmosphere from a live site or file into a semantic DESIGN.md for consistent page generation.
Overview
Design System is an agent skill most often used in Build (also Validate prototype, Launch seo) that analyses an existing site or screenshot and synthesises a DESIGN.md design system for consistent UI generation.
Install
npx skills add https://github.com/jezweb/claude-skills --skill design-systemWhat is this skill?
- Produces semantic DESIGN.md optimised for design-loop and page generation
- Supports live URL (Playwright/scraper), local HTML, and screenshot sources
- Analyses colours, typography, component styles, spacing, and atmosphere
- Workflow table: source identification then browser/HTML inspection
- Triggers include extract design system, create DESIGN.md, reverse engineer the design
Adoption & trust: 623 installs on skills.sh; 841 GitHub stars; 1/3 security scanners passed (skills.sh audits).
What problem does it solve?
You need to ship pages that match an existing brand but only have a URL or mock—no written tokens, type scale, or component rules.
Who is it for?
Solo builders starting a frontend from a reference site, client re-skin, or Stitch export who want documented tokens before iterative page work.
Skip if: Greenfield brands with no reference, backend-only APIs, or agents without Claude Code browser/file tooling.
When should I use this skill?
User asks to extract design system, create DESIGN.md, analyse the design, extract styles from a site, or reverse engineer visual design.
What do I get? / Deliverables
You get a DESIGN.md with semantic colours, typography, components, spacing, and atmosphere ready for design-loop or further frontend builds.
- DESIGN.md semantic design system
- Documented colour/type/component/spacing tokens
- Source method notes (URL vs file vs screenshot)
Recommended Skills
Journey fit
Spans multiple journey phases - primary shelf plus alternate fits below.
Design extraction happens when you are building UI fidelity, so build/frontend is the canonical shelf even when sourced from a client URL during validate. Output targets frontend generation and design-loop consumption—not backend APIs—so frontend is the right subphase.
Where it fits
Capture a competitor or inspiration URL into DESIGN.md to judge whether the visual direction is worth building.
Generate DESIGN.md from client HTML before implementing new pages with matching components.
Document informal site styling for a multi-page project the whole agent stack can reference.
Align new landing templates with an existing marketing site's chrome for consistent crawlable pages.
How it compares
Use for extracting and documenting visual language—not for running A/B analytics or automated visual regression testing.
Common Questions / FAQ
Who is design-system for?
Indie builders and small teams using Claude Code who need DESIGN.md from a live site, HTML file, or screenshot before building or looping on UI.
When should I use design-system?
In build/frontend when cloning or extending a UI; in validate/prototype when proving visual fit from a reference URL; in launch when documenting site chrome for content pages—whenever triggers like extract design system or create DESIGN.md apply.
Is design-system safe to install?
It uses Read/Write and may browse URLs via Bash; review Security Audits on this page and avoid pointing it at sites or files with secrets you do not want in the repo.
SKILL.md
READMESKILL.md - Design System
# Design System Extractor Analyse an existing website, HTML file, or screenshot and synthesise a semantic design system into a `DESIGN.md` file. The output is optimised for use with the `design-loop` skill and general page generation. ## When to Use - Starting a new project based on an existing site's visual language - Documenting a site's design system that was never formally written down - Preparing `.design/DESIGN.md` before running the design loop - Extracting brand guidelines from a client's existing website - Creating consistency documentation for a multi-page project - Extracting design tokens from a Google Stitch project ## Workflow ### Step 1: Identify the Source Ask the user for one of: | Source | Method | |--------|--------| | **Live URL** | Browse via Playwright CLI or scraper, screenshot + extract HTML | | **Local HTML file** | Read the file directly | | **Screenshot image** | Analyse visually (limited — no exact hex extraction) | | **Existing project** | Scan `site/public/` for HTML files to analyse | | **Stitch project** | Use `@google/stitch-sdk` to fetch screen HTML + design theme | ### Step 2: Extract Raw Design Data #### From a Live URL 1. **Browse the site** using Playwright CLI: ``` playwright-cli -s=design open {url} playwright-cli -s=design screenshot --filename=.design/screenshots/source-desktop.png ``` 2. **Extract the full HTML** — either via scraper MCP or by reading the page source 3. **Resize and screenshot mobile** (375px): ``` playwright-cli -s=design resize 375 812 playwright-cli -s=design screenshot --filename=.design/screenshots/source-mobile.png ``` 4. Close the session: `playwright-cli -s=design close` #### From a Local HTML File Read the file directly and extract design tokens from the source. #### From a Screenshot Only Analyse the image visually. Note: colour extraction will be approximate without HTML source. Flag this limitation in the output. #### From a Google Stitch Project If `@google/stitch-sdk` is installed and `STITCH_API_KEY` is set: ```typescript import { stitch } from "@google/stitch-sdk"; // List projects to find the target const projects = await stitch.projects(); // Get project details (includes designTheme) const project = stitch.project(projectId); const screens = await project.screens(); // Get HTML from the main screen const screen = screens[0]; // or find by title const htmlUrl = await screen.getHtml(); const imageUrl = await screen.getImage(); ``` The Stitch `designTheme` object provides structured tokens directly: ```json { "colorMode": "DARK", "font": "INTER", "roundness": "ROUND_EIGHT", "customColor": "#40baf7", "saturation": 3 } ``` Map these to DESIGN.md sections: - `colorMode` → Theme (Light/Dark) - `font` → Typography font family - `roundness` → Component border-radius (`ROUND_EIGHT` = 8px, `ROUND_SIXTEEN` = 16px, etc.) - `customColor` → Primary brand colour - `saturation` → Colour vibrancy (1-5 scale) Then also download and analyse the HTML for the full palette (Stitch's theme object only has the primary colour — the full palette is in the generated CSS). ### Step 3: Analyse Design Tokens Extract these from the HTML/CSS source: #### Colours Look in these locations (priority order): 1. **CSS custom properties** — `:root { --primary: #hex; }` or `@theme` blocks 2. **Tailwind config