create-yss-spec 2.2.0 → 2.2.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 (472) hide show
  1. package/README.md +2 -2
  2. package/package.json +1 -1
  3. package/src/cli.js +56 -8
  4. package/template/.agents/rules/yss-ai-skills.md +59 -0
  5. package/template/.agents/skills/.yss-skills-manifest.json +28 -0
  6. package/template/.agents/skills/component-selection-imports/SKILL.md +64 -0
  7. package/template/.agents/skills/file-export-download/SKILL.md +160 -0
  8. package/template/.agents/skills/file-export-download/agents/openai.yaml +4 -0
  9. package/template/.agents/skills/formily-foundation/SKILL.md +176 -0
  10. package/template/.agents/skills/formily-foundation/references/examples.md +486 -0
  11. package/template/.agents/skills/formily-linkage-effects/SKILL.md +167 -0
  12. package/template/.agents/skills/formily-mode-slot-detail/SKILL.md +137 -0
  13. package/template/.agents/skills/formily-step-flow/SKILL.md +194 -0
  14. package/template/.agents/skills/frontend-commit/SKILL.md +118 -0
  15. package/template/.agents/skills/frontend-commit/agents/openai.yaml +7 -0
  16. package/template/.agents/skills/frontend-commit/references/scope-and-examples.md +111 -0
  17. package/template/.agents/skills/java-backend-commit/SKILL.md +121 -0
  18. package/template/.agents/skills/java-backend-commit/agents/openai.yaml +7 -0
  19. package/template/.agents/skills/java-backend-commit/references/scope-and-examples.md +118 -0
  20. package/template/.agents/skills/page-form-module/SKILL.md +168 -0
  21. package/template/.agents/skills/page-list-module/SKILL.md +137 -0
  22. package/template/.agents/skills/page-skeleton/SKILL.md +76 -0
  23. package/template/.agents/skills/page-skeleton/examples/AdvancedFormPage/constant.ts +34 -0
  24. package/template/.agents/skills/page-skeleton/examples/AdvancedFormPage/hooks/useRuleConfig.ts +75 -0
  25. package/template/.agents/skills/page-skeleton/examples/AdvancedFormPage/index.vue +107 -0
  26. package/template/.agents/skills/page-skeleton/examples/AdvancedFormPage/schemas/ruleConfigSchema.ts +256 -0
  27. package/template/.agents/skills/page-skeleton/examples/AdvancedFormPage/style.less +30 -0
  28. package/template/.agents/skills/page-skeleton/examples/StandardListPage/constant.ts +28 -0
  29. package/template/.agents/skills/page-skeleton/examples/StandardListPage/hooks/useQualityRuleList.ts +58 -0
  30. package/template/.agents/skills/page-skeleton/examples/StandardListPage/hooks/useRuleActions.ts +65 -0
  31. package/template/.agents/skills/page-skeleton/examples/StandardListPage/index.vue +91 -0
  32. package/template/.agents/skills/page-skeleton/examples/StandardListPage/style.less +49 -0
  33. package/template/.agents/skills/prototype-page-acceptance/SKILL.md +62 -0
  34. package/template/.agents/skills/theme-token-usage/SKILL.md +123 -0
  35. package/template/.agents/skills/theme-token-usage/agents/openai.yaml +4 -0
  36. package/template/.agents/skills/vue3-best-practices/SKILL.md +68 -0
  37. package/template/.agents/skills/yedit-table-usage/SKILL.md +227 -0
  38. package/template/.agents/skills/yss-api-integration/SKILL.md +12 -2
  39. package/template/.agents/skills/yss-components/SKILL.md +1 -1
  40. package/template/.agents/skills/yss-design-system/SKILL.md +1 -1
  41. package/template/.agents/skills/yss-formily/SKILL.md +233 -265
  42. package/template/.agents/skills/yss-frontend-scaffold-generator/SKILL.md +1 -1
  43. package/template/.agents/skills/yss-hook/SKILL.md +1 -1
  44. package/template/.agents/skills/yss-openapi-governance/SKILL.md +2 -2
  45. package/template/.agents/skills/yss-page-module-development/SKILL.md +12 -2
  46. package/template/.agents/skills/yss-page-module-development/references/component-map.md +34 -0
  47. package/template/.agents/skills/yss-page-module-development/references/hooks-map.md +11 -0
  48. package/template/.agents/skills/yss-page-module-development/references/utils-map.md +14 -0
  49. package/template/.agents/skills/yss-product-lifecycle/references/orchestration-contract.yaml +62 -1
  50. package/template/.agents/skills/yss-router/references/boundaries.md +1 -1
  51. package/template/.agents/skills/yss-router/references/router-contract.yaml +6 -2
  52. package/template/.agents/skills/yss-ui/SKILL.md +1 -1
  53. package/template/.agents/skills/yss-use-table-height/SKILL.md +9 -0
  54. package/template/.agents/skills/yss-use-tree-height/SKILL.md +9 -0
  55. package/template/.agents/skills/ytable-usage/SKILL.md +251 -0
  56. package/template/.agents/skills/ytree-usage/SKILL.md +132 -0
  57. package/template/.claude/skills/.yss-skills-manifest.json +29 -0
  58. package/template/.claude/skills/component-selection-imports/SKILL.md +64 -0
  59. package/template/.claude/skills/file-export-download/SKILL.md +160 -0
  60. package/template/.claude/skills/file-export-download/agents/openai.yaml +4 -0
  61. package/template/.claude/skills/formily-foundation/SKILL.md +176 -0
  62. package/template/.claude/skills/formily-foundation/references/examples.md +486 -0
  63. package/template/.claude/skills/formily-linkage-effects/SKILL.md +167 -0
  64. package/template/.claude/skills/formily-mode-slot-detail/SKILL.md +137 -0
  65. package/template/.claude/skills/formily-step-flow/SKILL.md +194 -0
  66. package/template/.claude/skills/frontend-commit/SKILL.md +118 -0
  67. package/template/.claude/skills/frontend-commit/agents/openai.yaml +7 -0
  68. package/template/.claude/skills/frontend-commit/references/scope-and-examples.md +111 -0
  69. package/template/.claude/skills/java-backend-commit/SKILL.md +121 -0
  70. package/template/.claude/skills/java-backend-commit/agents/openai.yaml +7 -0
  71. package/template/.claude/skills/java-backend-commit/references/scope-and-examples.md +118 -0
  72. package/template/.claude/skills/page-form-module/SKILL.md +168 -0
  73. package/template/.claude/skills/page-list-module/SKILL.md +137 -0
  74. package/template/.claude/skills/page-skeleton/SKILL.md +76 -0
  75. package/template/.claude/skills/page-skeleton/examples/AdvancedFormPage/constant.ts +34 -0
  76. package/template/.claude/skills/page-skeleton/examples/AdvancedFormPage/hooks/useRuleConfig.ts +75 -0
  77. package/template/.claude/skills/page-skeleton/examples/AdvancedFormPage/index.vue +107 -0
  78. package/template/.claude/skills/page-skeleton/examples/AdvancedFormPage/schemas/ruleConfigSchema.ts +256 -0
  79. package/template/.claude/skills/page-skeleton/examples/AdvancedFormPage/style.less +30 -0
  80. package/template/.claude/skills/page-skeleton/examples/StandardListPage/constant.ts +28 -0
  81. package/template/.claude/skills/page-skeleton/examples/StandardListPage/hooks/useQualityRuleList.ts +58 -0
  82. package/template/.claude/skills/page-skeleton/examples/StandardListPage/hooks/useRuleActions.ts +65 -0
  83. package/template/.claude/skills/page-skeleton/examples/StandardListPage/index.vue +91 -0
  84. package/template/.claude/skills/page-skeleton/examples/StandardListPage/style.less +49 -0
  85. package/template/.claude/skills/prototype-page-acceptance/SKILL.md +62 -0
  86. package/template/.claude/skills/theme-token-usage/SKILL.md +123 -0
  87. package/template/.claude/skills/theme-token-usage/agents/openai.yaml +4 -0
  88. package/template/.claude/skills/vue3-best-practices/SKILL.md +68 -0
  89. package/template/.claude/skills/yedit-table-usage/SKILL.md +227 -0
  90. package/template/.claude/skills/yss-api-integration/SKILL.md +12 -2
  91. package/template/.claude/skills/yss-components/SKILL.md +1 -1
  92. package/template/.claude/skills/yss-design-system/SKILL.md +1 -1
  93. package/template/.claude/skills/yss-formily/SKILL.md +233 -265
  94. package/template/.claude/skills/yss-frontend-scaffold-generator/SKILL.md +1 -1
  95. package/template/.claude/skills/yss-hook/SKILL.md +1 -1
  96. package/template/.claude/skills/yss-openapi-governance/SKILL.md +2 -2
  97. package/template/.claude/skills/yss-page-module-development/SKILL.md +12 -2
  98. package/template/.claude/skills/yss-page-module-development/references/component-map.md +34 -0
  99. package/template/.claude/skills/yss-page-module-development/references/hooks-map.md +11 -0
  100. package/template/.claude/skills/yss-page-module-development/references/utils-map.md +14 -0
  101. package/template/.claude/skills/yss-product-lifecycle/references/orchestration-contract.yaml +62 -1
  102. package/template/.claude/skills/yss-router/references/boundaries.md +1 -1
  103. package/template/.claude/skills/yss-router/references/router-contract.yaml +6 -2
  104. package/template/.claude/skills/yss-ui/SKILL.md +1 -1
  105. package/template/.claude/skills/yss-use-table-height/SKILL.md +9 -0
  106. package/template/.claude/skills/yss-use-tree-height/SKILL.md +9 -0
  107. package/template/.claude/skills/ytable-usage/SKILL.md +251 -0
  108. package/template/.claude/skills/ytree-usage/SKILL.md +132 -0
  109. package/template/.codex/skills/component-selection-imports/SKILL.md +64 -0
  110. package/template/.codex/skills/file-export-download/SKILL.md +160 -0
  111. package/template/.codex/skills/file-export-download/agents/openai.yaml +4 -0
  112. package/template/.codex/skills/formily-foundation/SKILL.md +176 -0
  113. package/template/.codex/skills/formily-foundation/references/examples.md +486 -0
  114. package/template/.codex/skills/formily-linkage-effects/SKILL.md +167 -0
  115. package/template/.codex/skills/formily-mode-slot-detail/SKILL.md +137 -0
  116. package/template/.codex/skills/formily-step-flow/SKILL.md +194 -0
  117. package/template/.codex/skills/frontend-commit/SKILL.md +118 -0
  118. package/template/.codex/skills/frontend-commit/agents/openai.yaml +7 -0
  119. package/template/.codex/skills/frontend-commit/references/scope-and-examples.md +111 -0
  120. package/template/.codex/skills/java-backend-commit/SKILL.md +121 -0
  121. package/template/.codex/skills/java-backend-commit/agents/openai.yaml +7 -0
  122. package/template/.codex/skills/java-backend-commit/references/scope-and-examples.md +118 -0
  123. package/template/.codex/skills/page-form-module/SKILL.md +168 -0
  124. package/template/.codex/skills/page-list-module/SKILL.md +137 -0
  125. package/template/.codex/skills/page-skeleton/SKILL.md +76 -0
  126. package/template/.codex/skills/page-skeleton/examples/AdvancedFormPage/constant.ts +34 -0
  127. package/template/.codex/skills/page-skeleton/examples/AdvancedFormPage/hooks/useRuleConfig.ts +75 -0
  128. package/template/.codex/skills/page-skeleton/examples/AdvancedFormPage/index.vue +107 -0
  129. package/template/.codex/skills/page-skeleton/examples/AdvancedFormPage/schemas/ruleConfigSchema.ts +256 -0
  130. package/template/.codex/skills/page-skeleton/examples/AdvancedFormPage/style.less +30 -0
  131. package/template/.codex/skills/page-skeleton/examples/StandardListPage/constant.ts +28 -0
  132. package/template/.codex/skills/page-skeleton/examples/StandardListPage/hooks/useQualityRuleList.ts +58 -0
  133. package/template/.codex/skills/page-skeleton/examples/StandardListPage/hooks/useRuleActions.ts +65 -0
  134. package/template/.codex/skills/page-skeleton/examples/StandardListPage/index.vue +91 -0
  135. package/template/.codex/skills/page-skeleton/examples/StandardListPage/style.less +49 -0
  136. package/template/.codex/skills/prototype-page-acceptance/SKILL.md +62 -0
  137. package/template/.codex/skills/theme-token-usage/SKILL.md +123 -0
  138. package/template/.codex/skills/theme-token-usage/agents/openai.yaml +4 -0
  139. package/template/.codex/skills/vue3-best-practices/SKILL.md +68 -0
  140. package/template/.codex/skills/yedit-table-usage/SKILL.md +227 -0
  141. package/template/.codex/skills/yss-api-integration/SKILL.md +12 -2
  142. package/template/.codex/skills/yss-components/SKILL.md +1 -1
  143. package/template/.codex/skills/yss-design-system/SKILL.md +1 -1
  144. package/template/.codex/skills/yss-formily/SKILL.md +233 -265
  145. package/template/.codex/skills/yss-frontend-scaffold-generator/SKILL.md +1 -1
  146. package/template/.codex/skills/yss-hook/SKILL.md +1 -1
  147. package/template/.codex/skills/yss-openapi-governance/SKILL.md +2 -2
  148. package/template/.codex/skills/yss-page-module-development/SKILL.md +12 -2
  149. package/template/.codex/skills/yss-page-module-development/references/component-map.md +34 -0
  150. package/template/.codex/skills/yss-page-module-development/references/hooks-map.md +11 -0
  151. package/template/.codex/skills/yss-page-module-development/references/utils-map.md +14 -0
  152. package/template/.codex/skills/yss-product-lifecycle/references/orchestration-contract.yaml +62 -1
  153. package/template/.codex/skills/yss-router/references/boundaries.md +1 -1
  154. package/template/.codex/skills/yss-router/references/router-contract.yaml +6 -2
  155. package/template/.codex/skills/yss-ui/SKILL.md +1 -1
  156. package/template/.codex/skills/yss-use-table-height/SKILL.md +9 -0
  157. package/template/.codex/skills/yss-use-tree-height/SKILL.md +9 -0
  158. package/template/.codex/skills/ytable-usage/SKILL.md +251 -0
  159. package/template/.codex/skills/ytree-usage/SKILL.md +132 -0
  160. package/template/.cursor/skills/.yss-skills-manifest.json +29 -0
  161. package/template/.cursor/skills/component-selection-imports/SKILL.md +64 -0
  162. package/template/.cursor/skills/file-export-download/SKILL.md +160 -0
  163. package/template/.cursor/skills/file-export-download/agents/openai.yaml +4 -0
  164. package/template/.cursor/skills/formily-foundation/SKILL.md +176 -0
  165. package/template/.cursor/skills/formily-foundation/references/examples.md +486 -0
  166. package/template/.cursor/skills/formily-linkage-effects/SKILL.md +167 -0
  167. package/template/.cursor/skills/formily-mode-slot-detail/SKILL.md +137 -0
  168. package/template/.cursor/skills/formily-step-flow/SKILL.md +194 -0
  169. package/template/.cursor/skills/frontend-commit/SKILL.md +118 -0
  170. package/template/.cursor/skills/frontend-commit/agents/openai.yaml +7 -0
  171. package/template/.cursor/skills/frontend-commit/references/scope-and-examples.md +111 -0
  172. package/template/.cursor/skills/java-backend-commit/SKILL.md +121 -0
  173. package/template/.cursor/skills/java-backend-commit/agents/openai.yaml +7 -0
  174. package/template/.cursor/skills/java-backend-commit/references/scope-and-examples.md +118 -0
  175. package/template/.cursor/skills/page-form-module/SKILL.md +168 -0
  176. package/template/.cursor/skills/page-list-module/SKILL.md +137 -0
  177. package/template/.cursor/skills/page-skeleton/SKILL.md +76 -0
  178. package/template/.cursor/skills/page-skeleton/examples/AdvancedFormPage/constant.ts +34 -0
  179. package/template/.cursor/skills/page-skeleton/examples/AdvancedFormPage/hooks/useRuleConfig.ts +75 -0
  180. package/template/.cursor/skills/page-skeleton/examples/AdvancedFormPage/index.vue +107 -0
  181. package/template/.cursor/skills/page-skeleton/examples/AdvancedFormPage/schemas/ruleConfigSchema.ts +256 -0
  182. package/template/.cursor/skills/page-skeleton/examples/AdvancedFormPage/style.less +30 -0
  183. package/template/.cursor/skills/page-skeleton/examples/StandardListPage/constant.ts +28 -0
  184. package/template/.cursor/skills/page-skeleton/examples/StandardListPage/hooks/useQualityRuleList.ts +58 -0
  185. package/template/.cursor/skills/page-skeleton/examples/StandardListPage/hooks/useRuleActions.ts +65 -0
  186. package/template/.cursor/skills/page-skeleton/examples/StandardListPage/index.vue +91 -0
  187. package/template/.cursor/skills/page-skeleton/examples/StandardListPage/style.less +49 -0
  188. package/template/.cursor/skills/prototype-page-acceptance/SKILL.md +62 -0
  189. package/template/.cursor/skills/theme-token-usage/SKILL.md +123 -0
  190. package/template/.cursor/skills/theme-token-usage/agents/openai.yaml +4 -0
  191. package/template/.cursor/skills/vue3-best-practices/SKILL.md +68 -0
  192. package/template/.cursor/skills/yedit-table-usage/SKILL.md +227 -0
  193. package/template/.cursor/skills/yss-api-integration/SKILL.md +12 -2
  194. package/template/.cursor/skills/yss-components/SKILL.md +1 -1
  195. package/template/.cursor/skills/yss-design-system/SKILL.md +1 -1
  196. package/template/.cursor/skills/yss-formily/SKILL.md +233 -265
  197. package/template/.cursor/skills/yss-frontend-scaffold-generator/SKILL.md +1 -1
  198. package/template/.cursor/skills/yss-hook/SKILL.md +1 -1
  199. package/template/.cursor/skills/yss-openapi-governance/SKILL.md +2 -2
  200. package/template/.cursor/skills/yss-page-module-development/SKILL.md +12 -2
  201. package/template/.cursor/skills/yss-page-module-development/references/component-map.md +34 -0
  202. package/template/.cursor/skills/yss-page-module-development/references/hooks-map.md +11 -0
  203. package/template/.cursor/skills/yss-page-module-development/references/utils-map.md +14 -0
  204. package/template/.cursor/skills/yss-product-lifecycle/references/orchestration-contract.yaml +62 -1
  205. package/template/.cursor/skills/yss-router/references/boundaries.md +1 -1
  206. package/template/.cursor/skills/yss-router/references/router-contract.yaml +6 -2
  207. package/template/.cursor/skills/yss-ui/SKILL.md +1 -1
  208. package/template/.cursor/skills/yss-use-table-height/SKILL.md +9 -0
  209. package/template/.cursor/skills/yss-use-tree-height/SKILL.md +9 -0
  210. package/template/.cursor/skills/ytable-usage/SKILL.md +251 -0
  211. package/template/.cursor/skills/ytree-usage/SKILL.md +132 -0
  212. package/template/.cursorrules +32 -0
  213. package/template/.hermes/skills/component-selection-imports/SKILL.md +64 -0
  214. package/template/.hermes/skills/file-export-download/SKILL.md +160 -0
  215. package/template/.hermes/skills/file-export-download/agents/openai.yaml +4 -0
  216. package/template/.hermes/skills/formily-foundation/SKILL.md +176 -0
  217. package/template/.hermes/skills/formily-foundation/references/examples.md +486 -0
  218. package/template/.hermes/skills/formily-linkage-effects/SKILL.md +167 -0
  219. package/template/.hermes/skills/formily-mode-slot-detail/SKILL.md +137 -0
  220. package/template/.hermes/skills/formily-step-flow/SKILL.md +194 -0
  221. package/template/.hermes/skills/frontend-commit/SKILL.md +118 -0
  222. package/template/.hermes/skills/frontend-commit/agents/openai.yaml +7 -0
  223. package/template/.hermes/skills/frontend-commit/references/scope-and-examples.md +111 -0
  224. package/template/.hermes/skills/java-backend-commit/SKILL.md +121 -0
  225. package/template/.hermes/skills/java-backend-commit/agents/openai.yaml +7 -0
  226. package/template/.hermes/skills/java-backend-commit/references/scope-and-examples.md +118 -0
  227. package/template/.hermes/skills/page-form-module/SKILL.md +168 -0
  228. package/template/.hermes/skills/page-list-module/SKILL.md +137 -0
  229. package/template/.hermes/skills/page-skeleton/SKILL.md +76 -0
  230. package/template/.hermes/skills/page-skeleton/examples/AdvancedFormPage/constant.ts +34 -0
  231. package/template/.hermes/skills/page-skeleton/examples/AdvancedFormPage/hooks/useRuleConfig.ts +75 -0
  232. package/template/.hermes/skills/page-skeleton/examples/AdvancedFormPage/index.vue +107 -0
  233. package/template/.hermes/skills/page-skeleton/examples/AdvancedFormPage/schemas/ruleConfigSchema.ts +256 -0
  234. package/template/.hermes/skills/page-skeleton/examples/AdvancedFormPage/style.less +30 -0
  235. package/template/.hermes/skills/page-skeleton/examples/StandardListPage/constant.ts +28 -0
  236. package/template/.hermes/skills/page-skeleton/examples/StandardListPage/hooks/useQualityRuleList.ts +58 -0
  237. package/template/.hermes/skills/page-skeleton/examples/StandardListPage/hooks/useRuleActions.ts +65 -0
  238. package/template/.hermes/skills/page-skeleton/examples/StandardListPage/index.vue +91 -0
  239. package/template/.hermes/skills/page-skeleton/examples/StandardListPage/style.less +49 -0
  240. package/template/.hermes/skills/prototype-page-acceptance/SKILL.md +62 -0
  241. package/template/.hermes/skills/theme-token-usage/SKILL.md +123 -0
  242. package/template/.hermes/skills/theme-token-usage/agents/openai.yaml +4 -0
  243. package/template/.hermes/skills/vue3-best-practices/SKILL.md +68 -0
  244. package/template/.hermes/skills/yedit-table-usage/SKILL.md +227 -0
  245. package/template/.hermes/skills/yss-api-integration/SKILL.md +12 -2
  246. package/template/.hermes/skills/yss-components/SKILL.md +1 -1
  247. package/template/.hermes/skills/yss-design-system/SKILL.md +1 -1
  248. package/template/.hermes/skills/yss-formily/SKILL.md +233 -265
  249. package/template/.hermes/skills/yss-frontend-scaffold-generator/SKILL.md +1 -1
  250. package/template/.hermes/skills/yss-hook/SKILL.md +1 -1
  251. package/template/.hermes/skills/yss-openapi-governance/SKILL.md +2 -2
  252. package/template/.hermes/skills/yss-page-module-development/SKILL.md +12 -2
  253. package/template/.hermes/skills/yss-page-module-development/references/component-map.md +34 -0
  254. package/template/.hermes/skills/yss-page-module-development/references/hooks-map.md +11 -0
  255. package/template/.hermes/skills/yss-page-module-development/references/utils-map.md +14 -0
  256. package/template/.hermes/skills/yss-product-lifecycle/references/orchestration-contract.yaml +62 -1
  257. package/template/.hermes/skills/yss-router/references/boundaries.md +1 -1
  258. package/template/.hermes/skills/yss-router/references/router-contract.yaml +6 -2
  259. package/template/.hermes/skills/yss-ui/SKILL.md +1 -1
  260. package/template/.hermes/skills/yss-use-table-height/SKILL.md +9 -0
  261. package/template/.hermes/skills/yss-use-tree-height/SKILL.md +9 -0
  262. package/template/.hermes/skills/ytable-usage/SKILL.md +251 -0
  263. package/template/.hermes/skills/ytree-usage/SKILL.md +132 -0
  264. package/template/.pi/skills/component-selection-imports/SKILL.md +64 -0
  265. package/template/.pi/skills/file-export-download/SKILL.md +160 -0
  266. package/template/.pi/skills/file-export-download/agents/openai.yaml +4 -0
  267. package/template/.pi/skills/formily-foundation/SKILL.md +176 -0
  268. package/template/.pi/skills/formily-foundation/references/examples.md +486 -0
  269. package/template/.pi/skills/formily-linkage-effects/SKILL.md +167 -0
  270. package/template/.pi/skills/formily-mode-slot-detail/SKILL.md +137 -0
  271. package/template/.pi/skills/formily-step-flow/SKILL.md +194 -0
  272. package/template/.pi/skills/frontend-commit/SKILL.md +118 -0
  273. package/template/.pi/skills/frontend-commit/agents/openai.yaml +7 -0
  274. package/template/.pi/skills/frontend-commit/references/scope-and-examples.md +111 -0
  275. package/template/.pi/skills/java-backend-commit/SKILL.md +121 -0
  276. package/template/.pi/skills/java-backend-commit/agents/openai.yaml +7 -0
  277. package/template/.pi/skills/java-backend-commit/references/scope-and-examples.md +118 -0
  278. package/template/.pi/skills/page-form-module/SKILL.md +168 -0
  279. package/template/.pi/skills/page-list-module/SKILL.md +137 -0
  280. package/template/.pi/skills/page-skeleton/SKILL.md +76 -0
  281. package/template/.pi/skills/page-skeleton/examples/AdvancedFormPage/constant.ts +34 -0
  282. package/template/.pi/skills/page-skeleton/examples/AdvancedFormPage/hooks/useRuleConfig.ts +75 -0
  283. package/template/.pi/skills/page-skeleton/examples/AdvancedFormPage/index.vue +107 -0
  284. package/template/.pi/skills/page-skeleton/examples/AdvancedFormPage/schemas/ruleConfigSchema.ts +256 -0
  285. package/template/.pi/skills/page-skeleton/examples/AdvancedFormPage/style.less +30 -0
  286. package/template/.pi/skills/page-skeleton/examples/StandardListPage/constant.ts +28 -0
  287. package/template/.pi/skills/page-skeleton/examples/StandardListPage/hooks/useQualityRuleList.ts +58 -0
  288. package/template/.pi/skills/page-skeleton/examples/StandardListPage/hooks/useRuleActions.ts +65 -0
  289. package/template/.pi/skills/page-skeleton/examples/StandardListPage/index.vue +91 -0
  290. package/template/.pi/skills/page-skeleton/examples/StandardListPage/style.less +49 -0
  291. package/template/.pi/skills/prototype-page-acceptance/SKILL.md +62 -0
  292. package/template/.pi/skills/theme-token-usage/SKILL.md +123 -0
  293. package/template/.pi/skills/theme-token-usage/agents/openai.yaml +4 -0
  294. package/template/.pi/skills/vue3-best-practices/SKILL.md +68 -0
  295. package/template/.pi/skills/yedit-table-usage/SKILL.md +227 -0
  296. package/template/.pi/skills/yss-api-integration/SKILL.md +12 -2
  297. package/template/.pi/skills/yss-components/SKILL.md +1 -1
  298. package/template/.pi/skills/yss-design-system/SKILL.md +1 -1
  299. package/template/.pi/skills/yss-formily/SKILL.md +233 -265
  300. package/template/.pi/skills/yss-frontend-scaffold-generator/SKILL.md +1 -1
  301. package/template/.pi/skills/yss-hook/SKILL.md +1 -1
  302. package/template/.pi/skills/yss-openapi-governance/SKILL.md +2 -2
  303. package/template/.pi/skills/yss-page-module-development/SKILL.md +12 -2
  304. package/template/.pi/skills/yss-page-module-development/references/component-map.md +34 -0
  305. package/template/.pi/skills/yss-page-module-development/references/hooks-map.md +11 -0
  306. package/template/.pi/skills/yss-page-module-development/references/utils-map.md +14 -0
  307. package/template/.pi/skills/yss-product-lifecycle/references/orchestration-contract.yaml +62 -1
  308. package/template/.pi/skills/yss-router/references/boundaries.md +1 -1
  309. package/template/.pi/skills/yss-router/references/router-contract.yaml +6 -2
  310. package/template/.pi/skills/yss-ui/SKILL.md +1 -1
  311. package/template/.pi/skills/yss-use-table-height/SKILL.md +9 -0
  312. package/template/.pi/skills/yss-use-tree-height/SKILL.md +9 -0
  313. package/template/.pi/skills/ytable-usage/SKILL.md +251 -0
  314. package/template/.pi/skills/ytree-usage/SKILL.md +132 -0
  315. package/template/.qoder/skills/component-selection-imports/SKILL.md +64 -0
  316. package/template/.qoder/skills/file-export-download/SKILL.md +160 -0
  317. package/template/.qoder/skills/file-export-download/agents/openai.yaml +4 -0
  318. package/template/.qoder/skills/formily-foundation/SKILL.md +176 -0
  319. package/template/.qoder/skills/formily-foundation/references/examples.md +486 -0
  320. package/template/.qoder/skills/formily-linkage-effects/SKILL.md +167 -0
  321. package/template/.qoder/skills/formily-mode-slot-detail/SKILL.md +137 -0
  322. package/template/.qoder/skills/formily-step-flow/SKILL.md +194 -0
  323. package/template/.qoder/skills/frontend-commit/SKILL.md +118 -0
  324. package/template/.qoder/skills/frontend-commit/agents/openai.yaml +7 -0
  325. package/template/.qoder/skills/frontend-commit/references/scope-and-examples.md +111 -0
  326. package/template/.qoder/skills/java-backend-commit/SKILL.md +121 -0
  327. package/template/.qoder/skills/java-backend-commit/agents/openai.yaml +7 -0
  328. package/template/.qoder/skills/java-backend-commit/references/scope-and-examples.md +118 -0
  329. package/template/.qoder/skills/page-form-module/SKILL.md +168 -0
  330. package/template/.qoder/skills/page-list-module/SKILL.md +137 -0
  331. package/template/.qoder/skills/page-skeleton/SKILL.md +76 -0
  332. package/template/.qoder/skills/page-skeleton/examples/AdvancedFormPage/constant.ts +34 -0
  333. package/template/.qoder/skills/page-skeleton/examples/AdvancedFormPage/hooks/useRuleConfig.ts +75 -0
  334. package/template/.qoder/skills/page-skeleton/examples/AdvancedFormPage/index.vue +107 -0
  335. package/template/.qoder/skills/page-skeleton/examples/AdvancedFormPage/schemas/ruleConfigSchema.ts +256 -0
  336. package/template/.qoder/skills/page-skeleton/examples/AdvancedFormPage/style.less +30 -0
  337. package/template/.qoder/skills/page-skeleton/examples/StandardListPage/constant.ts +28 -0
  338. package/template/.qoder/skills/page-skeleton/examples/StandardListPage/hooks/useQualityRuleList.ts +58 -0
  339. package/template/.qoder/skills/page-skeleton/examples/StandardListPage/hooks/useRuleActions.ts +65 -0
  340. package/template/.qoder/skills/page-skeleton/examples/StandardListPage/index.vue +91 -0
  341. package/template/.qoder/skills/page-skeleton/examples/StandardListPage/style.less +49 -0
  342. package/template/.qoder/skills/prototype-page-acceptance/SKILL.md +62 -0
  343. package/template/.qoder/skills/theme-token-usage/SKILL.md +123 -0
  344. package/template/.qoder/skills/theme-token-usage/agents/openai.yaml +4 -0
  345. package/template/.qoder/skills/vue3-best-practices/SKILL.md +68 -0
  346. package/template/.qoder/skills/yedit-table-usage/SKILL.md +227 -0
  347. package/template/.qoder/skills/yss-api-integration/SKILL.md +12 -2
  348. package/template/.qoder/skills/yss-components/SKILL.md +1 -1
  349. package/template/.qoder/skills/yss-design-system/SKILL.md +1 -1
  350. package/template/.qoder/skills/yss-formily/SKILL.md +233 -265
  351. package/template/.qoder/skills/yss-frontend-scaffold-generator/SKILL.md +1 -1
  352. package/template/.qoder/skills/yss-hook/SKILL.md +1 -1
  353. package/template/.qoder/skills/yss-openapi-governance/SKILL.md +2 -2
  354. package/template/.qoder/skills/yss-page-module-development/SKILL.md +12 -2
  355. package/template/.qoder/skills/yss-page-module-development/references/component-map.md +34 -0
  356. package/template/.qoder/skills/yss-page-module-development/references/hooks-map.md +11 -0
  357. package/template/.qoder/skills/yss-page-module-development/references/utils-map.md +14 -0
  358. package/template/.qoder/skills/yss-product-lifecycle/references/orchestration-contract.yaml +62 -1
  359. package/template/.qoder/skills/yss-router/references/boundaries.md +1 -1
  360. package/template/.qoder/skills/yss-router/references/router-contract.yaml +6 -2
  361. package/template/.qoder/skills/yss-ui/SKILL.md +1 -1
  362. package/template/.qoder/skills/yss-use-table-height/SKILL.md +9 -0
  363. package/template/.qoder/skills/yss-use-tree-height/SKILL.md +9 -0
  364. package/template/.qoder/skills/ytable-usage/SKILL.md +251 -0
  365. package/template/.qoder/skills/ytree-usage/SKILL.md +132 -0
  366. package/template/.trae/skills/.yss-skills-manifest.json +29 -0
  367. package/template/.trae/skills/component-selection-imports/SKILL.md +64 -0
  368. package/template/.trae/skills/file-export-download/SKILL.md +160 -0
  369. package/template/.trae/skills/file-export-download/agents/openai.yaml +4 -0
  370. package/template/.trae/skills/formily-foundation/SKILL.md +176 -0
  371. package/template/.trae/skills/formily-foundation/references/examples.md +486 -0
  372. package/template/.trae/skills/formily-linkage-effects/SKILL.md +167 -0
  373. package/template/.trae/skills/formily-mode-slot-detail/SKILL.md +137 -0
  374. package/template/.trae/skills/formily-step-flow/SKILL.md +194 -0
  375. package/template/.trae/skills/frontend-commit/SKILL.md +118 -0
  376. package/template/.trae/skills/frontend-commit/agents/openai.yaml +7 -0
  377. package/template/.trae/skills/frontend-commit/references/scope-and-examples.md +111 -0
  378. package/template/.trae/skills/java-backend-commit/SKILL.md +121 -0
  379. package/template/.trae/skills/java-backend-commit/agents/openai.yaml +7 -0
  380. package/template/.trae/skills/java-backend-commit/references/scope-and-examples.md +118 -0
  381. package/template/.trae/skills/page-form-module/SKILL.md +168 -0
  382. package/template/.trae/skills/page-list-module/SKILL.md +137 -0
  383. package/template/.trae/skills/page-skeleton/SKILL.md +76 -0
  384. package/template/.trae/skills/page-skeleton/examples/AdvancedFormPage/constant.ts +34 -0
  385. package/template/.trae/skills/page-skeleton/examples/AdvancedFormPage/hooks/useRuleConfig.ts +75 -0
  386. package/template/.trae/skills/page-skeleton/examples/AdvancedFormPage/index.vue +107 -0
  387. package/template/.trae/skills/page-skeleton/examples/AdvancedFormPage/schemas/ruleConfigSchema.ts +256 -0
  388. package/template/.trae/skills/page-skeleton/examples/AdvancedFormPage/style.less +30 -0
  389. package/template/.trae/skills/page-skeleton/examples/StandardListPage/constant.ts +28 -0
  390. package/template/.trae/skills/page-skeleton/examples/StandardListPage/hooks/useQualityRuleList.ts +58 -0
  391. package/template/.trae/skills/page-skeleton/examples/StandardListPage/hooks/useRuleActions.ts +65 -0
  392. package/template/.trae/skills/page-skeleton/examples/StandardListPage/index.vue +91 -0
  393. package/template/.trae/skills/page-skeleton/examples/StandardListPage/style.less +49 -0
  394. package/template/.trae/skills/prototype-page-acceptance/SKILL.md +62 -0
  395. package/template/.trae/skills/theme-token-usage/SKILL.md +123 -0
  396. package/template/.trae/skills/theme-token-usage/agents/openai.yaml +4 -0
  397. package/template/.trae/skills/vue3-best-practices/SKILL.md +68 -0
  398. package/template/.trae/skills/yedit-table-usage/SKILL.md +227 -0
  399. package/template/.trae/skills/yss-api-integration/SKILL.md +12 -2
  400. package/template/.trae/skills/yss-components/SKILL.md +1 -1
  401. package/template/.trae/skills/yss-design-system/SKILL.md +1 -1
  402. package/template/.trae/skills/yss-formily/SKILL.md +233 -265
  403. package/template/.trae/skills/yss-frontend-scaffold-generator/SKILL.md +1 -1
  404. package/template/.trae/skills/yss-hook/SKILL.md +1 -1
  405. package/template/.trae/skills/yss-openapi-governance/SKILL.md +2 -2
  406. package/template/.trae/skills/yss-page-module-development/SKILL.md +12 -2
  407. package/template/.trae/skills/yss-page-module-development/references/component-map.md +34 -0
  408. package/template/.trae/skills/yss-page-module-development/references/hooks-map.md +11 -0
  409. package/template/.trae/skills/yss-page-module-development/references/utils-map.md +14 -0
  410. package/template/.trae/skills/yss-product-lifecycle/references/orchestration-contract.yaml +62 -1
  411. package/template/.trae/skills/yss-router/references/boundaries.md +1 -1
  412. package/template/.trae/skills/yss-router/references/router-contract.yaml +6 -2
  413. package/template/.trae/skills/yss-ui/SKILL.md +1 -1
  414. package/template/.trae/skills/yss-use-table-height/SKILL.md +9 -0
  415. package/template/.trae/skills/yss-use-tree-height/SKILL.md +9 -0
  416. package/template/.trae/skills/ytable-usage/SKILL.md +251 -0
  417. package/template/.trae/skills/ytree-usage/SKILL.md +132 -0
  418. package/template/AGENTS.md +1 -13
  419. package/template/docs/adr/README.md +7 -0
  420. package/template/docs/agents/skill-migrations.md +16 -0
  421. package/template/docs/agents/skills-maintenance.md +2 -2
  422. package/template/docs/agents/yss-skill-registry.yaml +125 -25
  423. package/template/docs/process/implementation-repo-integration.md +1 -1
  424. package/template/docs/user-guide//344/272/247/345/223/201/347/240/224/345/217/221/345/205/250/347/224/237/345/221/275/345/221/250/346/234/237/346/234/200/344/275/263/345/256/236/350/267/265.md +4 -4
  425. package/template/docs/user-guide//347/224/237/345/221/275/345/221/250/346/234/237/346/234/200/344/275/263/345/256/236/350/267/265.md +1 -1
  426. package/template/scripts/lib/scenario-checks.mjs +21 -0
  427. package/template/scripts/lib/skill-governance.mjs +50 -0
  428. package/template/scripts/lib/skill-registry.mjs +82 -5
  429. package/template/scripts/lib/skill-supply-chain.mjs +5 -1
  430. package/template/scripts/verify-governance-release +7 -5
  431. package/template/scripts/verify-skill-governance +10 -0
  432. package/template/scripts/verify-template +3 -2
  433. package/template/skills-lock.json +285 -29
  434. package/template.manifest.json +30 -7
  435. package/template.snapshot.json +5 -4
  436. package/template/.agents/skills/high-fidelity-html-prototype/SKILL.md +0 -89
  437. package/template/.agents/skills/high-fidelity-html-prototype/agents/openai.yaml +0 -5
  438. package/template/.agents/skills/yss-formily/agents/openai.yaml +0 -5
  439. package/template/.agents/skills/yss-formily/references/examples.md +0 -65
  440. package/template/.claude/skills/high-fidelity-html-prototype/SKILL.md +0 -89
  441. package/template/.claude/skills/high-fidelity-html-prototype/agents/openai.yaml +0 -5
  442. package/template/.claude/skills/yss-formily/agents/openai.yaml +0 -5
  443. package/template/.claude/skills/yss-formily/references/examples.md +0 -65
  444. package/template/.codex/skills/high-fidelity-html-prototype/SKILL.md +0 -89
  445. package/template/.codex/skills/high-fidelity-html-prototype/agents/openai.yaml +0 -5
  446. package/template/.codex/skills/yss-formily/agents/openai.yaml +0 -5
  447. package/template/.codex/skills/yss-formily/references/examples.md +0 -65
  448. package/template/.cursor/skills/high-fidelity-html-prototype/SKILL.md +0 -89
  449. package/template/.cursor/skills/high-fidelity-html-prototype/agents/openai.yaml +0 -5
  450. package/template/.cursor/skills/yss-formily/agents/openai.yaml +0 -5
  451. package/template/.cursor/skills/yss-formily/references/examples.md +0 -65
  452. package/template/.hermes/skills/high-fidelity-html-prototype/SKILL.md +0 -89
  453. package/template/.hermes/skills/high-fidelity-html-prototype/agents/openai.yaml +0 -5
  454. package/template/.hermes/skills/yss-formily/agents/openai.yaml +0 -5
  455. package/template/.hermes/skills/yss-formily/references/examples.md +0 -65
  456. package/template/.pi/skills/high-fidelity-html-prototype/SKILL.md +0 -89
  457. package/template/.pi/skills/high-fidelity-html-prototype/agents/openai.yaml +0 -5
  458. package/template/.pi/skills/yss-formily/agents/openai.yaml +0 -5
  459. package/template/.pi/skills/yss-formily/references/examples.md +0 -65
  460. package/template/.qoder/skills/high-fidelity-html-prototype/SKILL.md +0 -89
  461. package/template/.qoder/skills/high-fidelity-html-prototype/agents/openai.yaml +0 -5
  462. package/template/.qoder/skills/yss-formily/agents/openai.yaml +0 -5
  463. package/template/.qoder/skills/yss-formily/references/examples.md +0 -65
  464. package/template/.trae/skills/high-fidelity-html-prototype/SKILL.md +0 -89
  465. package/template/.trae/skills/high-fidelity-html-prototype/agents/openai.yaml +0 -5
  466. package/template/.trae/skills/yss-formily/agents/openai.yaml +0 -5
  467. package/template/.trae/skills/yss-formily/references/examples.md +0 -65
  468. package/template/docs/adr/0001-product-design-prototype-entrypoint.md +0 -54
  469. package/template/docs/adr/0002-yss-project-repository-mode.md +0 -3
  470. package/template/docs/adr/0003-machine-readable-lifecycle-registry.md +0 -5
  471. package/template/docs/adr/0006-stable-lifecycle-ids-and-generated-structure.md +0 -5
  472. package/template/docs/adr/0007-lifecycle-native-work-units.md +0 -5
