Extracts a design system from vibe-coded production apps: inventories components, mines styling into DTCG tokens, scaffolds a Storybook package, and optionally round-trips into Figma. Best for apps without an existing design system.
Ships in figma-console-mcp-skills. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Organizations let small teams vibe-code products with AI. The products work — but there's no design system underneath, so nothing is consistent, reusable, or versionable. This skill runs the extraction engagement: app(s) → component inventory → DTCG tokens → Storybook package → (optionally) Figma.
Two valid stopping points:
figma_import_tokens),
key components become Figma component sets.figma_ds_* tools.
They are deterministic, bounded, and persist manifests under <outDir>/.extraction/ so the
engagement survives session boundaries.analysis.json you write yourself, DTCG
tokens/tokens.json, and the same package layout. For the Figma round-trip use the
figma-import-tokens skill (official Figma MCP use_figma).Establish with the user before scanning:
<first app>/design-system, or a separate dir in
the monorepo.figma_ds_analyze { targets: ["/abs/path/app"], outDir: "/abs/path/app/design-system" }
Review the summary with the user before proceeding — especially the
architecture block, which is what separates a design system from a UI kit:
specializations are usage-named components (FollowButton, ModerationMenu,
NodeCard) — each is really a generic component (Button, Menu, Card) plus a
usage. The usage is what makes it a "follow button"; the component is just a button.missingPrimitives is the build list: generics the app implies but never made.levels is the atomic-design read (atom/molecule/organism/template) — heuristic;
confirm the org's vernacular with the user.Generalization pass (after review, before/during porting): if the
design-systems-assistant MCP is connected, ground decisions in it
(search_design_knowledge for naming conventions, component API design, atomic
hierarchy — it carries the cross-industry best practices). Then:
missingPrimitive as a generic component with a variant/prop API
wide enough to cover its observed specializations.recipes/ tier — never a
sibling primitive. The product keeps its follow button; the SYSTEM ships Button.Primitives/, Components/,
Patterns/) instead of one flat Components/ list.Also review the classic items:
vendored (shadcn-style copied source) and bespoke get ported
as-is; wrapped gets ported keeping the vendor package as a peer dep; pure-vendor (raw
MUI/Chakra usage) is NOT ported — it's represented by theme/tokens and usage docs.skipped in figma_ds_status with a note.topByUsage). Don't port long-tail components nobody
uses without asking.figma_ds_extract_tokens { outDir, formats: [...match the app's styling method...] }
declared tokens (CSS vars, @theme, SCSS vars, tailwind theme, shadcn HSL triples) keep their
names and carry sources provenance. .dark / [data-theme=dark] values become a real
Light/Dark multi-mode structure.inferred tokens are frequency-promoted raw values — review them with the user; the
belowThreshold list is worth a skim for near-misses.Semantic-naming pass (your job, not the tool's): structural names (color/blue/500,
color/extracted/hex-22c55e) are correct but not shippable. With the user's brand context,
layer semantic alias tokens (color/primary → {color.blue.500}) by editing
tokens/tokens.json — add to the Semantic group, reference primitives with {dot.path}
aliases, never delete the primitives. Re-run figma_ds_extract_tokens only if the codebase
changed (it regenerates; hand edits to generated projections are lost, edits to tokens.json are
the input for scaffold).
figma_ds_scaffold { outDir, packageName: "@org/design-system" }
cd <outDir> && npm install && npm create storybook@latest -- --yes --no-dev
figma_ds_setup_storybook { outDir } # AFTER init — wires the workshop to the extraction
figma_ds_setup_storybook generates .storybook/preview.css (extracted tokens + the source
app's @theme mapping, @utility definitions, @layer base, and @font-face rules so production
class names and fonts render faithfully), copies self-hosted fonts, and patches main.js
(tailwind vite plugin + automatic JSX runtime) and preview.jsx (theme toolbar/decorator from
the extracted mode names). Apply any manualSteps it returns, then restart the dev server.
Verify .storybook/main story globs include src/**/*.mdx — the generated
src/docs/*.mdx pages are the token/typography/iconography showcases.
Per component, in usage-rank order:
figma_ds_extract_component { outDir, component: "Button" } — gives source, local import
closure, prop contract, observed call-site variants, style touchpoints, and a CSF3 story
scaffold.<outDir>/src/components/<Name>/ — each component gets its own directory, component
file, stories file, and index (never monolithic files). Decouple app-specific imports
(routing, data fetching, global state); replace hardcoded values with tokens (check
styleTouchpoints.customProperties against tokens.json).tags: ['autodocs'].figma_ds_status { outDir, update: { component, status: "ported", storyFile } }.Long engagements: figma_ds_status { outDir } at session start tells you exactly where you left
off.
Buildable, versioned package: components + tokens + Storybook. Set up whatever
publishing/versioning the org uses (changesets, private registry). The products then consume
@org/design-system instead of their local copies — that migration is a separate engagement.
figma_import_tokens with tokens/tokens.json (top-level groups
become collections; Light/Dark modes come across). Preview with strategy: "dry-run" first.figma_create_component_set, figma_execute) or the figma-generate-library /
prototype-to-figma workflows — bind fills/strokes/radii to the imported variables so Figma
and code share one token source.figma_export_tokens / figma_import_tokens diff-aware merge.figma_ds_* tools are Local Mode only (they read/write the local filesystem).outDir.tokens.css, theme.css, …); edit tokens.json (or
the source app) and regenerate.$extensions["figma-console-mcp.extraction"] on every token — use it to
justify decisions to the user ("this is your primary because it appears 214 times").What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
design-system, storybook, figma, dtcg-tokens, component-inventory, ui-extraction
/figma-console-mcp-skills:figma-extract-design-systemfrom figma-console-mcp-skills
npx claudepluginhub southleft/figma-console-mcp-skills --plugin figma-console-mcp-skills23 skills in this plugin
/figjam-create-contentAuthor FigJam boards with granular control — sticky notes (single + batch), connectors between nodes, shapes-with-text, sections, tables, code blocks, and auto-arrange — plus read back board contents and the connection graph. Use when the user wants to build or edit a FigJam board element-by-element. Triggers: 'add stickies to FigJam', 'create a flowchart/diagram in FigJam', 'connect these nodes', 'make a section/table/code block in FigJam', 'auto-arrange the board', 'read what's on the FigJam board', 'map the connections'. More granular than the native generate_diagram (which produces a whole diagram in one shot). FigJam files only (figma.editorType === 'figjam'). Requires the Figma Desktop app (Plugin API)./figma-analyze-component-setAnalyze a Figma COMPONENT_SET as a state machine for code generation — extract variant axes (state/size/etc.), map state variants to CSS pseudo-classes (hover→:hover, focus→:focus-visible, disabled→:disabled, error→[aria-invalid]), and compute per-variant visual diffs (only what changes per state). Use when generating an interactive component from a Figma variant set — triggers: 'analyze this component set', 'turn these variants into CSS states', 'generate a button/input/checkbox from Figma variants', 'what changes between the hover and default state', 'map Figma variants to component props', 'extract the state machine for this component'. Resolves bound variables to token names. NOT covered by the native MCP's get_design_context/get_metadata, which don't give you a variant-axis→CSS-state machine./figma-annotationsRead and write designer annotations on Figma nodes — node-level design specs that pin properties (fills, width, fontSize, etc.) and carry plain or markdown notes. Use when the user wants to document or inspect interaction specs, animation timings, easing, accessibility requirements, or implementation notes attached directly to a node. Triggers: 'add an annotation', 'annotate this node/component', 'read the annotations on…', 'what specs are pinned to this element', 'list annotation categories', 'document the focus behavior on this button in Figma'. Annotations are distinct from comments (they pin to design properties) and from the description field. Requires the Figma Desktop app (Plugin API)./figma-arrange-component-setOrganize a Figma COMPONENT_SET's variants into a clean, labeled grid — rows and columns derived from the variant properties, with row labels on the left, column headers on top, and a titled white container. Use when a variant set is a messy pile and you want a presentable, documentation-ready layout — triggers: 'arrange my variants in a grid', 'organize this component set', 'lay out the variants with labels', 'make a variant matrix', 'clean up my component set layout', 'add row/column headers to my variants'. Picks the last property (usually State) as columns and the rest as rows by default. NOT something the native MCP's read-only tools do — this writes a new organized layout to the canvas./figma-audit-accessibilityDeep accessibility scorecard for a single Figma component or component set — state coverage (default/hover/focus/disabled/error/active/loading), focus-indicator quality and contrast, non-color state differentiation, target size, annotation completeness, and color-blind simulation (protanopia/deuteranopia/tritanopia), all rolled into per-category 0–100 scores and prioritized recommendations. Use when the user wants to vet ONE component before shipping it: triggers 'audit this component', 'accessibility score for this button', 'is this component set accessible', 'check the states on this component', 'does my button have a focus state', 'color blind check', 'rate this component for a11y', 'component accessibility scorecard'. Works on ANY Figma plan. For a broad sweep over a whole page/frame use figma-lint-design; for CODE-side (HTML) checks use figma-scan-code-accessibility./figma-blame-nodeFind which Figma version introduced a specific change — a component property or a child node — via a binary search over version history (~log2(N) API calls instead of N). Answers 'who added this and when'. Use when the user wants git-blame-style attribution for a Figma design — triggers: 'when was this component property added', 'which version introduced this variant', 'who added this node', 'blame this Figma element', 'find when this was created', 'git blame for Figma', 'when did this property first appear'. Uses the Figma REST API + a personal access token because version history is NOT reachable via the Plugin API / use_figma / the native Figma MCP. For a full diff between two versions use figma-version-history; for prose release notes use figma-generate-changelog.Other plugins' skills for the same job