@rt-tools/agent-kit 0.37.0 → 0.38.0

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 (436) hide show
  1. package/README.md +5 -5
  2. package/assets/checks/action-of.mjs +154 -0
  3. package/assets/checks/board-pull-state.github.mjs +82 -13
  4. package/assets/checks/board-runs.github.mjs +40 -5
  5. package/assets/checks/board.github.mjs +1 -1
  6. package/assets/checks/check-board.github.mjs +58 -19
  7. package/assets/checks/check-specs.mjs +2 -2
  8. package/assets/checks/check-state-next.mjs +22 -10
  9. package/assets/checks/check-turn-map.mjs +26 -6
  10. package/assets/checks/check-work-steps.mjs +4 -173
  11. package/assets/checks/decide.mjs +285 -0
  12. package/assets/checks/decision-table.json +21365 -0
  13. package/assets/checks/decision-table.mjs +495 -0
  14. package/assets/checks/epic-table.github.mjs +4 -3
  15. package/assets/checks/epic-window.mjs +98 -0
  16. package/assets/checks/flow-condition.mjs +64 -0
  17. package/assets/checks/flow-data.mjs +136 -0
  18. package/assets/checks/flow-forecast.mjs +330 -0
  19. package/assets/checks/flow-guard-run.mjs +90 -0
  20. package/assets/checks/flow-guard.mjs +294 -0
  21. package/assets/checks/flow-model.mjs +271 -0
  22. package/assets/checks/flow-override.mjs +130 -0
  23. package/assets/checks/flow-plan.mjs +206 -0
  24. package/assets/checks/flow-scaffold.mjs +224 -0
  25. package/assets/checks/flow-step.mjs +365 -0
  26. package/assets/checks/flow-sync.mjs +296 -0
  27. package/assets/checks/flow-syntax.mjs +292 -0
  28. package/assets/checks/flow-verdict.mjs +112 -0
  29. package/assets/checks/lib-common.mjs +10 -2
  30. package/assets/checks/lib-domains.mjs +1 -1
  31. package/assets/checks/lib-manifests.mjs +34 -2
  32. package/assets/checks/merge-read.mjs +239 -0
  33. package/assets/checks/owner-nudges.mjs +389 -0
  34. package/assets/checks/push-inputs.mjs +444 -0
  35. package/assets/checks/push-trace.mjs +108 -0
  36. package/assets/checks/record-count.mjs +410 -0
  37. package/assets/checks/record-recount.mjs +187 -0
  38. package/assets/checks/record-turn.mjs +155 -0
  39. package/assets/checks/rt-kit-checks.config.mjs +17 -2
  40. package/assets/checks/spec-anchors.mjs +4 -4
  41. package/assets/checks/spec-contract.mjs +5 -5
  42. package/assets/checks/task-flow-script.mjs +292 -0
  43. package/assets/checks/tree-assignment.mjs +26 -7
  44. package/assets/checks/work-result.mjs +281 -0
  45. package/assets/checks/work-steps-lib.mjs +205 -0
  46. package/assets/commands/next-session.md +3 -1
  47. package/assets/commands/night.md +28 -18
  48. package/assets/defaults/gate-map.sh +39 -12
  49. package/assets/defaults/merges.sh +48 -0
  50. package/assets/defaults/project.sh +43 -13
  51. package/assets/defaults/push.sh +23 -0
  52. package/assets/defaults/turn-map.md +24 -21
  53. package/assets/docs/GLOSSARY.md +6 -2
  54. package/assets/hooks/ask-judge.md +65 -0
  55. package/assets/hooks/browser-guard-device-id.sh +11 -9
  56. package/assets/hooks/browser-guard-no-asking.sh +12 -6
  57. package/assets/hooks/browser-guard-no-listing.sh +13 -7
  58. package/assets/hooks/browser-guard-no-other-drivers.sh +25 -17
  59. package/assets/hooks/browser-guard-require-select.sh +15 -15
  60. package/assets/hooks/commit-msg.sh +13 -3
  61. package/assets/hooks/conscience-guard.sh +9 -25
  62. package/assets/hooks/decide.sh +141 -0
  63. package/assets/hooks/deny-tail.sh +16 -11
  64. package/assets/hooks/dev-server-guard.sh +27 -20
  65. package/assets/hooks/dispatch.sh +47 -4
  66. package/assets/hooks/docs-guard.sh +31 -200
  67. package/assets/hooks/end-conversation-guard.sh +12 -21
  68. package/assets/hooks/epic-stop-guard.sh +54 -105
  69. package/assets/hooks/exam-guard.sh +32 -65
  70. package/assets/hooks/facts-docs.sh +221 -0
  71. package/assets/hooks/facts-flow.sh +173 -0
  72. package/assets/hooks/facts.sh +308 -0
  73. package/assets/hooks/flow-step-guard.sh +93 -0
  74. package/assets/hooks/git-guard-delivery-body.sh +4 -4
  75. package/assets/hooks/git-guard-delivery-conflict.sh +16 -10
  76. package/assets/hooks/git-guard-delivery-draft.sh +3 -3
  77. package/assets/hooks/git-guard-delivery-epic.sh +18 -9
  78. package/assets/hooks/git-guard-delivery-folder.sh +32 -7
  79. package/assets/hooks/git-guard-delivery-merge.sh +2 -2
  80. package/assets/hooks/git-guard-delivery-merged.sh +12 -1
  81. package/assets/hooks/git-guard-delivery-pipeline.sh +1 -1
  82. package/assets/hooks/git-guard-delivery-rerun.sh +32 -0
  83. package/assets/hooks/git-guard-delivery-signature.sh +82 -45
  84. package/assets/hooks/git-guard-delivery-task.sh +47 -0
  85. package/assets/hooks/git-guard-delivery.sh +112 -101
  86. package/assets/hooks/git-guard-discard.sh +8 -18
  87. package/assets/hooks/git-guard-main.sh +13 -19
  88. package/assets/hooks/git-guard-no-verify.sh +56 -16
  89. package/assets/hooks/git-guard-push-ahead.sh +46 -5
  90. package/assets/hooks/git-guard-push-marks.sh +227 -31
  91. package/assets/hooks/git-guard-push-tests.sh +51 -53
  92. package/assets/hooks/git-guard-tree-assignment.sh +7 -4
  93. package/assets/hooks/guard-note.sh +8 -6
  94. package/assets/hooks/handoff-entry-guard.sh +20 -39
  95. package/assets/hooks/handoff-write.sh +3 -1
  96. package/assets/hooks/hook-input.sh +0 -41
  97. package/assets/hooks/metric-marks.sh +19 -7
  98. package/assets/hooks/observe.sh +1 -1
  99. package/assets/hooks/override-write-guard.sh +27 -9
  100. package/assets/hooks/pre-push.sh +20 -10
  101. package/assets/hooks/prose-style-guard.sh +6 -19
  102. package/assets/hooks/pull-merges.sh +76 -0
  103. package/assets/hooks/push-set.sh +39 -7
  104. package/assets/hooks/qa-dataid-guard.sh +7 -17
  105. package/assets/hooks/record-turn.sh +52 -0
  106. package/assets/hooks/rerun-guard.sh +11 -16
  107. package/assets/hooks/reuse-first-guard.sh +7 -21
  108. package/assets/hooks/role-calls.sh +25 -3
  109. package/assets/hooks/rule-source-guard.sh +54 -21
  110. package/assets/hooks/skill-gate-rearm.sh +18 -5
  111. package/assets/hooks/skill-gate.sh +156 -20
  112. package/assets/hooks/skill-loaded.sh +18 -3
  113. package/assets/hooks/sql-guard-target.sh +2 -2
  114. package/assets/hooks/sql-guard-write.sh +12 -12
  115. package/assets/hooks/sql-guard.sh +58 -16
  116. package/assets/hooks/task-context-load.sh +3 -1
  117. package/assets/hooks/task-flow-context.sh +20 -22
  118. package/assets/hooks/task-flow-draft-guard.sh +25 -74
  119. package/assets/hooks/task-flow-guard.sh +28 -129
  120. package/assets/hooks/tree-assignment-guard.sh +25 -14
  121. package/assets/hooks/turn-entry-load.sh +3 -1
  122. package/assets/hooks/turn-exit-guard.sh +92 -452
  123. package/assets/hooks/turn-exit-role.sh +47 -0
  124. package/assets/hooks/turn-judge.md +103 -0
  125. package/assets/hooks/window-fill-guard.sh +22 -41
  126. package/assets/laws/work-conduct.md +9 -8
  127. package/assets/patterns/autonomous-work-run.md +35 -10
  128. package/assets/patterns/browser-verification-measure.md +10 -20
  129. package/assets/patterns/browser-verification-stand.md +30 -42
  130. package/assets/patterns/doc-style-human.md +0 -6
  131. package/assets/patterns/doc-style-sweep.md +7 -7
  132. package/assets/patterns/doc-style-trace.md +5 -4
  133. package/assets/patterns/doc-style-write.md +7 -7
  134. package/assets/patterns/epic-flow-declare.md +15 -8
  135. package/assets/patterns/git-workflow-commit.azure.md +9 -155
  136. package/assets/patterns/git-workflow-commit.github.md +11 -269
  137. package/assets/patterns/git-workflow-commit.gitlab.md +9 -161
  138. package/assets/patterns/git-workflow-docker.md +8 -231
  139. package/assets/patterns/git-workflow-freshness.md +9 -56
  140. package/assets/patterns/git-workflow-merge.md +7 -174
  141. package/assets/patterns/git-workflow-migration.md +5 -73
  142. package/assets/patterns/git-workflow-pr-body.github.md +6 -159
  143. package/assets/patterns/git-workflow-pr-ready.md +9 -69
  144. package/assets/patterns/git-workflow-pr.azure.md +14 -220
  145. package/assets/patterns/git-workflow-pr.github.md +13 -253
  146. package/assets/patterns/git-workflow-pr.gitlab.md +14 -241
  147. package/assets/patterns/git-workflow-restart.md +5 -41
  148. package/assets/patterns/git-workflow-secrets.md +10 -76
  149. package/assets/patterns/git-workflow-stack.md +9 -205
  150. package/assets/patterns/lib-layers-new.md +7 -3
  151. package/assets/patterns/queue-audit-read.github.md +9 -3
  152. package/assets/patterns/spec-driven-domain.md +50 -48
  153. package/assets/patterns/spec-driven-rule.md +18 -19
  154. package/assets/patterns/status-report-table.github.md +2 -2
  155. package/assets/patterns/task-flow-archive.md +15 -256
  156. package/assets/patterns/task-flow-close.md +16 -291
  157. package/assets/patterns/task-flow-cycle.md +13 -39
  158. package/assets/patterns/task-flow-graph.needs-graph.md +8 -58
  159. package/assets/patterns/task-flow-handoff.md +13 -161
  160. package/assets/patterns/task-flow-resume.md +19 -183
  161. package/assets/patterns/task-flow-start.md +9 -248
  162. package/assets/patterns/testing-e2e.md +14 -18
  163. package/assets/patterns/testing-unit.md +9 -13
  164. package/assets/patterns/turn-entry-map.md +15 -5
  165. package/assets/pitfalls/agent-kit-extend.md +200 -0
  166. package/assets/pitfalls/agent-kit.2.md +323 -0
  167. package/assets/pitfalls/angular-patterns.md +98 -0
  168. package/assets/pitfalls/autonomous-work.md +15 -0
  169. package/assets/pitfalls/browser-verification.md +265 -0
  170. package/assets/pitfalls/component-structure.md +98 -0
  171. package/assets/pitfalls/dependencies.md +92 -0
  172. package/assets/pitfalls/deploy-flow.azure.md +171 -0
  173. package/assets/pitfalls/deploy-flow.github.md +211 -0
  174. package/assets/pitfalls/deploy-flow.gitlab.md +173 -0
  175. package/assets/pitfalls/doc-style.2.md +286 -0
  176. package/assets/pitfalls/doc-style.md +3 -3
  177. package/assets/pitfalls/entity-conventions.needs-admin.md +96 -0
  178. package/assets/pitfalls/entity-models.md +89 -0
  179. package/assets/pitfalls/git-workflow-commit.azure.md +190 -0
  180. package/assets/pitfalls/git-workflow-commit.github.md +307 -0
  181. package/assets/pitfalls/git-workflow-commit.gitlab.md +196 -0
  182. package/assets/pitfalls/git-workflow-docker.md +275 -0
  183. package/assets/pitfalls/git-workflow-freshness.md +88 -0
  184. package/assets/pitfalls/git-workflow-hosting.azure.md +31 -0
  185. package/assets/pitfalls/git-workflow-hosting.github.md +32 -0
  186. package/assets/pitfalls/git-workflow-hosting.gitlab.md +31 -0
  187. package/assets/pitfalls/git-workflow-merge.md +220 -0
  188. package/assets/pitfalls/git-workflow-migration.md +103 -0
  189. package/assets/pitfalls/git-workflow-pr-body.github.md +185 -0
  190. package/assets/pitfalls/git-workflow-pr-ready.md +104 -0
  191. package/assets/pitfalls/git-workflow-pr.2.azure.md +172 -0
  192. package/assets/pitfalls/git-workflow-pr.2.github.md +184 -0
  193. package/assets/pitfalls/git-workflow-pr.2.gitlab.md +180 -0
  194. package/assets/pitfalls/git-workflow-pr.azure.md +159 -0
  195. package/assets/pitfalls/git-workflow-pr.github.md +107 -0
  196. package/assets/pitfalls/git-workflow-pr.gitlab.md +151 -0
  197. package/assets/pitfalls/git-workflow-push.azure.md +30 -0
  198. package/assets/pitfalls/git-workflow-push.github.md +30 -0
  199. package/assets/pitfalls/git-workflow-push.gitlab.md +30 -0
  200. package/assets/pitfalls/git-workflow-queue.azure.md +30 -0
  201. package/assets/pitfalls/git-workflow-queue.github.md +30 -0
  202. package/assets/pitfalls/git-workflow-queue.gitlab.md +30 -0
  203. package/assets/pitfalls/git-workflow-restart.md +72 -0
  204. package/assets/pitfalls/git-workflow-secrets.md +114 -0
  205. package/assets/pitfalls/git-workflow-stack.md +254 -0
  206. package/assets/pitfalls/git-workflow.2.azure.md +291 -0
  207. package/assets/pitfalls/git-workflow.2.github.md +294 -0
  208. package/assets/pitfalls/git-workflow.2.gitlab.md +278 -0
  209. package/assets/pitfalls/git-workflow.github.md +5 -9
  210. package/assets/pitfalls/lib-layers.md +114 -0
  211. package/assets/pitfalls/lists.md +117 -0
  212. package/assets/pitfalls/navigation.md +94 -0
  213. package/assets/pitfalls/reuse-first.md +201 -0
  214. package/assets/pitfalls/spec-driven.2.md +318 -0
  215. package/assets/pitfalls/spec-driven.md +9 -7
  216. package/assets/pitfalls/styling-bem.2.md +125 -0
  217. package/assets/pitfalls/task-flow-archive.md +264 -0
  218. package/assets/pitfalls/task-flow-close.2.md +165 -0
  219. package/assets/pitfalls/task-flow-close.md +167 -0
  220. package/assets/pitfalls/task-flow-cycle.md +73 -0
  221. package/assets/pitfalls/task-flow-graph.needs-graph.md +98 -0
  222. package/assets/pitfalls/task-flow-handoff.md +200 -0
  223. package/assets/pitfalls/task-flow-handover.md +30 -0
  224. package/assets/pitfalls/task-flow-owner.md +29 -0
  225. package/assets/pitfalls/task-flow-plan.md +29 -0
  226. package/assets/pitfalls/task-flow-resume.md +257 -0
  227. package/assets/pitfalls/task-flow-start.md +287 -0
  228. package/assets/pitfalls/task-flow.2.md +303 -0
  229. package/assets/pitfalls/task-flow.md +18 -29
  230. package/assets/pitfalls/testing.2.md +279 -0
  231. package/assets/pitfalls/testing.md +11 -12
  232. package/assets/pitfalls/turn-conduct.md +17 -18
  233. package/assets/pitfalls/typescript-conventions.md +161 -0
  234. package/assets/pitfalls/write-a-skill.md +128 -0
  235. package/assets/rules/angular-patterns.md +21 -86
  236. package/assets/rules/autonomous-work.md +37 -29
  237. package/assets/rules/browser-verification.md +28 -251
  238. package/assets/rules/component-structure.md +25 -87
  239. package/assets/rules/dependencies.md +20 -78
  240. package/assets/rules/deploy-flow.azure.md +27 -134
  241. package/assets/rules/deploy-flow.github.md +34 -196
  242. package/assets/rules/deploy-flow.gitlab.md +28 -137
  243. package/assets/rules/doc-style.md +32 -282
  244. package/assets/rules/entity-conventions.needs-admin.md +26 -82
  245. package/assets/rules/entity-models.md +14 -63
  246. package/assets/rules/epic-flow.md +5 -3
  247. package/assets/rules/git-workflow-hosting.azure.md +26 -0
  248. package/assets/rules/git-workflow-hosting.github.md +38 -0
  249. package/assets/rules/git-workflow-hosting.gitlab.md +27 -0
  250. package/assets/rules/git-workflow-push.azure.md +28 -0
  251. package/assets/rules/git-workflow-push.github.md +28 -0
  252. package/assets/rules/git-workflow-push.gitlab.md +28 -0
  253. package/assets/rules/git-workflow-queue.azure.md +23 -0
  254. package/assets/rules/git-workflow-queue.github.md +30 -0
  255. package/assets/rules/git-workflow-queue.gitlab.md +23 -0
  256. package/assets/rules/git-workflow.azure.md +21 -264
  257. package/assets/rules/git-workflow.github.md +24 -285
  258. package/assets/rules/git-workflow.gitlab.md +21 -258
  259. package/assets/rules/lib-layers.md +30 -103
  260. package/assets/rules/lists.md +21 -105
  261. package/assets/rules/navigation.md +10 -69
  262. package/assets/rules/queue-audit.github.md +5 -3
  263. package/assets/rules/reuse-first.md +20 -195
  264. package/assets/rules/spec-driven.md +35 -316
  265. package/assets/rules/status-report.md +5 -3
  266. package/assets/rules/styling-bem.md +20 -117
  267. package/assets/rules/task-flow-handover.md +24 -0
  268. package/assets/rules/task-flow-owner.md +34 -0
  269. package/assets/rules/task-flow-plan.md +38 -0
  270. package/assets/rules/task-flow.md +22 -289
  271. package/assets/rules/testing.md +32 -270
  272. package/assets/rules/turn-conduct.md +109 -111
  273. package/assets/rules/turn-entry.md +2 -2
  274. package/assets/rules/typescript-conventions.md +41 -147
  275. package/assets/samples/tasks/_template/plan.md +30 -6
  276. package/assets/samples/tasks/_template/progress.md +0 -1
  277. package/assets/skills/agent-kit-extend.md +25 -168
  278. package/assets/skills/agent-kit.md +27 -299
  279. package/assets/skills/write-a-skill.md +20 -106
  280. package/assets/task-flow/flow.js +188 -0
  281. package/assets/task-flow/flow.md +102 -0
  282. package/assets/task-flow/measure/agreement.mjs +24 -0
  283. package/assets/task-flow/measure/copy.mjs +22 -0
  284. package/assets/task-flow/measure/epic-of.mjs +50 -0
  285. package/assets/task-flow/measure/epic-text.mjs +35 -0
  286. package/assets/task-flow/measure/epic.mjs +114 -0
  287. package/assets/task-flow/measure/folder.mjs +16 -0
  288. package/assets/task-flow/measure/footprint.mjs +28 -0
  289. package/assets/task-flow/measure/grill.mjs +21 -0
  290. package/assets/task-flow/measure/host.mjs +8 -0
  291. package/assets/task-flow/measure/owner.mjs +20 -0
  292. package/assets/task-flow/measure/plan.mjs +27 -0
  293. package/assets/task-flow/measure/pr.mjs +20 -0
  294. package/assets/task-flow/measure/progress.mjs +50 -0
  295. package/assets/task-flow/measure/session.mjs +175 -0
  296. package/assets/task-flow/measure/task.mjs +23 -0
  297. package/assets/task-flow/measure/text.mjs +77 -0
  298. package/assets/task-flow/source/git.mjs +86 -0
  299. package/assets/task-flow/source/host.mjs +172 -0
  300. package/assets/task-flow/source/marks.mjs +56 -0
  301. package/assets/task-flow/source/owner.mjs +74 -0
  302. package/assets/task-flow/source/records.mjs +116 -0
  303. package/assets/task-flow/source/session.mjs +232 -0
  304. package/assets/task-flow/source/steps.mjs +28 -0
  305. package/assets/task-flow/source/tree.mjs +42 -0
  306. package/assets/templates/rule.md +2 -2
  307. package/bin/agent-kit.d.ts.map +1 -1
  308. package/bin/agent-kit.js +30 -0
  309. package/bin/agent-kit.js.map +1 -1
  310. package/lib/agent-checks.d.ts +55 -0
  311. package/lib/agent-checks.d.ts.map +1 -0
  312. package/lib/agent-checks.js +209 -0
  313. package/lib/agent-checks.js.map +1 -0
  314. package/lib/assets.d.ts.map +1 -1
  315. package/lib/assets.js +7 -2
  316. package/lib/assets.js.map +1 -1
  317. package/lib/cargo-prose.d.ts +2 -1
  318. package/lib/cargo-prose.d.ts.map +1 -1
  319. package/lib/cargo-prose.js.map +1 -1
  320. package/lib/cargo.d.ts +29 -0
  321. package/lib/cargo.d.ts.map +1 -1
  322. package/lib/cargo.js +27 -1
  323. package/lib/cargo.js.map +1 -1
  324. package/lib/cascade.d.ts.map +1 -1
  325. package/lib/cascade.js +3 -1
  326. package/lib/cascade.js.map +1 -1
  327. package/lib/commands.d.ts.map +1 -1
  328. package/lib/commands.js +78 -2
  329. package/lib/commands.js.map +1 -1
  330. package/lib/companion.d.ts +0 -5
  331. package/lib/companion.d.ts.map +1 -1
  332. package/lib/companion.js +1 -1
  333. package/lib/companion.js.map +1 -1
  334. package/lib/config.d.ts +18 -0
  335. package/lib/config.d.ts.map +1 -1
  336. package/lib/config.js +18 -1
  337. package/lib/config.js.map +1 -1
  338. package/lib/cost.d.ts +0 -8
  339. package/lib/cost.d.ts.map +1 -1
  340. package/lib/cost.js +4 -4
  341. package/lib/cost.js.map +1 -1
  342. package/lib/epic-window-send.d.ts +74 -0
  343. package/lib/epic-window-send.d.ts.map +1 -0
  344. package/lib/epic-window-send.js +166 -0
  345. package/lib/epic-window-send.js.map +1 -0
  346. package/lib/hooks-map.d.ts +4 -12
  347. package/lib/hooks-map.d.ts.map +1 -1
  348. package/lib/hooks-map.js +4 -27
  349. package/lib/hooks-map.js.map +1 -1
  350. package/lib/integrity.d.ts +3 -0
  351. package/lib/integrity.d.ts.map +1 -1
  352. package/lib/integrity.js +7 -0
  353. package/lib/integrity.js.map +1 -1
  354. package/lib/metric-lines.d.ts +2 -1
  355. package/lib/metric-lines.d.ts.map +1 -1
  356. package/lib/metric-lines.js +49 -1
  357. package/lib/metric-lines.js.map +1 -1
  358. package/lib/metric-send-mark.d.ts +6 -3
  359. package/lib/metric-send-mark.d.ts.map +1 -1
  360. package/lib/metric-send-mark.js +15 -5
  361. package/lib/metric-send-mark.js.map +1 -1
  362. package/lib/metric-send.d.ts +6 -2
  363. package/lib/metric-send.d.ts.map +1 -1
  364. package/lib/metric-send.js +47 -13
  365. package/lib/metric-send.js.map +1 -1
  366. package/lib/metrics.d.ts +17 -0
  367. package/lib/metrics.d.ts.map +1 -1
  368. package/lib/metrics.js +26 -15
  369. package/lib/metrics.js.map +1 -1
  370. package/lib/observations-cargo.d.ts +1 -5
  371. package/lib/observations-cargo.d.ts.map +1 -1
  372. package/lib/observations-cargo.js +2 -2
  373. package/lib/observations-cargo.js.map +1 -1
  374. package/lib/observations.d.ts +0 -2
  375. package/lib/observations.d.ts.map +1 -1
  376. package/lib/observations.js +3 -3
  377. package/lib/observations.js.map +1 -1
  378. package/lib/order.d.ts +0 -2
  379. package/lib/order.d.ts.map +1 -1
  380. package/lib/order.js +0 -4
  381. package/lib/order.js.map +1 -1
  382. package/lib/outcomes.d.ts +7 -9
  383. package/lib/outcomes.d.ts.map +1 -1
  384. package/lib/outcomes.js +8 -7
  385. package/lib/outcomes.js.map +1 -1
  386. package/lib/proposals.d.ts +0 -1
  387. package/lib/proposals.d.ts.map +1 -1
  388. package/lib/proposals.js +1 -1
  389. package/lib/proposals.js.map +1 -1
  390. package/lib/push-gate.d.ts +13 -0
  391. package/lib/push-gate.d.ts.map +1 -1
  392. package/lib/push-gate.js +11 -7
  393. package/lib/push-gate.js.map +1 -1
  394. package/lib/push-set-usefulness.d.ts +78 -0
  395. package/lib/push-set-usefulness.d.ts.map +1 -0
  396. package/lib/push-set-usefulness.js +225 -0
  397. package/lib/push-set-usefulness.js.map +1 -0
  398. package/lib/shipment.d.ts +2 -11
  399. package/lib/shipment.d.ts.map +1 -1
  400. package/lib/shipment.fixture.d.ts +0 -3
  401. package/lib/shipment.fixture.d.ts.map +1 -1
  402. package/lib/shipment.fixture.js +3 -3
  403. package/lib/shipment.fixture.js.map +1 -1
  404. package/lib/shipment.js +2 -2
  405. package/lib/shipment.js.map +1 -1
  406. package/lib/sync.d.ts +10 -0
  407. package/lib/sync.d.ts.map +1 -1
  408. package/lib/sync.js +14 -1
  409. package/lib/sync.js.map +1 -1
  410. package/lib/traits.d.ts +0 -3
  411. package/lib/traits.d.ts.map +1 -1
  412. package/lib/traits.js +2 -2
  413. package/lib/traits.js.map +1 -1
  414. package/lib/variants.d.ts +0 -1
  415. package/lib/variants.d.ts.map +1 -1
  416. package/lib/variants.js +1 -1
  417. package/lib/variants.js.map +1 -1
  418. package/lib/work-result.d.ts +43 -0
  419. package/lib/work-result.d.ts.map +1 -0
  420. package/lib/work-result.js +39 -0
  421. package/lib/work-result.js.map +1 -0
  422. package/package.json +1 -1
  423. package/assets/checks/signals/ui-kit.json +0 -11
  424. package/assets/hooks/claim-guard.sh +0 -212
  425. package/assets/hooks/grill-gate-ask.sh +0 -26
  426. package/assets/hooks/grill-gate-bypass.sh +0 -61
  427. package/assets/hooks/grill-gate-options.sh +0 -50
  428. package/assets/hooks/grill-gate.sh +0 -482
  429. package/assets/hooks/postmortem-guard.sh +0 -124
  430. package/assets/hooks/proposal-guard.sh +0 -154
  431. package/assets/hooks/stand-login-guard.sh +0 -107
  432. package/assets/hooks/turn-exit-epic.sh +0 -173
  433. package/assets/hooks/turn-exit-patterns.sh +0 -123
  434. package/assets/hooks/turn-exit-verdict.sh +0 -149
  435. package/assets/hooks/waiting-turn-guard.sh +0 -320
  436. package/assets/hooks/work-start-guard.sh +0 -175
