@gradeui/ui 0.10.0 → 1.0.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 (83) hide show
  1. package/components/ui/accordion.md +1 -1
  2. package/components/ui/ai-chat-composer.md +37 -0
  3. package/components/ui/ai-chat.md +68 -22
  4. package/components/ui/alert.md +0 -21
  5. package/components/ui/app-shell.md +135 -18
  6. package/components/ui/avatar.md +12 -1
  7. package/components/ui/badge.md +2 -2
  8. package/components/ui/breadcrumb.md +49 -2
  9. package/components/ui/button.md +35 -3
  10. package/components/ui/calendar.md +1 -1
  11. package/components/ui/callout.md +45 -0
  12. package/components/ui/card.md +16 -1
  13. package/components/ui/carousel.md +56 -0
  14. package/components/ui/chart.md +1 -1
  15. package/components/ui/checkbox.md +1 -0
  16. package/components/ui/collapsible.md +1 -1
  17. package/components/ui/command.md +1 -1
  18. package/components/ui/date-picker.md +1 -1
  19. package/components/ui/dialog.md +13 -2
  20. package/components/ui/dropdown-menu.md +7 -1
  21. package/components/ui/flex.md +1 -1
  22. package/components/ui/grid.md +1 -1
  23. package/components/ui/hover-card.md +1 -1
  24. package/components/ui/input.md +1 -1
  25. package/components/ui/label.md +1 -0
  26. package/components/ui/map.md +2 -2
  27. package/components/ui/media-surface.md +50 -7
  28. package/components/ui/multi-select.md +114 -0
  29. package/components/ui/popover.md +8 -1
  30. package/components/ui/progress.md +1 -0
  31. package/components/ui/radio-group.md +1 -1
  32. package/components/ui/resizable.md +1 -1
  33. package/components/ui/row.md +1 -1
  34. package/components/ui/scroll-area.md +1 -1
  35. package/components/ui/select.md +1 -1
  36. package/components/ui/separator.md +1 -1
  37. package/components/ui/sheet.md +7 -1
  38. package/components/ui/side-menu.md +0 -40
  39. package/components/ui/sidebar.md +121 -0
  40. package/components/ui/simple-tabs.md +0 -27
  41. package/components/ui/skeleton.md +1 -1
  42. package/components/ui/slider.md +1 -1
  43. package/components/ui/sortable.md +101 -0
  44. package/components/ui/stack.md +19 -1
  45. package/components/ui/switch.md +1 -1
  46. package/components/ui/table.md +1 -0
  47. package/components/ui/tabs.md +19 -2
  48. package/components/ui/textarea.md +1 -1
  49. package/components/ui/toast.md +2 -2
  50. package/components/ui/toggle-group.md +12 -5
  51. package/components/ui/toolbar.md +167 -0
  52. package/components/ui/tooltip.md +1 -1
  53. package/components/ui/video-player.md +2 -2
  54. package/dist/contracts.d.mts +14 -0
  55. package/dist/contracts.d.ts +14 -0
  56. package/dist/contracts.js +63 -0
  57. package/dist/contracts.js.map +1 -0
  58. package/dist/contracts.mjs +63 -0
  59. package/dist/contracts.mjs.map +1 -0
  60. package/dist/index.d.mts +1327 -179
  61. package/dist/index.d.ts +1327 -179
  62. package/dist/index.js +111 -49
  63. package/dist/index.js.map +1 -1
  64. package/dist/index.mjs +111 -49
  65. package/dist/index.mjs.map +1 -1
  66. package/dist/map/google.js +1 -0
  67. package/dist/map/google.js.map +1 -1
  68. package/dist/map/google.mjs +1 -0
  69. package/dist/map/google.mjs.map +1 -1
  70. package/dist/map/mapbox.js +1 -0
  71. package/dist/map/mapbox.js.map +1 -1
  72. package/dist/map/mapbox.mjs +1 -0
  73. package/dist/map/mapbox.mjs.map +1 -1
  74. package/dist/map/maplibre.js +1 -0
  75. package/dist/map/maplibre.js.map +1 -1
  76. package/dist/map/maplibre.mjs +1 -0
  77. package/dist/map/maplibre.mjs.map +1 -1
  78. package/dist/styles.css +1 -1
  79. package/dist/tailwind-preset.js +1 -1
  80. package/dist/tailwind-preset.js.map +1 -1
  81. package/dist/tailwind-preset.mjs +1 -1
  82. package/dist/tailwind-preset.mjs.map +1 -1
  83. package/package.json +24 -9
package/dist/index.d.ts CHANGED
@@ -1,9 +1,13 @@
1
+ import * as _gradeui_contracts from '@gradeui/contracts';
2
+ import { ComponentContract } from '@gradeui/contracts';
3
+ import { z } from 'zod';
1
4
  import * as React$1 from 'react';
2
5
  import * as AccordionPrimitive from '@radix-ui/react-accordion';
3
6
  import * as class_variance_authority_types from 'class-variance-authority/types';
4
7
  import { VariantProps } from 'class-variance-authority';
5
8
  import * as AvatarPrimitive from '@radix-ui/react-avatar';
6
9
  import { DayPicker, DayButton, DateRange } from 'react-day-picker';
10
+ import { UseEmblaCarouselType } from 'embla-carousel-react';
7
11
  import * as CheckboxPrimitive from '@radix-ui/react-checkbox';
8
12
  import * as DialogPrimitive from '@radix-ui/react-dialog';
9
13
  import * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';
@@ -16,6 +20,7 @@ import * as ScrollAreaPrimitive from '@radix-ui/react-scroll-area';
16
20
  import * as SelectPrimitive from '@radix-ui/react-select';
17
21
  import * as SeparatorPrimitive from '@radix-ui/react-separator';
18
22
  import * as SliderPrimitive from '@radix-ui/react-slider';
23
+ import { UniqueIdentifier } from '@dnd-kit/core';
19
24
  import * as SwitchPrimitives from '@radix-ui/react-switch';
20
25
  import * as TabsPrimitive from '@radix-ui/react-tabs';
21
26
  import * as TogglePrimitive from '@radix-ui/react-toggle';
@@ -26,16 +31,361 @@ export { C as Coords, c as MapAppearance, d as MapError, e as MapErrorCode } fro
26
31
  import * as THREE from 'three';
27
32
  import { ClassValue } from 'clsx';
28
33
 
34
+ /**
35
+ * Component contract registry — auto-managed by
36
+ * scripts/generate-contracts.mjs. Hand-authored contracts (MediaSurface,
37
+ * etc.) are also wired in here; the generator preserves them on each
38
+ * run.
39
+ */
40
+
41
+ declare const COMPONENT_CONTRACTS: Readonly<Record<string, ComponentContract>>;
42
+ declare function getComponentContract(componentName: string | null | undefined): ComponentContract | null;
43
+ declare function listContractedComponents(): string[];
44
+
45
+ declare const MediaSurfaceContract: _gradeui_contracts.ComponentContract<{
46
+ hint: {
47
+ schema: z.ZodOptional<z.ZodEnum<["album", "tv-show", "movie", "game", "book", "portrait", "landscape", "poster", "product", "food", "video", "audio", "embed", "3d", "generic"]>>;
48
+ design: "knob";
49
+ control: "glyph-picker";
50
+ label: string;
51
+ description: string;
52
+ default: string;
53
+ examples: string[];
54
+ };
55
+ aspect: {
56
+ schema: z.ZodOptional<z.ZodEnum<["video", "square", "portrait", "wide", "auto"]>>;
57
+ design: "knob";
58
+ control: "toggle-group";
59
+ label: string;
60
+ description: string;
61
+ };
62
+ radius: {
63
+ schema: z.ZodOptional<z.ZodEnum<["none", "sm", "md", "lg", "xl"]>>;
64
+ design: "knob";
65
+ control: "toggle-group";
66
+ label: string;
67
+ default: string;
68
+ description: string;
69
+ };
70
+ border: {
71
+ schema: z.ZodOptional<z.ZodBoolean>;
72
+ design: "knob";
73
+ label: string;
74
+ default: boolean;
75
+ };
76
+ loading: {
77
+ schema: z.ZodOptional<z.ZodBoolean>;
78
+ design: "knob";
79
+ label: string;
80
+ default: boolean;
81
+ description: string;
82
+ };
83
+ emptyState: {
84
+ schema: z.ZodOptional<z.ZodUnion<[z.ZodLiteral<"auto">, z.ZodLiteral<"icon">, z.ZodLiteral<"none">]>>;
85
+ design: "knob";
86
+ control: "select";
87
+ label: string;
88
+ default: string;
89
+ description: string;
90
+ };
91
+ alt: {
92
+ schema: z.ZodOptional<z.ZodString>;
93
+ design: "content";
94
+ control: "text";
95
+ label: string;
96
+ description: string;
97
+ examples: string[];
98
+ };
99
+ src: {
100
+ schema: z.ZodOptional<z.ZodString>;
101
+ design: "content";
102
+ control: "url";
103
+ label: string;
104
+ description: string;
105
+ };
106
+ source: {
107
+ schema: z.ZodOptional<z.ZodUnion<[z.ZodObject<{
108
+ kind: z.ZodLiteral<"album">;
109
+ artist: z.ZodString;
110
+ title: z.ZodString;
111
+ year: z.ZodOptional<z.ZodNumber>;
112
+ description: z.ZodOptional<z.ZodString>;
113
+ }, "strip", z.ZodTypeAny, {
114
+ title: string;
115
+ kind: "album";
116
+ artist: string;
117
+ description?: string | undefined;
118
+ year?: number | undefined;
119
+ }, {
120
+ title: string;
121
+ kind: "album";
122
+ artist: string;
123
+ description?: string | undefined;
124
+ year?: number | undefined;
125
+ }>, z.ZodObject<{
126
+ kind: z.ZodLiteral<"tv-show">;
127
+ title: z.ZodString;
128
+ year: z.ZodOptional<z.ZodNumber>;
129
+ description: z.ZodOptional<z.ZodString>;
130
+ }, "strip", z.ZodTypeAny, {
131
+ title: string;
132
+ kind: "tv-show";
133
+ description?: string | undefined;
134
+ year?: number | undefined;
135
+ }, {
136
+ title: string;
137
+ kind: "tv-show";
138
+ description?: string | undefined;
139
+ year?: number | undefined;
140
+ }>, z.ZodObject<{
141
+ kind: z.ZodLiteral<"movie">;
142
+ title: z.ZodString;
143
+ year: z.ZodOptional<z.ZodNumber>;
144
+ description: z.ZodOptional<z.ZodString>;
145
+ }, "strip", z.ZodTypeAny, {
146
+ title: string;
147
+ kind: "movie";
148
+ description?: string | undefined;
149
+ year?: number | undefined;
150
+ }, {
151
+ title: string;
152
+ kind: "movie";
153
+ description?: string | undefined;
154
+ year?: number | undefined;
155
+ }>, z.ZodObject<{
156
+ kind: z.ZodLiteral<"game">;
157
+ title: z.ZodString;
158
+ description: z.ZodOptional<z.ZodString>;
159
+ }, "strip", z.ZodTypeAny, {
160
+ title: string;
161
+ kind: "game";
162
+ description?: string | undefined;
163
+ }, {
164
+ title: string;
165
+ kind: "game";
166
+ description?: string | undefined;
167
+ }>, z.ZodObject<{
168
+ kind: z.ZodLiteral<"book">;
169
+ title: z.ZodOptional<z.ZodString>;
170
+ author: z.ZodOptional<z.ZodString>;
171
+ isbn: z.ZodOptional<z.ZodString>;
172
+ description: z.ZodOptional<z.ZodString>;
173
+ }, "strip", z.ZodTypeAny, {
174
+ kind: "book";
175
+ description?: string | undefined;
176
+ title?: string | undefined;
177
+ author?: string | undefined;
178
+ isbn?: string | undefined;
179
+ }, {
180
+ kind: "book";
181
+ description?: string | undefined;
182
+ title?: string | undefined;
183
+ author?: string | undefined;
184
+ isbn?: string | undefined;
185
+ }>, z.ZodObject<{
186
+ kind: z.ZodLiteral<"poster">;
187
+ title: z.ZodString;
188
+ year: z.ZodOptional<z.ZodNumber>;
189
+ description: z.ZodOptional<z.ZodString>;
190
+ }, "strip", z.ZodTypeAny, {
191
+ title: string;
192
+ kind: "poster";
193
+ description?: string | undefined;
194
+ year?: number | undefined;
195
+ }, {
196
+ title: string;
197
+ kind: "poster";
198
+ description?: string | undefined;
199
+ year?: number | undefined;
200
+ }>, z.ZodObject<{
201
+ kind: z.ZodLiteral<"portrait">;
202
+ name: z.ZodOptional<z.ZodString>;
203
+ role: z.ZodOptional<z.ZodString>;
204
+ }, "strip", z.ZodTypeAny, {
205
+ kind: "portrait";
206
+ name?: string | undefined;
207
+ role?: string | undefined;
208
+ }, {
209
+ kind: "portrait";
210
+ name?: string | undefined;
211
+ role?: string | undefined;
212
+ }>, z.ZodObject<{
213
+ kind: z.ZodLiteral<"landscape">;
214
+ location: z.ZodOptional<z.ZodString>;
215
+ mood: z.ZodOptional<z.ZodString>;
216
+ }, "strip", z.ZodTypeAny, {
217
+ kind: "landscape";
218
+ location?: string | undefined;
219
+ mood?: string | undefined;
220
+ }, {
221
+ kind: "landscape";
222
+ location?: string | undefined;
223
+ mood?: string | undefined;
224
+ }>, z.ZodObject<{
225
+ kind: z.ZodLiteral<"product">;
226
+ name: z.ZodOptional<z.ZodString>;
227
+ brand: z.ZodOptional<z.ZodString>;
228
+ }, "strip", z.ZodTypeAny, {
229
+ kind: "product";
230
+ name?: string | undefined;
231
+ brand?: string | undefined;
232
+ }, {
233
+ kind: "product";
234
+ name?: string | undefined;
235
+ brand?: string | undefined;
236
+ }>, z.ZodObject<{
237
+ kind: z.ZodLiteral<"food">;
238
+ dish: z.ZodOptional<z.ZodString>;
239
+ cuisine: z.ZodOptional<z.ZodString>;
240
+ }, "strip", z.ZodTypeAny, {
241
+ kind: "food";
242
+ dish?: string | undefined;
243
+ cuisine?: string | undefined;
244
+ }, {
245
+ kind: "food";
246
+ dish?: string | undefined;
247
+ cuisine?: string | undefined;
248
+ }>, z.ZodObject<{
249
+ kind: z.ZodLiteral<"generic">;
250
+ prompt: z.ZodString;
251
+ }, "strip", z.ZodTypeAny, {
252
+ kind: "generic";
253
+ prompt: string;
254
+ }, {
255
+ kind: "generic";
256
+ prompt: string;
257
+ }>, z.ZodUnion<[z.ZodObject<{
258
+ kind: z.ZodLiteral<"video">;
259
+ }, "strip", z.ZodTypeAny, {
260
+ kind: "video";
261
+ }, {
262
+ kind: "video";
263
+ }>, z.ZodObject<{
264
+ kind: z.ZodLiteral<"audio">;
265
+ }, "strip", z.ZodTypeAny, {
266
+ kind: "audio";
267
+ }, {
268
+ kind: "audio";
269
+ }>, z.ZodObject<{
270
+ kind: z.ZodLiteral<"embed">;
271
+ }, "strip", z.ZodTypeAny, {
272
+ kind: "embed";
273
+ }, {
274
+ kind: "embed";
275
+ }>, z.ZodObject<{
276
+ kind: z.ZodLiteral<"3d">;
277
+ }, "strip", z.ZodTypeAny, {
278
+ kind: "3d";
279
+ }, {
280
+ kind: "3d";
281
+ }>]>]>>;
282
+ design: "structured";
283
+ label: string;
284
+ description: string;
285
+ perKindFields: {
286
+ album: {
287
+ artist: string;
288
+ title: string;
289
+ year: string;
290
+ };
291
+ poster: {
292
+ title: string;
293
+ year: string;
294
+ };
295
+ portrait: {
296
+ name: string;
297
+ role: string;
298
+ };
299
+ landscape: {
300
+ location: string;
301
+ mood: string;
302
+ };
303
+ product: {
304
+ name: string;
305
+ brand: string;
306
+ };
307
+ food: {
308
+ dish: string;
309
+ cuisine: string;
310
+ };
311
+ generic: {
312
+ prompt: string;
313
+ };
314
+ video: {};
315
+ audio: {};
316
+ embed: {};
317
+ "3d": {};
318
+ };
319
+ };
320
+ className: {
321
+ schema: z.ZodOptional<z.ZodString>;
322
+ design: "plumbing";
323
+ };
324
+ style: {
325
+ schema: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
326
+ design: "plumbing";
327
+ };
328
+ children: {
329
+ schema: z.ZodOptional<z.ZodUnknown>;
330
+ design: "plumbing";
331
+ description: string;
332
+ };
333
+ overlay: {
334
+ schema: z.ZodOptional<z.ZodUnknown>;
335
+ design: "plumbing";
336
+ description: string;
337
+ };
338
+ glyph: {
339
+ schema: z.ZodOptional<z.ZodUnknown>;
340
+ design: "plumbing";
341
+ description: string;
342
+ };
343
+ fallback: {
344
+ schema: z.ZodOptional<z.ZodUnknown>;
345
+ design: "plumbing";
346
+ description: string;
347
+ };
348
+ onVisibilityChange: {
349
+ schema: z.ZodOptional<z.ZodFunction<z.ZodTuple<[], z.ZodUnknown>, z.ZodUnknown>>;
350
+ design: "event";
351
+ description: string;
352
+ };
353
+ }>;
354
+
29
355
  declare const Accordion: React$1.ForwardRefExoticComponent<(AccordionPrimitive.AccordionSingleProps | AccordionPrimitive.AccordionMultipleProps) & React$1.RefAttributes<HTMLDivElement>>;
