@cueplusplus/ui 0.20.1 → 0.22.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 (236) hide show
  1. package/CHANGELOG.md +133 -0
  2. package/dist/chat/agent-pile.js +2 -2
  3. package/dist/chrome/_status-bar.js +1 -1
  4. package/dist/chrome/app-shell.js +1 -1
  5. package/dist/chrome/navigation-menu.js +3 -3
  6. package/dist/chrome/row.js +1 -1
  7. package/dist/chrome/scroll-area.js +1 -1
  8. package/dist/chrome/section-header.js +1 -1
  9. package/dist/chrome/segmented-control.js +1 -1
  10. package/dist/chrome/tabs.js +1 -1
  11. package/dist/chrome/toolbar.js +1 -1
  12. package/dist/chrome/tree.js +3 -3
  13. package/dist/date/calendar.js +3 -3
  14. package/dist/dmx/channel-matrix.js +1 -1
  15. package/dist/dmx/universe-grid.js +1 -1
  16. package/dist/elements/agent-handoff.js +3 -3
  17. package/dist/elements/agent-plan.js +1 -1
  18. package/dist/elements/agent-status.js +1 -1
  19. package/dist/elements/agent-surface.d.ts +9 -6
  20. package/dist/elements/agent-surface.js +3 -2
  21. package/dist/elements/approval-card.d.ts +29 -3
  22. package/dist/elements/approval-card.js +18 -8
  23. package/dist/elements/artifact-card.js +2 -2
  24. package/dist/elements/canvas-split.js +3 -3
  25. package/dist/elements/chart.js +1 -1
  26. package/dist/elements/chat-panel.js +2 -2
  27. package/dist/elements/checkpoint-history.js +1 -1
  28. package/dist/elements/code-diff.js +1 -1
  29. package/dist/elements/code-runner.js +1 -1
  30. package/dist/elements/composer.d.ts +8 -2
  31. package/dist/elements/composer.js +20 -12
  32. package/dist/elements/computer-use.js +2 -2
  33. package/dist/elements/confidence-marker.js +1 -1
  34. package/dist/elements/connection-state.js +2 -2
  35. package/dist/elements/context-breakdown.js +1 -1
  36. package/dist/elements/context-usage.js +1 -1
  37. package/dist/elements/conversation-search.js +2 -2
  38. package/dist/elements/cost-meter.js +1 -1
  39. package/dist/elements/data-table.js +1 -1
  40. package/dist/elements/diagram.js +1 -1
  41. package/dist/elements/draft-restore.js +2 -2
  42. package/dist/elements/edit-message.js +1 -1
  43. package/dist/elements/elements.css +134 -0
  44. package/dist/elements/elicitation-form.d.ts +8 -1
  45. package/dist/elements/elicitation-form.js +24 -16
  46. package/dist/elements/empty-state.js +3 -3
  47. package/dist/elements/error-state.js +2 -2
  48. package/dist/elements/event-feed.d.ts +88 -0
  49. package/dist/elements/event-feed.js +190 -0
  50. package/dist/elements/feedback-dialog.js +2 -2
  51. package/dist/elements/file-tree.js +1 -1
  52. package/dist/elements/flow-graph.js +2 -2
  53. package/dist/elements/generative.css +13 -0
  54. package/dist/elements/generative.d.ts +8 -6
  55. package/dist/elements/generative.js +4 -3
  56. package/dist/elements/image-generation.js +2 -2
  57. package/dist/elements/index.d.ts +7 -3
  58. package/dist/elements/index.js +5 -2
  59. package/dist/elements/inline-citation.js +1 -1
  60. package/dist/elements/job-progress.js +1 -1
  61. package/dist/elements/launcher-bubble.js +3 -3
  62. package/dist/elements/loading-state.js +1 -1
  63. package/dist/elements/map-answer.js +1 -1
  64. package/dist/elements/math-block.js +1 -1
  65. package/dist/elements/mcp-server-panel.js +3 -3
  66. package/dist/elements/memory-chips.js +1 -1
  67. package/dist/elements/message-attachment.js +3 -3
  68. package/dist/elements/message-branches.js +1 -1
  69. package/dist/elements/message-pair.js +2 -2
  70. package/dist/elements/message-queue.js +1 -1
  71. package/dist/elements/message-timing.js +1 -1
  72. package/dist/elements/mobile-composer.js +1 -1
  73. package/dist/elements/model-picker.js +1 -1
  74. package/dist/elements/number-ticker.js +1 -1
  75. package/dist/elements/onboarding.js +3 -3
  76. package/dist/elements/permission-grant.js +3 -3
  77. package/dist/elements/prompt-library.js +1 -1
  78. package/dist/elements/question-card.d.ts +50 -0
  79. package/dist/elements/question-card.js +117 -0
  80. package/dist/elements/queue-dock.js +1 -1
  81. package/dist/elements/quota-banner.js +1 -1
  82. package/dist/elements/quote-reply.js +3 -3
  83. package/dist/elements/read-aloud.js +2 -2
  84. package/dist/elements/reasoning-effort.js +2 -2
  85. package/dist/elements/reasoning-panel.js +3 -3
  86. package/dist/elements/recommendation-card.js +2 -2
  87. package/dist/elements/regenerate-menu.js +1 -1
  88. package/dist/elements/request-delivery.js +31 -0
  89. package/dist/elements/research-report.js +1 -1
  90. package/dist/elements/retrieval-chunks.js +3 -3
  91. package/dist/elements/revert-dock.js +1 -1
  92. package/dist/elements/reviewable-diff.js +4 -4
  93. package/dist/elements/schedule-card.js +2 -2
  94. package/dist/elements/score-breakdown.js +2 -2
  95. package/dist/elements/scroll-anchor.js +2 -2
  96. package/dist/elements/settings-panel.js +3 -3
  97. package/dist/elements/sources.js +1 -1
  98. package/dist/elements/spec-sheet.js +1 -1
  99. package/dist/elements/stopped-run.js +2 -2
  100. package/dist/elements/streaming-text.js +2 -2
  101. package/dist/elements/subagent-list.js +4 -4
  102. package/dist/elements/suggestions.js +1 -1
  103. package/dist/elements/surfaces.d.ts +6 -6
  104. package/dist/elements/surfaces.js +7 -7
  105. package/dist/elements/tail-status.js +1 -1
  106. package/dist/elements/terminal-block.js +1 -1
  107. package/dist/elements/thinking-indicator.js +1 -1
  108. package/dist/elements/timeline.js +1 -1
  109. package/dist/elements/todo-list.js +1 -1
  110. package/dist/elements/tool-call.d.ts +18 -2
  111. package/dist/elements/tool-call.js +20 -11
  112. package/dist/elements/tool-error.js +2 -2
  113. package/dist/elements/tool-group.d.ts +11 -3
  114. package/dist/elements/tool-group.js +62 -38
  115. package/dist/elements/tool-state.d.ts +13 -0
  116. package/dist/elements/tool-state.js +44 -0
  117. package/dist/elements/tool-timeline.js +2 -2
  118. package/dist/elements/trace-waterfall.js +2 -2
  119. package/dist/elements/unsupported-request-card.d.ts +31 -0
  120. package/dist/elements/unsupported-request-card.js +80 -0
  121. package/dist/elements/vocabulary.d.ts +50 -1
  122. package/dist/elements/vocabulary.js +50 -1
  123. package/dist/elements/voice-conversation.js +5 -5
  124. package/dist/elements/web-preview.js +1 -1
  125. package/dist/elements/web-search.js +2 -2
  126. package/dist/elements/work-collapse.js +1 -1
  127. package/dist/forms/_chassis.d.ts +6 -1
  128. package/dist/forms/_chassis.js +8 -3
  129. package/dist/forms/file-upload.js +1 -1
  130. package/dist/forms/rating.js +1 -1
  131. package/dist/forms/select.js +1 -1
  132. package/dist/forms/switch.js +2 -2
  133. package/dist/forms/toggle.js +1 -1
  134. package/dist/index.d.ts +3 -1
  135. package/dist/index.js +3 -1
  136. package/dist/instruments/_ledger-disclosure.js +1 -1
  137. package/dist/instruments/data-tree.js +1 -1
  138. package/dist/instruments/meter.js +1 -1
  139. package/dist/instruments/seam-grid.js +1 -1
  140. package/dist/layout/_collapse.js +3 -3
  141. package/dist/layout/bento.js +1 -1
  142. package/dist/layout/breadcrumb.js +1 -1
  143. package/dist/layout/carousel.js +1 -1
  144. package/dist/layout/collapsible.js +1 -1
  145. package/dist/layout/index.d.ts +3 -1
  146. package/dist/layout/index.js +3 -1
  147. package/dist/layout/item.js +1 -1
  148. package/dist/layout/link.js +1 -1
  149. package/dist/layout/pagination.js +1 -1
  150. package/dist/layout/pane-seam.d.ts +75 -0
  151. package/dist/layout/pane-seam.js +127 -0
  152. package/dist/layout/resizable.d.ts +2 -1
  153. package/dist/layout/resizable.js +3 -2
  154. package/dist/layout/sidebar.js +3 -3
  155. package/dist/layout/split-pane.d.ts +74 -0
  156. package/dist/layout/split-pane.js +135 -0
  157. package/dist/layout/stepper.js +1 -1
  158. package/dist/lib/auto-grow.js +42 -0
  159. package/dist/overlays/_surface.d.ts +5 -5
  160. package/dist/overlays/_surface.js +4 -4
  161. package/dist/overlays/drawer.js +1 -1
  162. package/dist/overlays/menubar.js +1 -1
  163. package/dist/overlays/sheet.js +1 -1
  164. package/dist/overlays/toast.js +1 -1
  165. package/dist/primitives/button.js +1 -1
  166. package/dist/primitives/chip.d.ts +1 -1
  167. package/dist/styles.css +52 -0
  168. package/dist/system/_paint-stroke-sunken.js +22 -2
  169. package/dist/system/_paint-stroke-surface-1.js +5 -1
  170. package/dist/system/_paint-stroke-surface-2.js +5 -1
  171. package/dist/system/_style-disabled.js +1 -7
  172. package/dist/system/agent-skin.d.ts +11 -5
  173. package/manifest/components/agent-surface.json +5 -4
  174. package/manifest/components/alert-dialog.json +1 -0
  175. package/manifest/components/approval-card.json +45 -7
  176. package/manifest/components/autocomplete.json +2 -0
  177. package/manifest/components/button.json +0 -3
  178. package/manifest/components/card.json +1 -0
  179. package/manifest/components/channel-matrix.json +1 -0
  180. package/manifest/components/chart-tooltip-content.json +1 -0
  181. package/manifest/components/checkbox-group.json +0 -3
  182. package/manifest/components/checkbox.json +0 -3
  183. package/manifest/components/color-field.json +1 -0
  184. package/manifest/components/color-picker.json +1 -0
  185. package/manifest/components/combobox.json +2 -0
  186. package/manifest/components/command-palette.json +1 -0
  187. package/manifest/components/composer-input.json +16 -2
  188. package/manifest/components/composer.json +1 -0
  189. package/manifest/components/context-menu.json +1 -0
  190. package/manifest/components/date-field.json +1 -0
  191. package/manifest/components/date-picker.json +1 -0
  192. package/manifest/components/date-range-picker.json +1 -0
  193. package/manifest/components/dialog.json +1 -0
  194. package/manifest/components/dmx-bar.json +1 -0
  195. package/manifest/components/dmx-strip.json +1 -0
  196. package/manifest/components/drawer.json +1 -0
  197. package/manifest/components/dropdown-menu.json +1 -0
  198. package/manifest/components/elicitation-form.json +16 -1
  199. package/manifest/components/env-var-input.json +1 -0
  200. package/manifest/components/event-feed.json +171 -0
  201. package/manifest/components/event-row.json +116 -0
  202. package/manifest/components/generative-ui.json +4 -3
  203. package/manifest/components/hover-card.json +1 -0
  204. package/manifest/components/input-group.json +1 -0
  205. package/manifest/components/input.json +1 -0
  206. package/manifest/components/menubar.json +1 -0
  207. package/manifest/components/multi-select.json +2 -0
  208. package/manifest/components/musical-time-input.json +1 -0
  209. package/manifest/components/navigation-menu.json +1 -0
  210. package/manifest/components/number-field.json +1 -0
  211. package/manifest/components/otp-field.json +1 -0
  212. package/manifest/components/pane-seam.json +171 -0
  213. package/manifest/components/password-input.json +1 -0
  214. package/manifest/components/popover.json +1 -0
  215. package/manifest/components/question-card.json +157 -0
  216. package/manifest/components/resizable.json +1 -1
  217. package/manifest/components/scrub-input.json +1 -0
  218. package/manifest/components/search-input.json +1 -0
  219. package/manifest/components/select.json +2 -0
  220. package/manifest/components/sheet.json +1 -0
  221. package/manifest/components/split-pane.json +224 -0
  222. package/manifest/components/switch.json +0 -3
  223. package/manifest/components/tags-input.json +2 -0
  224. package/manifest/components/textarea.json +1 -0
  225. package/manifest/components/theme-configurator.json +1 -0
  226. package/manifest/components/time-field.json +1 -0
  227. package/manifest/components/toast.json +1 -0
  228. package/manifest/components/toggle.json +0 -3
  229. package/manifest/components/tool-call.json +46 -2
  230. package/manifest/components/tool-group.json +15 -3
  231. package/manifest/components/tooltip.json +1 -0
  232. package/manifest/components/unsupported-request-card.json +117 -0
  233. package/manifest/fixtures.json +16 -0
  234. package/manifest/manifest.json +134 -56
  235. package/manifest/tokens.json +12 -2
  236. package/package.json +3 -3