@@ -2,260 +2,37 @@
2
2
  name: browser-verification
3
3
  kind: rule
4
4
  law: verifiability
5
- description: Rule under the verifiability law. Load for any check through the browser and for requests to the dev server. Names where the tree's applications run, what on the dev server cannot be trusted and what to measure instead of looking. Patterns browser-verification-stand, -measure.
5
+ description: Rule under the verifiability law. Load for browser checks and requests to a running app. Patterns browser-verification-stand, -measure.
6
6
  ---
7
7
 
8
- # Checking the running application — how it works here
8
+ # Checking the running application
9
9
 
10
- Rule under the law `docs/constitution/verifiability.md`. The law says what counts as confirmation;
11
- here — where the applications live, what on them can be trusted and what to measure with. Tests
12
- under the same law — rule `testing`.
13
-
14
- ## What it is called here
15
-
16
- | In the law | Here |
17
- | -------------------------------- | ------------------------------------------------------------------------------------------------ |
18
- | the running application | what is up in this tree; the list and the ports — in `implementation.md` next to it |
19
- | the place where the user sees it | the production build behind the tree's real proxy, not the dev server |
20
- | measurement | `getComputedStyle`, `getBoundingClientRect`, contrast, matching centres, landing in the viewport |
21
- | browser driver | `claude-in-chrome` on the pinned profile of this tree |
22
-
23
- ## Where it lives
24
-
25
- In this tree — the table in `implementation.md` next to it. Paths live there, not here: the rule
26
- travels between repositories, the layout does not, and a path named in the rule lies in the first
27
- tree that keeps its code differently.
28
-
29
- ## Flow
30
-
31
- The flow of a check through the browser: what is found out before the first request, where the fork
32
- is between an application that is up and one that is not, and what backs the conclusion.
33
-
34
- ```mermaid
35
- flowchart TD
36
- A[A check in the browser is needed] --> B{The port is taken}
37
- B -->|Yes| C[What exactly answers is found out]
38
- B -->|No| D{Who raises the stand}
39
- C --> E{The very application answers}
40
- E -->|Yes| F[A second instance is not raised]
41
- E -->|No| T[What took the port is stopped by process id, not by command name]
42
- T --> D
43
- D -->|Owner| U[They are told at once, not at the end of the session: the guard refuses the agent]
44
- D -->|Agent| V[The stand is raised]
45
- U --> G[The driver drives the browser on the pinned profile]
46
- V --> G
47
- F --> G
48
- G --> W{The screen is public and this is the first visit}
49
- W -->|Yes| X[The visit is marked with the service-visit sign: otherwise it lands in the guest count]
50
- W -->|No| H{What is checked}
51
- X --> H
52
- H -->|Request path and page delivery| I[The check goes behind the real proxy]
53
- H -->|Layout| J[Measurement of computed values, not a look]
54
- I --> K{The divergence is explained by a cache}
55
- J --> K
56
- K -->|Yes| L[The cache is cleared and the measurement repeated: an explanation is not a confirmation]
57
- K -->|No| M[The conclusion names the number and the way to get it]
58
- L --> M
59
- ```
10
+ Rule under the law `docs/constitution/verifiability.md`. Cold part: `pitfalls.md`.
60
11
 
