设计系统
STDIO组件属性和设计令牌信息的MCP服务器
组件属性和设计令牌信息的MCP服务器
This project includes an MCP (Model Context Protocol) server that provides information about component props and design tokens.
The MCP server offers two main tools:
getComponentProps: Retrieves information about component propertiesgetTokens: Retrieves design token information from token filesTo debug the MCP server:
$ deno task debug-mcp
This script:
You can modify the debug script to test different components or specific token requests.
Design tokens are stored as JSON files in the src/design-system/tokens directory:
color.json: Color palette and theme colorstypography.json: Font families, sizes, weightsspacing.json: Spacing scaleradius.json: Border radius valuesTokens are processed using Style Dictionary with the following workflow:
tokens directorysrc/design-system/style-dictionary/config.jsonTo generate tokens:
$ deno task build-tokens
The generated files are placed in the src/design-system/style-dictionary/dist directory and can be imported into your components.