oh-my-opencode 5.1.51 → 5.1.55

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 (916) hide show
  1. package/dist/agents/atlas/agent.d.ts +5 -5
  2. package/dist/agents/dynamic-agent-core-sections.d.ts +0 -1
  3. package/dist/agents/dynamic-agent-prompt-builder.d.ts +1 -1
  4. package/dist/agents/gpt-apply-patch-guard.d.ts +0 -1
  5. package/dist/agents/hephaestus/agent.d.ts +3 -7
  6. package/dist/agents/hephaestus/model-support.d.ts +6 -0
  7. package/dist/agents/metis.d.ts +0 -15
  8. package/dist/agents/native-model-prompt.d.ts +9 -0
  9. package/dist/agents/native-prompt-frame.d.ts +20 -0
  10. package/dist/agents/native-tool-snippet.d.ts +6 -0
  11. package/dist/agents/sisyphus/default.d.ts +0 -1
  12. package/dist/agents/sisyphus-agent-factory.d.ts +2 -11
  13. package/dist/agents/sisyphus-junior/agent.d.ts +2 -20
  14. package/dist/agents/sisyphus-junior/index.d.ts +1 -11
  15. package/dist/agents/sisyphus-runtime-prompt-reconciler.d.ts +6 -0
  16. package/dist/agents/types.d.ts +2 -2
  17. package/dist/cli/index.js +1174 -394
  18. package/dist/cli/service-auth/credential-lock.d.ts +11 -0
  19. package/dist/cli/service-auth/credential-owner.d.ts +10 -0
  20. package/dist/cli/service-auth/index.d.ts +3 -1
  21. package/dist/cli/service-auth/keystore.d.ts +8 -1
  22. package/dist/cli/service-auth/owned-refresh.d.ts +21 -0
  23. package/dist/cli/service-auth/protocol-v2.d.ts +27 -0
  24. package/dist/cli/service-auth/protocol.d.ts +26 -2
  25. package/dist/cli/service-auth/recovery-clock.d.ts +7 -0
  26. package/dist/cli/service-auth/refresh-attempt.d.ts +34 -0
  27. package/dist/cli/service-auth/session.d.ts +9 -2
  28. package/dist/cli-node/index.js +1174 -394
  29. package/dist/config/schema/agent-overrides.d.ts +64 -0
  30. package/dist/config/schema/categories.d.ts +8 -0
  31. package/dist/config/schema/oh-my-opencode-config.d.ts +64 -0
  32. package/dist/hooks/native-edition-nudge/hook.d.ts +3 -4
  33. package/dist/index.js +15625 -8841
  34. package/dist/oh-my-opencode.schema.json +112 -0
  35. package/dist/plugin/session-tool-permissions.d.ts +10 -0
  36. package/dist/plugin/system-transform.d.ts +2 -1
  37. package/dist/plugin/tool-definition.d.ts +1 -0
  38. package/dist/shared/bun-ffi-shim.d.ts +29 -0
  39. package/dist/shared/json-file-cache-store.d.ts +11 -0
  40. package/dist/skills/browser/runtime/omowright/index.js +24 -33
  41. package/dist/skills/browser/runtime/omowright/manifest.json +3 -3
  42. package/dist/skills/frontend/ATTRIBUTION.md +104 -1
  43. package/dist/skills/frontend/SKILL.md +7 -3
  44. package/dist/skills/frontend/references/design/design-system-architecture.md +3 -3
  45. package/dist/skills/frontend/references/perfection/craft-floor.md +59 -0
  46. package/dist/skills/frontend/references/perfection/detect.md +52 -0
  47. package/dist/skills/frontend/scripts/detect/cli.ts +70 -0
  48. package/dist/skills/frontend/scripts/detect/config.test.ts +26 -0
  49. package/dist/skills/frontend/scripts/detect/config.ts +53 -0
  50. package/dist/skills/frontend/scripts/detect/core/characters.ts +2 -0
  51. package/dist/skills/frontend/scripts/detect/core/color.test.ts +29 -0
  52. package/dist/skills/frontend/scripts/detect/core/color.ts +150 -0
  53. package/dist/skills/frontend/scripts/detect/core/page.ts +84 -0
  54. package/dist/skills/frontend/scripts/detect/core/shadow.ts +40 -0
  55. package/dist/skills/frontend/scripts/detect/core/source.ts +33 -0
  56. package/dist/skills/frontend/scripts/detect/detect.ts +77 -0
  57. package/dist/skills/frontend/scripts/detect/index.ts +23 -0
  58. package/dist/skills/frontend/scripts/detect/lint.test.ts +27 -0
  59. package/dist/skills/frontend/scripts/detect/lint.ts +98 -0
  60. package/dist/skills/frontend/scripts/detect/render/probe-placement.test.ts +19 -0
  61. package/dist/skills/frontend/scripts/detect/render/probe-placement.ts +50 -0
  62. package/dist/skills/frontend/scripts/detect/render/renderer.ts +37 -0
  63. package/dist/skills/frontend/scripts/detect/render/webview.ts +71 -0
  64. package/dist/skills/frontend/scripts/detect/report.ts +29 -0
  65. package/dist/skills/frontend/scripts/detect/rule.ts +42 -0
  66. package/dist/skills/frontend/scripts/detect/rules/color/ai-color-palette.test.ts +74 -0
  67. package/dist/skills/frontend/scripts/detect/rules/color/ai-color-palette.ts +83 -0
  68. package/dist/skills/frontend/scripts/detect/rules/color/cream-palette.test.ts +24 -0
  69. package/dist/skills/frontend/scripts/detect/rules/color/cream-palette.ts +35 -0
  70. package/dist/skills/frontend/scripts/detect/rules/color/dark-glow.test.ts +47 -0
  71. package/dist/skills/frontend/scripts/detect/rules/color/dark-glow.ts +44 -0
  72. package/dist/skills/frontend/scripts/detect/rules/color/design-system-color.test.ts +26 -0
  73. package/dist/skills/frontend/scripts/detect/rules/color/design-system-color.ts +35 -0
  74. package/dist/skills/frontend/scripts/detect/rules/color/gradient-text.test.ts +24 -0
  75. package/dist/skills/frontend/scripts/detect/rules/color/gradient-text.ts +59 -0
  76. package/dist/skills/frontend/scripts/detect/rules/color/gray-on-color.test.ts +39 -0
  77. package/dist/skills/frontend/scripts/detect/rules/color/gray-on-color.ts +38 -0
  78. package/dist/skills/frontend/scripts/detect/rules/color/index.ts +15 -0
  79. package/dist/skills/frontend/scripts/detect/rules/color/low-contrast.test.ts +209 -0
  80. package/dist/skills/frontend/scripts/detect/rules/color/low-contrast.ts +57 -0
  81. package/dist/skills/frontend/scripts/detect/rules/color/placeholder-contrast.test.ts +62 -0
  82. package/dist/skills/frontend/scripts/detect/rules/color/radial-halo.test.ts +40 -0
  83. package/dist/skills/frontend/scripts/detect/rules/color/radial-halo.ts +31 -0
  84. package/dist/skills/frontend/scripts/detect/rules/color/radial-spotlight-glow.test.ts +27 -0
  85. package/dist/skills/frontend/scripts/detect/rules/color/radial-spotlight-glow.ts +33 -0
  86. package/dist/skills/frontend/scripts/detect/rules/color/support/animation-opacity.ts +78 -0
  87. package/dist/skills/frontend/scripts/detect/rules/color/support/color-path.ts +15 -0
  88. package/dist/skills/frontend/scripts/detect/rules/color/support/contrast-pairs.ts +54 -0
  89. package/dist/skills/frontend/scripts/detect/rules/color/support/contrast-role.ts +76 -0
  90. package/dist/skills/frontend/scripts/detect/rules/color/support/glow-forms.ts +56 -0
  91. package/dist/skills/frontend/scripts/detect/rules/color/support/gradient-samples.ts +134 -0
  92. package/dist/skills/frontend/scripts/detect/rules/color/support/gradients.ts +91 -0
  93. package/dist/skills/frontend/scripts/detect/rules/color/support/mockup-roots.ts +63 -0
  94. package/dist/skills/frontend/scripts/detect/rules/color/support/page-ignore.ts +7 -0
  95. package/dist/skills/frontend/scripts/detect/rules/color/support/painted-text.ts +141 -0
  96. package/dist/skills/frontend/scripts/detect/rules/color/support/palette-roles.ts +58 -0
  97. package/dist/skills/frontend/scripts/detect/rules/color/support/placeholder-contrast.ts +25 -0
  98. package/dist/skills/frontend/scripts/detect/rules/color/support/stock-accent.ts +31 -0
  99. package/dist/skills/frontend/scripts/detect/rules/color/support/text-colors.ts +80 -0
  100. package/dist/skills/frontend/scripts/detect/rules/copy/aphoristic-cadence.test.ts +18 -0
  101. package/dist/skills/frontend/scripts/detect/rules/copy/aphoristic-cadence.ts +20 -0
  102. package/dist/skills/frontend/scripts/detect/rules/copy/broken-image.test.ts +25 -0
  103. package/dist/skills/frontend/scripts/detect/rules/copy/broken-image.ts +17 -0
  104. package/dist/skills/frontend/scripts/detect/rules/copy/em-dash-overuse.test.ts +39 -0
  105. package/dist/skills/frontend/scripts/detect/rules/copy/em-dash-overuse.ts +46 -0
  106. package/dist/skills/frontend/scripts/detect/rules/copy/index.ts +15 -0
  107. package/dist/skills/frontend/scripts/detect/rules/copy/marketing-buzzword.test.ts +18 -0
  108. package/dist/skills/frontend/scripts/detect/rules/copy/marketing-buzzword.ts +33 -0
  109. package/dist/skills/frontend/scripts/detect/rules/copy/numbered-section-labels.test.ts +58 -0
  110. package/dist/skills/frontend/scripts/detect/rules/copy/numbered-section-labels.ts +34 -0
  111. package/dist/skills/frontend/scripts/detect/rules/copy/repeated-container-text.test.ts +43 -0
  112. package/dist/skills/frontend/scripts/detect/rules/copy/repeated-container-text.ts +56 -0
  113. package/dist/skills/frontend/scripts/detect/rules/copy/script-error.test.ts +48 -0
  114. package/dist/skills/frontend/scripts/detect/rules/copy/script-error.ts +38 -0
  115. package/dist/skills/frontend/scripts/detect/rules/copy/skipped-heading.test.ts +49 -0
  116. package/dist/skills/frontend/scripts/detect/rules/copy/skipped-heading.ts +81 -0
  117. package/dist/skills/frontend/scripts/detect/rules/copy/support/numbered-label.ts +94 -0
  118. package/dist/skills/frontend/scripts/detect/rules/copy/support/page-text.ts +37 -0
  119. package/dist/skills/frontend/scripts/detect/rules/copy/theater-slop-phrase.test.ts +17 -0
  120. package/dist/skills/frontend/scripts/detect/rules/copy/theater-slop-phrase.ts +21 -0
  121. package/dist/skills/frontend/scripts/detect/rules/decoration/blinking-cursor.test.ts +43 -0
  122. package/dist/skills/frontend/scripts/detect/rules/decoration/blinking-cursor.ts +48 -0
  123. package/dist/skills/frontend/scripts/detect/rules/decoration/border-accent-on-rounded.test.ts +33 -0
  124. package/dist/skills/frontend/scripts/detect/rules/decoration/border-accent-on-rounded.ts +14 -0
  125. package/dist/skills/frontend/scripts/detect/rules/decoration/bounce-easing.test.ts +72 -0
  126. package/dist/skills/frontend/scripts/detect/rules/decoration/bounce-easing.ts +83 -0
  127. package/dist/skills/frontend/scripts/detect/rules/decoration/buried-raster.test.ts +95 -0
  128. package/dist/skills/frontend/scripts/detect/rules/decoration/buried-raster.ts +72 -0
  129. package/dist/skills/frontend/scripts/detect/rules/decoration/codex-grid-background.test.ts +28 -0
  130. package/dist/skills/frontend/scripts/detect/rules/decoration/codex-grid-background.ts +34 -0
  131. package/dist/skills/frontend/scripts/detect/rules/decoration/design-system-radius.test.ts +37 -0
  132. package/dist/skills/frontend/scripts/detect/rules/decoration/design-system-radius.ts +31 -0
  133. package/dist/skills/frontend/scripts/detect/rules/decoration/gpt-thin-border-wide-shadow.test.ts +59 -0
  134. package/dist/skills/frontend/scripts/detect/rules/decoration/gpt-thin-border-wide-shadow.ts +66 -0
  135. package/dist/skills/frontend/scripts/detect/rules/decoration/hard-offset-shadow.test.ts +45 -0
  136. package/dist/skills/frontend/scripts/detect/rules/decoration/hard-offset-shadow.ts +31 -0
  137. package/dist/skills/frontend/scripts/detect/rules/decoration/hero-eyebrow-chip.test.ts +76 -0
  138. package/dist/skills/frontend/scripts/detect/rules/decoration/hero-eyebrow-chip.ts +19 -0
  139. package/dist/skills/frontend/scripts/detect/rules/decoration/icon-tile-stack.test.ts +67 -0
  140. package/dist/skills/frontend/scripts/detect/rules/decoration/icon-tile-stack.ts +92 -0
  141. package/dist/skills/frontend/scripts/detect/rules/decoration/index.ts +38 -0
  142. package/dist/skills/frontend/scripts/detect/rules/decoration/kicker-above-heading.test.ts +126 -0
  143. package/dist/skills/frontend/scripts/detect/rules/decoration/kicker-above-heading.ts +69 -0
  144. package/dist/skills/frontend/scripts/detect/rules/decoration/marquee.test.ts +63 -0
  145. package/dist/skills/frontend/scripts/detect/rules/decoration/marquee.ts +51 -0
  146. package/dist/skills/frontend/scripts/detect/rules/decoration/organic-clip-path.test.ts +67 -0
  147. package/dist/skills/frontend/scripts/detect/rules/decoration/organic-clip-path.ts +41 -0
  148. package/dist/skills/frontend/scripts/detect/rules/decoration/pulsing-dot.test.ts +58 -0
  149. package/dist/skills/frontend/scripts/detect/rules/decoration/pulsing-dot.ts +72 -0
  150. package/dist/skills/frontend/scripts/detect/rules/decoration/repeating-stripes-gradient.test.ts +26 -0
  151. package/dist/skills/frontend/scripts/detect/rules/decoration/repeating-stripes-gradient.ts +25 -0
  152. package/dist/skills/frontend/scripts/detect/rules/decoration/shape-assembled-illustration.test.ts +59 -0
  153. package/dist/skills/frontend/scripts/detect/rules/decoration/shape-assembled-illustration.ts +58 -0
  154. package/dist/skills/frontend/scripts/detect/rules/decoration/side-tab.test.ts +91 -0
  155. package/dist/skills/frontend/scripts/detect/rules/decoration/side-tab.ts +17 -0
  156. package/dist/skills/frontend/scripts/detect/rules/decoration/support/appearance.ts +110 -0
  157. package/dist/skills/frontend/scripts/detect/rules/decoration/support/assert-cases.ts +25 -0
  158. package/dist/skills/frontend/scripts/detect/rules/decoration/support/borders.ts +150 -0
  159. package/dist/skills/frontend/scripts/detect/rules/decoration/support/clip-geometry.ts +151 -0
  160. package/dist/skills/frontend/scripts/detect/rules/decoration/support/css-candidates.ts +66 -0
  161. package/dist/skills/frontend/scripts/detect/rules/decoration/support/curve-samples.ts +55 -0
  162. package/dist/skills/frontend/scripts/detect/rules/decoration/support/gradient-pattern.ts +40 -0
  163. package/dist/skills/frontend/scripts/detect/rules/decoration/support/keyframes.ts +134 -0
  164. package/dist/skills/frontend/scripts/detect/rules/decoration/support/labels.ts +85 -0
  165. package/dist/skills/frontend/scripts/detect/rules/decoration/support/raster-state.ts +51 -0
  166. package/dist/skills/frontend/scripts/detect/rules/index.ts +16 -0
  167. package/dist/skills/frontend/scripts/detect/rules/layout/body-text-viewport-edge.test.ts +64 -0
  168. package/dist/skills/frontend/scripts/detect/rules/layout/body-text-viewport-edge.ts +62 -0
  169. package/dist/skills/frontend/scripts/detect/rules/layout/clipped-overflow-container.test.ts +40 -0
  170. package/dist/skills/frontend/scripts/detect/rules/layout/clipped-overflow-container.ts +15 -0
  171. package/dist/skills/frontend/scripts/detect/rules/layout/content-hidden-at-rest.test.ts +62 -0
  172. package/dist/skills/frontend/scripts/detect/rules/layout/content-hidden-at-rest.ts +63 -0
  173. package/dist/skills/frontend/scripts/detect/rules/layout/cramped-padding.test.ts +61 -0
  174. package/dist/skills/frontend/scripts/detect/rules/layout/cramped-padding.ts +97 -0
  175. package/dist/skills/frontend/scripts/detect/rules/layout/edge-flush-cards.test.ts +43 -0
  176. package/dist/skills/frontend/scripts/detect/rules/layout/edge-flush-cards.ts +47 -0
  177. package/dist/skills/frontend/scripts/detect/rules/layout/first-viewport-column-overflow.test.ts +28 -0
  178. package/dist/skills/frontend/scripts/detect/rules/layout/first-viewport-column-overflow.ts +43 -0
  179. package/dist/skills/frontend/scripts/detect/rules/layout/heading-rhythm.test.ts +67 -0
  180. package/dist/skills/frontend/scripts/detect/rules/layout/heading-rhythm.ts +30 -0
  181. package/dist/skills/frontend/scripts/detect/rules/layout/index.ts +21 -0
  182. package/dist/skills/frontend/scripts/detect/rules/layout/monotonous-spacing.test.ts +19 -0
  183. package/dist/skills/frontend/scripts/detect/rules/layout/monotonous-spacing.ts +32 -0
  184. package/dist/skills/frontend/scripts/detect/rules/layout/nested-cards.test.ts +60 -0
  185. package/dist/skills/frontend/scripts/detect/rules/layout/nested-cards.ts +38 -0
  186. package/dist/skills/frontend/scripts/detect/rules/layout/straggler.test.ts +33 -0
  187. package/dist/skills/frontend/scripts/detect/rules/layout/straggler.ts +28 -0
  188. package/dist/skills/frontend/scripts/detect/rules/layout/support/cards.ts +114 -0
  189. package/dist/skills/frontend/scripts/detect/rules/layout/support/clipping.ts +71 -0
  190. package/dist/skills/frontend/scripts/detect/rules/layout/support/declared-mockups.ts +46 -0
  191. package/dist/skills/frontend/scripts/detect/rules/layout/support/geometry.ts +73 -0
  192. package/dist/skills/frontend/scripts/detect/rules/layout/support/hidden-interface.ts +35 -0
  193. package/dist/skills/frontend/scripts/detect/rules/layout/support/layout-cases.ts +23 -0
  194. package/dist/skills/frontend/scripts/detect/rules/layout/support/line-breaks.ts +32 -0
  195. package/dist/skills/frontend/scripts/detect/rules/layout/support/motion.ts +77 -0
  196. package/dist/skills/frontend/scripts/detect/rules/layout/support/padding.ts +93 -0
  197. package/dist/skills/frontend/scripts/detect/rules/layout/support/rhythm.ts +161 -0
  198. package/dist/skills/frontend/scripts/detect/rules/layout/text-occlusion.test.ts +37 -0
  199. package/dist/skills/frontend/scripts/detect/rules/layout/text-occlusion.ts +84 -0
  200. package/dist/skills/frontend/scripts/detect/rules/layout/text-overflow.test.ts +83 -0
  201. package/dist/skills/frontend/scripts/detect/rules/layout/text-overflow.ts +72 -0
  202. package/dist/skills/frontend/scripts/detect/rules/layout/unbalanced-heading.test.ts +22 -0
  203. package/dist/skills/frontend/scripts/detect/rules/layout/unbalanced-heading.ts +22 -0
  204. package/dist/skills/frontend/scripts/detect/rules/layout/viewport-reflow.test.ts +34 -0
  205. package/dist/skills/frontend/scripts/detect/rules/layout/viewport-reflow.ts +33 -0
  206. package/dist/skills/frontend/scripts/detect/rules/source/ai-color-palette.test.ts +13 -0
  207. package/dist/skills/frontend/scripts/detect/rules/source/ai-color-palette.ts +11 -0
  208. package/dist/skills/frontend/scripts/detect/rules/source/aphoristic-cadence.test.ts +12 -0
  209. package/dist/skills/frontend/scripts/detect/rules/source/aphoristic-cadence.ts +14 -0
  210. package/dist/skills/frontend/scripts/detect/rules/source/border-accent-on-rounded.test.ts +14 -0
  211. package/dist/skills/frontend/scripts/detect/rules/source/border-accent-on-rounded.ts +20 -0
  212. package/dist/skills/frontend/scripts/detect/rules/source/bounce-easing.test.ts +19 -0
  213. package/dist/skills/frontend/scripts/detect/rules/source/bounce-easing.ts +21 -0
  214. package/dist/skills/frontend/scripts/detect/rules/source/broken-image.test.ts +27 -0
  215. package/dist/skills/frontend/scripts/detect/rules/source/broken-image.ts +16 -0
  216. package/dist/skills/frontend/scripts/detect/rules/source/codex-grid-background.test.ts +11 -0
  217. package/dist/skills/frontend/scripts/detect/rules/source/codex-grid-background.ts +18 -0
  218. package/dist/skills/frontend/scripts/detect/rules/source/dark-glow.test.ts +15 -0
  219. package/dist/skills/frontend/scripts/detect/rules/source/dark-glow.ts +21 -0
  220. package/dist/skills/frontend/scripts/detect/rules/source/em-dash-overuse.test.ts +13 -0
  221. package/dist/skills/frontend/scripts/detect/rules/source/em-dash-overuse.ts +15 -0
  222. package/dist/skills/frontend/scripts/detect/rules/source/gradient-text.test.ts +12 -0
  223. package/dist/skills/frontend/scripts/detect/rules/source/gradient-text.ts +11 -0
  224. package/dist/skills/frontend/scripts/detect/rules/source/gray-on-color.test.ts +20 -0
  225. package/dist/skills/frontend/scripts/detect/rules/source/gray-on-color.ts +13 -0
  226. package/dist/skills/frontend/scripts/detect/rules/source/index.ts +19 -0
  227. package/dist/skills/frontend/scripts/detect/rules/source/marketing-buzzword.test.ts +12 -0
  228. package/dist/skills/frontend/scripts/detect/rules/source/marketing-buzzword.ts +17 -0
  229. package/dist/skills/frontend/scripts/detect/rules/source/marquee.test.ts +12 -0
  230. package/dist/skills/frontend/scripts/detect/rules/source/marquee.ts +12 -0
  231. package/dist/skills/frontend/scripts/detect/rules/source/monotonous-spacing.test.ts +13 -0
  232. package/dist/skills/frontend/scripts/detect/rules/source/monotonous-spacing.ts +22 -0
  233. package/dist/skills/frontend/scripts/detect/rules/source/overused-font.test.ts +21 -0
  234. package/dist/skills/frontend/scripts/detect/rules/source/overused-font.ts +16 -0
  235. package/dist/skills/frontend/scripts/detect/rules/source/radial-halo.test.ts +16 -0
  236. package/dist/skills/frontend/scripts/detect/rules/source/radial-halo.ts +14 -0
  237. package/dist/skills/frontend/scripts/detect/rules/source/side-tab.test.ts +29 -0
  238. package/dist/skills/frontend/scripts/detect/rules/source/side-tab.ts +58 -0
  239. package/dist/skills/frontend/scripts/detect/rules/source/support/accent-scans.ts +78 -0
  240. package/dist/skills/frontend/scripts/detect/rules/source/support/check-source.ts +6 -0
  241. package/dist/skills/frontend/scripts/detect/rules/source/support/corners.ts +105 -0
  242. package/dist/skills/frontend/scripts/detect/rules/source/support/css-effects.ts +81 -0
  243. package/dist/skills/frontend/scripts/detect/rules/source/support/css-scopes.ts +131 -0
  244. package/dist/skills/frontend/scripts/detect/rules/source/support/image-tags.ts +113 -0
  245. package/dist/skills/frontend/scripts/detect/rules/source/support/js-punctuation.ts +34 -0
  246. package/dist/skills/frontend/scripts/detect/rules/source/support/markup-scope.ts +44 -0
  247. package/dist/skills/frontend/scripts/detect/rules/source/support/source-color.ts +42 -0
  248. package/dist/skills/frontend/scripts/detect/rules/source/support/source-shadow.ts +15 -0
  249. package/dist/skills/frontend/scripts/detect/rules/source/support/source-text.ts +110 -0
  250. package/dist/skills/frontend/scripts/detect/rules/typography/all-caps-body.test.ts +24 -0
  251. package/dist/skills/frontend/scripts/detect/rules/typography/all-caps-body.ts +15 -0
  252. package/dist/skills/frontend/scripts/detect/rules/typography/design-system-font-size.test.ts +21 -0
  253. package/dist/skills/frontend/scripts/detect/rules/typography/design-system-font-size.ts +23 -0
  254. package/dist/skills/frontend/scripts/detect/rules/typography/design-system-font.test.ts +22 -0
  255. package/dist/skills/frontend/scripts/detect/rules/typography/design-system-font.ts +24 -0
  256. package/dist/skills/frontend/scripts/detect/rules/typography/extreme-negative-tracking.test.ts +23 -0
  257. package/dist/skills/frontend/scripts/detect/rules/typography/extreme-negative-tracking.ts +18 -0
  258. package/dist/skills/frontend/scripts/detect/rules/typography/flat-type-hierarchy.test.ts +33 -0
  259. package/dist/skills/frontend/scripts/detect/rules/typography/flat-type-hierarchy.ts +26 -0
  260. package/dist/skills/frontend/scripts/detect/rules/typography/index.ts +21 -0
  261. package/dist/skills/frontend/scripts/detect/rules/typography/italic-serif-display.test.ts +24 -0
  262. package/dist/skills/frontend/scripts/detect/rules/typography/italic-serif-display.ts +24 -0
  263. package/dist/skills/frontend/scripts/detect/rules/typography/justified-text.test.ts +31 -0
  264. package/dist/skills/frontend/scripts/detect/rules/typography/justified-text.ts +32 -0
  265. package/dist/skills/frontend/scripts/detect/rules/typography/line-length.test.ts +43 -0
  266. package/dist/skills/frontend/scripts/detect/rules/typography/line-length.ts +28 -0
  267. package/dist/skills/frontend/scripts/detect/rules/typography/oversized-h1.test.ts +26 -0
  268. package/dist/skills/frontend/scripts/detect/rules/typography/oversized-h1.ts +20 -0
  269. package/dist/skills/frontend/scripts/detect/rules/typography/overused-font.test.ts +35 -0
  270. package/dist/skills/frontend/scripts/detect/rules/typography/overused-font.ts +45 -0
  271. package/dist/skills/frontend/scripts/detect/rules/typography/support/drawn-enlargement.ts +48 -0
  272. package/dist/skills/frontend/scripts/detect/rules/typography/support/fading-text.ts +48 -0
  273. package/dist/skills/frontend/scripts/detect/rules/typography/support/flex-runs.ts +16 -0
  274. package/dist/skills/frontend/scripts/detect/rules/typography/support/font-family.ts +28 -0
  275. package/dist/skills/frontend/scripts/detect/rules/typography/support/painted-text.test.ts +63 -0
  276. package/dist/skills/frontend/scripts/detect/rules/typography/support/painted-text.ts +81 -0
  277. package/dist/skills/frontend/scripts/detect/rules/typography/support/svg-size.ts +57 -0
  278. package/dist/skills/frontend/scripts/detect/rules/typography/support/text-context.ts +112 -0
  279. package/dist/skills/frontend/scripts/detect/rules/typography/support/text-lines.ts +43 -0
  280. package/dist/skills/frontend/scripts/detect/rules/typography/support/type-hierarchy.ts +48 -0
  281. package/dist/skills/frontend/scripts/detect/rules/typography/tight-leading.test.ts +54 -0
  282. package/dist/skills/frontend/scripts/detect/rules/typography/tight-leading.ts +47 -0
  283. package/dist/skills/frontend/scripts/detect/rules/typography/tiny-text.test.ts +60 -0
  284. package/dist/skills/frontend/scripts/detect/rules/typography/tiny-text.ts +23 -0
  285. package/dist/skills/frontend/scripts/detect/rules/typography/undersized-ui-text.test.ts +98 -0
  286. package/dist/skills/frontend/scripts/detect/rules/typography/undersized-ui-text.ts +28 -0
  287. package/dist/skills/frontend/scripts/detect/rules/typography/wide-tracking.test.ts +26 -0
  288. package/dist/skills/frontend/scripts/detect/rules/typography/wide-tracking.ts +26 -0
  289. package/dist/skills/frontend/scripts/detect/snapshot/collect.ts +158 -0
  290. package/dist/skills/frontend/scripts/detect/snapshot/style-props.ts +25 -0
  291. package/dist/skills/frontend/scripts/detect/testing/build-snapshot.ts +78 -0
  292. package/dist/skills/frontend/scripts/detect/tsconfig.json +19 -0
  293. package/dist/skills/frontend/scripts/detect/types.ts +124 -0
  294. package/dist/skills/programming/SKILL.md +17 -74
  295. package/dist/skills/programming/references/go/README.md +1 -1
  296. package/dist/skills/programming/references/go/bootstrap.md +2 -2
  297. package/dist/skills/programming/references/python/README.md +4 -4
  298. package/dist/skills/programming/references/python/one-liners.md +5 -5
  299. package/dist/skills/programming/references/testing/README.md +82 -0
  300. package/dist/skills/programming/references/testing/junk-classes.md +56 -0
  301. package/dist/skills/programming/references/typescript/README.md +1 -2
  302. package/dist/skills/programming/scripts/go/new-project.ts +197 -0
  303. package/dist/skills/programming/scripts/python/new-project.ts +231 -0
  304. package/dist/skills/programming/scripts/python/new-script.ts +134 -0
  305. package/dist/skills/programming/scripts/rust/new-project.ts +215 -0
  306. package/dist/skills/programming/scripts/scaffolders.test.ts +96 -0
  307. package/dist/skills/programming/scripts/shared/run-tool.ts +19 -0
  308. package/dist/skills/programming/scripts/typescript/check-test-junk-rules.ts +140 -0
  309. package/dist/skills/programming/scripts/typescript/check-test-junk.test.ts +125 -0
  310. package/dist/skills/programming/scripts/typescript/check-test-junk.ts +148 -0
  311. package/dist/skills/programming/scripts/typescript/mutation-proof.test.ts +43 -0
  312. package/dist/skills/programming/scripts/typescript/mutation-proof.ts +179 -0
  313. package/dist/skills/remove-ai-slops/SKILL.md +32 -20
  314. package/dist/skills/ulw-research/scripts/source-commands.mjs +3 -1
  315. package/dist/skills/ulw-research/scripts/source-integrity.test.ts +39 -2
  316. package/dist/skills/visual-qa/SKILL.md +12 -1
  317. package/dist/tools/delegate-task/models-distribution.d.ts +1 -0
  318. package/dist/tui.js +142 -42
  319. package/package.json +22 -19
  320. package/packages/lsp-core/src/lsp/config-loader.ts +18 -2
  321. package/packages/lsp-core/src/lsp/host-js-runtime.test.ts +150 -0
  322. package/packages/lsp-core/src/lsp/host-js-runtime.ts +57 -0
  323. package/packages/lsp-core/src/lsp/server-definitions.ts +10 -0
  324. package/packages/lsp-core/src/lsp/server-resolution.ts +9 -1
  325. package/packages/lsp-core/src/lsp/typescript-server-defaults.test.ts +84 -0
  326. package/packages/lsp-daemon/dist/cli.js +81 -15
  327. package/packages/lsp-daemon/dist/client.js +74 -8
  328. package/packages/lsp-daemon/dist/index.js +76 -10
  329. package/packages/lsp-tools-mcp/dist/cli.js +74 -8
  330. package/packages/lsp-tools-mcp/dist/mcp.js +74 -8
  331. package/packages/lsp-tools-mcp/dist/tools.js +74 -8
  332. package/packages/omo-codex/plugin/.codex-plugin/plugin.json +1 -1
  333. package/packages/omo-codex/plugin/components/bootstrap/dist/cli.js +22 -4
  334. package/packages/omo-codex/plugin/components/bootstrap/hooks/hooks.json +1 -1
  335. package/packages/omo-codex/plugin/components/bootstrap/package.json +1 -1
  336. package/packages/omo-codex/plugin/components/comment-checker/hooks/hooks.json +1 -1
  337. package/packages/omo-codex/plugin/components/comment-checker/package.json +1 -1
  338. package/packages/omo-codex/plugin/components/git-bash/hooks/hooks.json +2 -2
  339. package/packages/omo-codex/plugin/components/git-bash/package.json +1 -1
  340. package/packages/omo-codex/plugin/components/lazycodex-executor-verify/hooks/hooks.json +1 -1
  341. package/packages/omo-codex/plugin/components/lazycodex-executor-verify/package.json +1 -1
  342. package/packages/omo-codex/plugin/components/lsp/dist/.omo-runtime-manifest.json +3 -3
  343. package/packages/omo-codex/plugin/components/lsp/dist/cli.js +77 -13
  344. package/packages/omo-codex/plugin/components/lsp/hooks/hooks.json +2 -2
  345. package/packages/omo-codex/plugin/components/lsp/package.json +1 -1
  346. package/packages/omo-codex/plugin/components/rules/hooks/hooks.json +4 -4
  347. package/packages/omo-codex/plugin/components/rules/package.json +1 -1
  348. package/packages/omo-codex/plugin/components/teammode/hooks/hooks.json +1 -1
  349. package/packages/omo-codex/plugin/components/teammode/package.json +1 -1
  350. package/packages/omo-codex/plugin/components/telemetry/dist/cli.js +34 -2
  351. package/packages/omo-codex/plugin/components/telemetry/dist/posthog.js +34 -2
  352. package/packages/omo-codex/plugin/components/telemetry/hooks/hooks.json +1 -1
  353. package/packages/omo-codex/plugin/components/telemetry/package.json +1 -1
  354. package/packages/omo-codex/plugin/components/telemetry/test/codex-hook.test.ts +14 -1
  355. package/packages/omo-codex/plugin/components/ultrawork/hooks/hooks.json +1 -1
  356. package/packages/omo-codex/plugin/components/ultrawork/package.json +1 -1
  357. package/packages/omo-codex/plugin/components/ulw-execute-continuation/hooks/hooks.json +1 -1
  358. package/packages/omo-codex/plugin/components/ulw-execute-continuation/package.json +1 -1
  359. package/packages/omo-codex/plugin/components/ulw-loop/hooks/hooks.json +5 -5
  360. package/packages/omo-codex/plugin/components/ulw-loop/package.json +1 -1
  361. package/packages/omo-codex/plugin/hooks/post-compact-resetting-git-bash-mcp-reminder.json +1 -1
  362. package/packages/omo-codex/plugin/hooks/post-compact-resetting-lsp-diagnostics-cache.json +1 -1
  363. package/packages/omo-codex/plugin/hooks/post-compact-resetting-project-rule-cache.json +1 -1
  364. package/packages/omo-codex/plugin/hooks/post-tool-use-checking-comments.json +1 -1
  365. package/packages/omo-codex/plugin/hooks/post-tool-use-checking-lsp-diagnostics.json +1 -1
  366. package/packages/omo-codex/plugin/hooks/post-tool-use-checking-thread-title-hygiene.json +1 -1
  367. package/packages/omo-codex/plugin/hooks/post-tool-use-matching-project-rules.json +1 -1
  368. package/packages/omo-codex/plugin/hooks/post-tool-use-recording-spawn-admission.json +1 -1
  369. package/packages/omo-codex/plugin/hooks/pre-tool-use-enforcing-unlimited-goal-budget.json +1 -1
  370. package/packages/omo-codex/plugin/hooks/pre-tool-use-guarding-ulw-loop-spawns.json +1 -1
  371. package/packages/omo-codex/plugin/hooks/pre-tool-use-recommending-git-bash-mcp.json +1 -1
  372. package/packages/omo-codex/plugin/hooks/session-start-checking-auto-update.json +1 -1
  373. package/packages/omo-codex/plugin/hooks/session-start-checking-bootstrap-provisioning.json +1 -1
  374. package/packages/omo-codex/plugin/hooks/session-start-loading-project-rules.json +1 -1
  375. package/packages/omo-codex/plugin/hooks/session-start-recording-session-telemetry.json +1 -1
  376. package/packages/omo-codex/plugin/hooks/stop-checking-ulw-execute-continuation.json +1 -1
  377. package/packages/omo-codex/plugin/hooks/stop-checking-ulw-loop-resume.json +1 -1
  378. package/packages/omo-codex/plugin/hooks/subagent-stop-verifying-lazycodex-executor-evidence.json +1 -1
  379. package/packages/omo-codex/plugin/hooks/user-prompt-submit-checking-ultrawork-trigger.json +1 -1
  380. package/packages/omo-codex/plugin/hooks/user-prompt-submit-checking-ulw-loop-steering.json +1 -1
  381. package/packages/omo-codex/plugin/hooks/user-prompt-submit-loading-project-rules.json +1 -1
  382. package/packages/omo-codex/plugin/package-lock.json +12 -12
  383. package/packages/omo-codex/plugin/package.json +1 -1
  384. package/packages/omo-codex/plugin/scripts/auto-update-plan.mjs +16 -1
  385. package/packages/omo-codex/plugin/skills/browser/runtime/omowright/index.js +24 -33
  386. package/packages/omo-codex/plugin/skills/browser/runtime/omowright/manifest.json +3 -3
  387. package/packages/omo-codex/plugin/skills/frontend/ATTRIBUTION.md +104 -1
  388. package/packages/omo-codex/plugin/skills/frontend/SKILL.md +7 -3
  389. package/packages/omo-codex/plugin/skills/frontend/references/design/design-system-architecture.md +3 -3
  390. package/packages/omo-codex/plugin/skills/frontend/references/perfection/craft-floor.md +59 -0
  391. package/packages/omo-codex/plugin/skills/frontend/references/perfection/detect.md +52 -0
  392. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/cli.ts +70 -0
  393. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/config.ts +53 -0
  394. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/core/characters.ts +2 -0
  395. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/core/color.ts +150 -0
  396. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/core/page.ts +84 -0
  397. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/core/shadow.ts +40 -0
  398. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/core/source.ts +33 -0
  399. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/detect.ts +77 -0
  400. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/index.ts +23 -0
  401. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/lint.ts +98 -0
  402. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/render/probe-placement.ts +50 -0
  403. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/render/renderer.ts +37 -0
  404. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/render/webview.ts +71 -0
  405. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/report.ts +29 -0
  406. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rule.ts +42 -0
  407. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/color/ai-color-palette.ts +83 -0
  408. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/color/cream-palette.ts +35 -0
  409. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/color/dark-glow.ts +44 -0
  410. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/color/design-system-color.ts +35 -0
  411. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/color/gradient-text.ts +59 -0
  412. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/color/gray-on-color.ts +38 -0
  413. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/color/index.ts +15 -0
  414. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/color/low-contrast.ts +57 -0
  415. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/color/radial-halo.ts +31 -0
  416. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/color/radial-spotlight-glow.ts +33 -0
  417. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/color/support/animation-opacity.ts +78 -0
  418. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/color/support/color-path.ts +15 -0
  419. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/color/support/contrast-pairs.ts +54 -0
  420. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/color/support/contrast-role.ts +76 -0
  421. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/color/support/glow-forms.ts +56 -0
  422. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/color/support/gradient-samples.ts +134 -0
  423. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/color/support/gradients.ts +91 -0
  424. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/color/support/mockup-roots.ts +63 -0
  425. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/color/support/page-ignore.ts +7 -0
  426. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/color/support/painted-text.ts +141 -0
  427. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/color/support/palette-roles.ts +58 -0
  428. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/color/support/placeholder-contrast.ts +25 -0
  429. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/color/support/stock-accent.ts +31 -0
  430. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/color/support/text-colors.ts +80 -0
  431. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/copy/aphoristic-cadence.ts +20 -0
  432. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/copy/broken-image.ts +17 -0
  433. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/copy/em-dash-overuse.ts +46 -0
  434. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/copy/index.ts +15 -0
  435. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/copy/marketing-buzzword.ts +33 -0
  436. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/copy/numbered-section-labels.ts +34 -0
  437. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/copy/repeated-container-text.ts +56 -0
  438. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/copy/script-error.ts +38 -0
  439. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/copy/skipped-heading.ts +81 -0
  440. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/copy/support/numbered-label.ts +94 -0
  441. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/copy/support/page-text.ts +37 -0
  442. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/copy/theater-slop-phrase.ts +21 -0
  443. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/decoration/blinking-cursor.ts +48 -0
  444. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/decoration/border-accent-on-rounded.ts +14 -0
  445. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/decoration/bounce-easing.ts +83 -0
  446. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/decoration/buried-raster.ts +72 -0
  447. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/decoration/codex-grid-background.ts +34 -0
  448. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/decoration/design-system-radius.ts +31 -0
  449. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/decoration/gpt-thin-border-wide-shadow.ts +66 -0
  450. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/decoration/hard-offset-shadow.ts +31 -0
  451. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/decoration/hero-eyebrow-chip.ts +19 -0
  452. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/decoration/icon-tile-stack.ts +92 -0
  453. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/decoration/index.ts +38 -0
  454. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/decoration/kicker-above-heading.ts +69 -0
  455. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/decoration/marquee.ts +51 -0
  456. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/decoration/organic-clip-path.ts +41 -0
  457. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/decoration/pulsing-dot.ts +72 -0
  458. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/decoration/repeating-stripes-gradient.ts +25 -0
  459. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/decoration/shape-assembled-illustration.ts +58 -0
  460. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/decoration/side-tab.ts +17 -0
  461. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/decoration/support/appearance.ts +110 -0
  462. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/decoration/support/assert-cases.ts +25 -0
  463. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/decoration/support/borders.ts +150 -0
  464. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/decoration/support/clip-geometry.ts +151 -0
  465. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/decoration/support/css-candidates.ts +66 -0
  466. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/decoration/support/curve-samples.ts +55 -0
  467. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/decoration/support/gradient-pattern.ts +40 -0
  468. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/decoration/support/keyframes.ts +134 -0
  469. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/decoration/support/labels.ts +85 -0
  470. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/decoration/support/raster-state.ts +51 -0
  471. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/index.ts +16 -0
  472. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/layout/body-text-viewport-edge.ts +62 -0
  473. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/layout/clipped-overflow-container.ts +15 -0
  474. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/layout/content-hidden-at-rest.ts +63 -0
  475. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/layout/cramped-padding.ts +97 -0
  476. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/layout/edge-flush-cards.ts +47 -0
  477. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/layout/first-viewport-column-overflow.ts +43 -0
  478. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/layout/heading-rhythm.ts +30 -0
  479. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/layout/index.ts +21 -0
  480. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/layout/monotonous-spacing.ts +32 -0
  481. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/layout/nested-cards.ts +38 -0
  482. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/layout/straggler.ts +28 -0
  483. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/layout/support/cards.ts +114 -0
  484. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/layout/support/clipping.ts +71 -0
  485. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/layout/support/declared-mockups.ts +46 -0
  486. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/layout/support/geometry.ts +73 -0
  487. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/layout/support/hidden-interface.ts +35 -0
  488. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/layout/support/layout-cases.ts +23 -0
  489. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/layout/support/line-breaks.ts +32 -0
  490. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/layout/support/motion.ts +77 -0
  491. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/layout/support/padding.ts +93 -0
  492. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/layout/support/rhythm.ts +161 -0
  493. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/layout/text-occlusion.ts +84 -0
  494. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/layout/text-overflow.ts +72 -0
  495. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/layout/unbalanced-heading.ts +22 -0
  496. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/layout/viewport-reflow.ts +33 -0
  497. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/source/ai-color-palette.ts +11 -0
  498. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/source/aphoristic-cadence.ts +14 -0
  499. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/source/border-accent-on-rounded.ts +20 -0
  500. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/source/bounce-easing.ts +21 -0
  501. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/source/broken-image.ts +16 -0
  502. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/source/codex-grid-background.ts +18 -0
  503. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/source/dark-glow.ts +21 -0
  504. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/source/em-dash-overuse.ts +15 -0
  505. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/source/gradient-text.ts +11 -0
  506. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/source/gray-on-color.ts +13 -0
  507. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/source/index.ts +19 -0
  508. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/source/marketing-buzzword.ts +17 -0
  509. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/source/marquee.ts +12 -0
  510. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/source/monotonous-spacing.ts +22 -0
  511. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/source/overused-font.ts +16 -0
  512. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/source/radial-halo.ts +14 -0
  513. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/source/side-tab.ts +58 -0
  514. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/source/support/accent-scans.ts +78 -0
  515. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/source/support/check-source.ts +6 -0
  516. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/source/support/corners.ts +105 -0
  517. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/source/support/css-effects.ts +81 -0
  518. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/source/support/css-scopes.ts +131 -0
  519. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/source/support/image-tags.ts +113 -0
  520. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/source/support/js-punctuation.ts +34 -0
  521. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/source/support/markup-scope.ts +44 -0
  522. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/source/support/source-color.ts +42 -0
  523. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/source/support/source-shadow.ts +15 -0
  524. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/source/support/source-text.ts +110 -0
  525. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/typography/all-caps-body.ts +15 -0
  526. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/typography/design-system-font-size.ts +23 -0
  527. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/typography/design-system-font.ts +24 -0
  528. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/typography/extreme-negative-tracking.ts +18 -0
  529. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/typography/flat-type-hierarchy.ts +26 -0
  530. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/typography/index.ts +21 -0
  531. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/typography/italic-serif-display.ts +24 -0
  532. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/typography/justified-text.ts +32 -0
  533. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/typography/line-length.ts +28 -0
  534. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/typography/oversized-h1.ts +20 -0
  535. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/typography/overused-font.ts +45 -0
  536. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/typography/support/drawn-enlargement.ts +48 -0
  537. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/typography/support/fading-text.ts +48 -0
  538. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/typography/support/flex-runs.ts +16 -0
  539. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/typography/support/font-family.ts +28 -0
  540. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/typography/support/painted-text.ts +81 -0
  541. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/typography/support/svg-size.ts +57 -0
  542. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/typography/support/text-context.ts +112 -0
  543. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/typography/support/text-lines.ts +43 -0
  544. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/typography/support/type-hierarchy.ts +48 -0
  545. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/typography/tight-leading.ts +47 -0
  546. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/typography/tiny-text.ts +23 -0
  547. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/typography/undersized-ui-text.ts +28 -0
  548. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/rules/typography/wide-tracking.ts +26 -0
  549. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/snapshot/collect.ts +158 -0
  550. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/snapshot/style-props.ts +25 -0
  551. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/testing/build-snapshot.ts +78 -0
  552. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/tsconfig.json +19 -0
  553. package/packages/omo-codex/plugin/skills/frontend/scripts/detect/types.ts +124 -0
  554. package/packages/omo-codex/plugin/skills/programming/SKILL.md +17 -74
  555. package/packages/omo-codex/plugin/skills/programming/references/go/README.md +1 -1
  556. package/packages/omo-codex/plugin/skills/programming/references/go/bootstrap.md +2 -2
  557. package/packages/omo-codex/plugin/skills/programming/references/python/README.md +4 -4
  558. package/packages/omo-codex/plugin/skills/programming/references/python/one-liners.md +5 -5
  559. package/packages/omo-codex/plugin/skills/programming/references/testing/README.md +82 -0
  560. package/packages/omo-codex/plugin/skills/programming/references/testing/junk-classes.md +56 -0
  561. package/packages/omo-codex/plugin/skills/programming/references/typescript/README.md +1 -2
  562. package/packages/omo-codex/plugin/skills/programming/scripts/go/new-project.ts +197 -0
  563. package/packages/omo-codex/plugin/skills/programming/scripts/python/new-project.ts +231 -0
  564. package/packages/omo-codex/plugin/skills/programming/scripts/python/new-script.ts +134 -0
  565. package/packages/omo-codex/plugin/skills/programming/scripts/rust/new-project.ts +215 -0
  566. package/packages/omo-codex/plugin/skills/programming/scripts/shared/run-tool.ts +19 -0
  567. package/packages/omo-codex/plugin/skills/programming/scripts/typescript/check-test-junk-rules.ts +140 -0
  568. package/packages/omo-codex/plugin/skills/programming/scripts/typescript/check-test-junk.ts +148 -0
  569. package/packages/omo-codex/plugin/skills/programming/scripts/typescript/mutation-proof.ts +179 -0
  570. package/packages/omo-codex/plugin/skills/remove-ai-slops/SKILL.md +32 -20
  571. package/packages/omo-codex/plugin/skills/ulw-research/scripts/source-commands.mjs +3 -1
  572. package/packages/omo-codex/plugin/skills/visual-qa/SKILL.md +12 -1
  573. package/packages/omo-codex/plugin/test/auto-update.test.mjs +62 -0
  574. package/packages/omo-codex/plugin/test/payload-equivalence.test.mjs +12 -2
  575. package/packages/omo-codex/scripts/install-dist/install-local.mjs +79 -10
  576. package/packages/shared-skills/skills/browser/runtime/omowright/index.js +24 -33
  577. package/packages/shared-skills/skills/browser/runtime/omowright/manifest.json +3 -3
  578. package/packages/shared-skills/skills/frontend/ATTRIBUTION.md +104 -1
  579. package/packages/shared-skills/skills/frontend/SKILL.md +7 -3
  580. package/packages/shared-skills/skills/frontend/references/design/design-system-architecture.md +3 -3
  581. package/packages/shared-skills/skills/frontend/references/perfection/craft-floor.md +59 -0
  582. package/packages/shared-skills/skills/frontend/references/perfection/detect.md +52 -0
  583. package/packages/shared-skills/skills/frontend/scripts/detect/cli.ts +70 -0
  584. package/packages/shared-skills/skills/frontend/scripts/detect/config.test.ts +26 -0
  585. package/packages/shared-skills/skills/frontend/scripts/detect/config.ts +53 -0
  586. package/packages/shared-skills/skills/frontend/scripts/detect/core/characters.ts +2 -0
  587. package/packages/shared-skills/skills/frontend/scripts/detect/core/color.test.ts +29 -0
  588. package/packages/shared-skills/skills/frontend/scripts/detect/core/color.ts +150 -0
  589. package/packages/shared-skills/skills/frontend/scripts/detect/core/page.ts +84 -0
  590. package/packages/shared-skills/skills/frontend/scripts/detect/core/shadow.ts +40 -0
  591. package/packages/shared-skills/skills/frontend/scripts/detect/core/source.ts +33 -0
  592. package/packages/shared-skills/skills/frontend/scripts/detect/detect.ts +77 -0
  593. package/packages/shared-skills/skills/frontend/scripts/detect/index.ts +23 -0
  594. package/packages/shared-skills/skills/frontend/scripts/detect/lint.test.ts +27 -0
  595. package/packages/shared-skills/skills/frontend/scripts/detect/lint.ts +98 -0
  596. package/packages/shared-skills/skills/frontend/scripts/detect/render/probe-placement.test.ts +19 -0
  597. package/packages/shared-skills/skills/frontend/scripts/detect/render/probe-placement.ts +50 -0
  598. package/packages/shared-skills/skills/frontend/scripts/detect/render/renderer.ts +37 -0
  599. package/packages/shared-skills/skills/frontend/scripts/detect/render/webview.ts +71 -0
  600. package/packages/shared-skills/skills/frontend/scripts/detect/report.ts +29 -0
  601. package/packages/shared-skills/skills/frontend/scripts/detect/rule.ts +42 -0
  602. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/ai-color-palette.test.ts +74 -0
  603. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/ai-color-palette.ts +83 -0
  604. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/cream-palette.test.ts +24 -0
  605. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/cream-palette.ts +35 -0
  606. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/dark-glow.test.ts +47 -0
  607. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/dark-glow.ts +44 -0
  608. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/design-system-color.test.ts +26 -0
  609. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/design-system-color.ts +35 -0
  610. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/gradient-text.test.ts +24 -0
  611. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/gradient-text.ts +59 -0
  612. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/gray-on-color.test.ts +39 -0
  613. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/gray-on-color.ts +38 -0
  614. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/index.ts +15 -0
  615. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/low-contrast.test.ts +209 -0
  616. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/low-contrast.ts +57 -0
  617. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/placeholder-contrast.test.ts +62 -0
  618. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/radial-halo.test.ts +40 -0
  619. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/radial-halo.ts +31 -0
  620. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/radial-spotlight-glow.test.ts +27 -0
  621. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/radial-spotlight-glow.ts +33 -0
  622. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/support/animation-opacity.ts +78 -0
  623. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/support/color-path.ts +15 -0
  624. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/support/contrast-pairs.ts +54 -0
  625. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/support/contrast-role.ts +76 -0
  626. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/support/glow-forms.ts +56 -0
  627. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/support/gradient-samples.ts +134 -0
  628. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/support/gradients.ts +91 -0
  629. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/support/mockup-roots.ts +63 -0
  630. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/support/page-ignore.ts +7 -0
  631. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/support/painted-text.ts +141 -0
  632. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/support/palette-roles.ts +58 -0
  633. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/support/placeholder-contrast.ts +25 -0
  634. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/support/stock-accent.ts +31 -0
  635. package/packages/shared-skills/skills/frontend/scripts/detect/rules/color/support/text-colors.ts +80 -0
  636. package/packages/shared-skills/skills/frontend/scripts/detect/rules/copy/aphoristic-cadence.test.ts +18 -0
  637. package/packages/shared-skills/skills/frontend/scripts/detect/rules/copy/aphoristic-cadence.ts +20 -0
  638. package/packages/shared-skills/skills/frontend/scripts/detect/rules/copy/broken-image.test.ts +25 -0
  639. package/packages/shared-skills/skills/frontend/scripts/detect/rules/copy/broken-image.ts +17 -0
  640. package/packages/shared-skills/skills/frontend/scripts/detect/rules/copy/em-dash-overuse.test.ts +39 -0
  641. package/packages/shared-skills/skills/frontend/scripts/detect/rules/copy/em-dash-overuse.ts +46 -0
  642. package/packages/shared-skills/skills/frontend/scripts/detect/rules/copy/index.ts +15 -0
  643. package/packages/shared-skills/skills/frontend/scripts/detect/rules/copy/marketing-buzzword.test.ts +18 -0
  644. package/packages/shared-skills/skills/frontend/scripts/detect/rules/copy/marketing-buzzword.ts +33 -0
  645. package/packages/shared-skills/skills/frontend/scripts/detect/rules/copy/numbered-section-labels.test.ts +58 -0
  646. package/packages/shared-skills/skills/frontend/scripts/detect/rules/copy/numbered-section-labels.ts +34 -0
  647. package/packages/shared-skills/skills/frontend/scripts/detect/rules/copy/repeated-container-text.test.ts +43 -0
  648. package/packages/shared-skills/skills/frontend/scripts/detect/rules/copy/repeated-container-text.ts +56 -0
  649. package/packages/shared-skills/skills/frontend/scripts/detect/rules/copy/script-error.test.ts +48 -0
  650. package/packages/shared-skills/skills/frontend/scripts/detect/rules/copy/script-error.ts +38 -0
  651. package/packages/shared-skills/skills/frontend/scripts/detect/rules/copy/skipped-heading.test.ts +49 -0
  652. package/packages/shared-skills/skills/frontend/scripts/detect/rules/copy/skipped-heading.ts +81 -0
  653. package/packages/shared-skills/skills/frontend/scripts/detect/rules/copy/support/numbered-label.ts +94 -0
  654. package/packages/shared-skills/skills/frontend/scripts/detect/rules/copy/support/page-text.ts +37 -0
  655. package/packages/shared-skills/skills/frontend/scripts/detect/rules/copy/theater-slop-phrase.test.ts +17 -0
  656. package/packages/shared-skills/skills/frontend/scripts/detect/rules/copy/theater-slop-phrase.ts +21 -0
  657. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/blinking-cursor.test.ts +43 -0
  658. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/blinking-cursor.ts +48 -0
  659. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/border-accent-on-rounded.test.ts +33 -0
  660. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/border-accent-on-rounded.ts +14 -0
  661. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/bounce-easing.test.ts +72 -0
  662. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/bounce-easing.ts +83 -0
  663. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/buried-raster.test.ts +95 -0
  664. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/buried-raster.ts +72 -0
  665. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/codex-grid-background.test.ts +28 -0
  666. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/codex-grid-background.ts +34 -0
  667. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/design-system-radius.test.ts +37 -0
  668. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/design-system-radius.ts +31 -0
  669. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/gpt-thin-border-wide-shadow.test.ts +59 -0
  670. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/gpt-thin-border-wide-shadow.ts +66 -0
  671. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/hard-offset-shadow.test.ts +45 -0
  672. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/hard-offset-shadow.ts +31 -0
  673. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/hero-eyebrow-chip.test.ts +76 -0
  674. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/hero-eyebrow-chip.ts +19 -0
  675. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/icon-tile-stack.test.ts +67 -0
  676. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/icon-tile-stack.ts +92 -0
  677. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/index.ts +38 -0
  678. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/kicker-above-heading.test.ts +126 -0
  679. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/kicker-above-heading.ts +69 -0
  680. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/marquee.test.ts +63 -0
  681. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/marquee.ts +51 -0
  682. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/organic-clip-path.test.ts +67 -0
  683. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/organic-clip-path.ts +41 -0
  684. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/pulsing-dot.test.ts +58 -0
  685. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/pulsing-dot.ts +72 -0
  686. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/repeating-stripes-gradient.test.ts +26 -0
  687. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/repeating-stripes-gradient.ts +25 -0
  688. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/shape-assembled-illustration.test.ts +59 -0
  689. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/shape-assembled-illustration.ts +58 -0
  690. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/side-tab.test.ts +91 -0
  691. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/side-tab.ts +17 -0
  692. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/support/appearance.ts +110 -0
  693. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/support/assert-cases.ts +25 -0
  694. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/support/borders.ts +150 -0
  695. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/support/clip-geometry.ts +151 -0
  696. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/support/css-candidates.ts +66 -0
  697. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/support/curve-samples.ts +55 -0
  698. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/support/gradient-pattern.ts +40 -0
  699. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/support/keyframes.ts +134 -0
  700. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/support/labels.ts +85 -0
  701. package/packages/shared-skills/skills/frontend/scripts/detect/rules/decoration/support/raster-state.ts +51 -0
  702. package/packages/shared-skills/skills/frontend/scripts/detect/rules/index.ts +16 -0
  703. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/body-text-viewport-edge.test.ts +64 -0
  704. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/body-text-viewport-edge.ts +62 -0
  705. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/clipped-overflow-container.test.ts +40 -0
  706. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/clipped-overflow-container.ts +15 -0
  707. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/content-hidden-at-rest.test.ts +62 -0
  708. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/content-hidden-at-rest.ts +63 -0
  709. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/cramped-padding.test.ts +61 -0
  710. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/cramped-padding.ts +97 -0
  711. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/edge-flush-cards.test.ts +43 -0
  712. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/edge-flush-cards.ts +47 -0
  713. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/first-viewport-column-overflow.test.ts +28 -0
  714. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/first-viewport-column-overflow.ts +43 -0
  715. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/heading-rhythm.test.ts +67 -0
  716. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/heading-rhythm.ts +30 -0
  717. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/index.ts +21 -0
  718. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/monotonous-spacing.test.ts +19 -0
  719. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/monotonous-spacing.ts +32 -0
  720. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/nested-cards.test.ts +60 -0
  721. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/nested-cards.ts +38 -0
  722. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/straggler.test.ts +33 -0
  723. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/straggler.ts +28 -0
  724. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/support/cards.ts +114 -0
  725. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/support/clipping.ts +71 -0
  726. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/support/declared-mockups.ts +46 -0
  727. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/support/geometry.ts +73 -0
  728. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/support/hidden-interface.ts +35 -0
  729. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/support/layout-cases.ts +23 -0
  730. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/support/line-breaks.ts +32 -0
  731. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/support/motion.ts +77 -0
  732. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/support/padding.ts +93 -0
  733. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/support/rhythm.ts +161 -0
  734. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/text-occlusion.test.ts +37 -0
  735. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/text-occlusion.ts +84 -0
  736. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/text-overflow.test.ts +83 -0
  737. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/text-overflow.ts +72 -0
  738. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/unbalanced-heading.test.ts +22 -0
  739. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/unbalanced-heading.ts +22 -0
  740. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/viewport-reflow.test.ts +34 -0
  741. package/packages/shared-skills/skills/frontend/scripts/detect/rules/layout/viewport-reflow.ts +33 -0
  742. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/ai-color-palette.test.ts +13 -0
  743. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/ai-color-palette.ts +11 -0
  744. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/aphoristic-cadence.test.ts +12 -0
  745. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/aphoristic-cadence.ts +14 -0
  746. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/border-accent-on-rounded.test.ts +14 -0
  747. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/border-accent-on-rounded.ts +20 -0
  748. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/bounce-easing.test.ts +19 -0
  749. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/bounce-easing.ts +21 -0
  750. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/broken-image.test.ts +27 -0
  751. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/broken-image.ts +16 -0
  752. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/codex-grid-background.test.ts +11 -0
  753. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/codex-grid-background.ts +18 -0
  754. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/dark-glow.test.ts +15 -0
  755. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/dark-glow.ts +21 -0
  756. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/em-dash-overuse.test.ts +13 -0
  757. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/em-dash-overuse.ts +15 -0
  758. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/gradient-text.test.ts +12 -0
  759. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/gradient-text.ts +11 -0
  760. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/gray-on-color.test.ts +20 -0
  761. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/gray-on-color.ts +13 -0
  762. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/index.ts +19 -0
  763. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/marketing-buzzword.test.ts +12 -0
  764. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/marketing-buzzword.ts +17 -0
  765. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/marquee.test.ts +12 -0
  766. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/marquee.ts +12 -0
  767. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/monotonous-spacing.test.ts +13 -0
  768. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/monotonous-spacing.ts +22 -0
  769. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/overused-font.test.ts +21 -0
  770. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/overused-font.ts +16 -0
  771. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/radial-halo.test.ts +16 -0
  772. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/radial-halo.ts +14 -0
  773. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/side-tab.test.ts +29 -0
  774. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/side-tab.ts +58 -0
  775. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/support/accent-scans.ts +78 -0
  776. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/support/check-source.ts +6 -0
  777. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/support/corners.ts +105 -0
  778. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/support/css-effects.ts +81 -0
  779. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/support/css-scopes.ts +131 -0
  780. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/support/image-tags.ts +113 -0
  781. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/support/js-punctuation.ts +34 -0
  782. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/support/markup-scope.ts +44 -0
  783. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/support/source-color.ts +42 -0
  784. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/support/source-shadow.ts +15 -0
  785. package/packages/shared-skills/skills/frontend/scripts/detect/rules/source/support/source-text.ts +110 -0
  786. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/all-caps-body.test.ts +24 -0
  787. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/all-caps-body.ts +15 -0
  788. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/design-system-font-size.test.ts +21 -0
  789. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/design-system-font-size.ts +23 -0
  790. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/design-system-font.test.ts +22 -0
  791. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/design-system-font.ts +24 -0
  792. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/extreme-negative-tracking.test.ts +23 -0
  793. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/extreme-negative-tracking.ts +18 -0
  794. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/flat-type-hierarchy.test.ts +33 -0
  795. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/flat-type-hierarchy.ts +26 -0
  796. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/index.ts +21 -0
  797. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/italic-serif-display.test.ts +24 -0
  798. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/italic-serif-display.ts +24 -0
  799. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/justified-text.test.ts +31 -0
  800. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/justified-text.ts +32 -0
  801. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/line-length.test.ts +43 -0
  802. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/line-length.ts +28 -0
  803. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/oversized-h1.test.ts +26 -0
  804. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/oversized-h1.ts +20 -0
  805. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/overused-font.test.ts +35 -0
  806. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/overused-font.ts +45 -0
  807. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/support/drawn-enlargement.ts +48 -0
  808. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/support/fading-text.ts +48 -0
  809. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/support/flex-runs.ts +16 -0
  810. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/support/font-family.ts +28 -0
  811. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/support/painted-text.test.ts +63 -0
  812. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/support/painted-text.ts +81 -0
  813. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/support/svg-size.ts +57 -0
  814. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/support/text-context.ts +112 -0
  815. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/support/text-lines.ts +43 -0
  816. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/support/type-hierarchy.ts +48 -0
  817. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/tight-leading.test.ts +54 -0
  818. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/tight-leading.ts +47 -0
  819. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/tiny-text.test.ts +60 -0
  820. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/tiny-text.ts +23 -0
  821. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/undersized-ui-text.test.ts +98 -0
  822. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/undersized-ui-text.ts +28 -0
  823. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/wide-tracking.test.ts +26 -0
  824. package/packages/shared-skills/skills/frontend/scripts/detect/rules/typography/wide-tracking.ts +26 -0
  825. package/packages/shared-skills/skills/frontend/scripts/detect/snapshot/collect.ts +158 -0
  826. package/packages/shared-skills/skills/frontend/scripts/detect/snapshot/style-props.ts +25 -0
  827. package/packages/shared-skills/skills/frontend/scripts/detect/testing/build-snapshot.ts +78 -0
  828. package/packages/shared-skills/skills/frontend/scripts/detect/tsconfig.json +19 -0
  829. package/packages/shared-skills/skills/frontend/scripts/detect/types.ts +124 -0
  830. package/packages/shared-skills/skills/programming/SKILL.md +17 -74
  831. package/packages/shared-skills/skills/programming/references/go/README.md +1 -1
  832. package/packages/shared-skills/skills/programming/references/go/bootstrap.md +2 -2
  833. package/packages/shared-skills/skills/programming/references/python/README.md +4 -4
  834. package/packages/shared-skills/skills/programming/references/python/one-liners.md +5 -5
  835. package/packages/shared-skills/skills/programming/references/testing/README.md +82 -0
  836. package/packages/shared-skills/skills/programming/references/testing/junk-classes.md +56 -0
  837. package/packages/shared-skills/skills/programming/references/typescript/README.md +1 -2
  838. package/packages/shared-skills/skills/programming/scripts/go/new-project.ts +197 -0
  839. package/packages/shared-skills/skills/programming/scripts/python/new-project.ts +231 -0
  840. package/packages/shared-skills/skills/programming/scripts/python/new-script.ts +134 -0
  841. package/packages/shared-skills/skills/programming/scripts/rust/new-project.ts +215 -0
  842. package/packages/shared-skills/skills/programming/scripts/scaffolders.test.ts +96 -0
  843. package/packages/shared-skills/skills/programming/scripts/shared/run-tool.ts +19 -0
  844. package/packages/shared-skills/skills/programming/scripts/typescript/check-test-junk-rules.ts +140 -0
  845. package/packages/shared-skills/skills/programming/scripts/typescript/check-test-junk.test.ts +125 -0
  846. package/packages/shared-skills/skills/programming/scripts/typescript/check-test-junk.ts +148 -0
  847. package/packages/shared-skills/skills/programming/scripts/typescript/mutation-proof.test.ts +43 -0
  848. package/packages/shared-skills/skills/programming/scripts/typescript/mutation-proof.ts +179 -0
  849. package/packages/shared-skills/skills/remove-ai-slops/SKILL.md +32 -20
  850. package/packages/shared-skills/skills/ulw-research/scripts/source-commands.mjs +3 -1
  851. package/packages/shared-skills/skills/ulw-research/scripts/source-integrity.test.ts +39 -2
  852. package/packages/shared-skills/skills/visual-qa/SKILL.md +12 -1
  853. package/dist/agents/gpt-prompt-identity.d.ts +0 -3
  854. package/dist/agents/hephaestus/gpt-5-4.d.ts +0 -24
  855. package/dist/agents/hephaestus/gpt-5-5.d.ts +0 -2
  856. package/dist/agents/hephaestus/gpt-5-6.d.ts +0 -2
  857. package/dist/agents/kimi-tool-loop-guard.d.ts +0 -1
  858. package/dist/agents/sisyphus/claude-fable-5.d.ts +0 -19
  859. package/dist/agents/sisyphus/claude-opus-4-7.d.ts +0 -22
  860. package/dist/agents/sisyphus/claude-opus-4-8.d.ts +0 -19
  861. package/dist/agents/sisyphus/claude-opus-5.d.ts +0 -33
  862. package/dist/agents/sisyphus/gemini.d.ts +0 -20
  863. package/dist/agents/sisyphus/glm-5-2.d.ts +0 -4
  864. package/dist/agents/sisyphus/gpt-5-4.d.ts +0 -26
  865. package/dist/agents/sisyphus/gpt-5-5.d.ts +0 -6
  866. package/dist/agents/sisyphus/gpt-task-system-guide.d.ts +0 -1
  867. package/dist/agents/sisyphus/grok-4.d.ts +0 -21
  868. package/dist/agents/sisyphus/index.d.ts +0 -31
  869. package/dist/agents/sisyphus/kimi-k2-6.d.ts +0 -32
  870. package/dist/agents/sisyphus/kimi-k2-7.d.ts +0 -17
  871. package/dist/agents/sisyphus/kimi-k3-1.d.ts +0 -9
  872. package/dist/agents/sisyphus/kimi-k3.d.ts +0 -19
  873. package/dist/agents/sisyphus-dynamic-prompt-builder.d.ts +0 -2
  874. package/dist/agents/sisyphus-dynamic-prompt-execution.d.ts +0 -2
  875. package/dist/agents/sisyphus-dynamic-prompt-exploration.d.ts +0 -2
  876. package/dist/agents/sisyphus-dynamic-prompt-role.d.ts +0 -2
  877. package/dist/agents/sisyphus-dynamic-prompt-sections.d.ts +0 -18
  878. package/dist/agents/sisyphus-dynamic-prompt-style.d.ts +0 -2
  879. package/dist/agents/sisyphus-dynamic-prompt.d.ts +0 -3
  880. package/dist/agents/sisyphus-gemini-fallback-overrides.d.ts +0 -1
  881. package/dist/agents/sisyphus-junior/gemini.d.ts +0 -10
  882. package/dist/agents/sisyphus-junior/glm-5-2.d.ts +0 -1
  883. package/dist/agents/sisyphus-junior/gpt-5-4.d.ts +0 -11
  884. package/dist/agents/sisyphus-junior/gpt-5-5.d.ts +0 -5
  885. package/dist/agents/sisyphus-junior/gpt.d.ts +0 -9
  886. package/dist/agents/sisyphus-junior/kimi-k2-6.d.ts +0 -13
  887. package/dist/agents/sisyphus-junior/kimi-k2-7.d.ts +0 -11
  888. package/dist/agents/sisyphus-junior/kimi-k3-1.d.ts +0 -6
  889. package/dist/agents/sisyphus-junior/kimi-k3.d.ts +0 -12
  890. package/dist/features/claude-code-agent-loader/opencode-config-agents-reader.d.ts +0 -1
  891. package/dist/features/claude-code-command-loader/loader-cache.d.ts +0 -1
  892. package/dist/features/claude-code-command-loader/loader.d.ts +0 -1
  893. package/dist/features/opencode-skill-loader/config-source-discovery.d.ts +0 -1
  894. package/dist/features/opencode-skill-loader/merger/config-skill-entry-loader.d.ts +0 -1
  895. package/dist/features/opencode-skill-loader/opencode-config-skills-reader.d.ts +0 -1
  896. package/dist/features/team-mode/team-layout-tmux/resolve-caller-tmux-session.d.ts +0 -1
  897. package/dist/features/team-mode/team-registry/team-spec-input-normalizer.d.ts +0 -1
  898. package/dist/shared/git-worktree/collect-git-diff-stats.d.ts +0 -1
  899. package/dist/shared/git-worktree/parse-status-porcelain-line.d.ts +0 -1
  900. package/dist/shared/migration/agent-names.d.ts +0 -1
  901. package/dist/shared/migration/migrations-sidecar.d.ts +0 -1
  902. package/dist/shared/skill-path-resolver.d.ts +0 -1
  903. package/dist/shared/zip-entry-listing/powershell-zip-entry-listing.d.ts +0 -1
  904. package/dist/shared/zip-entry-listing/zipinfo-zip-entry-listing.d.ts +0 -1
  905. package/dist/skills/programming/scripts/go/new-project.py +0 -138
  906. package/dist/skills/programming/scripts/python/new-project.py +0 -172
  907. package/dist/skills/programming/scripts/python/new-script.py +0 -116
  908. package/dist/skills/programming/scripts/rust/new-project.py +0 -178
  909. package/packages/omo-codex/plugin/skills/programming/scripts/go/new-project.py +0 -138
  910. package/packages/omo-codex/plugin/skills/programming/scripts/python/new-project.py +0 -172
  911. package/packages/omo-codex/plugin/skills/programming/scripts/python/new-script.py +0 -116
  912. package/packages/omo-codex/plugin/skills/programming/scripts/rust/new-project.py +0 -178
  913. package/packages/shared-skills/skills/programming/scripts/go/new-project.py +0 -138
  914. package/packages/shared-skills/skills/programming/scripts/python/new-project.py +0 -172
  915. package/packages/shared-skills/skills/programming/scripts/python/new-script.py +0 -116
  916. package/packages/shared-skills/skills/programming/scripts/rust/new-project.py +0 -178