61
12
  ## How the law applies here
62
13
 
63
- - **A second instance of an application that is already up is not raised.** Before the first request
64
- it is found out who answers on the port. An instance raised anew answers with its own build, not
65
- the one under check. Who raises the stand — the owner or the agent — is said in the tree's names.
66
- A taken port discovered late means the stand already exists: what was started on top of it is
67
- stopped by process id, not by command name — both instances share the same one.
68
- - **The browser is driven by one driver on the pinned profile.** The other doors — a second driver,
69
- `open`, `osascript`, launching the binary — do not ask the pinned profile at all.
70
- - **A browser raised by a library from inside a script is the same door as launching the binary.**
71
- The command line does not show it at all. There stand the interpreter name and a file path, and
72
- the driving lies inside the file itself. So what is judged is the content of the file being run,
73
- and the code passed as an argument instead of a file. A rule that judged one command line promised
74
- more than it checked, and the profile was bypassed through this door twice in one session.
75
- - **The browser choice goes stale and needs a repeated call.** A choice made at the start of the
76
- session does not hold: after a pause the next call opens a tab in another profile silently.
77
- - **A refused profile choice ends the work with the browser; it does not start a search for a
78
- workaround.** The profile is not among the connected ones — so there is nobody to drive. The tab
79
- list, the navigation and the screenshot will go to whichever browser the extension counts as
80
- active, and which one that is nobody knows. The state is named to the owner in words, and work
81
- through the browser stands until their answer.
82
- - **The profile is not picked from the list and not asked from the owner.** The list gives unstable
83
- names that identify nothing, and a pick from it leads to a profile without a sign-in.
84
- - **An unconfigured guard is a reason to stop, not a permission to go on.** The guard lets the
85
- action through when the helper is silent, so that a broken harness does not stall the work. It
86
- does not count as permission to work past the profile. An executor who got empty output from the
87
- helper names that to the owner and does not drive the browser: the tab would open in the profile
88
- the extension took for active, and which profile that is nobody knows.
89
- - **A screen behind sign-in is checked on a stand with a substituted sign-in answer, not with a live
90
- account.** The application gets the sign-in as a person gives it, through the form, and the stand
91
- answers it. The sign that closes the screen arrives with the substituted profile. Asking a person
92
- to do a step of the check — type a password, open a tab, press a button — means a wrongly chosen
93
- path, not a lack of rights on the executor's side.
94
- - **A move of people into a sign-in system is checked by signing in as a moved person.** The stand
95
- holds the same profile fields as the real people have after the move: a person moved with only a
96
- mail and rights lacks what the system requires of a profile, and is sent to a step the form check
97
- never reaches. Requests to the form, the API and the sign-in settings walk no part of that path.
98
- - **Changing the number of elements in a container is a layout edit.** It touches no styles, so it
99
- reads as a markup edit, and the check shrinks to response codes. The pages answer in every locale,
100
- and the document is already twice the viewport width. It is closed by a measurement — document
101
- width against viewport width on a narrow screen — not by a look at a screenshot: a screenshot
102
- shows what fit into the frame. A row with no wrapping and no narrow layout, grown from four
103
- elements to eight, held a horizontal scrollbar on every page of the site for forty-four minutes of
104
- production.
105
- - **A measurement is taken on the longest value, not on the sample one.** Overlap, overflow past the
106
- edge and clipping without a sign show only where the content does not fit its place. On a short
107
- value all three look fine. The value for measurement is the extreme one — what the node can get
108
- from a real consumer, not what stands in the example.
109
- - **The longest value is set for every node that shares the line, not only for the edited one.** An
110
- element next to a neighbour takes its place from the neighbour's length. A long neighbour wraps
111
- the element to a new line, and the element lands at its start. Its own short value hides that.
112
- - **A ready-made kit piece taken for values of another size is measured, not looked at.** A
113
- component that lived where values are short gets a value four times longer in its new place. It
114
- behaves differently while staying the same code. The test does not see this at all: clipping by
115
- the browser is not reflected in the markup, and the text comes out of it whole.
116
- - **The stand proxy supplies what the application recognises the request's tenant by.** A tree that
117
- keeps several organisations behind one application tells them apart by a header. The rendering
118
- server puts its own host there, and the application answers every call with a refusal. From
119
- outside that is a "not found" page — it looks like a code defect, not a stand defect. The
120
- measurement is three headers on one stand: own host with port — refusal, own host without port —
121
- refusal, the tenant name — the page. What tells one from the other is substituting the header, not
122
- reading the code.
123
- - **The production configuration is checked only behind the real proxy.** A bare page-serving server
124
- knows nothing about caching, redirects and headers.
125
- - **What is shown to a person is built from the work under discussion.** The stand is built from the
126
- branch of this edit, not from the one the executor is standing on. A build from another branch
127
- shows the tree without the edit, and the person reads that as "not done". What is said about the
128
- shown names the branch it was built from. One such showing cost two turns: the owner repeated a
129
- remark whose edit had long been made, and the executor set about explaining a defect already
130
- fixed.
131
- - **An edit of a shared frame is checked on every screen under it.** A frame, a layout or a shell
132
- edited for one page changes the rest under it, and those pages show in no diff. The list of screens
133
- is read from what the frame shows, not from the page the task named, and the suite that walks them
134
- runs before the push. The one page checked reads as the whole edit checked.
135
- - **The work branch keeps the tip of main merged in the whole time, not only before delivery.** A
136
- branch that has fallen behind builds into a stand with neither others' edits nor one's own
137
- neighbouring ones. What is shown on it describes a tree nobody has. The tip is pulled in when its
138
- movement became known, not when the work ended.
139
- - **The first visit to a public screen is marked with the service-visit sign.** The driver drives an
140
- ordinary browser, and the visit counter does not tell a check from a guest. Its
141
- `navigator.webdriver` is `false`, its `User-Agent` string is a live browser's. What marks the
142
- visit is said in the tree's names; a sign that lives in browser storage is written once per
143
- profile, not for every address.
144
-
145
- - **A screen whose data never exists in the development database is measured with the component's
146
- real styles.** The markup is inserted into an already open screen with its own scope attribute.
147
- The styling rules apply to it the same as they would to a live row. This is a technique, not a
148
- workaround: the same computed values are measured, and only the row content is invented. A
149
- workaround would be measuring another screen and calling that a measurement of the needed one.
150
-
151
- - **A measurement that will have to be repeated is taken by an end-to-end test, not by the driver.**
152
- Window width, node position and content going sideways are read there by the same computed values.
153
- The viewport is set for the whole suite, and the number agrees on every run — while a manual
154
- measurement lives one session and leaves with it. The driver stays where an unfamiliar screen is
155
- looked at: it answers "what is going on here", it does not confirm a known number. The conclusion
156
- "there is nothing to measure with", reached at a closed sign-in, most often means the search used
157
- the wrong tool.
158
-
159
- - **A measurement is taken before the work is shown to the owner, not after their remark.** Shown
160
- without a measurement is a request for a check, not a check. On a screenshot cards stuck tight
161
- together read as one with long content, a clipped shadow as no shadow, a zero gap as dense layout.
162
- Each such defect is visible by one measurement command. Numbers taken from the reference in
163
- advance are checked against the implementation the same way: work done by retelling the reference
164
- in words diverges from it unnoticed.
165
-
166
- - **Work that carries a look over from a sample is accepted by a frame of one's own screen next to
167
- the sample's frame.** Names carried into the markup are the technique, not the result: a green
168
- build, linters and tests say nothing about a field clipped mid-line. Every remade screen is
169
- looked at by the executor and shown to the owner; a screen not opened since the edit counts as
170
- unchecked. A measurement set assembled by the author under their own edit confirms nothing
171
- either — it holds what was fixed in that hour; the set is taken from what the work is accepted
172
- by and is written before the edit.
173
-
174
- A conclusion about layout is backed by a number: "looks fine" is never a check result. Nothing
175
- guards this — how to measure is covered in pattern `browser-verification-measure`.
176
-
177
- ## What of the law is not here
178
-
179
- There is no check for direct access to the browser environment — that is `Q-FA-1` in the
180
- frontend-application law: such access compiles and fails only when the page is served by the server.
181
-
182
- ## Patterns
183
-
184
- - `browser-verification-stand` — an honest stand from the production build, signing in to a closed
185
- application, sorting out a port.
186
- - `browser-verification-measure` — measurement instead of a look, pitfalls of the `computer` tool.
187
-
188
- ## Pitfalls
189
-
190
- - **First find out what answers on the port:** `lsof -nP -iTCP:<port> -sTCP:LISTEN` before the first
191
- request. A built artifact from a past session regularly hangs on the application port. It answers
192
- 200 with old code, and the handler created in the branch it does not have at all, so a 404 reads
193
- as a registration defect. There may be several such processes; killing by command pattern hits
194
- none of them — kill by PID from `lsof`, each one.
195
- - **A command-name pattern is no good either to hit or to spare.** Two instances of one stand — the
196
- one already up and the one just started — cannot be told apart by command text. It is the same for
197
- both. Killing by pattern takes both, and there is nothing to sort it out with afterwards: what
198
- gets killed is exactly the stand everything was started for. Own and foreign are told apart only
199
- by the process id taken by sorting out the port; that is what stops them, one by one. The reverse
200
- miss is the same in nature — the shell starts the process under a name the pattern lacks, and the
201
- kill hits nothing.
202
- - **Killing a process may be refused, and then the stand is raised alongside, not instead.** The
203
- runtime environment may refuse it — even for one's own stand from a past session. Neither a
204
- permission for the command nor rewording helps here. There is one move from here: a free port for
205
- the new stand, and the list of what was left is named to the owner at the end of the session —
206
- only they can kill those. Not named so, stands pile up across sessions and hold connections to the
207
- storage.
208
- - **A statement about the production build is made from the build itself, not from the branch.**
209
- Between the branch and what is served to the reader stands the image build. It substitutes
210
- environment values, cuts out the unused and renames symbols. "The build holds this" is checked by
211
- a search over the served file — all the more when the matter is exactly the value the build
212
- substitutes.
213
- - An incremental build goes stale piece by piece: the markup may already be new while the client
214
- chunk is from a compilation before the edit. The sign of a dev build is bundle names without a
215
- hash (`main.js`). A divergence between `curl` and the page after hydration is a reason to rebuild,
216
- not to look for a defect in the code. Nor can "there is no such route" be concluded from here:
217
- check against the route declaration.
218
- - **A cache explains a divergence but does not confirm it.** `.angular/cache/…/vite/deps` holds only
219
- packages from `node_modules`, none of the repository code. The conclusion "no defect, it is the
220
- cache" closes the investigation, so it is accepted only after a check on a clean build. Three
221
- rounds went on a stuck event feed panel while the defect lay in the outlet teardown.
222
- - **A caching build step without declared outputs serves the past silently.** The cache hit happens,
223
- and there is nothing to restore: the builder does not run, and the build directory keeps what lay
224
- there from last time. The stand raises that build, and the application behaves like code that is
225
- not in the tree. The pitfall above is about another cache: that one explains a divergence, this
226
- one creates it, and the builder's output is green with it. Before looking for a defect in the
227
- screen, the build step is asked for its declared outputs; that is checked by removing the build
228
- directory and calling again — after a cache hit it must restore itself.
229
- - The message `Angular debugging APIs are not available` in the console belongs to the Chrome
230
- extension, not to the application: the production build does not publish `window.ng`. No code edit
231
- is needed to cure it — `window.ng` in production is a map of the internals in the hands of anyone
232
- who opens the console.
233
- - Router behaviour is reproduced by clicks: substituting the address and entering by a direct link
234
- raise the application anew, and it has no accumulated state.
235
- - A measurement answers only the question asked. The rows of the profile popup matched the reference
236
- by padding, font size and rounding, while the reference paints no hover background there at all —
237
- a full-width highlight held on for two rounds with correct numbers.
238
- - **When the version of the package that draws the layout changed, the screens are walked by hand.**
239
- Tests click by `qa-dataid` and stay green even when a gap shifted, a size vanished and a row got a
240
- different height. They check transitions, not looks. A pair of screenshots is too little here too
241
- — every screen this package draws is looked at in turn.
242
- - **There are three launch paths here, and they are checked separately:** the local command, the
243
- image `deploy/api.Dockerfile` and the composition `docker-compose.prod.yml`. A variable set in the
244
- check command says nothing about the image: the production composition has it, while a manual run
245
- of the same image goes without it. The paths are listed before the check, not after one of them
246
- matched.
247
- - **The sign is taken from the owner's question, not from the subject of the edit.** A server-served
248
- page answers "did it build", and it never answers "is it visible". The display lives after
249
- hydration, and the picture after a request to an external service. The signs for the second
250
- question are their own — the image's `naturalWidth` above zero, the display node appeared on the
251
- raised page — and they are taken by the driver, not by a request to the address.
252
- - **A refusal from an external service is never a diagnosis of a setting.** A `403` names the state
253
- of the project at the provider and says nothing about what value lies in the tree's setting. Read
254
- as a diagnosis, it leads to fixing what is intact — while the value itself is read by one command
255
- on one's own side. All the less is it requested from the owner: the session already has it.
256
- - **The previous behaviour is read from the code of that version:** `git show <commit before the
257
- edit>:<file>`. A commit body names what the edit changed and is silent about what was true before
258
- it. A display condition with one more mandatory value appended switches off what was shown before,
259
- and in the edit itself it looks like a refinement. An edit from a neighbouring task rolled out the
260
- same day enters the production check alongside one's own: the branch answers for what left
261
- together with it.
14
+ - **A running application is not raised a second time.** The port's answerer is found first: this branch's is used, another's left alone and the stand goes on a free port; duplicates stop by process id.
15
+ - **The browser is driven by one driver on the pinned profile.** Not a second driver, `open`, `osascript` or the binary.
16
+ - **A browser a script raises counts as launching the binary.** Its file is judged, not the command line.
17
+ - **The browser choice goes stale; the call is repeated.**
18
+ - **A refused profile choice stops browser work.** Named to the owner; no workaround.
19
+ - **A profile is neither picked from the list nor asked of the owner.**
20
+ - **An unconfigured guard is a stop, not a permission.** Empty helper output: tell the owner.
21
+ - **A screen behind sign-in is checked on a stand, not a live account.** Through the form, seeded account; asking a person for a step is wrong.
22
+ - **A move into sign-in is checked by signing in as a moved person.** The stand holds real profile fields.
23
+ - **A container's element count change is a layout edit.** Measure document vs viewport width at each threshold, both sides.
24
+ - **A measurement takes the longest value, not the sample.**
25
+ - **The longest value is set for every node sharing the line.**
26
+ - **A kit piece reused for other-sized values is measured, not looked at.**
27
+ - **The stand proxy supplies the request's tenant sign.**
28
+ - **Production configuration is checked only behind the real proxy.**
29
+ - **What a person is shown is built from the work's branch.** Production build, branch named.
30
+ - **A shared frame's edit is checked on every screen under it.** Screens from the frame; their suite runs before the push.
31
+ - **The work branch always has its base tip merged in.**
32
+ - **A public screen's first visit carries the service-visit sign.**
33
+ - **A screen with no dev data is measured with the component's real styles.** Into the open screen, under its scope.
34
+ - **A measurement to repeat is an end-to-end test, not the driver.**
35
+ - **Measure before showing the owner, not after their remark.** Reference numbers too.
36
+ - **A sample's look carried over is accepted by own frame beside the sample's.** Each remade screen opened, shown to the owner; the measure set taken from the acceptance, written before the edit.
37
+
38
+ A layout conclusion is backed by a number.
@@ -7,97 +7,35 @@ description: Rule under the frontend-application law. Load when editing any *.co
7
7
 
