agentleFS
TomSzenessyTomSzenessy/AI_TEMPLATE/.agents/skills/design-tokens/SKILL.md

design-tokens

Skill0 starsChanged 58 days agoMITView on GitHub

Rebuilds a reference product's design system as design tokens: colour roles, type scale, spacing, radius, shadows and every component with its states, with original assets instead of the reference product's logos, icons, illustrations or licensed fonts. Includes a WCAG contrast checker. Use when the user says "design tokens", "match the design system", "WCAG contrast", or "make it look like X".

21 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use brief-to-tasks, information-architecture and 6 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.
  • julianoczkowskiSkill

    brief-to-tasks

    Break a design brief into an ordered checklist of independently buildable tasks using vertical slices. Saves as a markdown checklist. Use when user wants to break down work, create tasks from a brief, plan implementation order, or mentions "tasks" or "breakdown".

    Also in 4 projects that use this

  • fefogarciaSkill

    information-architecture

    Use when organizing content for digital products, designing navigation systems, restructuring information hierarchies, improving findability, creating taxonomies or metadata schemas, or when users mention information architecture, IA, sitemap, navigation design, content structure, card sorting, tree testing, taxonomy, findability, or need help making information discoverable and usable.

    Also in 5 projects that use this

  • julianoczkowskiSkill

    design-flow

    Run the full design-to-build workflow as a guided sequence. Orchestrates all designer skills in order, from grilling through review. Use when user wants to go through the complete design process, start a project from scratch, run the full flow, or mentions "design flow" or "full workflow".

    Also in 3 projects that use this

  • nandanosqlSkill

    design-brief

    Create a design brief that clearly communicates the product context, user needs, constraints, and success criteria to the design team — bridging PM requirements and design execution.

    Also in 4 projects that use this

  • AICreator-WindSkill

    design-review

    编码设计师工具。设计审计和修复。

    Also in 9 projects that use this

  • AnthropicSkill

    design-system

    Audit, document, or extend your design system. Use when checking for naming inconsistencies or hardcoded values across components, writing documentation for a component's variants, states, and accessibility notes, or designing a new pattern that fits the existing system.

    Also in 3 projects that use this

The file

We split this skill into the rules it gives an agent

5 rules. 0 are common, 4 are distinctive, and 1 is very specific to this project.

  • 0

    Common

    Most of the 19 edited versions we read keep these.

  • 4

    Distinctive

    This author's own choices. Worth a look.

  • 1

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Logos, icons, illustrations, photos, sounds: Use an open icon set (Lucide, Phosphor, Heroicons, Tabler, all MIT or similar) and make or …

    line 29
  2. Distinctive:

    Licensed fonts: If the reference product uses a paid or proprietary font, pick an open one with the same job: Inter, Geist, IBM Plex, …

    line 32
  3. Distinctive:

    Their copy: Every label and empty state gets written fresh.

    line 35
  4. Very specific:

    Add a pairs list for every text and background combination the app uses, then:

    line 62
  5. Distinctive:

    Every state the recon saw, plus the ones it should have: focus, disabled, loading, error, empty.

    line 88

“Common” is measured: kept by at least 6 in 10 of the 19 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.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

design-tokens

Reads reference/recon.md and the screenshots in reference/screens/, both from product-recon. Writes reference/design/tokens.json (template: tokens.json in this folder), reference/design/tokens.css, the theme mapping, and reference/design/components.md.

python3 .agents/skills/design-tokens/contrast.py reference/design/tokens.json     # every text pair, WCAG ratio

The rules

What you rebuild is the system: the roles, the scale, the patterns, the way a form or a modal behaves. Those are not ownable, and users expect them. What you never take:

  • Logos, icons, illustrations, photos, sounds. Use an open icon set (Lucide, Phosphor, Heroicons, Tabler, all MIT or similar) and make or commission your own illustrations. Do not trace theirs.
  • Licensed fonts. If the reference product uses a paid or proprietary font, pick an open one with the same job: Inter, Geist, IBM Plex, Manrope, Source Serif.
  • Their copy. Every label and empty state gets written fresh.
  • Their brand colour. Record it as a role (accent), use a neutral placeholder now, and brand-sweep gives you your own. The signature colour plus the signature layout is trade dress, and it changes before launch.

Step 1: measure, do not guess

From the screenshots (zoom in, use a colour picker on the user's machine):

  • Colour roles, not colours: bg, surface, border, border-input, text, text-muted, accent, on-accent, danger, success, warning. Count how many greys the app really uses. Usually 5 to 7.
  • Type scale: sizes, line heights, weights. Snap to a scale (12, 14, 16, 20, 28, 40 is common). Note the font category, not the font file.
  • Spacing: measure gaps between elements. It is almost always a 4 or 8 base. Write the scale.
  • Radius, shadow, motion: two or three of each.
  • Layout: max content width, grid, breakpoints, sidebar width, header height.

Step 2: write the tokens

Fill reference/design/tokens.json. Keep the role names. brand-sweep only changes values. Generate reference/design/tokens.css as custom properties and map them into the project's theme (Tailwind's theme where that is the stack) so components use bg-surface text-muted, never raw hex.

Add a pairs list for every text and background combination the app uses, then:

python3 .agents/skills/design-tokens/contrast.py reference/design/tokens.json

AA is the floor: 4.5:1 for body text, 3:1 for large text and for input borders and focus rings. It exits 1 on a failure. Fix it in the tokens, not per component.

Step 3: component specs

For every component in product-recon's list, one block in reference/design/components.md:

Button
  variants  primary, secondary, ghost, danger
  sizes     sm 32px, md 40px, lg 48px
  states    default, hover, active, focus-visible (2px ring, accent), disabled, loading
  tokens    bg accent, text on-accent, radius md, font sm/600
  a11y      real <button>, visible focus, loading keeps the label for screen readers
  used on   S02, S07, S09

Every state the recon saw, plus the ones it should have: focus, disabled, loading, error, empty. Keyboard and screen reader behaviour is part of the spec.

Step 4: build the primitives

Build the components in code once, in isolation (a /design route or Storybook), before any screen. Use an accessible base if the stack has one (Radix, shadcn/ui, React Aria). Screenshot the page. That is the design system check.

Output

tokens.json, tokens.css, the theme mapping, components.md, the primitives built, and a contrast report with zero AA failures. Then the project's issue-backed build loop (AGENTS.md) builds screens against the primitives. Remember: reference/ must be registered in project.toml (see product-recon).

Source

Adapted from the upstream skill in https://github.com/Jakeschincariol/replica-skill (MIT, © 2026 Jake Schincariol), revision 77c9436fb3d18c3d58169efb8caf4fe906b0dc51.

Download now (ZIP)

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
What did you use it for? e.g. Reviewing pull requests in a Rails app

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.