@tmorrow/cre8-wc 2.0.7 → 2.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (333) hide show
  1. package/a2ui/catalog +5 -5
  2. package/a2ui/catalog-kg.json +156 -20
  3. package/a2ui/catalog.compact.json +2466 -0
  4. package/a2ui/catalog.json +1636 -139
  5. package/a2ui/catalog.svg +2445 -2445
  6. package/a2ui/check-layer-parity.mjs +277 -0
  7. package/a2ui/examples/compound-families.json +298 -0
  8. package/a2ui/examples/llm-observability.json +678 -650
  9. package/a2ui/generate-catalog.mjs +256 -5
  10. package/a2ui/inert-props.json +32 -0
  11. package/a2ui/registry.js +28 -0
  12. package/a2ui/registry.ts +31 -0
  13. package/a2ui/render-audit.mjs +294 -0
  14. package/a2ui/renderer.d.ts +2 -1
  15. package/a2ui/renderer.js +1 -1
  16. package/a2ui/renderer.ts +1 -1
  17. package/a2ui/smoke-test.mjs +39 -5
  18. package/a2ui/stream/diff-test.mjs +299 -0
  19. package/a2ui/stream/diff.d.ts +28 -0
  20. package/a2ui/stream/diff.js +130 -0
  21. package/a2ui/stream/diff.ts +145 -0
  22. package/a2ui/stream/index.d.ts +11 -0
  23. package/a2ui/stream/index.js +11 -0
  24. package/a2ui/stream/index.ts +43 -0
  25. package/a2ui/stream/model.d.ts +66 -0
  26. package/a2ui/stream/model.js +429 -0
  27. package/a2ui/stream/model.ts +472 -0
  28. package/a2ui/stream/pointer.d.ts +34 -0
  29. package/a2ui/stream/pointer.js +146 -0
  30. package/a2ui/stream/pointer.ts +147 -0
  31. package/a2ui/stream/renderer.d.ts +51 -0
  32. package/a2ui/stream/renderer.js +282 -0
  33. package/a2ui/stream/renderer.ts +291 -0
  34. package/a2ui/stream/stream-test.mjs +592 -0
  35. package/a2ui/stream/types.d.ts +173 -0
  36. package/a2ui/stream/types.js +17 -0
  37. package/a2ui/stream/types.ts +127 -0
  38. package/a2ui/types.d.ts +5 -0
  39. package/a2ui/types.ts +5 -0
  40. package/cdn/cre8-wc.esm.js +3527 -3226
  41. package/cdn/cre8-wc.esm.js.map +1 -1
  42. package/cdn/cre8-wc.min.js +289 -289
  43. package/cdn/cre8-wc.min.js.map +1 -1
  44. package/dist/assets/{Changelog-Documentation-BguNswiM.js → Changelog-Documentation-CeOetLxK.js} +1 -1
  45. package/dist/assets/{Code-Guidelines-BM3dZyzL.js → Code-Guidelines-BjdezAjj.js} +1 -1
  46. package/dist/assets/{Color-6AOWCN3U-C4AEGNk3.js → Color-6AOWCN3U-DPFGZitI.js} +1 -1
  47. package/dist/assets/{Contributing-Guidelines-DZURVehh.js → Contributing-Guidelines-B1M2V1hW.js} +1 -1
  48. package/dist/assets/{DocsRenderer-JROSPFPF-DeZmCI9u.js → DocsRenderer-JROSPFPF-BBy8KWNl.js} +1 -1
  49. package/dist/assets/{Tokens-Documentation-ZecGbtQg.js → Tokens-Documentation-CdTxFDLe.js} +1 -1
  50. package/dist/assets/{WithTooltip-7X4HQR7L-2Hfrkir-.js → WithTooltip-7X4HQR7L-DZzTNMQ7.js} +1 -1
  51. package/dist/assets/{accordion-item.stories-D-MjrX5G.js → accordion-item.stories-Bl26JlHp.js} +1 -9
  52. package/dist/assets/{accordion.stories-icgNa1dl.js → accordion.stories-DjoLApQw.js} +3 -11
  53. package/dist/assets/{alert.stories-BzDaXtj-.js → alert.stories-pO1y3YCQ.js} +15 -31
  54. package/dist/assets/{badge-C5wOWgyg.js → badge-BTxW3bN2.js} +3 -11
  55. package/dist/assets/{badge.stories-5GfB4jVI.js → badge.stories-vqh63RJ2.js} +1 -1
  56. package/dist/assets/{band.stories-DhXaP_kL.js → band.stories-CjKRppSb.js} +1 -9
  57. package/dist/assets/{blocks-DhUVut8Z.js → blocks-1be_-L6v.js} +5 -5
  58. package/dist/assets/{breadcrumbs.stories-CrPUBVk1.js → breadcrumbs.stories-Doyfy3V9.js} +2 -18
  59. package/dist/assets/{button-CJL8yzAT.js → button-CgaWukz0.js} +1 -9
  60. package/dist/assets/{button-group-BgwgtSFC.js → button-group-G7qN4MwM.js} +1 -9
  61. package/dist/assets/{button-group.stories-W-07gO63.js → button-group.stories-cL3Kay6M.js} +1 -1
  62. package/dist/assets/{button.stories-BPzJ-sCv.js → button.stories-C9HSpxWb.js} +6 -6
  63. package/dist/assets/{card.stories-mlFGY2Xn.js → card.stories-BbU8YymD.js} +3 -11
  64. package/dist/assets/{chart.stories-C8yuHHeK.js → chart.stories-BL4FxIA_.js} +1 -1
  65. package/dist/assets/{checkbox-field-item-iHcdmTNw.js → checkbox-field-item-DIMHcWM0.js} +1 -9
  66. package/dist/assets/{checkbox-field-item.stories-D1aVLDXn.js → checkbox-field-item.stories-XbB4x_lO.js} +1 -1
  67. package/dist/assets/{checkbox-field.stories-BoVB2jCx.js → checkbox-field.stories-YnqFUI4K.js} +2 -10
  68. package/dist/assets/{cre8-element-DfmMtHJO.js → cre8-element-B35i4Lyg.js} +1 -1
  69. package/dist/assets/{cre8-form-element-bQpK8UYN.js → cre8-form-element-Cfc5VeYV.js} +1 -1
  70. package/dist/assets/{danger-button.stories-Cb4ljnhQ.js → danger-button.stories-xh25hmfd.js} +1 -9
  71. package/dist/assets/{date-picker.stories-Cje3qk8D.js → date-picker.stories-DD_ctzEF.js} +1 -49
  72. package/dist/assets/{divider-B_PXBGWD.js → divider-xZ2KARHf.js} +2 -10
  73. package/dist/assets/{divider.stories-CtfeBqVV.js → divider.stories-Bk9oF-OV.js} +1 -1
  74. package/dist/assets/{dropdown-Cgwne34I.js → dropdown-BEP5x3CW.js} +6 -22
  75. package/dist/assets/{dropdown-item.stories-pXkDLRuv.js → dropdown-item.stories-Iaw_UrEP.js} +1 -1
  76. package/dist/assets/{dropdown.stories-DZnmHieY.js → dropdown.stories-B0OlKD7h.js} +1 -1
  77. package/dist/assets/{example-drug-card.stories-DTzLXTFx.js → example-drug-card.stories-Bp5JIeE_.js} +1 -1
  78. package/dist/assets/{f-po-C2WpbOFJ.js → f-po-BdPzDRD-.js} +1 -1
  79. package/dist/assets/{feature.stories-DffXdJch.js → feature.stories-DYE1Js70.js} +1 -9
  80. package/dist/assets/{field-DzYRqQb2.js → field-BpUYyRW1.js} +1 -9
  81. package/dist/assets/{field-note-DKXZiXLU.js → field-note-fccBckVl.js} +3 -11
  82. package/dist/assets/{field-note.stories-DS_0bQul.js → field-note.stories-BH9AZMbF.js} +1 -1
  83. package/dist/assets/{field.stories-BvXn0oG6.js → field.stories-BQPtmziK.js} +1 -1
  84. package/dist/assets/{footer.stories-C3ZibisU.js → footer.stories-DCWEciqD.js} +1 -9
  85. package/dist/assets/{form-example.stories-C-TuOeF2.js → form-example.stories-9IDC0AgX.js} +1 -1
  86. package/dist/assets/{formatter-L2YTDE3Q-CJVnxOUW.js → formatter-L2YTDE3Q-B9u1AOWn.js} +1 -1
  87. package/dist/assets/{global-nav-item-xQL7wVjY.js → global-nav-item-T4htN-yO.js} +6 -14
  88. package/dist/assets/{global-nav-item.stories-Dp9TE3aR.js → global-nav-item.stories-2dWRfCXv.js} +1 -1
  89. package/dist/assets/{global-nav.stories-B5Nk8JZ0.js → global-nav.stories-Fh1gScqg.js} +2 -10
  90. package/dist/assets/{grid-DYgnZBsd.js → grid-C5CKMXNe.js} +3 -19
  91. package/dist/assets/{grid.stories-BFiXTq2C.js → grid.stories-BLmCNdeA.js} +1 -1
  92. package/dist/assets/{header.stories-D1f7xhjV.js → header.stories-BkDrjJtj.js} +1 -9
  93. package/dist/assets/{heading-485Jz7JZ.js → heading-Dbka33DK.js} +2 -10
  94. package/dist/assets/{heading.stories-gPF_SmTc.js → heading.stories-Be40_bmG.js} +1 -1
  95. package/dist/assets/{hero.stories-BHlFNdvF.js → hero.stories-vRu7PZG9.js} +1 -9
  96. package/dist/assets/{icon-DeTLDzTS.js → icon-ChfRWXWy.js} +2 -10
  97. package/dist/assets/{icon-description-o-YaiEjK.js → icon-description-BBSwDykJ.js} +1 -1
  98. package/dist/assets/{icon-description.stories-BdPRvEwe.js → icon-description.stories-Cg6ekOme.js} +1 -1
  99. package/dist/assets/{icon.stories-BxWpqxT5.js → icon.stories-Cj4U7L5G.js} +1 -1
  100. package/dist/assets/if-defined-Bxnzk64Q.js +1 -0
  101. package/dist/assets/{iframe-dHvya7sk.js → iframe-BNJP6ovU.js} +35 -35
  102. package/dist/assets/{inline-alert.stories-FH0bQ0jh.js → inline-alert.stories-CygBYI02.js} +1 -9
  103. package/dist/assets/{layout-container.stories-D6Z6Kx78.js → layout-container.stories-TMyIJteJ.js} +2 -10
  104. package/dist/assets/{layout.stories-CNYuwC_r.js → layout.stories-ylRM-ANL.js} +7 -23
  105. package/dist/assets/{linelength-container.stories-pCRXZvxS.js → linelength-container.stories-Br2v8jXE.js} +1 -9
  106. package/dist/assets/{link-BpCiLxNW.js → link-CRE0Eqdo.js} +1 -9
  107. package/dist/assets/{link-list.stories-12vsAa1P.js → link-list.stories--y-urrVo.js} +7 -23
  108. package/dist/assets/{link.stories-DAoQtY4_.js → link.stories-C3WQOgkY.js} +2 -2
  109. package/dist/assets/{list.stories-D0N3yBIf.js → list.stories-Bd2bxkxn.js} +7 -23
  110. package/dist/assets/{loading-spinner-g6iJajXH.js → loading-spinner-C52KNq6y.js} +4 -12
  111. package/dist/assets/{loading-spinner.stories-B6_mgPxB.js → loading-spinner.stories-DPRGEeHT.js} +1 -1
  112. package/dist/assets/{logo.stories-BvMwN2qg.js → logo.stories-2LBqqraT.js} +1 -9
  113. package/dist/assets/{main.stories-pL4zefbs.js → main.stories-BQzD7iWD.js} +2 -10
  114. package/dist/assets/{medication-card.stories-DK1XGJic.js → medication-card.stories-Wc-hA0-s.js} +5 -5
  115. package/dist/assets/{medication-form.stories-Bj5dLp5S.js → medication-form.stories-DfFOCDaU.js} +1 -1
  116. package/dist/assets/{modal-CO0M4e_8.js → modal-CCfbY4fF.js} +1 -9
  117. package/dist/assets/{modal-BNu8xy08.js → modal-GglWRNJp.js} +1 -1
  118. package/dist/assets/{modal.stories-CHYBrq_E.js → modal.stories-CpybCs79.js} +1 -1
  119. package/dist/assets/{multi-select.stories-C9XXsWio.js → multi-select.stories-BhzEKRui.js} +1 -9
  120. package/dist/assets/{nav-container.stories-DU9fhvDu.js → nav-container.stories-Be1YlegP.js} +3 -11
  121. package/dist/assets/{page-header.stories-BrstKiEY.js → page-header.stories-BOVLQ0YF.js} +1 -9
  122. package/dist/assets/{pagination.stories-Bw2M2iOn.js → pagination.stories-D62sa_1K.js} +9 -25
  123. package/dist/assets/{percent-bar.stories-UQRXYUqd.js → percent-bar.stories-CYi4El7T.js} +1 -9
  124. package/dist/assets/{popover.stories-ZkwrRFpR.js → popover.stories-B9O8F4yv.js} +1 -9
  125. package/dist/assets/{primary-nav.stories-wqOKwgQn.js → primary-nav.stories-Bt-o7h45.js} +1 -17
  126. package/dist/assets/{progress-meter-TzASasu0.js → progress-meter-Dit59091.js} +1 -9
  127. package/dist/assets/{progress-meter.stories-qfJALZf8.js → progress-meter.stories-CYnOCmjo.js} +1 -1
  128. package/dist/assets/{progress-steps-item-KvW1d_7L.js → progress-steps-item-CWJsad0s.js} +1 -9
  129. package/dist/assets/{progress-steps-item.stories-uOn6tJ1W.js → progress-steps-item.stories-ePn_6bPn.js} +1 -1
  130. package/dist/assets/{progress-steps.stories-CKFPx8D0.js → progress-steps.stories-CblrEcXF.js} +1 -9
  131. package/dist/assets/{radio-field-item-CTaR50XR.js → radio-field-item-Bm-0RWPe.js} +5 -21
  132. package/dist/assets/{radio-field-item.stories-DQSLj8W1.js → radio-field-item.stories-y_TrTRIW.js} +1 -1
  133. package/dist/assets/{radio-field.stories-Btmc_Iep.js → radio-field.stories-CSWrbUrn.js} +1 -1
  134. package/dist/assets/{remove-tag-BSEZ7VT8.js → remove-tag-lCr57c5r.js} +1 -9
  135. package/dist/assets/{remove-tag.stories-diRKi7Ua.js → remove-tag.stories-CDfwCdvZ.js} +1 -1
  136. package/dist/assets/{request-prescription.stories-DQvra7ia.js → request-prescription.stories-O4zqokfb.js} +1 -1
  137. package/dist/assets/{sample-modal.stories-deE1EBfZ.js → sample-modal.stories-BZ4N2R2Z.js} +1 -1
  138. package/dist/assets/{section.stories-DF4mcy2O.js → section.stories-D_1InThX.js} +1 -9
  139. package/dist/assets/{select-tile-D-C8oSrm.js → select-tile-BqqB3ZtE.js} +2 -10
  140. package/dist/assets/{select-tile-list.stories-vsBQUIcl.js → select-tile-list.stories-Di4ILgV8.js} +1 -9
  141. package/dist/assets/{select-tile.stories-CqHzN5fc.js → select-tile.stories-D3h_6zlV.js} +6 -6
  142. package/dist/assets/{select.stories-8aOGxTtr.js → select.stories-BB2phP9A.js} +1 -9
  143. package/dist/assets/{skeleton-loader.stories-CwR2-aC5.js → skeleton-loader.stories-y4uml_kV.js} +5 -13
  144. package/dist/assets/{split-button.stories-CyfdrK4u.js → split-button.stories-C_82I4ME.js} +2 -10
  145. package/dist/assets/{spread-BPiNgQQF.js → spread-CnPic3C2.js} +1 -1
  146. package/dist/assets/state-DkQhleoO.js +1 -0
  147. package/dist/assets/{submenu.stories-CDhNzZzh.js → submenu.stories-UDtaREr1.js} +2 -18
  148. package/dist/assets/{syntaxhighlighter-T5IQBZDB-BzI6WxUR.js → syntaxhighlighter-T5IQBZDB-D-I_s_yD.js} +1 -1
  149. package/dist/assets/{table-header-CfcchoYz.js → table-header-2837i43H.js} +3 -51
  150. package/dist/assets/{table-object.stories-Bd5qdfMU.js → table-object.stories-D4KoI-wA.js} +1 -9
  151. package/dist/assets/{table.stories-DxuBe9dJ.js → table.stories-DUJDibEp.js} +1 -1
  152. package/dist/assets/{tabs.stories-Cpc3OHJx.js → tabs.stories-C06SngOF.js} +5 -29
  153. package/dist/assets/{tag-list.stories-BmyCmrTF.js → tag-list.stories-Du-IoYzu.js} +2 -10
  154. package/dist/assets/{tag-vQFuZneb.js → tag-oHGdclJl.js} +1 -9
  155. package/dist/assets/{tag.stories-DGzrNUbb.js → tag.stories-C5D5IbuK.js} +1 -1
  156. package/dist/assets/{tertiary-nav.stories-D4q5K-am.js → tertiary-nav.stories-B1GU8Zi4.js} +3 -19
  157. package/dist/assets/{text-link-4qLRIeJB.js → text-link-B3m3KEqY.js} +1 -9
  158. package/dist/assets/{text-link.stories-D6BRm2I5.js → text-link.stories-4O6qn82H.js} +1 -1
  159. package/dist/assets/{text-passage-DGaI5i2I.js → text-passage-xQVosjOr.js} +3 -19
  160. package/dist/assets/{text-passage.stories-DkmXVUhH.js → text-passage.stories-Da1nspwG.js} +1 -1
  161. package/dist/assets/{tooltip.stories-B7ADDq7o.js → tooltip.stories-DLKyyeKn.js} +6 -14
  162. package/dist/assets/{utility-nav.stories-ffXVvyLp.js → utility-nav.stories-B6xBFe7z.js} +5 -21
  163. package/dist/design-tokens/brands/cre8/css/tokens_brand.css +1 -1
  164. package/dist/design-tokens/core/scss/theming/component.css +1 -1
  165. package/dist/design-tokens/core/scss/theming/variables.css +1 -7
  166. package/dist/design-tokens/core/scss/theming/variables.scss +0 -11
  167. package/dist/icons/cre8-icons.svg +1 -1
  168. package/dist/iframe.html +1 -24
  169. package/dist/index.html +25 -77
  170. package/dist/project.json +1 -1
  171. package/lib/a2ui/registry.d.ts.map +1 -1
  172. package/lib/a2ui/registry.js +28 -0
  173. package/lib/a2ui/registry.js.map +1 -1
  174. package/lib/a2ui/renderer.d.ts +2 -1
  175. package/lib/a2ui/renderer.d.ts.map +1 -1
  176. package/lib/a2ui/renderer.js +1 -1
  177. package/lib/a2ui/renderer.js.map +1 -1
  178. package/lib/a2ui/stream/diff.d.ts +29 -0
  179. package/lib/a2ui/stream/diff.d.ts.map +1 -0
  180. package/lib/a2ui/stream/diff.js +131 -0
  181. package/lib/a2ui/stream/diff.js.map +1 -0
  182. package/lib/a2ui/stream/index.d.ts +12 -0
  183. package/lib/a2ui/stream/index.d.ts.map +1 -0
  184. package/lib/a2ui/stream/index.js +12 -0
  185. package/lib/a2ui/stream/index.js.map +1 -0
  186. package/lib/a2ui/stream/model.d.ts +67 -0
  187. package/lib/a2ui/stream/model.d.ts.map +1 -0
  188. package/lib/a2ui/stream/model.js +423 -0
  189. package/lib/a2ui/stream/model.js.map +1 -0
  190. package/lib/a2ui/stream/pointer.d.ts +35 -0
  191. package/lib/a2ui/stream/pointer.d.ts.map +1 -0
  192. package/lib/a2ui/stream/pointer.js +147 -0
  193. package/lib/a2ui/stream/pointer.js.map +1 -0
  194. package/lib/a2ui/stream/renderer.d.ts +52 -0
  195. package/lib/a2ui/stream/renderer.d.ts.map +1 -0
  196. package/lib/a2ui/stream/renderer.js +279 -0
  197. package/lib/a2ui/stream/renderer.js.map +1 -0
  198. package/lib/a2ui/stream/types.d.ts +174 -0
  199. package/lib/a2ui/stream/types.d.ts.map +1 -0
  200. package/lib/a2ui/stream/types.js +18 -0
  201. package/lib/a2ui/stream/types.js.map +1 -0
  202. package/lib/a2ui/types.d.ts +5 -0
  203. package/lib/a2ui/types.d.ts.map +1 -1
  204. package/lib/a2ui/types.js.map +1 -1
  205. package/lib/components/accordion/accordion.d.ts +15 -0
  206. package/lib/components/accordion/accordion.d.ts.map +1 -1
  207. package/lib/components/accordion/accordion.js +23 -0
  208. package/lib/components/accordion/accordion.js.map +1 -1
  209. package/lib/components/badge/badge.d.ts +4 -17
  210. package/lib/components/badge/badge.d.ts.map +1 -1
  211. package/lib/components/badge/badge.js +0 -15
  212. package/lib/components/badge/badge.js.map +1 -1
  213. package/lib/components/breadcrumbs/breadcrumbs.d.ts +14 -0
  214. package/lib/components/breadcrumbs/breadcrumbs.d.ts.map +1 -1
  215. package/lib/components/breadcrumbs/breadcrumbs.js +21 -0
  216. package/lib/components/breadcrumbs/breadcrumbs.js.map +1 -1
  217. package/lib/components/chart/chart.d.ts +3 -3
  218. package/lib/components/chart/chart.js +6 -6
  219. package/lib/components/chart/chart.js.map +1 -1
  220. package/lib/components/checkbox-field/checkbox-field.d.ts +19 -0
  221. package/lib/components/checkbox-field/checkbox-field.d.ts.map +1 -1
  222. package/lib/components/checkbox-field/checkbox-field.js +28 -0
  223. package/lib/components/checkbox-field/checkbox-field.js.map +1 -1
  224. package/lib/components/cre8-element.d.ts +19 -0
  225. package/lib/components/cre8-element.d.ts.map +1 -1
  226. package/lib/components/cre8-element.js +51 -2
  227. package/lib/components/cre8-element.js.map +1 -1
  228. package/lib/components/divider/divider.d.ts +1 -1
  229. package/lib/components/divider/divider.d.ts.map +1 -1
  230. package/lib/components/divider/divider.js.map +1 -1
  231. package/lib/components/dropdown/dropdown.d.ts +13 -0
  232. package/lib/components/dropdown/dropdown.d.ts.map +1 -1
  233. package/lib/components/dropdown/dropdown.js +19 -0
  234. package/lib/components/dropdown/dropdown.js.map +1 -1
  235. package/lib/components/dropdown-item/dropdown-item.d.ts +1 -1
  236. package/lib/components/dropdown-item/dropdown-item.js +2 -2
  237. package/lib/components/dropdown-item/dropdown-item.js.map +1 -1
  238. package/lib/components/heading/heading.d.ts +3 -5
  239. package/lib/components/heading/heading.d.ts.map +1 -1
  240. package/lib/components/heading/heading.js +2 -4
  241. package/lib/components/heading/heading.js.map +1 -1
  242. package/lib/components/link-list/link-list.d.ts +19 -0
  243. package/lib/components/link-list/link-list.d.ts.map +1 -1
  244. package/lib/components/link-list/link-list.js +19 -0
  245. package/lib/components/link-list/link-list.js.map +1 -1
  246. package/lib/components/list/list.d.ts +13 -0
  247. package/lib/components/list/list.d.ts.map +1 -1
  248. package/lib/components/list/list.js +15 -0
  249. package/lib/components/list/list.js.map +1 -1
  250. package/lib/components/modal/modal.d.ts +2 -2
  251. package/lib/components/modal/modal.js +2 -2
  252. package/lib/components/modal/modal.js.map +1 -1
  253. package/lib/components/multi-select/multi-select.d.ts +2 -2
  254. package/lib/components/multi-select/multi-select.js +5 -5
  255. package/lib/components/multi-select/multi-select.js.map +1 -1
  256. package/lib/components/pagination/pagination.d.ts +1 -1
  257. package/lib/components/pagination/pagination.js +2 -2
  258. package/lib/components/pagination/pagination.js.map +1 -1
  259. package/lib/components/percent-bar/percent-bar.d.ts +2 -0
  260. package/lib/components/percent-bar/percent-bar.d.ts.map +1 -1
  261. package/lib/components/percent-bar/percent-bar.js +3 -1
  262. package/lib/components/percent-bar/percent-bar.js.map +1 -1
  263. package/lib/components/popover/popover.d.ts +6 -7
  264. package/lib/components/popover/popover.d.ts.map +1 -1
  265. package/lib/components/popover/popover.js +4 -4
  266. package/lib/components/popover/popover.js.map +1 -1
  267. package/lib/components/progress-meter/progress-meter.d.ts +0 -8
  268. package/lib/components/progress-meter/progress-meter.d.ts.map +1 -1
  269. package/lib/components/progress-meter/progress-meter.js +0 -7
  270. package/lib/components/progress-meter/progress-meter.js.map +1 -1
  271. package/lib/components/progress-steps/progress-steps.d.ts +16 -0
  272. package/lib/components/progress-steps/progress-steps.d.ts.map +1 -1
  273. package/lib/components/progress-steps/progress-steps.js +25 -0
  274. package/lib/components/progress-steps/progress-steps.js.map +1 -1
  275. package/lib/components/progress-steps-item/progress-steps-item.d.ts +1 -3
  276. package/lib/components/progress-steps-item/progress-steps-item.d.ts.map +1 -1
  277. package/lib/components/progress-steps-item/progress-steps-item.js +0 -1
  278. package/lib/components/progress-steps-item/progress-steps-item.js.map +1 -1
  279. package/lib/components/radio-field/radio-field.d.ts +33 -0
  280. package/lib/components/radio-field/radio-field.d.ts.map +1 -1
  281. package/lib/components/radio-field/radio-field.js +62 -0
  282. package/lib/components/radio-field/radio-field.js.map +1 -1
  283. package/lib/components/remove-tag/remove-tag.d.ts +1 -1
  284. package/lib/components/remove-tag/remove-tag.js +3 -3
  285. package/lib/components/remove-tag/remove-tag.js.map +1 -1
  286. package/lib/components/split-button/split-button.d.ts +3 -0
  287. package/lib/components/split-button/split-button.d.ts.map +1 -1
  288. package/lib/components/split-button/split-button.js +5 -2
  289. package/lib/components/split-button/split-button.js.map +1 -1
  290. package/lib/components/tab/tab.d.ts +1 -1
  291. package/lib/components/tab/tab.js +3 -3
  292. package/lib/components/tab/tab.js.map +1 -1
  293. package/lib/components/table/table.d.ts +36 -0
  294. package/lib/components/table/table.d.ts.map +1 -1
  295. package/lib/components/table/table.js +55 -0
  296. package/lib/components/table/table.js.map +1 -1
  297. package/lib/components/tabs/tabs.d.ts +20 -3
  298. package/lib/components/tabs/tabs.d.ts.map +1 -1
  299. package/lib/components/tabs/tabs.js +33 -5
  300. package/lib/components/tabs/tabs.js.map +1 -1
  301. package/lib/components/tag-list/tag-list.d.ts +17 -0
  302. package/lib/components/tag-list/tag-list.d.ts.map +1 -1
  303. package/lib/components/tag-list/tag-list.js +25 -0
  304. package/lib/components/tag-list/tag-list.js.map +1 -1
  305. package/lib/components/tooltip/tooltip.d.ts +2 -2
  306. package/lib/components/tooltip/tooltip.js +4 -4
  307. package/lib/components/tooltip/tooltip.js.map +1 -1
  308. package/lib/components/utils/light-children.d.ts +40 -0
  309. package/lib/components/utils/light-children.d.ts.map +1 -0
  310. package/lib/components/utils/light-children.js +100 -0
  311. package/lib/components/utils/light-children.js.map +1 -0
  312. package/lib/directives/if-truthy.d.ts +1 -1
  313. package/lib/light-children-TlEXev5S.js +39 -0
  314. package/lib/scripts/generate-mcp-manifest.js +38 -0
  315. package/lib/scripts/generate-mcp-manifest.js.map +1 -1
  316. package/lib/scripts/generate-react-wrappers.d.ts +8 -1
  317. package/lib/scripts/generate-react-wrappers.d.ts.map +1 -1
  318. package/lib/scripts/generate-react-wrappers.js +45 -1
  319. package/lib/scripts/generate-react-wrappers.js.map +1 -1
  320. package/mcp-manifest.json +169 -52
  321. package/package.json +14 -5
  322. package/react-manifest.json +153 -47
  323. package/dist/assets/if-defined-HKKhGupN.js +0 -1
  324. package/dist/assets/iframe-CWwoGI65.css +0 -1
  325. package/dist/assets/state-CfuknrX8.js +0 -1
  326. package/dist/fonts/PlusJakartaSans-Bold.woff2 +0 -0
  327. package/dist/fonts/PlusJakartaSans-Medium.woff2 +0 -0
  328. package/dist/fonts/PlusJakartaSans-Regular.woff2 +0 -0
  329. package/dist/fonts/PlusJakartaSans-SemiBold.woff2 +0 -0
  330. package/dist/logo.svg +0 -1
  331. package/dist/sb-addons/storybook-4/manager-bundle.js +0 -8
  332. /package/dist/icons/{express-scripts copy.svg → pharmacy copy.svg} +0 -0
  333. /package/dist/icons/{express-scripts.svg → pharmacy.svg} +0 -0
