Component Contracts

•

Establishes the authority layer for design-to-code component lifecycles by managing variant definitions and accessibility contracts.

Component Contracts serves as the authoritative backend for design-to-code workflows, offering two distinct MCP servers. The Variant Authority server acts as the engineering contract for component libraries, defining variants, required slots, design token mappings between Figma and code, and handling component deprecations while classifying variant surface changes. Complementing this, the Radix Primitives server provides an accessibility foundation by mapping component types to Radix UI primitives, exposing ARIA contracts, keyboard interactions, and documenting known caveats. Together, these servers provide the foundational source of truth for structural correctness and accessible composition within design-to-code operations.

主要功能

01Classify component variant changes (major, minor, patch) to inform consumers.
02Manage and validate component variant manifests, including versions and deprecation info.
03Define design token bindings between Figma and code for consistent styling.
04Scan workspaces for component usage and validate variant values and required slots.
050 GitHub stars
06Map component types to Radix UI primitives and expose their accessibility contracts.

使用案例

01Ensuring accessibility compliance by integrating Radix UI primitive ARIA contracts and keyboard interactions.
02Managing and validating component library changes, including deprecations and semantic versioning impact.
03Establishing a single source of truth for component variants and design tokens in design-to-code workflows.