8
8
  # Component file — how it works here
9
9
 
10
- Rule under the law `docs/constitution/frontend-application.md`. The law says what must be true; here
11
- — how the component file itself and its template are arranged. State and streams —
12
- `angular-patterns`, styles — `styling-bem`, the browser environment — `platform-access`, the server
13
- access layer — `api-layer`. All five under one law.
14
-
15
- ## What it is called here
16
-
17
- | In the law | Here |
18
- | ------------------------------------------------ | --------------------------------------------------------------------------- |
19
- | component | `<prefix>-<name>` — one prefix for all applications of the tree |
20
- | a ready value, not a computation in the template | `computed()`; where the value comes from the template context — a pure pipe |
21
- | an anchor for a check | the `qa-dataid` attribute in kebab-case by the meaning of the element |
22
- | markup root | `:host` with the block class from `host: { class: '<prefix>-<name>' }` |
23
-
24
- ## Where it lives
25
-
26
- In this tree — the table in `implementation.md` next to it. Paths live there, not here: the rule
27
- travels between repositories, the layout does not, and a path named in the rule lies in the first
28
- tree that keeps its code differently.
29
-
30
- ## Flow
31
-
32
- The flow of editing a component: where the markup is decided, where the binding is, and what is put
33
- on every interactive element.
34
-
35
- ```mermaid
36
- flowchart TD
37
- A[A component is edited] --> B[The selector is an element, the block class is on the host]
38
- B --> C{The template needs a computed view}
39
- C -->|Yes| D[The value is computed in the class, the template calls no methods]
40
- C -->|No| E[The markup is written as is]
41
- D --> F{There is an interactive element}
42
- E --> F
43
- F -->|Yes| G[An anchor for specs is set, and accessibility — by separate attributes]
44
- F -->|No| H[Done]
45
- G --> I{One component in both branches of a condition}
46
- I -->|Yes| J[That is a conditional binding: the branches are merged into one]
47
- I -->|No| H
48
- J --> H
49
- ```
10
+ Rule under the law `docs/constitution/frontend-application.md`. Cold part: `pitfalls.md` — the whole
11
+ text, every section and article with its reasons.
50
12
 