@@ -0,0 +1,11 @@
1
+ # YSS UI Hooks 速查
2
+
3
+ 业务页面生成时优先从 `@yss-ui/hooks` 复用 hooks。
4
+
5
+ ## 高度与异步
6
+
7
+ - `useTableHeight` 和 `useTreeHeight` 必须绑定真实容器 `ref`,并按页面的分页、工具栏、搜索区选择扣除项。
8
+ - `useLoading` 负责异步 loading 和错误边界;Orval mutator 已提示的错误不得在 `onError` 重复提示。
9
+ - `usePollingTask` 只负责轮询调度,不接管页面的 `loading/data/error`。
10
+ - `useUrlState` 用于把查询条件、分页和 Tab 状态同步到 URL。
11
+ - `useFullscreen` 用于容器、图表或编辑器全屏。
@@ -0,0 +1,14 @@
1
+ # YSS UI Utils 速查
2
+
3
+ 业务页面生成时优先从 `@yss-ui/utils` 复用工具函数,避免重复实现。
4
+
5
+ ## 常用工具
6
+
7
+ - 权限:`getAuthBtns`、`hasAuth`、`getBtnInfo`、`clearAuthInfo`。
8
+ - 复制:`copyToClipboard(text)`。
9
+ - 下载:`downloadFileStream`、`getFileNameFromContentDisposition`、`handleBlobResponse`、`downloadFileFromUrl`。
10
+ - 格式化:`formatMoney`、`formatDate`、`formatFileSize`、`formatDateRelative`。
11
+ - 主题:`applyYssTheme`、`lightenColor`、`darkenColor`。
12
+ - URL:`getUrlData`。
13
+
14
+ 接口导出下载必须读取 `file-export-download` 专项技能,优先复用统一的 Blob 响应处理,不在页面 Hook 重复解析文件名和创建下载链接。
@@ -88,6 +88,9 @@ workflow_execution_result:
88
88
  removal_target: schema_version_2
