gts-design-system-integration
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseGTS Design System Integration
GTS设计系统集成
Quick Workflow
快速工作流程
- Identify the app type and current styling stack.
- Align dependencies and Tailwind v4 tooling.
- Set up one Tailwind css entrypoint and correct import order.
- Import GTS css once at the app root.
- Remove conflicting token/theme/global style sources.
- Apply GTS layout and typography patterns.
- For complex pages (for example configurator screens), compose reusable layout sections and variant-driven states.
- Validate build, lint, and visual output.
- 确定应用类型和当前样式技术栈。
- 对齐依赖项和Tailwind v4工具链。
- 配置一个Tailwind CSS入口点并设置正确的导入顺序。
- 在应用根目录处导入一次GTS CSS。
- 移除冲突的token/主题/全局样式源。
- 应用GTS布局与排版模式。
- 对于复杂页面(例如配置器页面),组合可复用的布局区块和变体驱动的状态。
- 验证构建、代码检查和视觉输出效果。
Load These References
参考资料
- Always read .
references/guidelines.md - Always read .
references/shadcn-compatibility.md - Always read .
references/tailwind-style-usage.md - Always read .
references/tailwind-utility-inventory.md - Read for app-specific steps.
references/app-integration-playbook.md
- 务必阅读。
references/guidelines.md - 务必阅读。
references/shadcn-compatibility.md - 务必阅读。
references/tailwind-style-usage.md - 务必阅读。
references/tailwind-utility-inventory.md - 针对特定应用的步骤,请阅读。
references/app-integration-playbook.md
Guardrails
注意事项
- Treat as the styling source of truth.
gts-central-library - Keep app behavior and routing unchanged during migration.
- Keep local css minimal and app-specific.
- Avoid duplicate semantic variable systems.
- Keep Tailwind configuration modern (v4 syntax/tooling) and avoid legacy layering patterns.
- Prefer GTS components and token-backed values over one-off styles.
- For configurator implementations, model screen states as explicit variants (,
summary,style, etc.) instead of duplicating near-identical page code.personalize - Reuse existing primitives (,
Header,USPBar,ActionBar,Button, token utilities) before introducing new components.SearchBar - Keep configurator sections data-driven (accordion rows, swatches, option grids) so behavior and structure stay consistent across variants.
- Add Storybook coverage for each major layout state; do not create separate stories for transient interactive states (hover/focus/pressed).
- 将视为样式的唯一可信来源。
gts-central-library - 迁移期间保持应用行为和路由不变。
- 尽量减少本地CSS,仅保留应用特定的样式。
- 避免重复的语义变量系统。
- 保持Tailwind配置为现代版本(v4语法/工具),避免传统的分层模式。
- 优先使用GTS组件和基于token的值,而非一次性样式。
- 对于配置器实现,将页面状态建模为明确的变体(如、
summary、style等),而非复制几乎相同的页面代码。personalize - 在引入新组件之前,优先复用现有基础组件(、
Header、USPBar、ActionBar、Button、token工具类)。SearchBar - 保持配置器区块的数据驱动(手风琴行、色板、选项网格),确保不同变体间的行为和结构一致。
- 为每个主要布局状态添加Storybook覆盖;无需为临时交互状态(悬停/聚焦/按下)创建单独的Story。
Validation
验证
Use the app's standard checks:
bash
npm run build
npm run lintThen verify representative screens for token resolution, spacing, typography, and color parity.
For itself, use:
gts-central-librarybash
bun run build
bun run lint使用应用的标准检查命令:
bash
npm run build
npm run lint然后验证代表性页面的token解析、间距、排版和颜色一致性。
对于本身,使用:
gts-central-librarybash
bun run build
bun run lint