51
13
  ## How the law applies here
52
14
 
53
- - **The template calls no methods.** The linter rule bans `{{ getTotal() }}` and `@if
54
- (computeFlag())`, signal reads it does not touch.
55
- - **Every interactive element carries `qa-dataid`.** It is the only anchor of the specs: BEM classes
56
- change with the layout, and a search by role and text breaks on translation locales.
57
- - **A component is allowed only an element selector.** The linter rule demands from a component an
58
- element with the tree prefix and a hyphenated name, from a directive — an attribute and a one-word
59
- name. A technique that hangs on a foreign tag is written as a directive from the start: with a
60
- component on an attribute selector the lint turns red only after all three files and the styles
61
- are written.
62
- - **The block class hangs on the host, not on a wrapper inside the template.** An extra wrapper
63
- around all the children is layout, and its place is on `:host`.
64
-
65
- ## What of the law is not here
66
-
67
- The order of decorator properties, import grouping and self-closing tags are checked by nothing —
68
- they are held by reading the neighbouring file. There is no check for a direct call to the browser
69
- environment either — that is `Q-FA-1` in the law.
70
-
71
- ## Patterns
72
-
73
- - `component-structure-new` — a ready-made component file and the template conventions.
15
+ - **The template calls no methods.**
16
+ - **Every interactive element carries `qa-dataid`.**
17
+ - **A component is allowed only an element selector.**
18
+ - **The block class hangs on the host, not on a wrapper inside the template.**
74
19
 