89
89
  result_values: [completed, blocked, needs-human, failed]
90
90
  required: [result_schema, work_unit, workflow_reference, result, evidence_refs, changed_artifacts, new_impacts, stale_candidates, next_route, blocking_signals]
91
+ unavailable_skill:
92
+ required: [skill, provider, fallback, resolution]
93
+ blocking_result: blocked
91
94
  blocking_signals: [drift, new_impacts, violation, missing_evidence, stale_candidates]
92
95
  completed_requires_empty: [new_impacts, stale_candidates]
93
96
  completed_requires_non_empty: [evidence_refs]
@@ -130,43 +133,101 @@ lifecycle_native_entries:
130
133
  work_unit_routes:
131
134
  work-unit.discovery-opportunity:
132
135
  native: {source: yss-product-lifecycle, skill: yss-product-lifecycle, invocation_mode: model-invoked}
136
+ primary_skill: yss-product-lifecycle
137
+ supporting_skills: [competitive-intelligence, research]
133
138
  skills: [competitive-intelligence, research]
134
139
  route_by: {market_or_competitor_fact: competitive-intelligence, technical_or_standard_fact: research, no_external_fact: yss-product-lifecycle}
140
+ applies_when: opportunity_or_external_fact_requires_validation
141
+ not_applicable_reason: no_external_fact
135
142
  work-unit.discovery-requirements:
