@agile-team/wl-skills-kit 2.11.0 → 2.11.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (95) hide show
  1. package/CHANGELOG.md +47 -9
  2. package/README.md +41 -23
  3. package/bin/wl-skills.js +133 -39
  4. package/docs/agent-pipeline-runbook.md +3 -3
  5. package/docs//345/205/250/347/233/230/345/210/206/346/236/220/344/270/216/346/231/272/350/203/275/344/275/223/346/220/255/345/273/272/346/214/207/345/215/227.md +4 -4
  6. package/files/.wl-skills/copilot-instructions-full.md +233 -233
  7. package/files/.wl-skills/docs/jh-pagination.md +505 -505
  8. package/files/.wl-skills/docs/page-spec-schema.md +109 -0
  9. package/files/.wl-skills/docs/request.md +940 -940
  10. package/files/.wl-skills/guides/architecture.md +1 -1
  11. package/files/.wl-skills/skills/core/convention-audit/SKILL.md +3 -3
  12. package/files/.wl-skills/skills/core/page-codegen/SKILL.md +10 -4
  13. package/files/.wl-skills/skills/core/spec-doc-parse/SKILL.md +332 -332
  14. package/files/.wl-skills/skills/core/spec-doc-parse/USAGE.md +97 -97
  15. package/files/.wl-skills/skills/sync/permission-sync/USAGE.md +107 -107
  16. package/files/.wl-skills/src/components/global/C_ParentView/index.vue +3 -3
  17. package/files/.wl-skills/src/components/global/C_RightToolbar/index.vue +157 -157
  18. package/files/.wl-skills/src/components/global/C_SvgIcon/index.vue +31 -31
  19. package/files/.wl-skills/src/components/global/C_SvgIcon/svgicon.js +10 -10
  20. package/files/.wl-skills/src/components/global/C_TagStatus/README.md +264 -264
  21. package/files/.wl-skills/src/components/global/C_TagStatus/config.ts +192 -192
  22. package/files/.wl-skills/src/components/global/C_TagStatus/index.vue +106 -106
  23. package/files/.wl-skills/src/components/global/C_TagStatus/types.ts +64 -64
  24. package/files/.wl-skills/src/components/global/C_Tree/README.md +153 -153
  25. package/files/.wl-skills/src/components/global/C_Tree/index.scss +42 -42
  26. package/files/.wl-skills/src/components/global/C_Tree/index.vue +78 -78
  27. package/files/.wl-skills/src/components/global/C_Tree/types.ts +59 -59
  28. package/files/.wl-skills/src/components/local/c_formModal/README.md +235 -235
  29. package/files/.wl-skills/src/components/local/c_formModal/data.ts +95 -95
  30. package/files/.wl-skills/src/components/local/c_formModal/index.scss +8 -8
  31. package/files/.wl-skills/src/components/local/c_formModal/index.vue +107 -107
  32. package/files/.wl-skills/src/components/local/c_formSections/data.ts +175 -175
  33. package/files/.wl-skills/src/components/local/c_formSections/index.scss +280 -280
  34. package/files/.wl-skills/src/components/local/c_formSections/index.vue +429 -429
  35. package/files/.wl-skills/src/components/local/c_listModal/data.ts +41 -41
  36. package/files/.wl-skills/src/components/local/c_listModal/index.vue +136 -136
  37. package/files/.wl-skills/src/components/local/c_spliterTitle/index.scss +25 -25
  38. package/files/.wl-skills/src/components/local/c_spliterTitle/index.vue +21 -21
  39. package/files/.wl-skills/src/components/remote/AGGrid/README.md +530 -530
  40. package/files/.wl-skills/src/components/remote/BaseForm/README.md +508 -508
  41. package/files/.wl-skills/src/components/remote/BaseQuery/README.md +865 -865
  42. package/files/.wl-skills/src/components/remote/BaseTable/README.md +941 -941
  43. package/files/.wl-skills/src/components/remote/BaseToolbar/README.md +496 -496
  44. package/files/.wl-skills/src/types/page.ts +24 -24
  45. package/files/.wl-skills/standards/04-coding-basics.md +39 -1
  46. package/files/.wl-skills/standards/09-typescript.md +26 -3
  47. package/files/.wl-skills/standards/14-layout-containers.md +6 -6
  48. package/files/.wl-skills/standards/index.md +2 -2
  49. package/files/.wl-skills/templates/README.md +44 -44
  50. package/files/.wl-skills/templates/produce/aiflow/mmwr-customer-apply-add/api.md +54 -54
  51. package/files/.wl-skills/templates/produce/aiflow/mmwr-customer-apply-add/data.ts +346 -346
  52. package/files/.wl-skills/templates/produce/aiflow/mmwr-customer-apply-add/index.scss +1 -1
  53. package/files/.wl-skills/templates/produce/aiflow/mmwr-customer-apply-add/index.vue +28 -28
  54. package/files/.wl-skills/templates/produce/aiflow/mmwr-customer-apply-add-form/data.ts +115 -115
  55. package/files/.wl-skills/templates/produce/aiflow/mmwr-customer-apply-add-form/index.scss +44 -44
  56. package/files/.wl-skills/templates/produce/aiflow/mmwr-customer-apply-add-form/index.vue +43 -43
  57. package/files/.wl-skills/templates/produce/aiflow/mmwr-customer-apply-change/data.ts +338 -338
  58. package/files/.wl-skills/templates/produce/aiflow/mmwr-customer-apply-change/index.scss +1 -1
  59. package/files/.wl-skills/templates/produce/aiflow/mmwr-customer-apply-change/index.vue +28 -28
  60. package/files/.wl-skills/templates/produce/aiflow/mmwr-customer-apply-change-form/data.ts +115 -115
  61. package/files/.wl-skills/templates/produce/aiflow/mmwr-customer-apply-change-form/index.scss +44 -44
  62. package/files/.wl-skills/templates/produce/aiflow/mmwr-customer-apply-change-form/index.vue +43 -43
  63. package/files/.wl-skills/templates/produce/aiflow/mmwr-customer-archive/api.md +88 -88
  64. package/files/.wl-skills/templates/produce/aiflow/mmwr-customer-archive/data.ts +601 -601
  65. package/files/.wl-skills/templates/produce/aiflow/mmwr-customer-archive/index.scss +1 -1
  66. package/files/.wl-skills/templates/produce/aiflow/mmwr-customer-archive/index.vue +64 -64
  67. package/files/.wl-skills/templates/produce/aiflow/mmwr-customer-detail/api.md +67 -67
  68. package/files/.wl-skills/templates/produce/aiflow/mmwr-customer-detail/data.ts +286 -286
  69. package/files/.wl-skills/templates/produce/aiflow/mmwr-customer-detail/index.scss +139 -139
  70. package/files/.wl-skills/templates/produce/aiflow/mmwr-customer-detail/index.vue +318 -318
  71. package/files/.wl-skills/templates/produce/aiflow/mmwr-temp-customer-archive/api.md +98 -98
  72. package/files/.wl-skills/templates/produce/aiflow/mmwr-temp-customer-archive/data.ts +543 -543
  73. package/files/.wl-skills/templates/produce/aiflow/mmwr-temp-customer-archive/index.scss +1 -1
  74. package/files/.wl-skills/templates/produce/aiflow/mmwr-temp-customer-archive/index.vue +52 -52
  75. package/files/.wl-skills/templates/sale/demo/add-demo/data.ts +518 -518
  76. package/files/.wl-skills/templates/sale/demo/billet-flame-cut-plan/data.ts +524 -524
  77. package/files/.wl-skills/templates/sale/demo/billet-flame-cut-plan/index.scss +154 -154
  78. package/files/.wl-skills/templates/sale/demo/billet-flame-cut-plan/index.vue +117 -117
  79. package/files/.wl-skills/templates/sale/demo/domestic-trade-order/data.ts +308 -308
  80. package/files/.wl-skills/templates/sale/demo/domestic-trade-order/index.scss +99 -99
  81. package/files/.wl-skills/templates/sale/demo/domestic-trade-order/index.vue +77 -77
  82. package/files/.wl-skills/templates/sale/demo/heat-batch-return/data.ts +367 -367
  83. package/files/.wl-skills/templates/sale/demo/heat-batch-return/index.scss +100 -100
  84. package/files/.wl-skills/templates/sale/demo/heat-batch-return/index.vue +170 -170
  85. package/files/.wl-skills/templates/sale/demo/heat-batch-return/meltDialog.vue +320 -320
  86. package/files/.wl-skills/templates/sale/demo/metallurgical-spec/data.ts +824 -824
  87. package/lib/ast-rules.js +304 -9
  88. package/lib/page-spec.js +588 -0
  89. package/lib/safe-fix.js +115 -0
  90. package/mcp/config.js +47 -47
  91. package/mcp/registry.js +6 -1
  92. package/mcp/tools/projectTools.js +19 -1
  93. package/package.json +16 -11
  94. package/files/.wl-skills/src/components/global/C_Splitter/index.scss +0 -61
  95. package/files/.wl-skills/src/components/global/C_Splitter/index.vue +0 -149
