design-system-architect
Design System Architect
Master design system architecture to create consistent, maintainable, and scalable UI foundations across web and mobile applications.
When to Use This Skill
- Creating design tokens (colors, type, spacing).
- Establishing token hierarchies (Primitive -> Semantic -> Component).
- Defining visual foundations (8pt grid, modular type scales).
- Implementing light/dark theme switching.
- Architecting consistent component libraries.
- Brand Implementation: Translating Brand Guidelines (Colors, Voice) into code.
Core Concepts
1. Token Hierarchy (The "3-Layer Cake")
Understanding the relationship between layers is critical for scalability.
-
Layer 1: Primitive Tokens (Raw)
- Definition: Agnostic raw values.
- Example:
--color-blue-500: #3b82f6,--space-4: 1rem - Goal: The "Palette" available to the system.
-
Layer 2: Semantic Tokens (Intent)
- Definition: Contextual meaning; references primitives.
- Example:
--text-primary: var(--color-gray-900),--status-critical: var(--color-red-500) - Goal: The "Voice" of the system. Allows theming (remapping).
-
Layer 3: Component Tokens (Specific)
- Definition: Specific component usage.
- Example:
--button-bg-hover: var(--interactive-primary-hover) - Goal: Isolation. Changing a button shouldn't break a card.
2. Visual Foundations
Typography Scale Use a modular scale (e.g., Major Third 1.250).
:root {
--text-xs: 0.75rem; /* 12px */
--text-base: 1rem; /* 16px */
--text-xl: 1.25rem; /* 20px */
}
- Rules: Line height 1.5 for body, 1.2-1.1 for headings.
Spacing System (8pt Grid) Avoid magic numbers. Everything is a multiple of 4px or 8px.
--space-1: 0.25rem (4px)--space-2: 0.5rem (8px)--space-4: 1rem (16px) - The base unit
3. Aesthetics & Brand Identity
- Styles: Support for Glassmorphism, Aurora UI, Linear/Vercel Aesthetic.
- Framework: Refer to
resources/ai-design-framework.mdfor specific palettes and patterns. - Gradients: Define brand gradients as tokens (
--gradient-brand: linear-gradient(...)). - Shadows: Use layered shadows for depth (
--shadow-elevation-low,--shadow-elevation-high).
4. Implementation Architecture
Theming Infrastructure (React)
- Storage: Persist in
localStorageto avoid FOUC. - System Sync: Listen to
prefers-color-scheme. - Injector: Apply
.darkclass to<html>.
Component Variants (CVA)
Use class-variance-authority for type-safe variants.
const button = cva("rounded font-medium transition-colors", {
variants: {
intent: {
primary: "bg-brand-500 text-white hover:bg-brand-600",
secondary: "bg-surface-200 text-text-primary"
},
// ...
}
});
Best Practices
- Name by Purpose:
text-danger✅ vstext-red❌. - Private Primitives: Developers should use
surface-subtle, notgray-50. - Accessibility: Ensure Semantic tokens meet WCAG 2.1 AA (4.5:1) by default.
More from mileycy516-stack/skills
trading-psychology-coach
High-performance mental coach for traders. implementation of "Mental Hand History", A-Game/C-Game mapping, and probabilistic thinking protocols. Use PROACTIVELY to analyze behavior, reduce tilt, and optimize the Human OS.
52frontend-developer
Build React components, implement responsive layouts, and handle client-side state management. Masters React 19, Next.js 15, and modern frontend architecture. Optimizes performance and ensures accessibility.
9vercel-react-best-practices
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.
6context-manager
Elite AI context engineering specialist mastering dynamic context management, vector databases, knowledge graphs, and intelligent memory systems. Orchestrates context across multi-agent workflows, enterprise AI systems, and long-running projects.
4backend-architect
Expert backend architect specializing in scalable API design, microservices architecture, and distributed systems. Masters REST/GraphQL/gRPC APIs, event-driven architectures, service mesh patterns, and modern backend frameworks.
4backend-security-coder
Expert in secure backend coding practices specializing in input validation, authentication, and API security. Use PROACTIVELY for backend security implementations or security code reviews.
4