136
143
  native: {source: yss-product-lifecycle, skill: yss-product-lifecycle, invocation_mode: model-invoked}
144
+ primary_skill: yss-product-lifecycle
145
+ supporting_skills: [grilling, domain-modeling]
137
146
  skills: [grilling, domain-modeling]
147
+ applies_when: requirements_or_domain_boundary_unclear
148
+ not_applicable_reason: requirements_already_confirmed
138
149
  work-unit.spec-synthesis:
139
150
  native: {source: yss-product-lifecycle, skill: yss-product-lifecycle, invocation_mode: model-invoked}
151
+ primary_skill: yss-product-lifecycle
152
+ supporting_skills: [domain-modeling]
140
153
  compatibility: {source: mattpocock/skills, skill: to-spec, invocation_mode: reference, formal_artifact_owner: explicit-user-entry}
141
154
  skills: [domain-modeling]
142
155
  human_gate: spec-baseline
156
+ applies_when: new_feature_or_behavior_change
157
+ not_applicable_reason: existing_frozen_spec_is_current
143
158
  work-unit.prototype-design:
144
159
  native: {source: yss-product-lifecycle, skill: yss-product-lifecycle, invocation_mode: model-invoked}
145
- skills: [yss-design-system, yss-prototype-stage, yss-antd-design, product-design:index]
160
+ primary_skill: yss-prototype-stage
161
+ supporting_skills: [prototype-review, yss-design-system, yss-antd-design, product-design:index]
162
+ skills: [prototype-review, yss-design-system, yss-prototype-stage, yss-antd-design, product-design:index]
146
163
  human_gate: prototype-confirmation