@@ -0,0 +1,294 @@
1
+ /**
2
+ * Renders every catalog component and checks that its free-text props actually
3
+ * reach the DOM.
4
+ *
5
+ * node a2ui/render-audit.mjs # report
6
+ * node a2ui/render-audit.mjs --check # fail on anything not in KNOWN_INERT
7
+ *
8
+ * Why this exists: `validateSpec` answers "is this consistent with the
9
+ * catalog", which is not the same question as "will this render". The gap is
10
+ * not theoretical — `cre8-link-list-item` declares a `text` prop, documents it
11
+ * in its own JSDoc as "The link text", and never reads it, so a spec using
12
+ * `props.text` validates cleanly and produces an empty link. The same shape as
13
+ * the `cre8-heading.type` bug in docs/kb/04-a2ui.md.
14
+ *
15
+ * The method: give each free-text prop a sentinel value, upgrade the element
16
+ * with the real CDN bundle under jsdom, and look for the sentinel anywhere in
17
+ * the resulting shadow tree. A prop that drives styling shows up as a class; a
18
+ * prop that is reflected shows up as an attribute; a prop that is rendered shows
19
+ * up as text. A prop that appears nowhere is inert.
20
+ *
21
+ * What it cannot see: layout, colour, and anything that needs a real engine.
22
+ * jsdom upgrades components and runs their templates; it does not lay them out.
23
+ */
24
+
25
+ import { existsSync, readFileSync, writeFileSync } from 'node:fs';
26
+ import { dirname, resolve } from 'node:path';
27
+ import { fileURLToPath } from 'node:url';
28
+ import { JSDOM } from 'jsdom';
29
+
30
+ const HERE = dirname(fileURLToPath(import.meta.url));
31
+ const WC = resolve(HERE, '..');
32
+ const SENTINEL = 'Zq7Wx';
33
+
34
+ /**
35
+ * Props known to be inert, with the reason. A prop listed here is asserted to
36
+ * still be broken — same inversion as the KB's drift ledger, so fixing one makes
37
+ * this file fail and prompts the entry to be removed.
38
+ */
39
+ const KNOWN_INERT = {
40
+ 'cre8-link-list-item': {
41
+ text: 'Documented as "The link text"; render() never reads it. The label comes from the default slot.',
42
+ },
43
+ 'cre8-field': {
44
+ errorText: 'Declared with a default of "Error" and never read. The message that renders is `fieldNote`, shown in the error style by `isError`.',
45
+ successText: 'Declared with a default of "Success" and never read. Use `fieldNote` with `isSuccess`.',
46
+ },
47
+ 'cre8-date-picker': {
48
+ errorText: 'Declared and never read. Use `fieldNote` with `isError`.',
49
+ successText: 'Declared and never read. Use `fieldNote` with `isSuccess`.',
50
+ },
51
+ 'cre8-modal': {
52
+ closeButtonText: 'Declared and never read; the close control takes its label from elsewhere.',
53
+ },
54
+ };
55
+
56
+ // ─── jsdom, wired up enough for Lit ─────────────────────────────────────────
57
+
58
+ const dom = new JSDOM('<!doctype html><html><body></body></html>', {
59
+ pretendToBeVisual: true,
60
+ url: 'http://localhost/',
61
+ });
62
+ const win = dom.window;
63
+
64
+ for (const key of Object.getOwnPropertyNames(win)) {
65
+ if (key === 'undefined' || key in globalThis) continue;
66
+ try {
67
+ globalThis[key] = win[key];
68
+ } catch {
69
+ /* read-only global; jsdom's copy is not needed */
70
+ }
71
+ }
72
+ // Node defines these too, and a component that constructs one with Node's class
73
+ // cannot dispatch it on a jsdom EventTarget — @lit/context does exactly that.
74
+ for (const key of ['Event', 'CustomEvent', 'EventTarget', 'MessageEvent', 'MutationObserver']) {
75
+ if (win[key]) {
76
+ try {
77
+ globalThis[key] = win[key];
78
+ } catch {
79
+ /* ignore */
80
+ }
81
+ }
82
+ }
83
+ globalThis.window = win;
84
+ globalThis.document = win.document;
85
+
86
+ const catalog = JSON.parse(readFileSync(resolve(WC, 'a2ui/catalog.json'), 'utf8'));
87
+ const defs = catalog.$defs?.components ?? {};
88
+
89
+ // Importing the bundle registers all 85 elements.
90
+ await import(resolve(WC, 'cdn/cre8-wc.esm.js'));
91
+
92
+ // ─── the audit ──────────────────────────────────────────────────────────────
93
+
94
+ /**
95
+ * Only props whose *own documentation* says they are rendered text.
96
+ *
97
+ * A wider net does not work, and the reason is worth recording: sweeping every
98
+ * free-text prop flags 69 of them, and almost all are artefacts rather than
99
+ * bugs — form values consumed by ElementInternals (which jsdom does not
100
+ * implement), icon and style values that need a well-formed input before
101
+ * anything appears, and text that only renders once the component is open. A
102
+ * check with that signal-to-noise trains people to ignore it.
103
+ */
104
+ const RENDERED_TEXT = /\b(text|label|heading|message|caption)\b/i;
105
+
106
+ function renderedTextProps(def) {
107
+ const props = def.properties?.props?.properties ?? {};
108
+ return Object.entries(props)
109
+ .filter(([name, schema]) => {
110
+ const types = Array.isArray(schema.type) ? schema.type : [schema.type];
111
+ if (!types.includes('string') || schema.enum || schema.const !== undefined) return false;
112
+ if (/icon|svg|href|src|id|name|value|class|style|aria|width|height|colou?r|max|min|^type$/i.test(name)) {
113
+ return false;
114
+ }
115
+ return RENDERED_TEXT.test(name) || RENDERED_TEXT.test(String(schema.description ?? ''));
116
+ })
117
+ .map(([name]) => name);
118
+ }
119
+
120
+ /** Every boolean prop, so a second pass can switch the component's states on. */
121
+ function booleanProps(def) {
122
+ return Object.entries(def.properties?.props?.properties ?? {})
123
+ .filter(([, schema]) => {
124
+ const types = Array.isArray(schema.type) ? schema.type : [schema.type];
125
+ return types.includes('boolean');
126
+ })
127
+ .map(([name]) => name);
128
+ }
129
+
130
+ function contentRoute(def) {
131
+ if (def.properties?.children !== undefined) return 'children';
132
+ if (def.properties?.slots?.properties) {
133
+ const slots = Object.keys(def.properties.slots.properties);
134
+ return slots.includes('default') ? 'default' : (slots[0] ?? null);
135
+ }
136
+ return null;
137
+ }
138
+
139
+ /**
140
+ * Second, independent check: does the component's own source ever read the
141
+ * property back? Rendering alone cannot tell an inert prop from one that needs
142
+ * a state this audit did not reach, and static reading alone cannot tell a
143
+ * rendered prop from one consumed by CSS. Where both agree, the prop is inert;
144
+ * where they disagree, it is state-dependent and reported as unverified.
145
+ */
146
+ function readsPropInSource(tag, prop) {
147
+ const dir = tag.replace(/^cre8-/, '');
148
+ const file = resolve(WC, 'components', dir, `${dir}.ts`);
149
+ if (!existsSync(file)) return null;
150
+ return new RegExp(`this\\.${prop}\\b`).test(readFileSync(file, 'utf8'));
151
+ }
152
+
153
+ const results = [];
154
+ const errored = [];
155
+ let rendered = 0;
156
+ let skipped = 0;
157
+
158
+ // Some components throw when rendered bare — cre8-popover reaches into a
159
+ // trigger it expects to have been slotted. That is worth reporting, but it must
160
+ // not end the audit, and Lit surfaces it from a microtask where a try/catch
161
+ // around appendChild cannot see it.
162
+ let current = null;
163
+ process.on('uncaughtException', (error) => {
164
+ errored.push({ tag: current ?? '(unknown)', message: error.message.split('\n')[0].slice(0, 120) });
165
+ });
166
+
167
+ for (const [tag, def] of Object.entries(defs)) {
168
+ if (!win.customElements.get(tag)) {
169
+ skipped += 1;
170
+ continue;
171
+ }
172
+
173
+ const props = renderedTextProps(def);
174
+ if (!props.length) continue;
175
+
176
+ current = tag;
177
+
178
+ // Two passes. Most "missing" text is not missing, it is switched off:
179
+ // errorText renders only under isError, a modal's close button only when it
180
+ // is open. So render once bare, then again with every boolean prop true, and
181
+ // only report a prop that never appeared in either.
182
+ const renderOnce = async (withStates) => {
183
+ const el = win.document.createElement(tag);
184
+ for (const prop of props) el.setAttribute(prop, `${SENTINEL}${prop}`);
185
+ if (withStates) for (const flag of booleanProps(def)) el.setAttribute(flag, '');
186
+
187
+ const route = contentRoute(def);
188
+ if (route === 'children') {
189
+ el.appendChild(win.document.createTextNode('content'));
190
+ } else if (route) {
191
+ const child = win.document.createElement('span');
192
+ if (route !== 'default') child.setAttribute('slot', route);
193
+ child.textContent = 'content';
194
+ el.appendChild(child);
195
+ }
196
+
197
+ try {
198
+ win.document.body.appendChild(el);
199
+ await new Promise((r) => setTimeout(r, 0));
200
+ if (el.updateComplete) await el.updateComplete.catch(() => {});
201
+ } catch (error) {
202
+ errored.push({ tag, message: String(error?.message ?? error).split('\n')[0].slice(0, 120) });
203
+ }
204
+
205
+ // Light DOM too: a parent may stamp a prop onto its slotted children.
206
+ const html = `${el.shadowRoot?.innerHTML ?? ''}${el.innerHTML}`;
207
+ const upgraded = Boolean(el.shadowRoot);
208
+ el.remove();
209
+ return { html, upgraded };
210
+ };
211
+
212
+ const bare = await renderOnce(false);
213
+ const active = await renderOnce(true);
214
+
215
+ if (!bare.upgraded && !active.upgraded) {
216
+ results.push({ tag, prop: '(no shadow root)', kind: 'unrendered' });
217
+ } else {
218
+ rendered += 1;
219
+ for (const prop of props) {
220
+ const token = `${SENTINEL}${prop}`;
221
+ if (!bare.html.includes(token) && !active.html.includes(token)) {
222
+ results.push({ tag, prop, kind: 'inert' });
223
+ }
224
+ }
225
+ }
226
+ }
227
+
228
+ // ─── report ─────────────────────────────────────────────────────────────────
229
+
230
+ const known = (tag, prop) => KNOWN_INERT[tag]?.[prop];
231
+ for (const r of results) r.readInSource = readsPropInSource(r.tag, r.prop);
232
+
233
+ // Confirmed = never rendered AND never read back in source.
234
+ const confirmed = results.filter((r) => r.readInSource === false);
235
+ const unverified = results.filter((r) => r.readInSource !== false);
236
+ const fresh = confirmed.filter((r) => !known(r.tag, r.prop));
237
+ const expected = Object.entries(KNOWN_INERT).flatMap(([tag, props]) =>
238
+ Object.keys(props).map((prop) => ({ tag, prop }))
239
+ );
240
+ const stillBroken = expected.filter((e) => results.some((r) => r.tag === e.tag && r.prop === e.prop));
241
+ const nowFixed = expected.filter((e) => !stillBroken.some((s) => s.tag === e.tag && s.prop === e.prop));
242
+
243
+ console.log(`rendered ${rendered} components (${skipped} not registered by the bundle)`);
244
+ if (errored.length) {
245
+ console.log(`${errored.length} threw while rendering bare:`);
246
+ for (const e of errored) console.log(` ${e.tag}: ${e.message}`);
247
+ console.log('');
248
+ }
249
+ console.log(
250
+ `${results.length} prop(s) never reached the DOM: ${confirmed.length} confirmed inert by source too, ` +
251
+ `${unverified.length} state-dependent and unverified\n`
252
+ );
253
+
254
+ for (const r of fresh) {
255
+ console.log(` ${r.tag}.${r.prop} — never rendered, and never read in ${r.tag.replace(/^cre8-/, '')}.ts`);
256
+ }
257
+ if (unverified.length) {
258
+ console.log('\n unverified (the source reads them; a state this audit did not reach must show them):');
259
+ for (const r of unverified) console.log(` ${r.tag}.${r.prop}`);
260
+ }
261
+ for (const e of stillBroken) {
262
+ console.log(` (known) ${e.tag}.${e.prop} — ${KNOWN_INERT[e.tag][e.prop]}`);
263
+ }
264
+ for (const e of nowFixed) {
265
+ console.log(` FIXED: ${e.tag}.${e.prop} now reaches the DOM — remove it from KNOWN_INERT`);
266
+ }
267
+
268
+ // Ship the confirmed list so the MCP connector can warn an agent before it
269
+ // sets a prop that will silently do nothing.
270
+ const inertFile = resolve(WC, 'a2ui/inert-props.json');
271
+ const payload = {
272
+ $comment:
273
+ 'Generated by a2ui/render-audit.mjs. Props that are declared in the catalog but never reach ' +
274
+ 'the DOM — confirmed twice, by rendering under jsdom and by reading the component source. ' +
275
+ 'Setting one validates cleanly and does nothing.',
276
+ libraryVersion: catalog['x-a2ui']?.libraryVersion,
277
+ components: Object.fromEntries(
278
+ Object.entries(KNOWN_INERT).map(([tag, props]) => [
279
+ tag,
280
+ Object.fromEntries(Object.entries(props).map(([prop, reason]) => [prop, { reason }])),
281
+ ])
282
+ ),
283
+ };
284
+ writeFileSync(inertFile, `${JSON.stringify(payload, null, 2)}\n`);
285
+
286
+ const check = process.argv.includes('--check');
287
+ if (check && (fresh.length || nowFixed.length)) {
288
+ console.error(
289
+ `\nrender audit failed: ${fresh.length} new inert prop(s), ${nowFixed.length} fixed but still listed`
290
+ );
291
+ process.exit(1);
292
+ }
293
+ if (check) console.log('\nok — every free-text prop reaches the DOM, except the ones documented as inert');
294
+ process.exit(0);
@@ -1,7 +1,8 @@
1
- import type { ComponentSpec, EmittedEvent, RegisteredCatalog } from './types.js';
1
+ import type { ComponentSpec, EmittedEvent, PropSchema, RegisteredCatalog } from './types.js';
2
2
  export interface RenderOptions {
3
3
  root?: HTMLElement;
4
4
  doc?: Document;
5
5
  onEvent?: (evt: EmittedEvent) => void;
6
6
  }
