@copilotkit/shared 2.0.0-rc.30 → 2.0.0-rc.32

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 (231) hide show
  1. package/README.md +1 -1
  2. package/dist/generative-ui/catalog/catalog-export.cjs +329 -0
  3. package/dist/generative-ui/catalog/catalog-export.cjs.map +1 -0
  4. package/dist/generative-ui/catalog/catalog-export.d.cts +92 -0
  5. package/dist/generative-ui/catalog/catalog-export.d.cts.map +1 -0
  6. package/dist/generative-ui/catalog/catalog-export.d.mts +92 -0
  7. package/dist/generative-ui/catalog/catalog-export.d.mts.map +1 -0
  8. package/dist/generative-ui/catalog/catalog-export.mjs +328 -0
  9. package/dist/generative-ui/catalog/catalog-export.mjs.map +1 -0
  10. package/dist/generative-ui/catalog/catalog.cjs +315 -0
  11. package/dist/generative-ui/catalog/catalog.cjs.map +1 -0
  12. package/dist/generative-ui/catalog/catalog.d.cts +407 -0
  13. package/dist/generative-ui/catalog/catalog.d.cts.map +1 -0
  14. package/dist/generative-ui/catalog/catalog.d.mts +407 -0
  15. package/dist/generative-ui/catalog/catalog.d.mts.map +1 -0
  16. package/dist/generative-ui/catalog/catalog.mjs +312 -0
  17. package/dist/generative-ui/catalog/catalog.mjs.map +1 -0
  18. package/dist/generative-ui/catalog/errors.cjs +13 -0
  19. package/dist/generative-ui/catalog/errors.cjs.map +1 -0
  20. package/dist/generative-ui/catalog/errors.d.cts +46 -0
  21. package/dist/generative-ui/catalog/errors.d.cts.map +1 -0
  22. package/dist/generative-ui/catalog/errors.d.mts +46 -0
  23. package/dist/generative-ui/catalog/errors.d.mts.map +1 -0
  24. package/dist/generative-ui/catalog/errors.mjs +12 -0
  25. package/dist/generative-ui/catalog/errors.mjs.map +1 -0
  26. package/dist/generative-ui/catalog/index.d.mts +6 -0
  27. package/dist/generative-ui/catalog/json-schema.cjs +16 -0
  28. package/dist/generative-ui/catalog/json-schema.cjs.map +1 -0
  29. package/dist/generative-ui/catalog/json-schema.d.cts +12 -0
  30. package/dist/generative-ui/catalog/json-schema.d.cts.map +1 -0
  31. package/dist/generative-ui/catalog/json-schema.d.mts +12 -0
  32. package/dist/generative-ui/catalog/json-schema.d.mts.map +1 -0
  33. package/dist/generative-ui/catalog/json-schema.mjs +16 -0
  34. package/dist/generative-ui/catalog/json-schema.mjs.map +1 -0
  35. package/dist/generative-ui/catalog/refs.cjs +21 -0
  36. package/dist/generative-ui/catalog/refs.cjs.map +1 -0
  37. package/dist/generative-ui/catalog/refs.d.cts +55 -0
  38. package/dist/generative-ui/catalog/refs.d.cts.map +1 -0
  39. package/dist/generative-ui/catalog/refs.d.mts +55 -0
  40. package/dist/generative-ui/catalog/refs.d.mts.map +1 -0
  41. package/dist/generative-ui/catalog/refs.mjs +18 -0
  42. package/dist/generative-ui/catalog/refs.mjs.map +1 -0
  43. package/dist/generative-ui/catalog/schema.cjs +74 -0
  44. package/dist/generative-ui/catalog/schema.cjs.map +1 -0
  45. package/dist/generative-ui/catalog/schema.d.cts +43 -0
  46. package/dist/generative-ui/catalog/schema.d.cts.map +1 -0
  47. package/dist/generative-ui/catalog/schema.d.mts +43 -0
  48. package/dist/generative-ui/catalog/schema.d.mts.map +1 -0
  49. package/dist/generative-ui/catalog/schema.mjs +68 -0
  50. package/dist/generative-ui/catalog/schema.mjs.map +1 -0
  51. package/dist/generative-ui/index.cjs +247 -0
  52. package/dist/generative-ui/index.d.cts +33 -0
  53. package/dist/generative-ui/index.d.mts +35 -0
  54. package/dist/generative-ui/index.mjs +34 -0
  55. package/dist/generative-ui/is-record.cjs +6 -1
  56. package/dist/generative-ui/is-record.cjs.map +1 -1
  57. package/dist/generative-ui/is-record.d.cts +6 -0
  58. package/dist/generative-ui/is-record.d.cts.map +1 -0
  59. package/dist/generative-ui/is-record.d.mts +6 -0
  60. package/dist/generative-ui/is-record.d.mts.map +1 -0
  61. package/dist/generative-ui/is-record.mjs +6 -2
  62. package/dist/generative-ui/is-record.mjs.map +1 -1
  63. package/dist/generative-ui/standard/chart.cjs +56 -0
  64. package/dist/generative-ui/standard/chart.cjs.map +1 -0
  65. package/dist/generative-ui/standard/chart.d.cts +62 -0
  66. package/dist/generative-ui/standard/chart.d.cts.map +1 -0
  67. package/dist/generative-ui/standard/chart.d.mts +62 -0
  68. package/dist/generative-ui/standard/chart.d.mts.map +1 -0
  69. package/dist/generative-ui/standard/chart.mjs +54 -0
  70. package/dist/generative-ui/standard/chart.mjs.map +1 -0
  71. package/dist/generative-ui/standard/checks.cjs +74 -0
  72. package/dist/generative-ui/standard/checks.cjs.map +1 -0
  73. package/dist/generative-ui/standard/checks.d.cts +56 -0
  74. package/dist/generative-ui/standard/checks.d.cts.map +1 -0
  75. package/dist/generative-ui/standard/checks.d.mts +56 -0
  76. package/dist/generative-ui/standard/checks.d.mts.map +1 -0
  77. package/dist/generative-ui/standard/checks.mjs +71 -0
  78. package/dist/generative-ui/standard/checks.mjs.map +1 -0
  79. package/dist/generative-ui/standard/components.cjs +23 -0
  80. package/dist/generative-ui/standard/components.cjs.map +1 -0
  81. package/dist/generative-ui/standard/components.d.cts +24 -0
  82. package/dist/generative-ui/standard/components.d.cts.map +1 -0
  83. package/dist/generative-ui/standard/components.d.mts +24 -0
  84. package/dist/generative-ui/standard/components.d.mts.map +1 -0
  85. package/dist/generative-ui/standard/components.mjs +22 -0
  86. package/dist/generative-ui/standard/components.mjs.map +1 -0
  87. package/dist/generative-ui/standard/composites.cjs +143 -0
  88. package/dist/generative-ui/standard/composites.cjs.map +1 -0
  89. package/dist/generative-ui/standard/composites.d.cts +233 -0
  90. package/dist/generative-ui/standard/composites.d.cts.map +1 -0
  91. package/dist/generative-ui/standard/composites.d.mts +233 -0
  92. package/dist/generative-ui/standard/composites.d.mts.map +1 -0
  93. package/dist/generative-ui/standard/composites.mjs +132 -0
  94. package/dist/generative-ui/standard/composites.mjs.map +1 -0
  95. package/dist/generative-ui/standard/data.cjs +176 -0
  96. package/dist/generative-ui/standard/data.cjs.map +1 -0
  97. package/dist/generative-ui/standard/data.d.cts +365 -0
  98. package/dist/generative-ui/standard/data.d.cts.map +1 -0
  99. package/dist/generative-ui/standard/data.d.mts +365 -0
  100. package/dist/generative-ui/standard/data.d.mts.map +1 -0
  101. package/dist/generative-ui/standard/data.mjs +167 -0
  102. package/dist/generative-ui/standard/data.mjs.map +1 -0
  103. package/dist/generative-ui/standard/declarations.cjs +40 -0
  104. package/dist/generative-ui/standard/declarations.cjs.map +1 -0
  105. package/dist/generative-ui/standard/declarations.d.cts +2570 -0
  106. package/dist/generative-ui/standard/declarations.d.cts.map +1 -0
  107. package/dist/generative-ui/standard/declarations.d.mts +2571 -0
  108. package/dist/generative-ui/standard/declarations.d.mts.map +1 -0
  109. package/dist/generative-ui/standard/declarations.mjs +39 -0
  110. package/dist/generative-ui/standard/declarations.mjs.map +1 -0
  111. package/dist/generative-ui/standard/feedback.cjs +97 -0
  112. package/dist/generative-ui/standard/feedback.cjs.map +1 -0
  113. package/dist/generative-ui/standard/feedback.d.cts +133 -0
  114. package/dist/generative-ui/standard/feedback.d.cts.map +1 -0
  115. package/dist/generative-ui/standard/feedback.d.mts +133 -0
  116. package/dist/generative-ui/standard/feedback.d.mts.map +1 -0
  117. package/dist/generative-ui/standard/feedback.mjs +90 -0
  118. package/dist/generative-ui/standard/feedback.mjs.map +1 -0
  119. package/dist/generative-ui/standard/index.d.mts +16 -0
  120. package/dist/generative-ui/standard/inputs.cjs +333 -0
  121. package/dist/generative-ui/standard/inputs.cjs.map +1 -0
  122. package/dist/generative-ui/standard/inputs.d.cts +1128 -0
  123. package/dist/generative-ui/standard/inputs.d.cts.map +1 -0
  124. package/dist/generative-ui/standard/inputs.d.mts +1128 -0
  125. package/dist/generative-ui/standard/inputs.d.mts.map +1 -0
  126. package/dist/generative-ui/standard/inputs.mjs +318 -0
  127. package/dist/generative-ui/standard/inputs.mjs.map +1 -0
  128. package/dist/generative-ui/standard/layout.cjs +289 -0
  129. package/dist/generative-ui/standard/layout.cjs.map +1 -0
  130. package/dist/generative-ui/standard/layout.d.cts +1974 -0
  131. package/dist/generative-ui/standard/layout.d.cts.map +1 -0
  132. package/dist/generative-ui/standard/layout.d.mts +1975 -0
  133. package/dist/generative-ui/standard/layout.d.mts.map +1 -0
  134. package/dist/generative-ui/standard/layout.mjs +269 -0
  135. package/dist/generative-ui/standard/layout.mjs.map +1 -0
  136. package/dist/generative-ui/standard/map.cjs +27 -0
  137. package/dist/generative-ui/standard/map.cjs.map +1 -0
  138. package/dist/generative-ui/standard/map.d.cts +31 -0
  139. package/dist/generative-ui/standard/map.d.cts.map +1 -0
  140. package/dist/generative-ui/standard/map.d.mts +31 -0
  141. package/dist/generative-ui/standard/map.d.mts.map +1 -0
  142. package/dist/generative-ui/standard/map.mjs +25 -0
  143. package/dist/generative-ui/standard/map.mjs.map +1 -0
  144. package/dist/generative-ui/standard/media.cjs +215 -0
  145. package/dist/generative-ui/standard/media.cjs.map +1 -0
  146. package/dist/generative-ui/standard/media.d.cts +396 -0
  147. package/dist/generative-ui/standard/media.d.cts.map +1 -0
  148. package/dist/generative-ui/standard/media.d.mts +396 -0
  149. package/dist/generative-ui/standard/media.d.mts.map +1 -0
  150. package/dist/generative-ui/standard/media.mjs +205 -0
  151. package/dist/generative-ui/standard/media.mjs.map +1 -0
  152. package/dist/generative-ui/standard/parameter-order.cjs +231 -0
  153. package/dist/generative-ui/standard/parameter-order.cjs.map +1 -0
  154. package/dist/generative-ui/standard/parameter-order.d.cts +84 -0
  155. package/dist/generative-ui/standard/parameter-order.d.cts.map +1 -0
  156. package/dist/generative-ui/standard/parameter-order.d.mts +84 -0
  157. package/dist/generative-ui/standard/parameter-order.d.mts.map +1 -0
  158. package/dist/generative-ui/standard/parameter-order.mjs +230 -0
  159. package/dist/generative-ui/standard/parameter-order.mjs.map +1 -0
  160. package/dist/generative-ui/standard/styles.cjs +62 -0
  161. package/dist/generative-ui/standard/styles.cjs.map +1 -0
  162. package/dist/generative-ui/standard/styles.d.cts +17 -0
  163. package/dist/generative-ui/standard/styles.d.cts.map +1 -0
  164. package/dist/generative-ui/standard/styles.d.mts +17 -0
  165. package/dist/generative-ui/standard/styles.d.mts.map +1 -0
  166. package/dist/generative-ui/standard/styles.mjs +60 -0
  167. package/dist/generative-ui/standard/styles.mjs.map +1 -0
  168. package/dist/generative-ui/standard/text.cjs +226 -0
  169. package/dist/generative-ui/standard/text.cjs.map +1 -0
  170. package/dist/generative-ui/standard/text.d.cts +522 -0
  171. package/dist/generative-ui/standard/text.d.cts.map +1 -0
  172. package/dist/generative-ui/standard/text.d.mts +522 -0
  173. package/dist/generative-ui/standard/text.d.mts.map +1 -0
  174. package/dist/generative-ui/standard/text.mjs +209 -0
  175. package/dist/generative-ui/standard/text.mjs.map +1 -0
  176. package/dist/generative-ui/standard/theme.cjs +115 -0
  177. package/dist/generative-ui/standard/theme.cjs.map +1 -0
  178. package/dist/generative-ui/standard/theme.d.cts +60 -0
  179. package/dist/generative-ui/standard/theme.d.cts.map +1 -0
  180. package/dist/generative-ui/standard/theme.d.mts +60 -0
  181. package/dist/generative-ui/standard/theme.d.mts.map +1 -0
  182. package/dist/generative-ui/standard/theme.mjs +112 -0
  183. package/dist/generative-ui/standard/theme.mjs.map +1 -0
  184. package/dist/generative-ui/standard/tokens.cjs +336 -0
  185. package/dist/generative-ui/standard/tokens.cjs.map +1 -0
  186. package/dist/generative-ui/standard/tokens.d.cts +76 -0
  187. package/dist/generative-ui/standard/tokens.d.cts.map +1 -0
  188. package/dist/generative-ui/standard/tokens.d.mts +76 -0
  189. package/dist/generative-ui/standard/tokens.d.mts.map +1 -0
  190. package/dist/generative-ui/standard/tokens.mjs +305 -0
  191. package/dist/generative-ui/standard/tokens.mjs.map +1 -0
  192. package/dist/index.cjs.map +1 -1
  193. package/dist/index.d.cts +10 -10
  194. package/dist/index.d.mts +10 -10
  195. package/dist/index.mjs.map +1 -1
  196. package/dist/index.umd.js +2 -2
  197. package/dist/index.umd.js.map +1 -1
  198. package/dist/package.cjs +1 -1
  199. package/dist/package.mjs +1 -1
  200. package/package.json +7 -3
  201. package/src/generative-ui/base.ts +9 -0
  202. package/src/generative-ui/catalog/catalog-export.ts +478 -0
  203. package/src/generative-ui/catalog/catalog.ts +1167 -0
  204. package/src/generative-ui/catalog/errors.ts +102 -0
  205. package/src/generative-ui/catalog/index.ts +6 -0
  206. package/src/generative-ui/catalog/json-schema.ts +14 -0
  207. package/src/generative-ui/catalog/refs.ts +87 -0
  208. package/src/generative-ui/catalog/schema.ts +107 -0
  209. package/src/generative-ui/index.ts +7 -0
  210. package/src/generative-ui/is-record.ts +6 -1
  211. package/src/generative-ui/standard/__tests__/theme.test.ts +61 -0
  212. package/src/generative-ui/standard/__tests__/tokens.test.ts +139 -0
  213. package/src/generative-ui/standard/chart.ts +79 -0
  214. package/src/generative-ui/standard/checks.ts +98 -0
  215. package/src/generative-ui/standard/components.ts +35 -0
  216. package/src/generative-ui/standard/composites.ts +158 -0
  217. package/src/generative-ui/standard/data.ts +213 -0
  218. package/src/generative-ui/standard/declarations.ts +57 -0
  219. package/src/generative-ui/standard/feedback.ts +105 -0
  220. package/src/generative-ui/standard/index.ts +19 -0
  221. package/src/generative-ui/standard/inputs.ts +423 -0
  222. package/src/generative-ui/standard/layout.ts +312 -0
  223. package/src/generative-ui/standard/map.ts +32 -0
  224. package/src/generative-ui/standard/media.ts +265 -0
  225. package/src/generative-ui/standard/parameter-order.ts +155 -0
  226. package/src/generative-ui/standard/styles.ts +79 -0
  227. package/src/generative-ui/standard/text.ts +210 -0
  228. package/src/generative-ui/standard/theme.ts +198 -0
  229. package/src/generative-ui/standard/tokens.ts +317 -0
  230. package/src/index.ts +1 -1
  231. package/tsdown.config.ts +1 -1