75
20
  ## Pitfalls
76
21
 
77
- - **`href="#id"` in markup does not work.** The build is one for all locales, the markup holds
78
- `<base href="/">`, and the browser resolves the fragment against the base: instead of a scroll you
79
- get a full navigation with a reload. Scrolling — through the router: `<a [routerLink]="[]"
80
- fragment="booking">`.
81
- - **The same component in both branches of an `@if` is a conditional binding.** Two branches with
82
- different inputs recreate the component and lose its state.
83
- - **A kit that draws in an overlay is not addressed from the caller's host:** its markup lies
84
- outside the host, and `[qa-dataid="x"] button` does not reach the buttons. Such buttons carry
85
- their own anchors right in the kit template, and the guard does not check the dependency
86
- catalogue.
22
+ - **`href="#id"` in markup does not work.**
23
+ - **The same component in both branches of an `@if` is a conditional binding.**
24
+ - **A kit component that draws in an overlay is not addressed from the caller's host:** its markup lies
25
+ outside the host, and `[qa-dataid="x"] button` does not reach the buttons.
87
26
  - **`qa-dataid` does not replace `aria-label` and roles:** accessibility separately, the anchor
88
- separately. And it is not removed when the layout is edited — the specs hang on it.
89
- - **Markup is edited by the edit tool, not by a script.** The anchor guard judges a shell command
90
- by its whole body: the old markup in a find-and-replace pair counts as written, and an edit that
91
- adds every anchor is refused for the lines it removes. The article in full is in the rule
92
- `doc-style`.
93
- - What the kit has ready is not written anew: own markup with `role="alert"`, `<table>`,
94
- `role="dialog"`, `role="tablist"` or `role="tooltip"` means that `<prefix>-message`,
95
- `<prefix>-table`, `<prefix>-dialog`, `<prefix>-tabs` or `<prefix>-tooltip` were bypassed. The rule
96
- whole — `reuse-first`.
97
- - **A kit icon name is copied from its file, and an unknown name draws an empty frame.** The kit
98
- draws the frame of an icon it did not find and says nothing. The build, the lint and the tests
99
- stay green, and the owner sees an empty square. Before the edit the name is looked up among the
100
- kit icon files: some names carry the `ico-` prefix and most do not.
101
- - **A component that grew past the file limit is split, not squeezed.** An edit of a component does
102
- not load the rule of plain TypeScript files, where the 500-line article lives, so it is repeated
103
- in one line here: what the component does on its own moves out into a file next to it.
27
+ separately.
28
+ - **Markup is edited by the edit tool, not by a script.**
29
+ - **A kit icon name is copied from its file, and an unknown name draws an empty frame.**
30
+ - **A component that grew past the file limit is split, not squeezed.**
31
+
32
+ ## Names and techniques
33
+
34
+ - A computed view is `computed()` in the class, or a pure pipe for template context.
35
+ - `qa-dataid` is kebab-case by the element's meaning and stays when the layout changes.
36
+ - A directive takes an attribute selector; a technique on a foreign tag is a directive.
37
+ - Scroll to a fragment by `[routerLink]="[]" fragment="…"`, not `href="#id"`.
38
+ - Merge the two `@if` branches into one component with conditional inputs.
39
+ - Buttons of an overlay kit component carry their own anchors in the kit template.
40
+ - Own `role=alert`/`dialog`/`tablist`/`tooltip` or `<table>` bypasses the kit; use it.
41
+ - Decorator order, import grouping, self-closing tags follow the neighbouring file.
@@ -7,91 +7,33 @@ description: Rule under the delivery law. Load when editing package.json, the lo
7
7
 
