skills/council/artisan/design-system-architecture/SKILL.md
Use when designing a token-based design system architecture. Covers primitive, semantic, and component token hierarchy, theming strategy for dark/light mode, and cross-platform implementation planning. Do not use for visual critique of existing interfaces (use visual-audit) or animation specifications (use motion-design).
npx skillsauth add dtsong/my-claude-setup design-system-architectureInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Design a token-based design system architecture, including primitive, semantic, and component token hierarchy, theming strategy (dark/light mode), and cross-platform implementation plan.
Reads existing styling code, configuration files, and design documentation for analysis. Does not modify source files or push changes. Does not create or update Figma libraries or Storybook instances directly.
No user-provided values are used in commands or file paths. All inputs are treated as read-only analysis targets.
Review the existing styling approach:
Establish the raw values that form the foundation:
Map primitives to semantic meaning:
Map semantic tokens to component-specific values:
Define how themes override token values:
If multiple platforms:
Compaction resilience: If context was lost during a long session, re-read the Inputs section to reconstruct what system is being designed, check the Progress Checklist for completed steps, then resume from the earliest incomplete step.
# Design System Architecture
## Token Hierarchy
### Primitive Tokens
| Category | Token | Value |
|----------|-------|-------|
| Color | blue-500 | #3B82F6 |
| Spacing | space-4 | 16px |
| Type | text-base | 16px/24px |
### Semantic Tokens
| Token | Light | Dark | Usage |
|-------|-------|------|-------|
| surface-primary | white | gray-900 | Main background |
| text-primary | gray-900 | gray-50 | Body text |
| interactive-primary | blue-500 | blue-400 | Buttons, links |
### Component Tokens
| Component | Token | Maps To |
|-----------|-------|---------|
| Button (primary) | button-bg | interactive-primary |
| Button (primary) | button-text | text-inverse |
## Theme Switching
[Implementation approach — CSS class, media query, user preference]
## File Structure
tokens/ primitives.json semantic-light.json semantic-dark.json components.json
## Migration Plan
[Steps to migrate from current approach to token-based system]
development
Use when planning implementation steps, deciding commit format, or structuring development approach. Provides brainstorm-plan-implement flow with conventional commits. Triggers on 'how should I approach this', 'commit format'.
development
Security audit checklist for web applications. Use when reviewing, auditing, or hardening a web app's security posture. Covers rate limiting, auth headers, IP blocking, CORS, security middleware, input validation, file upload limits, ORM usage, and password hashing. Triggers on requests like "review security", "harden this app", "security audit", "check for vulnerabilities", or when building/reviewing API endpoints.
development
Review UI code for Web Interface Guidelines compliance. Use when asked to "review my UI", "check accessibility", "audit design", "review UX", or "check my site against best practices".
development
React and Next.js performance optimization guidelines from Vercel Engineering. This skill should be used when writing, reviewing, or refactoring React/Next.js code to ensure optimal performance patterns. Triggers on tasks involving React components, Next.js pages, data fetching, bundle optimization, or performance improvements.