@kitn.ai/ui 0.29.0 → 0.31.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 (280) hide show
  1. package/README.md +11 -7
  2. package/dist/{Icon-DObhsRtm.js → Icon-DJDuE_-x.js} +1 -1
  3. package/dist/action-icons-xkBBVKkF.js +1 -0
  4. package/dist/agent-tooling/construct/schema-url.d.ts +9 -0
  5. package/dist/agent-tooling/construct/schema.d.ts +76 -1
  6. package/dist/agent-tooling/construct/templates.d.ts +45 -0
  7. package/dist/arrow-down-DU6wOl-h.js +1 -0
  8. package/dist/arrow-left-DD46kN17.js +1 -0
  9. package/dist/artifact-DoUAr1Fd.js +1 -0
  10. package/dist/assets/dev-DwzHsqYD.js +553 -0
  11. package/dist/{attachments-Qr4kg-2b.js → attachments-BLWPDiLH.js} +1 -1
  12. package/dist/{audio-visualizer-DToYdfSc.js → audio-visualizer-DhHicYvV.js} +1 -1
  13. package/dist/{badge-CdEu_jn2.js → badge-BGm7pcwi.js} +1 -1
  14. package/dist/{bell-DQAAOpDz.js → bell-CMEdSo7A.js} +1 -1
  15. package/dist/builder-app/App.d.ts +1 -0
  16. package/dist/builder-app/edit-guard.d.ts +8 -0
  17. package/dist/builder-app/main.d.ts +0 -0
  18. package/dist/builder-page/assets/index-C10OF-ur.js +72 -0
  19. package/dist/builder-page/assets/index-CFyKLBlu.css +1 -0
  20. package/dist/builder-page/index.html +20 -0
  21. package/dist/button-BM0YTTDQ.js +1 -0
  22. package/dist/{card-renderer-Jx70m6_l.js → card-renderer-Ds-wXc6_.js} +1 -1
  23. package/dist/check-BG1VfYjm.js +1 -0
  24. package/dist/{checkbox-group-B2_rpoPM.js → checkbox-group-CqXj8ehz.js} +1 -1
  25. package/dist/{checkbox-D7iRB3nL.js → checkbox-np_5mKxM.js} +1 -1
  26. package/dist/chevron-down-CZ4W0hy6.js +1 -0
  27. package/dist/chevron-right-5gdxkCTF.js +1 -0
  28. package/dist/{choice-card-m0BYqqOK.js → choice-card-BYBmPAT5.js} +1 -1
  29. package/dist/circle-C0lwjD2A.js +1 -0
  30. package/dist/circle-check-BfT1cxQU.js +1 -0
  31. package/dist/{circle-x-BPG0iPst.js → circle-x-DzUfvRqr.js} +1 -1
  32. package/dist/{code-block-ClMLKb7C.js → code-block-H6E5Eurc.js} +1 -1
  33. package/dist/{collapsible-B4DlWicL.js → collapsible-CBq1Tj6y.js} +1 -1
  34. package/dist/components/builder-composer-triggers.d.ts +62 -0
  35. package/dist/components/builder-layout.d.ts +54 -0
  36. package/dist/components/builder-message-actions.d.ts +63 -0
  37. package/dist/components/builder-panel-derived.d.ts +18 -0
  38. package/dist/components/builder-panel.d.ts +240 -0
  39. package/dist/components/builder-preview.d.ts +11 -0
  40. package/dist/components/builder-shell-controls.d.ts +69 -0
  41. package/dist/components/builder-skeleton.d.ts +58 -0
  42. package/dist/components/builder-start.d.ts +79 -0
  43. package/dist/components/builder-workspace-variants.d.ts +23 -0
  44. package/dist/components/captions.d.ts +66 -0
  45. package/dist/components/chat-thread.d.ts +27 -1
  46. package/dist/components/construct-form-paths.d.ts +54 -0
  47. package/dist/components/message.d.ts +5 -0
  48. package/dist/{composer-sQ0HcvyG.js → composer-B5IvgxAF.js} +1 -1
  49. package/dist/{confirm-card-rQWDQsnC.js → confirm-card-B63pZIfG.js} +1 -1
  50. package/dist/construct-cli.es.js +469 -125
  51. package/dist/construct-templates.d.ts +5 -0
  52. package/dist/construct-templates.js +266 -0
  53. package/dist/construct.js +269 -86
  54. package/dist/{context-0kg4ZX1J.js → context-Byqor78j.js} +1 -1
  55. package/dist/controllable-C4BSt73s.js +1 -0
  56. package/dist/{conversation-item-BxwQLaFJ.js → conversation-item-piXZFRWa.js} +1 -1
  57. package/dist/{conversation-list-BCfGN1JU.js → conversation-list-B5yu9cPg.js} +1 -1
  58. package/dist/{copy-n9u9rqpi.js → copy-DfI2NYEX.js} +1 -1
  59. package/dist/{create-tween-uPkArjIG.js → create-tween-C4j96_Aj.js} +1 -1
  60. package/dist/{create-tween-C-q-JCM-.js → create-tween-CHleHI8m.js} +1 -1
  61. package/dist/{create-tween-CRrJXxBd.js → create-tween-DQ6lOhdl.js} +1 -1
  62. package/dist/{create-tween-DZ3RRDHD.js → create-tween-DyjTgkJi.js} +1 -1
  63. package/dist/custom-elements.json +40 -5
  64. package/dist/{default-input-CaMrJkgH.js → default-input-Bwmt8Lai.js} +1 -1
  65. package/dist/define-B3OpsIDE.js +1 -0
  66. package/dist/define.js +41 -41
  67. package/dist/define.server.js +46 -46
  68. package/dist/{disclosure-WUImBbDv.js → disclosure-ZSAlD4wg.js} +1 -1
  69. package/dist/{dropdown-wZVeJOMd.js → dropdown-CSRhiMN2.js} +1 -1
  70. package/dist/elements/agent-card.js +1 -1
  71. package/dist/elements/artifact.js +1 -1
  72. package/dist/elements/attachments.js +1 -1
  73. package/dist/elements/audio-visualizer.js +1 -1
  74. package/dist/elements/avatar.js +1 -1
  75. package/dist/elements/badge.js +1 -1
  76. package/dist/elements/button.js +1 -1
  77. package/dist/elements/card.js +1 -1
  78. package/dist/elements/cards.js +1 -1
  79. package/dist/elements/chain-of-thought.js +1 -1
  80. package/dist/elements/chat-actions.d.ts +12 -0
  81. package/dist/elements/chat-scope-picker.js +1 -1
  82. package/dist/elements/chat-types.d.ts +7 -2
  83. package/dist/elements/chat-workspace.js +1 -1
  84. package/dist/elements/chat.js +1 -1
  85. package/dist/elements/checkbox-group.js +1 -1
  86. package/dist/elements/checkbox.js +1 -1
  87. package/dist/elements/checkpoint.js +1 -1
  88. package/dist/elements/choice.js +1 -1
  89. package/dist/elements/coachmark.js +1 -1
  90. package/dist/elements/code-block.js +1 -1
  91. package/dist/elements/command.js +1 -1
  92. package/dist/elements/compare.js +1 -1
  93. package/dist/elements/composer.js +1 -1
  94. package/dist/elements/confirm-card.js +1 -1
  95. package/dist/elements/context-meter.js +1 -1
  96. package/dist/elements/conversation-item.js +1 -1
  97. package/dist/elements/conversation-list.js +1 -1
  98. package/dist/elements/dialog.js +1 -1
  99. package/dist/elements/dock.js +1 -1
  100. package/dist/elements/dropdown.js +1 -1
  101. package/dist/elements/editable-label.js +1 -1
  102. package/dist/elements/embed.js +1 -1
  103. package/dist/elements/empty.js +1 -1
  104. package/dist/elements/feedback-bar.js +1 -1
  105. package/dist/elements/file-tree.js +1 -1
  106. package/dist/elements/file-upload.js +1 -1
  107. package/dist/elements/form.js +1 -1
  108. package/dist/elements/hover-card.js +1 -1
  109. package/dist/elements/icon.js +1 -1
  110. package/dist/elements/image.js +1 -1
  111. package/dist/elements/input.js +1 -1
  112. package/dist/elements/kbd.js +1 -1
  113. package/dist/elements/link-preview.js +1 -1
  114. package/dist/elements/loader.js +1 -1
  115. package/dist/elements/markdown.js +1 -1
  116. package/dist/elements/menu.js +1 -1
  117. package/dist/elements/message-skills.js +1 -1
  118. package/dist/elements/message.js +1 -1
  119. package/dist/elements/model-switcher.js +1 -1
  120. package/dist/elements/nav.js +1 -1
  121. package/dist/elements/notice.js +1 -1
  122. package/dist/elements/pane-grid.js +1 -1
  123. package/dist/elements/pane-group.js +1 -1
  124. package/dist/elements/pane.js +1 -1
  125. package/dist/elements/popover.js +1 -1
  126. package/dist/elements/progress-bar.js +1 -1
  127. package/dist/elements/prompt-dock.js +1 -1
  128. package/dist/elements/prompt-input.js +1 -1
  129. package/dist/elements/prompt-suggestions.js +1 -1
  130. package/dist/elements/radio-group.js +1 -1
  131. package/dist/elements/reasoning.js +1 -1
  132. package/dist/elements/remote.js +1 -1
  133. package/dist/elements/resizable.js +1 -1
  134. package/dist/elements/response-stream.js +1 -1
  135. package/dist/elements/screen.js +1 -1
  136. package/dist/elements/scroll-area.js +1 -1
  137. package/dist/elements/scroll-button.js +1 -1
  138. package/dist/elements/search.js +1 -1
  139. package/dist/elements/segmented.js +1 -1
  140. package/dist/elements/select.js +1 -1
  141. package/dist/elements/separator.js +1 -1
  142. package/dist/elements/setting-item.js +1 -1
  143. package/dist/elements/settings-group.js +1 -1
  144. package/dist/elements/skeleton.js +1 -1
  145. package/dist/elements/slider.js +1 -1
  146. package/dist/elements/source.js +1 -1
  147. package/dist/elements/status.js +1 -1
  148. package/dist/elements/switch.js +1 -1
  149. package/dist/elements/tabs.js +1 -1
  150. package/dist/elements/tasks.js +1 -1
  151. package/dist/elements/text-shimmer.js +1 -1
  152. package/dist/elements/thinking-bar.js +1 -1
  153. package/dist/elements/thread.js +1 -1
  154. package/dist/elements/toast.js +1 -1
  155. package/dist/elements/tool.js +1 -1
  156. package/dist/elements/tooltip.js +1 -1
  157. package/dist/elements/voice-input.js +1 -1
  158. package/dist/elements/voice-output.js +1 -1
  159. package/dist/elements.d.ts +22 -10
  160. package/dist/{ellipsis-CbOpJnU3.js → ellipsis-CJ5QIjWo.js} +1 -1
  161. package/dist/{embed-CrfjkbUG.js → embed-6Vji0PfS.js} +1 -1
  162. package/dist/{external-link-ByXAwBBQ.js → external-link-BPTtTdet.js} +1 -1
  163. package/dist/{file-text-DMib2qwt.js → file-text-eVjcFDrK.js} +1 -1
  164. package/dist/{file-tree-CJqM2aP7.js → file-tree-a9tfWYmg.js} +1 -1
  165. package/dist/{folder-_BAb929C.js → folder-DN6Ilq6d.js} +1 -1
  166. package/dist/{form-DSZgZQZk.js → form-U1cwhcQx.js} +1 -1
  167. package/dist/{hover-card-BQbul9eq.js → hover-card-C5ptzZOZ.js} +1 -1
  168. package/dist/{icon-CdcfRhYI.js → icon-BOMrFp0D.js} +1 -1
  169. package/dist/index.js +2297 -2279
  170. package/dist/index.server.js +2102 -2084
  171. package/dist/{info-DsFjGuI_.js → info-DxzKsIHn.js} +1 -1
  172. package/dist/{input-DKbmkMos.js → input-aW72PACH.js} +1 -1
  173. package/dist/kai.es.js +1 -1
  174. package/dist/{kbd-PvdGhX4s.js → kbd-BP-6MwUs.js} +1 -1
  175. package/dist/{link-preview-DbM1866N.js → link-preview-CZaDilMG.js} +1 -1
  176. package/dist/{link-zF8PzWfF.js → link-rlN11N0B.js} +1 -1
  177. package/dist/loader-BdFK70fF.js +1 -0
  178. package/dist/{markdown-LMvmAyBk.js → markdown-DjEaoNz-.js} +1 -1
  179. package/dist/mcp.es.js +587 -111
  180. package/dist/message--Nlbemtp.js +1 -0
  181. package/dist/message-C88yTu2A.js +1 -0
  182. package/dist/message-circle-CZeVDN1f.js +1 -0
  183. package/dist/message-square-BXNBKC6i.js +1 -0
  184. package/dist/{minimize-2-BQRoBV1V.js → minimize-2-BxLOOSEf.js} +1 -1
  185. package/dist/{model-switcher-CMpCOYcB.js → model-switcher-BxRvub2A.js} +1 -1
  186. package/dist/{overlay-Cb-MkyDa.js → overlay-CDwKJtHN.js} +1 -1
  187. package/dist/{panel-right-i8warFxT.js → panel-right-BovedCwW.js} +1 -1
  188. package/dist/{paperclip-ByY3UVO6.js → paperclip-D0Xyjja2.js} +1 -1
  189. package/dist/play-DGJ4MgB2.js +1 -0
  190. package/dist/primitives/speech.d.ts +35 -0
  191. package/dist/primitives/use-auto-resize.d.ts +11 -0
  192. package/dist/{progress-bar-jVAHvMUf.js → progress-bar-D-aQfy5h.js} +1 -1
  193. package/dist/{prompt-suggestion-CD-qtNgC.js → prompt-suggestion-C6qLjMEQ.js} +1 -1
  194. package/dist/{radio-BsoBMhkF.js → radio-D1CkXISc.js} +1 -1
  195. package/dist/react/index.d.ts +22 -6
  196. package/dist/react.js +13 -13
  197. package/dist/{reasoning-4kBPtlTx.js → reasoning-DARmbgmE.js} +1 -1
  198. package/dist/register-impl-WcrdIihK.js +424 -0
  199. package/dist/{resizable-uPmY9VY-.js → resizable-Da6oSO2z.js} +1 -1
  200. package/dist/{rotate-ccw-B2xn93py.js → rotate-ccw-31ed1xK_.js} +1 -1
  201. package/dist/{rotate-cw-CMVLoCyH.js → rotate-cw-qkl39dw3.js} +1 -1
  202. package/dist/{scroll-area-BqLUo8ZZ.js → scroll-area-RrKnLYlA.js} +1 -1
  203. package/dist/{scroll-button-DslXiJyL.js → scroll-button--QeNjobK.js} +1 -1
  204. package/dist/{select-2cLRtPGT.js → select-CS_0mWW3.js} +1 -1
  205. package/dist/{separator-BWQtNJcM.js → separator-fT-zBypW.js} +1 -1
  206. package/dist/{settings-BBR63jLg.js → settings-dfkV_WDm.js} +1 -1
  207. package/dist/{settings-group-B2ciy-Iw.js → settings-group-CX694npG.js} +1 -1
  208. package/dist/{skeleton-CkHI-HgC.js → skeleton-BsqKD9TV.js} +1 -1
  209. package/dist/{slider-DDR9U-i0.js → slider-_EWfTH9H.js} +1 -1
  210. package/dist/{solid-DruVOXnf.js → solid-BITWG_VE.js} +4214 -3996
  211. package/dist/{solid-BzCFdL25.js → solid-CRFYWlBw.js} +5647 -5373
  212. package/dist/solid.d.ts +6 -0
  213. package/dist/solid.js +259 -254
  214. package/dist/solid.server.js +259 -254
  215. package/dist/{source-GEnFF528.js → source-Da1TFiuj.js} +1 -1
  216. package/dist/speech-CjbWuqG2.js +1 -0
  217. package/dist/{star-CilHq8GP.js → star-ZvSbbXS6.js} +1 -1
  218. package/dist/{store-Ciyk6eZG.js → store-DE5lcr9q.js} +1 -1
  219. package/dist/{switch-KkeQIbuH.js → switch-P_fsHqv3.js} +1 -1
  220. package/dist/{tasks-card-BrN4bggJ.js → tasks-card-B86qqyZm.js} +1 -1
  221. package/dist/text-shimmer-BAkw_65G.js +1 -0
  222. package/dist/textarea-Bkinatpi.js +1 -0
  223. package/dist/theme.tokens.css +22 -21
  224. package/dist/{thumbs-up-CsT9Wzb9.js → thumbs-up-CDGW7a4o.js} +1 -1
  225. package/dist/{toast-store-tgK6MuMv.js → toast-store-B94I50AO.js} +1 -1
  226. package/dist/{tool-DzUjIBT8.js → tool-CUiCeyi1.js} +1 -1
  227. package/dist/{tooltip-Bkkg_4t0.js → tooltip-B3wlQSPh.js} +1 -1
  228. package/dist/{trash-2-jBKxjGGQ.js → trash-2-Cu8yZmFQ.js} +1 -1
  229. package/dist/{triangle-alert-DlQ68ppf.js → triangle-alert-CCtDUUmn.js} +1 -1
  230. package/dist/ui/button-variant-names.d.ts +12 -0
  231. package/dist/ui/button.d.ts +6 -0
  232. package/dist/ui/color-field.d.ts +48 -0
  233. package/dist/ui/textarea.d.ts +4 -0
  234. package/dist/ui/toggle-chip.d.ts +40 -0
  235. package/dist/{upload-TcAHXv9W.js → upload-CxotJlLv.js} +1 -1
  236. package/dist/{use-card-resolution-DaZqAdWf.js → use-card-resolution-DILUvNyj.js} +1 -1
  237. package/dist/{variant-aurora-DbW_OWL2.js → variant-aurora-BGaXBBGf.js} +1 -1
  238. package/dist/{variant-aurora-BhLuYxJR.js → variant-aurora-BLcQmvkd.js} +1 -1
  239. package/dist/{variant-aurora-CNmfHhcx.js → variant-aurora-DZIfAtx1.js} +2 -2
  240. package/dist/{variant-aurora-D6GsdTPA.js → variant-aurora-DpoIW4ZX.js} +2 -2
  241. package/dist/{variant-custom-BRvaNHSi.js → variant-custom-BhtWdAxE.js} +1 -1
  242. package/dist/{variant-custom-DMTrEO5w.js → variant-custom-BtApuSyr.js} +2 -2
  243. package/dist/{variant-custom-DV2x254s.js → variant-custom-C-zS4ZtE.js} +2 -2
  244. package/dist/{variant-custom-BvYHR62b.js → variant-custom-swi9PXxU.js} +1 -1
  245. package/dist/{variant-wave-sp-qwsdI.js → variant-wave-7JCIwhpb.js} +1 -1
  246. package/dist/{variant-wave-BpDd8t3Z.js → variant-wave-BG4nGr6x.js} +1 -1
  247. package/dist/{variant-wave-BNMGrDfj.js → variant-wave-C32lM9G2.js} +2 -2
  248. package/dist/{variant-wave-CyBueXj9.js → variant-wave-Dl6jOiK3.js} +2 -2
  249. package/dist/x-C4niw05N.js +1 -0
  250. package/frameworks/react/index.tsx +12 -6
  251. package/kit-base.css +311 -0
  252. package/llms-full.txt +9 -6
  253. package/llms.txt +1 -1
  254. package/package.json +23 -4
  255. package/solid.css +48 -0
  256. package/src/elements/element-meta.json +39 -14
  257. package/theme.css +39 -23
  258. package/dist/action-icons-CcgNN2oT.js +0 -1
  259. package/dist/arrow-down-CjRU3JgV.js +0 -1
  260. package/dist/arrow-left-Bnpb1UEW.js +0 -1
  261. package/dist/artifact-Bwt7OgcR.js +0 -1
  262. package/dist/assets/dev-5XzXYR21.js +0 -91
  263. package/dist/button-DkuOnGLy.js +0 -1
  264. package/dist/check-njkVdZu2.js +0 -1
  265. package/dist/chevron-down-B72s6PXR.js +0 -1
  266. package/dist/chevron-right-BatuHzUm.js +0 -1
  267. package/dist/circle-check-B62pODB3.js +0 -1
  268. package/dist/circle-zx0ByzY9.js +0 -1
  269. package/dist/controllable-CnGpMF6r.js +0 -1
  270. package/dist/define-By-uL588.js +0 -1
  271. package/dist/loader-BM4CEz4G.js +0 -1
  272. package/dist/message-BSsgvHvf.js +0 -1
  273. package/dist/message-BYZECyek.js +0 -1
  274. package/dist/message-circle-DruwObfX.js +0 -1
  275. package/dist/message-square-BG6q6mlm.js +0 -1
  276. package/dist/play-BvKKq3fX.js +0 -1
  277. package/dist/register-impl-B1hLkrI8.js +0 -424
  278. package/dist/text-shimmer-Dcj1MHuq.js +0 -1
  279. package/dist/textarea-Dpvbngbg.js +0 -1
  280. package/dist/x-Z5UntkIJ.js +0 -1