@@ -2,7 +2,7 @@
2
2
 
3
3
  > **读者**:团队技术负责人 / wl-skills-kit 维护者 / 对体系设计感兴趣的团队成员
4
4
  > **更新方式**:重大架构变更后追加对应章节,旧章节原文保留(历史可溯)
5
- > **当前版本**:v2.11.0(2026-06-14
5
+ > **当前版本**:v2.11.2(2026-06-21
6
6
 
7
7
  ---
8
8
 
@@ -112,7 +112,7 @@ description: "Use when: auditing project source code against the 14 modular stan
112
112
  | 06 | 安全规范 | 静态扫描 | `v-html` 无注释 / `import axios` / `eval` / `new Function` → 🔴 |
113
113
  | 07 | 配置管理 | 静态扫描 | 硬编码 `http://` IP → 🔴;API 路径散落 → 🟡 |
114
114
  | 08 | Git 规范 | Git 命令 + 文件检测 | 工具链缺失 → 🔴;分支名不规范 → 🟡;近期提交不规范 → 🟡;历史 → 🟢 |
115
- | 09 | TypeScript | tsc / ESLint 委托 | AI 不逐文件做类型推导,读取工具链输出归类;`any` 滥用 → 🟡 |
115
+ | 09 | TypeScript 类型 + 类型错误 | R14(vue-tsc/tsc 委托)+ AI | 类型检查器缺失 → 🔴;`vue-tsc --noEmit` 非 0 → 🔴;`any` 滥用 → 🟡 |
116
116
  | 10 | Pinia | 静态扫描 | `data.ts` 内 import Store → 🔴 |
117
117
  | 11 | 表单校验 | AI 场景判断 | FORM_ROUTE 缺 validate / resetFields → 🔴 |
118
118
  | 12 | BaseTable + cid | 静态 + 场景判断 | 主列表用 el-table → 🔴;cid 缺失/重复 → 🔴;弹窗小表格见豁免规则 |
@@ -158,14 +158,14 @@ description: "Use when: auditing project source code against the 14 modular stan
158
158
  1. 读取 `standards/01 ~ 14` 全部规范文件
159
159
  2. 检测工具链状态:
160
160
  - ESLint:是否可执行
161
- - TypeScript:`tsc --noEmit` 是否可执行
161
+ - TypeScript:`vue-tsc --noEmit`(回退 `tsc --noEmit`)是否可执行、是否 0 error(R14)
162
162
  - Git:当前分支 / 最近提交
163
163
  - Husky:`.husky/pre-commit`、`.husky/commit-msg` 是否存在
164
164
  3. 读取 `package.json` 获取项目脚本名称
165
165
 
166
166
  ### 步骤 3:扫描源码
167
167
 
168
- 逐个文件检查 13 个维度。同时记录:
168
+ 逐个文件检查 14 个维度。同时记录:
169
169
 
170
170
  - **扫描统计**:目录数、文件数、页面数、类型分布
171
171
  - **跨页面相同 el-\* 模式**(统计出现次数和位置)
@@ -43,10 +43,12 @@ description: "Use when: generating complete Vue 3 page code (index.vue + data.ts
43
43
  ✅ src/views/.../{页面}/data.ts
44
44
  ✅ src/views/.../{页面}/index.scss
45
45
  ✅ src/views/.../{页面}/api.md
46
+ ✅ src/views/.../{页面}/page-spec.json → 约定真值(供 S1~S5 比对)
46
47
  ✅ reports/SYS_MENU_INFO.md → 已追加菜单条目
47
48
  ────────────────────────────────────────────────
48
49
  🔍 强制自检(不可跳过):
49
50
  wl-skills validate src/views/{生成的页面目录}
51
+ → 同时执行 R1~R12(AST 语义)+ S1~S5(page-spec 比对)
50
52
  → 结果:{0 error / N warn} 或列出 error 待修复
51
53
  ────────────────────────────────────────────────
52
54
  📌 后续步骤:
@@ -98,12 +100,15 @@ description: "Use when: generating complete Vue 3 page code (index.vue + data.ts
98
100
 
99
101
  ```
100
102
  src/views/[域]/[模块]/[子模块]/[kebab-case-目录名]/
101
- ├── index.vue ← 页面入口(纯模板 + 解构)
102
- ├── data.ts ← 业务逻辑(AbstractPageQueryHook 类 / 直接导出 ref+函数)
103
- ├── index.scss ← 页面样式
104
- └── api.md ← 接口约定(按 api-contract Skill 模板生成)
103
+ ├── index.vue ← 页面入口(纯模板 + 解构)
104
+ ├── data.ts ← 业务逻辑(AbstractPageQueryHook 类 / 直接导出 ref+函数)
105
+ ├── index.scss ← 页面样式
106
+ ├── api.md ← 接口约定(按 api-contract Skill 模板生成)
107
+ └── page-spec.json ← ★ 原型约定真值(查询/列/按钮/操作列 顺序+颜色),供 validate S1~S5 确定性比对
105
108
  ```
106
109
 
110
+ > **page-spec.json 是"精准实现"的真值锚点**:把 page-spec(查询字段顺序、列顺序、按钮顺序与颜色、操作列)固化到页面目录,`wl-skills validate` 据此比对 data.ts 实际实现,偏差即报(详见 `.wl-skills/docs/page-spec-schema.md`)。**不可省略**——没有它,"按约定实现"无法被验证,只能靠 AI 自觉。
111
+
107
112
  弹窗组件处理策略:
108
113
 
109
114
  - **通用弹窗**(新增/编辑表单,2+ 页面可复用)→ 提取到 `.wl-skills/src/components/local/c_xxxModal/`
@@ -150,6 +155,7 @@ src/views/[域]/[模块]/[子模块]/[kebab-case-目录名]/
150
155
  27. **BaseTable 强制 AGGrid**:所有业务主列表/台账/主从表/树表/详情子表的 `BaseTable` 必须显式写 `render-type="agGrid"`,并绑定全局唯一 `cid`。弹窗小表格可豁免,但必须在生成摘要中说明理由。
151
156
  28. **cid 必须可追踪**:每个页面导出 `TABLE_CID = "{pageAbbr}-{base36Timestamp}"`;多表页面使用 `BOTTOM_TABLE_CID` / `ITEM_TABLE_CID`,列级 `cid` 必须使用 `${TABLE_CID}-fieldName` 前缀。
152
157
  29. **skills-ui 只能融合,不可生搬硬套**:不得照搬 `wk-skills-ui/templates/list-page` 中的原生 `el-form/usePageHook/el-pagination` 通用写法;本项目必须保留 `AbstractPageQueryHook + BaseQuery + BaseToolbar + BaseTable + jh-pagination` 平台骨架,只融合 `defineColumns/renderOps/tokens/preset`。
158
+ 30. **必须落盘 page-spec.json**:生成页面时,把 page-spec(`page` 中文名 + `query` + `columns` + `toolbar` + `operations`)按 `.wl-skills/docs/page-spec-schema.md` 写入页面目录的 `page-spec.json`。字段 `name`/`label`/顺序必须与 data.ts 生成内容、与原型严格一致——这是 `validate` 做 S1~S5 比对的真值。生成后自检若出现 S2/S3/S4 error,说明 data.ts 与 spec 不一致,必须修正到 0 error。
153
159
 
154
160
  ### 禁止事项(严格遵守)
155
161