@@ -0,0 +1,112 @@
1
+ import { ancestors, childrenOf, fontSizePx, isHeading, px, styleOf } from "../../../core/page"
2
+ import type { ElementSnapshot, PageSnapshot } from "../../../types"
3
+
4
+ export const readingTags = ["p", "li", "td", "th", "dd", "blockquote", "figcaption"]
5
+ export const lineage = (s: PageSnapshot, e: ElementSnapshot): readonly ElementSnapshot[] => [e, ...ancestors(s, e)]
6
+ export const className = (e: ElementSnapshot): string => e.attributes["class"] ?? ""
7
+ export const mono = (e: ElementSnapshot): boolean => {
8
+ const first = (styleOf(e, "font-family").split(",")[0] ?? "").trim().replace(/^['"]|['"]$/g, "").toLowerCase()
9
+ return ["courier", "courier new", "consolas", "menlo", "monaco", "andale mono", "lucida console"].includes(first) ||
10
+ first.split(/[^a-z0-9]+/).some(w => ["mono", "monospace", "monospaced", "sfmono"].includes(w))
11
+ }
12
+ export const letters = (text: string): readonly string[] => [...text].filter(c => /\p{L}/u.test(c))
13
+ export const cjkChar = (c: string): boolean => /[\u1100-\u11ff\u3040-\u30ff\u3130-\u318f\u31f0-\u31ff\u3400-\u9fff\ua960-\ud7ff\uf900-\ufaff\uff66-\uff9f\u{20000}-\u{3ffff}]/u.test(c)
14
+ export const cjk = (text: string): boolean => {
15
+ const sample = [...text].slice(0, 256)
16
+ const count = sample.filter(cjkChar).length
17
+ return count > 0 && count * 2 >= sample.filter(c => /\p{L}/u.test(c)).length
18
+ }
19
+ export const caps = (text: string): boolean => {
20
+ const chars = letters(text)
21
+ return chars.some(c => c.toUpperCase() !== c.toLowerCase()) && chars.every(c => /\p{Lu}/u.test(c))
22
+ }
23
+
24
+ export function visibleText(s: PageSnapshot, e: ElementSnapshot): boolean {
25
+ const box = (e.rect.width > 0 && e.rect.height > 0) || e.lineRects.some(r => r.width > 0 && r.height > 0)
26
+ return box && lineage(s, e).every(n =>
27
+ n.attributes["hidden"] === undefined && styleOf(n, "display") !== "none" &&
28
+ styleOf(n, "visibility") !== "collapse" && styleOf(n, "visibility") !== "hidden" &&
29
+ styleOf(n, "content-visibility") !== "hidden" &&
30
+ (Number.parseFloat(styleOf(n, "opacity")) <= 0.01) === false &&
31
+ ((n.rect.width <= 0 || n.rect.height <= 0) &&
32
+ ["overflow-x", "overflow-y"].some(p => ["hidden", "clip"].includes(styleOf(n, p)))) === false &&
33
+ /sr-only|visually-?hidden|screen-?reader|a11y-hidden|hidden-visually/i.test(className(n)) === false &&
34
+ /^(script|style|title|noscript|template|head|meta|link|base|param|source|track|datalist|col|colgroup|area)$/.test(n.tag) === false &&
35
+ /inset\(\s*(50%|99|100%)/.test(styleOf(n, "clip-path")) === false)
36
+ }
37
+
38
+ export function control(s: PageSnapshot, e: ElementSnapshot): boolean {
39
+ return lineage(s, e).some(n =>
40
+ ["button", "summary", "label", "select", "textarea"].includes(n.tag) ||
41
+ (n.tag === "a" && n.attributes["href"] !== undefined) ||
42
+ /^(button|link|tab|menuitem|menuitemcheckbox|menuitemradio|option|checkbox|radio|switch|treeitem)$/.test(n.attributes["role"] ?? "") ||
43
+ (n.attributes["tabindex"] !== undefined && Number(n.attributes["tabindex"]) >= 0 && n.text.length <= 80))
44
+ }
45
+
46
+ export function headingText(s: PageSnapshot, e: ElementSnapshot): boolean {
47
+ for (const n of lineage(s, e)) {
48
+ if (isHeading(n) || n.attributes["role"] === "heading") return true
49
+ if (readingTags.includes(n.tag)) return false
50
+ }
51
+ return false
52
+ }
53
+
54
+ export function pitch(s: PageSnapshot, e: ElementSnapshot): number {
55
+ let height = px(styleOf(e, "line-height")) ?? 0
56
+ if (styleOf(e, "display") === "inline") {
57
+ for (const n of ancestors(s, e)) {
58
+ height = Math.max(height, px(styleOf(n, "line-height")) ?? 0)
59
+ if (["inline", "contents"].includes(styleOf(n, "display")) === false) break
60
+ }
61
+ }
62
+ return height
63
+ }
64
+
65
+ export const smallprint = (s: PageSnapshot, e: ElementSnapshot): boolean => lineage(s, e).some(n =>
66
+ ["small", "footer"].includes(n.tag) || /legal|copyright|disclaimer|small-?print|fine-?print|disclosure|footnote/i.test(className(n)))
67
+
68
+ export function finePrintExempt(s: PageSnapshot, e: ElementSnapshot): boolean {
69
+ if (fontSizePx(e) <= 0 || fontSizePx(e) >= 15 ||
70
+ lineage(s, e).some(n => n.tag === "label" || isHeading(n)) ||
71
+ childrenOf(s, e).some(n => ["input", "select", "textarea", "button"].includes(n.tag))) return false
72
+ const marked: ElementSnapshot[] = []
73
+ for (const n of lineage(s, e).slice(0, 4)) {
74
+ if (["html", "body", "main", "article", "form"].includes(n.tag)) break
75
+ const words = `${className(n)} ${n.attributes["id"] ?? ""}`.replace(/([a-z])([A-Z])/g, "$1-$2").toLowerCase()
76
+ if (/(?:^|[-_\s])(legal|fine-?print|small-?print|disclaimers?|footnotes?|disclosures)(?:$|[-_\s])/.test(words) &&
77
+ /(?:type|text|typography|font|fs)[-_]footnote/.test(words) === false) marked.push(n)
78
+ }
79
+ if (marked.length === 0 || marked.some(n => n.tag === "details" || n.tag === "summary" ||
80
+ n.attributes["aria-expanded"] !== undefined || childrenOf(s, n).some(c => c.tag === "summary" || c.attributes["aria-expanded"] !== undefined))) return false
81
+ const outer = marked[marked.length - 1]
82
+ if (outer && outer.text.length >= 2000 &&
83
+ outer.text.length >= (s.elements.find(n => n.tag === "body")?.text.length ?? 0) * 0.5 &&
84
+ lineage(s, outer).some(n => n.tag === "footer" || n.attributes["role"] === "contentinfo") === false) return false
85
+ return true
86
+ }
87
+
88
+ export const codeContext = (s: PageSnapshot, e: ElementSnapshot): boolean => lineage(s, e).some(n =>
89
+ ["pre", "code", "kbd", "samp", "var", "svg"].includes(n.tag) ||
90
+ n.attributes["aria-hidden"] === "true" || /terminal|console|code|mock|editor|syntax|diff/i.test(className(n)))
91
+
92
+ export const uiContext = (s: PageSnapshot, e: ElementSnapshot): boolean => lineage(s, e).some(n =>
93
+ ["button", "a", "label", "summary", "pre", "nav", "footer"].includes(n.tag) ||
94
+ n.attributes["aria-hidden"] === "true" ||
95
+ /^(button|link|tab|menuitem|option)$/.test(n.attributes["role"] ?? "") ||
96
+ /badge|caption|chip|code|console|diff|label|meta|mock|pill|preview|tag|terminal|writes/i.test(className(n)))
97
+
98
+ export function buttonBox(s: PageSnapshot, e: ElementSnapshot): boolean {
99
+ for (const n of lineage(s, e).slice(0, 3)) {
100
+ if (n !== e && n.text.length > 80) return false
101
+ if (className(n).toLowerCase().split(/\s+/).some(t => t === "btn" || t.endsWith("-btn") || t.endsWith("_btn"))) return true
102
+ }
103
+ return false
104
+ }
105
+
106
+ export const furnitureClass = (value: string): boolean => value.replace(/([a-z])([A-Z])/g, "$1-$2").toLowerCase()
107
+ .split(/[-_\s]+/).some(raw => {
108
+ const part = raw.replace(/[^\p{L}\p{N}]/gu, "")
109
+ return ["pillar", "pillars", "navy"].includes(part) === false &&
110
+ ["meta", "label", "badge", "chip", "pill", "tag", "kicker", "eyebrow", "breadcrumb", "timestamp", "category", "caption", "nav"]
111
+ .some(w => part.startsWith(w) || part.endsWith(w))
112
+ })
@@ -0,0 +1,43 @@
1
+ import { childrenOf, px, styleOf } from "../../../core/page"
2
+ import type { ElementSnapshot, PageSnapshot, Rect } from "../../../types"
3
+ import { visibleText } from "./text-context"
4
+
5
+ export function phrasingNodes(s: PageSnapshot, e: ElementSnapshot): readonly ElementSnapshot[] {
6
+ const nodes: ElementSnapshot[] = []
7
+ const walk = (n: ElementSnapshot): void => {
8
+ if (visibleText(s, n) === false) return
9
+ nodes.push(n)
10
+ for (const c of childrenOf(s, n)) {
11
+ if (["inline", "contents"].includes(styleOf(c, "display")) || ["br", "wbr"].includes(c.tag)) walk(c)
12
+ }
13
+ }
14
+ walk(e)
15
+ return nodes
16
+ }
17
+
18
+ export function mergedLines(nodes: readonly ElementSnapshot[]): readonly Rect[] {
19
+ const lines: Rect[] = []
20
+ for (const r of nodes.flatMap(n => n.lineRects).sort((a, b) => a.y - b.y || a.x - b.x)) {
21
+ const match = lines.find(l => Math.abs(l.y - r.y) <= Math.max(2, Math.min(l.height, r.height) * 0.5))
22
+ if (match) {
23
+ const i = lines.indexOf(match)
24
+ const x = Math.min(match.x, r.x)
25
+ const y = Math.min(match.y, r.y)
26
+ lines[i] = { x, y, width: Math.max(match.x + match.width, r.x + r.width) - x, height: Math.max(match.y + match.height, r.y + r.height) - y }
27
+ } else lines.push(r)
28
+ }
29
+ return lines
30
+ }
31
+
32
+ export function renderedCharacters(nodes: readonly ElementSnapshot[]): number {
33
+ return nodes.reduce((n, e) => n + [...e.ownText.normalize("NFC")].filter(c =>
34
+ /[\p{M}\u200b-\u200f\u202a-\u202e\u2060-\u206f]/u.test(c) === false).length, 0)
35
+ }
36
+
37
+ export function shownLines(s: PageSnapshot, e: ElementSnapshot, lineHeight: number): number {
38
+ const lines = mergedLines(phrasingNodes(s, e))
39
+ const top = lines[0]?.y
40
+ if (top === undefined || lineHeight <= 0) return 0
41
+ const bottom = Math.max(...lines.map(r => r.y + r.height))
42
+ return Math.max(1, Math.round((bottom - top - (px(styleOf(e, "font-size")) ?? 16)) / lineHeight) + 1)
43
+ }
@@ -0,0 +1,48 @@
1
+ export type TypeSample = { readonly role: string; readonly size: number; readonly weight: number }
2
+
3
+ function dominant(role: string, values: readonly number[]): number | null {
4
+ const counts = new Map<number, number>()
5
+ for (const n of values) counts.set(n, (counts.get(n) ?? 0) + 1)
6
+ const ranked = [...counts].sort((a, b) => b[1] - a[1] || a[0] - b[0])
7
+ const first = ranked[0]
8
+ const second = ranked[1]
9
+ if (first === undefined) return null
10
+ if (second && first[1] === second[1]) {
11
+ return role === "h1" ? Math.max(...ranked.filter(n => n[1] === first[1]).map(n => n[0])) : null
12
+ }
13
+ if (second && role !== "h1" && role !== "body" && second[1] >= first[1] * 0.75 && second[0] >= first[0] * 1.25) return null
14
+ return first[0]
15
+ }
16
+
17
+ const largestStep = (values: readonly number[]): number => {
18
+ const sorted = [...values].sort((a, b) => a - b)
19
+ return sorted.reduce((n, v, i) => Math.max(n, v / (sorted[i - 1] ?? v)), 1)
20
+ }
21
+
22
+ export function flatHierarchy(samples: readonly TypeSample[]): readonly [string, number][] {
23
+ const groups = new Map<string, number[]>()
24
+ for (const s of samples) {
25
+ const values = groups.get(s.role) ?? []
26
+ values.push(Math.round(s.size * 10) / 10)
27
+ groups.set(s.role, values)
28
+ }
29
+ const roles: [string, number][] = []
30
+ const dropped: number[] = []
31
+ let settled = 0
32
+ for (const [role, values] of groups) {
33
+ const size = dominant(role, values)
34
+ if (size === null) {
35
+ if (role !== "body") dropped.push(...values)
36
+ } else {
37
+ roles.push([role, size])
38
+ if (role !== "body") settled += values.length
39
+ }
40
+ }
41
+ if (roles.length < 3) return []
42
+ const h1 = roles.find(r => r[0] === "h1")?.[1]
43
+ const body = roles.find(r => r[0] === "body")?.[1]
44
+ if (h1 !== undefined && body !== undefined && h1 < body) return []
45
+ const sizes = roles.map(r => r[1])
46
+ if (largestStep(sizes) >= 1.25 || (dropped.length > settled && dropped.some(n => largestStep([...sizes, n]) >= 1.25))) return []
47
+ return roles
48
+ }
@@ -0,0 +1,54 @@
1
+ import { expect, test } from "bun:test"
2
+ import { buildSnapshot } from "../../testing/build-snapshot"
3
+ import { tightLeading } from "./tight-leading"
4
+
5
+ const text = "This card description is reading copy long enough to wrap over several lines in a narrow column."
6
+ const lines = (count: number, height = 20) => Array.from({ length: count }, (_, i) => ({ x: 0, y: i * height, width: 240, height: 18 }))
7
+
8
+ test("#given multiline body copy, bold titles and heading wrappers #then only crowded body runs report", () => {
9
+ const style = { "font-size": "16px", "line-height": "20px" }
10
+ const snapshot = buildSnapshot([
11
+ { id: "body", tag: "p", text, style, lineRects: lines(4) },
12
+ { id: "bold-body", tag: "p", text, style: { ...style, "font-weight": "700" }, lineRects: lines(4) },
13
+ { id: "medium-title", text, style: { ...style, "font-weight": "500" }, lineRects: lines(2) },
14
+ { text, style: { ...style, "font-weight": "600" }, lineRects: lines(2) },
15
+ { text, style: { "font-size": "32px", "line-height": "36px" }, lineRects: lines(3, 36) },
16
+ { tag: "h2", children: [{ text, style, lineRects: lines(4) }] },
17
+ { tag: "h3", children: [{ id: "nested-prose", tag: "p", text, style, lineRects: lines(4) }] },
18
+ { text, style, lineRects: lines(1) },
19
+ ])
20
+ expect(tightLeading.check({ snapshot, config: {} }).map(h => h.element?.selector)).toEqual(["#body", "#bold-body", "#medium-title", "#nested-prose"])
21
+ })
22
+
23
+ test("#given lead text and capital labels with long-run controls #then exemption limits are enforced", () => {
24
+ const snapshot = buildSnapshot([
25
+ { text, style: { "font-size": "22px", "line-height": "26.4px" }, lineRects: lines(3, 26.4) },
26
+ { id: "long-lead", text, style: { "font-size": "22px", "line-height": "26.4px" }, lineRects: lines(4, 26.4) },
27
+ { id: "solid-lead", text, style: { "font-size": "22px", "line-height": "22px" }, lineRects: lines(2, 22) },
28
+ { text, style: { "font-size": "12px", "line-height": "13.2px", "text-transform": "uppercase" }, lineRects: lines(3, 13.2) },
29
+ { id: "caps-paragraph", text, style: { "font-size": "12px", "line-height": "13.2px", "text-transform": "uppercase" }, lineRects: lines(4, 13.2) },
30
+ { id: "caps-overlap", text, style: { "font-size": "12px", "line-height": "10.8px", "text-transform": "uppercase" }, lineRects: lines(3, 10.8) },
31
+ { text, style: { "font-size": "18px", "line-height": "23.4px" }, lineRects: lines(3, 23.4) },
32
+ ])
33
+ expect(tightLeading.check({ snapshot, config: {} }).map(h => h.element?.selector)).toEqual(["#long-lead", "#solid-lead", "#caps-paragraph", "#caps-overlap"])
34
+ })
35
+
36
+ test("#given inline struts and preformatted text #then actual block pitch and code exemptions apply", () => {
37
+ const snapshot = buildSnapshot([
38
+ { style: { "line-height": "22px" }, children: [{ tag: "span", text, style: { "font-size": "12px", "line-height": "11.4px" }, lineRects: lines(3, 22) }] },
39
+ { id: "proportional-pre", tag: "pre", text, style: { "font-family": "Inter", "font-size": "12px", "line-height": "15px", "white-space": "pre-wrap" }, lineRects: lines(4, 15) },
40
+ { tag: "pre", text, style: { "font-family": "monospace", "font-size": "12px", "line-height": "15px", "white-space": "pre-wrap" }, lineRects: lines(4, 15) },
41
+ ])
42
+ expect(tightLeading.check({ snapshot, config: {} }).map(h => h.element?.selector)).toEqual(["#proportional-pre"])
43
+ })
44
+
45
+ test("#given wrapping flex rows of text runs #then only a row whose run wraps inside its own item reports", () => {
46
+ const row = { display: "flex", "flex-wrap": "wrap", "font-size": "12px", "line-height": "14px" }
47
+ const long = "The first item of this flex row is a whole sentence of reading copy, long enough to wrap inside its own box"
48
+ const snapshot = buildSnapshot([
49
+ { id: "long-run", tag: "p", text: `${long} Short note`, textRuns: [long, "Short note"], style: row, rect: { width: 260 }, scroll: { clientWidth: 260 }, lineRects: lines(4, 14) },
50
+ { id: "short-runs", tag: "p", text: "100 free lead searches 14-day trial No card needed Cancel anytime", textRuns: ["100 free lead searches", "14-day trial", "No card needed", "Cancel anytime"], style: row, rect: { width: 260 }, scroll: { clientWidth: 260 }, lineRects: lines(3, 14) },
51
+ { id: "nowrap-runs", tag: "p", text: "100 free lead searches 14-day trial No card needed Cancel anytime", textRuns: ["100 free lead searches", "14-day trial", "No card needed", "Cancel anytime"], style: { ...row, "flex-wrap": "nowrap" }, rect: { width: 260 }, scroll: { clientWidth: 260 }, lineRects: lines(3, 14) },
52
+ ])
53
+ expect(tightLeading.check({ snapshot, config: {} }).map(h => h.element?.selector)).toEqual(["#long-run", "#nowrap-runs"])
54
+ })
@@ -0,0 +1,47 @@
1
+ import { fontSizePx, px, shortSnippet, styleOf } from "../../core/page"
2
+ import type { PageRule } from "../../rule"
3
+ import { caps, headingText, lineage, mono, pitch, visibleText } from "./support/text-context"
4
+ import { itemsEachFitOneLine } from "./support/flex-runs"
5
+ import { mergedLines, phrasingNodes, shownLines } from "./support/text-lines"
6
+
7
+ export const tightLeading: PageRule = {
8
+ meta: {
9
+ id: "tight-leading", name: "Tight line height", category: "quality", severity: "warning", engine: "page",
10
+ description: "Multiline reading copy with line height below 1.3 crowds adjacent lines.",
11
+ fixHint: "Use line height around 1.5 to 1.7 for body copy.",
12
+ },
13
+ check: ({ snapshot }) => snapshot.elements.flatMap(element => {
14
+ const size = fontSizePx(element)
15
+ const height = pitch(snapshot, element)
16
+ const ratio = Math.round(height / size * 100) / 100
17
+ if (visibleText(snapshot, element) === false || element.ownText.length <= 10 || element.text.length <= 50 ||
18
+ size <= 0 || size >= 24 || height <= 0 || ratio >= 1.3 || headingText(snapshot, element)) return []
19
+ const lines = mergedLines(phrasingNodes(snapshot, element))
20
+ const top = lines[0]?.y
21
+ if (top === undefined) return []
22
+ const bottom = Math.max(...lines.map(l => l.y + l.height))
23
+ if (bottom - top < height * 1.5) return []
24
+ let count = shownLines(snapshot, element, height)
25
+ let clamped = false
26
+ for (const n of lineage(snapshot, element).slice(0, 4)) {
27
+ const display = styleOf(n, "display")
28
+ const clamp = Number.parseFloat(styleOf(n, "-webkit-line-clamp"))
29
+ if (["-webkit-box", "-webkit-inline-box"].includes(display) ||
30
+ (["flow-root", "inline-block"].includes(display) && clamp > 0)) clamped = true
31
+ if (["hidden", "clip"].includes(styleOf(n, "overflow-y"))) {
32
+ count = Math.min(count, Math.max(1, Math.round((n.rect.y + n.rect.height - top) / height)))
33
+ break
34
+ }
35
+ }
36
+ const weight = Number.parseFloat(styleOf(element, "font-weight"))
37
+ if (weight >= 600 && (clamped || count <= 2)) return []
38
+ if (size >= 20 && ratio >= 1.15 && count <= 3) return []
39
+ if (ratio >= 1 && ((styleOf(element, "text-transform") === "uppercase" && count <= 3) ||
40
+ (element.text.length < 80 && caps(element.text)))) return []
41
+ const ws = styleOf(element, "white-space")
42
+ if (mono(element) && ((ws.startsWith("pre") && ws !== "pre-line") || ws === "break-spaces") &&
43
+ (lineage(snapshot, element).some(n => ["pre", "code", "samp"].includes(n.tag)) || /[\u2500-\u257f]/.test(element.ownText))) return []
44
+ if (itemsEachFitOneLine(element, size)) return []
45
+ return [{ element, message: `Line height ${(height / size).toFixed(2)}x below 1.3`, snippet: shortSnippet(element) }]
46
+ }),
47
+ }
@@ -0,0 +1,60 @@
1
+ import { expect, test } from "bun:test"
2
+ import { buildSnapshot } from "../../testing/build-snapshot"
3
+ import { tinyText } from "./tiny-text"
4
+
5
+ test("#given tiny prose beside labels, code and fine print #then only running prose reports", () => {
6
+ const text = "This is a longer sentence of ordinary reading copy."
7
+ const style = { "font-size": "11px" }
8
+ const snapshot = buildSnapshot([
9
+ { id: "body", tag: "p", text, style },
10
+ { tag: "p", text, style: { "font-size": "12px" } },
11
+ { tag: "button", text, style },
12
+ { tag: "sup", text, style },
13
+ { tag: "p", text, style: { ...style, "text-transform": "uppercase" } },
14
+ { text: "ANIMATION AND CINEMATIC THREE DIMENSIONS", style },
15
+ { tag: "p", text, style: { ...style, "font-family": "IBM Plex Mono", "white-space": "pre-wrap" } },
16
+ { text, style, attributes: { class: "legal" } },
17
+ ])
18
+ expect(tinyText.check({ snapshot, config: {} }).map(h => h.element?.selector)).toEqual(["#body"])
19
+ })
20
+
21
+ test("#given SVG text scaled by viewBox and uniform transforms #then drawn sizes control findings", () => {
22
+ const text = "Cited report with sources for every claim"
23
+ const snapshot = buildSnapshot([
24
+ { tag: "svg", attributes: { viewBox: "0 0 400 200" }, rect: { width: 200, height: 100 }, children: [
25
+ { id: "shrunk", tag: "text", text, style: { "font-size": "14px" } },
26
+ ] },
27
+ { tag: "svg", attributes: { viewBox: "0 0 200 100" }, rect: { width: 400, height: 200 }, children: [
28
+ { tag: "text", text, style: { "font-size": "10px" } },
29
+ ] },
30
+ { tag: "svg", attributes: { viewBox: "0 0 400 100" }, rect: { width: 400, height: 100 }, children: [
31
+ { id: "group", tag: "text", text, style: { "font-size": "14px", transform: "matrix(0.5, 0, 0, 0.5, 0, 0)" } },
32
+ { tag: "text", text, style: { "font-size": "10px", transform: "matrix(1.5, 0, 0, 1.5, 0, 0)" } },
33
+ ] },
34
+ ])
35
+ expect(tinyText.check({ snapshot, config: {} }).map(h => h.element?.selector)).toEqual(["#shrunk", "#group"])
36
+ })
37
+
38
+ test("#given fine-print markers at different depths #then only actual small legal blocks are exempt", () => {
39
+ const text = "Requires a qualifying plan and a new account. Restrictions apply to every purchase."
40
+ const style = { "font-size": "11px" }
41
+ const snapshot = buildSnapshot([
42
+ { text, style, attributes: { id: "disclaimer-2" } },
43
+ { attributes: { class: "disclaimers" }, children: [{ tag: "li", children: [{ text, style }] }] },
44
+ { attributes: { class: "legal-page" }, children: [{ children: [{ children: [{ children: [{ id: "deep", text, style }] }] }] }] },
45
+ { id: "type", text, style, attributes: { class: "text-footnote" } },
46
+ { tag: "details", attributes: { open: "", class: "footnote-accordion" }, children: [{ id: "accordion", text, style }] },
47
+ { id: "terms", text, style, attributes: { class: "offer-terms" } },
48
+ ])
49
+ expect(tinyText.check({ snapshot, config: {} }).map(h => h.element?.selector)).toEqual(["#deep", "#type", "#accordion", "#terms"])
50
+ })
51
+
52
+ test("#given overflowing text on zero-size anchors #then visible glyphs report while clipped glyphs do not", () => {
53
+ const text = "Harbour office, open nine to five"
54
+ const style = { "font-size": "10px" }
55
+ const snapshot = buildSnapshot([
56
+ { id: "pin", tag: "span", text, style, rect: { width: 0, height: 0 }, lineRects: [{ x: 0, y: 0, width: 150, height: 12 }] },
57
+ { text, style: { ...style, "overflow-x": "hidden", "overflow-y": "hidden" }, rect: { width: 0, height: 0 }, lineRects: [{ x: 0, y: 0, width: 150, height: 12 }] },
58
+ ])
59
+ expect(tinyText.check({ snapshot, config: {} }).map(h => h.element?.selector)).toEqual(["#pin"])
60
+ })
@@ -0,0 +1,23 @@
1
+ import { shortSnippet, styleOf } from "../../core/page"
2
+ import type { PageRule } from "../../rule"
3
+ import { buttonBox, caps, finePrintExempt, mono, smallprint, uiContext, visibleText } from "./support/text-context"
4
+ import { drawnFontSize } from "./support/svg-size"
5
+ import { textPainted } from "./support/painted-text"
6
+
7
+ export const tinyText: PageRule = {
8
+ meta: {
9
+ id: "tiny-text", name: "Tiny body text", category: "quality", severity: "warning", engine: "page",
10
+ description: "Running copy smaller than 12px is difficult to read.",
11
+ fixHint: "Increase body copy to at least 14px, preferably 16px.",
12
+ },
13
+ check: ({ snapshot }) => snapshot.elements.flatMap(element => {
14
+ if (visibleText(snapshot, element) === false || !textPainted(snapshot, element) || element.ownText.length <= 10 || element.text.length <= 20 ||
15
+ drawnFontSize(snapshot, element) >= 12 ||
16
+ ["sub", "sup", "code", "kbd", "samp", "var", "caption", "figcaption"].includes(element.tag) ||
17
+ uiContext(snapshot, element) || (buttonBox(snapshot, element) && smallprint(snapshot, element) === false) || finePrintExempt(snapshot, element) ||
18
+ styleOf(element, "text-transform") === "uppercase" ||
19
+ (element.text.length < 80 && caps(element.text)) ||
20
+ (mono(element) && styleOf(element, "white-space").startsWith("pre"))) return []
21
+ return [{ element, message: `${drawnFontSize(snapshot, element).toFixed(2)}px body text`, snippet: shortSnippet(element) }]
22
+ }),
23
+ }
@@ -0,0 +1,98 @@
1
+ import { expect, test } from "bun:test"
2
+ import { buildSnapshot } from "../../testing/build-snapshot"
3
+ import { undersizedUiText } from "./undersized-ui-text"
4
+ test("#given captured opacity motion and held endpoints #then only permanent replacing fades leave size scoring", () => {
5
+ const animation = {
6
+ "font-size": "9px", "animation-name": "out", "animation-iteration-count": "1",
7
+ "animation-duration": "10s", "animation-delay": "40s", "animation-fill-mode": "forwards",
8
+ "animation-direction": "normal", "animation-play-state": "running", "animation-composition": "replace",
9
+ }
10
+ const cases = [
11
+ { id: "out", style: {} },
12
+ { id: "returns", style: { "animation-fill-mode": "none" } },
13
+ { id: "paused", style: { "animation-play-state": "paused" } },
14
+ { id: "endless", style: { "animation-iteration-count": "infinite" } },
15
+ { id: "fraction", style: { "animation-iteration-count": "1.5" } },
16
+ { id: "long", style: { "animation-delay": "51s" } },
17
+ { id: "reverse", style: { "animation-direction": "reverse" } },
18
+ { id: "alternate", style: { "animation-direction": "alternate", "animation-iteration-count": "2" } },
19
+ { id: "reverse-alternate", style: { "animation-direction": "alternate-reverse", "animation-iteration-count": "2" } },
20
+ { id: "add", style: { "animation-composition": "add" } },
21
+ { id: "scroll", style: { "animation-timeline": "scroll()" } },
22
+ { id: "unknown", style: { "animation-name": "out, unavailable" } },
23
+ { id: "competing", style: { "animation-name": "out, in" } },
24
+ { id: "no-endpoint", style: { "animation-name": "middle" } },
25
+ { id: "near-end", style: { "animation-name": "near" } },
26
+ ]
27
+ const nodes = cases.map(({ id, style }) => ({
28
+ id, tag: "a", text: "Calendar", attributes: { href: "#" }, style: { ...animation, ...style }, motion: ["opacity"],
29
+ }))
30
+ const snapshot = buildSnapshot([
31
+ ...nodes,
32
+ { id: "no-motion", tag: "a", text: "Calendar", attributes: { href: "#" }, style: animation },
33
+ { id: "missing-composition", tag: "a", text: "Calendar", attributes: { href: "#" }, style: {
34
+ ...animation, "animation-composition": "",
35
+ }, motion: ["opacity"] },
36
+ { style: animation, motion: ["opacity"], children: [
37
+ { id: "child", tag: "a", text: "Calendar", attributes: { href: "#" }, style: { "font-size": "9px" } },
38
+ ] },
39
+ ], { cssText: [
40
+ "@keyframes out { from {opacity:1} 35%, to {opacity:0} } @keyframes in {from {opacity:0}to {opacity:1}}" +
41
+ "@keyframes middle {50% {opacity:0}} @keyframes near {from {opacity:1}to {opacity:1%}}",
42
+ ] })
43
+ expect(undersizedUiText.check({ snapshot, config: {} }).map(hit => hit.element?.selector)).toEqual([
44
+ "#returns", "#paused", "#endless", "#fraction", "#long", "#reverse", "#alternate",
45
+ "#add", "#scroll", "#unknown", "#competing", "#no-endpoint", "#no-motion", "#missing-composition",
46
+ ])
47
+ })
48
+
49
+ test("#given functional text, legal floors and tolerant fluid sizes #then only undersized labels report", () => {
50
+ const snapshot = buildSnapshot([
51
+ { id: "button", tag: "button", text: "Learn more", style: { "font-size": "10px" } },
52
+ { id: "floor", tag: "button", text: "Learn more", style: { "font-size": "10.9px" } },
53
+ { tag: "button", text: "Learn more", style: { "font-size": "10.9688px" } },
54
+ { tag: "button", text: "Learn more", style: { "font-size": "11px" } },
55
+ { tag: "footer", children: [
56
+ { text: "Copyright", style: { "font-size": "10px" } },
57
+ { id: "legal", text: "Copyright", style: { "font-size": "9.9px" } },
58
+ { id: "footer-link", tag: "a", text: "Privacy", attributes: { href: "#" }, style: { "font-size": "10px" } },
59
+ ] },
60
+ ])
61
+ expect(undersizedUiText.check({ snapshot, config: {} }).map(h => h.element?.selector)).toEqual(["#button", "#floor", "#legal", "#footer-link"])
62
+ })
63
+
64
+ test("#given footnote links, code and nonfunctional prose #then ordinary short labels alone report", () => {
65
+ const style = { "font-size": "8px" }
66
+ const snapshot = buildSnapshot([
67
+ { id: "label", text: "Short label", style },
68
+ { tag: "sup", children: [{ tag: "a", text: "[7]", style, attributes: { href: "#" } }] },
69
+ { tag: "code", text: "const x = 1", style },
70
+ { text: "A long paragraph of body copy belongs to the tiny-text check.", style },
71
+ { text: "const result = { count: 3 };", style: { ...style, "font-family": "IBM Plex Mono", "white-space": "pre-wrap" } },
72
+ { text: "Hidden label", style, attributes: { class: "sr-only" } },
73
+ ])
74
+ expect(undersizedUiText.check({ snapshot, config: {} }).map(h => h.element?.selector)).toEqual(["#label"])
75
+ })
76
+
77
+ test("#given furniture class parts and button groups #then only real furniture and button labels report", () => {
78
+ const style = { "font-size": "9.5px" }
79
+ const text = "A content-bearing label longer than twenty characters"
80
+ const snapshot = buildSnapshot([
81
+ ...["taglist", "hero-tagline", "footer-subnav"].map((name, i) => ({ attributes: { class: name }, children: [{ id: `furniture-${i}`, text, style }] })),
82
+ ...["px-stage-compact", "instagram-feed", "pillars", "navy"].map(name => ({ attributes: { class: name }, children: [{ text, style }] })),
83
+ { id: "button", text, style, attributes: { class: "demo__btn" } },
84
+ { attributes: { class: "hero-btns btn-group" }, children: [
85
+ { text, style }, { text: "*Offer valid for new customers only. Terms and conditions apply to every plan.", style, attributes: { class: "offer-terms" } },
86
+ ] },
87
+ ])
88
+ expect(undersizedUiText.check({ snapshot, config: {} }).map(h => h.element?.selector)).toEqual(["#furniture-0", "#furniture-1", "#furniture-2", "#button"])
89
+ })
90
+
91
+ test("#given JSON runs and monospace pricing #then punctuation identifies code rather than prices", () => {
92
+ const style = { "font-size": "8px", "font-family": "IBM Plex Mono", "white-space": "pre-wrap" }
93
+ const snapshot = buildSnapshot([
94
+ { text: '"data": {', style }, { text: '"id": 7,', style }, { text: '"title": "Introducing Directus",', style }, { text: "},", style },
95
+ { id: "price", text: "$50/seat", style }, { id: "count", text: "200+", style },
96
+ ])
97
+ expect(undersizedUiText.check({ snapshot, config: {} }).map(h => h.element?.selector)).toEqual(["#price", "#count"])
98
+ })
@@ -0,0 +1,28 @@
1
+ import { fontSizePx, shortSnippet, styleOf } from "../../core/page"
2
+ import type { PageRule } from "../../rule"
3
+ import { buttonBox, className, codeContext, control, furnitureClass, lineage, mono, smallprint, visibleText } from "./support/text-context"
4
+ import { textPainted } from "./support/painted-text"
5
+
6
+ export const undersizedUiText: PageRule = {
7
+ meta: {
8
+ id: "undersized-ui-text", name: "Undersized functional text", category: "quality", severity: "warning", engine: "page",
9
+ description: "Functional labels below 11px are difficult to read and use.",
10
+ fixHint: "Use at least 11px for functional text and at least 10px for noninteractive small print.",
11
+ },
12
+ check: ({ snapshot }) => snapshot.elements.flatMap(element => {
13
+ const size = fontSizePx(element)
14
+ const interactive = control(snapshot, element)
15
+ const floor = interactive === false && smallprint(snapshot, element) ? 10 : 11
16
+ const chain = lineage(snapshot, element)
17
+ const furniture = chain.some(n => ["nav", "td", "th", "caption", "figcaption", "dt", "dd", "footer"].includes(n.tag) ||
18
+ ["navigation", "gridcell", "cell"].includes(n.attributes["role"] ?? "") ||
19
+ (n.tag !== "html" && furnitureClass(className(n))))
20
+ const codeRun = mono(element) && styleOf(element, "white-space").startsWith("pre") && /[{}[\]<>=;"`\\_]/.test(element.ownText)
21
+ if (visibleText(snapshot, element) === false || !textPainted(snapshot, element) || size <= 0 || Math.round((floor - size) * 1000) < 100 ||
22
+ element.ownText.trim().length < 2 || ["sub", "sup", "option"].includes(element.tag) ||
23
+ chain.some(n => ["sub", "sup"].includes(n.tag)) || codeContext(snapshot, element) || codeRun ||
24
+ (interactive === false && furniture === false &&
25
+ (buttonBox(snapshot, element) === false || smallprint(snapshot, element)) && element.ownText.length > 20)) return []
26
+ return [{ element, message: `${size}px functional text below ${floor}px floor`, snippet: shortSnippet(element) }]
27
+ }),
28
+ }
@@ -0,0 +1,26 @@
1
+ import { expect, test } from "bun:test"
2
+ import { buildSnapshot } from "../../testing/build-snapshot"
3
+ import { wideTracking } from "./wide-tracking"
4
+
5
+ test("#given tracked prose, capitals, CJK and control labels #then reading text alone reports", () => {
6
+ const style = { "font-size": "16px", "letter-spacing": "2px" }
7
+ const snapshot = buildSnapshot([
8
+ { id: "prose", text: "Letter spacing this wide breaks natural word shapes.", style },
9
+ { id: "mixed", tag: "span", text: "Fall 2026 technology preview", style },
10
+ { id: "caps-sentence", text: "SUPPORT HOURS RUN MONDAY TO FRIDAY, FROM NINE IN THE MORNING UNTIL SIX IN THE EVENING, EXCEPT ON PUBLIC HOLIDAYS.", style },
11
+ { text: "NOW AVAILABLE ACROSS THE UNITED STATES, CANADA AND NEW ZEALAND", style },
12
+ { text: "Short capitals label made from mixed source text", style: { ...style, "text-transform": "uppercase" } },
13
+ { text: "台風が近づいているときに気をつけることは何ですか?", style },
14
+ { tag: "button", text: "A compact action label", style },
15
+ { text: "Reading copy at the exact tracking floor.", style: { ...style, "letter-spacing": "0.8px" } },
16
+ ])
17
+ expect(wideTracking.check({ snapshot, config: {} }).map(h => h.element?.selector)).toEqual(["#prose", "#mixed", "#caps-sentence"])
18
+ })
19
+
20
+ test("#given typed capitals forced lowercase beside normal capitals #then the lowercase run reports", () => {
21
+ const snapshot = buildSnapshot([
22
+ { id: "lower", text: "LIMITED EDITION RELEASE 2026", style: { "letter-spacing": "2px", "text-transform": "lowercase" } },
23
+ { text: "LIMITED EDITION RELEASE 2026", style: { "letter-spacing": "2px" } },
24
+ ])
25
+ expect(wideTracking.check({ snapshot, config: {} }).map(h => h.element?.selector)).toEqual(["#lower"])
26
+ })
@@ -0,0 +1,26 @@
1
+ import { fontSizePx, px, shortSnippet, styleOf } from "../../core/page"
2
+ import type { PageRule } from "../../rule"
3
+ import { caps, cjk, letters, lineage, visibleText } from "./support/text-context"
4
+ import { shownLines } from "./support/text-lines"
5
+
6
+ export const wideTracking: PageRule = {
7
+ meta: {
8
+ id: "wide-tracking", name: "Wide letter spacing on body text", category: "quality", severity: "warning", engine: "page",
9
+ description: "Widely tracked reading text splits words into individual characters.",
10
+ fixHint: "Keep body tracking at or below 0.05em; reserve wider spacing for capital labels.",
11
+ },
12
+ check: ({ snapshot }) => snapshot.elements.flatMap(element => {
13
+ const size = fontSizePx(element)
14
+ if (visibleText(snapshot, element) === false || element.ownText.length <= 10 || element.text.length <= 20 ||
15
+ size <= 0 || (px(styleOf(element, "letter-spacing")) ?? 0) / size <= 0.05) return []
16
+ const transform = styleOf(element, "text-transform")
17
+ const count = shownLines(snapshot, element, px(styleOf(element, "line-height")) ?? size * 1.2)
18
+ const capsLabel = transform === "uppercase" || (transform !== "lowercase" && caps(element.text) &&
19
+ (element.text.length < 80 || (letters(element.text).length <= 40 && count <= 1)))
20
+ const trackedControl = lineage(snapshot, element).some(n => n.tag === "button" ||
21
+ (n.tag === "a" && n.attributes["href"] !== undefined) ||
22
+ ["button", "link", "tab"].includes(n.attributes["role"] ?? ""))
23
+ if (capsLabel || (trackedControl && letters(element.text).length <= 40 && count <= 1) || cjk(element.ownText)) return []
24
+ return [{ element, message: "Letter spacing exceeds 0.05em on reading text", snippet: shortSnippet(element) }]
25
+ }),
26
+ }