164
+ applies_when: product_design_impact
165
+ not_applicable_reason: no_ui_or_product_design_impact
147
166
  work-unit.technical-analysis:
148
167
  native: {source: yss-product-lifecycle, skill: yss-product-lifecycle, invocation_mode: model-invoked}
168
+ primary_skill: yss-router
169
+ supporting_skills: [yss-openapi-governance, yss-openapi-draft-review, codebase-design, implementation-repo-onboarding]
149
170
  skills: [yss-openapi-governance, yss-openapi-draft-review, codebase-design, implementation-repo-onboarding, yss-router]
150
171
  human_gate: openapi-freeze_if_api_impact
172
+ applies_when: technical_or_contract_impact
173
+ not_applicable_reason: no_technical_or_contract_impact
151
174
  work-unit.ticket-decomposition:
152
175
  native: {source: yss-product-lifecycle, skill: yss-product-lifecycle, invocation_mode: model-invoked}
176
+ primary_skill: yss-product-lifecycle
177
+ supporting_skills: [yss-router]
153
178
  compatibility: {source: mattpocock/skills, skill: to-tickets, invocation_mode: reference, formal_artifact_owner: explicit-user-entry}
154
179
  skills: [yss-router]
180
+ applies_when: frozen_scope_ready_for_slicing
181
+ not_applicable_reason: contract_or_scope_not_frozen
155
182
  work-unit.slice-implementation:
156
183
  native: {source: yss-product-lifecycle, skill: yss-product-lifecycle, invocation_mode: model-invoked}
184
+ primary_skill: yss-router
185
+ supporting_skills: [tdd, yss-ui, yss-page-module-development]
157
186
  compatibility: {source: mattpocock/skills, skill: implement, invocation_mode: reference, formal_artifact_owner: explicit-user-entry}
158
187
  skills: [tdd, yss-router, yss-ui, yss-page-module-development]
188
+ frontend_route:
189
+ primary_skill: yss-ui
190
+ page_orchestration_skill: yss-page-module-development
191
+ conditional_skills:
192
+ api_impact: [yss-api-integration]
193
+ formily_impact: [yss-formily, formily-foundation, formily-linkage-effects, formily-mode-slot-detail, formily-step-flow]
194
+ table_impact: [ytable-usage, yedit-table-usage]
195
+ tree_impact: [ytree-usage]
196
+ height_impact: [yss-use-table-height, yss-use-tree-height]
197
+ export_impact: [file-export-download]
198
+ theme_impact: [theme-token-usage]
199
+ not_applicable_reasons:
200
+ api_impact: no_api_impact
201
+ formily_impact: no_formily_impact
202
+ table_impact: no_table_impact
203
+ tree_impact: no_tree_impact
204
+ height_impact: no_height_impact
205
+ export_impact: no_export_impact
206
+ theme_impact: no_theme_impact
207
+ applies_when: ready_for_agent
208
+ not_applicable_reason: slice_contract_not_approved
159
209
  work-unit.frontend-implementation-verification:
160
210
  native: {source: yss-product-lifecycle, skill: yss-product-lifecycle, invocation_mode: model-invoked}
211
+ primary_skill: yss-ui
212
+ supporting_skills: [yss-design-system, code-review]
161
213
  skills: [yss-ui, yss-design-system, code-review]
162
214
  applies_when: ui_impact
215
+ not_applicable_reason: no_ui_impact
163
216
  work-unit.code-review:
164
217
  native: {source: yss-product-lifecycle, skill: code-review, invocation_mode: model-invoked}
218
+ primary_skill: code-review
219
+ supporting_skills: []
165
220
  skills: [code-review]
221
+ applies_when: implementation_candidate_exists
222
+ not_applicable_reason: no_implementation_candidate
166
223
  work-unit.release-and-retrospective:
167
224
  native: {source: yss-product-lifecycle, skill: yss-product-lifecycle, invocation_mode: model-invoked}
225
+ primary_skill: yss-product-lifecycle
226
+ supporting_skills: []
168
227
  skills: [yss-product-lifecycle]
169
228
  human_gate: merge_or_release
229
+ applies_when: release_or_stage_completion
230
+ not_applicable_reason: work_not_ready_for_release
170
231
 
171
232
  compatibility_flow_preconditions:
172
233
  to-spec:
@@ -9,7 +9,7 @@ Use this reference when multiple YSS skills seem applicable.
9
9
  - `yss-page-module-development`: Page/module workflow. Use for creating or reorganizing a page folder, deciding structure, and assembling page, hooks, schemas, and blocks.
