design-systems
Skill0 starsChanged 44 days agoMITView on GitHub
Use when creating, cleaning up, or extending a design system. That includes design tokens, theming (light/dark, brands, density, contrast), component APIs and variants, DESIGN.md, a component library, or syncing tokens to iOS and Android. Covers the W3C DTCG 2025.10 token format and resolver, primitive → semantic → component tiers and naming, Tailwind v4 @theme, shadcn-style semantic color pairs, CSS variable theming, component variant and prop rules, authoring and linting DESIGN.md (Google spec), the component and required-state checklist, Style Dictionary-style multi-platform pipelines, governance, and building a system from zero (tier choice, interface inventory, component lifecycle, adoption). Also use when the user only says "set up tokens", "our colors are all over the place", "add dark mode properly", "write a DESIGN.md", "make a component library", or "keep web and app styles in sync". Not for choosing the visual direction (use design-taste) or deciding the values themselves (use design-foundations).
19 other projects use a version of this.
Adopted by
Most recently taken up by
- ldaume/agentic-engineering-harnesstheir own version, first seen Nov 8, 2026
- naman10parikh/pennytheir own version, first seen Nov 8, 2026
- hamzzaqureshi/gravidextheir own version, first seen Nov 8, 2026
- AxlZero21/Skillstheir own version, first seen Nov 8, 2026
- memi-design/design-skillstheir own version, first seen Nov 8, 2026
- reddygopalkrishna/developer-agent-skillstheir own version, first seen Nov 8, 2026
Used with
Projects with it also use ecosystem-reference, fractal-delegation and 10 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
naman10parikhSkillecosystem-reference
Quick-access directory of Claude Code ecosystem repos, skills, plugins, MCPs, and patterns. Use when improving the harness.
Also in 5 projects that use this
naman10parikhSkillfractal-delegation
Also in 5 projects that use this
KirchliveSkillskill-routing
Decides which of the installed skills a task needs and loads them before the work starts. This skill should be used at the beginning of any multi-step task — build, fix, refactor, migrate, review, plan, release, research, write, design, video — and again at every phase change, after context compaction, and when work moves into a different part of the codebase. Use it for requests like "let's build X", "fix this bug", "refactor Y", "plan the migration", "review this", and also when the user asks which skill applies, why a skill did not fire, or asks to check what is available.
Also in 5 projects that use this
sublimotionSkillagent-runtime
Launch and manage detached agent runs on EKS via the agent-runner CLI. Use when the user says "launch an agent run", "agent runtime", "agent-runner", "run this spec on the cluster", "check run status", "agent run logs", or "stop a run". Do NOT use for writing the agent-runner code itself (edit the sibling ../agent-runner repo), Terraform of the foundation (use terraform-automation), or GPU serving deployments (use infra-deployer).
Also in 5 projects that use this
GoZippySkillrepo-scout
Also in 5 projects that use this
BenjaminGSkillharness-review
Turn one PR's review comments into harness fixes — classify each cause by the most solid place it can live (codebase, lint, rules, skill), then draft the fixes in a separate PR.
Also in 5 projects that use this
- +6 more from naman10parikh
Other versions19 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 19
- Mindrally/skills★ 275same name
- cuellarfr/design-skills★ 94same name
- nahid-sparktales/agent-dispatcher★ 59same name
- nimadorostkar/Claude-Skills-collection★ 33same name
- codetesla51/skills★ 32same name
- naman10parikh/agentgrid★ 9same name
- naman10parikh/wikimem★ 8same name
- reddygopalkrishna/developer-agent-skills★ 8same name
- memi-design/design-skills★ 7same name
- botirkhaltaev/botir-skills★ 4same name
9 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository45 other files it gives its agents.
- AGENTS.mdAGENTS.md
- accessibilitySkill
- ai-interface-designSkill
- ai-native-architectureSkill
- android-designSkill
- api-designSkill
- application-securitySkill
- app-screen-patternsSkill
- auth-flowsSkill
- clean-codeSkill
- codebase-organizationSkill
- code-reviewSkill
- conversion-uxSkill
- dashboard-designSkill
- data-dense-uiSkill
- data-infrastructureSkill
- data-modelingSkill
- dependency-managementSkill
- deployment-and-infrastructureSkill
- design-foundationsSkill
- design-patternsSkill
- design-resourcesSkill
- design-reviewSkill
- design-tasteSkill
- environments-and-configSkill
- frontend-architectureSkill
- how-to-build-softwareSkill
- interaction-designSkill
- ios-designSkill
- lessons-from-failuresSkill
- mobile-architectureSkill
- mobile-designSkill
- motion-designSkill
- object-oriented-designSkill
- onboarding-designSkill
- project-bootstrapSkill
- project-contextSkill
- reliabilitySkill
- scalabilitySkill
- software-architectureSkill
- system-designSkill
- tech-stack-selectionSkill
- testing-strategySkill
- ux-principlesSkill
- web-platformSkill
The file
We split this skill into the rules it gives an agent
5 rules. 0 are common, 3 are distinctive, and 2 are very specific to this project.
0
Common
Most of the 18 edited versions we read keep these.
3
Distinctive
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 25
Name by role, not by value: Use color.danger.fg, not red-600.
- Distinctive: line 28
Every component ships every state: Default, hover, focus-visible, active, disabled, loading, error, and empty where relevant, plus RTL and …
- Distinctive: line 140
Keep Do's and Don'ts short and intentional (5–10).
- Very specific: line 155
Old DTCG draft syntax: Before 2025.10, dimensions and colors were strings ("16px", "#fff").
- Distinctive: line 160
Dark mode as a second palette of raw values: instead of a mode of the same semantic names.
“Common” is measured: kept by at least 6 in 10 of the 18 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Design Systems
A design system is a set of decisions made once and enforced everywhere: tokens for values, components for behavior, and documentation that says why. It fails in three ways. Raw values leak into components, so a rebrand touches 400 files. There are so many tiers and variants that nobody knows which token to use. Or the documentation says one thing and the code does another. This skill sets up the smallest system that removes those failures and grows with the product. It keeps one source of truth, generates everything else from it, and makes the system readable to people and to agents through DESIGN.md.
Before you start
If .agents/project-context.md exists (or .claude/project-context.md), read it first and treat it as ground truth for stack, platforms, scale, design system, and constraints. Only ask for what it does not cover. If it does not exist and the task is larger than a quick fix, suggest running the project-context skill — but never block on it.
Then find what already exists: DESIGN.md, *.tokens.json, a Tailwind @theme block, :root variables, a Figma variables export, a component library, Storybook. Extend what exists. Never start a parallel system.
Core principles
- One source of truth, everything else generated. Hand-maintained duplicates drift within weeks.
- Components consume semantic tokens only. Primitives never appear in component code. That rule is what makes theming a single remap.
- Name by role, not by value. Use
color.danger.fg, notred-600. Useradius.control, notradius-6. Values change; roles don't. - Few tiers, few tokens. Primitive → semantic is mandatory. Add component tokens only where a component truly diverges.
- Themes remap the semantic tier. Light, dark, brand, density, and contrast are modes over the same names, never forks.
- Every component ships every state. Default, hover, focus-visible, active, disabled, loading, error, and empty where relevant, plus RTL and both themes.
- The system is a product. Version it, keep a changelog, deprecate before deleting, and measure adoption.
Workflow
- No system yet, or one nobody uses? Choose the tier first (table below) and follow
references/build-from-zero.mdfor the inventory, order of work, and lifecycle. Don't build a tier-3 system for one app. - Audit: list every color, size, radius, shadow, font, and z-index value in the code, and count the duplicates and near-duplicates. List components and their variants. Output: an inventory table and a merge plan (for example "23 greys → 12-step neutral ramp").
- Decide the source of truth (table below) and the file layout.
- Primitives: ramps, spacing, type, radius, shadows, durations, and easings, with values from
design-foundations. - Semantic tier: role names mapped to primitives for each mode (light and dark at minimum). Check contrast for every text/surface pair.
- Wire it up: CSS variables and Tailwind
@theme(web), generated platform files (native). Replace raw values in components. A lint rule blocks new raw hex or px values. - Components: apply the API rules below. Check each one against
references/component-checklist.md. - Document: write or update
DESIGN.md(Google spec order) fromassets/DESIGN.template.md. Validate withnpx @google/design.md lint DESIGN.md. - Govern: add a version, a changelog, a deprecation policy, and visual regression on the component catalog.
- Verify: switch themes and nothing breaks;
grepfinds no raw colors in components; lint passes; the visual diff shows only intended changes.
How much system you need
| Tier | What | Enough when |
| 0 — Adopt | An existing system as-is (shadcn/ui defaults, Polaris for Shopify apps, Primer for GitHub apps) | Prototypes, internal tools, apps inside a host platform |
| 1 — Own the basics | DESIGN.md + semantic tokens + a copied component library (shadcn/ui or similar) | Default for startups and single-product teams |
| 2 — Shared patterns | Tier 1 + documented patterns published as reusable blocks (e.g. a private shadcn registry) | Several apps or repos, or agents generating UI across repos |
| 3 — System as a product | Versioned packages, docs site, Figma linked to code, lifecycle labels, contribution process, adoption metrics, owners | Several product teams or platforms with a consistency mandate |
Move up only on evidence: duplicated components in the inventory, teams rebuilding the same pattern, recurring accessibility bugs in the same widget, Figma and code disagreeing. Process for each tier: references/build-from-zero.md.
Source of truth
| Situation | Source of truth | Generated from it |
| Web only, one app, Tailwind | CSS file with :root variables + @theme inline | DESIGN.md front matter (or check it with design.md diff) |
| Web + iOS/Android, or several apps and brands | DTCG *.tokens.json + a resolver file for modes | CSS, Tailwind theme, Swift, Kotlin/Compose, DESIGN.md tokens |
| Design team works in Figma variables | DTCG JSON exported from Figma and committed to the repo; the repo is canonical | Everything else |
| Bootstrapping from an existing DESIGN.md | DESIGN.md → npx @google/design.md export --format dtcg once, then DTCG | CSS, native |
DESIGN.md is always present as the agent-readable summary and rationale. Its front matter covers only colors, typography, rounded, spacing, and components, so it cannot be the only source of truth for shadows, motion, breakpoints, or z-index.
Token tiers and naming
| Tier | Example | Rules |
| Primitive (reference, global) | color.orange.9, gray.1…12, space.4 = 16px, radius.2, duration.200 | Raw scales with no meaning. Never used directly by components |
| Semantic (system, alias) | color.bg, color.fg.muted, color.accent, color.border.subtle, color.danger.fg, space.inset.card, radius.control, motion.duration.fast | Intent. Themes remap this tier only |
| Component (optional) | button.primary.bg → {color.accent}, input.border.focus | Only where a component diverges from the semantic default. Keep it to a handful |
- Naming pattern:
category.property.variant.state(for examplecolor.bg.surface.hover). In CSS this becomes kebab-case:--color-bg-surface-hover. - Cover more than color: typography composites, spacing, sizing (control heights 32/36/40/44), radius, border width, shadow/elevation, z-index layers (base, dropdown, sticky, overlay, modal, toast, tooltip), durations, easings, breakpoints, and opacity.
- Status roles come as sets:
success|warning|danger|info×fg,bg(subtle),border,solid. - Record why with
$description, and mark retirement with$deprecated(a string that names the replacement).
Formats in one screen
DTCG 2025.10 (stable since 2025-10-28): $value, $type, $description, $deprecated, and $extensions. Dimensions and colors are objects. Aliases use curly braces.
{
"$schema": "https://www.designtokens.org/schemas/2025.10/format.json",
"color": {
"$type": "color",
"orange": { "9": { "$value": { "colorSpace": "oklch", "components": [0.62, 0.17, 40], "hex": "#dc6a31" } } },
"accent": { "$value": "{color.orange.9}", "$description": "Primary action background" }
},
"space": { "$type": "dimension", "4": { "$value": { "value": 16, "unit": "px" } } }
}CSS theming with semantic variables (web):
@layer tokens {
:root {
color-scheme: light dark;
--color-bg: light-dark(var(--gray-1), var(--gray-dark-1));
--color-fg: light-dark(var(--gray-12), var(--gray-dark-12));
--color-accent: light-dark(var(--orange-9), var(--orange-dark-9));
--radius-control: 6px; --radius-card: 12px;
}
[data-theme="light"] { color-scheme: light; }
[data-theme="dark"] { color-scheme: dark; }
}Tailwind v4 exposes tokens as utilities through @theme (use @theme inline when values reference other variables). shadcn uses background/foreground pairs. Full formats, the resolver for modes, and the Tailwind/shadcn wiring are in references/tokens-dtcg.md and references/tailwind-shadcn.md.
Theming and modes
- Modes are axes:
theme(light/dark),contrast(standard/high),brand,density(compact/comfortable), and optionallymotion(full/reduced). Each mode swaps semantic values only. - In DTCG, express modes with a resolver document:
setsfor the base files,modifierswithcontextsper mode, andresolutionOrder. The number of outputs is the product of all contexts. Keep the axes few. - On the web, set the mode with an attribute on
<html>(data-theme,data-density), and uselight-dark()for color pairs. Respectprefers-color-scheme, persist the user's override, and disable transitions while switching. - Density changes spacing and control-height tokens, never font size below the floors.
- A high-contrast mode raises
fg-muted→fg, strengthens borders one or two steps, and thickens focus rings.
Component API rules
- Variants express intent, such as
variant: primary | secondary | ghost | destructive. Size is a separate axis (sm | md | lg). State is not a variant:disabled,loading,invalid, andselectedare booleans, and hover and focus live in CSS. - Props are named by purpose:
tone="danger", notcolor="red". Don't expose raw style props (bgColor,borderRadius). - Compose rather than configure: slots and subcomponents (
Card,Card.Header,Card.Footer), or a render orasChildprop for polymorphism. More than about 10 styling props means the component should be split. - Keep native semantics: forward refs, spread native attributes,
type="button"by default, links as<a>. Build overlays, menus, comboboxes, and dialogs on accessible primitives (Base UI, React Aria, Radix). Don't mix primitive systems within one surface. - Controlled and uncontrolled:
value/defaultValue/onValueChange(or the platform's equivalent). - Layout belongs to the parent: components carry no outer margin. Accept
className/stylefor placement, not for restyling internals. - Loading keeps size: the spinner replaces or accompanies the label without changing the width. Use
aria-disabledwhen the control must stay focusable. - Implement variants with a variant helper (for example
cvaortailwind-variants) that maps to tokens, never to raw values.
The full component list with the states each must ship is in references/component-checklist.md.
DESIGN.md
The file sits at the repo root and follows Google's DESIGN.md spec (alpha): YAML front matter tokens followed by ## sections in this order: Overview → Colors → Typography → Layout → Elevation & Depth → Shapes → Components → Do's and Don'ts. Rules:
- The tokens are normative, and the prose explains how to apply them. A specific reference beats adjectives. "A 1970s university lecture handout" describes a point; "modern, clean, premium" describes a region.
colors.primarymust exist. Component variants are sibling keys (button-primary,button-primary-hover). References look like"{colors.primary}".- In repo mode, invent no tokens. Every value traces to code, and accidental repetition is not design intent. Each sentence should change an implementation decision.
- Keep Do's and Don'ts short and intentional (5–10).
- Validate with
npx @google/design.md lint DESIGN.md(broken refs, missing primary, WCAG contrast of component pairs, section order). Export withexport --format css-tailwind | dtcg.
Authoring procedure and lint rules: references/design-md.md. Template: assets/DESIGN.template.md.
Multi-platform and governance (summary)
- Pipeline: DTCG JSON → a build tool that reads DTCG (Style Dictionary v4+, Terrazzo) → CSS/Tailwind, Swift, Kotlin/Compose, and Android resources. Unit transforms turn px into pt, dp, and sp. Colors convert from OKLCH to sRGB or P3 hex for native. Native type maps to platform text styles (Dynamic Type, Material roles) rather than copying web sizes. Details:
references/multi-platform.md. - Versioning: semver for the token and component packages. A rename or removal is major, a new token or component is minor, and a value tweak is patch, but a visible change to a widely used semantic value gets a changelog entry and a visual diff whatever its level. Deprecate with
$deprecatedand alias for one major version before deleting. Details:references/governance.md.
Gotchas
- Components using primitives (
bg-orange-500,--gray-12). Dark mode then needs per-component overrides. Route everything through semantic roles. - Tokens named by value (
--blue,--spacing-16px). The first rebrand turns--blueorange. Name by role. - Token explosion. 600 component tokens that each alias one semantic token add maintenance and help nobody. Start with primitives plus about 40–80 semantic tokens.
- Old DTCG draft syntax. Before 2025.10, dimensions and colors were strings (
"16px","#fff"). 2025.10 uses objects. Check that your build tool's version supports what you write. - Tailwind v4
@themereferencing variables withoutinline.var()resolves at the definition site and can fall back unexpectedly. Use@theme inlinefor aliases. - Shipping shadcn defaults. The achromatic default theme is the recognizable "shadcn look". Set
--primary,--radius, fonts, and chart colors from the direction. - DESIGN.md out of sync with code, or written as aspirations. Generate or diff its tokens from the source of truth, and lint it in CI.
- Brand DESIGN.md copied from a gallery. It is useful as a reference, but copying another company's system is impersonation-adjacent and still generic. Take the principles, not the palette.
- Dark mode as a second palette of raw values instead of a mode of the same semantic names.
- Missing non-color tokens. Hard-coded z-indexes, durations, and breakpoints drift first.
- Variants for one-offs.
variant="homepage-hero-blue"belongs in the page, not in the system. - Web type sizes forced onto native. iOS and Android users expect Dynamic Type and
spscaling. Map to platform roles. - Building a big system for a small product. A docs site, Figma library, and contribution process for one app with three developers is overhead nobody maintains. Start at tier 1 and move up on evidence.
- Designing the system in isolation. A system built without an inventory of real screens gets ignored. Extract from what exists and build with product teams.
- Breaking changes without notice. Renaming a token in a patch release breaks consumers silently. Follow the deprecation policy.
Output format
For setup or cleanup work, deliver:
Inventory: <n> colors → <m>; <n> font sizes → <m>; radii <…>; shadows <…> (merge plan)
Source of truth: <file(s)>; generated: <outputs>
Tiers: primitives <count>, semantic <count>, component <count> (list any component tokens with reason)
Modes: <theme/contrast/brand/density> via <mechanism>
Components: <list> with state coverage (✓/✗ per state)
DESIGN.md: written/updated; lint result <pass / findings>
Governance: version <x.y.z>, changelog entry, deprecations
Verified: theme switch, no raw values in components (grep), visual diff · Not checked: <…>References
| File | Read when |
references/tokens-dtcg.md | Writing token JSON, choosing types, aliasing, composite tokens (shadow, typography), or modeling modes with the resolver |
references/tailwind-shadcn.md | Wiring tokens into Tailwind v4 @theme, customizing shadcn/ui themes, or adding a new semantic color |
references/design-md.md | Creating, extracting, updating, or linting a DESIGN.md |
references/component-checklist.md | Building or reviewing components and their required states, anatomy, and API |
references/multi-platform.md | Generating tokens for iOS, Android, or Flutter, or setting up a token build pipeline and CI |
references/governance.md | Versioning, deprecating, contributing to, documenting, or measuring adoption of the system |
references/build-from-zero.md | Building a design system for a project that has none, or rescuing one nobody uses: choosing the tier, running an interface inventory, ordering the work, component lifecycle (Experimental → Removed), contribution and team models, adoption metrics, Figma ↔ code sync, and failure modes |
assets/DESIGN.template.md | Starting a new DESIGN.md |
Related skills
design-foundations— the values themselves (scales, ramps, contrast, elevation).design-taste— the direction the tokens encode; do it first for a new product.app-screen-patterns— the product screen patterns (settings, billing, errors, destructive confirms) a pattern layer should encode.frontend-architecture— where the component library lives in the repo or monorepo, and how it is consumed.accessibility— deeper keyboard, ARIA, and screen-reader requirements for components.ios-design/android-design— native theming (Liquid Glass materials, dynamic color, type roles).
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