@@ -0,0 +1,54 @@
1
+ import { JSX } from 'solid-js';
2
+ export type BuilderViewport = 'desktop' | 'tablet' | 'mobile';
3
+ export interface BuilderLayoutProps {
4
+ /** The construct's display name, shown in the toolbar. */
5
+ name: string;
6
+ /** The inspector panel content — typically `<BuilderPanel>`. */
7
+ panel: JSX.Element;
8
+ /** The preview content — typically a device frame wrapping `<ChatThread>`.
9
+ * Callers that need to reflow their OWN preview at narrower widths (e.g.
10
+ * a docked-rail template collapsing to full-bleed on `mobile`, matching
11
+ * `ui/dock.tsx`'s own <=480px takeover) should read `viewport`/
12
+ * `defaultViewport`/`onViewportChange` below and drive their preview's
13
+ * shape from the same signal they hand this component — see
14
+ * `builder-in-app-assistant.stories.tsx` and `builder.stories.tsx` for
15
+ * the pattern. */
16
+ preview: JSX.Element;
17
+ /** Controlled viewport selection. Omit for uncontrolled (internal) state,
18
+ * same controlled/uncontrolled convention as `Switch`'s
19
+ * `checked`/`defaultChecked` and `ToggleChip`'s `pressed`/
20
+ * `defaultPressed`. A caller that needs to reflow its own `preview` JSX
21
+ * per viewport (see the doc comment on `preview`) should lift this to a
22
+ * signal of its own and pass both this and `onViewportChange`. */
23
+ viewport?: BuilderViewport;
24
+ /** Initial viewport when uncontrolled. Defaults to `'desktop'`. */
25
+ defaultViewport?: BuilderViewport;
26
+ /** Fires with the next viewport on chip selection (controlled or not). */
27
+ onViewportChange?: (viewport: BuilderViewport) => void;
28
+ /** Stub export/save action; the real seam (a file write, per the spike) isn't
29
+ * built here. */
30
+ onSave?: () => void;
31
+ class?: string;
32
+ }
33
+ /**
34
+ * `BuilderLayout` — the two-pane builder shell: a fixed-width scrollable
35
+ * inspector on the left, a live preview on the right over a dotted canvas
36
+ * background (a deliberate "this is a design tool" cue, not a real device
37
+ * emulator). A thin toolbar strip carries the construct name, a viewport
38
+ * toggle, and a stub Export action.
39
+ *
40
+ * The viewport toggle (Round A4 — was a round-1 visual stub) constrains the
41
+ * PREVIEW FRAME's width: `desktop` fills the pane exactly as before (no
42
+ * wrapper, no width style — the historical "stub" behavior for that one
43
+ * case); `tablet`/`mobile` wrap `preview` in a centered frame sized to
44
+ * `FRAME_WIDTH` above (768px / 390px), letting whatever `preview` renders
45
+ * reflow inside it. This is still not a real device emulator — no bezel,
46
+ * no user-agent spoofing, no touch simulation — just a width constraint,
47
+ * consistent with the doc comment this replaced.
48
+ *
49
+ * Pure shell: `panel` and `preview` are handed in as JSX so this component
50
+ * carries no opinion about what fills them; reflowing the CONTENT of
51
+ * `preview` at a given width (rather than just its outer box) is the
52
+ * caller's job — see the `preview` prop's own doc comment.
53
+ */
54
+ export declare function BuilderLayout(props: BuilderLayoutProps): JSX.Element;
@@ -0,0 +1,63 @@
1
+ import { JSX, Component } from 'solid-js';
2
+ import { ChatMessageAction } from '../elements/chat-types.js';
3
+ /**
4
+ * The role-scoped, ordered message-action picker — extracted from
5
+ * `builder-in-app-assistant.stories.tsx` (Round A3) into this standalone
6
+ * module during the T-1 build-out so the Assistant and Research templates
7
+ * (both asked for a "message actions, role-scoped picker, reuse" section)
8
+ * share one definition instead of forking it. `builder-in-app-assistant.
9
+ * stories.tsx` was retrofitted to import from here in the same round; its
10
+ * rendered output and behavior are unchanged — this is a pure extraction.
11
+ *
12
+ * Model: `ChatMessage.actions` (`elements/chat-types.ts`) is `(ChatMessage
13
+ * Action | CustomAction)[]` — an ORDERED array, not a set — and role-scoped
14
+ * only by caller curation (checked against `message.tsx`/`chat-thread.tsx`:
15
+ * neither hard-couples any built-in id to a role). This picker enforces
16
+ * role-appropriateness via two independent catalogs, one per role, each
17
+ * independently ordered and toggled.
18
+ *
19
+ * `'speak'` (read-aloud) is a real `ChatMessageAction` (elements/
20
+ * chat-actions.ts) backed by the kit's own SpeechSynthesis mechanics
21
+ * (primitives/speech.ts, shared with `kai-voice-output`) via the shared
22
+ * action-bar click router (primitives/message-feedback.ts).
23
+ */
24
+ export type UserActionId = Extract<ChatMessageAction, 'edit' | 'copy'>;
25
+ export type AssistantActionId = ChatMessageAction;
26
+ export interface ActionRowDef<TId extends string> {
27
+ id: TId;
28
+ label: string;
29
+ /** A curated icon — same components `ui/action-icons.ts`'s registry maps
30
+ * each built-in id to, so the picker's icons match what the real action
31
+ * bar renders. */
32
+ icon: Component<{
33
+ class?: string;
34
+ }>;
35
+ }
36
+ export interface ActionRowState<TId extends string> {
37
+ id: TId;
38
+ enabled: boolean;
39
+ }
40
+ export declare const USER_ACTION_CATALOG: readonly ActionRowDef<UserActionId>[];
41
+ export declare const ASSISTANT_ACTION_CATALOG: readonly ActionRowDef<AssistantActionId>[];
42
+ /** Owner defaults (Round A3): "Your messages" starts with only Edit on;
43
+ * "Assistant messages" starts with Copy/Like/Dislike on, Regenerate and
44
+ * Speak off. Row ORDER here is also the default enabled-action order. */
45
+ export declare const DEFAULT_USER_ACTION_ROWS: ActionRowState<UserActionId>[];
46
+ export declare const DEFAULT_ASSISTANT_ACTION_ROWS: ActionRowState<AssistantActionId>[];
47
+ /**
48
+ * One role's ordered, toggleable action list — a vertical list of rows
49
+ * (icon + label + up/down reorder buttons + an enable switch). Row ORDER
50
+ * is the array order, and doubles
51
+ * as the enabled-action order once filtered — no separate "priority"
52
+ * field, because the component tier has no separate concept either.
53
+ *
54
+ * Up/down buttons over drag-and-drop: keyboard- and screen-reader-operable
55
+ * for free, which a bare drag handle is not, without extra work a design
56
+ * round doesn't need to do to prove the model (T-6).
57
+ */
58
+ export declare function ActionRowPicker<TId extends string>(props: {
59
+ legend: string;
60
+ catalog: readonly ActionRowDef<TId>[];
61
+ rows: ActionRowState<TId>[];
62
+ onChange: (next: ActionRowState<TId>[]) => void;
63
+ }): JSX.Element;
@@ -0,0 +1,18 @@
1
+ import { JSX } from 'solid-js';
2
+ import { BuildableTemplate } from '../agent-tooling/construct/templates.js';
3
+ import { Construct, ConstructProblem } from '../agent-tooling/construct/schema.js';
4
+ export interface DerivedBuilderPanelProps {
5
+ value: Construct;
6
+ onChange: (next: Construct) => void;
7
+ template: BuildableTemplate;
8
+ problems?: readonly ConstructProblem[];
9
+ class?: string;
10
+ }
11
+ export interface FieldEditorProps {
12
+ path: string;
13
+ value: Construct;
14
+ write: (next: Construct) => void;
15
+ }
16
+ export declare function labelFor(path: string): string;
17
+ export declare const FIELD_OVERRIDES: Record<string, (props: FieldEditorProps) => JSX.Element>;
18
+ export declare function DerivedBuilderPanel(props: DerivedBuilderPanelProps): JSX.Element;
@@ -0,0 +1,240 @@
1
+ import { JSX } from 'solid-js';
2
+ export type BuilderLayoutKind = 'widget' | 'fullscreen' | 'aside' | 'split' | 'custom';
3
+ export type BuilderThemeMode = 'light' | 'dark' | 'system';
4
+ export type BuilderHistoryPersistence = 'none' | 'local' | 'endpoint';
5
+ export interface BuilderHomeLink {
6
+ label: string;
7
+ href?: string;
8
+ description?: string;
9
+ icon?: string;
10
+ }
11
+ export interface BuilderHome {
12
+ greeting?: {
13
+ title?: string;
14
+ subtitle?: string;
15
+ };
16
+ links?: BuilderHomeLink[];
17
+ }
18
+ export interface BuilderCapabilities {
19
+ starters?: string[];
20
+ attachments?: {
21
+ accept?: string[];
22
+ };
23
+ history?: {
24
+ persistence: BuilderHistoryPersistence;
25
+ };
26
+ conversations?: boolean;
27
+ }
28
+ export type BuilderWidgetPosition = 'bottom-end' | 'bottom-start' | 'top-end' | 'top-start';
29
+ /** `layout: 'widget'`-scoped FAB chrome — mirrors `construct.v1`'s own
30
+ * `widget` block. Meaningless on any other layout, which is exactly why
31
+ * the panel section it drives is HIDDEN, not just disabled, on any other
32
+ * layout (see the Layout section's own doc comment for that distinction). */
33
+ export interface BuilderWidget {
34
+ position?: BuilderWidgetPosition;
35
+ launcherIcon?: string;
36
+ defaultOpen?: boolean;
37
+ }
38
+ export type BuilderProviderMode = 'mock' | 'endpoint';
39
+ export type BuilderProviderWire = 'openai' | 'anthropic';
40
+ /** Mirrors `construct.v1`'s own `provider` discriminated union
41
+ * (`agent-tooling/construct/schema.ts`'s `ProviderSchema`) — `mock` needs
42
+ * nothing else; `endpoint` needs the consumer's own chat route + wire
43
+ * format. A DISPLAY/edit stub, not a real one: no dev-server exists for
44
+ * this design round to actually call, so there's nothing to validate the
45
+ * URL against — the field exists so a template's panel shows the whole
46
+ * construct shape, not because this round wires it to anything. */
47
+ export interface BuilderProvider {
48
+ mode: BuilderProviderMode;
49
+ url?: string;
50
+ wire?: BuilderProviderWire;
51
+ }
52
+ /** Mirrors `construct.v1`'s own `cards` entry shape (`schema.ts`'s
53
+ * `cards` array): a tool-facing `name` plus the kit's card-schema JSON.
54
+ * `schema` is `Record<string, unknown>` here too — deep card validation
55
+ * (incl. `x-kai-format` mask hints) is the kit's own card contract at
56
+ * render time, not this stub panel's job; this stub only ever READS
57
+ * `schema.title` for a display label (Round A's read-only Cards section —
58
+ * see `BuilderPanelSections.cards`). */
59
+ export interface BuilderCard {
60
+ name: string;
61
+ schema?: Record<string, unknown>;
62
+ }
63
+ export interface BuilderConstruct {
64
+ name: string;
65
+ layout: BuilderLayoutKind;
66
+ provider?: BuilderProvider;
67
+ header?: {
68
+ title?: string;
69
+ };
70
+ theme?: {
71
+ accent?: string;
72
+ unreadColor?: string;
73
+ mode?: BuilderThemeMode;
74
+ };
75
+ home?: BuilderHome;
76
+ capabilities?: BuilderCapabilities;
77
+ widget?: BuilderWidget;
78
+ cards?: BuilderCard[];
79
+ }
80
+ /**
81
+ * A template-scoped section configuration (Round W, T-2/T-6): a template
82
+ * FIXES its layout internally (no layout radio) and owns which of the
83
+ * layout-scoped sections apply — a widget template shows Widget chrome
84
+ * unconditionally (it IS the widget template, not merely "currently set to
85
+ * widget"), where the old layout-driven panel showed it only when the
86
+ * layout radio happened to be on "Widget". Omit this prop entirely to get
87
+ * the original, generic, layout-driven panel (every existing test above
88
+ * exercises that default) — a template panel opts INTO the narrower set
89
+ * rather than the generic panel opting out.
90
+ */
91
+ export interface BuilderPanelSections {
92
+ /** Show the Layout radio section. Default `true` (the generic panel).
93
+ * A template panel sets this `false` — T-2: the template fixes the
94
+ * layout, so there is nothing left to choose here. */
95
+ layout?: boolean;
96
+ /** The Widget-chrome section's visibility. `'auto'` (default) follows
97
+ * `value.layout === 'widget'`, the original cross-field-visibility
98
+ * behavior. `'always'` shows it unconditionally — what a Support widget
99
+ * template panel wants, since for THAT template the section is never
100
+ * conditional, it's simply always this template's own controls.
101
+ * `'never'` hides it — what every non-widget template wants once each
102
+ * gets its own `Labs/Builder/<Template>` story. */
103
+ widget?: 'auto' | 'always' | 'never';
104
+ /** Show the Provider section (mode + endpoint URL/wire when applicable).
105
+ * Default `false` — the generic panel predates `provider` existing on
106
+ * `BuilderConstruct` at all; a template panel opts in. */
107
+ provider?: boolean;
108
+ /** Show the Home section (greeting/links tab). Default `true` (the
109
+ * generic panel). A template with no Home concept at all — In-app
110
+ * assistant (Round A): widget-only chrome, no Home/Messages tab bar in
111
+ * its own construct basis (`fixtures/ops-console.construct.json` has no
112
+ * `home` key) — sets this `false` to remove the section outright,
113
+ * rather than leaving a switch that would only ever read "off". */
114
+ home?: boolean;
115
+ /** Show a READ-ONLY Cards section: the construct's declared card names
116
+ * (Round A's `cards` addition to `BuilderConstruct`), with a muted note
117
+ * that editing them is a later round. Default `false`. Deliberately not
118
+ * an editor — a template whose construct basis carries `cards` (like
119
+ * `ops-console.construct.json`'s `deployment_parameters` form) still
120
+ * needs the panel to acknowledge them exist rather than silently
121
+ * dropping them from view, without this design round faking a card-
122
+ * schema editor it doesn't have (decide loudly, per CLAUDE.md). */
123
+ cards?: boolean;
124
+ }
125
+ export interface BuilderPanelProps {
126
+ /** The construct being edited. Controlled — the panel never holds its own copy. */
127
+ value: BuilderConstruct;
128
+ /** Fires with the next construct on every edit. */
129
+ onChange: (next: BuilderConstruct) => void;
130
+ /** Which sections render — see `BuilderPanelSections`. Omit for the
131
+ * original generic, layout-driven panel. */
132
+ sections?: BuilderPanelSections;
133
+ class?: string;
134
+ }
135
+ /** One "common case" chip for `capabilities.attachments.accept`: a human label
136
+ * over one or more raw MIME patterns. Owner feedback (design round 2):
137
+ * raw MIME types are hostile to the audience this panel is for, so the
138
+ * common cases get a toggle chip and the raw list is a secondary, visible
139
+ * ("Advanced") affordance rather than the primary input. */
140
+ export interface AcceptChip {
141
+ id: string;
142
+ label: string;
143
+ patterns: readonly string[];
144
+ }
145
+ /**
146
+ * The chip → MIME-pattern map for the attachments accept editor below.
147
+ *
148
+ * Exported (not module-local) because it's exactly the vocabulary a future
149
+ * schema-driven wizard or capability menu (RECOMMENDATION.md's "real build")
150
+ * will also want — one place to widen the common-case list rather than a
151
+ * second one growing beside it.
152
+ */
153
+ export declare const ACCEPT_CHIPS: readonly AcceptChip[];
154
+ export declare function Section(props: {
155
+ title: string;
156
+ children: JSX.Element;
157
+ }): JSX.Element;
158
+ export declare function Field(props: {
159
+ label: string;
160
+ hint?: string;
161
+ children: JSX.Element;
162
+ }): JSX.Element;
163
+ export declare function Row(props: {
164
+ label: string;
165
+ children: JSX.Element;
166
+ muted?: boolean;
167
+ }): JSX.Element;
168
+ /** A minimal, reusable string-tag editor — the taglist pattern the spike
169
+ * proved out (`starters`). `capabilities.attachments.accept` moved to
170
+ * `AcceptTypeEditor` below (owner feedback, design round 2): raw MIME
171
+ * strings are a bad first surface for this audience. */
172
+ export declare function TagEditor(props: {
173
+ tags: string[];
174
+ onChange: (next: string[]) => void;
175
+ ariaLabel: string;
176
+ placeholder?: string;
177
+ }): JSX.Element;
178
+ /**
179
+ * `capabilities.attachments.accept` — chips for the common cases
180
+ * (`ACCEPT_CHIPS`) over a collapsed "Advanced" raw MIME-list editor.
181
+ *
182
+ * A chip lights up (`aria-pressed`) exactly when EVERY one of its patterns is
183
+ * present in `accept` — toggling it adds/removes that whole pattern group.
184
+ *
185
+ * Owner feedback (design round 5): the raw pattern list is no longer shown
186
+ * under the chips at all — it lives ONLY inside the "Advanced" disclosure,
187
+ * as an autosizing textarea (one MIME type/glob per line, not a comma
188
+ * string: each edit adds or removes a LINE rather than reflowing a long
189
+ * wrapped string, and a list copied from a spec or another tool's `accept`
190
+ * field is naturally one-per-line already; a pasted comma list still parses
191
+ * fine, `commitDraft` splits on either). A hand-added entry lives only
192
+ * there; no chip claims it.
193
+ */
194
+ export declare function AcceptTypeEditor(props: {
195
+ accept: string[];
196
+ onChange: (next: string[]) => void;
197
+ }): JSX.Element;
198
+ /** `home.links` — the array-of-objects hard case (RECOMMENDATION.md), as a
199
+ * small labeled-row repeater. Each row explicitly numbered ("Link N") so a
200
+ * scanning eye always knows which entry it's looking at. */
201
+ export declare function LinksEditor(props: {
202
+ links: BuilderHomeLink[];
203
+ onChange: (next: BuilderHomeLink[]) => void;
204
+ }): JSX.Element;
205
+ /**
206
+ * `BuilderPanel` — the visual construct builder's inspector: identity, layout,
207
+ * theme, an optional Home tab, and capabilities. Pure props/callbacks, stub-
208
+ * friendly (no dev-server seam, no schema derivation) — a STORY-FIRST design
209
+ * surface for the panel's look, per RECOMMENDATION.md. Composed entirely from
210
+ * the kit's own controls (`Input`/`Textarea`/`Switch`/`RadioGroup`/`Select`/
211
+ * `Button`/`ColorField`/`ToggleChip`); no `part=` attributes — this component is not
212
+ * yet wired to a `kai-*` facade.
213
+ *
214
+ * Round W (T-2/T-6) added `sections` (`BuilderPanelSections`): omit it for
215
+ * the original generic, layout-driven panel this doc comment otherwise
216
+ * describes unchanged; pass it to scope the panel to ONE template's control
217
+ * set — no Layout radio, Widget chrome shown unconditionally rather than
218
+ * `layout`-conditionally, a Provider section — the shape `Labs/Builder/
219
+ * Support widget` (`src/elements/builder.stories.tsx`) actually uses.
220
+ *
221
+ * Three patterns from the spike (plus the owner's own round-8 ruling) get
222
+ * real design treatment here rather than being hand-waved:
223
+ * - **presence-as-boolean**: `home` and `capabilities.attachments` are each
224
+ * driven by ONE switch that adds/removes the whole sub-object, with its
225
+ * revealed fields directly below (no second "enabled" flag living beside
226
+ * the object it toggles).
227
+ * - **cross-field visibility, field-level**: `capabilities.conversations`
228
+ * requires `capabilities.history.persistence` to be `local`/`endpoint`
229
+ * (the schema's own `superRefine` rule) — shown as a disabled switch with
230
+ * the reason spelled out in muted text right below it, not a validation
231
+ * error surfaced after the fact.
232
+ * - **cross-field visibility, section-level**: the whole "Widget" section
233
+ * (position/launcher icon/open-by-default) is meaningless outside
234
+ * `layout: 'widget'`, and unlike the single Conversations toggle above, a
235
+ * disabled-and-explained SECTION would just be three greyed-out rows for
236
+ * one sentence's worth of reason — so it's hidden entirely, not disabled,
237
+ * whenever `layout` isn't `'widget'` (owner ruling, design round 8; see
238
+ * that section's own comment for the full distinction).
239
+ */
240
+ export declare function BuilderPanel(props: BuilderPanelProps): JSX.Element;
@@ -0,0 +1,11 @@
1
+ import { BuilderConstruct } from './builder-panel.js';
2
+ /**
3
+ * The inline style object a stub preview's wrapper needs so a construct's
4
+ * `theme.accent` actually retints its descendants: both the public
5
+ * (`--kai-color-primary`) and internal (`--color-primary`) tokens, plus
6
+ * their paired foreground when the accent resolves to concrete RGB — see
7
+ * the module doc comment above for why both are required. Returns `{}` for
8
+ * no accent (the kit's own neutral default applies, same as omitting the
9
+ * property entirely).
10
+ */
11
+ export declare function resolveAccentWrapperStyle(theme: BuilderConstruct['theme']): Record<string, string>;
@@ -0,0 +1,69 @@
1
+ import { JSX } from 'solid-js';
2
+ /**
3
+ * "App chrome" — the Command palette and User menu shell knobs (owner
4
+ * discovery round), factored as a shared module so every shell-bearing
5
+ * template (`Labs/Builder/Assistant`, `.../Workspace`, `.../Multi-mode`)
6
+ * reuses the same real pieces instead of forking a fourth copy —
7
+ * consistent with `builder-composer-triggers.tsx`'s own rule-of-three
8
+ * extraction earlier this round.
9
+ *
10
+ * COMMAND PALETTE: composes the kit's real `CommandList` (`ui/command.tsx`)
11
+ * — a presentational grouped listbox — inside a hand-built overlay
12
+ * (backdrop + centered panel + Escape/backdrop-click to close), the SAME
13
+ * shape `elements/claude-code.stories.tsx`'s own command-center overlay
14
+ * uses around `kai-command` (read before building this — `CommandList` is
15
+ * that facade's underlying Solid piece; the facade adds the search input's
16
+ * filtering behavior itself, which `CommandList` does not own). A plain
17
+ * `Input` above the list does the filtering here, client-side over a stub
18
+ * catalog, matching claude-code's own placeholder copy style ("Search
19
+ * commands...").
20
+ *
21
+ * USER MENU: `elements/user-menu.stories.tsx`'s own doc comment states it
22
+ * plainly — "the user menu is a RECIPE, not an element... kai-menu with a
23
+ * slotted trigger (kai-avatar + name + plan + a chevron + a kai-status
24
+ * dot)". Reused here as the Solid-tier equivalent: `Dropdown`/
25
+ * `DropdownTrigger`/`DropdownContent`/`DropdownItem` (the same primitives
26
+ * `components/model-switcher.tsx` and the Workspace composer menu already
27
+ * compose) with an `Avatar` + name/plan trigger.
28
+ */
29
+ export interface ShellControlsState {
30
+ commandPalette: boolean;
31
+ userMenu: boolean;
32
+ }
33
+ /** The command palette overlay — mounted only while `open`. Filters the
34
+ * stub catalog client-side; selecting a row or pressing Escape closes it. */
35
+ export declare function CommandPaletteOverlay(props: {
36
+ open: boolean;
37
+ onClose: () => void;
38
+ }): JSX.Element;
39
+ /** The command palette's TRIGGER — a plain search-icon button, matching
40
+ * claude-code's own rail-header search affordance. Rendering the overlay
41
+ * itself is the caller's job (`CommandPaletteOverlay`), so a template can
42
+ * place the trigger inside its own rail/header chrome while the overlay
43
+ * mounts at the frame root. */
44
+ export declare function CommandPaletteTrigger(props: {
45
+ onOpen: () => void;
46
+ }): JSX.Element;
47
+ /** The user-menu recipe itself — avatar + name/plan trigger, real Dropdown
48
+ * primitives, a stub items list (Settings/Help/Log out). `compact` (owner
49
+ * feedback round, Workspace's app-header rework) drops the name/plan text
50
+ * entirely, rendering avatar + chevron only — for a header utility cluster
51
+ * where the full name/plan reads as too much next to icon-only siblings.
52
+ * `name`/`plan` still feed the avatar initials and the accessible name
53
+ * (`aria-label`) even when compact, so the control never loses its name to
54
+ * assistive tech just because the text is hidden visually. */
55
+ export declare function UserMenu(props: {
56
+ name: string;
57
+ plan?: string;
58
+ class?: string;
59
+ compact?: boolean;
60
+ }): JSX.Element;
61
+ /** The panel section every shell-bearing template reuses: two toggles,
62
+ * "Command palette" and "User menu." Preview-only — see each template's
63
+ * own module doc comment for how the toggles wire into ITS OWN chrome
64
+ * (the trigger/overlay/menu placement differs per template's real
65
+ * anatomy, so this section only owns the on/off state, not the layout). */
66
+ export declare function ShellSection(props: {
67
+ state: ShellControlsState;
68
+ onChange: (v: ShellControlsState) => void;
69
+ }): JSX.Element;
@@ -0,0 +1,58 @@
1
+ import { JSX } from 'solid-js';
2
+ /**
3
+ * Shared wordless-skeleton language for `Labs/Builder/<Template>` preview
4
+ * hosts (docs/superpowers/specs/2026-08-28-template-builder-design.md).
5
+ *
6
+ * Extracted from `builder-in-app-assistant.stories.tsx` (Round A2) into this
7
+ * standalone module during the T-1 build-out (Assistant/Research/Workspace/
8
+ * Voice) so every template's "the rest of your app" skeleton chrome shares
9
+ * one definition instead of four copies drifting apart — the cross-cutting
10
+ * mandate the design spec's Process step names ("as shared needs emerge,
11
+ * refactor the shared components ONCE"). `builder-in-app-assistant.stories.tsx`
12
+ * was retrofitted to import from here in the same round; nothing about its
13
+ * rendered output changed.
14
+ *
15
+ * PLAIN inline CSS (`color-mix`), not a Tailwind opacity-modifier class
16
+ * on a color utility or an arbitrary-bracket width value — see the
17
+ * original Round A2 note in git blame: this Storybook dev server's
18
+ * Tailwind JIT pass proved non-deterministic for FRESH combinations
19
+ * introduced by a single file (a class would show correctly in the rendered
20
+ * `className` while `getComputedStyle` reported the rule simply wasn't
21
+ * compiled). `color-mix()` is real CSS with no compile step to race, and
22
+ * matches what Tailwind's own `/NN` opacity modifier generates.
23
+ */
24
+ export declare function mix(colorVar: string, pct: number): string;
25
+ /** One skeleton bar/pill. `widthClass` for a standard-scale Tailwind width
26
+ * utility (proven reliable); `width` for an inline CSS width (a
27
+ * percentage, or anything arbitrary); `flex` to grow and fill instead of
28
+ * taking either. Height is always a standard-scale utility unless
29
+ * overridden. */
30
+ export declare function SkeletonBar(props: {
31
+ widthClass?: string;
32
+ width?: string;
33
+ heightClass?: string;
34
+ pct: number;
35
+ flex?: boolean;
36
+ }): JSX.Element;
37
+ /** A grayscale/muted skeleton stat tile: a label bar over a bigger number
38
+ * bar. Deliberately toneless (muted-foreground tints only, never
39
+ * `bg-primary`/accent) so the host reads as chrome around the product
40
+ * rather than product itself. */
41
+ export declare function StubStatTile(props: {
42
+ class?: string;
43
+ }): JSX.Element;
44
+ /** A single stub nav-rail row: an icon-ish dot plus a label bar. `active`
45
+ * lights the row the way a real nav's current-page item would. */
46
+ export declare function StubNavRow(props: {
47
+ active?: boolean;
48
+ }): JSX.Element;
49
+ /** A single stub table row: a handful of column bars at staggered widths,
50
+ * so the row reads as data rather than one flat block. */
51
+ export declare function StubTableRow(): JSX.Element;
52
+ /** A wordless skeleton code/text block: a stack of bars at staggered
53
+ * widths, monospace rhythm (shorter, denser bars) rather than prose
54
+ * rhythm — for the Workspace template's artifact/code pane. */
55
+ export declare function StubCodeBlock(props: {
56
+ lines?: number;
57
+ class?: string;
58
+ }): JSX.Element;
@@ -0,0 +1,79 @@
1
+ import { JSX } from 'solid-js';
2
+ import { TemplateId } from '../agent-tooling/construct/templates.js';
3
+ export type BuilderTemplateId = TemplateId | 'scratch';
4
+ /** The template ids that DO have a card — every registry id. */
5
+ export type BuilderCardTemplateId = TemplateId;
6
+ export interface BuilderTemplate {
7
+ id: BuilderCardTemplateId;
8
+ name: string;
9
+ description: string;
10
+ }
11
+ /** All six cards, DERIVED from the template registry (B-17b) — id, name and
12
+ * one-liner are the registry's own; this module adds only the
13
+ * illustrations, which stay component-side keyed by id (SVGs are not
14
+ * registry data). The Labs story renders all six (T-1a); a real product
15
+ * surface renders BUILDABLE_BUILDER_TEMPLATES instead (menu-honesty). */
16
+ export declare const BUILDER_TEMPLATES: readonly BuilderTemplate[];
17
+ export declare const BUILDABLE_BUILDER_TEMPLATES: readonly BuilderTemplate[];
18
+ export interface BuilderStartProps {
19
+ /** The currently selected template id, or unset for none yet. Controlled —
20
+ * this component holds no selection state of its own. */
21
+ value?: BuilderTemplateId;
22
+ /**
23
+ * Fires with a template's id when its card is chosen. Click-to-advance
24
+ * (design choice, this round): T-7 says "selection advances to that
25
+ * template's builder", and there is nothing a second "Continue" step
26
+ * would add here that the click itself doesn't already mean — a
27
+ * disambiguating confirm step belongs to T-2's SWITCHING-template case
28
+ * (control set changes, so a re-pick needs a confirm), not to picking a
29
+ * template for the first time. So `onSelect` fires on the same click that
30
+ * shows the selected ring; the story's Continue readout below just proves
31
+ * the callback fired, since there's no template builder screen yet to
32
+ * navigate to.
33
+ */
34
+ onSelect: (id: BuilderTemplateId) => void;
35
+ /** Which cards to render. Defaults to BUILDABLE_BUILDER_TEMPLATES
36
+ * (menu-honest by default). The Labs story passes BUILDER_TEMPLATES (all
37
+ * six) explicitly to show the full catalog. */
38
+ templates?: readonly BuilderTemplate[];
39
+ class?: string;
40
+ }
41
+ export declare const BLUEPRINT_BG: {
42
+ readonly 'background-image': "radial-gradient(circle, var(--color-border) 1px, transparent 1px)";
43
+ readonly 'background-size': "14px 14px";
44
+ };
45
+ /**
46
+ * `BuilderStart` — the builder's opening screen: six selectable template
47
+ * cards (T-7, grown from four in Round P2). Each card is a real
48
+ * `ui/card.tsx` `Card` (`clickable`,
49
+ * `media` for the illustration, `header` for the name), not a hand-rolled
50
+ * button — the kit's own primitive already gives a `role="button"` with
51
+ * Enter/Space activation, which settles this screen's keyboard-semantics
52
+ * question: a `radiogroup` was the other defensible reading (this IS a
53
+ * single choice among six), but `Card` already implements exactly the
54
+ * button-per-card pattern with no extra wiring, and reusing it beats
55
+ * building a second selection primitive for one screen.
56
+ *
57
+ * Brand alignment (T-7): the kit's own tokens throughout — no new color, no
58
+ * new radius, no new type stack. The illustrations are the one genuinely new
59
+ * visual element this round adds; see `TEMPLATE_ILLUSTRATIONS` below for
60
+ * their shared style rules.
61
+ */
62
+ export declare function BuilderStart(props: BuilderStartProps): JSX.Element;
63
+ export declare const STROKE = 1.5;
64
+ export declare const LINE: {
65
+ stroke: string;
66
+ fill: string;
67
+ };
68
+ export declare const BORDER: {
69
+ stroke: string;
70
+ fill: string;
71
+ };
72
+ export declare const ACCENT: {
73
+ stroke: string;
74
+ fill: string;
75
+ };
76
+ export declare const ACCENT_FILL: {
77
+ stroke: string;
78
+ fill: string;
79
+ };
@@ -0,0 +1,23 @@
1
+ import { JSX } from 'solid-js';
2
+ export type WorkspaceVariantId = 'artifactPreview' | 'appPreview';
3
+ export interface WorkspaceVariant {
4
+ id: WorkspaceVariantId;
5
+ name: string;
6
+ description: string;
7
+ }
8
+ export declare const WORKSPACE_VARIANTS: readonly WorkspaceVariant[];
9
+ export interface WorkspaceVariantPickerProps {
10
+ value?: WorkspaceVariantId;
11
+ onSelect: (id: WorkspaceVariantId) => void;
12
+ onBack: () => void;
13
+ class?: string;
14
+ }
15
+ /**
16
+ * `WorkspaceVariantPicker` — the Workspace family's second screen: two
17
+ * function-named variant cards (smaller-scale `Card`s, reusing `Builder
18
+ * Start`'s own pattern) plus a back affordance to the template picker.
19
+ * Selection fires `onSelect` with the variant id the same click-to-advance
20
+ * shape `BuilderStart` itself uses (T-7's own reasoning: nothing a second
21
+ * "Continue" step would add here that the click doesn't already mean).
22
+ */
23
+ export declare function WorkspaceVariantPicker(props: WorkspaceVariantPickerProps): JSX.Element;