10
10
  - `yss-components`: Component layout and visual/page composition rules. Use for YTable/YTree/YssFormily/YSplitPane usage details.
11
11
  - `yss-hook`: Request, pagination, parameter, tree-selection, and response-mapping logic in `views/**/hooks/useXxx.ts`.
12
- - `api-integration`: Orval-generated API client imports, request/response mapping, `useRequest` calling patterns, submit/list/detail flows.
12
+ - `yss-api-integration`: Orval-generated API client imports, request/response mapping, `useRequest` calling patterns, submit/list/detail flows.
13
13
  - `yss-formily`: Hand-written YssFormily schema implementation and form behavior.
14
14
  - `yss-formily-schema-generator`: Generate YssFormily schema from requirements, screenshots, mockups, Figma, or natural-language field descriptions.
15
15
  - `yss-use-table-height`: Only table available-height calculation and required container/pagination/toolbar wiring.
@@ -4,6 +4,10 @@ forbidden_statuses: [approved, ready-for-agent, completed]
4
4
  skill_aliases:
5
5
  api-integration: yss-api-integration
6
6
  microapp-commit: yss-microapp-commit
7
+ page-module-development: yss-page-module-development
8
+ yss-ui-business-page-generation: yss-page-module-development
9
+ use-table-height: yss-use-table-height
10
+ use-tree-height: yss-use-tree-height
7
11
  implementation_path_policy:
8
12
  applies_to: harness-resident-runtime-code
9
13
  project_roots:
@@ -169,8 +173,8 @@ dependency_closure:
169
173
  when_components: [yss-components]
170
174
  when_hooks: [yss-hook]
171
175
  when_form: [yss-formily]
172
- when_api: [api-integration]
173
- api-integration:
176
+ when_api: [yss-api-integration]
177
+ yss-api-integration:
174
178
  when_regeneration: [yss-openapi-governance]
175
179
 
176
180
  component_impact_values:
@@ -59,7 +59,7 @@ pnpm why vue @yss-ui/components @yss-ui/hooks ant-design-vue vxe-table
59
59
  | Formily schema、联动、校验、详情态 | `yss-formily` |
60
60
  | 表格高度 | `yss-use-table-height` |
61
61
  | 树高度 | `yss-use-tree-height` |
62
- | Orval、API、useRequest 接入 | `api-integration` |
62
+ | Orval、API、useRequest 接入 | `yss-api-integration` |
63
63
  | 视觉、token、响应式体验 | `yss-design-system` |
64
64
 
65
65
  不得引用不存在的复数 Hook skill 名称。
@@ -5,6 +5,15 @@ description: Use when working with YTable that needs responsive height, paginati
5
5
 
6
6
  # useTableHeight 表格高度计算 Hook
7
7
 
8
+ 本目录是表格高度的 canonical 技能;历史名称 `use-table-height` 仅通过注册表和 Router alias 解析。
9
+
10
+ ## YSS canonical execution rules
11
+
12
+ - 使用真实签名 `useTableHeight(containerRef, options)`,结果解构为 `tableHeight`、`isReady` 和 `recalculateHeight`。
13
+ - `YTable` 必须绑定 `:height="tableHeight"`;不要只绑定 `max-height`,也不要用固定魔法高度替代 Hook。
14
+ - `pageable`、工具栏和 `YEditTable` 添加按钮分别对应 `withPagination`、`withToolbar` 和 `withAddButton`。
15
+ - 容器使用 `flex: 1; min-height: 0; overflow: hidden`,避免观察由表格内容反向撑开的直属容器。
16
+
8
17
  ## Authoritative Docs And Boundary
9
18
 
10
19
  - YSS UI hooks documentation: `http://192.168.164.27:3200/hooks`
@@ -5,6 +5,15 @@ description: Use when working with YTree that needs responsive height, virtual s
5
5
 
6
6
  # useTreeHeight 树组件高度计算 Hook
7
7
 
8
+ 本目录是树高度的 canonical 技能;历史名称 `use-tree-height` 仅通过注册表和 Router alias 解析。
9
+
10
+ ## YSS canonical execution rules
11
+
12
+ - 使用真实签名 `useTreeHeight(containerRef, options)`,结果绑定到 `YTree` 的 `:height`。
13
+ - `filterable` 时配置 `extraOffset: YTREE_SEARCH_HEIGHT`;不得重复扣减或添加无依据偏移。
14
+ - 容器使用 `flex: 1; min-height: 0; overflow: hidden`,隐藏态切换后在可见的 `nextTick` 中调用 `recalculateHeight()`。
15
+ - 不因节点数量少而强制开启虚拟滚动;按实际可见节点阈值决定是否裁剪 DOM。
16
+
8
17
  ## Authoritative Docs And Boundary
9
18
 
10
19
  - YSS UI hooks documentation: `http://192.168.164.27:3200/hooks`
