feat(web): 接入和信企业 Design System 并统一控制台主色

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
unknownandCursor committed 2026-11-19 15:40:38 +08:00
1 parent b071c2a7a4
commit ae67fefc80
9 files changed
+168 -17

No files matched your search

+33
View File
@@ -0,0 +1,33 @@
# Watchman 管理端 Element Plus 细则
> 本文件是 **本仓库** 执行细则;跨项目视觉真源见 `D:\FDE\SP\design-system\`。
> 公司 EP 接入方式(按页导入、确认框、检查清单)以 `standards://frontend/element-plus` 最新版为准。
## 1. 索引
| 层 | 位置 | 职责 |
| --- | --- | --- |
| 共享风格 | `D:\FDE\SP\design-system\` | 色板、Pattern、组件选用 |
| 本仓 Token | `web/design/tokens.css` | 可执行色/字阶/圆角 |
| EP 桥接 | `web/apps/console/src/shared/styles/element-theme.css` | `--el-*` 映射 |
| 业务页面约定 | `docs/current/frontend-ui.md` | 列表筛选、页脚按钮、模块特例 |
| Cursor 规则 | `.cursor/rules/element-admin-ui.mdc` | 改 `web/apps/console/src/**/*.vue` 时约束 Agent |
## 2. 硬规则(与共享 + 公司规范对齐)
1. 控件用 Element Plus;禁止第二 UI 库;OpenDesign HTML 须 EP 重写。
2. 危险确认:`ElMessageBox.confirm`(文案走 i18n)。
3. Primary:`#0284c7`(见 D41);页面禁止散落 hex,改色只动 tokens。
4. 列表:一层卡片、左右约 32px;筛选「查询才请求」、服务端排序分页等以 `frontend-ui.md` 为准。
5. 短表单 `ElDialog`(约 480/680);长内容才用 `ElDrawer`。
6. 图标:`@element-plus/icons-vue`。
## 3. 与公司 visual-ux 的关系
公司 `standards://frontend/visual-ux` 文档基线主色为 `#5e6ad2`。
**Watchman 控制台已确认改用和信企业共享主色 `#0284c7`**(D41)。结构与接入方式仍遵守 `standards://frontend/element-plus`。
## 4. 后续可选
- 在 `web/packages/ui-components` 落地 ProTable / 列表骨架封装(公司 EP §3)。
- 需要时在本会话启用 Skill:`D:\FDE\SP\runtime\skills\hexin-ui-design-system`(勿全局 always)。