30
356
  declare const AccordionItem: React$1.ForwardRefExoticComponent<Omit<AccordionPrimitive.AccordionItemProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
31
357
  declare const AccordionTrigger: React$1.ForwardRefExoticComponent<Omit<AccordionPrimitive.AccordionTriggerProps & React$1.RefAttributes<HTMLButtonElement>, "ref"> & React$1.RefAttributes<HTMLButtonElement>>;
32
358
  declare const AccordionContent: React$1.ForwardRefExoticComponent<Omit<AccordionPrimitive.AccordionContentProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
33
359
 
34
- declare const Alert: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTMLDivElement> & VariantProps<(props?: ({
35
- variant?: "default" | "destructive" | "success" | "warning" | "info" | "highlight" | null | undefined;
360
+ /**
361
+ * Callout inline, ambient, non-blocking status/feedback surface.
362
+ *
363
+ * Renamed from `Alert` (May 2026). The old name collided with
364
+ * Apple HIG `Alert` (a modal) and with `role="alert"` ARIA semantics,
365
+ * both of which imply interruptive/assertive behaviour the component
366
+ * does not have. "Callout" is honest about what it is: an inline
367
+ * attention-grabber that sits in the layout flow. The `Alert` name is
368
+ * deliberately left vacant in the barrel so a future genuinely-
369
+ * interruptive primitive can claim it without further renames — until
370
+ * then, reach for `<Dialog>` for modal alerts.
371
+ *
372
+ * Variants intentionally preserved as-is in this pass (`default |
373
+ * destructive | success | warning | info`) — splitting `variant` onto
374
+ * orthogonal `intent × emphasis` axes is a planned follow-up across
375
+ * the whole library, not a one-component change. The `highlight`
376
+ * variant (yellow) was dropped in this rename: in practice it
377
+ * overlapped `warning` (amber) and added one more variant without a
378
+ * unique semantic. Consumers needing "notable but not alarming" use
379
+ * `variant="warning"` or `variant="info"` depending on temperature.
380
+ */
381
+ declare const calloutVariants: (props?: ({
382
+ variant?: "default" | "destructive" | "success" | "warning" | "info" | null | undefined;
383
+ } & class_variance_authority_types.ClassProp) | undefined) => string;
384
+ declare const Callout: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTMLDivElement> & VariantProps<(props?: ({
385
+ variant?: "default" | "destructive" | "success" | "warning" | "info" | null | undefined;
36
386
  } & class_variance_authority_types.ClassProp) | undefined) => string> & React$1.RefAttributes<HTMLDivElement>>;
37
- declare const AlertTitle: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTMLHeadingElement> & React$1.RefAttributes<HTMLParagraphElement>>;
38
- declare const AlertDescription: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTMLParagraphElement> & React$1.RefAttributes<HTMLParagraphElement>>;
387
+ declare const CalloutTitle: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTMLHeadingElement> & React$1.RefAttributes<HTMLParagraphElement>>;
388
+ declare const CalloutDescription: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTMLParagraphElement> & React$1.RefAttributes<HTMLParagraphElement>>;
39
389
 
40
390
  /**
41
391
  * AppShell — top-level page scaffold for an app-like or marketing layout.
@@ -54,14 +404,14 @@ declare const AlertDescription: React$1.ForwardRefExoticComponent<React$1.HTMLAt
54
404
  * - `top` — Main below an in-app top-nav row (TopMenu)
55
405
  * - `side` — Nav rail + Main (classic app layout)
56
406
  * - `three-pane` — Nav rail + fixed Aside + flex Main (Slack/Mail/Notion
57
- * shape; aside width via --rds-app-shell-aside, default 320px)
407
+ * shape; aside width via --gds-app-shell-aside, default 320px)
58
408
  *
59
409
  * Each slot is assigned a fixed `grid-area` (header/nav/aside/main/footer),
60
410
  * so the **JSX child order doesn't matter** — drop slots in any order and
61
411
  * the grid sorts them.
62
412
  *
63
413
  * It is deliberately *just* structure: no collapse state, no context, no
64
- * runtime JS. Nav content is whatever the caller drops in — a SideMenu, a
414
+ * runtime JS. Nav content is whatever the caller drops in — a Sidebar, a
65
415
  * TopMenu, a hand-rolled `<nav>`. For drag-to-resize columns inside the
66
416
  * body, compose this with `Resizable` instead of using a static grid.
67
417
  *
@@ -120,7 +470,7 @@ declare const AvatarImage: React$1.ForwardRefExoticComponent<Omit<AvatarPrimitiv
120
470
  declare const AvatarFallback: React$1.ForwardRefExoticComponent<Omit<AvatarPrimitive.AvatarFallbackProps & React$1.RefAttributes<HTMLSpanElement>, "ref"> & React$1.RefAttributes<HTMLSpanElement>>;
121
471
 
122
472
  declare const badgeVariants: (props?: ({
123
- variant?: "default" | "destructive" | "success" | "warning" | "info" | "highlight" | "secondary" | "outline" | "success-soft" | "warning-soft" | "destructive-soft" | "info-soft" | "highlight-soft" | "success-outline" | "warning-outline" | "destructive-outline" | "info-outline" | null | undefined;
473
+ variant?: "default" | "destructive" | "outline" | "secondary" | "success" | "warning" | "info" | "highlight" | "success-soft" | "warning-soft" | "destructive-soft" | "info-soft" | "highlight-soft" | "success-outline" | "warning-outline" | "destructive-outline" | "info-outline" | null | undefined;
124
474
  rounded?: "default" | "full" | null | undefined;
125
475
  } & class_variance_authority_types.ClassProp) | undefined) => string;
126
476
  interface BadgeProps extends React$1.HTMLAttributes<HTMLDivElement>, VariantProps<typeof badgeVariants> {
@@ -147,7 +497,7 @@ declare function Badge({ className, variant, rounded, ...props }: BadgeProps): R
147
497
  * consistent across primitives.
148
498
  */
149
499
  declare const buttonVariants: (props?: ({
150
- variant?: "link" | "default" | "destructive" | "secondary" | "outline" | "ghost" | null | undefined;
500
+ variant?: "default" | "destructive" | "outline" | "secondary" | "ghost" | "link" | "raised" | null | undefined;
151
501
  size?: "default" | "sm" | "md" | "lg" | "icon" | null | undefined;
152
502
  } & class_variance_authority_types.ClassProp) | undefined) => string;
153
503
  interface ButtonProps extends React$1.ButtonHTMLAttributes<HTMLButtonElement>, VariantProps<typeof buttonVariants> {
@@ -160,6 +510,145 @@ declare function Calendar({ className, classNames, showOutsideDays, captionLayou
160
510
  }): React$1.JSX.Element;
161
511
  declare function CalendarDayButton({ className, day, modifiers, ...props }: React$1.ComponentProps<typeof DayButton>): React$1.JSX.Element;
162
512
 
513
+ /**
514
+ * Carousel — token-driven slideshow primitive built on embla-carousel.
515
+ *
516
+ * Compound API:
517
+ *
518
+ * <Carousel autoplay loop>
519
+ * <Carousel.Slide>{...}</Carousel.Slide>
520
+ * <Carousel.Slide duration={15000}>{...}</Carousel.Slide>
521
+ * <Carousel.VideoSlide src="…" poster="…" alt="…" />
522
+ *
523
+ * <Carousel.Arrows />
524
+ * <Carousel.Dots />
525
+ * </Carousel>
526
+ *
527
+ * Design-system contract:
528
+ * - All visual dimensions are CSS variables (`--gds-carousel-*`) so the
529
+ * control surface, dot size, gap, arrow look etc. are themable per
530
+ * consumer without prop drilling. Defaults live in `styles/globals.css`.
531
+ * - Root stamps `data-gds-part="carousel"` so Studio's selection agent
532
+ * can target the whole carousel as one unit, with sub-parts on
533
+ * `Carousel.Slide` (`carousel-slide`), `Carousel.Dots` (`carousel-dots`),
534
+ * `Carousel.Arrows` (`carousel-arrows`).
535
+ * - Autoplay is hand-rolled (no `embla-carousel-autoplay` plugin) so per-
536
+ * slide duration overrides and "advance when the video ends" behaviour
537
+ * fall out cleanly. The plugin's fixed `delay` would have made both of
538
+ * those fight the library.
539
+ *
540
+ * Video slide behaviour (the one the user asked for):
541
+ * - Poster image is rendered until the slide becomes active.
542
+ * - On activation the <video> autoplays muted + loop (= browser-friendly)
543
+ * with no controls — chosen default.
544
+ * - When the loop is short (`<video loop>` re-fires onEnded continuously
545
+ * in some browsers but never in others), we ALSO use the same per-slide
546
+ * `duration` mechanism as still slides: if the slide author passes
547
+ * `duration={15000}` we advance after 15s regardless of the video
548
+ * length. Without a duration the slide stays put until the carousel
549
+ * stops being autoplayed — that matches "play this video forever
550
+ * while it's on screen".
551
+ *
552
+ * Library: embla-carousel-react. Headless, ~6kb gzip, no opinionated CSS.
553
+ */
554
+
555
+ type EmblaApi = NonNullable<UseEmblaCarouselType[1]>;
556
+ interface CarouselProps extends React$1.HTMLAttributes<HTMLDivElement> {
557
+ /** Loop back to slide 0 after the last one. Default true. */
558
+ loop?: boolean;
559
+ /** Slide alignment within the viewport when not all slides are full-width.
560
+ * `"start"` (default) lines slides up to the left edge; `"center"` is the
561
+ * classic "current slide centered, peek of neighbours" treatment. */
562
+ align?: "start" | "center" | "end";
563
+ /** How many slides to show at once. Default `1` (full-bleed slides).
564
+ * For responsive multi-slide layouts (e.g. 1 mobile / 3 desktop) leave
565
+ * this and use the `--gds-carousel-slide-basis` CSS var on `Slide`
566
+ * instead — it accepts media-query-driven values. */
567
+ slidesPerView?: number;
568
+ /** Autoplay config. Pass `true` for defaults (5s delay, pause on hover,
569
+ * pause when offscreen). Pass an object to override; pass `false` /
570
+ * omit to disable. */
571
+ autoplay?: boolean | AutoplayConfig;
572
+ /** Drag-to-swipe. Default `true`. Disable when the carousel is being
573
+ * driven entirely by Dots/Arrows and drag would conflict with chrome
574
+ * inside the slides. */
575
+ draggable?: boolean;
576
+ /** Fired whenever the active slide changes — programmatic, autoplay,
577
+ * or user swipe. The value is the zero-based slide index. */
578
+ onSlideChange?: (index: number) => void;
579
+ }
580
+ interface AutoplayConfig {
581
+ /** Default delay per slide in ms. Overridden by `<Carousel.Slide duration>`
582
+ * on a per-slide basis. Default 5000. */
583
+ delay?: number;
584
+ /** Pause the autoplay while the pointer is over the carousel. Default true. */
585
+ pauseOnHover?: boolean;
586
+ /** Pause when the carousel scrolls out of the viewport — saves work and
587
+ * matches the MediaSurface "play when visible" convention. Default true. */
588
+ pauseWhenOffscreen?: boolean;
589
+ }
590
+ interface CarouselRootComponent extends React$1.ForwardRefExoticComponent<CarouselProps & React$1.RefAttributes<HTMLDivElement>> {
591
+ Slide: typeof CarouselSlide;
592
+ VideoSlide: typeof CarouselVideoSlide;
593
+ Dots: typeof CarouselDots;
594
+ Arrows: typeof CarouselArrows;
595
+ Prev: typeof CarouselPrev;
596
+ Next: typeof CarouselNext;
597
+ }
598
+ interface CarouselSlideProps extends React$1.HTMLAttributes<HTMLDivElement> {
599
+ /** Per-slide autoplay duration in ms. Overrides the carousel's default
600
+ * delay for this slide only. e.g. `duration={15000}` keeps a hero
601
+ * still on screen for 15s while the rest cycle at 5s. */
602
+ duration?: number;
603
+ }
604
+ declare const CarouselSlide: React$1.ForwardRefExoticComponent<CarouselSlideProps & React$1.RefAttributes<HTMLDivElement>>;
605
+ interface CarouselVideoSlideProps extends Omit<CarouselSlideProps, "children"> {
606
+ src: string;
607
+ /** Poster shown until the slide becomes active. Reuses the
608
+ * `--gds-media-placeholder-bg/-fg` tokens as a fallback. */
609
+ poster?: string;
610
+ alt?: string;
611
+ /** Override default behaviour and show native controls. Default false —
612
+ * the chosen default ("muted autoplay + loop, no controls"). */
613
+ controls?: boolean;
614
+ /** Override the default loop behaviour. Default true (the chosen
615
+ * default). When `false` and no `duration` is set, the carousel
616
+ * advances when the video ends. */
617
+ loop?: boolean;
618
+ /** Object-fit for the video. Default `"cover"`. */
619
+ fit?: "cover" | "contain";
620
+ }
621
+ declare const CarouselVideoSlide: React$1.ForwardRefExoticComponent<CarouselVideoSlideProps & React$1.RefAttributes<HTMLDivElement>>;
622
+ interface CarouselDotsProps extends React$1.HTMLAttributes<HTMLDivElement> {
623
+ /** Position the dots relative to the viewport. Default `"below"` puts
624
+ * them in flow underneath; `"overlay"` floats them at the bottom of
625
+ * the carousel area on top of the slides. */
626
+ position?: "below" | "overlay";
627
+ /** Custom render function for one dot. Receives `{ index, active, onClick }`
628
+ * and should return a button — for when the default rounded-pill look
629
+ * doesn't fit (e.g. thumbnail strips, numeric pagination). */
630
+ renderDot?: (state: {
631
+ index: number;
632
+ active: boolean;
633
+ onClick: () => void;
634
+ }) => React$1.ReactNode;
635
+ }
636
+ declare const CarouselDots: React$1.ForwardRefExoticComponent<CarouselDotsProps & React$1.RefAttributes<HTMLDivElement>>;
637
+ interface CarouselArrowsProps extends React$1.HTMLAttributes<HTMLDivElement> {
638
+ /** Position relative to the viewport. `"overlay"` (default) floats the
639
+ * arrows over the slides; `"outside"` places them in flow alongside
640
+ * the carousel (useful when the viewport is full-bleed). */
641
+ position?: "overlay" | "outside";
642
+ }
643
+ declare const CarouselArrows: React$1.ForwardRefExoticComponent<CarouselArrowsProps & React$1.RefAttributes<HTMLDivElement>>;
644
+ interface CarouselNavButtonProps extends React$1.ButtonHTMLAttributes<HTMLButtonElement> {
645
+ }
646
+ declare const CarouselPrev: React$1.ForwardRefExoticComponent<CarouselNavButtonProps & React$1.RefAttributes<HTMLButtonElement>>;
647
+ declare const CarouselNext: React$1.ForwardRefExoticComponent<CarouselNavButtonProps & React$1.RefAttributes<HTMLButtonElement>>;
648
+ declare const Carousel: CarouselRootComponent;
649
+
650
+ declare function useCarouselApi(): EmblaApi | undefined;
651
+
163
652
  declare const Card: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTMLDivElement> & React$1.RefAttributes<HTMLDivElement>>;
164
653
  declare const CardHeader: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTMLDivElement> & React$1.RefAttributes<HTMLDivElement>>;
165
654
  declare const CardTitle: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTMLDivElement> & React$1.RefAttributes<HTMLDivElement>>;
@@ -276,7 +765,26 @@ declare const DropdownMenuShortcut: {
276
765
  displayName: string;
277
766
  };
278
767
 
279
- declare const Input: React$1.ForwardRefExoticComponent<Omit<React$1.DetailedHTMLProps<React$1.InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, "ref"> & React$1.RefAttributes<HTMLInputElement>>;
768
+ /**
769
+ * Input variants — `size` lets dense surfaces (the Studio inspector,
770
+ * settings sheets) reach for a compact `sm` input without hand-rolling
771
+ * className overrides. Default keeps the existing h-9 padding /
772
+ * text-base-md:text-sm so this is a no-op for every existing call
773
+ * site.
774
+ *
775
+ * `pl-3 pr-3` is preserved verbatim from the original so the search-
776
+ * input pattern (leading icon overrides `pl-*`) still wins via
777
+ * twMerge. See packages/ui/components/ui/input.tsx for the full
778
+ * rationale.
779
+ */
780
+ declare const inputVariants: (props?: ({
781
+ size?: "default" | "sm" | null | undefined;
782
+ } & class_variance_authority_types.ClassProp) | undefined) => string;
783
+ type InputSize = NonNullable<VariantProps<typeof inputVariants>["size"]>;
784
+ type InputProps = Omit<React$1.ComponentProps<"input">, "size"> & {
785
+ size?: InputSize;
786
+ };
787
+ declare const Input: React$1.ForwardRefExoticComponent<Omit<InputProps, "ref"> & React$1.RefAttributes<HTMLInputElement>>;
280
788
 
281
789
  declare const Label: React$1.ForwardRefExoticComponent<Omit<LabelPrimitive.LabelProps & React$1.RefAttributes<HTMLLabelElement>, "ref"> & VariantProps<(props?: class_variance_authority_types.ClassProp | undefined) => string> & React$1.RefAttributes<HTMLLabelElement>>;
282
790
 
@@ -287,6 +795,91 @@ declare const PopoverContent: React$1.ForwardRefExoticComponent<Omit<PopoverPrim
287
795
 
288
796
  declare const Progress: React$1.ForwardRefExoticComponent<Omit<ProgressPrimitive.ProgressProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
289
797
 
798
+ /**
799
+ * MultiSelect — multi-pick combobox.
800
+ *
801
+ * Composes Popover + Command (cmdk) + Badge + Checkbox into the
802
+ * pattern popularised by sersavan/shadcn-multi-select-component:
803
+ *
804
+ * - Trigger: a button that shows the currently-selected items as
805
+ * removable Badges. Past `maxCount` selected items it collapses
806
+ * into a "+N more" badge so the trigger doesn't grow forever.
807
+ * - Open: a Popover containing a searchable Command list. Each
808
+ * row is a checkable item; a leading icon is optional per
809
+ * option.
810
+ * - Footer actions: Select all · Clear · Close.
811
+ *
812
+ * Controlled and uncontrolled both supported (value / defaultValue
813
+ * mirroring Radix conventions). Selection is `string[]` — the
814
+ * caller pulls the matching option objects from their own `options`
815
+ * array when needed.
816
+ *
817
+ * Data-driven via `options` rather than compound children. Multi-
818
+ * select lists are typically dozens of items long; declaring each
819
+ * one in JSX is noisy and the per-item icon prop doesn't have a
820
+ * natural children-API equivalent. A compound API (`MultiSelect.Item`)
821
+ * could land later for the few cases that need fully custom rendering.
822
+ *
823
+ * Theming: visual surfaces (popover bg, badge fill, focus rings)
824
+ * inherit from the theme tokens the underlying Popover / Badge /
825
+ * Checkbox already read from. No new `--gds-multi-select-*` vars
826
+ * needed yet; if/when callers want to retune density (e.g. a
827
+ * compact variant), add them then.
828
+ */
829
+
830
+ interface MultiSelectOption {
831
+ /** Value stored in selection. Must be unique. */
832
+ value: string;
833
+ /** Display label for the dropdown row and selected badge. */
834
+ label: string;
835
+ /** Optional lucide-style icon component (or any React component
836
+ * accepting a className). Rendered both in the dropdown row and
837
+ * on the badge. */
838
+ icon?: React$1.ComponentType<{
839
+ className?: string;
840
+ }>;
841
+ /** Disables the row in the dropdown — selection is locked in
842
+ * whichever state it's currently in. */
843
+ disabled?: boolean;
844
+ }
845
+ interface MultiSelectProps {
846
+ /** The full pool of selectable items. */
847
+ options: MultiSelectOption[];
848
+ /** Controlled value. When provided, `onValueChange` MUST be wired
849
+ * or the component becomes a read-only display of `value`. */
850
+ value?: string[];
851
+ /** Uncontrolled initial value. Ignored if `value` is provided. */
852
+ defaultValue?: string[];
853
+ /** Fired whenever the selection changes. The full next selection
854
+ * is passed — caller doesn't need to reconcile add/remove. */
855
+ onValueChange?: (next: string[]) => void;
856
+ /** Placeholder text on the trigger when nothing is selected. */
857
+ placeholder?: string;
858
+ /** Search-input placeholder. Default "Search…". */
859
+ searchPlaceholder?: string;
860
+ /** Message rendered when search returns no rows. */
861
+ emptyMessage?: string;
862
+ /** Max badges to show on the trigger before collapsing to
863
+ * `+N more`. Default 3. Pass `Infinity` to never collapse. */
864
+ maxCount?: number;
865
+ /** Hide the Search input. Useful for short option lists. */
866
+ searchable?: boolean;
867
+ /** Hide the per-badge × button. Selected items can still be
868
+ * toggled off through the dropdown. */
869
+ badgeDismissible?: boolean;
870
+ /** Disable the whole control. */
871
+ disabled?: boolean;
872
+ /** Drives Popover's `modal` prop — when true, clicks outside the
873
+ * dropdown don't dismiss it until an explicit close. Default false. */
874
+ modalPopover?: boolean;
875
+ /** Extra classes on the trigger. */
876
+ className?: string;
877
+ /** Forwarded to the trigger button for tests / Studio selection. */
878
+ id?: string;
879
+ "aria-label"?: string;
880
+ }
881
+ declare const MultiSelect: React$1.ForwardRefExoticComponent<MultiSelectProps & React$1.RefAttributes<HTMLButtonElement>>;
882
+
290
883
  declare const RadioGroup: React$1.ForwardRefExoticComponent<Omit<RadioGroupPrimitive.RadioGroupProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
291
884
  declare const RadioGroupItem: React$1.ForwardRefExoticComponent<Omit<RadioGroupPrimitive.RadioGroupItemProps & React$1.RefAttributes<HTMLButtonElement>, "ref"> & React$1.RefAttributes<HTMLButtonElement>>;
292
885
 
@@ -315,7 +908,7 @@ declare const RadioGroupItem: React$1.ForwardRefExoticComponent<Omit<RadioGroupP
315
908
  *
316
909
  * <ResizablePanelGroup direction="horizontal" id="inbox-shell">
317
910
  * <ResizablePanel defaultSize={20} minSize={15} id="nav">
318
- * <SideMenu />
911
+ * <Sidebar />
319
912
  * </ResizablePanel>
320
913
  * <ResizableHandle withHandle />
321
914
  * <ResizablePanel defaultSize={30} minSize={20} id="list">
@@ -328,7 +921,7 @@ declare const RadioGroupItem: React$1.ForwardRefExoticComponent<Omit<RadioGroupP
328
921
  * </ResizablePanelGroup>
329
922
  */
330
923
  declare const ResizablePanelGroup: ({ className, ...props }: React$1.ComponentProps<typeof ResizablePrimitive.PanelGroup>) => React$1.JSX.Element;
331
- declare const ResizablePanel: React$1.ForwardRefExoticComponent<Omit<React$1.HTMLAttributes<HTMLDivElement | HTMLElement | HTMLObjectElement | HTMLMapElement | HTMLAnchorElement | HTMLButtonElement | HTMLFormElement | HTMLHeadingElement | HTMLImageElement | HTMLInputElement | HTMLLabelElement | HTMLLIElement | HTMLOListElement | HTMLParagraphElement | HTMLSelectElement | HTMLSpanElement | HTMLUListElement | HTMLAreaElement | HTMLAudioElement | HTMLBaseElement | HTMLQuoteElement | HTMLBodyElement | HTMLBRElement | HTMLCanvasElement | HTMLTableColElement | HTMLDataElement | HTMLDataListElement | HTMLModElement | HTMLDetailsElement | HTMLDialogElement | HTMLDListElement | HTMLEmbedElement | HTMLFieldSetElement | HTMLHeadElement | HTMLHRElement | HTMLHtmlElement | HTMLIFrameElement | HTMLLegendElement | HTMLLinkElement | HTMLMetaElement | HTMLMeterElement | HTMLOptGroupElement | HTMLOptionElement | HTMLOutputElement | HTMLPreElement | HTMLProgressElement | HTMLSlotElement | HTMLScriptElement | HTMLSourceElement | HTMLStyleElement | HTMLTableElement | HTMLTemplateElement | HTMLTableSectionElement | HTMLTableCellElement | HTMLTextAreaElement | HTMLTimeElement | HTMLTitleElement | HTMLTableRowElement | HTMLTrackElement | HTMLVideoElement | HTMLTableCaptionElement | HTMLMenuElement | HTMLPictureElement>, "id" | "onResize"> & {
924
+ declare const ResizablePanel: React$1.ForwardRefExoticComponent<Omit<React$1.HTMLAttributes<HTMLDivElement | HTMLElement | HTMLObjectElement | HTMLSelectElement | HTMLTextAreaElement | HTMLMapElement | HTMLTitleElement | HTMLButtonElement | HTMLLinkElement | HTMLLabelElement | HTMLStyleElement | HTMLTableColElement | HTMLVideoElement | HTMLAudioElement | HTMLEmbedElement | HTMLSourceElement | HTMLProgressElement | HTMLHRElement | HTMLTableElement | HTMLAnchorElement | HTMLFormElement | HTMLHeadingElement | HTMLImageElement | HTMLInputElement | HTMLLIElement | HTMLOListElement | HTMLParagraphElement | HTMLSpanElement | HTMLUListElement | HTMLAreaElement | HTMLBaseElement | HTMLQuoteElement | HTMLBodyElement | HTMLBRElement | HTMLCanvasElement | HTMLDataElement | HTMLDataListElement | HTMLModElement | HTMLDetailsElement | HTMLDialogElement | HTMLDListElement | HTMLFieldSetElement | HTMLHeadElement | HTMLHtmlElement | HTMLIFrameElement | HTMLLegendElement | HTMLMetaElement | HTMLMeterElement | HTMLOptGroupElement | HTMLOptionElement | HTMLOutputElement | HTMLPreElement | HTMLSlotElement | HTMLScriptElement | HTMLTemplateElement | HTMLTableSectionElement | HTMLTableCellElement | HTMLTimeElement | HTMLTableRowElement | HTMLTrackElement | HTMLTableCaptionElement | HTMLMenuElement | HTMLPictureElement>, "id" | "onResize"> & {
332
925
  className?: string | undefined;
333
926
  collapsedSize?: number | undefined;
334
927
  collapsible?: boolean | undefined;
@@ -368,8 +961,8 @@ declare const ResizableHandle: ({ withHandle, className, ...props }: React$1.Com
368
961
  */
369
962
  declare const rowVariants: (props?: ({
370
963
  gap?: "none" | "sm" | "md" | "lg" | "xs" | "xl" | "2xl" | null | undefined;
371
- align?: "center" | "end" | "start" | "stretch" | "baseline" | null | undefined;
372
- justify?: "center" | "end" | "start" | "between" | "around" | "evenly" | null | undefined;
964
+ align?: "start" | "center" | "end" | "stretch" | "baseline" | null | undefined;
965
+ justify?: "start" | "center" | "end" | "between" | "around" | "evenly" | null | undefined;
373
966
  wrap?: boolean | null | undefined;
374
967
  } & class_variance_authority_types.ClassProp) | undefined) => string;
375
968
  interface RowProps extends React$1.HTMLAttributes<HTMLDivElement>, VariantProps<typeof rowVariants> {
@@ -404,7 +997,7 @@ declare const Row: React$1.ForwardRefExoticComponent<RowProps & React$1.RefAttri
404
997
  declare const gridVariants: (props?: ({
405
998
  cols?: "1" | "2" | "3" | "4" | "5" | "6" | "12" | null | undefined;
406
999
  gap?: "none" | "sm" | "md" | "lg" | "xs" | "xl" | "2xl" | null | undefined;
407
- align?: "center" | "end" | "start" | "stretch" | null | undefined;
1000
+ align?: "start" | "center" | "end" | "stretch" | null | undefined;
408
1001
  } & class_variance_authority_types.ClassProp) | undefined) => string;
409
1002
  interface GridProps extends React$1.HTMLAttributes<HTMLDivElement>, VariantProps<typeof gridVariants> {
410
1003
  /** When true, render as the single child element via Radix Slot — lets
@@ -436,10 +1029,10 @@ declare const Grid: React$1.ForwardRefExoticComponent<GridProps & React$1.RefAtt
436
1029
  * case. Flex is the escape hatch, not the default.
437
1030
  */
438
1031
  declare const flexVariants: (props?: ({
439
- direction?: "col" | "row" | "row-reverse" | "col-reverse" | null | undefined;
1032
+ direction?: "row" | "col" | "row-reverse" | "col-reverse" | null | undefined;
440
1033
  gap?: "none" | "sm" | "md" | "lg" | "xs" | "xl" | "2xl" | null | undefined;
441
- align?: "center" | "end" | "start" | "stretch" | "baseline" | null | undefined;
442
- justify?: "center" | "end" | "start" | "between" | "around" | "evenly" | null | undefined;
1034
+ align?: "start" | "center" | "end" | "stretch" | "baseline" | null | undefined;
1035
+ justify?: "start" | "center" | "end" | "between" | "around" | "evenly" | null | undefined;
443
1036
  wrap?: "wrap" | "nowrap" | "wrap-reverse" | null | undefined;
444
1037
  } & class_variance_authority_types.ClassProp) | undefined) => string;
445
1038
  interface FlexProps extends React$1.HTMLAttributes<HTMLDivElement>, VariantProps<typeof flexVariants> {
@@ -456,7 +1049,20 @@ declare const ScrollBar: React$1.ForwardRefExoticComponent<Omit<ScrollAreaPrimit
456
1049
  declare const Select: React$1.FC<SelectPrimitive.SelectProps>;
457
1050
  declare const SelectGroup: React$1.ForwardRefExoticComponent<SelectPrimitive.SelectGroupProps & React$1.RefAttributes<HTMLDivElement>>;
458
1051
  declare const SelectValue: React$1.ForwardRefExoticComponent<SelectPrimitive.SelectValueProps & React$1.RefAttributes<HTMLSpanElement>>;
459
- declare const SelectTrigger: React$1.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectTriggerProps & React$1.RefAttributes<HTMLButtonElement>, "ref"> & React$1.RefAttributes<HTMLButtonElement>>;
1052
+ /**
1053
+ * Select trigger variants — `size` lets dense surfaces (the
1054
+ * Studio inspector, settings sheets) reach for a compact `sm`
1055
+ * trigger without hand-rolling className overrides. Default keeps
1056
+ * the existing h-10 / px-3 / text-sm so this is a no-op for every
1057
+ * existing call site.
1058
+ */
1059
+ declare const selectTriggerVariants: (props?: ({
1060
+ size?: "default" | "sm" | null | undefined;
1061
+ } & class_variance_authority_types.ClassProp) | undefined) => string;
1062
+ type SelectTriggerSize = NonNullable<VariantProps<typeof selectTriggerVariants>["size"]>;
1063
+ declare const SelectTrigger: React$1.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectTriggerProps & React$1.RefAttributes<HTMLButtonElement>, "ref"> & {
1064
+ size?: SelectTriggerSize;
1065
+ } & React$1.RefAttributes<HTMLButtonElement>>;
460
1066
  declare const SelectScrollUpButton: React$1.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectScrollUpButtonProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
461
1067
  declare const SelectScrollDownButton: React$1.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectScrollDownButtonProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
462
1068
  declare const SelectContent: React$1.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectContentProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
@@ -472,7 +1078,7 @@ declare const SheetClose: React$1.ForwardRefExoticComponent<DialogPrimitive.Dial
472
1078
  declare const SheetPortal: React$1.FC<DialogPrimitive.DialogPortalProps>;
473
1079
  declare const SheetOverlay: React$1.ForwardRefExoticComponent<Omit<DialogPrimitive.DialogOverlayProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
474
1080
  declare const sheetVariants: (props?: ({
475
- side?: "top" | "left" | "right" | "bottom" | null | undefined;
1081
+ side?: "top" | "right" | "bottom" | "left" | null | undefined;
476
1082
  } & class_variance_authority_types.ClassProp) | undefined) => string;
477
1083
  interface SheetContentProps extends React$1.ComponentPropsWithoutRef<typeof DialogPrimitive.Content>, VariantProps<typeof sheetVariants> {
478
1084
  }
@@ -492,6 +1098,102 @@ declare function Skeleton({ className, ...props }: React.HTMLAttributes<HTMLDivE
492
1098
 
493
1099
  declare const Slider: React$1.ForwardRefExoticComponent<Omit<SliderPrimitive.SliderProps & React$1.RefAttributes<HTMLSpanElement>, "ref"> & React$1.RefAttributes<HTMLSpanElement>>;
494
1100
 
1101
+ /**
1102
+ * Sortable — compound drag-to-reorder primitive built on dnd-kit.
1103
+ *
1104
+ * The orchestrator (`<Sortable>`) owns the DndContext + SortableContext;
1105
+ * items (`<Sortable.Item>`) attach the `useSortable` hook + transform
1106
+ * styles to whatever you put inside them. An optional `<Sortable.Handle>`
1107
+ * scopes the drag activation to a specific child element (drag-by-grip
1108
+ * instead of drag-by-whole-row).
1109
+ *
1110
+ * Design choices that may surprise you:
1111
+ *
1112
+ * - Layout primitives (Stack, Row, Grid) stay PURE — they don't grow
1113
+ * a `sortable` prop. The reorder behaviour lives on its own
1114
+ * primitive that composes with any layout:
1115
+ * `<Sortable><Stack>...</Stack></Sortable>` works.
1116
+ * `<Sortable strategy="grid"><Grid cols={3}>...</Grid></Sortable>`
1117
+ * too. This matches the dnd-kit / framer Reorder pattern and
1118
+ * keeps each component's contract tight.
1119
+ *
1120
+ * - `values` is the source of truth, not the children. The model is
1121
+ * `state -> children`, so reorder fires `onReorder(newValues)` and
1122
+ * the consumer updates state; React re-renders children in the
1123
+ * new order. Trying to read children's keys + mutate them is
1124
+ * fighting React's data-flow.
1125
+ *
1126
+ * - Item identity is `value`, NOT `key`. Items must have a unique
1127
+ * `value` prop that matches one entry in `values`. We deliberately
1128
+ * don't auto-derive from `key` because React lifts keys out of
1129
+ * children before we can read them, AND because the value carries
1130
+ * more semantic weight than a render-time key.
1131
+ *
1132
+ * - Cross-container drag (the "drag from To Do to Done" kanban case)
1133
+ * is NOT covered by v1. That needs one DndContext above multiple
1134
+ * SortableContexts — planned as `<Sortable.Group>` follow-up. For
1135
+ * now, each `<Sortable>` is its own world. Single-list reorder,
1136
+ * single-grid reorder, single-horizontal-row reorder all work.
1137
+ *
1138
+ * - Theming: no new tokens. dnd-kit handles the transform CSS;
1139
+ * visual treatment (drop shadow on the active item, slight
1140
+ * scale, etc.) is applied via opt-in className on the item.
1141
+ */
1142
+
1143
+ type SortableStrategy = "vertical" | "horizontal" | "grid";
1144
+ interface SortableGroupProps extends React$1.HTMLAttributes<HTMLDivElement> {
1145
+ /** Disable drag for every container inside the Group. */
1146
+ disabled?: boolean;
1147
+ }
1148
+ declare const SortableGroup: React$1.ForwardRefExoticComponent<SortableGroupProps & React$1.RefAttributes<HTMLDivElement>>;
1149
+ interface SortableProps<T extends UniqueIdentifier = UniqueIdentifier> extends Omit<React$1.HTMLAttributes<HTMLDivElement>, "onChange" | "id"> {
1150
+ /** Ordered list of unique ids — strings or numbers. Source of truth
1151
+ * for the order; reorder fires `onReorder(newValues)` and the
1152
+ * consumer updates their state. */
1153
+ values: T[];
1154
+ /** Fired with the full new order after a drag-end that changed it.
1155
+ * Drags that snap back (drop on origin) DON'T fire — only real
1156
+ * reorders. */
1157
+ onReorder?: (next: T[]) => void;
1158
+ /** Layout direction the sort strategy assumes.
1159
+ * `vertical` (default) — stacked column of items, drag up/down.
1160
+ * `horizontal` — row of items, drag left/right.
1161
+ * `grid` — 2D wrap, drag in any direction.
1162
+ * Match this to the layout your items render in. */
1163
+ strategy?: SortableStrategy;
1164
+ /** Disable drag on every item without rebuilding the tree. */
1165
+ disabled?: boolean;
1166
+ /** Stable container id — required when this Sortable is nested
1167
+ * inside a `Sortable.Group` for cross-container drag (the Group
1168
+ * routes drag-end events by container id). Optional for standalone
1169
+ * Sortable; auto-generated via React.useId when omitted. */
1170
+ id?: string;
1171
+ }
1172
+ interface SortableRootComponent extends React$1.ForwardRefExoticComponent<SortableProps & React$1.RefAttributes<HTMLDivElement>> {
1173
+ Item: typeof SortableItem;
1174
+ Handle: typeof SortableHandle;
1175
+ Group: typeof SortableGroup;
1176
+ }
1177
+ interface SortableItemProps extends React$1.HTMLAttributes<HTMLDivElement> {
1178
+ /** Must match one of the parent `<Sortable values>` entries.
1179
+ * Identity, not React key. */
1180
+ value: UniqueIdentifier;
1181
+ /** Render the item as its child element via Radix Slot — useful when
1182
+ * the wrapping div would mess with your layout (e.g. inside Table
1183
+ * rows). */
1184
+ asChild?: boolean;
1185
+ /** Disable drag for THIS item without disabling the whole Sortable. */
1186
+ disabled?: boolean;
1187
+ }
1188
+ declare const SortableItem: React$1.ForwardRefExoticComponent<SortableItemProps & React$1.RefAttributes<HTMLDivElement>>;
1189
+ interface SortableHandleProps extends React$1.HTMLAttributes<HTMLElement> {
1190
+ /** Render as the child element via Slot — typical pattern is
1191
+ * `<Sortable.Handle asChild><Button variant="ghost" size="icon">…</Button></Sortable.Handle>`. */
1192
+ asChild?: boolean;
1193
+ }
1194
+ declare const SortableHandle: React$1.ForwardRefExoticComponent<SortableHandleProps & React$1.RefAttributes<HTMLElement>>;
1195
+ declare const Sortable: SortableRootComponent;
1196
+
495
1197
  /**
496
1198
  * Stack — vertical layout primitive.
497
1199
  *
@@ -508,7 +1210,8 @@ declare const Slider: React$1.ForwardRefExoticComponent<Omit<SliderPrimitive.Sli
508
1210
  */
509
1211
  declare const stackVariants: (props?: ({
510
1212
  gap?: "none" | "sm" | "md" | "lg" | "xs" | "xl" | "2xl" | null | undefined;
511
- align?: "center" | "end" | "start" | "stretch" | null | undefined;
1213
+ align?: "start" | "center" | "end" | "stretch" | null | undefined;
1214
+ justify?: "start" | "center" | "end" | "between" | "around" | "evenly" | null | undefined;
512
1215
  } & class_variance_authority_types.ClassProp) | undefined) => string;
513
1216
  interface StackProps extends React$1.HTMLAttributes<HTMLDivElement>, VariantProps<typeof stackVariants> {
514
1217
  /** When true, render as the single child element via Radix Slot — lets
@@ -529,37 +1232,15 @@ declare const TableHead: React$1.ForwardRefExoticComponent<React$1.ThHTMLAttribu
529
1232
  declare const TableCell: React$1.ForwardRefExoticComponent<React$1.TdHTMLAttributes<HTMLTableCellElement> & React$1.RefAttributes<HTMLTableCellElement>>;
530
1233
  declare const TableCaption: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTMLTableCaptionElement> & React$1.RefAttributes<HTMLTableCaptionElement>>;
531
1234
 
532
- /**
533
- * Breadcrumb composable navigation primitive.
534
- *
535
- * Pure surface-less component (no background, no border, no sticky
536
- * positioning). Density matches `TabsTrigger` so a breadcrumb row
537
- * placed above a tab strip — or alongside one — reads at the same
538
- * scale.
539
- *
540
- * Composition is shadcn-flavoured:
541
- *
542
- * <Breadcrumb>
543
- * <BreadcrumbList>
544
- * <BreadcrumbItem>
545
- * <BreadcrumbLink onClick={onBack}>All screens</BreadcrumbLink>
546
- * </BreadcrumbItem>
547
- * <BreadcrumbSeparator />
548
- * <BreadcrumbItem>
549
- * <BreadcrumbPage>Pricing</BreadcrumbPage>
550
- * </BreadcrumbItem>
551
- * </BreadcrumbList>
552
- * </Breadcrumb>
553
- *
554
- * Note: the `TopMenu` component in this package wraps the same
555
- * breadcrumb idea in an app-bar surface (sticky, bordered, padded).
556
- * Use TopMenu when you want the full app-shell chrome; use
557
- * Breadcrumb on its own when you want navigation embedded inside an
558
- * existing surface (e.g. inside the Studio canvas).
559
- */
560
- declare const Breadcrumb: React$1.ForwardRefExoticComponent<Omit<React$1.DetailedHTMLProps<React$1.HTMLAttributes<HTMLElement>, HTMLElement>, "ref"> & {
1235
+ interface BreadcrumbProps extends React$1.ComponentPropsWithoutRef<"nav"> {
1236
+ /** Default separator node for every <BreadcrumbSeparator/> inside this
1237
+ * tree. Pass a string ("/", "›", "•"), a lucide icon (<Slash />,
1238
+ * <ChevronRight />), or any ReactNode. Default: <ChevronRight />.
1239
+ * Per-instance `<BreadcrumbSeparator>children</BreadcrumbSeparator>`
1240
+ * still overrides. */
561
1241
  separator?: React$1.ReactNode;
562
- } & React$1.RefAttributes<HTMLElement>>;
1242
+ }
1243
+ declare const Breadcrumb: React$1.ForwardRefExoticComponent<BreadcrumbProps & React$1.RefAttributes<HTMLElement>>;
563
1244
  declare const BreadcrumbList: React$1.ForwardRefExoticComponent<Omit<React$1.DetailedHTMLProps<React$1.OlHTMLAttributes<HTMLOListElement>, HTMLOListElement>, "ref"> & React$1.RefAttributes<HTMLOListElement>>;
564
1245
  declare const BreadcrumbItem: React$1.ForwardRefExoticComponent<Omit<React$1.DetailedHTMLProps<React$1.LiHTMLAttributes<HTMLLIElement>, HTMLLIElement>, "ref"> & React$1.RefAttributes<HTMLLIElement>>;
565
1246
  interface BreadcrumbLinkProps extends React$1.HTMLAttributes<HTMLElement> {
@@ -579,12 +1260,63 @@ declare const BreadcrumbEllipsis: {
579
1260
  ({ className, ...props }: React$1.ComponentProps<"span">): React$1.JSX.Element;
580
1261
  displayName: string;
581
1262
  };
1263
+ /** One row inside a BreadcrumbMenuTrigger's popover. The dropdown
1264
+ * renders the label as the main text and (optionally) a small
1265
+ * muted summary line below. `active` is the visual cue for "this
1266
+ * is the current trail node" so users can tell which entry maps
1267
+ * to their current path. `hasChildren` adds a `›` so the user
1268
+ * knows this entry has its own sub-menu when they pick it. */
1269
+ interface BreadcrumbMenuItem {
1270
+ id: string;
1271
+ label: string;
1272
+ summary?: string;
1273
+ active?: boolean;
1274
+ hasChildren?: boolean;
1275
+ }
1276
+ interface BreadcrumbMenuTriggerProps {
1277
+ /** The label that appears in the breadcrumb itself (e.g. "Stack",
1278
+ * "AppShellMain"). Distinct from the items: this is the segment
1279
+ * the user is hovering, not its children. */
1280
+ label: string;
1281
+ /** Items to render in the popover when the segment is opened.
1282
+ * Typically the children of the node this segment represents. */
1283
+ items: BreadcrumbMenuItem[];
1284
+ /** Called with the picked item's id when the user makes a
1285
+ * selection. The popover auto-closes on select. */
1286
+ onSelect: (id: string) => void;
1287
+ /** Optional click handler for the segment label itself (not the
1288
+ * dropdown). Useful when the host wants clicking the label to
1289
+ * also select that node directly. When omitted, the label is
1290
+ * purely a popover trigger. */
1291
+ onSelectLabel?: () => void;
1292
+ /** When true, mark the trigger as the current trail position.
1293
+ * Visually heavier (matches BreadcrumbPage's weight) and the
1294
+ * chevron rotates down to signal "you are here." */
1295
+ current?: boolean;
1296
+ className?: string;
1297
+ }
1298
+ /**
1299
+ * Segment that opens a popover of children/peers. Composes inside
1300
+ * a `<BreadcrumbItem>` exactly where you'd otherwise put a
1301
+ * `<BreadcrumbLink>` — same density, same focus ring.
1302
+ *
1303
+ * <BreadcrumbItem>
1304
+ * <BreadcrumbMenuTrigger
1305
+ * label="Stack"
1306
+ * items={children}
1307
+ * onSelect={selectById}
1308
+ * />
1309
+ * </BreadcrumbItem>
1310
+ */
1311
+ declare const BreadcrumbMenuTrigger: React$1.ForwardRefExoticComponent<BreadcrumbMenuTriggerProps & React$1.RefAttributes<HTMLButtonElement>>;
582
1312
 
583
1313
  declare const Tabs: React$1.ForwardRefExoticComponent<TabsPrimitive.TabsProps & React$1.RefAttributes<HTMLDivElement>>;
584
1314
  declare const tabsListVariants: (props?: ({
1315
+ variant?: "pill" | "underlined" | null | undefined;
585
1316
  size?: "sm" | "md" | "lg" | null | undefined;
586
1317
  } & class_variance_authority_types.ClassProp) | undefined) => string;
587
1318
  declare const tabsTriggerVariants: (props?: ({
1319
+ variant?: "pill" | "underlined" | null | undefined;
588
1320
  size?: "sm" | "md" | "lg" | null | undefined;
589
1321
  } & class_variance_authority_types.ClassProp) | undefined) => string;
590
1322
  interface TabsListProps extends React$1.ComponentPropsWithoutRef<typeof TabsPrimitive.List>, VariantProps<typeof tabsListVariants> {
@@ -617,6 +1349,11 @@ declare const Toggle: React$1.ForwardRefExoticComponent<Omit<TogglePrimitive.Tog
617
1349
  size?: "default" | "sm" | "lg" | null | undefined;
618
1350
  } & class_variance_authority_types.ClassProp) | undefined) => string> & React$1.RefAttributes<HTMLButtonElement>>;
619
1351
 
1352
+ declare const TooltipProvider: React$1.FC<TooltipPrimitive.TooltipProviderProps>;
1353
+ declare const Tooltip: React$1.FC<TooltipPrimitive.TooltipProps>;
1354
+ declare const TooltipTrigger: React$1.ForwardRefExoticComponent<TooltipPrimitive.TooltipTriggerProps & React$1.RefAttributes<HTMLButtonElement>>;
1355
+ declare const TooltipContent: React$1.ForwardRefExoticComponent<Omit<TooltipPrimitive.TooltipContentProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
1356
+
620
1357
  declare const toggleGroupVariants: (props?: ({
621
1358
  size?: "sm" | "md" | "lg" | null | undefined;
622
1359
  } & class_variance_authority_types.ClassProp) | undefined) => string;
@@ -624,157 +1361,503 @@ type ToggleGroupProps = React$1.ComponentPropsWithoutRef<typeof ToggleGroupPrimi
624
1361
  declare const ToggleGroup: React$1.ForwardRefExoticComponent<ToggleGroupProps & React$1.RefAttributes<HTMLDivElement>>;
625
1362
  declare const ToggleGroupItem: React$1.ForwardRefExoticComponent<Omit<ToggleGroupPrimitive.ToggleGroupItemProps & React$1.RefAttributes<HTMLButtonElement>, "ref"> & VariantProps<(props?: ({
626
1363
  size?: "sm" | "md" | "lg" | null | undefined;
627
- } & class_variance_authority_types.ClassProp) | undefined) => string> & React$1.RefAttributes<HTMLButtonElement>>;
1364
+ } & class_variance_authority_types.ClassProp) | undefined) => string> & {
1365
+ /** Tooltip content. When set, the item is wrapped in a Tooltip
1366
+ * so icon-only items keep an accessible label without bloating
1367
+ * the chrome with text. Pass a string for the common case;
1368
+ * pass a node for richer content (key hint, badge, etc.).
1369
+ *
1370
+ * Assumes a `TooltipProvider` exists somewhere upstream — in
1371
+ * apps/docs the root layout already mounts one, which is the
1372
+ * pattern most consumers should follow. If no provider is
1373
+ * present, the tooltip is silently ignored at runtime (Radix
1374
+ * no-ops) — pass `tooltip={undefined}` to be sure of plain
1375
+ * behavior. */
1376
+ tooltip?: React$1.ReactNode;
1377
+ /** Which side of the item the tooltip renders on. Defaults to
1378
+ * "top" — matches the Tabs primitive's convention. */
1379
+ tooltipSide?: React$1.ComponentPropsWithoutRef<typeof TooltipContent>["side"];
1380
+ /** Tooltip delay override. The provider's `delayDuration` is
1381
+ * the default; pass a per-item value if a specific control
1382
+ * needs a snappier or quieter feel. */
1383
+ tooltipDelay?: number;
1384
+ } & React$1.RefAttributes<HTMLButtonElement>>;
628
1385
 
629
- interface SideMenuItem {
630
- id: string;
631
- label: string;
632
- href?: string;
633
- icon?: React$1.ReactNode;
634
- badge?: string | number;
635
- onClick?: () => void;
636
- disabled?: boolean;
1386
+ /**
1387
+ * Toolbar — slot-based chrome bar for the leading/center/trailing
1388
+ * pattern Apple HIG describes as a "Toolbar."
1389
+ *
1390
+ * ┌─────────────────────────────────────────────────┐
1391
+ * │ [leading] [center] [trailing]
1392
+ * └─────────────────────────────────────────────────┘
1393
+ *
1394
+ * The three-region top nav is everywhere — Reddit, Twitter, GitHub,
1395
+ * Linear's top bar, every desktop app's window chrome — and most
1396
+ * scaffolds end up rebuilding it from raw `<Row justify="between">`
1397
+ * with a manual flex-1 on the center. This primitive collapses that
1398
+ * into:
1399
+ *
1400
+ * <Toolbar leading={<Logo/>} center={<Search/>} trailing={<Avatar/>} />
1401
+ *
1402
+ * The grid template is `auto 1fr auto`, so the center slot absorbs
1403
+ * available width and stays visually centered relative to the bar
1404
+ * (not relative to the gap between leading and trailing). If any
1405
+ * slot is omitted, the grid column collapses cleanly.
1406
+ *
1407
+ * Accessibility — role="toolbar" by default, with aria-label expected
1408
+ * via props. WAI-ARIA toolbar pattern: children should be keyboard-
1409
+ * navigable via arrow keys if they're a tight set of related actions.
1410
+ * For an app chrome bar (logo + nav + actions) the standard tab
1411
+ * sequence is usually fine and a single aria-label is enough; for an
1412
+ * editor-style toolbar (B / I / S / link), pair with a roving
1413
+ * tabindex implementation. (Roving tabindex is out of scope for v1 —
1414
+ * if you need it, compose with @radix-ui/react-toolbar's primitives
1415
+ * inside the slots.)
1416
+ *
1417
+ * Anatomy:
1418
+ * Toolbar — <div role="toolbar"> by default; sets the grid
1419
+ * Toolbar.Slot — exported for symmetry but rarely needed; the
1420
+ * leading/center/trailing props are the canonical
1421
+ * API
1422
+ *
1423
+ * Variants:
1424
+ * position — "top" | "bottom" | "inline" (border placement)
1425
+ * variant — "default" | "subtle" | "transparent"
1426
+ * size — "sm" | "md" | "lg" (height + padding)
1427
+ * sticky — boolean (sticky to top/bottom)
1428
+ *
1429
+ * Used for: app window chrome (AppShellHeader), section toolbars
1430
+ * inside a card or panel, action bars at the bottom of a list,
1431
+ * persistent footer toolbars on mobile-style layouts.
1432
+ */
1433
+ declare const toolbarVariants: (props?: ({
1434
+ position?: "top" | "bottom" | "inline" | null | undefined;
1435
+ variant?: "default" | "subtle" | "transparent" | null | undefined;
1436
+ size?: "sm" | "md" | "lg" | null | undefined;
1437
+ sticky?: boolean | null | undefined;
1438
+ } & class_variance_authority_types.ClassProp) | undefined) => string;
1439
+ interface ToolbarProps extends Omit<React$1.HTMLAttributes<HTMLDivElement>, "title">, VariantProps<typeof toolbarVariants> {
1440
+ /** Left-aligned content. Usually a logo + primary nav links. */
1441
+ leading?: React$1.ReactNode;
1442
+ /** Center-aligned content. Usually a search input, a page title,
1443
+ * or a segmented control. The center column stretches via `1fr`
1444
+ * so it stays visually centered relative to the bar. */
1445
+ center?: React$1.ReactNode;
1446
+ /** Right-aligned content. Usually action icons + user avatar. */
1447
+ trailing?: React$1.ReactNode;
1448
+ /** When using `children` directly (advanced custom layout), the
1449
+ * slot props are ignored. Most callers should prefer the slot
1450
+ * props — they give the canonical grid layout for free. */
1451
+ children?: React$1.ReactNode;
1452
+ /** Required by WAI-ARIA toolbar pattern. Falls back to "Toolbar". */
1453
+ "aria-label"?: string;
637
1454
  }
638
- interface SideMenuSection {
639
- id: string;
640
- title: string;
641
- icon?: React$1.ReactNode;
642
- items: SideMenuItem[];
643
- defaultExpanded?: boolean;
1455
+ declare const Toolbar: React$1.ForwardRefExoticComponent<ToolbarProps & React$1.RefAttributes<HTMLDivElement>>;
1456
+ /**
1457
+ * ToolbarSlot — escape-hatch piece for the rare case a consumer
1458
+ * wants to compose a custom inner layout with children but still
1459
+ * get the slot styling. Use the slot props on Toolbar where you can.
1460
+ */
1461
+ interface ToolbarSlotProps extends React$1.HTMLAttributes<HTMLDivElement> {
1462
+ align?: "leading" | "center" | "trailing";
644
1463
  }
645
- interface SideMenuProps {
646
- /** Header content (logo, title, etc.) */
647
- header?: React$1.ReactNode;
648
- /** Header content shown when collapsed (icon, etc.) */
649
- collapsedHeader?: React$1.ReactNode;
650
- /** Navigation sections with collapsible groups */
651
- sections?: SideMenuSection[];
652
- /** Standalone items without sections */
653
- items?: SideMenuItem[];
654
- /** Footer content */
655
- footer?: React$1.ReactNode;
656
- /** Whether the sidebar is collapsed */
1464
+ declare const ToolbarSlot: React$1.ForwardRefExoticComponent<ToolbarSlotProps & React$1.RefAttributes<HTMLDivElement>>;
1465
+
1466
+ /**
1467
+ * Sidebar compound layout primitive for vertical app navigation.
1468
+ *
1469
+ * Renamed from `SideMenu` (May 2026) and rebuilt around a compound API
1470
+ * so consumers can slot custom content into the header/content/footer
1471
+ * regions instead of being forced through a data-driven `sections=[...]`
1472
+ * prop. Replaces the previous single-component shape entirely.
1473
+ *
1474
+ * Why compound: sidebars vary wildly across products — Notion-style
1475
+ * workspace switcher up top, search input below, scrollable nav in the
1476
+ * middle, user profile + settings link at the bottom. The old data-
1477
+ * driven SideMenu could express the section list cleanly but anything
1478
+ * non-list-shaped (search inputs, drag handles, command-K trigger
1479
+ * pills, custom brand blocks) had to fight the API. Compound trades
1480
+ * "two lines of JSX" for "any shape the consumer wants."
1481
+ *
1482
+ * Compound shape:
1483
+ *
1484
+ * <Sidebar>
1485
+ * <SidebarHeader> // brand / logo / org switcher
1486
+ * <SidebarContent> // scrollable body
1487
+ * <SidebarSection title="Workspace">
1488
+ * <SidebarItem href="/" icon={<Home />}>Dashboard</SidebarItem>
1489
+ * <SidebarItem href="/inbox" icon={<Inbox />} badge={3}>Inbox</SidebarItem>
1490
+ * </SidebarSection>
1491
+ * </SidebarContent>
1492
+ * <SidebarFooter> // user / settings / pinned chrome
1493
+ * </Sidebar>
1494
+ *
1495
+ * For routing integration, `<SidebarItem href>` renders an `<a>` by
1496
+ * default. Drop `asChild` to wrap any link component (Next/Link, React
1497
+ * Router Link, Remix Link, etc.) — Radix Slot stamps the item's classes
1498
+ * onto whatever you pass:
1499
+ *
1500
+ * <SidebarItem asChild icon={<Home />}>
1501
+ * <Link href="/">Dashboard</Link>
1502
+ * </SidebarItem>
1503
+ *
1504
+ * Theming: visual surfaces (bg, border, text colour) come from semantic
1505
+ * theme tokens, not hard-coded greys. Sizing knobs (collapsed width,
1506
+ * expanded width, item padding) live as `--gds-sidebar-*` CSS variables
1507
+ * so the consumer can retune without prop drilling.
1508
+ *
1509
+ * Composition: Sidebar slots inside `<AppShellNav placement="side">`
1510
+ * exactly the way SideMenu did; AppShell is the page-level chrome,
1511
+ * Sidebar is the navigation content for that chrome.
1512
+ */
1513
+
1514
+ interface SidebarProps extends React$1.HTMLAttributes<HTMLElement> {
1515
+ /** Controlled collapsed state. When set, `onCollapsedChange` MUST be
1516
+ * wired or the toggle button becomes a no-op. */
657
1517
  collapsed?: boolean;
658
- /** Callback when collapsed state changes */
659
- onCollapsedChange?: (collapsed: boolean) => void;
660
- /** Whether the sidebar can be collapsed */
661
- collapsible?: boolean;
662
- /** Default collapsed state */
1518
+ /** Uncontrolled initial collapsed state. Ignored if `collapsed` is set. */
663
1519
  defaultCollapsed?: boolean;
664
- /** Currently active item id */
665
- activeItem?: string;
666
- /** Custom className */
667
- className?: string;
668
- /** Custom link component (e.g., Next.js Link) */
669
- linkComponent?: React$1.ComponentType<{
670
- href: string;
671
- className?: string;
672
- children: React$1.ReactNode;
673
- }>;
1520
+ /** Fired when the toggle button flips collapsed state. */
1521
+ onCollapsedChange?: (next: boolean) => void;
1522
+ /** Show / hide the affordance for the user to collapse. Defaults true. */
1523
+ collapsible?: boolean;
1524
+ /**
1525
+ * Visual treatment.
1526
+ *
1527
+ * - `"rail"` (default) — the classic nav rail: sits flush against an
1528
+ * adjacent surface with only a right-side border, fixed width via
1529
+ * `--gds-sidebar-width`. Designed to slot into `<AppShellNav placement="side">`.
1530
+ * - `"panel"` — a floating card-style sidebar: full border, rounded
1531
+ * corners, width inherited from the parent (typically a flex/grid
1532
+ * track). Use when the sidebar is one of several adjacent panes
1533
+ * in a body row, like Studio's `Projects | Canvas | Settings`.
1534
+ *
1535
+ * The variant affects ONLY the outer chrome — header/content/footer/
1536
+ * section/item internals are identical so the same compound markup
1537
+ * works in both treatments.
1538
+ */
1539
+ variant?: "rail" | "panel";
674
1540
  }
675
- declare const SideMenu: React$1.ForwardRefExoticComponent<SideMenuProps & React$1.RefAttributes<HTMLElement>>;
676
-
677
- interface SimpleTab {
678
- id: string;
679
- label: string;
680
- icon?: React$1.ReactNode;
681
- disabled?: boolean;
1541
+ interface SidebarRootComponent extends React$1.ForwardRefExoticComponent<SidebarProps & React$1.RefAttributes<HTMLElement>> {
1542
+ Header: typeof SidebarHeader;
1543
+ Content: typeof SidebarContent;
1544
+ Footer: typeof SidebarFooter;
1545
+ Section: typeof SidebarSection;
1546
+ Item: typeof SidebarItem;
1547
+ TreeItem: typeof SidebarTreeItem;
682
1548
  }
683
- interface SimpleTabsProps {
684
- /** Array of tab definitions */
685
- tabs: SimpleTab[];
686
- /** Currently active tab id */
687
- activeTab?: string;
688
- /** Default active tab id (for uncontrolled mode) */
689
- defaultTab?: string;
690
- /** Callback when tab changes */
691
- onTabChange?: (tabId: string) => void;
692
- /** Tab panel children */
693
- children?: React$1.ReactNode;
694
- /** Custom className for the container */
695
- className?: string;
696
- /** Custom className for the tabs list */
697
- tabsClassName?: string;
1549
+ declare const Sidebar: SidebarRootComponent;
1550
+ interface SidebarHeaderProps extends React$1.HTMLAttributes<HTMLDivElement> {
698
1551
  }
699
- interface SimpleTabsPanelProps {
700
- /** Tab id this panel corresponds to */
701
- id: string;
702
- /** Panel content */
703
- children: React$1.ReactNode;
704
- /** Custom className */
705
- className?: string;
1552
+ declare const SidebarHeader: React$1.ForwardRefExoticComponent<SidebarHeaderProps & React$1.RefAttributes<HTMLDivElement>>;
1553
+ interface SidebarContentProps extends React$1.HTMLAttributes<HTMLElement> {
706
1554
  }
707
- declare const SimpleTabs: React$1.ForwardRefExoticComponent<SimpleTabsProps & React$1.RefAttributes<HTMLDivElement>>;
708
- declare const SimpleTabsPanel: React$1.ForwardRefExoticComponent<SimpleTabsPanelProps & React$1.RefAttributes<HTMLDivElement>>;
709
- interface SimpleTabsRootProps {
710
- /** Currently active tab id */
711
- activeTab?: string;
712
- /** Default active tab id (for uncontrolled mode) */
713
- defaultTab?: string;
714
- /** Callback when tab changes */
715
- onTabChange?: (tabId: string) => void;
716
- /** Children (SimpleTabsList and SimpleTabsPanel components) */
717
- children: React$1.ReactNode;
718
- /** Custom className */
719
- className?: string;
1555
+ declare const SidebarContent: React$1.ForwardRefExoticComponent<SidebarContentProps & React$1.RefAttributes<HTMLElement>>;
1556
+ interface SidebarFooterProps extends React$1.HTMLAttributes<HTMLDivElement> {
720
1557
  }
721
- declare const SimpleTabsRoot: React$1.ForwardRefExoticComponent<SimpleTabsRootProps & React$1.RefAttributes<HTMLDivElement>>;
722
- interface SimpleTabsListProps {
723
- children: React$1.ReactNode;
724
- className?: string;
1558
+ declare const SidebarFooter: React$1.ForwardRefExoticComponent<SidebarFooterProps & React$1.RefAttributes<HTMLDivElement>>;
1559
+ interface SidebarSectionProps extends Omit<React$1.HTMLAttributes<HTMLDivElement>, "title"> {
1560
+ /** Group label shown above the items. Hidden when sidebar is collapsed
1561
+ * (children render flat under the icon strip). */
1562
+ title?: React$1.ReactNode;
1563
+ /** Optional icon next to the title. */
1564
+ icon?: React$1.ReactNode;
1565
+ /** Action(s) rendered on the right edge of the section header — the
1566
+ * canonical "+ add to this group" or "..." menu slot. Common in Notion
1567
+ * (+ next to Pages), Linear (+ next to Favorites), Slack (+ next to
1568
+ * Channels). Rendered as a sibling of the chevron when `collapsible`,
1569
+ * otherwise pinned to the right edge of the static header.
1570
+ * Pointer events on the trailing content are isolated from the
1571
+ * collapse toggle, so a Button inside `trailing` won't also flip the
1572
+ * expanded state. */
1573
+ trailing?: React$1.ReactNode;
1574
+ /** Allow the section to toggle open/closed via clicking the title.
1575
+ * Default true when `title` is set; ignored otherwise (no header to click). */
1576
+ collapsible?: boolean;
1577
+ /** Initial open state for collapsible sections. Default true. */
1578
+ defaultExpanded?: boolean;
725
1579
  }
726
- declare const SimpleTabsList: React$1.ForwardRefExoticComponent<SimpleTabsListProps & React$1.RefAttributes<HTMLDivElement>>;
727
- interface SimpleTabsTriggerProps {
728
- /** Tab id */
729
- value: string;
730
- /** Tab content */
731
- children: React$1.ReactNode;
732
- /** Tab icon */
1580
+ declare const SidebarSection: React$1.ForwardRefExoticComponent<SidebarSectionProps & React$1.RefAttributes<HTMLDivElement>>;
1581
+ interface SidebarItemProps extends Omit<React$1.AnchorHTMLAttributes<HTMLAnchorElement>, "children" | "title"> {
1582
+ /** Leading icon. Sized to fit both expanded + collapsed states. */
733
1583
  icon?: React$1.ReactNode;
734
- /** Disabled state */
1584
+ /** Trailing badge — count, status label. Hidden when collapsed. */
1585
+ badge?: React$1.ReactNode;
1586
+ /** Marks the current page / route. Drives the highlighted style + sets
1587
+ * `aria-current="page"`. */
1588
+ active?: boolean;
1589
+ /** Render the item as a button rather than a link. Use when the row
1590
+ * triggers an action (open dialog, log out) rather than navigation. */
1591
+ asButton?: boolean;
1592
+ /** Wrap a custom link component (Next/Link, etc.) via Radix Slot
1593
+ * rather than rendering a plain <a>. Mutually exclusive with `asButton`. */
1594
+ asChild?: boolean;
1595
+ /** Disabled state — visual greying + pointer-events-none. */
735
1596
  disabled?: boolean;
736
- /** Custom className */
737
- className?: string;
1597
+ /** Visible label. Use `children` so the JSX reads naturally — the
1598
+ * prop name is `children` not `label`. */
1599
+ children?: React$1.ReactNode;
1600
+ /** Tooltip override shown when sidebar is collapsed. Defaults to the
1601
+ * item's text content (children, when it's a string). */
1602
+ collapsedLabel?: React$1.ReactNode;
1603
+ /**
1604
+ * Row size.
1605
+ *
1606
+ * - `"md"` (default) — `text-sm font-medium`, the standard nav row.
1607
+ * - `"sm"` — `text-xs`, lighter weight + tighter padding. Use for
1608
+ * visually-subordinate rows (nested screens under a parent
1609
+ * project, sub-pages under a section, etc.) so the hierarchy is
1610
+ * legible without manual className overrides. Active state still
1611
+ * wins on color + weight so the current row pops at either size.
1612
+ */
1613
+ size?: "sm" | "md";
1614
+ /**
1615
+ * Secondary line shown beneath the label — typically metadata like
1616
+ * "Edited 2m ago", "12 items", or a brief description. Layout
1617
+ * adapts: the row becomes label + description stacked vertically,
1618
+ * with the icon vertically centered against the stack and the
1619
+ * badge anchored to the trailing edge as usual. Hidden when the
1620
+ * sidebar is collapsed (only the icon + tooltip remain).
1621
+ */
1622
+ description?: React$1.ReactNode;
738
1623
  }
739
- declare const SimpleTabsTrigger: React$1.ForwardRefExoticComponent<SimpleTabsTriggerProps & React$1.RefAttributes<HTMLButtonElement>>;
740
- declare const SimpleTabsContent: React$1.ForwardRefExoticComponent<{
741
- value: string;
742
- children: React$1.ReactNode;
743
- className?: string;
744
- } & React$1.RefAttributes<HTMLDivElement>>;
745
-
746
- declare const TooltipProvider: React$1.FC<TooltipPrimitive.TooltipProviderProps>;
747
- declare const Tooltip: React$1.FC<TooltipPrimitive.TooltipProps>;
748
- declare const TooltipTrigger: React$1.ForwardRefExoticComponent<TooltipPrimitive.TooltipTriggerProps & React$1.RefAttributes<HTMLButtonElement>>;
749
- declare const TooltipContent: React$1.ForwardRefExoticComponent<Omit<TooltipPrimitive.TooltipContentProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
1624
+ declare const SidebarItem: React$1.ForwardRefExoticComponent<SidebarItemProps & React$1.RefAttributes<HTMLAnchorElement>>;
1625
+ interface SidebarTreeItemProps extends Omit<React$1.ButtonHTMLAttributes<HTMLButtonElement>, "children" | "title"> {
1626
+ /** Row label. Required — without it the row has nothing to show. */
1627
+ label: React$1.ReactNode;
1628
+ /** Leading icon (folder, file, custom emoji). Shown to the right
1629
+ * of the chevron column. */
1630
+ icon?: React$1.ReactNode;
1631
+ /** Trailing badge — count, status. Hidden when sidebar is collapsed. */
1632
+ badge?: React$1.ReactNode;
1633
+ /** Marks the branch as the current route. Adds aria-current="page"
1634
+ * on the row. */
1635
+ active?: boolean;
1636
+ /** Initial expanded state. Defaults `true` so the user can see what's
1637
+ * inside without having to click. */
1638
+ defaultExpanded?: boolean;
1639
+ /** Controlled expanded state — wire `onExpandedChange` to manage from
1640
+ * outside (useful when you want to persist tree state). */
1641
+ expanded?: boolean;
1642
+ onExpandedChange?: (next: boolean) => void;
1643
+ /** Disabled state. */
1644
+ disabled?: boolean;
1645
+ /** Nested children — SidebarItem or more SidebarTreeItem. */
1646
+ children?: React$1.ReactNode;
1647
+ /**
1648
+ * Secondary line shown beneath the label — same shape as
1649
+ * SidebarItem's `description`. Useful when a branch needs more
1650
+ * than just a name (last-edited timestamp, item count, owner).
1651
+ * Layout adapts to stack label + description; chevron and icon
1652
+ * stay vertically centered against the stack.
1653
+ */
1654
+ description?: React$1.ReactNode;
1655
+ /**
1656
+ * Right-edge action slot — settings cog, more-actions overflow,
1657
+ * "+ add child" affordance. Rendered as a sibling of the branch
1658
+ * button (not nested inside it, so `<button>` children inside
1659
+ * trailing remain valid HTML). Vertically centered against the
1660
+ * branch row, isolated from the expand/collapse click so a tap
1661
+ * on a trailing button doesn't toggle the tree.
1662
+ *
1663
+ * The wrapper container also exposes a `group/row` named-group
1664
+ * class so consumer-provided trailing can opt into hover-only
1665
+ * visibility via Tailwind's `group-hover/row:` variant
1666
+ * (`hidden group-hover/row:flex`) without writing custom CSS.
1667
+ * Hovering nested children rows does NOT trigger the group hover
1668
+ * — the named group is scoped to the branch row alone.
1669
+ */
1670
+ trailing?: React$1.ReactNode;
1671
+ }
1672
+ declare const SidebarTreeItem: React$1.ForwardRefExoticComponent<SidebarTreeItemProps & React$1.RefAttributes<HTMLButtonElement>>;
750
1673
 
751
1674
  declare const Map: React$1.ForwardRefExoticComponent<MapProps & React$1.RefAttributes<MapHandle>>;
752
1675
 
753
1676
  declare const MapMarker: React$1.NamedExoticComponent<MapMarkerProps>;
754
1677
 
755
1678
  /**
756
- * MediaSurface — the shared shell used by VideoPlayer, RivePlayer,
757
- * and ThreeScene. Not exported publicly.
1679
+ * MediaSurface — the shared shell used by VideoPlayer, RivePlayer, ThreeScene
1680
+ * AND the canonical "media slot" primitive for still images, posters, album
1681
+ * art, etc.
758
1682
  *
759
1683
  * Handles the surface area that's identical across all media types:
760
1684
  * - aspect ratio / radius / border (driven by CSS variables for theming)
761
1685
  * - loading skeleton
762
1686
  * - intersection-observer (for pause-when-offscreen)
763
1687
  * - reduced-motion query
1688
+ * - **empty-state placeholder** with format-suggesting glyph + alt caption
764
1689
  *
765
1690
  * Design-system note: all visual dimensions are backed by CSS vars so
766
- * consumers can retheme via `--rds-media-radius`, `--rds-media-border`,
767
- * `--rds-media-placeholder-bg`, `--rds-media-placeholder-fg`. The
768
- * placeholder pair drives the empty-state treatment — it's the
769
- * canonical "image not yet loaded" surface across Grade until the
770
- * image-generation pipeline replaces empty slots with real pictures.
771
- * Custom placeholder UI elsewhere in the product should consume the
772
- * same vars so we stay visually coherent.
1691
+ * consumers can retheme via `--gds-media-radius`, `--gds-media-border`,
1692
+ * `--gds-media-placeholder-bg`, `--gds-media-placeholder-fg`. The
1693
+ * placeholder pair drives the empty-state treatment — it's the canonical
1694
+ * "image not yet loaded" surface across Grade until the image-generation
1695
+ * pipeline replaces empty slots with real pictures. Custom placeholder UI
1696
+ * elsewhere in the product should consume the same vars so we stay
1697
+ * visually coherent.
773
1698
  * (These will rename to `--gds-*` when the broader codebase rename lands.)
1699
+ *
1700
+ * The placeholder uses a **size-tiered** rendering: sub-64px slots show
1701
+ * initials only (avatar-density), 64-160px show the format glyph alone,
1702
+ * and >160px add the alt text as a small caption beneath the glyph. The
1703
+ * tier is measured via ResizeObserver — we deliberately don't lean on CSS
1704
+ * container queries here so the component works in projects whose Tailwind
1705
+ * config doesn't have the container-queries plugin installed.
1706
+ *
1707
+ * **Do NOT wrap <Avatar> inside <MediaSurface>** to get a 2-letter initials
1708
+ * fallback. That pattern conflates two primitives — Avatar is for people
1709
+ * only (circular, social context); MediaSurface is for everything else
1710
+ * (square album art, wide landscapes, portrait posters). Set `alt` + `hint`
1711
+ * on MediaSurface directly and you get the same initials affordance with
1712
+ * the right semantics.
774
1713
  */
775
1714
 
776
1715
  type MediaAspect = "video" | "square" | "portrait" | "wide" | "auto";
777
1716
  type MediaRadius = "none" | "sm" | "md" | "lg" | "xl";
1717
+ /**
1718
+ * What kind of media is this slot intended for? Drives three things:
1719
+ * 1. The glyph rendered in the empty-state placeholder.
1720
+ * 2. The default `aspect` when the caller hasn't pinned one.
1721
+ * 3. The future generation pipeline's provider routing (album →
1722
+ * MusicBrainz cover-art, poster → TMDB, generic → Gemini, etc.).
1723
+ *
1724
+ * Kept as a small finite union so the Settings panel can render it as a
1725
+ * glyph-led toggle picker rather than a free-text input. Adding a hint
1726
+ * here means adding a glyph in `HINT_GLYPH` and a default aspect in
1727
+ * `HINT_DEFAULT_ASPECT` below — both maps are checked exhaustively.
1728
+ */
1729
+ type MediaHint = "album" | "tv-show" | "movie" | "game" | "book" | "portrait" | "landscape" | "poster" | "product" | "food" | "video" | "audio" | "embed" | "3d" | "generic";
1730
+ /**
1731
+ * Structured metadata the future generation pipeline reads to look up real
1732
+ * imagery for this slot. The component itself never renders from `source` —
1733
+ * it's purely declarative until the generator walks the JSX and patches in
1734
+ * `src` values. Discriminated by `kind` so we can route per-provider:
1735
+ *
1736
+ * album → MusicBrainz Cover Art Archive (free, no auth)
1737
+ * tv-show → TMDb (free with key)
1738
+ * movie → TMDb (free with key)
1739
+ * game → IGDB (free, Twitch OAuth)
1740
+ * book → OpenLibrary (free, no auth)
1741
+ * poster → Picsum (or wired generator)
1742
+ * portrait → Picsum (until prompt-aware generator lands)
1743
+ * landscape→ Picsum (until prompt-aware generator lands)
1744
+ * product → Picsum (until prompt-aware generator lands)
1745
+ * food → Picsum (until prompt-aware generator lands)
1746
+ * generic → Picsum
1747
+ * video/audio/embed/3d → no auto-gen; user provides
1748
+ *
1749
+ * Every variant optionally carries a `description` string — populated
1750
+ * by Studio from the surface's `alt` prop via the Generate Image
1751
+ * action. Prompt-aware providers use it as the user-intent prompt;
1752
+ * lookup providers (MusicBrainz, TMDb, …) ignore unknown fields.
1753
+ */
1754
+ type MediaSource = {
1755
+ kind: "album";
1756
+ artist: string;
1757
+ title: string;
1758
+ year?: number;
1759
+ description?: string;
1760
+ } | {
1761
+ kind: "tv-show";
1762
+ title: string;
1763
+ year?: number;
1764
+ description?: string;
1765
+ } | {
1766
+ kind: "movie";
1767
+ title: string;
1768
+ year?: number;
1769
+ description?: string;
1770
+ } | {
1771
+ kind: "game";
1772
+ title: string;
1773
+ description?: string;
1774
+ } | {
1775
+ kind: "book";
1776
+ title?: string;
1777
+ author?: string;
1778
+ isbn?: string;
1779
+ description?: string;
1780
+ } | {
1781
+ kind: "portrait";
1782
+ name?: string;
1783
+ role?: string;
1784
+ description?: string;
1785
+ } | {
1786
+ kind: "landscape";
1787
+ location?: string;
1788
+ mood?: string;
1789
+ description?: string;
1790
+ } | {
1791
+ kind: "poster";
1792
+ title: string;
1793
+ year?: number;
1794
+ description?: string;
1795
+ } | {
1796
+ kind: "product";
1797
+ name?: string;
1798
+ brand?: string;
1799
+ description?: string;
1800
+ } | {
1801
+ kind: "food";
1802
+ dish?: string;
1803
+ cuisine?: string;
1804
+ description?: string;
1805
+ } | {
1806
+ kind: "video";
1807
+ } | {
1808
+ kind: "audio";
1809
+ } | {
1810
+ kind: "embed";
1811
+ } | {
1812
+ kind: "3d";
1813
+ } | {
1814
+ kind: "generic";
1815
+ prompt: string;
1816
+ description?: string;
1817
+ };
1818
+ /**
1819
+ * Subscribe to the runtime URL map exposed by Studio (and any other host
1820
+ * that wants to wire the same protocol). The map lives on `window.__gradeMediaUrls`
1821
+ * — a `Record<sourceKey, url>` — and emits `grade:media-urls-updated`
1822
+ * whenever it changes. Components reading the map re-render on the event.
1823
+ *
1824
+ * Headless / server-rendered consumers get an empty map; the resolution
1825
+ * only kicks in client-side.
1826
+ *
1827
+ * The map is intentionally **decoupled** from React context so consuming
1828
+ * apps don't have to thread a provider through their tree — MediaSurface
1829
+ * can be dropped anywhere in any layout and the URL map "just works"
1830
+ * once the host writes to the global. Studio's iframe agent writes to
1831
+ * the global in response to the "Fill images" flow; other integrations
1832
+ * (e.g. an MCP server, a CLI codemod) can use the same protocol.
1833
+ */
1834
+ type MediaUrlMap = Record<string, string>;
1835
+ /**
1836
+ * Per-instance prop overrides, keyed by the same `sourceKey` as the
1837
+ * URL map. Each entry is a partial MediaSurface props bag — only the
1838
+ * keys the user has customised for THIS specific slot. The studio
1839
+ * settings panel writes overrides via the `grade:component-action`
1840
+ * event with kind `"set-media-override"`; this component reads
1841
+ * `overrides[myKey]` at render and merges on top of its JSX props
1842
+ * so an edit on Discovery doesn't ripple to every other album in the
1843
+ * same `.map()`. See `useResolvedOverride` below.
1844
+ */
1845
+ type MediaOverrideMap = Record<string, Partial<{
1846
+ hint: MediaHint;
1847
+ aspect: MediaAspect;
1848
+ radius: MediaRadius;
1849
+ border: boolean;
1850
+ loading: boolean;
1851
+ alt: string;
1852
+ src: string;
1853
+ emptyState: "auto" | "icon" | "none";
1854
+ }>>;
1855
+ declare global {
1856
+ interface Window {
1857
+ __gradeMediaUrls?: MediaUrlMap;
1858
+ __gradeMediaOverrides?: MediaOverrideMap;
1859
+ }
1860
+ }
778
1861
  interface MediaSurfaceProps extends Omit<React$1.HTMLAttributes<HTMLDivElement>, "children"> {
779
1862
  aspect?: MediaAspect;
780
1863
  radius?: MediaRadius;
@@ -785,15 +1868,80 @@ interface MediaSurfaceProps extends Omit<React$1.HTMLAttributes<HTMLDivElement>,
785
1868
  /** Fallback shown before `onReady` is signalled by the child. */
786
1869
  fallback?: React$1.ReactNode;
787
1870
  /**
788
- * Controls the empty-state placeholder shown when no `children` and no
789
- * `loading` state are provided. Default `"icon"` renders a subtle
790
- * image-icon centered on the muted surface so the slot reads as
791
- * "media goes here" rather than blank. Use `"none"` for cases where
792
- * the consumer wants a truly empty surface (e.g. a custom decorative
793
- * overlay that needs the surface clean), or pass a node to fully
794
- * override.
1871
+ * Controls the empty-state placeholder shown when no `src`, `children`,
1872
+ * and no `loading` state are provided. Default `"auto"` renders the
1873
+ * size-tiered placeholder (initials / glyph / glyph + caption depending
1874
+ * on the slot's rendered width — see `tierFromWidth`). Use `"none"` for
1875
+ * a truly empty surface (e.g. a custom decorative overlay that needs
1876
+ * the surface clean), or pass a node to fully override.
1877
+ *
1878
+ * Legacy `"icon"` is kept as an alias for `"auto"` so the previous API
1879
+ * doesn't break.
1880
+ */
1881
+ emptyState?: "auto" | "icon" | "none" | React$1.ReactNode;
1882
+ /**
1883
+ * What kind of media is intended for this slot — drives the placeholder
1884
+ * glyph, the default `aspect` when unset, and the future generator's
1885
+ * provider routing. See `MediaHint`. Defaults to `"generic"` (image icon).
1886
+ */
1887
+ hint?: MediaHint;
1888
+ /**
1889
+ * Descriptive label for the slot. Used three ways:
1890
+ * 1. The `alt` attribute on the rendered `<img>` when `src` is set.
1891
+ * 2. The caption shown beneath the glyph in the large placeholder tier.
1892
+ * 3. The source string for derived 2-letter initials in the small tier.
1893
+ * Strongly recommended — without it the placeholder is anonymous and the
1894
+ * eventual image has no a11y label.
1895
+ */
1896
+ alt?: string;
1897
+ /**
1898
+ * Structured metadata for the generation pipeline. Opaque to MediaSurface
1899
+ * itself (it just stamps `data-media-source-kind` on the root for
1900
+ * inspector visibility); read by the generator AST walker to look up real
1901
+ * imagery from the right provider. See `MediaSource`.
1902
+ */
1903
+ source?: MediaSource;
1904
+ /**
1905
+ * When set, MediaSurface renders an `<img>` filling the slot via
1906
+ * object-cover. The wrapper keeps its aspect / radius / border chrome.
1907
+ * Convenience prop so callers don't have to write the `<img>` themselves;
1908
+ * also the target the future generator patches into when filling slots.
1909
+ */
1910
+ src?: string;
1911
+ /**
1912
+ * Override the hint-derived glyph for one-off cases. Most consumers
1913
+ * should pick a `hint` and let the map decide; this is the escape
1914
+ * hatch for special slots that don't fit the canonical set.
1915
+ */
1916
+ glyph?: React$1.ReactNode;
1917
+ /**
1918
+ * Stable identifier for this specific MediaSurface instance, stamped
1919
+ * on the root as `data-gds-instance-id`. When the JSX renders a list
1920
+ * of MediaSurfaces from a data array (`.map(a => <MediaSurface
1921
+ * instanceId={a.id} ... />)`), this is how Studio's selection agent
1922
+ * tells THIS card apart from its siblings — every other prop is
1923
+ * either shared via the template (hint, aspect) or content that
1924
+ * happens to differ but isn't guaranteed unique.
1925
+ *
1926
+ * Combined with the data-array-mutator path, this is what makes
1927
+ * "click Discovery, change its alt text, only Discovery's alt
1928
+ * changes" actually work — the panel finds the data entry whose
1929
+ * `id` matches `instanceId` and patches just that entry.
1930
+ *
1931
+ * No-op if omitted (standalone MediaSurfaces don't need it).
1932
+ */
1933
+ instanceId?: string;
1934
+ /**
1935
+ * Content layered ON TOP of the media (or placeholder) — play buttons,
1936
+ * hover gradients, corner badges, watch-progress bars. Renders in its
1937
+ * own absolutely-positioned layer at the highest z-index. Importantly,
1938
+ * an overlay does NOT suppress the empty-state placeholder: a play
1939
+ * button hovering over an unfilled album slot is still meaningfully
1940
+ * unfilled, and we want the placeholder to read through it. Use
1941
+ * `children` for content that REPLACES the media (custom canvas/video);
1942
+ * use `overlay` for content that DECORATES it.
795
1943
  */
796
- emptyState?: "icon" | "none" | React$1.ReactNode;
1944
+ overlay?: React$1.ReactNode;
797
1945
  children?: React$1.ReactNode;
798
1946
  }
799
1947
  declare const MediaSurface: React$1.ForwardRefExoticComponent<MediaSurfaceProps & React$1.RefAttributes<HTMLDivElement>>;
@@ -1458,7 +2606,7 @@ declare function themeToCSSVars(theme: GeneratedTheme, mode: ModeName): Record<s
1458
2606
  * CSS rules key off of.
1459
2607
  *
1460
2608
  * Safe to call repeatedly — each call fully resets the vars the theme
1461
- * controls. Vars the theme doesn't touch (e.g. --rds-green-500 in
2609
+ * controls. Vars the theme doesn't touch (e.g. --gds-green-500 in
1462
2610
  * globals.css) are left alone.
1463
2611
  */
1464
2612
  declare function applyThemeToRoot(theme: GeneratedTheme, mode: ModeName): void;
@@ -1544,7 +2692,7 @@ declare const ALL_MODES: ModeName[];
1544
2692
  * NOTE: this string is embedded directly into the <head> via
1545
2693
  * dangerouslySetInnerHTML. Keep it self-contained and dependency-free.
1546
2694
  */
1547
- declare const GRADE_PRE_HYDRATION_SCRIPT = "\n(function() {\n try {\n var mode = localStorage.getItem('ramp-mode');\n var valid = ['superLight','light','dark','superDark'];\n if (!mode || valid.indexOf(mode) === -1) {\n mode = window.matchMedia('(prefers-color-scheme: dark)').matches ? 'dark' : 'light';\n }\n if (mode === 'dark' || mode === 'superDark') {\n document.documentElement.classList.add('dark');\n }\n document.documentElement.setAttribute('data-mode', mode);\n var themeId = localStorage.getItem('ramp-theme');\n if (themeId) document.documentElement.setAttribute('data-ramp-theme', themeId);\n } catch(e) {}\n})();\n";
2695
+ declare const GRADE_PRE_HYDRATION_SCRIPT = "\n(function() {\n try {\n var mode = localStorage.getItem('grade-mode');\n var valid = ['superLight','light','dark','superDark'];\n if (!mode || valid.indexOf(mode) === -1) {\n mode = window.matchMedia('(prefers-color-scheme: dark)').matches ? 'dark' : 'light';\n }\n if (mode === 'dark' || mode === 'superDark') {\n document.documentElement.classList.add('dark');\n }\n document.documentElement.setAttribute('data-mode', mode);\n var themeId = localStorage.getItem('grade-theme');\n if (themeId) document.documentElement.setAttribute('data-grade-theme', themeId);\n } catch(e) {}\n})();\n";
1548
2696
  type GradeThemeContextValue = {
1549
2697
  /** The currently active theme object. */
1550
2698
  theme: GeneratedTheme;
@@ -1610,4 +2758,4 @@ declare function GradeModeSwitcher({ className, variant }: GradeModeSwitcherProp
1610
2758
  */
1611
2759
  declare function ThemeToggle(): React$1.JSX.Element;
1612
2760
 
1613
- export { ALL_MODES, Accordion, AccordionContent, AccordionItem, AccordionTrigger, Alert, AlertDescription, AlertTitle, AppShell, AppShellAside, type AppShellAsideProps, AppShellFooter, type AppShellFooterProps, AppShellHeader, type AppShellHeaderProps, AppShellMain, type AppShellMainProps, AppShellNav, type AppShellNavProps, type AppShellProps, Avatar, AvatarFallback, AvatarImage, BUILT_IN_INPUTS, Badge, type BaseMediaProps, Breadcrumb, BreadcrumbEllipsis, BreadcrumbItem, BreadcrumbLink, BreadcrumbList, BreadcrumbPage, BreadcrumbSeparator, Button, type ButtonShape, Calendar, CalendarDayButton, Card, CardContent, CardDescription, CardFooter, CardHeader, type CardStyle, CardTitle, type ChartPalette, Checkbox, type ColorIntensity, DatePicker, type DatePickerProps, DateRangePicker, type DateRangePickerProps, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, FRAGMENT_HEADER, Flex, type FlexProps, type FontKey, GRADE_PRE_HYDRATION_SCRIPT, type GeneratedTheme, GradeModeSwitcher, GradeThemeProvider, type GradeThemeProviderProps, GradeThemeSwitcher, Grid, type GridProps, Input, type InputStyle, Label, LenisProvider, Map, MapHandle, MapMarker, MapMarkerProps, MapProps, type MediaAspect, type MediaRadius, MediaSurface, type MediaSurfaceProps, type ModeName, type OKLCHTriplet, type Palette, Popover, PopoverAnchor, PopoverContent, PopoverTrigger, type PostPreset, Progress, RadioGroup, RadioGroupItem, type RadiusStyle, type Ramp, ResizableHandle, ResizablePanel, ResizablePanelGroup, RivePlayer, type RivePlayerProps, Row, type RowProps, type SceneContext, type SceneFactory, type SceneHandle, ScrollArea, ScrollBar, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, Separator, ShaderCompileError, type ShaderPreset, ShaderPresetPicker, type ShaderPresetPickerProps, ShaderPresetPreview, type ShaderPresetPreviewProps, type ShadowIntensity, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetOverlay, SheetPortal, SheetTitle, SheetTrigger, SideMenu, type SideMenuItem, type SideMenuProps, type SideMenuSection, type SimpleTab, SimpleTabs, SimpleTabsContent, SimpleTabsList, type SimpleTabsListProps, SimpleTabsPanel, type SimpleTabsPanelProps, type SimpleTabsProps, SimpleTabsRoot, type SimpleTabsRootProps, SimpleTabsTrigger, type SimpleTabsTriggerProps, Skeleton, Slider, type SpacingDensity, Stack, type StackProps, Switch, Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableRow, Tabs, TabsContent, TabsList, TabsTrigger, Textarea, type ThemeInput, ThemeToggle, ThreeScene, type ThreeSceneProps, Toggle, ToggleGroup, ToggleGroupItem, Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, type TypeScalePreset, VideoPlayer, type VideoPlayerProps, asideVariants as appShellAsideVariants, footerVariants as appShellFooterVariants, headerVariants as appShellHeaderVariants, mainVariants as appShellMainVariants, navVariants as appShellNavVariants, applyThemeToRoot, badgeVariants, buildFragmentShaderScene, builtInThemes, buttonVariants, calmInput, cn, defaultPostPreset, defaultThemeId, deleteUserTheme, duplicateTheme, energyInput, flexVariants, generateTheme, getTheme, gridVariants, listThemes, listUserThemes, loadUserThemeInput, postPresets, rowVariants, saveUserTheme, sceneRegistry, shaderPresetById, shaderPresets, shellVariants, stackVariants, themeToCSSVars, toggleVariants, useGradeTheme, useMaybeGradeTheme, usePrefersReducedMotion };
2761
+ export { ALL_MODES, Accordion, AccordionContent, AccordionItem, AccordionTrigger, AppShell, AppShellAside, type AppShellAsideProps, AppShellFooter, type AppShellFooterProps, AppShellHeader, type AppShellHeaderProps, AppShellMain, type AppShellMainProps, AppShellNav, type AppShellNavProps, type AppShellProps, Avatar, AvatarFallback, AvatarImage, BUILT_IN_INPUTS, Badge, type BaseMediaProps, Breadcrumb, BreadcrumbEllipsis, BreadcrumbItem, BreadcrumbLink, BreadcrumbList, type BreadcrumbMenuItem, BreadcrumbMenuTrigger, BreadcrumbPage, BreadcrumbSeparator, Button, type ButtonShape, COMPONENT_CONTRACTS, Calendar, CalendarDayButton, Callout, CalloutDescription, CalloutTitle, Card, CardContent, CardDescription, CardFooter, CardHeader, type CardStyle, CardTitle, Carousel, CarouselArrows, type CarouselArrowsProps, type AutoplayConfig as CarouselAutoplayConfig, CarouselDots, type CarouselDotsProps, type CarouselNavButtonProps, CarouselNext, CarouselPrev, type CarouselProps, CarouselSlide, type CarouselSlideProps, CarouselVideoSlide, type CarouselVideoSlideProps, type ChartPalette, Checkbox, type ColorIntensity, DatePicker, type DatePickerProps, DateRangePicker, type DateRangePickerProps, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, FRAGMENT_HEADER, Flex, type FlexProps, type FontKey, GRADE_PRE_HYDRATION_SCRIPT, type GeneratedTheme, GradeModeSwitcher, GradeThemeProvider, type GradeThemeProviderProps, GradeThemeSwitcher, Grid, type GridProps, Input, type InputStyle, Label, LenisProvider, Map, MapHandle, MapMarker, MapMarkerProps, MapProps, type MediaAspect, type MediaRadius, MediaSurface, MediaSurfaceContract, type MediaSurfaceProps, type ModeName, MultiSelect, type MultiSelectOption, type MultiSelectProps, type OKLCHTriplet, type Palette, Popover, PopoverAnchor, PopoverContent, PopoverTrigger, type PostPreset, Progress, RadioGroup, RadioGroupItem, type RadiusStyle, type Ramp, ResizableHandle, ResizablePanel, ResizablePanelGroup, RivePlayer, type RivePlayerProps, Row, type RowProps, type SceneContext, type SceneFactory, type SceneHandle, ScrollArea, ScrollBar, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, Separator, ShaderCompileError, type ShaderPreset, ShaderPresetPicker, type ShaderPresetPickerProps, ShaderPresetPreview, type ShaderPresetPreviewProps, type ShadowIntensity, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetOverlay, SheetPortal, SheetTitle, SheetTrigger, Sidebar, SidebarContent, type SidebarContentProps, SidebarFooter, type SidebarFooterProps, SidebarHeader, type SidebarHeaderProps, SidebarItem, type SidebarItemProps, type SidebarProps, SidebarSection, type SidebarSectionProps, SidebarTreeItem, type SidebarTreeItemProps, Skeleton, Slider, Sortable, SortableGroup, type SortableGroupProps, SortableHandle, type SortableHandleProps, SortableItem, type SortableItemProps, type SortableProps, type SpacingDensity, Stack, type StackProps, Switch, Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableRow, Tabs, TabsContent, TabsList, TabsTrigger, Textarea, type ThemeInput, ThemeToggle, ThreeScene, type ThreeSceneProps, Toggle, ToggleGroup, ToggleGroupItem, Toolbar, type ToolbarProps, ToolbarSlot, type ToolbarSlotProps, Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, type TypeScalePreset, VideoPlayer, type VideoPlayerProps, asideVariants as appShellAsideVariants, footerVariants as appShellFooterVariants, headerVariants as appShellHeaderVariants, mainVariants as appShellMainVariants, navVariants as appShellNavVariants, applyThemeToRoot, badgeVariants, buildFragmentShaderScene, builtInThemes, buttonVariants, calloutVariants, calmInput, cn, defaultPostPreset, defaultThemeId, deleteUserTheme, duplicateTheme, energyInput, flexVariants, generateTheme, getComponentContract, getTheme, gridVariants, listContractedComponents, listThemes, listUserThemes, loadUserThemeInput, postPresets, rowVariants, saveUserTheme, sceneRegistry, shaderPresetById, shaderPresets, shellVariants, stackVariants, themeToCSSVars, toggleVariants, useCarouselApi, useGradeTheme, useMaybeGradeTheme, usePrefersReducedMotion };