8
8
  # Dependencies — how it works here
9
9
 
10
- Rule under the law `docs/constitution/delivery.md`. The law says what must be true; here — what it
11
- is called in this tree, where it lives and what of the law does not apply here. Branch, commit and
12
- rollout under the same law — rule `git-workflow`.
10
+ Rule under the law `docs/constitution/delivery.md`. Cold part: `pitfalls.md`. Where it lives: the
11
+ table in `implementation.md` next to it.
13
12
 
14
- ## What it is called here
15
-
16
- | In the law | Here |
17
- | --------------------------------- | ------------------------------------------------------------------------------------------------------------ |
18
- | a dependency declaration | an exact number in `package.json` — `"prettier": "3.9.6"`; `^` and `~` do not occur in the file once |
19
- | snapshot of the installed tree | `pnpm-lock.yaml`; goes in the same commit as the declaration |
20
- | substitution of a foreign version | `overrides` in `pnpm-workspace.yaml` — the substituted transitive dependencies lie there |
21
- | waiting period of a new version | `minimumReleaseAge`; a package needed before the term is written out by number in `minimumReleaseAgeExclude` |
22
- | package manager | pnpm: `npm run` calls the scripts, installation is done by `pnpm install` |
23
-
24
- ## Where it lives
25
-
26
- In this tree — the table in `implementation.md` next to it. Paths live there, not here: the rule
27
- travels between repositories, the layout does not, and a path named in the rule lies in the first
28
- tree that keeps its code differently.
29
-
30
- ## Flow
31
-
32
- The flow of raising a version: where the version itself is decided, where the reformatting boundary
33
- lies, and what the work ends with.
34
-
35
- ```mermaid
36
- flowchart TD
37
- A[A new package version is needed] --> B{What sets the upper bound}
38
- B -->|Dependents have peer ranges| C[The bound is taken from them, not from the last number in the registry]
39
- B -->|None| D[The last released one is taken]
40
- C --> E{The version was released recently}
41
- D --> E
42
- E -->|Yes, and it is needed right now| F[Written out separately, with the reason named]
43
- E -->|Yes, but not urgent| G[It waits: a fresh version is withdrawn more often than an old one]
44
- E -->|No| H[Written as an exact number, without a range]
45
- F --> H
46
- H --> I{The formatter or the linter was updated}
47
- I -->|Yes| J[Only what the linter checks is reformatted; new rules are sorted out by name]
48
- I -->|No| K[The tree snapshot is rebuilt, the suite is run whole]
49
- J --> K
50
- ```
13
+ | In the law | Here |
14
+ | --------------------------------- | ---------------------------------------------------------------------- |
15
+ | snapshot of the installed tree | `pnpm-lock.yaml`; goes in the same commit as the declaration |
16
+ | substitution of a foreign version | `overrides` in `pnpm-workspace.yaml` |
17
+ | waiting period of a new version | `minimumReleaseAge`; an earlier version by number in `minimumReleaseAgeExclude` |
18
+ | package manager | pnpm: `npm run` calls the scripts, `pnpm install` installs |
51
19
 