@@ -0,0 +1,116 @@
1
+ {
2
+ "name": "EventRow",
3
+ "slug": "event-row",
4
+ "group": "elements",
5
+ "importPath": "@cueplusplus/ui/elements",
6
+ "peerDependencies": [],
7
+ "clientOnly": true,
8
+ "description": "One event, as a feed row: time, a toned dot, kind, title, and a one-line\npreview under the title. Exported for a list of the caller's own.\n\nInside an {@link EventFeed} it is an `option` of the feed's listbox. Drawn\nalone it claims no role, and in a listbox of the caller's it takes\n`role=\"option\"` from its props; either way `aria-selected` follows `selected`\nonly when the row is an option.",
9
+ "props": [
10
+ {
11
+ "name": "event",
12
+ "type": "FeedEvent",
13
+ "required": true,
14
+ "defaultValue": null,
15
+ "description": "The record this row draws.",
16
+ "control": {
17
+ "kind": "opaque",
18
+ "fixture": "agents.feed-event"
19
+ }
20
+ },
21
+ {
22
+ "name": "selected",
23
+ "type": "boolean",
24
+ "required": false,
25
+ "defaultValue": "false",
26
+ "description": "Whether this row is the selected one.",
27
+ "control": {
28
+ "kind": "boolean"
29
+ }
30
+ },
31
+ {
32
+ "name": "onSelect",
33
+ "type": "((id: string) => void)",
34
+ "required": false,
35
+ "defaultValue": null,
36
+ "description": "Called with the event's `id` when the row is clicked.",
37
+ "control": {
38
+ "kind": "callback",
39
+ "fixture": "callback.log"
40
+ }
41
+ },
42
+ {
43
+ "name": "formatTime",
44
+ "type": "((timestamp: string | number | Date) => string)",
45
+ "required": false,
46
+ "defaultValue": "formatTimestamp",
47
+ "description": "Formats the time column. Defaults to a time of day for a `Date` or a number.",
48
+ "control": {
49
+ "kind": "callback",
50
+ "fixture": "callback.log"
51
+ }
52
+ }
53
+ ],
54
+ "typeReferences": [
55
+ "Omit<React.ComponentPropsWithoutRef<\"div\">, \"children\" | \"onSelect\">"
56
+ ],
57
+ "subcomponents": [],
58
+ "parts": [],
59
+ "variants": {},
60
+ "defaultVariants": {},
61
+ "tokensUsed": [
62
+ "--cue-accent",
63
+ "--cue-border",
64
+ "--cue-danger",
65
+ "--cue-fg",
66
+ "--cue-fg-muted",
67
+ "--cue-fg-subtle",
68
+ "--cue-focus",
69
+ "--cue-focus-ring",
70
+ "--cue-ok",
71
+ "--cue-radius-control",
72
+ "--cue-space-1",
73
+ "--cue-space-2",
74
+ "--cue-space-3",
75
+ "--cue-stream",
76
+ "--cue-style-focus-width",
77
+ "--cue-surface-2",
78
+ "--cue-text-label",
79
+ "--cue-text-ui",
80
+ "--cue-warn"
81
+ ],
82
+ "summary": "One event as an activity feed draws it, for a list of your own.",
83
+ "examples": [
84
+ {
85
+ "title": "Usage",
86
+ "code": "<div role=\"listbox\" aria-label=\"Recent\">\n <EventRow role=\"option\" event={event} selected={event.id === id} onSelect={setId} />\n</div>",
87
+ "language": "tsx"
88
+ }
89
+ ],
90
+ "status": "stable",
91
+ "url": "/docs/components/event-row",
92
+ "mdUrl": "/docs/components/event-row.md",
93
+ "jsonUrl": "/r/components/event-row.json",
94
+ "whenToUse": [
95
+ "A custom list of typed records that should look like `EventFeed`'s rows: grouped by run, virtualised, or interleaved with headings."
96
+ ],
97
+ "whenNotToUse": [
98
+ "A plain filterable feed. `EventFeed` draws these rows with chips and a keyboard already."
99
+ ],
100
+ "commonMistakes": [
101
+ "Rows in a listbox of your own without `role=\"option\"`. Outside an `EventFeed` a row claims no role, so pass it, and the row then says whether it is selected.",
102
+ "Expecting the row to move the selection from the keyboard. `EventFeed` owns that; a list of your own must too."
103
+ ],
104
+ "specimens": [
105
+ {
106
+ "title": "EventRow",
107
+ "group": "elements",
108
+ "components": [
109
+ "EventRow"
110
+ ],
111
+ "code": "<div role=\"listbox\" aria-label=\"Two run events\" className=\"flex w-full max-w-md flex-col\">\n <EventRow role=\"option\" event={RUN_EVENTS[0]} onSelect={setRunEvent} />\n <EventRow role=\"option\" event={RUN_EVENTS[3]} selected onSelect={setRunEvent} />\n</div>",
112
+ "note": "One event as the feed draws it, for a list of your own: the time, the toned dot, the kind, the title and its preview. The second row is the selected one.",
113
+ "interaction": "click a row: it reports its id through onSelect. Inside an EventFeed the feed owns the keyboard."
114
+ }
115
+ ]
116
+ }
@@ -5,7 +5,7 @@
5
5
  "importPath": "@cueplusplus/ui/elements/generative",
