agentleFS
botirkhaltaevbotirkhaltaev/botir-skills/skills/design-systems/SKILL.md

design-systems

Skill4 starsChanged 3 months agoApache-2.0View on GitHub

Build and maintain scalable design systems: design tokens, component libraries, naming conventions, governance, and design-to-code pipelines. Covers Figma variables, token architecture, atomic design, component APIs, versioning, and team workflows. Use when creating a design system, scaling an existing one, or establishing design-engineering alignment. Triggers on: "design system", "design tokens", "component library", "token naming", "Figma variables", "atomic design", "design ops", "design-to-code".

We split this skill into the rules it gives an agent

2 rules. 0 are common, 2 are distinctive, and 0 are very specific to this project.

  • 0

    Common

    Most of the 11 edited versions we read keep these.

  • 2

    Distinctive

    This author's own choices. Worth a look.

  • 0

    Very specific

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

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Use consistent, predictable naming.

    line 39
  2. Distinctive:

    Every component needs a clear, documented API:

    line 76

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

A design system is a single source of truth for design and engineering — tokens, components, patterns, and governance that keep products consistent at scale.

Design Tokens

The atomic values that feed every component. The single source of truth.

Token Tiers (3-Layer Model)

TierPurposeExamples
PrimitiveRaw values, no semantic meaning#0066CC, 16px, 0.25rem
SemanticMeaning-based, context-awarecolor-action-primary, spacing-section-md
ComponentComponent-specific assignmentsbutton-bg-primary, input-border-focus

Token Categories

  • Color — brand, neutral, semantic (success/warning/error), alpha
  • Spacing — inset, stack, inline, spacing scale
  • Typography — font family, size, weight, line height, letter spacing
  • Elevation — shadow, z-index, overlay opacity
  • Border — radius, width, style
  • Motion — duration, easing curve
  • Breakpoint — responsive width thresholds

Naming Convention

Use consistent, predictable naming. Two popular approaches:

Category/Property/Variant (recommended)

color/background/primary
color/background/primary-hover
spacing/inset/md
typography/font-size/body

Dot-notation (code-friendly)

color.bg.primary
color.bg.primaryHover
spacing.inset.md

Token Governance

  • Assign token owners — each category has a responsible person
  • Version tokens — use semantic versioning (breaking.addition.fix)
  • Document decisions — every token needs a rationale
  • Audit quarterly — retire unused tokens, resolve duplicates
  • Never hardcode — everything consumed by components must be a token

Component Architecture

Atomic Design Hierarchy

LevelDescriptionExample
AtomsIndivisible building blocksButton, Input, Label, Icon
MoleculesSimple component groupsSearch bar (input + button), Form field (label + input + error)
OrganismsComplex, distinct sectionsHeader, Card, Navigation bar
TemplatesPage-level layouts without contentProduct page template, Dashboard template
PagesTemplates populated with real contentActual product page with real data

Component API Design

Every component needs a clear, documented API:

interface ButtonProps {
  variant: 'primary' | 'secondary' | 'tertiary' | 'danger';
  size: 'sm' | 'md' | 'lg';
  isDisabled?: boolean;
  isLoading?: boolean;
  onPress: () => void;
  children: ReactNode;
  icon?: IconName;        // optional icon
  iconPosition?: 'start' | 'end';
}

Component Checklist

  • All states defined: default, hover, active, focus, disabled, loading
  • Accessibility: keyboard operable, screen reader labels, focus visible
  • Responsive behavior documented
  • Dark mode variants specified
  • Usage guidelines written
  • Do/don't examples provided
  • Edge cases handled (empty, error, overflow)

Figma-to-Code Pipeline

Modern Workflow (2025)

  1. Design in Figma using variables and components
  2. Variables sync to Token Studio or Figma REST API
  3. Tokens export as JSON via Style Dictionary or Tokens Studio
  4. JSON transforms to code (CSS variables, JS constants, Swift, Android XML)
  5. Components built in code consuming the same tokens
  6. Storybook documents components with live examples

Tools

ToolPurpose
Token StudioToken management in Figma
Style DictionaryTransform tokens to any platform
Code ConnectLink Figma components to code
StorybookComponent documentation
ChromaticVisual regression testing

Governance Model

Roles

RoleResponsibility
Design System LeadStrategy, roadmap, stakeholder alignment
Token OwnerMaintains token category, reviews changes
Component OwnerMaintains component, ensures quality
DesignOpsProcess, tooling, adoption metrics

Contribution Model

Three approaches, pick one based on team size:

  1. Centralized — dedicated team maintains everything (enterprise)
  2. Federated — contributions from product teams, reviewed by core team (mid-size)
  3. Open source — anyone can contribute, PR review process (small/startups)

Change Process

  1. Proposal submitted (RFC or ticket)
  2. Reviewed by component/token owner
  3. Designed and documented
  4. Implemented in code
  5. Communicated to consumers (changelog, migration guide)
  6. Deprecated old version with timeline

Anti-Patterns

  • One-off overrides — teams bypassing tokens for "just this one case"
  • Undocumented components — built but not in the system
  • Breaking changes without migration — updating without guidance
  • Design without code parity — Figma looks different from production
  • Too many variants — component with 50+ variants is unmaintainable

Reference Map

  • references/token-architecture.md — primitive/semantic/component tiers, naming, pipeline
  • references/governance-rfc.md — roles, contribution models, RFC/semver, adoption metrics

Related Skills

  • For visual design fundamentals → use ui-visual-design
  • For dark mode specifics → use dark-mode-design
  • For accessibility in systems → use a11y-accessibility-design

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.