@@ -0,0 +1,251 @@
1
+ ---
2
+ name: ytable-usage
3
+ description: 指导 YSS UI 业务列表页、CRUD 表格、远程分页、操作列、气泡确认、列筛选、字典翻译、行拖拽、工具栏和自定义插槽正确使用 @yss-ui/components 的 YTable;当需要配置 YTableColumn、YTableActionConfig、pagination、filter-change 或表格实例方法时使用。
4
+ ---
5
+
6
+ # YTable 使用
7
+
8
+ ## 触发条件
9
+
10
+ - 生成或修改业务列表、CRUD 表格、远程分页、操作列、列筛选、工具栏或行拖拽。
11
+ - 需要配置 `YTableColumn`、`YTableActionConfig`、分页状态或表格实例方法。
12
+
13
+ ## 不适用场景
14
+
15
+ - 可编辑表格是核心需求:使用 `../yedit-table-usage/SKILL.md`。
16
+ - 页面只有短小静态数据且不需要表格交互。
17
+
18
+ ## 实施流程
19
+
20
+ 1. 当前会话可用 yss-ui MCP 时,先用 `get_component_docs` 查询 `YTable` 的 Props、Events、Slots、Types 与实例方法;需要远程分页、筛选、操作列、拖拽或工具栏时,再用 `get_demo` 获取对应官方 Demo。
21
+ 2. MCP 工具不可用、调用失败或用 `search_docs/list_components` 校正后仍无结果时,才读取最新 `llms-full.txt`;若文档与当前项目依赖版本不一致,用当前源码和导出核验。
22
+ 3. 把远程数据、`loading`、分页映射、API 调用和事件处理放入 Hook;把列定义和纯配置放入 `constant.ts`。
23
+ 4. 在模板中组合 `data/columns/loading/pagination`,并根据真实开启的工具栏和分页配置高度 Hook。
24
+ 5. 完成后核对删除确认、远程筛选、分页字段映射和 API 错误处理边界。
25
+
26
+ ## 硬约束(禁止/必须)
27
+
28
+ - 必须从 `@yss-ui/components` 导入 `YTable`、`YTableColumn`、`YTableActionConfig` 等真实导出,不使用 `a-table` 实现业务主表格。
29
+ - 远程分页状态使用 `current/pageSize/total/remote`,显式设置 `remote: true`;后端 `pageIndex/pageSize/totalCount` 只在 Hook 中映射。
30
+ - 开启内置分页时传 `pageable`,受控更新使用 `v-model:pagination`,请求时机使用 `@page-change="handlePageChange"`。
31
+ - `page-change` 事件参数固定为 `{ current: number, pageSize: number }`;回调必须读取 `current`,禁止写成组件不会派发的 `currentPage`。
32
+ - YTable 没有 `request` 或 `searchParams` Props;远程查询由业务 Hook 管理。`refresh()` 是真实实例方法,内部调用 vxe-table `updateData()` 刷新当前表格数据,不等于重新调用后端接口。
33
+ - 行键使用 `:row-config="{ keyField: 'id', useKey: true }"`,不臆造 `row-key` Prop。
34
+ - 新增、导入、批量操作等主按钮直接放入 `#toolbar-right` 或 `#toolbar-left` 插槽即可自动渲染工具栏;**无需配置 `:toolbar-config="{ custom: true }"`**,避免无端展示列设置图标;**仅在业务明确需要列设置时才传入 `:toolbar-config="{ custom: true }"`**。
35
+ - 删除、启停、发布等危险操作使用 `actionConfig.buttons[].isConfirm = true`,不默认使用 `Modal.confirm`。
36
+ - 列配置超过 10 行时放入 `constant.ts`;需要调用组件 Hook 的操作配置使用工厂函数注入回调,禁止在 `constant.ts` 直接引用组件局部的 `openEdit/deleteItem`。
37
+ - 远程筛选必须提供稳定 `filters`,设置 `filterMethod: () => true` 禁用本地二次过滤,并监听 `filter-change`。
38
+ - 自适应滚动列表绑定 `:height="tableHeight"`;`pageable`、工具栏分别对应 `withPagination: true`、`withToolbar: true`。纯短表不强制引入高度 Hook。
39
+ - `mutator.ts` 已对网络错误和 `success === false` 统一 `message.error` 并 reject。API Hook 不再检查 `success === false`,不在 `else/catch` 重复 `message.error`;用 `finally` 恢复 loading,让异常继续中断流程。
40
+
41
+ ## 标准代码骨架
42
+
43
+ ```typescript
44
+ import type { YTableActionConfig, YTableColumn } from '@yss-ui/components';
45
+
46
+ /** 列表行数据。 */
47
+ export interface ItemRow {
48
+ id: string;
49
+ name: string;
50
+ status: string;
51
+ }
52
+
53
+ /** 状态字典。 */
54
+ export const STATUS_OPTIONS = [
55
+ { label: '启用', value: '1' },
56
+ { label: '停用', value: '0' },
57
+ ];
58
+
59
+ /** 列表固定列配置。 */
60
+ export const TABLE_COLUMNS: YTableColumn[] = [
61
+ { type: 'seq', title: '序号', width: 70 },
62
+ { field: 'name', title: '名称', minWidth: 180 },
63
+ { field: 'status', title: '状态', width: 120, isTransform: true },
64
+ { type: 'action', title: '操作', width: 180 },
65
+ ];
66
+
67
+ /** 按组件 Hook 提供的回调创建操作列配置。 */
68
+ export const createActionConfig = (handlers: {
69
+ onEdit: (row: ItemRow) => void;
70
+ onDelete: (row: ItemRow) => Promise<void>;
71
+ }): YTableActionConfig => ({
72
+ width: 180,
73
+ fixed: 'right',
74
+ buttons: [
75
+ { value: 'edit', label: '编辑', type: 'link', click: ({ row }) => handlers.onEdit(row) },
76
+ {
77
+ value: 'delete',
78
+ label: '删除',
79
+ type: 'link',
80
+ isConfirm: true,
81
+ confirmProps: { title: '确认删除该数据吗?', okText: '确定', cancelText: '取消' },
82
+ click: ({ row }) => handlers.onDelete(row),
83
+ },
84
+ ],
85
+ });
86
+ ```
87
+
88
+ ## 远程分页 Hook 关键模式
89
+
90
+ ```typescript
91
+ import { ref } from 'vue';
92
+ import type { YTablePagination } from '@yss-ui/components';
93
+ import type { ItemRow } from '../constant';
94
+
95
+ /** 列表 API 依赖,由当前项目的 Orval 函数适配。 */
96
+ export interface ItemListApi {
97
+ queryPage: (params: { pageIndex: number; pageSize: number }) => Promise<{
98
+ list?: ItemRow[];
99
+ totalCount?: number;
100
+ }>;
101
+ deleteItem: (params: { id: string }) => Promise<unknown>;
102
+ }
103
+
104
+ /** 管理 YTable 远程分页和删除刷新。 */
105
+ export const useItemList = (api: ItemListApi) => {
106
+ const dataList = ref<ItemRow[]>([]);
107
+ const loading = ref(false);
108
+ const pagination = ref<YTablePagination>({ current: 1, pageSize: 20, total: 0, remote: true });
109
+
110
+ /** 查询当前页;错误提示由 mutator 统一处理。 */
111
+ const loadList = async () => {
112
+ loading.value = true;
113
+ try {
114
+ const result = await api.queryPage({
115
+ pageIndex: pagination.value.current,
116
+ pageSize: pagination.value.pageSize,
117
+ });
118
+ dataList.value = result.list ?? [];
119
+ pagination.value = { ...pagination.value, total: result.totalCount ?? 0 };
120
+ } finally {
121
+ loading.value = false;
122
+ }
123
+ };
124
+
125
+ /** 同步 YTable 分页状态并重新查询。 */
126
+ const handlePageChange = async ({ current, pageSize }: { current: number; pageSize: number }) => {
127
+ pagination.value = { ...pagination.value, current, pageSize };
128
+ await loadList();
129
+ };
130
+
131
+ /** 删除后刷新列表;不重复弹出 API 错误。 */
132
+ const handleDelete = async (row: ItemRow) => {
133
+ await api.deleteItem({ id: row.id });
134
+ await loadList();
135
+ };
136
+
137
+ return { dataList, loading, pagination, loadList, handlePageChange, handleDelete };
138
+ };
139
+ ```
140
+
141
+ ```vue
142
+ <script setup lang="ts">
143
+ import { onMounted, ref } from 'vue';
144
+ import { YButton, YTable } from '@yss-ui/components';
145
+ import { useTableHeight } from '@yss-ui/hooks';
146
+ import { createActionConfig, STATUS_OPTIONS, TABLE_COLUMNS, type ItemRow } from './constant';
147
+ import { useItemList, type ItemListApi } from './hooks/useItemList';
148
+
149
+ /** 列表实例的 API 依赖。 */
150
+ interface Props {
151
+ api: ItemListApi;
152
+ }
153
+
154
+ const props = defineProps<Props>();
155
+ const emit = defineEmits<{
156
+ create: [];
157
+ edit: [row: ItemRow];
158
+ }>();
159
+ const tableAreaRef = ref<HTMLDivElement>();
160
+ const { tableHeight } = useTableHeight(tableAreaRef, { withPagination: true, withToolbar: true });
161
+ const { dataList, loading, pagination, loadList, handlePageChange, handleDelete } = useItemList(props.api);
162
+ const actionConfig = createActionConfig({
163
+ onEdit: row => emit('edit', row),
164
+ onDelete: handleDelete,
165
+ });
166
+
167
+ onMounted(loadList);
168
+ </script>
169
+
170
+ <template>
171
+ <div ref="tableAreaRef" class="table-area">
172
+ <YTable
173
+ :data="dataList"
174
+ :columns="TABLE_COLUMNS"
175
+ :action-config="actionConfig"
176
+ :loading="loading"
177
+ :options-map="{ status: STATUS_OPTIONS }"
178
+ :row-config="{ keyField: 'id', useKey: true }"
179
+ :height="tableHeight"
180
+ pageable
181
+ v-model:pagination="pagination"
182
+ @page-change="handlePageChange"
183
+ >
184
+ <template #toolbar-right>
185
+ <YButton type="primary" @click="emit('create')">新增</YButton>
186
+ </template>
187
+ </YTable>
188
+ </div>
189
+ </template>
190
+
191
+ <style scoped lang="less">
192
+ @import './style.less';
193
+ </style>
194
+ ```
195
+
196
+ ```less
197
+ /* style.less */
198
+ .table-area {
199
+ height: 100%;
200
+ min-height: 0;
201
+ overflow: hidden;
202
+ }
203
+ ```
204
+
205
+ ## 表格多选与批量操作标准模式
206
+
207
+ 当业务需要 Checkbox 多选与批量操作(如批量删除、批量导出、批量启用)时,遵循以下规范:
208
+
209
+ 1. **列配置**:首列必须声明 `{ type: 'checkbox', width: 50, fixed: 'left', align: 'center' }`。
210
+ 2. **行唯一键**:必须显式指定 `:row-config="{ keyField: 'id', useKey: true }"`(`keyField` 与业务主键如 `userCode` 对齐)。
211
+ 3. **受控双向绑定**:推荐优先使用 `v-model:selected-row-keys="selectedRowKeys"` 或 `v-model:selected-rows="selectedRows"`,或者统一监听 `@selection-change`。
212
+ 4. **批量操作按钮**:放在 `#toolbar-right`,并配置 `:disabled="selectedRowKeys.length === 0"`。
213
+ 5. **清空选中态**:批量操作成功后,直接重置 `selectedRowKeys.value = []` 或调用 `tableRef.value.clearSelection()`。
214
+
215
+ ```vue
216
+ <YTable
217
+ ref="tableRef"
218
+ v-model:selected-row-keys="selectedRowKeys"
219
+ :row-config="{ keyField: 'id', useKey: true }"
220
+ :data="dataList"
221
+ :columns="TABLE_COLUMNS"
222
+ pageable
223
+ v-model:pagination="pagination"
224
+ @page-change="handlePageChange"
225
+ >
226
+ <template #toolbar-right>
227
+ <YButton :disabled="selectedRowKeys.length === 0" @click="handleBatchDelete">批量删除</YButton>
228
+ </template>
229
+ </YTable>
230
+ ```
231
+
232
+ ## 插槽与实例边界
233
+
234
+ - 优先使用 kebab-case:单元格 `#<field>`、表头 `#<field>-header`、筛选 `#<field>-filter`、工具栏 `#toolbar-left/#toolbar-right`、展开行 `#expand-row`、分组表头 `#group-header`、更多图标 `#action-more-icon`。
235
+ - `getTableInstance()`、`refresh()`、`recalculate()`、`clearSelection()`、`getSelectedRows()`、`getSelectedRowKeys()`、`setSelection()`、`getPaginationInstance()` 是真实暴露方法;只在对应语义下使用。
236
+
237
+ ## 交付检查清单
238
+
239
+ - [ ] 分页状态和 `page-change` 参数均使用 `current/pageSize`,未使用 `currentPage`;`filter-change` 与 YTable 真实 API 一致。
240
+ - [ ] 多选列已配置 `type: 'checkbox'`,已设置 `:row-config="{ keyField: 'xxx', useKey: true }"`,批量按钮绑定了 `selectedRowKeys.length === 0` 禁用。
241
+ - [ ] 批量操作成功后已重置 `selectedRowKeys` 并调用 `tableRef.clearSelection()`。
242
+ - [ ] 未使用虚构 `request/searchParams/row-key` Props,也未把 `refresh()` 当成远程请求。
243
+ - [ ] 工具栏、字典翻译、操作确认与高度偏移均与实际开关一致。
244
+ - [ ] API Hook 没有 `success === false` 分支或重复 `message.error`。
245
+
246
+ ## 失败兜底策略
247
+
248
+ - 分页字段混乱时,在 Hook 中分离 YTable 状态和后端参数,不直接把 `pageIndex/totalCount` 绑到组件。
249
+ - 操作过多时使用 `displayLimit` 和更多菜单;远程刷新失效时回到业务 `loadList()`,不把实例 `refresh()` 当成接口请求。
250
+ - API 失败后只在 `finally` 恢复本地 loading,让 mutator 的 reject 继续中断删除后刷新等后续流程。
251
+
@@ -0,0 +1,132 @@
1
+ ---
2
+ name: ytree-usage
3
+ description: 指导 YSS UI 左树右表、组织树、分类树、目录树和节点管理页使用 @yss-ui/components 的 YTree,覆盖 fieldNames 字段映射、搜索过滤、受控选中、节点动作、删除确认、虚拟滚动和自适应高度;当生成或修改树形筛选、左树右表、树搜索或树节点操作时使用。
4
+ ---
5
+
6
+ # YTree 使用
7
+
8
+ ## 触发条件
9
+
10
+ - 生成或修改左树右表、组织树、分类树、目录树、树搜索或树节点操作。
11
+ - 需要配置 `fieldNames`、受控选中、`YTreeActionItem` 或树区域自适应高度。
12
+
13
+ ## 不适用场景
14
+
15
+ - 树数据只用于表单 TreeSelect 字段:使用 `YFormily` 或对应表单规范。
16
+ - 页面只有普通列表而没有层级筛选:使用 `../ytable-usage/SKILL.md`。
17
+
18
+ ## 实施流程
19
+
20
+ 1. 当前会话可用 yss-ui MCP 时,先用 `get_component_docs` 查询 `YTree` 的 Props、Slots、Events 和 `YTreeActionItem`;需要搜索、节点动作、受控选中或左树右表时,再用 `get_demo` 获取对应官方 Demo。
21
+ 2. MCP 工具不可用、调用失败或用 `search_docs/list_components` 校正后仍无结果时,才读取最新 `llms-full.txt`;若文档与当前项目依赖版本不一致,用当前源码和导出核验。
22
+ 3. 确定树数据的 title/key/children 字段、受控状态和选中后的业务联动。
23
+ 4. 按容器布局配置 `useTreeHeight`,再添加搜索和节点动作。
24
+ 5. 若包含删除,单独完成气泡确认链路;不把 `danger` 颜色当成二次确认。
25
+
26
+ ## 硬约束(禁止/必须)
27
+
28
+ - 从 `@yss-ui/components` 导入 `YTree`、`YTreeActionItem` 等真实导出;高度使用 `@yss-ui/hooks` 的 `useTreeHeight`。
29
+ - 数据字段不一致时配置 `fieldNames`,不为了改名重复递归复制树数据。
30
+ - 搜索使用 `filterable + v-model:searchValue`;受控选中使用 `v-model:selectedKeys`。
31
+ - 普通节点菜单使用 `showActions + getNodeActions`,并监听 `@action`。`YTreeActionItem` 只支持 `key/label/icon/disabled/danger`,禁止臆造 `isConfirm/click` 等字段。
32
+ - `danger: true` 只改变危险项视觉,不会弹出确认框。删除必须放在节点附近的 `#node-suffix` 或当前选中节点操作区,用 Ant Design Vue `Popconfirm` 的 `@confirm` 调用接口;不使用居中 `Modal.confirm`。
33
+ - 树区域需要滚动时绑定 `:height="treeHeight"`,不默认添加 `:virtual="true"`。只有展开后可见扁平节点数 `* itemHeight > height` 时才会实际裁剪 DOM。
34
+ - 使用 YTree 内置搜索时,高度 Hook 通过 `extraOffset: YTREE_SEARCH_HEIGHT` 扣除 48px;不再叠加无依据的魔法数。
35
+ - 左树右表优先组合 `YSplitPane + YCard + YTree + YTable`;切换节点时同步查询条件并把右表分页重置为第 1 页。
36
+ - 节点删除 API 的错误由 `mutator.ts` 统一提示并 reject;不在 `else/catch` 重复 `message.error`。
37
+
38
+ ## 标准代码骨架
39
+
40
+ ```vue
41
+ <script setup lang="ts">
42
+ import { ref } from 'vue';
43
+ import { YTree, type YTreeActionItem } from '@yss-ui/components';
44
+ import { useTreeHeight, YTREE_SEARCH_HEIGHT } from '@yss-ui/hooks';
45
+
46
+ /** 树节点数据。 */
47
+ interface TreeNode {
48
+ id: string;
49
+ name: string;
50
+ children?: TreeNode[];
51
+ }
52
+
53
+ const emit = defineEmits<{
54
+ create: [node: TreeNode];
55
+ edit: [node: TreeNode];
56
+ }>();
57
+ const treeAreaRef = ref<HTMLDivElement>();
58
+ const treeData = ref<TreeNode[]>([]);
59
+ const searchValue = ref('');
60
+ const selectedKeys = ref<Array<string | number>>([]);
61
+ const { treeHeight } = useTreeHeight(treeAreaRef, {
62
+ extraOffset: YTREE_SEARCH_HEIGHT,
63
+ });
64
+
65
+ /** 生成当前节点的非危险操作。 */
66
+ const getNodeActions = (): YTreeActionItem[] => [
67
+ { key: 'add', label: '新增子节点' },
68
+ { key: 'edit', label: '编辑' },
69
+ ];
70
+
71
+ /** 处理 YTree 动作事件。 */
72
+ const handleTreeAction = ({ key, node }: { key: string; node: TreeNode }) => {
73
+ if (key === 'add') emit('create', node);
74
+ if (key === 'edit') emit('edit', node);
75
+ };
76
+ </script>
77
+
78
+ <template>
79
+ <div ref="treeAreaRef" class="tree-area">
80
+ <YTree
81
+ :height="treeHeight"
82
+ :tree-data="treeData"
83
+ :field-names="{ title: 'name', key: 'id', children: 'children' }"
84
+ filterable
85
+ show-actions
86
+ v-model:searchValue="searchValue"
87
+ v-model:selectedKeys="selectedKeys"
88
+ :get-node-actions="getNodeActions"
89
+ @action="handleTreeAction"
90
+ />
91
+ </div>
92
+ </template>
93
+
94
+ <style scoped lang="less">
95
+ @import './style.less';
96
+ </style>
97
+ ```
98
+
99
+ ```less
100
+ /* style.less */
101
+ .tree-area {
102
+ flex: 1;
103
+ min-height: 0;
104
+ overflow: hidden;
105
+ }
106
+ ```
107
+
108
+ ## 删除确认边界
109
+
110
+ ```vue
111
+ <template #node-suffix="{ node }">
112
+ <Popconfirm title="确认删除该节点吗?" ok-text="确定" cancel-text="取消" @confirm="handleDelete(node)">
113
+ <YButton type="link" @click.stop>删除</YButton>
114
+ </Popconfirm>
115
+ </template>
116
+ ```
117
+
118
+ `Popconfirm` 从 `ant-design-vue` 导入,`YButton` 从 `@yss-ui/components` 导入。如果每个节点都展示删除会过密,把同样的 `Popconfirm` 放到选中节点的页面工具栏。
119
+
120
+ ## 交付检查清单
121
+
122
+ - [ ] `fieldNames`、`searchValue`、`selectedKeys`、`action` 与真实 API 一致。
123
+ - [ ] 节点动作项未出现虚构字段,删除不会点菜单后立即执行。
124
+ - [ ] 高度偏移与内置搜索实际开关一致,没有多扣魔法数。
125
+ - [ ] 左树选中后,右表查询条件和分页重置闭环清晰。
126
+
127
+ ## 失败兜底策略
128
+
129
+ - 节点字段不统一时先修正 `fieldNames`,不复制整棵树换键。
130
+ - 点击删除立即调用 API 时,移出节点动作菜单,改为节点附近或页面操作区 `Popconfirm`。
131
+ - 传入 `height` 但节点未裁剪时,先核对展开后可见节点数、`itemHeight` 和阈值,不盲目强制 `virtual=true`。
132
+ - 节点 API 失败后让 mutator reject 中断右表刷新等后续流程,不重复错误提示。
@@ -10,7 +10,7 @@
10
10
  - `repository_mode: project-instance`:按产品研发生命周期分诊任务。