7
7
  export declare function render(spec: ComponentSpec, catalog: RegisteredCatalog, options?: RenderOptions): HTMLElement;
8
+ export declare function applyProp(el: HTMLElement, key: string, value: unknown, schema: PropSchema | undefined): void;
package/a2ui/renderer.js CHANGED
@@ -76,7 +76,7 @@ function attachEvent(el, component, path, eventName, binding, onEvent) {
76
76
  });
77
77
  });
78
78
  }
79
- function applyProp(el, key, value, schema) {
79
+ export function applyProp(el, key, value, schema) {
80
80
  if (value === undefined || value === null)
81
81
  return;
82
82
  if (schema?.['x-kind'] === 'property') {
package/a2ui/renderer.ts CHANGED
@@ -117,7 +117,7 @@ function attachEvent(
117
117
  });
118
118
  }
119
119
 
120
- function applyProp(
120
+ export function applyProp(
121
121
  el: HTMLElement,
122
122
  key: string,
123
123
  value: unknown,
@@ -19,7 +19,7 @@ const spec = {
19
19
  component: 'cre8-card',
20
20
  slots: {
21
21
  header: [{ component: 'cre8-button', props: { text: 'Close', variant: 'tertiary' } }],
22
- body: [
22
+ default: [
23
23
  { component: 'cre8-alert', props: { status: 'info' } },
24
24
  {
25
25
  component: 'cre8-button-group',
@@ -73,12 +73,46 @@ try {
73
73
  console.log('slot reject:', e.message);
74
74
  }
75
75
 
76
+ // An invented custom event used to bind cleanly and then never fire — the UI
77
+ // renders and silently does nothing, which is worse than an error.
78
+ const badEvent = { component: 'cre8-modal', events: { 'totally-made-up': 'x' } };
79
+ try {
80
+ validateSpec(badEvent, cat);
81
+ console.error('FAIL: expected rejection of undeclared event');
82
+ process.exit(1);
83
+ } catch (e) {
84
+ console.log('event reject:', e.message);
85
+ }
86
+
87
+ // Binding a real event to the wrong component is the same failure wearing a
88
+ // disguise: the name exists in the library, just not on this component.
89
+ const misattributed = { component: 'cre8-button', events: { 'modal-close': 'x' } };
90
+ try {
91
+ validateSpec(misattributed, cat);
92
+ console.error('FAIL: expected rejection of an event from another component');
93
+ process.exit(1);
94
+ } catch (e) {
95
+ console.log('misattributed event reject:', e.message);
96
+ }
97
+
98
+ // Native DOM events stay bindable on anything — `@fires` documents only what a
99
+ // component dispatches itself, so the catalog can never list `click`.
100
+ for (const native of ['click', 'input', 'submit', 'keydown', 'focus']) {
101
+ validateSpec({ component: 'cre8-button', events: { [native]: 'h' } }, cat);
102
+ }
103
+ console.log('native events accepted on an undocumented component: ok');
104
+
105
+ // Binds one native event and one custom event, on the component that actually
106
+ // dispatches the custom one. It used to bind `split-button-text-click` to a
107
+ // plain `cre8-button`, which no `cre8-button` ever fires — a binding that
108
+ // renders cleanly and then silently does nothing. Event-name validation now
109
+ // rejects that, so the example has to be a real pairing.
76
110
  const eventSpec = {
77
- component: 'cre8-button',
78
- props: { text: 'Save', variant: 'primary' },
111
+ component: 'cre8-split-button',
112
+ props: { buttonText: 'Save' },
79
113
  events: {
80
114
  click: { handler: 'save-record', stopPropagation: true },
81
- 'text-click': 'emit-telemetry',
115
+ 'split-button-text-click': 'emit-telemetry',
82
116
  },
83
117
  };
84
118
 
@@ -86,7 +120,7 @@ const emitted = [];
86
120
  const eventEl = render(eventSpec, cat, { onEvent: (e) => emitted.push(e) });
87
121
 
88
122
  eventEl.dispatchEvent(new dom.window.Event('click', { bubbles: true }));
89
- eventEl.dispatchEvent(new dom.window.CustomEvent('text-click', { detail: { source: 'kbd' } }));
123
+ eventEl.dispatchEvent(new dom.window.CustomEvent('split-button-text-click', { detail: { source: 'kbd' } }));
90
124
 
91
125
  if (emitted.length !== 2) {
92
126
  console.error('FAIL: expected 2 emitted events, got', emitted.length);