@@ -0,0 +1,62 @@
1
+ const require_tokens = require('./tokens.cjs');
2
+ const require_theme = require('./theme.cjs');
3
+
4
+ //#region src/generative-ui/standard/styles.ts
5
+ /**
6
+ * The stylesheet for what inline styles cannot do: pseudo-elements (slider
7
+ * track and thumb, placeholder), `:checked` and `:first-child` states,
8
+ * heading fallbacks, and resets for host prose styles. It is added once per
9
+ * document.
10
+ *
11
+ * Typography is inherited: a surface takes the font, size, line height and
12
+ * color of the text around it (the chat prose). Headings take the heading
13
+ * styles of the host.
14
+ */
15
+ const STANDARD_STYLE_ID = "a2ui-standard-catalog";
16
+ const ACCENT = "var(--a2ui-color-accent, #0d0d0d)";
17
+ const FOCUS_RING = "2px solid var(--a2ui-color-focus, #0285ff)";
18
+ const CHECK_SVG = "url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E\")";
19
+ const SLIDER_TRACK = "var(--a2ui-color-slider-track, rgba(0, 0, 0, 0.04))";
20
+ const THUMB = `width:20px;height:20px;box-sizing:border-box;border-radius:9999px;background:${require_tokens.CONTROL_BG};border:1px solid ${require_tokens.borderColor("default")};box-shadow:${require_tokens.SHADOW_XS};cursor:pointer`;
21
+ const STANDARD_CSS = [
22
+ require_theme.DARK_THEME_CSS,
23
+ ".a2ui-surface{min-width:0;max-width:100%;box-sizing:border-box}",
24
+ ".a2ui-surface{font:inherit;color:inherit}",
25
+ ":where(.a2ui-surface) :where(h2){font-size:1.5em;font-weight:600;line-height:1.3}",
26
+ ":where(.a2ui-surface) :where(h3){font-size:1.25em;font-weight:600;line-height:1.3}",
27
+ ":where(.a2ui-surface) :where(h4){font-size:1em;font-weight:600;line-height:1.4}",
28
+ "[data-a2ui-std] :is(button,input,select,textarea),[data-a2ui-input]{font:inherit;color:inherit}",
29
+ "[data-a2ui-row=\"spaceBetween\"]>[data-a2ui-text]:last-child:not(:first-child){text-align:right;margin-inline-start:auto}",
30
+ `[data-a2ui-input]:focus-visible{outline:${FOCUS_RING};outline-offset:1px}`,
31
+ `[data-a2ui-scroll]:focus-visible{outline:${FOCUS_RING};outline-offset:2px}`,
32
+ `[data-a2ui-input]::placeholder{color:${require_tokens.textColor("tertiary")};opacity:1}`,
33
+ `.a2ui-std-range{-webkit-appearance:none;appearance:none;display:block;width:100%;height:24px;margin:0;padding:0 2px;box-sizing:border-box;border-radius:9999px;background:${SLIDER_TRACK};cursor:pointer}`,
34
+ ".a2ui-std-range:disabled{cursor:not-allowed;opacity:.5}",
35
+ ".a2ui-std-range::-webkit-slider-runnable-track{height:24px;background:transparent;border:0}",
36
+ `.a2ui-std-range::-webkit-slider-thumb{-webkit-appearance:none;appearance:none;margin-top:2px;${THUMB}}`,
37
+ ".a2ui-std-range::-moz-range-track{height:24px;background:transparent;border:0}",
38
+ `.a2ui-std-range::-moz-range-thumb{${THUMB}}`,
39
+ `.a2ui-std-check{-webkit-appearance:none;appearance:none;flex-shrink:0;width:20px;height:20px;margin:0;box-sizing:border-box;border:1px solid ${require_tokens.borderColor("strong")};border-radius:9999px;background:${require_tokens.CONTROL_BG} center/14px 14px no-repeat;cursor:pointer}`,
40
+ ".a2ui-std-check[data-shape=\"square\"]{border-radius:6px}",
41
+ `.a2ui-std-check:checked{background-color:${ACCENT};border-color:${ACCENT};background-image:${CHECK_SVG}}`,
42
+ `.a2ui-std-check[type="radio"]:checked{background-image:none;background-color:${require_tokens.CONTROL_BG};border:6px solid ${ACCENT}}`,
43
+ ".a2ui-std-check:disabled{cursor:not-allowed}",
44
+ ".a2ui-surface :is(h1,h2,h3,h4,h5,h6):not(.a2ui-markdown *){margin:var(--a2ui-heading-margin,0)}",
45
+ ".a2ui-surface :is(p,table,figure,figcaption,blockquote,pre):not(.a2ui-markdown *){margin:var(--a2ui-block-margin,0)}",
46
+ ".a2ui-markdown>:first-child{margin-top:0}",
47
+ ".a2ui-markdown>:last-child{margin-bottom:0}",
48
+ ".a2ui-surface :is(.a2ui-std-list,.a2ui-std-list>li){margin:0}",
49
+ ".a2ui-surface .a2ui-std-table{font-size:inherit;line-height:inherit}",
50
+ ".a2ui-std-table-wrap{width:100%;max-width:100%;min-width:0;overflow-x:auto}",
51
+ ".a2ui-std-cell{padding:8px}",
52
+ ".a2ui-std-cell:first-child{padding-inline-start:0}",
53
+ ".a2ui-std-cell:last-child{padding-inline-end:0}",
54
+ `.a2ui-std-cell[data-divider]{border-bottom:1px solid ${require_tokens.borderColor("subtle")}}`,
55
+ ".a2ui-std-table>tbody:last-child>tr:last-child>.a2ui-std-cell{border-bottom:0}"
56
+ ].join("\n");
57
+
58
+ //#endregion
59
+ exports.ACCENT = ACCENT;
60
+ exports.STANDARD_CSS = STANDARD_CSS;
61
+ exports.STANDARD_STYLE_ID = STANDARD_STYLE_ID;
62
+ //# sourceMappingURL=styles.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"styles.cjs","names":["CONTROL_BG","borderColor","SHADOW_XS","DARK_THEME_CSS","textColor"],"sources":["../../../src/generative-ui/standard/styles.ts"],"sourcesContent":["import { DARK_THEME_CSS } from \"./theme\";\nimport { borderColor, textColor, CONTROL_BG, SHADOW_XS } from \"./tokens\";\n\n/**\n * The stylesheet for what inline styles cannot do: pseudo-elements (slider\n * track and thumb, placeholder), `:checked` and `:first-child` states,\n * heading fallbacks, and resets for host prose styles. It is added once per\n * document.\n *\n * Typography is inherited: a surface takes the font, size, line height and\n * color of the text around it (the chat prose). Headings take the heading\n * styles of the host.\n */\n\nexport const STANDARD_STYLE_ID = \"a2ui-standard-catalog\";\nexport const ACCENT = \"var(--a2ui-color-accent, #0d0d0d)\";\n\nconst FOCUS_RING = \"2px solid var(--a2ui-color-focus, #0285ff)\";\n\nconst CHECK_SVG =\n \"url(\\\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E\\\")\";\n\nconst SLIDER_TRACK = \"var(--a2ui-color-slider-track, rgba(0, 0, 0, 0.04))\";\nconst THUMB = `width:20px;height:20px;box-sizing:border-box;border-radius:9999px;background:${CONTROL_BG};border:1px solid ${borderColor(\"default\")};box-shadow:${SHADOW_XS};cursor:pointer`;\n\nexport const STANDARD_CSS = [\n // The built-in dark values, under a `.dark` class. Every theme rule wins\n // over them.\n DARK_THEME_CSS,\n // The surface (and its root component) never gets wider than the chat column.\n \".a2ui-surface{min-width:0;max-width:100%;box-sizing:border-box}\",\n // The surface inherits the font, size, line height and ink of the host.\n \".a2ui-surface{font:inherit;color:inherit}\",\n // Heading sizes only for hosts without heading styles (zero specificity).\n \":where(.a2ui-surface) :where(h2){font-size:1.5em;font-weight:600;line-height:1.3}\",\n \":where(.a2ui-surface) :where(h3){font-size:1.25em;font-weight:600;line-height:1.3}\",\n \":where(.a2ui-surface) :where(h4){font-size:1em;font-weight:600;line-height:1.4}\",\n // Controls never fall back to the UA font.\n \"[data-a2ui-std] :is(button,input,select,textarea),[data-a2ui-input]{font:inherit;color:inherit}\",\n // Key/value rows: the last text of a space-between row sits flush right.\n '[data-a2ui-row=\"spaceBetween\"]>[data-a2ui-text]:last-child:not(:first-child){text-align:right;margin-inline-start:auto}',\n `[data-a2ui-input]:focus-visible{outline:${FOCUS_RING};outline-offset:1px}`,\n // A scrollable container can take keyboard focus, so it shows a focus ring.\n `[data-a2ui-scroll]:focus-visible{outline:${FOCUS_RING};outline-offset:2px}`,\n `[data-a2ui-input]::placeholder{color:${textColor(\"tertiary\")};opacity:1}`,\n // Slider: 24px pill track, 2px inset white thumb (no filled range).\n `.a2ui-std-range{-webkit-appearance:none;appearance:none;display:block;width:100%;height:24px;margin:0;padding:0 2px;box-sizing:border-box;border-radius:9999px;background:${SLIDER_TRACK};cursor:pointer}`,\n \".a2ui-std-range:disabled{cursor:not-allowed;opacity:.5}\",\n \".a2ui-std-range::-webkit-slider-runnable-track{height:24px;background:transparent;border:0}\",\n `.a2ui-std-range::-webkit-slider-thumb{-webkit-appearance:none;appearance:none;margin-top:2px;${THUMB}}`,\n \".a2ui-std-range::-moz-range-track{height:24px;background:transparent;border:0}\",\n `.a2ui-std-range::-moz-range-thumb{${THUMB}}`,\n // Checkbox and radio: 20px round control, filled when checked.\n `.a2ui-std-check{-webkit-appearance:none;appearance:none;flex-shrink:0;width:20px;height:20px;margin:0;box-sizing:border-box;border:1px solid ${borderColor(\"strong\")};border-radius:9999px;background:${CONTROL_BG} center/14px 14px no-repeat;cursor:pointer}`,\n '.a2ui-std-check[data-shape=\"square\"]{border-radius:6px}',\n `.a2ui-std-check:checked{background-color:${ACCENT};border-color:${ACCENT};background-image:${CHECK_SVG}}`,\n `.a2ui-std-check[type=\"radio\"]:checked{background-image:none;background-color:${CONTROL_BG};border:6px solid ${ACCENT}}`,\n \".a2ui-std-check:disabled{cursor:not-allowed}\",\n // Hosts often wrap chat markdown in a \"prose\" stylesheet (Tailwind\n // typography) that adds margins to headings, paragraphs, lists and tables.\n // A surface is an app panel spaced by gaps, so these rules remove those\n // margins. A Markdown component keeps them, because it reads like the chat\n // prose. The selector must be stronger than `.prose :where(h2)`. Hosts\n // change the margins with `--a2ui-heading-margin` and `--a2ui-block-margin`.\n \".a2ui-surface :is(h1,h2,h3,h4,h5,h6):not(.a2ui-markdown *){margin:var(--a2ui-heading-margin,0)}\",\n \".a2ui-surface :is(p,table,figure,figcaption,blockquote,pre):not(.a2ui-markdown *){margin:var(--a2ui-block-margin,0)}\",\n \".a2ui-markdown>:first-child{margin-top:0}\",\n \".a2ui-markdown>:last-child{margin-bottom:0}\",\n // Only the List component removes native bullets. Markdown keeps them.\n \".a2ui-surface :is(.a2ui-std-list,.a2ui-std-list>li){margin:0}\",\n \".a2ui-surface .a2ui-std-table{font-size:inherit;line-height:inherit}\",\n // Table: 8px cells, flush outer edges, hairline row dividers, no outer border.\n \".a2ui-std-table-wrap{width:100%;max-width:100%;min-width:0;overflow-x:auto}\",\n \".a2ui-std-cell{padding:8px}\",\n \".a2ui-std-cell:first-child{padding-inline-start:0}\",\n \".a2ui-std-cell:last-child{padding-inline-end:0}\",\n `.a2ui-std-cell[data-divider]{border-bottom:1px solid ${borderColor(\"subtle\")}}`,\n \".a2ui-std-table>tbody:last-child>tr:last-child>.a2ui-std-cell{border-bottom:0}\",\n].join(\"\\n\");\n"],"mappings":";;;;;;;;;;;;;;AAcA,MAAa,oBAAoB;AACjC,MAAa,SAAS;AAEtB,MAAM,aAAa;AAEnB,MAAM,YACJ;AAEF,MAAM,eAAe;AACrB,MAAM,QAAQ,gFAAgFA,0BAAW,oBAAoBC,2BAAY,UAAU,CAAC,cAAcC,yBAAU;AAE5K,MAAa,eAAe;CAG1BC;CAEA;CAEA;CAEA;CACA;CACA;CAEA;CAEA;CACA,2CAA2C,WAAW;CAEtD,4CAA4C,WAAW;CACvD,wCAAwCC,yBAAU,WAAW,CAAC;CAE9D,6KAA6K,aAAa;CAC1L;CACA;CACA,gGAAgG,MAAM;CACtG;CACA,qCAAqC,MAAM;CAE3C,gJAAgJH,2BAAY,SAAS,CAAC,mCAAmCD,0BAAW;CACpN;CACA,4CAA4C,OAAO,gBAAgB,OAAO,oBAAoB,UAAU;CACxG,gFAAgFA,0BAAW,oBAAoB,OAAO;CACtH;CAOA;CACA;CACA;CACA;CAEA;CACA;CAEA;CACA;CACA;CACA;CACA,wDAAwDC,2BAAY,SAAS,CAAC;CAC9E;CACD,CAAC,KAAK,KAAK"}
@@ -0,0 +1,17 @@
1
+ //#region src/generative-ui/standard/styles.d.ts
2
+ /**
3
+ * The stylesheet for what inline styles cannot do: pseudo-elements (slider
4
+ * track and thumb, placeholder), `:checked` and `:first-child` states,
5
+ * heading fallbacks, and resets for host prose styles. It is added once per
6
+ * document.
7
+ *
8
+ * Typography is inherited: a surface takes the font, size, line height and
9
+ * color of the text around it (the chat prose). Headings take the heading
10
+ * styles of the host.
11
+ */
12
+ declare const STANDARD_STYLE_ID = "a2ui-standard-catalog";
13
+ declare const ACCENT = "var(--a2ui-color-accent, #0d0d0d)";
14
+ declare const STANDARD_CSS: string;
15
+ //#endregion
16
+ export { ACCENT, STANDARD_CSS, STANDARD_STYLE_ID };
17
+ //# sourceMappingURL=styles.d.cts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"styles.d.cts","names":[],"sources":["../../../src/generative-ui/standard/styles.ts"],"mappings":";;AAcA;;;;;AACA;;;;cADa,iBAAA;AAAA,cACA,MAAA;AAAA,cAUA,YAAA"}
@@ -0,0 +1,17 @@
1
+ //#region src/generative-ui/standard/styles.d.ts
2
+ /**
3
+ * The stylesheet for what inline styles cannot do: pseudo-elements (slider
4
+ * track and thumb, placeholder), `:checked` and `:first-child` states,
5
+ * heading fallbacks, and resets for host prose styles. It is added once per
6
+ * document.
7
+ *
8
+ * Typography is inherited: a surface takes the font, size, line height and
9
+ * color of the text around it (the chat prose). Headings take the heading
10
+ * styles of the host.
11
+ */
12
+ declare const STANDARD_STYLE_ID = "a2ui-standard-catalog";
13
+ declare const ACCENT = "var(--a2ui-color-accent, #0d0d0d)";
14
+ declare const STANDARD_CSS: string;
15
+ //#endregion
16
+ export { ACCENT, STANDARD_CSS, STANDARD_STYLE_ID };
17
+ //# sourceMappingURL=styles.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"styles.d.mts","names":[],"sources":["../../../src/generative-ui/standard/styles.ts"],"mappings":";;AAcA;;;;;AACA;;;;cADa,iBAAA;AAAA,cACA,MAAA;AAAA,cAUA,YAAA"}
@@ -0,0 +1,60 @@
1
+ import { CONTROL_BG, SHADOW_XS, borderColor, textColor } from "./tokens.mjs";
2
+ import { DARK_THEME_CSS } from "./theme.mjs";
3
+
4
+ //#region src/generative-ui/standard/styles.ts
5
+ /**
6
+ * The stylesheet for what inline styles cannot do: pseudo-elements (slider
7
+ * track and thumb, placeholder), `:checked` and `:first-child` states,
8
+ * heading fallbacks, and resets for host prose styles. It is added once per
9
+ * document.
10
+ *
11
+ * Typography is inherited: a surface takes the font, size, line height and
12
+ * color of the text around it (the chat prose). Headings take the heading
13
+ * styles of the host.
14
+ */
15
+ const STANDARD_STYLE_ID = "a2ui-standard-catalog";
16
+ const ACCENT = "var(--a2ui-color-accent, #0d0d0d)";
17
+ const FOCUS_RING = "2px solid var(--a2ui-color-focus, #0285ff)";
18
+ const CHECK_SVG = "url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E\")";
19
+ const SLIDER_TRACK = "var(--a2ui-color-slider-track, rgba(0, 0, 0, 0.04))";
20
+ const THUMB = `width:20px;height:20px;box-sizing:border-box;border-radius:9999px;background:${CONTROL_BG};border:1px solid ${borderColor("default")};box-shadow:${SHADOW_XS};cursor:pointer`;
21
+ const STANDARD_CSS = [
22
+ DARK_THEME_CSS,
23
+ ".a2ui-surface{min-width:0;max-width:100%;box-sizing:border-box}",
24
+ ".a2ui-surface{font:inherit;color:inherit}",
25
+ ":where(.a2ui-surface) :where(h2){font-size:1.5em;font-weight:600;line-height:1.3}",
26
+ ":where(.a2ui-surface) :where(h3){font-size:1.25em;font-weight:600;line-height:1.3}",
27
+ ":where(.a2ui-surface) :where(h4){font-size:1em;font-weight:600;line-height:1.4}",
28
+ "[data-a2ui-std] :is(button,input,select,textarea),[data-a2ui-input]{font:inherit;color:inherit}",
29
+ "[data-a2ui-row=\"spaceBetween\"]>[data-a2ui-text]:last-child:not(:first-child){text-align:right;margin-inline-start:auto}",
30
+ `[data-a2ui-input]:focus-visible{outline:${FOCUS_RING};outline-offset:1px}`,
31
+ `[data-a2ui-scroll]:focus-visible{outline:${FOCUS_RING};outline-offset:2px}`,
32
+ `[data-a2ui-input]::placeholder{color:${textColor("tertiary")};opacity:1}`,
33
+ `.a2ui-std-range{-webkit-appearance:none;appearance:none;display:block;width:100%;height:24px;margin:0;padding:0 2px;box-sizing:border-box;border-radius:9999px;background:${SLIDER_TRACK};cursor:pointer}`,
34
+ ".a2ui-std-range:disabled{cursor:not-allowed;opacity:.5}",
35
+ ".a2ui-std-range::-webkit-slider-runnable-track{height:24px;background:transparent;border:0}",
36
+ `.a2ui-std-range::-webkit-slider-thumb{-webkit-appearance:none;appearance:none;margin-top:2px;${THUMB}}`,
37
+ ".a2ui-std-range::-moz-range-track{height:24px;background:transparent;border:0}",
38
+ `.a2ui-std-range::-moz-range-thumb{${THUMB}}`,
39
+ `.a2ui-std-check{-webkit-appearance:none;appearance:none;flex-shrink:0;width:20px;height:20px;margin:0;box-sizing:border-box;border:1px solid ${borderColor("strong")};border-radius:9999px;background:${CONTROL_BG} center/14px 14px no-repeat;cursor:pointer}`,
40
+ ".a2ui-std-check[data-shape=\"square\"]{border-radius:6px}",
41
+ `.a2ui-std-check:checked{background-color:${ACCENT};border-color:${ACCENT};background-image:${CHECK_SVG}}`,
42
+ `.a2ui-std-check[type="radio"]:checked{background-image:none;background-color:${CONTROL_BG};border:6px solid ${ACCENT}}`,
43
+ ".a2ui-std-check:disabled{cursor:not-allowed}",
44
+ ".a2ui-surface :is(h1,h2,h3,h4,h5,h6):not(.a2ui-markdown *){margin:var(--a2ui-heading-margin,0)}",
45
+ ".a2ui-surface :is(p,table,figure,figcaption,blockquote,pre):not(.a2ui-markdown *){margin:var(--a2ui-block-margin,0)}",
46
+ ".a2ui-markdown>:first-child{margin-top:0}",
47
+ ".a2ui-markdown>:last-child{margin-bottom:0}",
48
+ ".a2ui-surface :is(.a2ui-std-list,.a2ui-std-list>li){margin:0}",
49
+ ".a2ui-surface .a2ui-std-table{font-size:inherit;line-height:inherit}",
50
+ ".a2ui-std-table-wrap{width:100%;max-width:100%;min-width:0;overflow-x:auto}",
51
+ ".a2ui-std-cell{padding:8px}",
52
+ ".a2ui-std-cell:first-child{padding-inline-start:0}",
53
+ ".a2ui-std-cell:last-child{padding-inline-end:0}",
54
+ `.a2ui-std-cell[data-divider]{border-bottom:1px solid ${borderColor("subtle")}}`,
55
+ ".a2ui-std-table>tbody:last-child>tr:last-child>.a2ui-std-cell{border-bottom:0}"
56
+ ].join("\n");
57
+
58
+ //#endregion
59
+ export { ACCENT, STANDARD_CSS, STANDARD_STYLE_ID };
60
+ //# sourceMappingURL=styles.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"styles.mjs","names":[],"sources":["../../../src/generative-ui/standard/styles.ts"],"sourcesContent":["import { DARK_THEME_CSS } from \"./theme\";\nimport { borderColor, textColor, CONTROL_BG, SHADOW_XS } from \"./tokens\";\n\n/**\n * The stylesheet for what inline styles cannot do: pseudo-elements (slider\n * track and thumb, placeholder), `:checked` and `:first-child` states,\n * heading fallbacks, and resets for host prose styles. It is added once per\n * document.\n *\n * Typography is inherited: a surface takes the font, size, line height and\n * color of the text around it (the chat prose). Headings take the heading\n * styles of the host.\n */\n\nexport const STANDARD_STYLE_ID = \"a2ui-standard-catalog\";\nexport const ACCENT = \"var(--a2ui-color-accent, #0d0d0d)\";\n\nconst FOCUS_RING = \"2px solid var(--a2ui-color-focus, #0285ff)\";\n\nconst CHECK_SVG =\n \"url(\\\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E\\\")\";\n\nconst SLIDER_TRACK = \"var(--a2ui-color-slider-track, rgba(0, 0, 0, 0.04))\";\nconst THUMB = `width:20px;height:20px;box-sizing:border-box;border-radius:9999px;background:${CONTROL_BG};border:1px solid ${borderColor(\"default\")};box-shadow:${SHADOW_XS};cursor:pointer`;\n\nexport const STANDARD_CSS = [\n // The built-in dark values, under a `.dark` class. Every theme rule wins\n // over them.\n DARK_THEME_CSS,\n // The surface (and its root component) never gets wider than the chat column.\n \".a2ui-surface{min-width:0;max-width:100%;box-sizing:border-box}\",\n // The surface inherits the font, size, line height and ink of the host.\n \".a2ui-surface{font:inherit;color:inherit}\",\n // Heading sizes only for hosts without heading styles (zero specificity).\n \":where(.a2ui-surface) :where(h2){font-size:1.5em;font-weight:600;line-height:1.3}\",\n \":where(.a2ui-surface) :where(h3){font-size:1.25em;font-weight:600;line-height:1.3}\",\n \":where(.a2ui-surface) :where(h4){font-size:1em;font-weight:600;line-height:1.4}\",\n // Controls never fall back to the UA font.\n \"[data-a2ui-std] :is(button,input,select,textarea),[data-a2ui-input]{font:inherit;color:inherit}\",\n // Key/value rows: the last text of a space-between row sits flush right.\n '[data-a2ui-row=\"spaceBetween\"]>[data-a2ui-text]:last-child:not(:first-child){text-align:right;margin-inline-start:auto}',\n `[data-a2ui-input]:focus-visible{outline:${FOCUS_RING};outline-offset:1px}`,\n // A scrollable container can take keyboard focus, so it shows a focus ring.\n `[data-a2ui-scroll]:focus-visible{outline:${FOCUS_RING};outline-offset:2px}`,\n `[data-a2ui-input]::placeholder{color:${textColor(\"tertiary\")};opacity:1}`,\n // Slider: 24px pill track, 2px inset white thumb (no filled range).\n `.a2ui-std-range{-webkit-appearance:none;appearance:none;display:block;width:100%;height:24px;margin:0;padding:0 2px;box-sizing:border-box;border-radius:9999px;background:${SLIDER_TRACK};cursor:pointer}`,\n \".a2ui-std-range:disabled{cursor:not-allowed;opacity:.5}\",\n \".a2ui-std-range::-webkit-slider-runnable-track{height:24px;background:transparent;border:0}\",\n `.a2ui-std-range::-webkit-slider-thumb{-webkit-appearance:none;appearance:none;margin-top:2px;${THUMB}}`,\n \".a2ui-std-range::-moz-range-track{height:24px;background:transparent;border:0}\",\n `.a2ui-std-range::-moz-range-thumb{${THUMB}}`,\n // Checkbox and radio: 20px round control, filled when checked.\n `.a2ui-std-check{-webkit-appearance:none;appearance:none;flex-shrink:0;width:20px;height:20px;margin:0;box-sizing:border-box;border:1px solid ${borderColor(\"strong\")};border-radius:9999px;background:${CONTROL_BG} center/14px 14px no-repeat;cursor:pointer}`,\n '.a2ui-std-check[data-shape=\"square\"]{border-radius:6px}',\n `.a2ui-std-check:checked{background-color:${ACCENT};border-color:${ACCENT};background-image:${CHECK_SVG}}`,\n `.a2ui-std-check[type=\"radio\"]:checked{background-image:none;background-color:${CONTROL_BG};border:6px solid ${ACCENT}}`,\n \".a2ui-std-check:disabled{cursor:not-allowed}\",\n // Hosts often wrap chat markdown in a \"prose\" stylesheet (Tailwind\n // typography) that adds margins to headings, paragraphs, lists and tables.\n // A surface is an app panel spaced by gaps, so these rules remove those\n // margins. A Markdown component keeps them, because it reads like the chat\n // prose. The selector must be stronger than `.prose :where(h2)`. Hosts\n // change the margins with `--a2ui-heading-margin` and `--a2ui-block-margin`.\n \".a2ui-surface :is(h1,h2,h3,h4,h5,h6):not(.a2ui-markdown *){margin:var(--a2ui-heading-margin,0)}\",\n \".a2ui-surface :is(p,table,figure,figcaption,blockquote,pre):not(.a2ui-markdown *){margin:var(--a2ui-block-margin,0)}\",\n \".a2ui-markdown>:first-child{margin-top:0}\",\n \".a2ui-markdown>:last-child{margin-bottom:0}\",\n // Only the List component removes native bullets. Markdown keeps them.\n \".a2ui-surface :is(.a2ui-std-list,.a2ui-std-list>li){margin:0}\",\n \".a2ui-surface .a2ui-std-table{font-size:inherit;line-height:inherit}\",\n // Table: 8px cells, flush outer edges, hairline row dividers, no outer border.\n \".a2ui-std-table-wrap{width:100%;max-width:100%;min-width:0;overflow-x:auto}\",\n \".a2ui-std-cell{padding:8px}\",\n \".a2ui-std-cell:first-child{padding-inline-start:0}\",\n \".a2ui-std-cell:last-child{padding-inline-end:0}\",\n `.a2ui-std-cell[data-divider]{border-bottom:1px solid ${borderColor(\"subtle\")}}`,\n \".a2ui-std-table>tbody:last-child>tr:last-child>.a2ui-std-cell{border-bottom:0}\",\n].join(\"\\n\");\n"],"mappings":";;;;;;;;;;;;;;AAcA,MAAa,oBAAoB;AACjC,MAAa,SAAS;AAEtB,MAAM,aAAa;AAEnB,MAAM,YACJ;AAEF,MAAM,eAAe;AACrB,MAAM,QAAQ,gFAAgF,WAAW,oBAAoB,YAAY,UAAU,CAAC,cAAc,UAAU;AAE5K,MAAa,eAAe;CAG1B;CAEA;CAEA;CAEA;CACA;CACA;CAEA;CAEA;CACA,2CAA2C,WAAW;CAEtD,4CAA4C,WAAW;CACvD,wCAAwC,UAAU,WAAW,CAAC;CAE9D,6KAA6K,aAAa;CAC1L;CACA;CACA,gGAAgG,MAAM;CACtG;CACA,qCAAqC,MAAM;CAE3C,gJAAgJ,YAAY,SAAS,CAAC,mCAAmC,WAAW;CACpN;CACA,4CAA4C,OAAO,gBAAgB,OAAO,oBAAoB,UAAU;CACxG,gFAAgF,WAAW,oBAAoB,OAAO;CACtH;CAOA;CACA;CACA;CACA;CAEA;CACA;CAEA;CACA;CACA;CACA;CACA,wDAAwD,YAAY,SAAS,CAAC;CAC9E;CACD,CAAC,KAAK,KAAK"}
@@ -0,0 +1,226 @@
1
+ const require_runtime = require('../../_virtual/_rolldown/runtime.cjs');
2
+ const require_tokens = require('./tokens.cjs');
3
+ const require_layout = require('./layout.cjs');
4
+ let zod = require("zod");
5
+
6
+ //#region src/generative-ui/standard/text.ts
7
+ const colorProp = zod.z.string().optional().describe(`One of ${require_tokens.TEXT_COLORS.join("|")} or a CSS color`);
8
+ const fontWeight = zod.z.enum(require_tokens.WEIGHTS).optional();
9
+ const textAlign = zod.z.enum([
10
+ "start",
11
+ "center",
12
+ "end"
13
+ ]).optional();
14
+ const typographyProps = {
15
+ color: colorProp,
16
+ fontWeight,
17
+ textAlign,
18
+ italic: zod.z.boolean().optional(),
19
+ truncate: zod.z.boolean().optional(),
20
+ maxLines: zod.z.number().optional(),
21
+ tabularNums: zod.z.boolean().optional(),
22
+ width: require_layout.sizeValue.optional()
23
+ };
24
+ const typographySchema = zod.z.object(typographyProps);
25
+ const titleSchema = zod.z.object({
26
+ ...typographyProps,
27
+ text: zod.z.string().describe("Heading text"),
28
+ size: zod.z.enum(require_tokens.TITLE_SIZES).optional().describe("Default \"md\""),
29
+ strong: zod.z.boolean().optional().describe("Default true")
30
+ });
31
+ const textSchema = zod.z.object({
32
+ ...typographyProps,
33
+ weight: require_layout.weightProp,
34
+ text: zod.z.union([zod.z.string(), zod.z.number()]).optional().describe("Text with inline markdown. A bound number shows as text"),
35
+ size: zod.z.enum(require_tokens.TEXT_SIZES).optional().describe("Default \"md\""),
36
+ fontSize: require_layout.sizeValue.optional().describe("Pixels when a number. Wins over size"),
37
+ lineHeight: zod.z.union([zod.z.number(), zod.z.string()]).optional().describe("A unitless ratio, or CSS"),
38
+ minLines: zod.z.number().optional().describe("Reserves the height of this many lines"),
39
+ strong: zod.z.boolean().optional().describe("Default false"),
40
+ underline: zod.z.boolean().optional(),
41
+ lineThrough: zod.z.boolean().optional(),
42
+ inline: zod.z.boolean().optional(),
43
+ preserveWhitespace: zod.z.boolean().optional(),
44
+ highlight: zod.z.union([zod.z.enum([
45
+ "green",
46
+ "orange",
47
+ "pink"
48
+ ]), zod.z.boolean()]).optional()
49
+ });
50
+ const CAPTION_SIZES = [
51
+ "sm",
52
+ "md",
53
+ "lg"
54
+ ];
55
+ const captionSchema = zod.z.object({
56
+ text: zod.z.union([zod.z.string(), zod.z.number()]).describe("Caption text"),
57
+ color: colorProp,
58
+ size: zod.z.enum(CAPTION_SIZES).optional().describe("Default \"lg\""),
59
+ fontWeight: fontWeight.describe("Default \"normal\""),
60
+ textAlign,
61
+ truncate: zod.z.boolean().optional(),
62
+ maxLines: zod.z.number().optional()
63
+ });
64
+ const labelSchema = zod.z.object({
65
+ text: zod.z.union([zod.z.string(), zod.z.number()]).describe("Label text"),
66
+ htmlFor: zod.z.string().optional(),
67
+ color: colorProp,
68
+ size: zod.z.enum(require_tokens.TEXT_SIZES).optional().describe("Default \"sm\""),
69
+ fontWeight: fontWeight.describe("Default \"medium\""),
70
+ textAlign,
71
+ truncate: zod.z.boolean().optional(),
72
+ width: require_layout.sizeValue.optional()
73
+ });
74
+ const boldSchema = zod.z.object({
75
+ text: zod.z.string(),
76
+ fontWeight
77
+ });
78
+ const inlineTextSchema = zod.z.object({ text: zod.z.string() });
79
+ const blockquoteSchema = zod.z.object({ text: zod.z.string().describe("The quoted text, with inline markdown") });
80
+ const BADGE_SIZES = [
81
+ "sm",
82
+ "md",
83
+ "lg"
84
+ ];
85
+ const badgeSchema = zod.z.object({
86
+ label: zod.z.string().describe("Badge text"),
87
+ color: zod.z.enum([
88
+ "secondary",
89
+ "success",
90
+ "danger",
91
+ "warning",
92
+ "info",
93
+ "discovery"
94
+ ]).optional().describe("Default \"secondary\""),
95
+ size: zod.z.enum(BADGE_SIZES).optional().describe("Default \"md\""),
96
+ pill: zod.z.boolean().optional().describe("Default true"),
97
+ variant: zod.z.enum([
98
+ "soft",
99
+ "solid",
100
+ "outline"
101
+ ]).optional().describe("Default \"soft\""),
102
+ fontWeight: fontWeight.describe("Default \"medium\""),
103
+ maxWidth: require_layout.sizeValue.optional(),
104
+ padding: require_layout.sizeValue.optional()
105
+ });
106
+ const codeSchema = zod.z.object({
107
+ text: zod.z.string().describe("Source code"),
108
+ language: zod.z.string().optional()
109
+ });
110
+ const markdownSchema = zod.z.object({
111
+ text: zod.z.string().describe("Markdown source"),
112
+ streaming: zod.z.boolean().optional().describe("Default false")
113
+ });
114
+ const mathSchema = zod.z.object({
115
+ value: zod.z.string().describe("TeX source"),
116
+ block: zod.z.boolean().optional().describe("Default false")
117
+ });
118
+ const shimmerSchema = zod.z.object({
119
+ ...typographyProps,
120
+ text: zod.z.string(),
121
+ size: zod.z.enum(require_tokens.TEXT_SIZES).optional().describe("Default \"md\""),
122
+ lineThrough: zod.z.boolean().optional()
123
+ });
124
+ const linkSchema = zod.z.object({
125
+ text: zod.z.string().describe("Link text"),
126
+ href: zod.z.string().describe("URL"),
127
+ title: zod.z.string().optional()
128
+ });
129
+ /**
130
+ * The standard text components, without their framework components.
131
+ *
132
+ * - Text has a "multiple" `children` slot. The children render inline
133
+ * after the text.
134
+ * - Tooltip has two "single" slots: `trigger` and `content`.
135
+ * - Link is a plain link. It opens http, https and mailto URLs only.
136
+ */
137
+ const textDeclarations = {
138
+ Title: {
139
+ description: "A heading in a Card or next to another component; a heading alone is markdown. Size \"2xl\" at most once per surface, \"lg\" for sections. \"sm\" is an h4, \"md\"/\"lg\" an h3 (default \"md\"), \"xl\" and up an h2. Bold unless strong is false.",
140
+ props: titleSchema
141
+ },
142
+ Text: {
143
+ description: "Body text in a Card or next to another component; a paragraph alone is markdown outside the fence. Color \"default\" or \"secondary\". `text` takes inline markdown (**bold**, *italic*, ~~strike~~, ++underline++, `code`, [link](url)). `children` ids render inline after it, e.g. a Badge.",
144
+ props: textSchema,
145
+ slots: require_layout.CHILDREN_SLOT
146
+ },
147
+ Caption: {
148
+ description: "Small secondary text: a hint under a control, or a label in a Row. `text` can have inline markdown.",
149
+ props: captionSchema
150
+ },
151
+ Label: {
152
+ description: "The label of a form field.",
153
+ props: labelSchema
154
+ },
155
+ Bold: {
156
+ description: "Bold inline text.",
157
+ props: boldSchema
158
+ },
159
+ Italic: {
160
+ description: "Italic inline text.",
161
+ props: inlineTextSchema
162
+ },
163
+ Underline: {
164
+ description: "Underlined inline text.",
165
+ props: inlineTextSchema
166
+ },
167
+ Strikethrough: {
168
+ description: "Struck-through inline text.",
169
+ props: inlineTextSchema
170
+ },
171
+ Badge: {
172
+ description: "A small status pill. Use the colors success, danger and warning only to show a status, not for decoration.",
173
+ props: badgeSchema
174
+ },
175
+ Blockquote: {
176
+ description: "A block quotation with a line on the left. `text` can have inline markdown.",
177
+ props: blockquoteSchema
178
+ },
179
+ Code: {
180
+ description: "A block of code in a monospace font.",
181
+ props: codeSchema
182
+ },
183
+ Markdown: {
184
+ description: "A block of GitHub-flavored markdown. Use it only next to other components, for example in a table cell or next to a chart. Markdown alone goes outside the fence.",
185
+ props: markdownSchema
186
+ },
187
+ Math: {
188
+ description: "A TeX math formula, typeset with KaTeX. Set block to true for a centered formula on its own line.",
189
+ props: mathSchema
190
+ },
191
+ ShimmerText: {
192
+ description: "Text with a moving shimmer. It shows that something is loading or pending.",
193
+ props: shimmerSchema
194
+ },
195
+ Link: {
196
+ description: "A link. Only http, https and mailto URLs work. It opens in a new tab.",
197
+ props: linkSchema
198
+ },
199
+ Tooltip: {
200
+ description: "Shows `content` when the user points at or focuses `trigger`. `trigger`: one child id, a Text, Icon or Badge (not a Button or Link). `content`: one child id of short text, no links or buttons.",
201
+ slots: {
202
+ trigger: "single",
203
+ content: "single"
204
+ }
205
+ }
206
+ };
207
+
208
+ //#endregion
209
+ exports.BADGE_SIZES = BADGE_SIZES;
210
+ exports.CAPTION_SIZES = CAPTION_SIZES;
211
+ exports.badgeSchema = badgeSchema;
212
+ exports.blockquoteSchema = blockquoteSchema;
213
+ exports.boldSchema = boldSchema;
214
+ exports.captionSchema = captionSchema;
215
+ exports.codeSchema = codeSchema;
216
+ exports.inlineTextSchema = inlineTextSchema;
217
+ exports.labelSchema = labelSchema;
218
+ exports.linkSchema = linkSchema;
219
+ exports.markdownSchema = markdownSchema;
220
+ exports.mathSchema = mathSchema;
221
+ exports.shimmerSchema = shimmerSchema;
222
+ exports.textDeclarations = textDeclarations;
223
+ exports.textSchema = textSchema;
224
+ exports.titleSchema = titleSchema;
225
+ exports.typographySchema = typographySchema;
226
+ //# sourceMappingURL=text.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"text.cjs","names":["z","TEXT_COLORS","WEIGHTS","sizeValue","TITLE_SIZES","weightProp","TEXT_SIZES","CHILDREN_SLOT"],"sources":["../../../src/generative-ui/standard/text.ts"],"sourcesContent":["import { z } from \"zod\";\nimport { CHILDREN_SLOT, sizeValue, weightProp } from \"./layout\";\nimport { TEXT_COLORS, TEXT_SIZES, TITLE_SIZES, WEIGHTS } from \"./tokens\";\n\n// ---- Schemas ----\n\nconst colorProp = z\n .string()\n .optional()\n .describe(`One of ${TEXT_COLORS.join(\"|\")} or a CSS color`);\nconst fontWeight = z.enum(WEIGHTS).optional();\nconst textAlign = z.enum([\"start\", \"center\", \"end\"]).optional();\n\nconst typographyProps = {\n color: colorProp,\n fontWeight,\n textAlign,\n italic: z.boolean().optional(),\n truncate: z.boolean().optional(),\n maxLines: z.number().optional(),\n tabularNums: z.boolean().optional(),\n width: sizeValue.optional(),\n};\n\nexport const typographySchema = z.object(typographyProps);\nexport const titleSchema = z.object({\n ...typographyProps,\n text: z.string().describe(\"Heading text\"),\n size: z.enum(TITLE_SIZES).optional().describe('Default \"md\"'),\n strong: z.boolean().optional().describe(\"Default true\"),\n});\nexport const textSchema = z.object({\n ...typographyProps,\n weight: weightProp,\n text: z\n .union([z.string(), z.number()])\n .optional()\n .describe(\"Text with inline markdown. A bound number shows as text\"),\n size: z.enum(TEXT_SIZES).optional().describe('Default \"md\"'),\n fontSize: sizeValue\n .optional()\n .describe(\"Pixels when a number. Wins over size\"),\n lineHeight: z\n .union([z.number(), z.string()])\n .optional()\n .describe(\"A unitless ratio, or CSS\"),\n minLines: z\n .number()\n .optional()\n .describe(\"Reserves the height of this many lines\"),\n strong: z.boolean().optional().describe(\"Default false\"),\n underline: z.boolean().optional(),\n lineThrough: z.boolean().optional(),\n inline: z.boolean().optional(),\n preserveWhitespace: z.boolean().optional(),\n highlight: z\n .union([z.enum([\"green\", \"orange\", \"pink\"]), z.boolean()])\n .optional(),\n});\nexport const CAPTION_SIZES = [\"sm\", \"md\", \"lg\"] as const;\nexport const captionSchema = z.object({\n text: z.union([z.string(), z.number()]).describe(\"Caption text\"),\n color: colorProp,\n size: z.enum(CAPTION_SIZES).optional().describe('Default \"lg\"'),\n fontWeight: fontWeight.describe('Default \"normal\"'),\n textAlign,\n truncate: z.boolean().optional(),\n maxLines: z.number().optional(),\n});\nexport const labelSchema = z.object({\n text: z.union([z.string(), z.number()]).describe(\"Label text\"),\n htmlFor: z.string().optional(),\n color: colorProp,\n size: z.enum(TEXT_SIZES).optional().describe('Default \"sm\"'),\n fontWeight: fontWeight.describe('Default \"medium\"'),\n textAlign,\n truncate: z.boolean().optional(),\n width: sizeValue.optional(),\n});\nexport const boldSchema = z.object({ text: z.string(), fontWeight });\nexport const inlineTextSchema = z.object({ text: z.string() });\nexport const blockquoteSchema = z.object({\n text: z.string().describe(\"The quoted text, with inline markdown\"),\n});\nexport const BADGE_SIZES = [\"sm\", \"md\", \"lg\"] as const;\nexport const badgeSchema = z.object({\n label: z.string().describe(\"Badge text\"),\n color: z\n .enum([\"secondary\", \"success\", \"danger\", \"warning\", \"info\", \"discovery\"])\n .optional()\n .describe('Default \"secondary\"'),\n size: z.enum(BADGE_SIZES).optional().describe('Default \"md\"'),\n pill: z.boolean().optional().describe(\"Default true\"),\n variant: z\n .enum([\"soft\", \"solid\", \"outline\"])\n .optional()\n .describe('Default \"soft\"'),\n fontWeight: fontWeight.describe('Default \"medium\"'),\n maxWidth: sizeValue.optional(),\n padding: sizeValue.optional(),\n});\nexport const codeSchema = z.object({\n text: z.string().describe(\"Source code\"),\n language: z.string().optional(),\n});\nexport const markdownSchema = z.object({\n text: z.string().describe(\"Markdown source\"),\n streaming: z.boolean().optional().describe(\"Default false\"),\n});\nexport const mathSchema = z.object({\n value: z.string().describe(\"TeX source\"),\n block: z.boolean().optional().describe(\"Default false\"),\n});\nexport const shimmerSchema = z.object({\n ...typographyProps,\n text: z.string(),\n size: z.enum(TEXT_SIZES).optional().describe('Default \"md\"'),\n lineThrough: z.boolean().optional(),\n});\nexport const linkSchema = z.object({\n text: z.string().describe(\"Link text\"),\n href: z.string().describe(\"URL\"),\n title: z.string().optional(),\n});\n\n/**\n * The standard text components, without their framework components.\n *\n * - Text has a \"multiple\" `children` slot. The children render inline\n * after the text.\n * - Tooltip has two \"single\" slots: `trigger` and `content`.\n * - Link is a plain link. It opens http, https and mailto URLs only.\n */\nexport const textDeclarations = {\n Title: {\n description:\n 'A heading in a Card or next to another component; a heading alone is markdown. Size \"2xl\" at most once per surface, \"lg\" for sections. \"sm\" is an h4, \"md\"/\"lg\" an h3 (default \"md\"), \"xl\" and up an h2. Bold unless strong is false.',\n props: titleSchema,\n },\n Text: {\n description:\n 'Body text in a Card or next to another component; a paragraph alone is markdown outside the fence. Color \"default\" or \"secondary\". `text` takes inline markdown (**bold**, *italic*, ~~strike~~, ++underline++, `code`, [link](url)). `children` ids render inline after it, e.g. a Badge.',\n props: textSchema,\n slots: CHILDREN_SLOT,\n },\n Caption: {\n description:\n \"Small secondary text: a hint under a control, or a label in a Row. `text` can have inline markdown.\",\n props: captionSchema,\n },\n Label: {\n description: \"The label of a form field.\",\n props: labelSchema,\n },\n Bold: {\n description: \"Bold inline text.\",\n props: boldSchema,\n },\n Italic: {\n description: \"Italic inline text.\",\n props: inlineTextSchema,\n },\n Underline: {\n description: \"Underlined inline text.\",\n props: inlineTextSchema,\n },\n Strikethrough: {\n description: \"Struck-through inline text.\",\n props: inlineTextSchema,\n },\n Badge: {\n description:\n \"A small status pill. Use the colors success, danger and warning only to show a status, not for decoration.\",\n props: badgeSchema,\n },\n Blockquote: {\n description:\n \"A block quotation with a line on the left. `text` can have inline markdown.\",\n props: blockquoteSchema,\n },\n Code: {\n description: \"A block of code in a monospace font.\",\n props: codeSchema,\n },\n Markdown: {\n description:\n \"A block of GitHub-flavored markdown. Use it only next to other components, for example in a table cell or next to a chart. Markdown alone goes outside the fence.\",\n props: markdownSchema,\n },\n Math: {\n description:\n \"A TeX math formula, typeset with KaTeX. Set block to true for a centered formula on its own line.\",\n props: mathSchema,\n },\n ShimmerText: {\n description:\n \"Text with a moving shimmer. It shows that something is loading or pending.\",\n props: shimmerSchema,\n },\n Link: {\n description:\n \"A link. Only http, https and mailto URLs work. It opens in a new tab.\",\n props: linkSchema,\n },\n Tooltip: {\n description:\n \"Shows `content` when the user points at or focuses `trigger`. `trigger`: one child id, a Text, Icon or Badge (not a Button or Link). `content`: one child id of short text, no links or buttons.\",\n slots: { trigger: \"single\", content: \"single\" } as const,\n },\n};\n"],"mappings":";;;;;;AAMA,MAAM,YAAYA,MACf,QAAQ,CACR,UAAU,CACV,SAAS,UAAUC,2BAAY,KAAK,IAAI,CAAC,iBAAiB;AAC7D,MAAM,aAAaD,MAAE,KAAKE,uBAAQ,CAAC,UAAU;AAC7C,MAAM,YAAYF,MAAE,KAAK;CAAC;CAAS;CAAU;CAAM,CAAC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