@cueplusplus/ui 0.1.0 → 0.3.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 (246) hide show
  1. package/CHANGELOG.md +705 -0
  2. package/dist/brand/_chassis.d.ts +54 -0
  3. package/dist/brand/_chassis.js +81 -0
  4. package/dist/brand/_geometry.js +41 -0
  5. package/dist/brand/cue-logotype.d.ts +29 -0
  6. package/dist/brand/cue-logotype.js +60 -0
  7. package/dist/brand/cue-mark.d.ts +30 -0
  8. package/dist/brand/cue-mark.js +61 -0
  9. package/dist/brand/index.d.ts +5 -0
  10. package/dist/brand/plussie.d.ts +67 -0
  11. package/dist/brand/plussie.js +125 -0
  12. package/dist/chat/agent-pile.js +1 -1
  13. package/dist/chat/ask-box.js +2 -2
  14. package/dist/chat/delegation-card.js +1 -1
  15. package/dist/chat/message.js +2 -2
  16. package/dist/chrome/_edge-scroller.d.ts +45 -0
  17. package/dist/chrome/_edge-scroller.js +149 -0
  18. package/dist/chrome/_glyphs.js +19 -1
  19. package/dist/chrome/_tabs-scroll.d.ts +13 -8
  20. package/dist/chrome/_tabs-scroll.js +13 -8
  21. package/dist/chrome/app-bar.d.ts +103 -0
  22. package/dist/chrome/app-bar.js +175 -0
  23. package/dist/chrome/app-shell.d.ts +125 -0
  24. package/dist/chrome/app-shell.js +167 -0
  25. package/dist/chrome/footer.d.ts +75 -0
  26. package/dist/chrome/footer.js +68 -0
  27. package/dist/chrome/index.d.ts +5 -1
  28. package/dist/chrome/index.js +4 -1
  29. package/dist/chrome/navigation-menu.js +1 -1
  30. package/dist/chrome/page-shell.d.ts +1 -1
  31. package/dist/chrome/page-shell.js +15 -5
  32. package/dist/chrome/segmented-control.d.ts +19 -0
  33. package/dist/chrome/segmented-control.js +40 -21
  34. package/dist/chrome/tabs.js +21 -65
  35. package/dist/chrome/toolbar.d.ts +22 -0
  36. package/dist/chrome/toolbar.js +26 -5
  37. package/dist/configurator/_overrides.js +22 -8
  38. package/dist/configurator/configurator.js +1 -1
  39. package/dist/configurator/panel-sections.js +10 -4
  40. package/dist/dmx/channel-matrix.js +1 -1
  41. package/dist/forms/otp-field.js +1 -1
  42. package/dist/index.d.ts +18 -9
  43. package/dist/index.js +16 -10
  44. package/dist/instruments/data-table.js +1 -1
  45. package/dist/instruments/index.d.ts +2 -2
  46. package/dist/instruments/index.js +2 -2
  47. package/dist/instruments/table.d.ts +14 -1
  48. package/dist/instruments/table.js +20 -1
  49. package/dist/layout/carousel.js +1 -1
  50. package/dist/layout/container.d.ts +1 -1
  51. package/dist/layout/container.js +6 -3
  52. package/dist/layout/index.d.ts +3 -3
  53. package/dist/layout/index.js +3 -3
  54. package/dist/layout/pagination.js +1 -1
  55. package/dist/layout/sidebar.d.ts +23 -3
  56. package/dist/layout/sidebar.js +18 -7
  57. package/dist/midi/spectrum-visualizer.js +1 -1
  58. package/dist/midi/timeline-ruler.js +1 -1
  59. package/dist/overlays/command-palette.js +1 -1
  60. package/dist/overlays/dialog.js +1 -1
  61. package/dist/overlays/dropdown-menu.js +2 -2
  62. package/dist/overlays/hover-card.js +1 -1
  63. package/dist/overlays/index.js +1 -1
  64. package/dist/overlays/popover.js +1 -1
  65. package/dist/overlays/sheet.js +1 -1
  66. package/dist/overlays/toast.js +1 -1
  67. package/dist/primitives/chip.d.ts +1 -1
  68. package/dist/primitives/index.d.ts +1 -1
  69. package/dist/primitives/index.js +1 -1
  70. package/dist/primitives/status-dot.d.ts +7 -0
  71. package/dist/primitives/status-dot.js +8 -1
  72. package/dist/styles.css +58 -2
  73. package/dist/system/density.d.ts +4 -1
  74. package/dist/system/density.js +12 -4
  75. package/dist/system/index.d.ts +4 -4
  76. package/dist/system/portal.d.ts +5 -5
  77. package/dist/system/portal.js +30 -11
  78. package/dist/system/prepaint.d.ts +34 -9
  79. package/dist/system/prepaint.js +48 -25
  80. package/dist/system/theme-provider.d.ts +48 -11
  81. package/dist/system/theme-provider.js +109 -35
  82. package/dist/system/use-density.d.ts +3 -3
  83. package/dist/system/use-density.js +16 -6
  84. package/dist/system/use-theme.d.ts +4 -2
  85. package/dist/system/use-theme.js +4 -2
  86. package/dist/theming/_presets.js +133 -5
  87. package/dist/theming/create-theme.d.ts +2 -2
  88. package/dist/theming/create-theme.js +37 -19
  89. package/dist/theming/serialize.d.ts +1 -1
  90. package/dist/theming/serialize.js +25 -1
  91. package/manifest/components/accordion.json +154 -0
  92. package/manifest/components/agent-pile.json +116 -0
  93. package/manifest/components/alert-dialog.json +190 -0
  94. package/manifest/components/app-bar.json +244 -0
  95. package/manifest/components/app-shell.json +291 -0
  96. package/manifest/components/app-window-frame.json +102 -0
  97. package/manifest/components/ask-box.json +209 -0
  98. package/manifest/components/autocomplete.json +197 -0
  99. package/manifest/components/avatar-group.json +72 -0
  100. package/manifest/components/avatar.json +95 -0
  101. package/manifest/components/breadcrumb.json +74 -0
  102. package/manifest/components/button-group.json +74 -0
  103. package/manifest/components/button.json +125 -0
  104. package/manifest/components/calendar.json +65 -0
  105. package/manifest/components/card.json +140 -0
  106. package/manifest/components/carousel.json +200 -0
  107. package/manifest/components/channel-matrix.json +173 -0
  108. package/manifest/components/chart-container.json +111 -0
  109. package/manifest/components/chart-ramp.json +72 -0
  110. package/manifest/components/chart-swatch.json +65 -0
  111. package/manifest/components/chart-tooltip-content.json +114 -0
  112. package/manifest/components/checkbox-group.json +68 -0
  113. package/manifest/components/checkbox.json +93 -0
  114. package/manifest/components/chip.json +132 -0
  115. package/manifest/components/collapsible.json +120 -0
  116. package/manifest/components/color-area.json +59 -0
  117. package/manifest/components/color-field.json +79 -0
  118. package/manifest/components/color-picker.json +175 -0
  119. package/manifest/components/color-slider.json +75 -0
  120. package/manifest/components/color-swatch.json +68 -0
  121. package/manifest/components/colors-section.json +66 -0
  122. package/manifest/components/combobox.json +198 -0
  123. package/manifest/components/command-palette.json +177 -0
  124. package/manifest/components/composer.json +176 -0
  125. package/manifest/components/container.json +60 -0
  126. package/manifest/components/context-menu.json +121 -0
  127. package/manifest/components/copy-button.json +93 -0
  128. package/manifest/components/cue-logotype.json +96 -0
  129. package/manifest/components/cue-mark.json +97 -0
  130. package/manifest/components/cue-portal-frame.json +55 -0
  131. package/manifest/components/data-table-pagination.json +83 -0
  132. package/manifest/components/data-table-toolbar.json +104 -0
  133. package/manifest/components/date-field.json +80 -0
  134. package/manifest/components/date-picker.json +191 -0
  135. package/manifest/components/date-range-picker.json +191 -0
  136. package/manifest/components/delegation-card.json +144 -0
  137. package/manifest/components/density.json +58 -0
  138. package/manifest/components/description-list.json +84 -0
  139. package/manifest/components/dialog.json +198 -0
  140. package/manifest/components/disclosure.json +109 -0
  141. package/manifest/components/dmx-bar.json +94 -0
  142. package/manifest/components/dmx-strip.json +101 -0
  143. package/manifest/components/drawer.json +179 -0
  144. package/manifest/components/dropdown-menu.json +229 -0
  145. package/manifest/components/empty-state.json +90 -0
  146. package/manifest/components/env-var-input.json +150 -0
  147. package/manifest/components/export-dialog.json +84 -0
  148. package/manifest/components/eyebrow.json +56 -0
  149. package/manifest/components/field-description.json +63 -0
  150. package/manifest/components/field-error.json +77 -0
  151. package/manifest/components/field-label.json +63 -0
  152. package/manifest/components/field.json +79 -0
  153. package/manifest/components/file-upload.json +159 -0
  154. package/manifest/components/flow-background.json +50 -0
  155. package/manifest/components/flow-controls.json +50 -0
  156. package/manifest/components/footer.json +112 -0
  157. package/manifest/components/grid.json +81 -0
  158. package/manifest/components/group-bar.json +102 -0
  159. package/manifest/components/hover-card.json +151 -0
  160. package/manifest/components/icon-button.json +88 -0
  161. package/manifest/components/info-tip.json +98 -0
  162. package/manifest/components/input-group.json +91 -0
  163. package/manifest/components/input.json +89 -0
  164. package/manifest/components/item.json +129 -0
  165. package/manifest/components/kbd.json +52 -0
  166. package/manifest/components/link.json +81 -0
  167. package/manifest/components/log-viewer.json +139 -0
  168. package/manifest/components/menubar.json +157 -0
  169. package/manifest/components/message-list.json +100 -0
  170. package/manifest/components/message.json +116 -0
  171. package/manifest/components/meter.json +114 -0
  172. package/manifest/components/multi-select.json +190 -0
  173. package/manifest/components/musical-time-input.json +113 -0
  174. package/manifest/components/navigation-menu.json +226 -0
  175. package/manifest/components/node-card.json +109 -0
  176. package/manifest/components/node-handle.json +69 -0
  177. package/manifest/components/number-field.json +107 -0
  178. package/manifest/components/otp-field.json +128 -0
  179. package/manifest/components/page-shell.json +96 -0
  180. package/manifest/components/pagination.json +92 -0
  181. package/manifest/components/panel-header.json +77 -0
  182. package/manifest/components/panel.json +71 -0
  183. package/manifest/components/password-input.json +119 -0
  184. package/manifest/components/piano-keyboard.json +120 -0
  185. package/manifest/components/plussie.json +111 -0
  186. package/manifest/components/popover.json +193 -0
  187. package/manifest/components/preset-section.json +73 -0
  188. package/manifest/components/progress.json +95 -0
  189. package/manifest/components/radio-group.json +73 -0
  190. package/manifest/components/radio.json +80 -0
  191. package/manifest/components/rating.json +141 -0
  192. package/manifest/components/resizable.json +88 -0
  193. package/manifest/components/row.json +109 -0
  194. package/manifest/components/scroll-area.json +91 -0
  195. package/manifest/components/scrollable-tabs-list.json +83 -0
  196. package/manifest/components/scrub-input.json +200 -0
  197. package/manifest/components/seam-cell.json +75 -0
  198. package/manifest/components/seam-grid.json +75 -0
  199. package/manifest/components/seam-list.json +56 -0
  200. package/manifest/components/search-input.json +134 -0
  201. package/manifest/components/section-header.json +112 -0
  202. package/manifest/components/segmented-control.json +138 -0
  203. package/manifest/components/select.json +194 -0
  204. package/manifest/components/separator.json +53 -0
  205. package/manifest/components/shape-section.json +66 -0
  206. package/manifest/components/sheet.json +186 -0
  207. package/manifest/components/sidebar.json +198 -0
  208. package/manifest/components/signal-edge.json +56 -0
  209. package/manifest/components/skeleton.json +46 -0
  210. package/manifest/components/slider.json +89 -0
  211. package/manifest/components/sparkline.json +76 -0
  212. package/manifest/components/spectrum-visualizer.json +115 -0
  213. package/manifest/components/spinner.json +61 -0
  214. package/manifest/components/stack.json +96 -0
  215. package/manifest/components/stat.json +87 -0
  216. package/manifest/components/status-bar.json +58 -0
  217. package/manifest/components/status-dot.json +78 -0
  218. package/manifest/components/stepper.json +89 -0
  219. package/manifest/components/switch.json +87 -0
  220. package/manifest/components/table-scroll-region.json +69 -0
  221. package/manifest/components/table.json +155 -0
  222. package/manifest/components/tabs.json +145 -0
  223. package/manifest/components/tags-input.json +190 -0
  224. package/manifest/components/terminal-frame.json +119 -0
  225. package/manifest/components/textarea.json +76 -0
  226. package/manifest/components/theme-configurator.json +124 -0
  227. package/manifest/components/theme-provider.json +134 -0
  228. package/manifest/components/threshold-rail.json +160 -0
  229. package/manifest/components/time-field.json +80 -0
  230. package/manifest/components/timeline-ruler.json +139 -0
  231. package/manifest/components/timeline.json +115 -0
  232. package/manifest/components/title-bar.json +82 -0
  233. package/manifest/components/toast.json +130 -0
  234. package/manifest/components/toggle-group.json +106 -0
  235. package/manifest/components/toggle.json +109 -0
  236. package/manifest/components/token-editor.json +90 -0
  237. package/manifest/components/toolbar.json +163 -0
  238. package/manifest/components/tooltip.json +164 -0
  239. package/manifest/components/tree-visibility-toggle.json +84 -0
  240. package/manifest/components/tree.json +140 -0
  241. package/manifest/components/two-step-button.json +113 -0
  242. package/manifest/components/universe-grid.json +127 -0
  243. package/manifest/components/usage-chart.json +124 -0
  244. package/manifest/manifest.json +2142 -0
  245. package/manifest/tokens.json +138 -0
  246. package/package.json +13 -5