11
11
  - 文件缺失、schema 版本不支持或模式值非法时,停止路由并执行迁移检查;不根据目录、Git 远程或占位符猜测身份。
12
12
 
13
- 仓库身份契约见 `docs/adr/0002-yss-project-repository-mode.md`。
13
+ 仓库身份契约由根目录 `yss-project.yaml` 和本文件共同声明。
14
14
 
15
15
  ## 2. 单一事实来源
16
16
 
@@ -108,15 +108,3 @@ README、用户指南、根目录 `CLAUDE.md` 和其他说明文档只引用或
108
108
  ## 12. 测试质量基线
109
109
 
110
110
  模板推荐值为 Domain / Application `>= 90%`、API `>= 80%`、前端组件 `>= 75%`、已明确的关键流程 `100% E2E`。只有项目实例在测试策略中明确采纳或覆盖后才构成 CI 门禁;未定义关键流程清单时,不声称其 E2E 覆盖率达到 100%。
111
-
112
- ## Cursor Cloud specific instructions
113
-
114
- 本仓库是 `template-source` Harness / 研发管理仓库,没有前端 / 后端运行时应用;可运行、可测试的表面只有 Node 工具链与治理校验脚本。
115
-
116
- - 依赖与工具链:Node `>=22 <27`(`.nvmrc` 固定 22);`pnpm` 通过 `packageManager` 字段由 corepack 自动切换到 `10.15.0`,无需手工切换。Node 依赖只装在 `.template-source/tooling/node`,仓库根没有 `package.json`。本仓 wiki-root 为 `.template-source/wiki`。
117
- - 测试:`pnpm --dir .template-source/tooling/node test`(`node --test`,共 16 个用例)。
118
- - 构建 / lint:`pnpm --dir .template-source/tooling/node build:vendor` 与 `check:vendor` 维护 `scripts/vendor/*.mjs`;顶层 lint 是 `verify-template` 内对所有脚本执行的 `node --check`。
119
- - 完整发布门禁(相当于"运行应用"):`scripts/verify-template`,成功输出 `模板发布校验通过`。它串联证据索引、`pnpm test`、`check:vendor` 和全部 `scripts/verify-*` 场景校验。
120
- - 非显然的坑:`scripts/verify-lifecycle-registry`(及其对应测试 `Node lifecycle registry verifier ...`)会 shell out 到 `python3` 并 `import jsonschema` 做 JSON Schema 校验。缺少该 Python 模块时测试会以 `ModuleNotFoundError: No module named 'jsonschema'` 失败,而不是代码问题;update script 已负责 `pip3 install jsonschema`。
121
- - `pnpm install` 输出的 `Ignored build scripts: esbuild` 警告可忽略:esbuild 0.28.2 在本平台自带二进制,`build:vendor` / `check:vendor` 无需 `pnpm approve-builds`。
122
- - 常用只读入口:`scripts/repository-mode`(返回仓库身份)、`scripts/generate-lifecycle-artifacts`(从 `docs/process/lifecycle-registry.yaml` 派生产物,输出应无 diff)、`scripts/export-yss-skills --output <dir>`(导出公开技能)。
@@ -0,0 +1,7 @@
1
+ # 产品架构决策
2
+
3
+ 本目录只记录当前项目自身的架构决策,不承载 `yss-spec-project-template` 模板源仓库的治理决策。
4
+
5
+ 创建 ADR 时使用 [`docs/templates/adr-template.md`](../templates/adr-template.md),并为每条决策补充状态、背景、取舍、后果和相关资产。
6
+
7
+ 模板源仓库的 ADR 保存在 `.template-source/adr/`,不会随 `create-yss-spec` 进入 `project-instance`。
@@ -0,0 +1,16 @@
1
+ # 技能迁移说明
2
+
3
+ 本文记录已退役技能入口的迁移路径。退役技能不保留物理目录、投影或 lock 条目;本文件是历史名称的唯一持久兼容说明。
4
+
5
+ ## high-fidelity-html-prototype
6
+
7
+ `high-fidelity-html-prototype` 已退役,不再作为 Router alias、默认发现入口或独立物理技能存在。
8
+
9
+ 迁移到:
10
+
11
+ - 阶段合同:`yss-prototype-stage`
12
+ - Codex 产品设计主入口:`product-design:index`
13
+ - Ant Design v6 事实与 CLI 证据:`yss-antd-design`
14
+ - 独立低保真评审:`prototype-review`
15
+
16
+ 迁移时保留原型评审记录、AntD CLI 验证、浏览器验证和用户确认,并由 `yss-product-lifecycle` 裁决 `gate.prototype-reviewed`、`gate.prototype-verified` 和 `gate.user-confirmation`。不得创建同名兼容目录。