52
20
  ## How the law applies here
53
21
 
54
- - **A package version is written as an exact number.** From a range, today and a week later
55
- different things get installed, and reverting the edit does not fix that.
22
+ - **A package version is written as an exact number.** `"prettier": "3.9.6"` in the root manifest;
23
+ the published packages declare what they accept by a range. The check of this rule refuses a
24
+ range in the root `package.json`, in the push set and in the pipeline. Manifest and lock are
25
+ matched before the push only for an edit of either; otherwise in the pipeline, after the push.
56
26
  - **Substituted versions of foreign dependencies are gathered in one list, and it is revisited at
57
- every update.** A substitution left in the list after the main package was raised silently rolls
58
- its dependency back.
59
- - **A fresh version waits first, and one needed before the term is written out separately.**
60
- Otherwise a release its author managed to withdraw lands in the snapshot.
61
- - **Only what the linter checks the formatting of gets reformatted.** An updated formatter changes
62
- every file it reaches, and `.md` and `.json` are checked by nobody here: an edit in them is just
63
- noise that has to be read by eye.
64
- - **A package that carries styling is raised by a task of its own.** The look breaks silently:
65
- neither the linter, nor the build, nor the tests read styling properties, and the person at the
66
- screen sees the breakage. Gone into a shared update, such a raise is reverted only together with
67
- the others, and tying the breakage to it costs a separate investigation; its own branch is
68
- reverted alone. A feature that needs a component several releases ahead raises the skipped ones
69
- first, by that task of its own, and its branch takes only the last step: each skipped release
70
- brings changes of its own, and in the feature branch they read as the feature's breakage.
71
-
72
- ## What of the law is not here
73
-
74
- Nobody checks that the declared versions match the snapshot: `--frozen-lockfile` stands only in the
75
- rollout, and it goes from a push to the main branch, that is, after the merge. Ranges are not
76
- checked either: one `^` in `package.json` passes every check of the tree.
27
+ every update.** A stale entry silently rolls its dependency back after the main package is raised.
28
+ - **A fresh version waits first, and one needed before the term is written out separately.** The
29
+ upper bound comes from dependents' peer ranges, not from the last number in the registry.
30
+ - **Only what the linter checks the formatting of gets reformatted.** After a formatter update its
31
+ rewrite of `.md` and `.json` is not committed: nobody checks them here, the diff is noise.
32
+ - **A package that carries styling is raised by a task of its own.** Styling breaks silently: no
33
+ lint, build or test reads it. Skipped releases go first, by that task; the feature branch takes
34
+ only the last release.
77
35
 
78
36
  ## Patterns
79
37
 
80
38
  - `dependencies-upgrade` — raising versions, choosing the upper bound, sorting out the consequences
81
39
  of an update.
82
-
83
- ## Pitfalls
84
-
85
- - **A range lets through a version that is not in the registry.** `^0.2.0` was written into the kit
86
- declaration, and the snapshot stayed on the previous version: the declaration looked right, but
87
- everything was built on 0.1.0, where the component has no such size at all, and the main branch
88
- stopped building. This was found two weeks later — when a tree was needed for comparison, and
89
- there turned out to be nothing to compare with.
90
- - **The upper bound is set by peer ranges, not by the last number in the registry.** TypeScript
91
- stayed on 6.0.3 with the seventh version out, because Angular declares `>=6.0 <6.1`. `pnpm
92
- install` does not catch such a mistake: `autoInstallPeers` silently delivers what is missing.
93
- - **After a linter plugin update, rules appear that were not there yesterday.** eslint 10 added
94
- `no-useless-assignment`, `eslint-plugin-playwright` 2 — three rules at once. The findings come on
95
- files the edit did not touch and look like its consequences.
96
- - A test run after an update — rule `testing`: after a Playwright version change the browser has to
97
- be installed anew, and that is not a regression.