@@ -0,0 +1,109 @@
1
+ {
2
+ "name": "Toggle",
3
+ "slug": "toggle",
4
+ "group": "forms",
5
+ "importPath": "@cueplusplus/ui",
6
+ "peerDependencies": [],
7
+ "clientOnly": true,
8
+ "description": "A two-state button: solo, mute, snap-to-grid, \"show hidden\".\n\nDistinct from {@link Switch }, which sets a *setting* and reads as a physical\nthrow; a toggle is a **button that stays down**, so it belongs in a toolbar\nnext to other buttons rather than in a settings list. `aria-pressed` — not\n`aria-checked` — is what says so to assistive technology, and Base UI wires\nthat for us.\n\nInside a {@link ToggleGroup } it inherits the group's density rung and joins\nits roving-focus ring; on its own it is a perfectly good standalone control.",
9
+ "props": [
10
+ {
11
+ "name": "className",
12
+ "type": "string",
13
+ "required": false,
14
+ "defaultValue": null,
15
+ "description": "Extra classes, merged over the recipe."
16
+ },
17
+ {
18
+ "name": "children",
19
+ "type": "ReactNode",
20
+ "required": false,
21
+ "defaultValue": null,
22
+ "description": "The label. Leave it off for an icon-only toggle — and then pass `aria-label`."
23
+ },
24
+ {
25
+ "name": "size",
26
+ "type": "\"sm\" | \"md\" | \"lg\"",
27
+ "required": false,
28
+ "defaultValue": null,
29
+ "description": "Rung of the control ladder. Defaults to the enclosing {@link ToggleGroup }'s\nrung, or `\"md\"` outside one."
30
+ },
31
+ {
32
+ "name": "icon",
33
+ "type": "ElementType<any, keyof IntrinsicElements>",
34
+ "required": false,
35
+ "defaultValue": null,
36
+ "description": "Optional leading icon component (e.g. a lucide icon). Rendered `aria-hidden`\nand sized to the density icon token. With no `children` the toggle collapses\nto a square target instead of a wide pill."
37
+ }
38
+ ],
39
+ "typeReferences": [
40
+ "Omit<BaseToggle.Props, \"className\">"
41
+ ],
42
+ "subcomponents": [],
43
+ "parts": [],
44
+ "variants": {
45
+ "size": [
46
+ "sm",
47
+ "md",
48
+ "lg"
49
+ ],
50
+ "square": [
51
+ "true",
52
+ "false"
53
+ ]
54
+ },
55
+ "defaultVariants": {
56
+ "size": "md",
57
+ "square": "false"
58
+ },
59
+ "tokensUsed": [
60
+ "--cue-accent",
61
+ "--cue-accent-soft",
62
+ "--cue-border",
63
+ "--cue-control-lg",
64
+ "--cue-control-md",
65
+ "--cue-control-sm",
66
+ "--cue-danger",
67
+ "--cue-fg",
68
+ "--cue-fg-muted",
69
+ "--cue-fg-subtle",
70
+ "--cue-font-mono",
71
+ "--cue-icon-md",
72
+ "--cue-icon-sm",
73
+ "--cue-radius-control",
74
+ "--cue-space-3",
75
+ "--cue-space-4",
76
+ "--cue-space-5",
77
+ "--cue-sunken",
78
+ "--cue-surface-2",
79
+ "--cue-text-body",
80
+ "--cue-text-label",
81
+ "--cue-text-ui"
82
+ ],
83
+ "summary": "A two-state button: solo, mute, snap-to-grid, \"show hidden\".",
84
+ "examples": [
85
+ {
86
+ "title": "Usage",
87
+ "code": "<Toggle aria-label=\"Solo\" icon={Headphones} pressed={solo} onPressedChange={setSolo} />\n<Toggle defaultPressed>Snap</Toggle>",
88
+ "language": "tsx"
89
+ }
90
+ ],
91
+ "status": "todo-docs",
92
+ "url": "/docs/components/toggle",
93
+ "mdUrl": "/docs/components/toggle.md",
94
+ "jsonUrl": "/r/components/toggle.json",
95
+ "specimens": [
96
+ {
97
+ "title": "Toggle / ToggleGroup",
98
+ "group": "forms",
99
+ "components": [
100
+ "Toggle",
101
+ "ToggleGroup"
102
+ ],
103
+ "code": "<Specimens>\n <Specimen label=\"off\">\n <Toggle aria-label=\"Highlight\" icon={Lightbulb} />\n </Specimen>\n <Specimen label=\"on\">\n <Toggle aria-label=\"Highlight, on\" icon={Lightbulb} defaultPressed />\n </Specimen>\n <Specimen label=\"with label\">\n <Toggle icon={Lightbulb}>Highlight</Toggle>\n </Specimen>\n <Specimen label=\"disabled\">\n <Toggle aria-label=\"Highlight, disabled\" icon={Lightbulb} disabled />\n </Specimen>\n <Specimen label=\"group\">\n <ToggleGroup aria-label=\"Text style\" defaultValue={[\"bold\"]}>\n <Toggle value=\"bold\" aria-label=\"Bold\" icon={Bold} />\n <Toggle value=\"italic\" aria-label=\"Italic\" icon={Italic} />\n <Toggle value=\"underline\" aria-label=\"Underline\" icon={Underline} />\n </ToggleGroup>\n </Specimen>\n</Specimens>",
104
+ "note": "A button that stays pressed, and a set of them. `aria-pressed` carries the state.",
105
+ "interaction": "hover tints the ground; pressed is accent-soft, on the same ruling as the active tab."
106
+ }
107
+ ],
108
+ "todo": true
109
+ }
@@ -0,0 +1,90 @@
1
+ {
2
+ "name": "TokenEditor",
3
+ "slug": "token-editor",
4
+ "group": "configurator",
5
+ "importPath": "@cueplusplus/ui/configurator",
6
+ "peerDependencies": [
7
+ "react-aria-components"
8
+ ],
9
+ "clientOnly": true,
10
+ "description": "The grouped colour rows.\n\nStateless by design: it renders the values it is handed and reports edits\nback. The configurator owns the override model, and so does anything else\nthat wants to reuse these rows.\n\n`react-aria-components` is an **optional peer** (it arrives with\n`ColorPicker`): import this from `@cueplusplus/ui/configurator`.",
11
+ "props": [
12
+ {
13
+ "name": "values",
14
+ "type": "Record<string, string>",
15
+ "required": true,
16
+ "defaultValue": null,
17
+ "description": "Current values, keyed by `--cue-*` property."
18
+ },
19
+ {
20
+ "name": "overridden",
21
+ "type": "ReadonlySet<string>",
22
+ "required": true,
23
+ "defaultValue": null,
24
+ "description": "Which properties carry an override rather than the preset's value."
25
+ },
26
+ {
27
+ "name": "onTokenChange",
28
+ "type": "(token: string, value: string) => void",
29
+ "required": true,
30
+ "defaultValue": null,
31
+ "description": "Called with the `--cue-*` property and its new value."
32
+ },
33
+ {
34
+ "name": "onTokenReset",
35
+ "type": "(token: string) => void",
36
+ "required": true,
37
+ "defaultValue": null,
38
+ "description": "Called with the `--cue-*` property to put back to the preset's value."
39
+ },
40
+ {
41
+ "name": "groups",
42
+ "type": "readonly TokenGroup[]",
43
+ "required": false,
44
+ "defaultValue": "[\n {\n id: \"ground\",\n label: \"Ground & surfaces\",\n tokens: [\"bg\", \"sunken\", \"surface-1\", \"surface-2\", \"surface-3\", \"data-ground\", \"scrim\"],\n },\n { id: \"ink\", label: \"Ink\", tokens: [\"fg\", \"fg-muted\", \"fg-subtle\"] },\n { id: \"borders\", label: \"Borders\", tokens: [\"border\", \"border-strong\", \"border-overlay\"] },\n {\n id: \"accent\",\n label: \"Accent\",\n tokens: [\"accent\", \"accent-hover\", \"accent-fg\", \"focus\", \"selection\"],\n },\n { id: \"status\", label: \"Status\", tokens: [\"ok\", \"busy\", \"warn\", \"danger\", \"info\"] },\n]",
45
+ "description": "Groups to render. Defaults to {@link COLOR_TOKEN_GROUPS}."
46
+ },
47
+ {
48
+ "name": "className",
49
+ "type": "string",
50
+ "required": false,
51
+ "defaultValue": null,
52
+ "description": "Extra classes for the list."
53
+ }
54
+ ],
55
+ "typeReferences": [],
56
+ "subcomponents": [],
57
+ "parts": [],
58
+ "variants": {},
59
+ "defaultVariants": {},
60
+ "tokensUsed": [
61
+ "--cue-accent",
62
+ "--cue-control-sm",
63
+ "--cue-fg",
64
+ "--cue-fg-muted",
65
+ "--cue-fg-subtle",
66
+ "--cue-font-mono",
67
+ "--cue-font-pairing-mono",
68
+ "--cue-font-sans",
69
+ "--cue-font-scale",
70
+ "--cue-font-theme-mono",
71
+ "--cue-radius-scale",
72
+ "--cue-space-2",
73
+ "--cue-space-4",
74
+ "--cue-text-label",
75
+ "--cue-text-micro"
76
+ ],
77
+ "summary": "The grouped colour rows.",
78
+ "examples": [
79
+ {
80
+ "title": "Usage",
81
+ "code": "<TokenEditor\n values={resolvedTokens(overrides, scope)}\n overridden={new Set(Object.keys(overrides.themes[scopeKey(scope)] ?? {}))}\n onTokenChange={(token, value) => setOverrides(setOverride(overrides, scope, token, value))}\n onTokenReset={(token) => setOverrides(clearOverride(overrides, scope, token))}\n/>",
82
+ "language": "tsx"
83
+ }
84
+ ],
85
+ "status": "todo-docs",
86
+ "url": "/docs/components/token-editor",
87
+ "mdUrl": "/docs/components/token-editor.md",
88
+ "jsonUrl": "/r/components/token-editor.json",
89
+ "todo": true
90
+ }
@@ -0,0 +1,163 @@
1
+ {
2
+ "name": "Toolbar",
3
+ "slug": "toolbar",
4
+ "group": "chrome",
5
+ "importPath": "@cueplusplus/ui",
6
+ "peerDependencies": [],
7
+ "clientOnly": true,
8
+ "description": "The strip of controls across the top of a view.\n\nWraps Base UI's `Toolbar`, so the whole bar is one tab stop with arrow-key\nroving focus inside it — which is the entire point of the ARIA toolbar\npattern and the reason not to hand-roll this out of a flex row of buttons.",
9
+ "props": [],
10
+ "typeReferences": [],
11
+ "subcomponents": [
12
+ "Root",
13
+ "Button",
14
+ "Group",
15
+ "Separator"
16
+ ],
17
+ "parts": [
18
+ {
19
+ "name": "Root",
20
+ "usage": "Toolbar.Root",
21
+ "description": "The bar itself: chrome-toolbar tall, hairline underneath, surface fill.\n\nHeight comes from `--cue-chrome-toolbar`, which is a *chrome* token rather\nthan a control token — the bar is part of the window furniture and gets its\nown rung of the density ladder, one that stays legible when the controls\ninside it shrink.\n\nThe bar element is also its own scroller, rather than sitting inside one:\nthat is what keeps the height, the hairline and the fill on the element with\n`role=\"toolbar\"`, so a bar that overflows still looks like one bar rather\nthan a strip inside a box. The wrapper the scrolling shape adds is an\nunpainted `relative` frame whose only job is to hold the pager chevrons.\n\nGive it an `aria-label`: a toolbar with no name is announced as \"toolbar\".",
22
+ "props": [
23
+ {
24
+ "name": "className",
25
+ "type": "string",
26
+ "required": false,
27
+ "defaultValue": null,
28
+ "description": "Extra classes for the bar."
29
+ },
30
+ {
31
+ "name": "overflow",
32
+ "type": "\"clip\" | \"scroll\"",
33
+ "required": false,
34
+ "defaultValue": "scroll",
35
+ "description": "What the bar does when its controls do not fit. Defaults to `\"scroll\"`.\n\n`\"scroll\"` is the library's one overflow behaviour (see\n`./_edge-scroller` for why it is scrolling rather than wrapping or a \"more\"\nmenu): the bar keeps its single chrome-rung height, the controls scroll\ninside it, the overflowing edge is faded and a pager chevron appears there.\nA bar whose controls all fit renders exactly as it did before — no mask, no\nchevrons, no compositing layer.\n\n`\"clip\"` restores the old behaviour and adds no wrapper element, for a bar\nthat is already inside something which scrolls.\n\nA vertical toolbar ignores this: the affordance is horizontal, and a\nvertical bar overflows on the axis this does not measure."
36
+ },
37
+ {
38
+ "name": "previousLabel",
39
+ "type": "string",
40
+ "required": false,
41
+ "defaultValue": "Show earlier controls",
42
+ "description": "Accessible name for the chevron that reveals controls off the leading edge."
43
+ },
44
+ {
45
+ "name": "nextLabel",
46
+ "type": "string",
47
+ "required": false,
48
+ "defaultValue": "Show later controls",
49
+ "description": "Accessible name for the chevron that reveals controls off the trailing edge."
50
+ }
51
+ ],
52
+ "typeReferences": [
53
+ "Omit<BaseToolbar.Root.Props, \"className\">"
54
+ ]
55
+ },
56
+ {
57
+ "name": "Button",
58
+ "usage": "Toolbar.Button",
59
+ "description": "A borderless toolbar control.\n\nDeliberately not a `Button`: inside a bar, six rimmed buttons in a row read\nas six competing objects. Toolbar controls speak through text colour and a\nhover fill only (the venu convention), which keeps the bar reading as one\nstrip. Reach for `<Toolbar.Button render={<Button variant=\"primary\" />}>`\nwhen exactly one action in the bar must be loud.",
60
+ "props": [
61
+ {
62
+ "name": "className",
63
+ "type": "string",
64
+ "required": false,
65
+ "defaultValue": null,
66
+ "description": "Extra classes for the button."
67
+ },
68
+ {
69
+ "name": "icon",
70
+ "type": "ElementType<any, keyof IntrinsicElements>",
71
+ "required": false,
72
+ "defaultValue": null,
73
+ "description": "Optional leading icon (e.g. a lucide icon), drawn `aria-hidden`."
74
+ }
75
+ ],
76
+ "typeReferences": [
77
+ "Omit<BaseToolbar.Button.Props, \"className\">"
78
+ ]
79
+ },
80
+ {
81
+ "name": "Group",
82
+ "usage": "Toolbar.Group",
83
+ "description": "A tight cluster of related controls inside the bar.",
84
+ "props": [
85
+ {
86
+ "name": "className",
87
+ "type": "string",
88
+ "required": false,
89
+ "defaultValue": null,
90
+ "description": "Extra classes for the group."
91
+ }
92
+ ],
93
+ "typeReferences": [
94
+ "Omit<BaseToolbar.Group.Props, \"className\">"
95
+ ]
96
+ },
97
+ {
98
+ "name": "Separator",
99
+ "usage": "Toolbar.Separator",
100
+ "description": "A hairline between clusters. Base UI orients it perpendicular to the bar, so\na horizontal toolbar gets a vertical rule with no prop to remember; the\nclasses follow `data-orientation` for the same reason.",
101
+ "props": [
102
+ {
103
+ "name": "className",
104
+ "type": "string",
105
+ "required": false,
106
+ "defaultValue": null,
107
+ "description": "Extra classes for the rule."
108
+ }
109
+ ],
110
+ "typeReferences": [
111
+ "Omit<BaseToolbar.Separator.Props, \"className\">"
112
+ ]
113
+ }
114
+ ],
115
+ "variants": {},
116
+ "defaultVariants": {},
117
+ "tokensUsed": [
118
+ "--cue-accent",
119
+ "--cue-border",
120
+ "--cue-chrome-toolbar",
121
+ "--cue-control-md",
122
+ "--cue-edge-fade",
123
+ "--cue-fg",
124
+ "--cue-fg-muted",
125
+ "--cue-font-mono",
126
+ "--cue-icon-md",
127
+ "--cue-icon-sm",
128
+ "--cue-pad-row-x",
129
+ "--cue-radius-control",
130
+ "--cue-space-1",
131
+ "--cue-space-2",
132
+ "--cue-space-3",
133
+ "--cue-space-5",
134
+ "--cue-surface-1",
135
+ "--cue-surface-2",
136
+ "--cue-text-ui"
137
+ ],
138
+ "summary": "The strip of controls across the top of a view.",
139
+ "examples": [
140
+ {
141
+ "title": "Usage",
142
+ "code": "<Toolbar.Root aria-label=\"Cue actions\">\n <Toolbar.Group aria-label=\"Playback\">\n <Toolbar.Button icon={Play}>Go</Toolbar.Button>\n <Toolbar.Button icon={Square}>Stop</Toolbar.Button>\n </Toolbar.Group>\n <Toolbar.Separator />\n <Toolbar.Button icon={Save}>Save</Toolbar.Button>\n</Toolbar.Root>",
143
+ "language": "tsx"
144
+ }
145
+ ],
146
+ "status": "todo-docs",
147
+ "url": "/docs/components/toolbar",
148
+ "mdUrl": "/docs/components/toolbar.md",
149
+ "jsonUrl": "/r/components/toolbar.json",
150
+ "specimens": [
151
+ {
152
+ "title": "Toolbar",
153
+ "group": "chrome",
154
+ "components": [
155
+ "Toolbar"
156
+ ],
157
+ "code": "<div className=\"flex w-full flex-col gap-(--cue-space-4)\">\n <Toolbar.Root aria-label=\"Text formatting\">\n <Toolbar.Group>\n <Toolbar.Button icon={Bold} aria-label=\"Bold\" />\n <Toolbar.Button icon={Italic} aria-label=\"Italic\" />\n <Toolbar.Button icon={Underline} aria-label=\"Underline\" />\n </Toolbar.Group>\n <Toolbar.Separator />\n <Toolbar.Group>\n <Toolbar.Button icon={List}>Cue list</Toolbar.Button>\n <Toolbar.Button icon={Monitor} disabled>\n Preview\n </Toolbar.Button>\n </Toolbar.Group>\n </Toolbar.Root>\n\n <div className=\"w-full max-w-[16rem] overflow-hidden rounded-(--radius-surface) border border-border\">\n <Toolbar.Root aria-label=\"Playback, boxed\">\n <Toolbar.Button icon={List}>Cue list</Toolbar.Button>\n <Toolbar.Separator />\n <Toolbar.Button icon={Monitor}>Preview</Toolbar.Button>\n <Toolbar.Button icon={Plus}>Add cue</Toolbar.Button>\n <Toolbar.Button icon={Eye}>Blind</Toolbar.Button>\n </Toolbar.Root>\n </div>\n</div>",
158
+ "note": "Borderless text-colour feedback: a pressed tool changes ink, not ground. Boxed to 16rem below, the bar scrolls rather than clipping — it stays one chrome rung tall, because a second row would be stolen from the work area.",
159
+ "interaction": "hover lifts the ink to `--cue-fg`; arrow keys move between tools and reach the ones off-screen, Tab leaves the toolbar."
160
+ }
161
+ ],
162
+ "todo": true
163
+ }
@@ -0,0 +1,164 @@
1
+ {
2
+ "name": "Tooltip",
3
+ "slug": "tooltip",
4
+ "group": "overlays",
5
+ "importPath": "@cueplusplus/ui",
6
+ "peerDependencies": [],
7
+ "clientOnly": true,
8
+ "description": "A short label revealed on hover or keyboard focus — what an icon-only control\ndoes, what an abbreviated column header means.\n\nWraps Base UI's `Tooltip` and adds the two things a design system must not\nleave to the caller: the `role=\"tooltip\"` / `aria-describedby` pairing, and\nthe portal theme stamp. For anything longer than a label, reach for\n{@link InfoTip } (a focusable badge) or a `Popover` instead — hover-only\ncontent is unreachable on touch.",
9
+ "props": [],
10
+ "typeReferences": [],
11
+ "subcomponents": [
12
+ "Provider",
13
+ "Root",
14
+ "Trigger",
15
+ "Content"
16
+ ],
17
+ "parts": [
18
+ {
19
+ "name": "Provider",
20
+ "usage": "Tooltip.Provider",
21
+ "description": "Shares one hover delay across a group of tooltips: once the first one has\nopened, its neighbours open instantly, so scanning a toolbar does not mean\nwaiting out the delay at every button.",
22
+ "props": [],
23
+ "typeReferences": [
24
+ "BaseTooltip.Provider.Props"
25
+ ]
26
+ },
27
+ {
28
+ "name": "Root",
29
+ "usage": "Tooltip.Root",
30
+ "description": "Groups the parts of one tooltip. Renders no element.",
31
+ "props": [],
32
+ "typeReferences": [
33
+ "BaseTooltip.Root.Props"
34
+ ]
35
+ },
36
+ {
37
+ "name": "Trigger",
38
+ "usage": "Tooltip.Trigger",
39
+ "description": "The element the tooltip describes. A `<button>` by default; pass\n`render={…}` to attach the tooltip to something else.\n\nOpens on hover after {@link TooltipTriggerProps.delay} and instantly on\nkeyboard focus — a tooltip nobody can reach with the keyboard is a decoration.",
40
+ "props": [],
41
+ "typeReferences": [
42
+ "BaseTooltip.Trigger.Props"
43
+ ]
44
+ },
45
+ {
46
+ "name": "Content",
47
+ "usage": "Tooltip.Content",
48
+ "description": "The tooltip's portal, positioner and popup.\n\nCarries `role=\"tooltip\"` and the id the trigger describes itself with.\nPortalled through {@link useCuePortalProps} so it renders in the caller's\ntheme and density.",
49
+ "props": [
50
+ {
51
+ "name": "className",
52
+ "type": "string",
53
+ "required": false,
54
+ "defaultValue": null,
55
+ "description": "Extra classes for the popup surface."
56
+ },
57
+ {
58
+ "name": "align",
59
+ "type": "\"center\" | \"end\" | \"start\"",
60
+ "required": false,
61
+ "defaultValue": null,
62
+ "description": "Alignment along that side. Defaults to `\"center\"`."
63
+ },
64
+ {
65
+ "name": "keepMounted",
66
+ "type": "boolean",
67
+ "required": false,
68
+ "defaultValue": null,
69
+ "description": "Keep the popup mounted while closed."
70
+ },
71
+ {
72
+ "name": "positionerClassName",
73
+ "type": "string",
74
+ "required": false,
75
+ "defaultValue": null,
76
+ "description": "Extra classes for the positioner that places the popup."
77
+ },
78
+ {
79
+ "name": "sideOffset",
80
+ "type": "number | OffsetFunction",
81
+ "required": false,
82
+ "defaultValue": "4",
83
+ "description": "Gap in px between trigger and popup. Defaults to `4`."
84
+ },
85
+ {
86
+ "name": "side",
87
+ "type": "\"left\" | \"right\" | \"top\" | \"bottom\" | \"inline-end\" | \"inline-start\"",
88
+ "required": false,
89
+ "defaultValue": "top",
90
+ "description": "Preferred side of the trigger. Defaults to `\"top\"`."
91
+ },
92
+ {
93
+ "name": "alignOffset",
94
+ "type": "number | OffsetFunction",
95
+ "required": false,
96
+ "defaultValue": null,
97
+ "description": "Nudge along the alignment axis, in px."
98
+ }
99
+ ],
100
+ "typeReferences": [
101
+ "Omit<BaseTooltip.Popup.Props, \"className\">"
102
+ ]
103
+ }
104
+ ],
105
+ "variants": {},
106
+ "defaultVariants": {},
107
+ "tokensUsed": [
108
+ "--cue-accent-soft",
109
+ "--cue-border",
110
+ "--cue-border-overlay",
111
+ "--cue-control-sm",
112
+ "--cue-fg",
113
+ "--cue-fg-muted",
114
+ "--cue-fg-subtle",
115
+ "--cue-font-mono",
116
+ "--cue-radius-control",
117
+ "--cue-radius-overlay",
118
+ "--cue-scrim",
119
+ "--cue-space-1",
120
+ "--cue-space-2",
121
+ "--cue-space-3",
122
+ "--cue-surface-2",
123
+ "--cue-text-emphasis",
124
+ "--cue-text-label",
125
+ "--cue-text-ui"
126
+ ],
127
+ "summary": "A short description of the control under the pointer or the focus ring.",
128
+ "examples": [
129
+ {
130
+ "title": "Usage",
131
+ "code": "<Tooltip.Root>\n <Tooltip.Trigger render={<IconButton aria-label=\"Blackout\" icon={Power} />} />\n <Tooltip.Content>Fades every channel to zero</Tooltip.Content>\n</Tooltip.Root>",
132
+ "language": "tsx"
133
+ }
134
+ ],
135
+ "status": "stable",
136
+ "url": "/docs/components/tooltip",
137
+ "mdUrl": "/docs/components/tooltip.md",
138
+ "jsonUrl": "/r/components/tooltip.json",
139
+ "whenToUse": [
140
+ "Naming an icon-only control, or adding the keyboard shortcut for it.",
141
+ "Around a cluster of them, `Tooltip.Provider` so the open delay is paid once for the whole toolbar."
142
+ ],
143
+ "whenNotToUse": [
144
+ "Information the user actually needs. A tooltip is unreachable on touch; put it in the page, or use `InfoTip`.",
145
+ "Anything interactive. Nothing inside a tooltip can be clicked."
146
+ ],
147
+ "commonMistakes": [
148
+ "Attaching one to an element that cannot take focus, which hides it from every keyboard user.",
149
+ "Repeating the visible label of the control it points at."
150
+ ],
151
+ "specimens": [
152
+ {
153
+ "title": "Tooltip / InfoTip",
154
+ "group": "overlays",
155
+ "components": [
156
+ "Tooltip",
157
+ "InfoTip"
158
+ ],
159
+ "code": "<Tooltip.Provider>\n <Specimens>\n <Specimen label=\"tooltip\">\n <Tooltip.Root>\n <Tooltip.Trigger render={<IconButton aria-label=\"Go\" icon={Play} />} />\n <Tooltip.Content>Fire the selected cue</Tooltip.Content>\n </Tooltip.Root>\n </Specimen>\n <Specimen label=\"side bottom\">\n <Tooltip.Root>\n <Tooltip.Trigger render={<IconButton aria-label=\"Copy address\" icon={Copy} />} />\n <Tooltip.Content side=\"bottom\">Copy 10.0.0.42</Tooltip.Content>\n </Tooltip.Root>\n </Specimen>\n <Specimen label=\"info tip\">\n <span className=\"flex items-center gap-(--cue-space-2) font-mono text-(length:--cue-text-ui) text-fg-muted\">\n Pace tick\n <InfoTip text=\"Where the meter would be if usage were flat across the period.\" />\n </span>\n </Specimen>\n <Specimen label=\"wide info tip\">\n <InfoTip\n width={320}\n label=\"About provenance\"\n text=\"Vendor numbers are measured, estimated ones are hatched, and an unbounded meter draws no percentage at all.\"\n />\n </Specimen>\n </Specimens>\n</Tooltip.Provider>",
160
+ "note": "A tooltip names a control; an InfoTip is the 13px `i` badge that explains one.",
161
+ "interaction": "tooltips open on hover and on keyboard focus, and never on touch; the InfoTip badge is a real button."
162
+ }
163
+ ]
164
+ }
@@ -0,0 +1,84 @@
1
+ {
2
+ "name": "TreeVisibilityToggle",
3
+ "slug": "tree-visibility-toggle",
4
+ "group": "chrome",
5
+ "importPath": "@cueplusplus/ui",
6
+ "peerDependencies": [],
7
+ "clientOnly": true,
8
+ "description": "The outliner's three-state visibility control: shown → ghosted → hidden.\n\nThree states rather than a checkbox because a rig has three answers, not two:\n*there*, *there but out of the way*, and *not drawn*. Ghost is the one that\nearns the extra state — it is how you keep a truss as spatial reference while\nworking behind it — and collapsing it into \"hidden\" is what makes people\ntoggle things off and lose their bearings.\n\nMeant for {@link TreeProps.rowControls}. The accessible name states the\n*current* state (\"Visibility: ghosted\") rather than the next action, because\nwith three states \"toggle\" names nothing useful; pressing cycles.",
9
+ "props": [
10
+ {
11
+ "name": "value",
12
+ "type": "\"hidden\" | \"visible\" | \"ghost\"",
13
+ "required": true,
14
+ "defaultValue": null,
15
+ "description": "The node's current visibility."
16
+ },
17
+ {
18
+ "name": "onValueChange",
19
+ "type": "(value: TreeVisibility) => void",
20
+ "required": true,
21
+ "defaultValue": null,
22
+ "description": "Called with the next state in the cycle."
23
+ },
24
+ {
25
+ "name": "labels",
26
+ "type": "Partial<Record<TreeVisibility, string>>",
27
+ "required": false,
28
+ "defaultValue": null,
29
+ "description": "Override the state names used in the accessible label."
30
+ }
31
+ ],
32
+ "typeReferences": [
33
+ "Omit<React.ComponentPropsWithoutRef<\"button\">, \"value\" | \"onChange\" | \"children\">"
34
+ ],
35
+ "subcomponents": [],
36
+ "parts": [],
37
+ "variants": {},
38
+ "defaultVariants": {},
39
+ "tokensUsed": [
40
+ "--cue-accent",
41
+ "--cue-accent-soft",
42
+ "--cue-control-sm",
43
+ "--cue-fg",
44
+ "--cue-fg-muted",
45
+ "--cue-fg-subtle",
46
+ "--cue-font-mono",
47
+ "--cue-icon-md",
48
+ "--cue-icon-sm",
49
+ "--cue-info",
50
+ "--cue-radius-control",
51
+ "--cue-space-1",
52
+ "--cue-space-2",
53
+ "--cue-space-4",
54
+ "--cue-surface-2",
55
+ "--cue-text-ui",
56
+ "--cue-warn"
57
+ ],
58
+ "summary": "The outliner's three-state visibility control: shown → ghosted → hidden.",
59
+ "examples": [
60
+ {
61
+ "title": "Usage",
62
+ "code": "<TreeVisibilityToggle value={state} onValueChange={setState} />",
63
+ "language": "tsx"
64
+ }
65
+ ],
66
+ "status": "todo-docs",
67
+ "url": "/docs/components/tree-visibility-toggle",
68
+ "mdUrl": "/docs/components/tree-visibility-toggle.md",
69
+ "jsonUrl": "/r/components/tree-visibility-toggle.json",
70
+ "specimens": [
71
+ {
72
+ "title": "Tree",
73
+ "group": "chrome",
74
+ "components": [
75
+ "Tree",
76
+ "TreeVisibilityToggle"
77
+ ],
78
+ "code": "<Panel className=\"w-full max-w-[30rem] p-(--cue-space-2)\">\n <Tree\n items={TREE_ITEMS}\n expanded={expanded}\n onExpandedChange={setExpanded}\n selected={selected}\n onSelect={setSelected}\n rowControls={(item) => (\n <TreeVisibilityToggle\n value={visibility[item.id] ?? \"visible\"}\n onValueChange={(next) =>\n setVisibility((current) => ({ ...current, [item.id]: next }))\n }\n />\n )}\n />\n</Panel>",
79
+ "note": "Roving tabindex, `└` indent guides, a hover-revealed control slot and the three-state visibility toggle.",
80
+ "interaction": "arrow keys move and expand, Enter selects; the row controls appear on hover and stay put for keyboard users."
81
+ }
82
+ ],
83
+ "todo": true
84
+ }