Files
ONE-OS/axhub-make/skills/web-page-workflow/theme-generation.md
王冕 a27e3b8e43 feat: sync full workspace including web modules, docs, and configurations to Gitea
Optimized the root .gitignore to exclude virtual environments, node modules,
and temp folders to ensure clean and lightweight version tracking.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-09 18:12:25 +08:00

44 lines
1.3 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# 网页主题生成规则
用于从网页提取并生成主题资产。
只处理主题相关产物,不处理文档正文与数据建模细节。
## 页面选择
1. 从页面发现结果中选择 3-5 个代表性页面。
2. 优先:首页、主流程页、核心详情页。
3. 页面风格差异较大时,优先与业务主线一致的页面。
## 提取策略
1. 优先调用本项目 MCP 的 `get_page_theme`
2. 若失败,再使用 Firecrawl `extract` 的 branding 结果兜底。
3. 多页面结果需要合并并去重,保留稳定 token。
## 输出文件(强约束)
输出目录:`src/themes/<theme-key>/`
必需:
- `globals.css``designToken.json`(二选一)
- `DESIGN.md`
- `index.tsx`
约束:
- `designToken.json` 必须包含 `name` 字段。
- `index.tsx` 必须展示主题关键 token 与主要组件风格。
## DESIGN.md 最低结构
1. 视觉关键词与品牌气质
2. 色彩体系(主色/辅色/语义色)
3. 排版体系(字体、字号、行高)
4. 组件风格(按钮、卡片、输入、表格)
5. 状态与反馈hover/active/disabled/error
## 质量检查
- token 是否可复用且命名一致
- 文档是否可用于后续页面还原/二次生成
- 产物路径是否严格在 `src/themes/<theme-key>/`