6
6
  "peerDependencies": [],
7
7
  "clientOnly": true,
8
- "description": "The vocabulary a model composes at runtime.\n\nEvery other component in this library is handed props by a programmer, and a\nwrong one costs a type error at the call site. This one is handed a tree by a\nlanguage model over a network, so its whole contract is what it does with\ninput nobody checked. A model emits JSON — 27 intrinsic names, nested — and\n`GenerativeUI` turns it into elements. There is no compile step between the\ntwo and there cannot be one.\n\nThat reverses the usual priorities. The interesting question is not what a\ncorrect spec renders as, it is what an incorrect one does, and the answer is\nthree-fold and never an exception:\n\n- a `$type` from a newer catalogue draws an in-place notice and its siblings\n still render;\n- a spec that is not a component tree at all draws a legible error state,\n never a blank box that looks like a message still streaming;\n- a tree nested deeper than {@link GENERATIVE_MAX_DEPTH} stops and says so,\n rather than exhausting the stack and taking the console with it.\n\nThe root is a plain `<div data-slot=\"generative-ui\" data-aui=\"root\">` and it\nis always there: an unreadable spec draws the error state *inside* it rather\nthan instead of it, so a caller's layout, `className` and ref hold whatever\nthe model sent.\n\n## Why it is not Tailwind\n\nThe stylesheet is plain `[data-aui]` CSS, and the tree it draws carries no\n`class` attribute anywhere. That is upstream's arrangement and it is worth\nkeeping precisely: a widget a model composed has to draw inside whatever\nconsole it was sent to, and a console is very often somebody else's app with\nno utility framework, no shadcn and no design system of its own. The\nconsequence runs all the way down — the icons are hand-drawn rather than\n`lucide-react`, the chart is 300 lines of SVG rather than `recharts`, and\n`./elements/generative` declares no optional peer at all. There is no package\nin the tree whose absence turns a weather card into a stack trace.\n\n```tsx\nimport { GenerativeUI } from \"@cueplusplus/ui/elements/generative\";\nimport \"@cueplusplus/ui/elements/generative.css\";\n```\n\n## Two skins\n\n`skin` and `fidelity` are the same two axes {@link AgentSurface } publishes,\nand for the same reason: the vocabulary has cue's values by default and\nassistant-ui's under `skin=\"aui\"`, which is upstream's own\n`data-aui-theme=\"elements\"` layer — a 20px card, a borderless 12px field, a\npill button. Pass them here when the tree is its own island; leave them off\ninside an `AgentSurface`, which has already stamped the subtree and whose\nvalues inherit through CSS with nothing threaded.",
8
+ "description": "The vocabulary a model composes at runtime.\n\nEvery other component in this library is handed props by a programmer, and a\nwrong one costs a type error at the call site. This one is handed a tree by a\nlanguage model over a network, so its whole contract is what it does with\ninput nobody checked. A model emits JSON — 27 intrinsic names, nested — and\n`GenerativeUI` turns it into elements. There is no compile step between the\ntwo and there cannot be one.\n\nThat reverses the usual priorities. The interesting question is not what a\ncorrect spec renders as, it is what an incorrect one does, and the answer is\nthree-fold and never an exception:\n\n- a `$type` from a newer catalogue draws an in-place notice and its siblings\n still render;\n- a spec that is not a component tree at all draws a legible error state,\n never a blank box that looks like a message still streaming;\n- a tree nested deeper than {@link GENERATIVE_MAX_DEPTH} stops and says so,\n rather than exhausting the stack and taking the console with it.\n\nThe root is a plain `<div data-slot=\"generative-ui\" data-aui=\"root\">` and it\nis always there: an unreadable spec draws the error state *inside* it rather\nthan instead of it, so a caller's layout, `className` and ref hold whatever\nthe model sent.\n\n## Why it is not Tailwind\n\nThe stylesheet is plain `[data-aui]` CSS, and the tree it draws carries no\n`class` attribute anywhere. That is upstream's arrangement and it is worth\nkeeping precisely: a widget a model composed has to draw inside whatever\nconsole it was sent to, and a console is very often somebody else's app with\nno utility framework, no shadcn and no design system of its own. The\nconsequence runs all the way down — the icons are hand-drawn rather than\n`lucide-react`, the chart is 300 lines of SVG rather than `recharts`, and\n`./elements/generative` declares no optional peer at all. There is no package\nin the tree whose absence turns a weather card into a stack trace.\n\n```tsx\nimport { GenerativeUI } from \"@cueplusplus/ui/elements/generative\";\nimport \"@cueplusplus/ui/elements/generative.css\";\n```\n\n## Skins\n\n`skin` and `fidelity` are the same two axes {@link AgentSurface } publishes,\nand for the same reason: the vocabulary has cue's values by default,\nCursor's under `skin=\"cursor\"`, and assistant-ui's under `skin=\"aui\"`, which\nis upstream's own\n`data-aui-theme=\"elements\"` layer — a 20px card, a borderless 12px field, a\npill button. Pass them here when the tree is its own island; leave them off\ninside an `AgentSurface`, which has already stamped the subtree and whose\nvalues inherit through CSS with nothing threaded.",
9
9
  "props": [
10
10
  {
11
11
  "name": "spec",
@@ -62,13 +62,14 @@
62
62
  },
63
63
  {
64
64
  "name": "skin",
65
- "type": "\"cue\" | \"aui\"",
65
+ "type": "\"cursor\" | \"cue\" | \"aui\"",
66
66
  "required": false,
67
67
  "defaultValue": null,
68
- "description": "Which value-set paints this tree: `cue` (the default) or `aui`, which\ninstalls assistant-ui's own surface language. Leave it off inside an\n{@link AgentSurface }, which has stamped the subtree already.",
68
+ "description": "Which value-set paints this tree: `cue` (the default), `aui`, which\ninstalls assistant-ui's own surface language, or `cursor`, Cursor's\nagent-pane values. Leave it off inside an {@link AgentSurface }, which has\nstamped the subtree already.",
69
69
  "control": {
70
70
  "kind": "enum",
71
71
  "members": [
72
+ "cursor",
72
73
  "cue",
73
74
  "aui"
74
75
  ]
@@ -147,6 +147,7 @@
147
147
  "--cue-fg",
148
148
  "--cue-fg-muted",
149
149
  "--cue-font-mono",
150
+ "--cue-ground",
150
151
  "--cue-leading-ui",
151
152
  "--cue-paint-rim-width",
152
153
  "--cue-paint-scrim-filter",
@@ -100,6 +100,7 @@
100
100
  "--cue-style-disabled-fill",
101
101
  "--cue-style-disabled-ink",
102
102
  "--cue-style-disabled-opacity",
103
+ "--cue-style-field-fill",
103
104
  "--cue-style-field-focus-offset",
104
105
  "--cue-style-field-hover-edge",
105
106
  "--cue-style-field-pad",
@@ -96,6 +96,7 @@
96
96
  "--cue-style-disabled-fill",
97
97
  "--cue-style-disabled-ink",
98
98
  "--cue-style-disabled-opacity",
99
+ "--cue-style-field-fill",
99
100
  "--cue-style-field-focus-offset",
100
101
  "--cue-style-field-hover-edge",
101
102
  "--cue-style-field-pad",
@@ -143,6 +143,7 @@
143
143
  "--cue-focus",
144
144
  "--cue-focus-ring",
145
145
  "--cue-font-mono",
146
+ "--cue-ground",
146
147
  "--cue-leading-ui",
147
148
  "--cue-paint-rim-width",
148
149
  "--cue-paint-scrim-filter",
@@ -215,6 +215,7 @@
215
215
  "--cue-focus",
216
216
  "--cue-focus-ring",
217
217
  "--cue-font-mono",
218
+ "--cue-ground",
218
219
  "--cue-hair-strong",
219
220
  "--cue-icon-sm",
220
221
  "--cue-info",
@@ -268,6 +269,7 @@
268
269
  "--cue-style-disabled-ink",
269
270
  "--cue-style-disabled-opacity",
270
271
  "--cue-style-display-variation",
272
+ "--cue-style-field-fill",
271
273
  "--cue-style-field-focus-offset",
272
274
  "--cue-style-field-hover-edge",
273
275
  "--cue-style-field-pad",
@@ -128,6 +128,7 @@
128
128
  "--cue-style-disabled-fill",
129
129
  "--cue-style-disabled-ink",
130
130
  "--cue-style-disabled-opacity",
131
+ "--cue-style-field-fill",
131
132
  "--cue-style-field-focus-offset",
132
133
  "--cue-style-field-hover-edge",
133
134
  "--cue-style-field-pad",
@@ -229,6 +229,7 @@
229
229
  "--cue-focus",
230
230
  "--cue-focus-ring",
231
231
  "--cue-font-mono",
232
+ "--cue-ground",
232
233
  "--cue-icon-sm",
233
234
  "--cue-leading-ui",
234
235
  "--cue-paint-rim-width",
@@ -117,6 +117,7 @@
117
117
  "--cue-style-disabled-fill",
118
118
  "--cue-style-disabled-ink",
119
119
  "--cue-style-disabled-opacity",
120
+ "--cue-style-field-fill",
120
121
  "--cue-style-field-focus-offset",
121
122
  "--cue-style-field-hover-edge",
122
123
  "--cue-style-field-pad",
@@ -150,6 +150,7 @@
150
150
  "--cue-style-disabled-fill",
151
151
  "--cue-style-disabled-ink",
152
152
  "--cue-style-disabled-opacity",
153
+ "--cue-style-field-fill",
153
154
  "--cue-style-field-focus-offset",
154
155
  "--cue-style-field-hover-edge",
155
156
  "--cue-style-field-pad",
@@ -0,0 +1,171 @@
1
+ {
2
+ "name": "PaneSeam",
3
+ "slug": "pane-seam",
4
+ "group": "layout",
5
+ "importPath": "@cueplusplus/ui",
6
+ "peerDependencies": [],
7
+ "clientOnly": true,
8
+ "description": "One accessible seam that resizes one pane, with no dependency (cue-ui-55).\n\n`Resizable` divides a frame between panel groups on `react-resizable-panels`,\nan optional peer. Most consoles need one thing less: a side pane whose edge a\nreader can drag, and move from the keyboard. This is that edge, and nothing\nelse. It owns a number, not a layout: apply `value` to the pane's width (or\nheight) and the seam supplies the rest.\n\nThe rest is the part a hand-written separator forgets. It is a focusable\n`role=\"separator\"` that says its size and its bounds (`aria-valuenow`,\n`-valuemin`, `-valuemax`), so the width is spoken as well as draggable. The\narrows move it by `step`, Shift by `largeStep`, and Home and End jump to the\nbounds. Every value is clamped, so the pane can never squeeze its neighbour\nout of use.",
9
+ "props": [
10
+ {
11
+ "name": "label",
12
+ "type": "string",
13
+ "required": true,
14
+ "defaultValue": null,
15
+ "description": "The name a screen reader lists the seam by: `Resize the inspector`. Required,\nbecause a separator nobody can name is one a keyboard user cannot find.",
16
+ "control": {
17
+ "kind": "string"
18
+ }
19
+ },
20
+ {
21
+ "name": "value",
22
+ "type": "number",
23
+ "required": false,
24
+ "defaultValue": null,
25
+ "description": "The pane's size in pixels, when the caller holds it.",
26
+ "control": {
27
+ "kind": "number"
28
+ }
29
+ },
30
+ {
31
+ "name": "defaultValue",
32
+ "type": "number",
33
+ "required": false,
34
+ "defaultValue": null,
35
+ "description": "The size to start from when nothing controls it. Defaults to `min`.",
36
+ "control": {
37
+ "kind": "number"
38
+ }
39
+ },
40
+ {
41
+ "name": "onValueChange",
42
+ "type": "((value: number) => void)",
43
+ "required": false,
44
+ "defaultValue": null,
45
+ "description": "Called with every new size, already clamped to `min` and `max`.",
46
+ "control": {
47
+ "kind": "callback",
48
+ "fixture": "callback.log"
49
+ }
50
+ },
51
+ {
52
+ "name": "min",
53
+ "type": "number",
54
+ "required": true,
55
+ "defaultValue": null,
56
+ "description": "The smallest the pane may become, in pixels.",
57
+ "control": {
58
+ "kind": "number"
59
+ }
60
+ },
61
+ {
62
+ "name": "max",
63
+ "type": "number",
64
+ "required": true,
65
+ "defaultValue": null,
66
+ "description": "The largest the pane may become, in pixels.",
67
+ "control": {
68
+ "kind": "number"
69
+ }
70
+ },
71
+ {
72
+ "name": "step",
73
+ "type": "number",
74
+ "required": false,
75
+ "defaultValue": "16",
76
+ "description": "How far one arrow press moves the seam, in pixels. Defaults to 16.",
77
+ "control": {
78
+ "kind": "number"
79
+ }
80
+ },
81
+ {
82
+ "name": "largeStep",
83
+ "type": "number",
84
+ "required": false,
85
+ "defaultValue": "64",
86
+ "description": "How far Shift with an arrow moves it, in pixels. Defaults to 64.",
87
+ "control": {
88
+ "kind": "number"
89
+ }
90
+ },
91
+ {
92
+ "name": "orientation",
93
+ "type": "\"horizontal\" | \"vertical\"",
94
+ "required": false,
95
+ "defaultValue": "vertical",
96
+ "description": "`vertical`, the default, divides side-by-side panes and resizes a width;\n`horizontal` divides stacked panes and resizes a height.",
97
+ "control": {
98
+ "kind": "enum",
99
+ "members": [
100
+ "horizontal",
101
+ "vertical"
102
+ ]
103
+ }
104
+ },
105
+ {
106
+ "name": "edge",
107
+ "type": "\"end\" | \"start\"",
108
+ "required": false,
109
+ "defaultValue": "start",
110
+ "description": "Where the pane sits: `start`, the default, before the seam (left, or top),\nor `end`, after it. Moving the seam away from the pane grows it. A vertical\nseam reads the document's direction, so `start` is the right-hand pane\nunder `dir=\"rtl\"`.",
111
+ "control": {
112
+ "kind": "enum",
113
+ "members": [
114
+ "end",
115
+ "start"
116
+ ]
117
+ }
118
+ }
119
+ ],
120
+ "typeReferences": [
121
+ "Omit<React.ComponentPropsWithoutRef<\"div\">, \"children\" | \"defaultValue\" | \"onChange\">"
122
+ ],
123
+ "subcomponents": [],
124
+ "parts": [],
125
+ "variants": {},
126
+ "defaultVariants": {},
127
+ "tokensUsed": [
128
+ "--cue-accent",
129
+ "--cue-border",
130
+ "--cue-focus",
131
+ "--cue-focus-ring",
132
+ "--cue-style-focus-width"
133
+ ],
134
+ "summary": "One accessible seam that resizes one pane, with no dependency.",
135
+ "examples": [
136
+ {
137
+ "title": "Usage",
138
+ "code": "const [width, setWidth] = React.useState(320);\nconst inspector = { width };\n\n<div className=\"flex\">\n <main className=\"min-w-0 flex-1\">…</main>\n <PaneSeam\n label=\"Resize the inspector\"\n edge=\"end\"\n min={240}\n max={640}\n value={width}\n onValueChange={setWidth}\n />\n <aside style={inspector}>…</aside>\n</div>",
139
+ "language": "tsx"
140
+ }
141
+ ],
142
+ "status": "stable",
143
+ "url": "/docs/components/pane-seam",
144
+ "mdUrl": "/docs/components/pane-seam.md",
145
+ "jsonUrl": "/r/components/pane-seam.json",
146
+ "whenToUse": [
147
+ "A side pane whose edge a reader can drag and move from the keyboard: an inspector, a file tree, a thread beside a canvas.",
148
+ "Keeping the layout yours. The seam reports a size and you apply it, so it fits any flex or grid frame."
149
+ ],
150
+ "whenNotToUse": [
151
+ "Several panels that divide one frame by percentage. Use `Resizable`, from `@cueplusplus/ui/layout/resizable`.",
152
+ "A list beside a detail that should stack when narrow. `SplitPane` builds that on this seam."
153
+ ],
154
+ "commonMistakes": [
155
+ "Rendering the seam and not applying its `value`. It moves nothing by itself; put the value on the pane's width or height.",
156
+ "Setting `edge` for the wrong side. `edge=\"end\"` is a pane after the seam, which grows as the seam moves toward the start.",
157
+ "A `label` that names the seam rather than the pane. A screen reader lists it by name, so say what it resizes: `Resize the inspector`."
158
+ ],
159
+ "specimens": [
160
+ {
161
+ "title": "PaneSeam",
162
+ "group": "layout",
163
+ "components": [
164
+ "PaneSeam"
165
+ ],
166
+ "code": "<div className=\"flex h-[9rem] w-full max-w-[36rem] overflow-hidden rounded-(--radius-surface) border border-border\">\n <div className=\"flex min-w-0 flex-1 items-center justify-center font-mono text-(length:--cue-text-ui) text-fg-muted\">\n Patch\n </div>\n <PaneSeam\n label=\"Resize the inspector\"\n edge=\"end\"\n min={160}\n max={360}\n value={inspector}\n onValueChange={setInspector}\n />\n <div\n className=\"flex shrink-0 items-center justify-center font-mono text-(length:--cue-text-ui) text-fg-muted\"\n style={{ width: inspector }}\n >\n Inspector · {inspector}px\n </div>\n</div>",
167
+ "note": "One seam that resizes one pane, with no dependency. It owns a number, not a layout: the inspector below takes the seam's value as its width, and the seam clamps it so the patch list always keeps its room.",
168
+ "interaction": "drag the seam, or tab to it: the arrows move it 16px, Shift+arrow 64px, and Home and End jump to the inspector's narrowest and widest. A screen reader hears the width and its bounds."
169
+ }
170
+ ]
171
+ }
@@ -158,6 +158,7 @@
158
158
  "--cue-style-disabled-fill",
159
159
  "--cue-style-disabled-ink",
160
160
  "--cue-style-disabled-opacity",
161
+ "--cue-style-field-fill",
161
162
  "--cue-style-field-focus-offset",
162
163
  "--cue-style-field-hover-edge",
163
164
  "--cue-style-field-pad",
@@ -177,6 +177,7 @@
177
177
  "--cue-fg",
178
178
  "--cue-fg-muted",
179
179
  "--cue-font-mono",
180
+ "--cue-ground",
180
181
  "--cue-leading-ui",
181
182
  "--cue-paint-rim-width",
182
183
  "--cue-paint-scrim-filter",
@@ -0,0 +1,157 @@
1
+ {
2
+ "name": "QuestionCard",
3
+ "slug": "question-card",
4
+ "group": "elements",
5
+ "importPath": "@cueplusplus/ui/elements",
6
+ "peerDependencies": [
7
+ "lucide-react"
8
+ ],
9
+ "clientOnly": true,
10
+ "description": "An agent's free-text question, answered in place.\n\nThe answer is the caller's to deliver. The card reports it through\n`onAnswer` and says where it has got to from `delivery`: on its way, arrived,\nor not arrived. It never claims more than that.",
11
+ "props": [
12
+ {
13
+ "name": "question",
14
+ "type": "string",
15
+ "required": true,
16
+ "defaultValue": null,
17
+ "description": "What the agent asked, in its own words. It also names the answer field.",
18
+ "control": {
19
+ "kind": "string"
20
+ }
21
+ },
22
+ {
23
+ "name": "context",
24
+ "type": "string",
25
+ "required": false,
26
+ "defaultValue": null,
27
+ "description": "A supporting line under the question: who is asking, or why.",
28
+ "control": {
29
+ "kind": "string"
30
+ }
31
+ },
32
+ {
33
+ "name": "placeholder",
34
+ "type": "string",
35
+ "required": false,
36
+ "defaultValue": null,
37
+ "description": "The field's resting text. Defaults to `QUESTION_LABELS.placeholder`.",
38
+ "control": {
39
+ "kind": "string"
40
+ }
41
+ },
42
+ {
43
+ "name": "answer",
44
+ "type": "string",
45
+ "required": false,
46
+ "defaultValue": null,
47
+ "description": "The answer as the caller holds it. Drawn as sent while `delivery` is\n`sending` or `sent`, and put back in the field when it is `failed`, so a\nretry is one press.",
48
+ "control": {
49
+ "kind": "string"
50
+ }
51
+ },
52
+ {
53
+ "name": "delivery",
54
+ "type": "\"failed\" | \"sending\" | \"sent\"",
55
+ "required": false,
56
+ "defaultValue": null,
57
+ "description": "Where the answer has got to: `sending`, `sent` or `failed`. Unset while\nthe question is still waiting on the person.",
58
+ "control": {
59
+ "kind": "enum",
60
+ "members": [
61
+ "failed",
62
+ "sending",
63
+ "sent"
64
+ ]
65
+ }
66
+ },
67
+ {
68
+ "name": "onAnswer",
69
+ "type": "((answer: string) => void)",
70
+ "required": false,
71
+ "defaultValue": null,
72
+ "description": "Called with the typed answer, trimmed, when the person sends it.",
73
+ "control": {
74
+ "kind": "callback",
75
+ "fixture": "callback.log"
76
+ }
77
+ },
78
+ {
79
+ "name": "onDismiss",
80
+ "type": "(() => void)",
81
+ "required": false,
82
+ "defaultValue": null,
83
+ "description": "Called when the person skips the question. Skip is drawn only when this is set.",
84
+ "control": {
85
+ "kind": "callback",
86
+ "fixture": "callback.log"
87
+ }
88
+ },
89
+ {
90
+ "name": "labels",
91
+ "type": "Partial<QuestionLabels>",
92
+ "required": false,
93
+ "defaultValue": null,
94
+ "description": "Replace any of the card's own copy.",
95
+ "control": {
96
+ "kind": "opaque"
97
+ }
98
+ }
99
+ ],
100
+ "typeReferences": [
101
+ "Omit<React.ComponentPropsWithoutRef<\"div\">, \"children\" | \"onSubmit\">"
102
+ ],
103
+ "subcomponents": [],
104
+ "parts": [],
105
+ "variants": {},
106
+ "defaultVariants": {},
107
+ "tokensUsed": [
108
+ "--cue-fg",
109
+ "--cue-fg-muted",
110
+ "--cue-fg-subtle",
111
+ "--cue-focus",
112
+ "--cue-focus-ring",
113
+ "--cue-radius-overlay",
114
+ "--cue-radius-surface",
115
+ "--cue-style-focus-width",
116
+ "--cue-surface-1",
117
+ "--cue-surface-2",
118
+ "--cue-text-body",
119
+ "--cue-text-ui"
120
+ ],
121
+ "summary": "An agent's free-text question, answered in place, with where the answer has got to.",
122
+ "examples": [
123
+ {
124
+ "title": "Usage",
125
+ "code": "import { QuestionCard } from \"@cueplusplus/ui/elements\";\n\n<QuestionCard\n question=\"Which branch should I deploy?\"\n context=\"Asked by the release agent\"\n onAnswer={(text) => reply(request.id, text)}\n/>\n// While the answer travels, the card shows it and takes no other.\n<QuestionCard question=\"Which branch?\" answer=\"main\" delivery=\"sending\" />",
126
+ "language": "tsx"
127
+ }
128
+ ],
129
+ "status": "stable",
130
+ "url": "/docs/components/question-card",
131
+ "mdUrl": "/docs/components/question-card.md",
132
+ "jsonUrl": "/r/components/question-card.json",
133
+ "whenToUse": [
134
+ "An agent asking something whose answer is a sentence: which branch, what to call the release, what the user meant.",
135
+ "Relaying a remote agent, where the answer can be on its way, arrive, or fail. `delivery` says which."
136
+ ],
137
+ "whenNotToUse": [
138
+ "A question with typed fields, such as a repository, a toggle or a choice. `ElicitationForm` draws those.",
139
+ "A yes or no about running something. `ApprovalCard` draws the decision as buttons."
140
+ ],
141
+ "commonMistakes": [
142
+ "Setting `delivery` to `sent` and treating the question as answered by the agent. Sent says the answer arrived, nothing more.",
143
+ "Dropping `answer` when delivery fails. Pass it back, and the field holds it again so the retry is one press."
144
+ ],
145
+ "specimens": [
146
+ {
147
+ "title": "QuestionCard",
148
+ "group": "elements",
149
+ "components": [
150
+ "QuestionCard"
151
+ ],
152
+ "code": "<Specimens>\n <Specimen label=\"asking\" wide>\n <LiveQuestion />\n </Specimen>\n <Specimen label=\"sending\" wide>\n <QuestionCard\n question=\"Which universe holds the house lights?\"\n answer=\"Universe 1, channels 1 to 12\"\n delivery=\"sending\"\n />\n </Specimen>\n <Specimen label=\"not sent\" wide>\n <QuestionCard\n question=\"Which universe holds the house lights?\"\n answer=\"Universe 1, channels 1 to 12\"\n delivery=\"failed\"\n onAnswer={() => {}}\n />\n </Specimen>\n</Specimens>",
153
+ "note": "An agent's free-text question, answered in place. The answer is the caller's to deliver: the card reports it and says where it has got to. While it travels the card shows it and takes no other, and a failed delivery keeps what was typed, so sending again is one press.",
154
+ "interaction": "type an answer and press Enter to send it; Shift+Enter breaks the line. The first card is live and shows its answer as sent. Skip is drawn only when the question can be skipped."
155
+ }
156
+ ]
157
+ }
@@ -7,7 +7,7 @@
7
7
  "react-resizable-panels"
8
8
  ],
9
9
  "clientOnly": true,
10
- "description": "Split panes the user can drag, on `react-resizable-panels`.\n\n`react-resizable-panels` is an **optional peer**: import this from\n`@cueplusplus/ui/layout/resizable`, never from the core barrel, so an app\nwith no split view never installs one.",
10
+ "description": "Split panes the user can drag, on `react-resizable-panels`.\n\n`react-resizable-panels` is an **optional peer**: import this from\n`@cueplusplus/ui/layout/resizable`, never from the core barrel, so an app\nwith no split view never installs one. For one seam beside one pane,\n`PaneSeam` in the core barrel needs no peer at all.",
11
11
  "props": [],
12
12
  "typeReferences": [],
13
13
  "subcomponents": [
@@ -244,6 +244,7 @@
244
244
  "--cue-style-disabled-fill",
245
245
  "--cue-style-disabled-ink",
246
246
  "--cue-style-disabled-opacity",
247
+ "--cue-style-field-fill",
247
248
  "--cue-style-field-focus-offset",
248
249
  "--cue-style-field-hover-edge",
249
250
  "--cue-style-field-pad",
@@ -182,6 +182,7 @@
182
182
  "--cue-style-disabled-fill",
183
183
  "--cue-style-disabled-ink",
184
184
  "--cue-style-disabled-opacity",
185
+ "--cue-style-field-fill",
185
186
  "--cue-style-field-focus-offset",
186
187
  "--cue-style-field-hover-edge",
187
188
  "--cue-style-field-pad",
@@ -202,6 +202,7 @@
202
202
  "--cue-focus",
203
203
  "--cue-focus-ring",
204
204
  "--cue-font-mono",
205
+ "--cue-ground",
205
206
  "--cue-icon-md",
206
207
  "--cue-icon-sm",
207
208
  "--cue-paint-rest-shade",
@@ -235,6 +236,7 @@
235
236
  "--cue-style-disabled-fill",
236
237
  "--cue-style-disabled-ink",
237
238
  "--cue-style-disabled-opacity",
239
+ "--cue-style-field-fill",
238
240
  "--cue-style-field-focus-offset",
239
241
  "--cue-style-field-hover-edge",
240
242
  "--cue-style-field-pad",
@@ -167,6 +167,7 @@
167
167
  "--cue-fg",
168
168
  "--cue-fg-muted",
169
169
  "--cue-font-mono",
170
+ "--cue-ground",
170
171
  "--cue-leading-ui",
171
172
  "--cue-paint-rim-width",
172
173
  "--cue-paint-scrim-filter",