extract
Pull a draft DESIGN.md from any production URL.
Synopsis
design-md extract <url> [-o <path>] [--token-only]
Submits a URL for extraction and opens the web-based creation flow in your browser. The extraction process uses Playwright to sample the production site’s CSS (colors, fonts, radii, spacing, components) and synthesizes a draft DESIGN.md file.
Options
| Flag | Short | Argument | Default | Description |
|---|---|---|---|---|
--out | -o | <path> | ./<slug>.draft | Output path for the extracted DESIGN.md file (optional; most users will set this in the web UI). |
--token-only | — | — | false | Extract only the token frontmatter (colors, typography, spacing, radii) without prose sections. Useful for design systems with publicly documented CSS variables. |
What gets extracted
Playwright navigates to the production URL and samples the DOM to identify:
- Colors:
background,text,brand,border,surfaceroles (via computed styles on headings, buttons, text elements) - Typography:
bodyandheadingroles with family, size, weight, and line-height from sampled elements - Spacing: gutters, padding scale inferred from button/card layouts
- Radii: border-radius values sampled from buttons, cards, and form inputs
- Components: structure and states (primary buttons, secondary buttons, inputs, cards) via DOM traversal
The output is a skeleton DESIGN.md with:
- Frontmatter populated from sampled CSS
- 15 markdown sections containing
[TODO]placeholders for prose (visual theme, color palette, typography rules, components, accessibility, etc.) quality: autoflag indicating the entry requires hand-review and curation
Examples
Extract from a retail site with full prose sections:
design-md extract https://www.wayfair.com
Extract from a design system that ships CSS variables — tokens only:
design-md extract https://www.stripe.com --token-only
Specify an output path:
design-md extract https://www.pinterest.com -o ./brands/pinterest.draft.md
Output
The extract command:
- Logs the target URL and opens a browser to the webdesignhot creation flow:
https://webdesignhot.com/design-md/create?url=<encoded-url> - Writes a
.draftfile to disk (path specified via-oor defaulting to./<slug>.draft) - The draft file contains frontmatter and skeleton prose ready for curation
Example output structure:
site/src/content/designs/
└── wayfair.draft.md
# Contents:
---
name: Wayfair
tagline: "The Way Home"
colors:
bg: '#ffffff'
text: '#1a1a1a'
brand: '#b5956d'
# ... sampled from production
---
# Wayfair
[TODO: Visual Theme & Atmosphere — describe the overall mood and grid-based composition.]
## 1. Visual Theme & Atmosphere
[TODO]
...
Important — drafts are not catalog entries
Related
init— initialize a new design system from scratchsubmit— publish a DESIGN.md to the webdesignhot catalog- Runbook: Add a brand to the catalog — step-by-step workflow