@augmenting-integrations/ui 0.2.2 → 2.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 (113) hide show
  1. package/dist/components/chrome/Logo.cjs +52 -0
  2. package/dist/components/chrome/Logo.cjs.map +1 -0
  3. package/dist/components/chrome/Logo.js +28 -0
  4. package/dist/components/chrome/Logo.js.map +1 -0
  5. package/dist/components/chrome/RoleSwitcher.cjs +98 -0
  6. package/dist/components/chrome/RoleSwitcher.cjs.map +1 -0
  7. package/dist/components/chrome/RoleSwitcher.js +64 -0
  8. package/dist/components/chrome/RoleSwitcher.js.map +1 -0
  9. package/dist/components/chrome/ThemeSwitcher.cjs +129 -0
  10. package/dist/components/chrome/ThemeSwitcher.cjs.map +1 -0
  11. package/dist/components/chrome/ThemeSwitcher.js +100 -0
  12. package/dist/components/chrome/ThemeSwitcher.js.map +1 -0
  13. package/dist/components/shells/AppShell.cjs +128 -0
  14. package/dist/components/shells/AppShell.cjs.map +1 -0
  15. package/dist/components/shells/AppShell.d.ts +1 -7
  16. package/dist/components/shells/AppShell.d.ts.map +1 -1
  17. package/dist/components/shells/AppShell.js +94 -0
  18. package/dist/components/shells/AppShell.js.map +1 -0
  19. package/dist/components/shells/PublicShell.cjs +87 -0
  20. package/dist/components/shells/PublicShell.cjs.map +1 -0
  21. package/dist/components/shells/PublicShell.d.ts +1 -11
  22. package/dist/components/shells/PublicShell.d.ts.map +1 -1
  23. package/dist/components/shells/PublicShell.js +53 -0
  24. package/dist/components/shells/PublicShell.js.map +1 -0
  25. package/dist/components/shells/StudioShell.cjs +49 -0
  26. package/dist/components/shells/StudioShell.cjs.map +1 -0
  27. package/dist/components/shells/StudioShell.js +25 -0
  28. package/dist/components/shells/StudioShell.js.map +1 -0
  29. package/dist/components/ui/avatar.cjs +131 -0
  30. package/dist/components/ui/avatar.cjs.map +1 -0
  31. package/dist/components/ui/avatar.js +102 -0
  32. package/dist/components/ui/avatar.js.map +1 -0
  33. package/dist/components/ui/badge.cjs +69 -0
  34. package/dist/components/ui/badge.cjs.map +1 -0
  35. package/dist/components/ui/badge.js +44 -0
  36. package/dist/components/ui/badge.js.map +1 -0
  37. package/dist/components/ui/button.cjs +82 -0
  38. package/dist/components/ui/button.cjs.map +1 -0
  39. package/dist/components/ui/button.js +57 -0
  40. package/dist/components/ui/button.js.map +1 -0
  41. package/dist/components/ui/card.cjs +114 -0
  42. package/dist/components/ui/card.cjs.map +1 -0
  43. package/dist/components/ui/card.js +84 -0
  44. package/dist/components/ui/card.js.map +1 -0
  45. package/dist/components/ui/checkbox.cjs +57 -0
  46. package/dist/components/ui/checkbox.cjs.map +1 -0
  47. package/dist/components/ui/checkbox.js +33 -0
  48. package/dist/components/ui/checkbox.js.map +1 -0
  49. package/dist/components/ui/dialog.cjs +172 -0
  50. package/dist/components/ui/dialog.cjs.map +1 -0
  51. package/dist/components/ui/dialog.js +139 -0
  52. package/dist/components/ui/dialog.js.map +1 -0
  53. package/dist/components/ui/dropdown-menu.cjs +250 -0
  54. package/dist/components/ui/dropdown-menu.cjs.map +1 -0
  55. package/dist/components/ui/dropdown-menu.js +212 -0
  56. package/dist/components/ui/dropdown-menu.js.map +1 -0
  57. package/dist/components/ui/input.cjs +46 -0
  58. package/dist/components/ui/input.cjs.map +1 -0
  59. package/dist/components/ui/input.js +22 -0
  60. package/dist/components/ui/input.js.map +1 -0
  61. package/dist/components/ui/label.cjs +48 -0
  62. package/dist/components/ui/label.cjs.map +1 -0
  63. package/dist/components/ui/label.js +24 -0
  64. package/dist/components/ui/label.js.map +1 -0
  65. package/dist/components/ui/select.cjs +201 -0
  66. package/dist/components/ui/select.cjs.map +1 -0
  67. package/dist/components/ui/select.js +168 -0
  68. package/dist/components/ui/select.js.map +1 -0
  69. package/dist/components/ui/separator.cjs +52 -0
  70. package/dist/components/ui/separator.cjs.map +1 -0
  71. package/dist/components/ui/separator.js +28 -0
  72. package/dist/components/ui/separator.js.map +1 -0
  73. package/dist/components/ui/sheet.cjs +154 -0
  74. package/dist/components/ui/sheet.cjs.map +1 -0
  75. package/dist/components/ui/sheet.js +123 -0
  76. package/dist/components/ui/sheet.js.map +1 -0
  77. package/dist/components/ui/table.cjs +134 -0
  78. package/dist/components/ui/table.cjs.map +1 -0
  79. package/dist/components/ui/table.js +103 -0
  80. package/dist/components/ui/table.js.map +1 -0
  81. package/dist/components/ui/tabs.cjs +121 -0
  82. package/dist/components/ui/tabs.cjs.map +1 -0
  83. package/dist/components/ui/tabs.js +93 -0
  84. package/dist/components/ui/tabs.js.map +1 -0
  85. package/dist/components/ui/textarea.cjs +43 -0
  86. package/dist/components/ui/textarea.cjs.map +1 -0
  87. package/dist/components/ui/textarea.js +19 -0
  88. package/dist/components/ui/textarea.js.map +1 -0
  89. package/dist/index.cjs +55 -1651
  90. package/dist/index.cjs.map +1 -1
  91. package/dist/index.js +26 -1547
  92. package/dist/index.js.map +1 -1
  93. package/dist/lib/utils.cjs +33 -0
  94. package/dist/lib/utils.cjs.map +1 -0
  95. package/dist/lib/utils.js +9 -0
  96. package/dist/lib/utils.js.map +1 -0
  97. package/dist/providers/MockProvider.cjs +83 -0
  98. package/dist/providers/MockProvider.cjs.map +1 -0
  99. package/dist/providers/MockProvider.js +49 -0
  100. package/dist/providers/MockProvider.js.map +1 -0
  101. package/dist/providers/QueryProvider.cjs +52 -0
  102. package/dist/providers/QueryProvider.cjs.map +1 -0
  103. package/dist/providers/QueryProvider.js +18 -0
  104. package/dist/providers/QueryProvider.js.map +1 -0
  105. package/dist/providers/SessionProvider.cjs +37 -0
  106. package/dist/providers/SessionProvider.cjs.map +1 -0
  107. package/dist/providers/SessionProvider.js +13 -0
  108. package/dist/providers/SessionProvider.js.map +1 -0
  109. package/dist/providers/ThemeProvider.cjs +92 -0
  110. package/dist/providers/ThemeProvider.cjs.map +1 -0
  111. package/dist/providers/ThemeProvider.js +57 -0
  112. package/dist/providers/ThemeProvider.js.map +1 -0
  113. package/package.json +7 -5
package/dist/index.js CHANGED
@@ -1,1562 +1,41 @@
1
- // src/components/ui/avatar.tsx
2
- import * as React2 from "react";
3
- import { Avatar as AvatarPrimitive } from "radix-ui";
4
-
5
- // src/lib/utils.ts
6
- import { clsx } from "clsx";
7
- import { twMerge } from "tailwind-merge";
8
- function cn(...inputs) {
9
- return twMerge(clsx(inputs));
10
- }
11
-
12
- // src/components/ui/avatar.tsx
13
- function Avatar({
14
- className,
15
- size = "default",
16
- ...props
17
- }) {
18
- return /* @__PURE__ */ React2.createElement(
19
- AvatarPrimitive.Root,
20
- {
21
- "data-slot": "avatar",
22
- "data-size": size,
23
- className: cn(
24
- "group/avatar relative flex size-8 shrink-0 overflow-hidden rounded-full select-none data-[size=lg]:size-10 data-[size=sm]:size-6",
25
- className
26
- ),
27
- ...props
28
- }
29
- );
30
- }
31
- function AvatarImage({
32
- className,
33
- ...props
34
- }) {
35
- return /* @__PURE__ */ React2.createElement(
36
- AvatarPrimitive.Image,
37
- {
38
- "data-slot": "avatar-image",
39
- className: cn("aspect-square size-full", className),
40
- ...props
41
- }
42
- );
43
- }
44
- function AvatarFallback({
45
- className,
46
- ...props
47
- }) {
48
- return /* @__PURE__ */ React2.createElement(
49
- AvatarPrimitive.Fallback,
50
- {
51
- "data-slot": "avatar-fallback",
52
- className: cn(
53
- "flex size-full items-center justify-center rounded-full bg-muted text-sm text-muted-foreground group-data-[size=sm]/avatar:text-xs",
54
- className
55
- ),
56
- ...props
57
- }
58
- );
59
- }
60
- function AvatarBadge({ className, ...props }) {
61
- return /* @__PURE__ */ React2.createElement(
62
- "span",
63
- {
64
- "data-slot": "avatar-badge",
65
- className: cn(
66
- "absolute right-0 bottom-0 z-10 inline-flex items-center justify-center rounded-full bg-primary text-primary-foreground ring-2 ring-background select-none",
67
- "group-data-[size=sm]/avatar:size-2 group-data-[size=sm]/avatar:[&>svg]:hidden",
68
- "group-data-[size=default]/avatar:size-2.5 group-data-[size=default]/avatar:[&>svg]:size-2",
69
- "group-data-[size=lg]/avatar:size-3 group-data-[size=lg]/avatar:[&>svg]:size-2",
70
- className
71
- ),
72
- ...props
73
- }
74
- );
75
- }
76
- function AvatarGroup({ className, ...props }) {
77
- return /* @__PURE__ */ React2.createElement(
78
- "div",
79
- {
80
- "data-slot": "avatar-group",
81
- className: cn(
82
- "group/avatar-group flex -space-x-2 *:data-[slot=avatar]:ring-2 *:data-[slot=avatar]:ring-background",
83
- className
84
- ),
85
- ...props
86
- }
87
- );
88
- }
89
- function AvatarGroupCount({ className, ...props }) {
90
- return /* @__PURE__ */ React2.createElement(
91
- "div",
92
- {
93
- "data-slot": "avatar-group-count",
94
- className: cn(
95
- "relative flex size-8 shrink-0 items-center justify-center rounded-full bg-muted text-sm text-muted-foreground ring-2 ring-background group-has-data-[size=lg]/avatar-group:size-10 group-has-data-[size=sm]/avatar-group:size-6 [&>svg]:size-4 group-has-data-[size=lg]/avatar-group:[&>svg]:size-5 group-has-data-[size=sm]/avatar-group:[&>svg]:size-3",
96
- className
97
- ),
98
- ...props
99
- }
100
- );
101
- }
102
-
103
- // src/components/ui/badge.tsx
104
- import * as React3 from "react";
105
- import { cva } from "class-variance-authority";
106
- import { Slot } from "radix-ui";
107
- var badgeVariants = cva(
108
- "inline-flex w-fit shrink-0 items-center justify-center gap-1 overflow-hidden rounded-full border border-transparent px-2 py-0.5 text-xs font-medium whitespace-nowrap transition-[color,box-shadow] focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&>svg]:pointer-events-none [&>svg]:size-3",
109
- {
110
- variants: {
111
- variant: {
112
- default: "bg-primary text-primary-foreground [a&]:hover:bg-primary/90",
113
- secondary: "bg-secondary text-secondary-foreground [a&]:hover:bg-secondary/90",
114
- destructive: "bg-destructive text-white focus-visible:ring-destructive/20 dark:bg-destructive/60 dark:focus-visible:ring-destructive/40 [a&]:hover:bg-destructive/90",
115
- outline: "border-border text-foreground [a&]:hover:bg-accent [a&]:hover:text-accent-foreground",
116
- ghost: "[a&]:hover:bg-accent [a&]:hover:text-accent-foreground",
117
- link: "text-primary underline-offset-4 [a&]:hover:underline"
118
- }
119
- },
120
- defaultVariants: {
121
- variant: "default"
122
- }
123
- }
124
- );
125
- function Badge({
126
- className,
127
- variant = "default",
128
- asChild = false,
129
- ...props
130
- }) {
131
- const Comp = asChild ? Slot.Root : "span";
132
- return /* @__PURE__ */ React3.createElement(
133
- Comp,
134
- {
135
- "data-slot": "badge",
136
- "data-variant": variant,
137
- className: cn(badgeVariants({ variant }), className),
138
- ...props
139
- }
140
- );
141
- }
142
-
143
- // src/components/ui/button.tsx
144
- import * as React4 from "react";
145
- import { cva as cva2 } from "class-variance-authority";
146
- import { Slot as Slot2 } from "radix-ui";
147
- var buttonVariants = cva2(
148
- "inline-flex shrink-0 items-center justify-center gap-2 rounded-md text-sm font-medium whitespace-nowrap transition-all outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
149
- {
150
- variants: {
151
- variant: {
152
- default: "bg-primary text-primary-foreground hover:bg-primary/90",
153
- destructive: "bg-destructive text-white hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:bg-destructive/60 dark:focus-visible:ring-destructive/40",
154
- outline: "border bg-background shadow-xs hover:bg-accent hover:text-accent-foreground dark:border-input dark:bg-input/30 dark:hover:bg-input/50",
155
- secondary: "bg-secondary text-secondary-foreground hover:bg-secondary/80",
156
- ghost: "hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50",
157
- link: "text-primary underline-offset-4 hover:underline"
158
- },
159
- size: {
160
- default: "h-9 px-4 py-2 has-[>svg]:px-3",
161
- xs: "h-6 gap-1 rounded-md px-2 text-xs has-[>svg]:px-1.5 [&_svg:not([class*='size-'])]:size-3",
162
- sm: "h-8 gap-1.5 rounded-md px-3 has-[>svg]:px-2.5",
163
- lg: "h-10 rounded-md px-6 has-[>svg]:px-4",
164
- icon: "size-9",
165
- "icon-xs": "size-6 rounded-md [&_svg:not([class*='size-'])]:size-3",
166
- "icon-sm": "size-8",
167
- "icon-lg": "size-10"
168
- }
169
- },
170
- defaultVariants: {
171
- variant: "default",
172
- size: "default"
173
- }
174
- }
175
- );
176
- function Button({
177
- className,
178
- variant = "default",
179
- size = "default",
180
- asChild = false,
181
- ...props
182
- }) {
183
- const Comp = asChild ? Slot2.Root : "button";
184
- return /* @__PURE__ */ React4.createElement(
185
- Comp,
186
- {
187
- "data-slot": "button",
188
- "data-variant": variant,
189
- "data-size": size,
190
- className: cn(buttonVariants({ variant, size, className })),
191
- ...props
192
- }
193
- );
194
- }
195
-
196
- // src/components/ui/card.tsx
197
- import * as React5 from "react";
198
- function Card({ className, ...props }) {
199
- return /* @__PURE__ */ React5.createElement(
200
- "div",
201
- {
202
- "data-slot": "card",
203
- className: cn(
204
- "flex flex-col gap-6 rounded-xl border bg-card py-6 text-card-foreground shadow-sm",
205
- className
206
- ),
207
- ...props
208
- }
209
- );
210
- }
211
- function CardHeader({ className, ...props }) {
212
- return /* @__PURE__ */ React5.createElement(
213
- "div",
214
- {
215
- "data-slot": "card-header",
216
- className: cn(
217
- "@container/card-header grid auto-rows-min grid-rows-[auto_auto] items-start gap-2 px-6 has-data-[slot=card-action]:grid-cols-[1fr_auto] [.border-b]:pb-6",
218
- className
219
- ),
220
- ...props
221
- }
222
- );
223
- }
224
- function CardTitle({ className, ...props }) {
225
- return /* @__PURE__ */ React5.createElement(
226
- "div",
227
- {
228
- "data-slot": "card-title",
229
- className: cn("leading-none font-semibold", className),
230
- ...props
231
- }
232
- );
233
- }
234
- function CardDescription({ className, ...props }) {
235
- return /* @__PURE__ */ React5.createElement(
236
- "div",
237
- {
238
- "data-slot": "card-description",
239
- className: cn("text-sm text-muted-foreground", className),
240
- ...props
241
- }
242
- );
243
- }
244
- function CardAction({ className, ...props }) {
245
- return /* @__PURE__ */ React5.createElement(
246
- "div",
247
- {
248
- "data-slot": "card-action",
249
- className: cn(
250
- "col-start-2 row-span-2 row-start-1 self-start justify-self-end",
251
- className
252
- ),
253
- ...props
254
- }
255
- );
256
- }
257
- function CardContent({ className, ...props }) {
258
- return /* @__PURE__ */ React5.createElement("div", { "data-slot": "card-content", className: cn("px-6", className), ...props });
259
- }
260
- function CardFooter({ className, ...props }) {
261
- return /* @__PURE__ */ React5.createElement(
262
- "div",
263
- {
264
- "data-slot": "card-footer",
265
- className: cn("flex items-center px-6 [.border-t]:pt-6", className),
266
- ...props
267
- }
268
- );
269
- }
270
-
271
- // src/components/ui/checkbox.tsx
272
- import * as React6 from "react";
273
- import { CheckIcon } from "lucide-react";
274
- import { Checkbox as CheckboxPrimitive } from "radix-ui";
275
- function Checkbox({
276
- className,
277
- ...props
278
- }) {
279
- return /* @__PURE__ */ React6.createElement(
280
- CheckboxPrimitive.Root,
281
- {
282
- "data-slot": "checkbox",
283
- className: cn(
284
- "peer size-4 shrink-0 rounded-[4px] border border-input shadow-xs transition-shadow outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 data-[state=checked]:border-primary data-[state=checked]:bg-primary data-[state=checked]:text-primary-foreground dark:bg-input/30 dark:aria-invalid:ring-destructive/40 dark:data-[state=checked]:bg-primary",
285
- className
286
- ),
287
- ...props
288
- },
289
- /* @__PURE__ */ React6.createElement(
290
- CheckboxPrimitive.Indicator,
291
- {
292
- "data-slot": "checkbox-indicator",
293
- className: "grid place-content-center text-current transition-none"
294
- },
295
- /* @__PURE__ */ React6.createElement(CheckIcon, { className: "size-3.5" })
296
- )
297
- );
298
- }
299
-
300
- // src/components/ui/dialog.tsx
301
- import * as React7 from "react";
302
- import { XIcon } from "lucide-react";
303
- import { Dialog as DialogPrimitive } from "radix-ui";
304
- function Dialog({ ...props }) {
305
- return /* @__PURE__ */ React7.createElement(DialogPrimitive.Root, { "data-slot": "dialog", ...props });
306
- }
307
- function DialogTrigger({
308
- ...props
309
- }) {
310
- return /* @__PURE__ */ React7.createElement(DialogPrimitive.Trigger, { "data-slot": "dialog-trigger", ...props });
311
- }
312
- function DialogPortal({ ...props }) {
313
- return /* @__PURE__ */ React7.createElement(DialogPrimitive.Portal, { "data-slot": "dialog-portal", ...props });
314
- }
315
- function DialogClose({ ...props }) {
316
- return /* @__PURE__ */ React7.createElement(DialogPrimitive.Close, { "data-slot": "dialog-close", ...props });
317
- }
318
- function DialogOverlay({
319
- className,
320
- ...props
321
- }) {
322
- return /* @__PURE__ */ React7.createElement(
323
- DialogPrimitive.Overlay,
324
- {
325
- "data-slot": "dialog-overlay",
326
- className: cn(
327
- "fixed inset-0 z-50 bg-black/50 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:animate-in data-[state=open]:fade-in-0",
328
- className
329
- ),
330
- ...props
331
- }
332
- );
333
- }
334
- function DialogContent({
335
- className,
336
- children,
337
- showCloseButton = true,
338
- ...props
339
- }) {
340
- return /* @__PURE__ */ React7.createElement(DialogPortal, { "data-slot": "dialog-portal" }, /* @__PURE__ */ React7.createElement(DialogOverlay, null), /* @__PURE__ */ React7.createElement(
341
- DialogPrimitive.Content,
342
- {
343
- "data-slot": "dialog-content",
344
- className: cn(
345
- "fixed top-[50%] left-[50%] z-50 grid w-full max-w-[calc(100%-2rem)] translate-x-[-50%] translate-y-[-50%] gap-4 rounded-lg border bg-background p-6 shadow-lg duration-200 outline-none data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95 sm:max-w-lg",
346
- className
347
- ),
348
- ...props
349
- },
350
- children,
351
- showCloseButton && /* @__PURE__ */ React7.createElement(
352
- DialogPrimitive.Close,
353
- {
354
- "data-slot": "dialog-close",
355
- className: "absolute top-4 right-4 rounded-xs opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:ring-2 focus:ring-ring focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4"
356
- },
357
- /* @__PURE__ */ React7.createElement(XIcon, null),
358
- /* @__PURE__ */ React7.createElement("span", { className: "sr-only" }, "Close")
359
- )
360
- ));
361
- }
362
- function DialogHeader({ className, ...props }) {
363
- return /* @__PURE__ */ React7.createElement(
364
- "div",
365
- {
366
- "data-slot": "dialog-header",
367
- className: cn("flex flex-col gap-2 text-center sm:text-left", className),
368
- ...props
369
- }
370
- );
371
- }
372
- function DialogFooter({
373
- className,
374
- showCloseButton = false,
375
- children,
376
- ...props
377
- }) {
378
- return /* @__PURE__ */ React7.createElement(
379
- "div",
380
- {
381
- "data-slot": "dialog-footer",
382
- className: cn("flex flex-col-reverse gap-2 sm:flex-row sm:justify-end", className),
383
- ...props
384
- },
385
- children,
386
- showCloseButton && /* @__PURE__ */ React7.createElement(DialogPrimitive.Close, { asChild: true }, /* @__PURE__ */ React7.createElement(Button, { variant: "outline" }, "Close"))
387
- );
388
- }
389
- function DialogTitle({
390
- className,
391
- ...props
392
- }) {
393
- return /* @__PURE__ */ React7.createElement(
394
- DialogPrimitive.Title,
395
- {
396
- "data-slot": "dialog-title",
397
- className: cn("text-lg leading-none font-semibold", className),
398
- ...props
399
- }
400
- );
401
- }
402
- function DialogDescription({
403
- className,
404
- ...props
405
- }) {
406
- return /* @__PURE__ */ React7.createElement(
407
- DialogPrimitive.Description,
408
- {
409
- "data-slot": "dialog-description",
410
- className: cn("text-sm text-muted-foreground", className),
411
- ...props
412
- }
413
- );
414
- }
415
-
416
- // src/components/ui/dropdown-menu.tsx
417
- import * as React8 from "react";
418
- import { CheckIcon as CheckIcon2, ChevronRightIcon, CircleIcon } from "lucide-react";
419
- import { DropdownMenu as DropdownMenuPrimitive } from "radix-ui";
420
- function DropdownMenu({
421
- ...props
422
- }) {
423
- return /* @__PURE__ */ React8.createElement(DropdownMenuPrimitive.Root, { "data-slot": "dropdown-menu", ...props });
424
- }
425
- function DropdownMenuPortal({
426
- ...props
427
- }) {
428
- return /* @__PURE__ */ React8.createElement(DropdownMenuPrimitive.Portal, { "data-slot": "dropdown-menu-portal", ...props });
429
- }
430
- function DropdownMenuTrigger({
431
- ...props
432
- }) {
433
- return /* @__PURE__ */ React8.createElement(DropdownMenuPrimitive.Trigger, { "data-slot": "dropdown-menu-trigger", ...props });
434
- }
435
- function DropdownMenuContent({
436
- className,
437
- sideOffset = 4,
438
- ...props
439
- }) {
440
- return /* @__PURE__ */ React8.createElement(DropdownMenuPrimitive.Portal, null, /* @__PURE__ */ React8.createElement(
441
- DropdownMenuPrimitive.Content,
442
- {
443
- "data-slot": "dropdown-menu-content",
444
- sideOffset,
445
- className: cn(
446
- "z-50 max-h-(--radix-dropdown-menu-content-available-height) min-w-[8rem] origin-(--radix-dropdown-menu-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-md border bg-popover p-1 text-popover-foreground shadow-md data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95",
447
- className
448
- ),
449
- ...props
450
- }
451
- ));
452
- }
453
- function DropdownMenuGroup({
454
- ...props
455
- }) {
456
- return /* @__PURE__ */ React8.createElement(DropdownMenuPrimitive.Group, { "data-slot": "dropdown-menu-group", ...props });
457
- }
458
- function DropdownMenuItem({
459
- className,
460
- inset,
461
- variant = "default",
462
- ...props
463
- }) {
464
- return /* @__PURE__ */ React8.createElement(
465
- DropdownMenuPrimitive.Item,
466
- {
467
- "data-slot": "dropdown-menu-item",
468
- "data-inset": inset,
469
- "data-variant": variant,
470
- className: cn(
471
- "relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50 data-[inset]:pl-8 data-[variant=destructive]:text-destructive data-[variant=destructive]:focus:bg-destructive/10 data-[variant=destructive]:focus:text-destructive dark:data-[variant=destructive]:focus:bg-destructive/20 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 [&_svg:not([class*='text-'])]:text-muted-foreground data-[variant=destructive]:*:[svg]:text-destructive!",
472
- className
473
- ),
474
- ...props
475
- }
476
- );
477
- }
478
- function DropdownMenuCheckboxItem({
479
- className,
480
- children,
481
- checked,
482
- ...props
483
- }) {
484
- return /* @__PURE__ */ React8.createElement(
485
- DropdownMenuPrimitive.CheckboxItem,
486
- {
487
- "data-slot": "dropdown-menu-checkbox-item",
488
- className: cn(
489
- "relative flex cursor-default items-center gap-2 rounded-sm py-1.5 pr-2 pl-8 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
490
- className
491
- ),
492
- checked,
493
- ...props
494
- },
495
- /* @__PURE__ */ React8.createElement("span", { className: "pointer-events-none absolute left-2 flex size-3.5 items-center justify-center" }, /* @__PURE__ */ React8.createElement(DropdownMenuPrimitive.ItemIndicator, null, /* @__PURE__ */ React8.createElement(CheckIcon2, { className: "size-4" }))),
496
- children
497
- );
498
- }
499
- function DropdownMenuRadioGroup({
500
- ...props
501
- }) {
502
- return /* @__PURE__ */ React8.createElement(DropdownMenuPrimitive.RadioGroup, { "data-slot": "dropdown-menu-radio-group", ...props });
503
- }
504
- function DropdownMenuRadioItem({
505
- className,
506
- children,
507
- ...props
508
- }) {
509
- return /* @__PURE__ */ React8.createElement(
510
- DropdownMenuPrimitive.RadioItem,
511
- {
512
- "data-slot": "dropdown-menu-radio-item",
513
- className: cn(
514
- "relative flex cursor-default items-center gap-2 rounded-sm py-1.5 pr-2 pl-8 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
515
- className
516
- ),
517
- ...props
518
- },
519
- /* @__PURE__ */ React8.createElement("span", { className: "pointer-events-none absolute left-2 flex size-3.5 items-center justify-center" }, /* @__PURE__ */ React8.createElement(DropdownMenuPrimitive.ItemIndicator, null, /* @__PURE__ */ React8.createElement(CircleIcon, { className: "size-2 fill-current" }))),
520
- children
521
- );
522
- }
523
- function DropdownMenuLabel({
524
- className,
525
- inset,
526
- ...props
527
- }) {
528
- return /* @__PURE__ */ React8.createElement(
529
- DropdownMenuPrimitive.Label,
530
- {
531
- "data-slot": "dropdown-menu-label",
532
- "data-inset": inset,
533
- className: cn("px-2 py-1.5 text-sm font-medium data-[inset]:pl-8", className),
534
- ...props
535
- }
536
- );
537
- }
538
- function DropdownMenuSeparator({
539
- className,
540
- ...props
541
- }) {
542
- return /* @__PURE__ */ React8.createElement(
543
- DropdownMenuPrimitive.Separator,
544
- {
545
- "data-slot": "dropdown-menu-separator",
546
- className: cn("-mx-1 my-1 h-px bg-border", className),
547
- ...props
548
- }
549
- );
550
- }
551
- function DropdownMenuShortcut({ className, ...props }) {
552
- return /* @__PURE__ */ React8.createElement(
553
- "span",
554
- {
555
- "data-slot": "dropdown-menu-shortcut",
556
- className: cn("ml-auto text-xs tracking-widest text-muted-foreground", className),
557
- ...props
558
- }
559
- );
560
- }
561
- function DropdownMenuSub({
562
- ...props
563
- }) {
564
- return /* @__PURE__ */ React8.createElement(DropdownMenuPrimitive.Sub, { "data-slot": "dropdown-menu-sub", ...props });
565
- }
566
- function DropdownMenuSubTrigger({
567
- className,
568
- inset,
569
- children,
570
- ...props
571
- }) {
572
- return /* @__PURE__ */ React8.createElement(
573
- DropdownMenuPrimitive.SubTrigger,
574
- {
575
- "data-slot": "dropdown-menu-sub-trigger",
576
- "data-inset": inset,
577
- className: cn(
578
- "flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground data-[inset]:pl-8 data-[state=open]:bg-accent data-[state=open]:text-accent-foreground [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 [&_svg:not([class*='text-'])]:text-muted-foreground",
579
- className
580
- ),
581
- ...props
582
- },
583
- children,
584
- /* @__PURE__ */ React8.createElement(ChevronRightIcon, { className: "ml-auto size-4" })
585
- );
586
- }
587
- function DropdownMenuSubContent({
588
- className,
589
- ...props
590
- }) {
591
- return /* @__PURE__ */ React8.createElement(
592
- DropdownMenuPrimitive.SubContent,
593
- {
594
- "data-slot": "dropdown-menu-sub-content",
595
- className: cn(
596
- "z-50 min-w-[8rem] origin-(--radix-dropdown-menu-content-transform-origin) overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-lg data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95",
597
- className
598
- ),
599
- ...props
600
- }
601
- );
602
- }
603
-
604
- // src/components/ui/input.tsx
605
- import * as React9 from "react";
606
- function Input({ className, type, ...props }) {
607
- return /* @__PURE__ */ React9.createElement(
608
- "input",
609
- {
610
- type,
611
- "data-slot": "input",
612
- className: cn(
613
- "h-9 w-full min-w-0 rounded-md border border-input bg-transparent px-3 py-1 text-base shadow-xs transition-[color,box-shadow] outline-none selection:bg-primary selection:text-primary-foreground file:inline-flex file:h-7 file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50 md:text-sm dark:bg-input/30",
614
- "focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50",
615
- "aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40",
616
- className
617
- ),
618
- ...props
619
- }
620
- );
621
- }
622
-
623
- // src/components/ui/label.tsx
624
- import * as React10 from "react";
625
- import { Label as LabelPrimitive } from "radix-ui";
626
- function Label({
627
- className,
628
- ...props
629
- }) {
630
- return /* @__PURE__ */ React10.createElement(
631
- LabelPrimitive.Root,
632
- {
633
- "data-slot": "label",
634
- className: cn(
635
- "flex items-center gap-2 text-sm leading-none font-medium select-none group-data-[disabled=true]:pointer-events-none group-data-[disabled=true]:opacity-50 peer-disabled:cursor-not-allowed peer-disabled:opacity-50",
636
- className
637
- ),
638
- ...props
639
- }
640
- );
641
- }
642
-
643
- // src/components/ui/select.tsx
644
- import * as React11 from "react";
645
- import { CheckIcon as CheckIcon3, ChevronDownIcon, ChevronUpIcon } from "lucide-react";
646
- import { Select as SelectPrimitive } from "radix-ui";
647
- function Select({ ...props }) {
648
- return /* @__PURE__ */ React11.createElement(SelectPrimitive.Root, { "data-slot": "select", ...props });
649
- }
650
- function SelectGroup({ ...props }) {
651
- return /* @__PURE__ */ React11.createElement(SelectPrimitive.Group, { "data-slot": "select-group", ...props });
652
- }
653
- function SelectValue({ ...props }) {
654
- return /* @__PURE__ */ React11.createElement(SelectPrimitive.Value, { "data-slot": "select-value", ...props });
655
- }
656
- function SelectTrigger({
657
- className,
658
- size = "default",
659
- children,
660
- ...props
661
- }) {
662
- return /* @__PURE__ */ React11.createElement(
663
- SelectPrimitive.Trigger,
664
- {
665
- "data-slot": "select-trigger",
666
- "data-size": size,
667
- className: cn(
668
- "flex w-fit items-center justify-between gap-2 rounded-md border border-input bg-transparent px-3 py-2 text-sm whitespace-nowrap shadow-xs transition-[color,box-shadow] outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 data-[placeholder]:text-muted-foreground data-[size=default]:h-9 data-[size=sm]:h-8 *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-2 dark:bg-input/30 dark:hover:bg-input/50 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 [&_svg:not([class*='text-'])]:text-muted-foreground",
669
- className
670
- ),
671
- ...props
672
- },
673
- children,
674
- /* @__PURE__ */ React11.createElement(SelectPrimitive.Icon, { asChild: true }, /* @__PURE__ */ React11.createElement(ChevronDownIcon, { className: "size-4 opacity-50" }))
675
- );
676
- }
677
- function SelectContent({
678
- className,
679
- children,
680
- position = "item-aligned",
681
- align = "center",
682
- ...props
683
- }) {
684
- return /* @__PURE__ */ React11.createElement(SelectPrimitive.Portal, null, /* @__PURE__ */ React11.createElement(
685
- SelectPrimitive.Content,
686
- {
687
- "data-slot": "select-content",
688
- className: cn(
689
- "relative z-50 max-h-(--radix-select-content-available-height) min-w-[8rem] origin-(--radix-select-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-md border bg-popover text-popover-foreground shadow-md data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95",
690
- position === "popper" && "data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",
691
- className
692
- ),
693
- position,
694
- align,
695
- ...props
696
- },
697
- /* @__PURE__ */ React11.createElement(SelectScrollUpButton, null),
698
- /* @__PURE__ */ React11.createElement(
699
- SelectPrimitive.Viewport,
700
- {
701
- className: cn(
702
- "p-1",
703
- position === "popper" && "h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)] scroll-my-1"
704
- )
705
- },
706
- children
707
- ),
708
- /* @__PURE__ */ React11.createElement(SelectScrollDownButton, null)
709
- ));
710
- }
711
- function SelectLabel({
712
- className,
713
- ...props
714
- }) {
715
- return /* @__PURE__ */ React11.createElement(
716
- SelectPrimitive.Label,
717
- {
718
- "data-slot": "select-label",
719
- className: cn("px-2 py-1.5 text-xs text-muted-foreground", className),
720
- ...props
721
- }
722
- );
723
- }
724
- function SelectItem({
725
- className,
726
- children,
727
- ...props
728
- }) {
729
- return /* @__PURE__ */ React11.createElement(
730
- SelectPrimitive.Item,
731
- {
732
- "data-slot": "select-item",
733
- className: cn(
734
- "relative flex w-full cursor-default items-center gap-2 rounded-sm py-1.5 pr-8 pl-2 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 [&_svg:not([class*='text-'])]:text-muted-foreground *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2",
735
- className
736
- ),
737
- ...props
738
- },
739
- /* @__PURE__ */ React11.createElement(
740
- "span",
741
- {
742
- "data-slot": "select-item-indicator",
743
- className: "absolute right-2 flex size-3.5 items-center justify-center"
744
- },
745
- /* @__PURE__ */ React11.createElement(SelectPrimitive.ItemIndicator, null, /* @__PURE__ */ React11.createElement(CheckIcon3, { className: "size-4" }))
746
- ),
747
- /* @__PURE__ */ React11.createElement(SelectPrimitive.ItemText, null, children)
748
- );
749
- }
750
- function SelectSeparator({
751
- className,
752
- ...props
753
- }) {
754
- return /* @__PURE__ */ React11.createElement(
755
- SelectPrimitive.Separator,
756
- {
757
- "data-slot": "select-separator",
758
- className: cn("pointer-events-none -mx-1 my-1 h-px bg-border", className),
759
- ...props
760
- }
761
- );
762
- }
763
- function SelectScrollUpButton({
764
- className,
765
- ...props
766
- }) {
767
- return /* @__PURE__ */ React11.createElement(
768
- SelectPrimitive.ScrollUpButton,
769
- {
770
- "data-slot": "select-scroll-up-button",
771
- className: cn("flex cursor-default items-center justify-center py-1", className),
772
- ...props
773
- },
774
- /* @__PURE__ */ React11.createElement(ChevronUpIcon, { className: "size-4" })
775
- );
776
- }
777
- function SelectScrollDownButton({
778
- className,
779
- ...props
780
- }) {
781
- return /* @__PURE__ */ React11.createElement(
782
- SelectPrimitive.ScrollDownButton,
783
- {
784
- "data-slot": "select-scroll-down-button",
785
- className: cn("flex cursor-default items-center justify-center py-1", className),
786
- ...props
787
- },
788
- /* @__PURE__ */ React11.createElement(ChevronDownIcon, { className: "size-4" })
789
- );
790
- }
791
-
792
- // src/components/ui/separator.tsx
793
- import * as React12 from "react";
794
- import { Separator as SeparatorPrimitive } from "radix-ui";
795
- function Separator({
796
- className,
797
- orientation = "horizontal",
798
- decorative = true,
799
- ...props
800
- }) {
801
- return /* @__PURE__ */ React12.createElement(
802
- SeparatorPrimitive.Root,
803
- {
804
- "data-slot": "separator",
805
- decorative,
806
- orientation,
807
- className: cn(
808
- "shrink-0 bg-border data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px",
809
- className
810
- ),
811
- ...props
812
- }
813
- );
814
- }
815
-
816
- // src/components/ui/sheet.tsx
817
- import * as React13 from "react";
818
- import { XIcon as XIcon2 } from "lucide-react";
819
- import { Dialog as SheetPrimitive } from "radix-ui";
820
- function Sheet({ ...props }) {
821
- return /* @__PURE__ */ React13.createElement(SheetPrimitive.Root, { "data-slot": "sheet", ...props });
822
- }
823
- function SheetTrigger({ ...props }) {
824
- return /* @__PURE__ */ React13.createElement(SheetPrimitive.Trigger, { "data-slot": "sheet-trigger", ...props });
825
- }
826
- function SheetClose({ ...props }) {
827
- return /* @__PURE__ */ React13.createElement(SheetPrimitive.Close, { "data-slot": "sheet-close", ...props });
828
- }
829
- function SheetPortal({ ...props }) {
830
- return /* @__PURE__ */ React13.createElement(SheetPrimitive.Portal, { "data-slot": "sheet-portal", ...props });
831
- }
832
- function SheetOverlay({
833
- className,
834
- ...props
835
- }) {
836
- return /* @__PURE__ */ React13.createElement(
837
- SheetPrimitive.Overlay,
838
- {
839
- "data-slot": "sheet-overlay",
840
- className: cn(
841
- "fixed inset-0 z-50 bg-black/50 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:animate-in data-[state=open]:fade-in-0",
842
- className
843
- ),
844
- ...props
845
- }
846
- );
847
- }
848
- function SheetContent({
849
- className,
850
- children,
851
- side = "right",
852
- showCloseButton = true,
853
- ...props
854
- }) {
855
- return /* @__PURE__ */ React13.createElement(SheetPortal, null, /* @__PURE__ */ React13.createElement(SheetOverlay, null), /* @__PURE__ */ React13.createElement(
856
- SheetPrimitive.Content,
857
- {
858
- "data-slot": "sheet-content",
859
- className: cn(
860
- "fixed z-50 flex flex-col gap-4 bg-background shadow-lg transition ease-in-out data-[state=closed]:animate-out data-[state=closed]:duration-300 data-[state=open]:animate-in data-[state=open]:duration-500",
861
- side === "right" && "inset-y-0 right-0 h-full w-3/4 border-l data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right sm:max-w-sm",
862
- side === "left" && "inset-y-0 left-0 h-full w-3/4 border-r data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left sm:max-w-sm",
863
- side === "top" && "inset-x-0 top-0 h-auto border-b data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top",
864
- side === "bottom" && "inset-x-0 bottom-0 h-auto border-t data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom",
865
- className
866
- ),
867
- ...props
868
- },
869
- children,
870
- showCloseButton && /* @__PURE__ */ React13.createElement(SheetPrimitive.Close, { className: "absolute top-4 right-4 rounded-xs opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:ring-2 focus:ring-ring focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none data-[state=open]:bg-secondary" }, /* @__PURE__ */ React13.createElement(XIcon2, { className: "size-4" }), /* @__PURE__ */ React13.createElement("span", { className: "sr-only" }, "Close"))
871
- ));
872
- }
873
- function SheetHeader({ className, ...props }) {
874
- return /* @__PURE__ */ React13.createElement(
875
- "div",
876
- {
877
- "data-slot": "sheet-header",
878
- className: cn("flex flex-col gap-1.5 p-4", className),
879
- ...props
880
- }
881
- );
882
- }
883
- function SheetFooter({ className, ...props }) {
884
- return /* @__PURE__ */ React13.createElement(
885
- "div",
886
- {
887
- "data-slot": "sheet-footer",
888
- className: cn("mt-auto flex flex-col gap-2 p-4", className),
889
- ...props
890
- }
891
- );
892
- }
893
- function SheetTitle({
894
- className,
895
- ...props
896
- }) {
897
- return /* @__PURE__ */ React13.createElement(
898
- SheetPrimitive.Title,
899
- {
900
- "data-slot": "sheet-title",
901
- className: cn("font-semibold text-foreground", className),
902
- ...props
903
- }
904
- );
905
- }
906
- function SheetDescription({
907
- className,
908
- ...props
909
- }) {
910
- return /* @__PURE__ */ React13.createElement(
911
- SheetPrimitive.Description,
912
- {
913
- "data-slot": "sheet-description",
914
- className: cn("text-sm text-muted-foreground", className),
915
- ...props
916
- }
917
- );
918
- }
919
-
920
- // src/components/ui/table.tsx
921
- import * as React14 from "react";
922
- function Table({ className, ...props }) {
923
- return /* @__PURE__ */ React14.createElement("div", { "data-slot": "table-container", className: "relative w-full overflow-x-auto" }, /* @__PURE__ */ React14.createElement(
924
- "table",
925
- {
926
- "data-slot": "table",
927
- className: cn("w-full caption-bottom text-sm", className),
928
- ...props
929
- }
930
- ));
931
- }
932
- function TableHeader({ className, ...props }) {
933
- return /* @__PURE__ */ React14.createElement(
934
- "thead",
935
- {
936
- "data-slot": "table-header",
937
- className: cn("[&_tr]:border-b", className),
938
- ...props
939
- }
940
- );
941
- }
942
- function TableBody({ className, ...props }) {
943
- return /* @__PURE__ */ React14.createElement(
944
- "tbody",
945
- {
946
- "data-slot": "table-body",
947
- className: cn("[&_tr:last-child]:border-0", className),
948
- ...props
949
- }
950
- );
951
- }
952
- function TableFooter({ className, ...props }) {
953
- return /* @__PURE__ */ React14.createElement(
954
- "tfoot",
955
- {
956
- "data-slot": "table-footer",
957
- className: cn("border-t bg-muted/50 font-medium [&>tr]:last:border-b-0", className),
958
- ...props
959
- }
960
- );
961
- }
962
- function TableRow({ className, ...props }) {
963
- return /* @__PURE__ */ React14.createElement(
964
- "tr",
965
- {
966
- "data-slot": "table-row",
967
- className: cn(
968
- "border-b transition-colors hover:bg-muted/50 has-aria-expanded:bg-muted/50 data-[state=selected]:bg-muted",
969
- className
970
- ),
971
- ...props
972
- }
973
- );
974
- }
975
- function TableHead({ className, ...props }) {
976
- return /* @__PURE__ */ React14.createElement(
977
- "th",
978
- {
979
- "data-slot": "table-head",
980
- className: cn(
981
- "h-10 px-2 text-left align-middle font-medium whitespace-nowrap text-foreground [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]",
982
- className
983
- ),
984
- ...props
985
- }
986
- );
987
- }
988
- function TableCell({ className, ...props }) {
989
- return /* @__PURE__ */ React14.createElement(
990
- "td",
991
- {
992
- "data-slot": "table-cell",
993
- className: cn(
994
- "p-2 align-middle whitespace-nowrap [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]",
995
- className
996
- ),
997
- ...props
998
- }
999
- );
1000
- }
1001
- function TableCaption({ className, ...props }) {
1002
- return /* @__PURE__ */ React14.createElement(
1003
- "caption",
1004
- {
1005
- "data-slot": "table-caption",
1006
- className: cn("mt-4 text-sm text-muted-foreground", className),
1007
- ...props
1008
- }
1009
- );
1010
- }
1011
-
1012
- // src/components/ui/tabs.tsx
1013
- import * as React15 from "react";
1014
- import { cva as cva3 } from "class-variance-authority";
1015
- import { Tabs as TabsPrimitive } from "radix-ui";
1016
- function Tabs({
1017
- className,
1018
- orientation = "horizontal",
1019
- ...props
1020
- }) {
1021
- return /* @__PURE__ */ React15.createElement(
1022
- TabsPrimitive.Root,
1023
- {
1024
- "data-slot": "tabs",
1025
- "data-orientation": orientation,
1026
- orientation,
1027
- className: cn(
1028
- "group/tabs flex gap-2 data-[orientation=horizontal]:flex-col",
1029
- className
1030
- ),
1031
- ...props
1032
- }
1033
- );
1034
- }
1035
- var tabsListVariants = cva3(
1036
- "group/tabs-list inline-flex w-fit items-center justify-center rounded-lg p-[3px] text-muted-foreground group-data-[orientation=horizontal]/tabs:h-9 group-data-[orientation=vertical]/tabs:h-fit group-data-[orientation=vertical]/tabs:flex-col data-[variant=line]:rounded-none",
1037
- {
1038
- variants: {
1039
- variant: {
1040
- default: "bg-muted",
1041
- line: "gap-1 bg-transparent"
1042
- }
1043
- },
1044
- defaultVariants: {
1045
- variant: "default"
1046
- }
1047
- }
1048
- );
1049
- function TabsList({
1050
- className,
1051
- variant = "default",
1052
- ...props
1053
- }) {
1054
- return /* @__PURE__ */ React15.createElement(
1055
- TabsPrimitive.List,
1056
- {
1057
- "data-slot": "tabs-list",
1058
- "data-variant": variant,
1059
- className: cn(tabsListVariants({ variant }), className),
1060
- ...props
1061
- }
1062
- );
1063
- }
1064
- function TabsTrigger({
1065
- className,
1066
- ...props
1067
- }) {
1068
- return /* @__PURE__ */ React15.createElement(
1069
- TabsPrimitive.Trigger,
1070
- {
1071
- "data-slot": "tabs-trigger",
1072
- className: cn(
1073
- "relative inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center gap-1.5 rounded-md border border-transparent px-2 py-1 text-sm font-medium whitespace-nowrap text-foreground/60 transition-all group-data-[orientation=vertical]/tabs:w-full group-data-[orientation=vertical]/tabs:justify-start hover:text-foreground focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 focus-visible:outline-1 focus-visible:outline-ring disabled:pointer-events-none disabled:opacity-50 group-data-[variant=default]/tabs-list:data-[state=active]:shadow-sm group-data-[variant=line]/tabs-list:data-[state=active]:shadow-none dark:text-muted-foreground dark:hover:text-foreground [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
1074
- "group-data-[variant=line]/tabs-list:bg-transparent group-data-[variant=line]/tabs-list:data-[state=active]:bg-transparent dark:group-data-[variant=line]/tabs-list:data-[state=active]:border-transparent dark:group-data-[variant=line]/tabs-list:data-[state=active]:bg-transparent",
1075
- "data-[state=active]:bg-background data-[state=active]:text-foreground dark:data-[state=active]:border-input dark:data-[state=active]:bg-input/30 dark:data-[state=active]:text-foreground",
1076
- "after:absolute after:bg-foreground after:opacity-0 after:transition-opacity group-data-[orientation=horizontal]/tabs:after:inset-x-0 group-data-[orientation=horizontal]/tabs:after:bottom-[-5px] group-data-[orientation=horizontal]/tabs:after:h-0.5 group-data-[orientation=vertical]/tabs:after:inset-y-0 group-data-[orientation=vertical]/tabs:after:-right-1 group-data-[orientation=vertical]/tabs:after:w-0.5 group-data-[variant=line]/tabs-list:data-[state=active]:after:opacity-100",
1077
- className
1078
- ),
1079
- ...props
1080
- }
1081
- );
1082
- }
1083
- function TabsContent({
1084
- className,
1085
- ...props
1086
- }) {
1087
- return /* @__PURE__ */ React15.createElement(
1088
- TabsPrimitive.Content,
1089
- {
1090
- "data-slot": "tabs-content",
1091
- className: cn("flex-1 outline-none", className),
1092
- ...props
1093
- }
1094
- );
1095
- }
1096
-
1097
- // src/components/ui/textarea.tsx
1098
- import * as React16 from "react";
1099
- function Textarea({ className, ...props }) {
1100
- return /* @__PURE__ */ React16.createElement(
1101
- "textarea",
1102
- {
1103
- "data-slot": "textarea",
1104
- className: cn(
1105
- "flex field-sizing-content min-h-16 w-full rounded-md border border-input bg-transparent px-3 py-2 text-base shadow-xs transition-[color,box-shadow] outline-none placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 md:text-sm dark:bg-input/30 dark:aria-invalid:ring-destructive/40",
1106
- className
1107
- ),
1108
- ...props
1109
- }
1110
- );
1111
- }
1112
-
1113
- // src/components/chrome/Logo.tsx
1114
- import { useBrand } from "@augmenting-integrations/brand";
1115
- function Logo({
1116
- className,
1117
- showWordmark = true
1118
- }) {
1119
- const brand = useBrand();
1120
- return /* @__PURE__ */ React.createElement("div", { className: cn("inline-flex items-center gap-2 text-primary", className) }, /* @__PURE__ */ React.createElement("span", { className: "inline-flex h-8 w-8 shrink-0 items-center justify-center text-current" }, /* @__PURE__ */ React.createElement("svg", { viewBox: "0 0 32 32", className: "h-full w-full", "aria-hidden": "true" }, /* @__PURE__ */ React.createElement("rect", { x: "2", y: "2", width: "28", height: "28", rx: "6", fill: "currentColor" }), /* @__PURE__ */ React.createElement(
1121
- "path",
1122
- {
1123
- d: "M10 22V10h2.6l3.4 6.4L19.4 10H22v12h-2.4v-7.4l-2.8 5.2h-1.6L12.4 14.6V22H10z",
1124
- fill: "var(--primary-foreground)"
1125
- }
1126
- ))), showWordmark ? /* @__PURE__ */ React.createElement("span", { className: "text-base font-semibold tracking-tight text-foreground" }, brand.shortName) : null, /* @__PURE__ */ React.createElement("span", { className: "sr-only" }, brand.name));
1127
- }
1128
-
1129
- // src/components/chrome/ThemeSwitcher.tsx
1130
- import * as React18 from "react";
1131
- import { useTheme } from "next-themes";
1132
- import { Moon, Sun, Palette } from "lucide-react";
1133
- import { BASE_THEMES } from "@augmenting-integrations/themes";
1134
-
1135
- // src/providers/ThemeProvider.tsx
1136
- import * as React17 from "react";
1137
- import { ThemeProvider as NextThemesProvider } from "next-themes";
1138
- import { THEME_COOKIE_KEY } from "@augmenting-integrations/themes";
1139
- var ThemeNameContext = React17.createContext(null);
1140
- function readCookie() {
1141
- if (typeof document === "undefined") return null;
1142
- const match = document.cookie.split("; ").find((row) => row.startsWith(`${THEME_COOKIE_KEY}=`));
1143
- if (!match) return null;
1144
- const value = match.split("=")[1];
1145
- return value && value.length > 0 ? value : null;
1146
- }
1147
- function writeCookie(value) {
1148
- if (typeof document === "undefined") return;
1149
- document.cookie = `${THEME_COOKIE_KEY}=${value}; path=/; max-age=${60 * 60 * 24 * 365}; samesite=lax`;
1150
- }
1151
- function ThemeProvider({
1152
- children,
1153
- defaultTheme,
1154
- defaultVariant
1155
- }) {
1156
- const [themeName, setThemeNameState] = React17.useState(
1157
- () => readCookie() ?? defaultTheme
1158
- );
1159
- React17.useEffect(() => {
1160
- document.documentElement.setAttribute("data-theme", themeName);
1161
- }, [themeName]);
1162
- const setThemeName = React17.useCallback((next) => {
1163
- writeCookie(next);
1164
- setThemeNameState(next);
1165
- }, []);
1166
- const value = React17.useMemo(
1167
- () => ({ themeName, setThemeName }),
1168
- [themeName, setThemeName]
1169
- );
1170
- return /* @__PURE__ */ React17.createElement(ThemeNameContext.Provider, { value }, /* @__PURE__ */ React17.createElement(
1171
- NextThemesProvider,
1172
- {
1173
- attribute: "class",
1174
- defaultTheme: defaultVariant,
1175
- enableSystem: false,
1176
- disableTransitionOnChange: true
1177
- },
1178
- children
1179
- ));
1180
- }
1181
- function useThemeName() {
1182
- const ctx = React17.useContext(ThemeNameContext);
1183
- if (!ctx) throw new Error("useThemeName must be used inside <ThemeProvider />");
1184
- return ctx;
1185
- }
1186
-
1187
- // src/components/chrome/ThemeSwitcher.tsx
1188
- function ThemeSwitcher({ className }) {
1189
- const { themeName, setThemeName } = useThemeName();
1190
- const { resolvedTheme, setTheme } = useTheme();
1191
- const mounted = React18.useSyncExternalStore(
1192
- () => () => {
1193
- },
1194
- () => true,
1195
- () => false
1196
- );
1197
- if (!mounted) {
1198
- return /* @__PURE__ */ React18.createElement(
1199
- "div",
1200
- {
1201
- className: cn(
1202
- "h-9 w-[120px] rounded-md border border-border bg-background",
1203
- className
1204
- )
1205
- }
1206
- );
1207
- }
1208
- const isDark = resolvedTheme === "dark";
1209
- const activeLabel = BASE_THEMES.find((t) => t.id === themeName)?.label ?? "Theme";
1210
- return /* @__PURE__ */ React18.createElement("div", { className: cn("flex items-center gap-2", className) }, /* @__PURE__ */ React18.createElement(
1211
- "button",
1212
- {
1213
- type: "button",
1214
- onClick: () => setTheme(isDark ? "light" : "dark"),
1215
- "aria-label": isDark ? "Switch to light mode" : "Switch to dark mode",
1216
- className: "inline-flex h-9 w-9 items-center justify-center rounded-md border border-border bg-background text-foreground transition hover:bg-muted"
1217
- },
1218
- isDark ? /* @__PURE__ */ React18.createElement(Sun, { className: "h-4 w-4" }) : /* @__PURE__ */ React18.createElement(Moon, { className: "h-4 w-4" })
1219
- ), /* @__PURE__ */ React18.createElement(DropdownMenu, null, /* @__PURE__ */ React18.createElement(
1220
- DropdownMenuTrigger,
1221
- {
1222
- className: "inline-flex h-9 items-center gap-2 rounded-md border border-border bg-background px-3 text-sm text-foreground transition hover:bg-muted",
1223
- "aria-label": "Switch theme palette"
1224
- },
1225
- /* @__PURE__ */ React18.createElement(Palette, { className: "h-4 w-4" }),
1226
- /* @__PURE__ */ React18.createElement("span", { className: "font-medium" }, activeLabel)
1227
- ), /* @__PURE__ */ React18.createElement(DropdownMenuContent, { align: "end", sideOffset: 6, className: "w-72 p-1" }, BASE_THEMES.map((t) => /* @__PURE__ */ React18.createElement(
1228
- DropdownMenuItem,
1229
- {
1230
- key: t.id,
1231
- onClick: () => setThemeName(t.id),
1232
- className: cn(
1233
- "items-start gap-3 px-2 py-2",
1234
- themeName === t.id && "bg-muted"
1235
- )
1236
- },
1237
- /* @__PURE__ */ React18.createElement(
1238
- "span",
1239
- {
1240
- "aria-hidden": true,
1241
- className: "mt-0.5 inline-flex h-6 w-6 shrink-0 overflow-hidden rounded-full ring-1 ring-border"
1242
- },
1243
- /* @__PURE__ */ React18.createElement("span", { className: "h-full w-1/2", style: { background: t.swatch.primary } }),
1244
- /* @__PURE__ */ React18.createElement(
1245
- "span",
1246
- {
1247
- className: "h-full w-1/2",
1248
- style: { background: t.swatch.primaryDark }
1249
- }
1250
- )
1251
- ),
1252
- /* @__PURE__ */ React18.createElement("span", { className: "flex flex-col" }, /* @__PURE__ */ React18.createElement("span", { className: "text-sm font-medium" }, t.label), /* @__PURE__ */ React18.createElement("span", { className: "text-xs text-muted-foreground" }, t.description))
1253
- )))));
1254
- }
1255
-
1256
- // src/components/chrome/RoleSwitcher.tsx
1257
- import * as React19 from "react";
1258
- import { signIn, useSession } from "next-auth/react";
1259
- import { UserCog } from "lucide-react";
1260
- var ROLES = ["visitor", "sales", "agent", "admin"];
1261
- function RoleSwitcher({ className }) {
1262
- const { data: session, update } = useSession();
1263
- const [open, setOpen] = React19.useState(false);
1264
- const current = session?.user?.role ?? "visitor";
1265
- return /* @__PURE__ */ React19.createElement("div", { className: cn("relative", className) }, /* @__PURE__ */ React19.createElement(
1266
- "button",
1267
- {
1268
- type: "button",
1269
- onClick: () => setOpen((o) => !o),
1270
- "aria-haspopup": "menu",
1271
- "aria-expanded": open,
1272
- className: "inline-flex h-9 items-center gap-2 rounded-md border border-border bg-background px-3 text-sm text-foreground transition hover:bg-muted"
1273
- },
1274
- /* @__PURE__ */ React19.createElement(UserCog, { className: "h-4 w-4" }),
1275
- /* @__PURE__ */ React19.createElement("span", { className: "font-medium capitalize" }, current)
1276
- ), open ? /* @__PURE__ */ React19.createElement(
1277
- "div",
1278
- {
1279
- role: "menu",
1280
- className: "absolute right-0 top-full z-50 mt-2 w-56 rounded-md border border-border bg-popover p-1 text-popover-foreground shadow-lg",
1281
- onMouseLeave: () => setOpen(false)
1282
- },
1283
- /* @__PURE__ */ React19.createElement("div", { className: "px-2 py-1 text-xs uppercase tracking-wide text-muted-foreground" }, "Switch role (dev)"),
1284
- ROLES.map((r) => /* @__PURE__ */ React19.createElement(
1285
- "button",
1286
- {
1287
- key: r,
1288
- type: "button",
1289
- role: "menuitem",
1290
- onClick: async () => {
1291
- await signIn("credentials", { role: r, redirect: false });
1292
- await update();
1293
- setOpen(false);
1294
- },
1295
- className: cn(
1296
- "flex w-full items-center justify-between rounded-sm px-2 py-1.5 text-sm capitalize transition hover:bg-muted",
1297
- current === r && "bg-muted"
1298
- )
1299
- },
1300
- /* @__PURE__ */ React19.createElement("span", null, r),
1301
- current === r ? /* @__PURE__ */ React19.createElement("span", { className: "text-xs text-muted-foreground" }, "active") : null
1302
- ))
1303
- ) : null);
1304
- }
1305
-
1306
- // src/components/shells/PublicShell.tsx
1307
- import * as React20 from "react";
1308
- import { useBrand as useBrand2 } from "@augmenting-integrations/brand";
1309
- function PublicShell({
1310
- children,
1311
- navLinks,
1312
- loginHref = "/login",
1313
- footerLinks,
1314
- Link
1315
- }) {
1316
- const brand = useBrand2();
1317
- return /* @__PURE__ */ React20.createElement("div", { className: "flex min-h-svh flex-col bg-background text-foreground" }, /* @__PURE__ */ React20.createElement("header", { className: "border-b border-border bg-background/80 backdrop-blur" }, /* @__PURE__ */ React20.createElement("div", { className: "mx-auto flex max-w-6xl items-center justify-between px-6 py-4" }, /* @__PURE__ */ React20.createElement(Link, { href: "/", "aria-label": "Home" }, /* @__PURE__ */ React20.createElement(Logo, null)), /* @__PURE__ */ React20.createElement("nav", { className: "flex items-center gap-6 text-sm" }, navLinks.map((link) => /* @__PURE__ */ React20.createElement(
1318
- Link,
1319
- {
1320
- key: link.href,
1321
- href: link.href,
1322
- className: "text-muted-foreground transition hover:text-foreground"
1323
- },
1324
- link.label
1325
- )), /* @__PURE__ */ React20.createElement(
1326
- Link,
1327
- {
1328
- href: loginHref,
1329
- className: "text-muted-foreground transition hover:text-foreground"
1330
- },
1331
- "Log in"
1332
- ), /* @__PURE__ */ React20.createElement(ThemeSwitcher, null)))), /* @__PURE__ */ React20.createElement("main", { className: "flex-1" }, children), /* @__PURE__ */ React20.createElement("footer", { className: "border-t border-border" }, /* @__PURE__ */ React20.createElement("div", { className: "mx-auto flex max-w-6xl flex-wrap items-center justify-between gap-3 px-6 py-6 text-sm text-muted-foreground" }, /* @__PURE__ */ React20.createElement("span", null, "\xA9 ", (/* @__PURE__ */ new Date()).getFullYear(), " ", brand.name), /* @__PURE__ */ React20.createElement("div", { className: "flex gap-4" }, (footerLinks ?? []).map((link) => /* @__PURE__ */ React20.createElement(Link, { key: link.href, href: link.href, className: "hover:text-foreground" }, link.label))))));
1333
- }
1334
-
1335
- // src/components/shells/AppShell.tsx
1336
- import * as React21 from "react";
1337
- import { Menu, X } from "lucide-react";
1338
- function NavGroup({
1339
- group,
1340
- pathname,
1341
- Link
1342
- }) {
1343
- if (group.items.length === 0) return null;
1344
- return /* @__PURE__ */ React21.createElement("div", { className: "space-y-1" }, /* @__PURE__ */ React21.createElement("p", { className: "px-3 text-xs font-semibold uppercase tracking-wide text-muted-foreground" }, group.label), /* @__PURE__ */ React21.createElement("ul", { className: "space-y-0.5" }, group.items.map((item) => {
1345
- const active = pathname === item.href || pathname.startsWith(`${item.href}/`);
1346
- return /* @__PURE__ */ React21.createElement("li", { key: item.href }, /* @__PURE__ */ React21.createElement(
1347
- Link,
1348
- {
1349
- href: item.href,
1350
- className: cn(
1351
- "flex items-center gap-3 rounded-md px-3 py-2 text-sm transition",
1352
- active ? "bg-sidebar-accent text-sidebar-accent-foreground" : "text-sidebar-foreground hover:bg-sidebar-accent/60"
1353
- )
1354
- },
1355
- /* @__PURE__ */ React21.createElement(item.icon, { className: "h-4 w-4 shrink-0" }),
1356
- /* @__PURE__ */ React21.createElement("span", null, item.label)
1357
- ));
1358
- })));
1359
- }
1360
- function AppShell({
1361
- children,
1362
- pathname,
1363
- navGroups,
1364
- Link,
1365
- homeHref = "/",
1366
- showRoleSwitcher = true
1367
- }) {
1368
- const [mobileOpen, setMobileOpen] = React21.useState(false);
1369
- const sidebarContent = /* @__PURE__ */ React21.createElement("div", { className: "flex h-full flex-col gap-6 px-3 py-4" }, /* @__PURE__ */ React21.createElement(Link, { href: homeHref, className: "px-2", "aria-label": "Home" }, /* @__PURE__ */ React21.createElement(Logo, null)), navGroups.map((g) => /* @__PURE__ */ React21.createElement(NavGroup, { key: g.label, group: g, pathname, Link })));
1370
- return /* @__PURE__ */ React21.createElement("div", { className: "flex min-h-svh bg-background text-foreground" }, /* @__PURE__ */ React21.createElement("aside", { className: "hidden w-64 shrink-0 border-r border-sidebar-border bg-sidebar text-sidebar-foreground md:block" }, sidebarContent), mobileOpen ? /* @__PURE__ */ React21.createElement("div", { className: "fixed inset-0 z-50 flex md:hidden" }, /* @__PURE__ */ React21.createElement(
1371
- "div",
1372
- {
1373
- className: "flex-1 bg-foreground/40 backdrop-blur-sm",
1374
- onClick: () => setMobileOpen(false),
1375
- "aria-hidden": true
1376
- }
1377
- ), /* @__PURE__ */ React21.createElement("aside", { className: "relative w-72 border-l border-sidebar-border bg-sidebar text-sidebar-foreground" }, /* @__PURE__ */ React21.createElement(
1378
- "button",
1379
- {
1380
- type: "button",
1381
- onClick: () => setMobileOpen(false),
1382
- "aria-label": "Close menu",
1383
- className: "absolute right-2 top-2 inline-flex h-9 w-9 items-center justify-center rounded-md hover:bg-sidebar-accent"
1384
- },
1385
- /* @__PURE__ */ React21.createElement(X, { className: "h-4 w-4" })
1386
- ), sidebarContent)) : null, /* @__PURE__ */ React21.createElement("div", { className: "flex min-w-0 flex-1 flex-col" }, /* @__PURE__ */ React21.createElement("header", { className: "flex h-14 items-center justify-between gap-3 border-b border-border bg-background/80 px-4 backdrop-blur md:px-6" }, /* @__PURE__ */ React21.createElement(
1387
- "button",
1388
- {
1389
- type: "button",
1390
- onClick: () => setMobileOpen(true),
1391
- "aria-label": "Open menu",
1392
- className: "inline-flex h-9 w-9 items-center justify-center rounded-md border border-border md:hidden"
1393
- },
1394
- /* @__PURE__ */ React21.createElement(Menu, { className: "h-4 w-4" })
1395
- ), /* @__PURE__ */ React21.createElement("div", { className: "flex items-center gap-3 md:ml-auto" }, showRoleSwitcher ? /* @__PURE__ */ React21.createElement(RoleSwitcher, null) : null, /* @__PURE__ */ React21.createElement(ThemeSwitcher, null))), /* @__PURE__ */ React21.createElement("main", { className: "min-w-0 flex-1 px-4 py-6 md:px-8 md:py-8" }, children)));
1396
- }
1397
-
1398
- // src/components/shells/StudioShell.tsx
1399
- import * as React22 from "react";
1400
- function StudioShell({
1401
- title,
1402
- description,
1403
- actions,
1404
- children,
1405
- className
1406
- }) {
1407
- return /* @__PURE__ */ React22.createElement("section", { className: cn("space-y-6", className) }, /* @__PURE__ */ React22.createElement("header", { className: "flex flex-wrap items-start justify-between gap-3" }, /* @__PURE__ */ React22.createElement("div", null, /* @__PURE__ */ React22.createElement("h1", { className: "text-2xl font-semibold tracking-tight" }, title), description ? /* @__PURE__ */ React22.createElement("p", { className: "mt-1 max-w-2xl text-sm text-muted-foreground" }, description) : null), actions ? /* @__PURE__ */ React22.createElement("div", { className: "flex items-center gap-2" }, actions) : null), /* @__PURE__ */ React22.createElement("div", { className: "rounded-lg border border-border bg-card p-4 md:p-6" }, children));
1408
- }
1409
-
1410
- // src/providers/SessionProvider.tsx
1411
- import { SessionProvider as NextAuthSessionProvider } from "next-auth/react";
1412
- function SessionProvider({
1413
- children,
1414
- session
1415
- }) {
1416
- return /* @__PURE__ */ React.createElement(NextAuthSessionProvider, { session }, children);
1417
- }
1418
-
1419
- // src/providers/QueryProvider.tsx
1420
- import * as React23 from "react";
1421
- import { QueryClient, QueryClientProvider } from "@tanstack/react-query";
1422
- function QueryProvider({ children }) {
1423
- const [client] = React23.useState(
1424
- () => new QueryClient({
1425
- defaultOptions: {
1426
- queries: { staleTime: 3e4, refetchOnWindowFocus: false }
1427
- }
1428
- })
1429
- );
1430
- return /* @__PURE__ */ React23.createElement(QueryClientProvider, { client }, children);
1431
- }
1432
-
1433
- // src/providers/MockProvider.tsx
1434
- import * as React24 from "react";
1435
- function MockProvider({
1436
- children,
1437
- loadWorker,
1438
- serviceWorkerUrl = "/mockServiceWorker.js"
1439
- }) {
1440
- const [ready, setReady] = React24.useState(() => process.env.NODE_ENV !== "development");
1441
- const [error, setError] = React24.useState(null);
1442
- React24.useEffect(() => {
1443
- if (process.env.NODE_ENV !== "development") return;
1444
- let cancelled = false;
1445
- void (async () => {
1446
- try {
1447
- const worker = await loadWorker();
1448
- await worker.start({
1449
- onUnhandledRequest: "bypass",
1450
- serviceWorker: { url: serviceWorkerUrl }
1451
- });
1452
- if (!cancelled) setReady(true);
1453
- } catch (e) {
1454
- console.error("[MockProvider] MSW failed to start:", e);
1455
- if (!cancelled) {
1456
- setError(e instanceof Error ? e.message : String(e));
1457
- setReady(true);
1458
- }
1459
- }
1460
- })();
1461
- return () => {
1462
- cancelled = true;
1463
- };
1464
- }, [loadWorker, serviceWorkerUrl]);
1465
- if (!ready) {
1466
- return /* @__PURE__ */ React24.createElement("div", { className: "flex min-h-svh items-center justify-center bg-background text-muted-foreground" }, /* @__PURE__ */ React24.createElement("p", { className: "text-sm" }, "Initializing mocks\u2026"));
1467
- }
1468
- return /* @__PURE__ */ React24.createElement(React24.Fragment, null, error ? /* @__PURE__ */ React24.createElement("div", { className: "border-b border-destructive/40 bg-destructive/10 px-4 py-2 text-xs text-destructive" }, "MSW failed to start (", error, "). Mock API calls will return real 404s.") : null, children);
1469
- }
1
+ export * from "./components/ui/avatar.js";
2
+ export * from "./components/ui/badge.js";
3
+ export * from "./components/ui/button.js";
4
+ export * from "./components/ui/card.js";
5
+ export * from "./components/ui/checkbox.js";
6
+ export * from "./components/ui/dialog.js";
7
+ export * from "./components/ui/dropdown-menu.js";
8
+ export * from "./components/ui/input.js";
9
+ export * from "./components/ui/label.js";
10
+ export * from "./components/ui/select.js";
11
+ export * from "./components/ui/separator.js";
12
+ export * from "./components/ui/sheet.js";
13
+ export * from "./components/ui/table.js";
14
+ export * from "./components/ui/tabs.js";
15
+ export * from "./components/ui/textarea.js";
16
+ import { Logo } from "./components/chrome/Logo.js";
17
+ import { ThemeSwitcher } from "./components/chrome/ThemeSwitcher.js";
18
+ import { RoleSwitcher } from "./components/chrome/RoleSwitcher.js";
19
+ import { PublicShell } from "./components/shells/PublicShell.js";
20
+ import { AppShell } from "./components/shells/AppShell.js";
21
+ import { StudioShell } from "./components/shells/StudioShell.js";
22
+ import { SessionProvider } from "./providers/SessionProvider.js";
23
+ import { QueryProvider } from "./providers/QueryProvider.js";
24
+ import { ThemeProvider, useThemeName } from "./providers/ThemeProvider.js";
25
+ import { MockProvider } from "./providers/MockProvider.js";
26
+ import { cn } from "./lib/utils.js";
1470
27
  export {
1471
28
  AppShell,
1472
- Avatar,
1473
- AvatarBadge,
1474
- AvatarFallback,
1475
- AvatarGroup,
1476
- AvatarGroupCount,
1477
- AvatarImage,
1478
- Badge,
1479
- Button,
1480
- Card,
1481
- CardAction,
1482
- CardContent,
1483
- CardDescription,
1484
- CardFooter,
1485
- CardHeader,
1486
- CardTitle,
1487
- Checkbox,
1488
- Dialog,
1489
- DialogClose,
1490
- DialogContent,
1491
- DialogDescription,
1492
- DialogFooter,
1493
- DialogHeader,
1494
- DialogOverlay,
1495
- DialogPortal,
1496
- DialogTitle,
1497
- DialogTrigger,
1498
- DropdownMenu,
1499
- DropdownMenuCheckboxItem,
1500
- DropdownMenuContent,
1501
- DropdownMenuGroup,
1502
- DropdownMenuItem,
1503
- DropdownMenuLabel,
1504
- DropdownMenuPortal,
1505
- DropdownMenuRadioGroup,
1506
- DropdownMenuRadioItem,
1507
- DropdownMenuSeparator,
1508
- DropdownMenuShortcut,
1509
- DropdownMenuSub,
1510
- DropdownMenuSubContent,
1511
- DropdownMenuSubTrigger,
1512
- DropdownMenuTrigger,
1513
- Input,
1514
- Label,
1515
29
  Logo,
1516
30
  MockProvider,
1517
31
  PublicShell,
1518
32
  QueryProvider,
1519
33
  RoleSwitcher,
1520
- Select,
1521
- SelectContent,
1522
- SelectGroup,
1523
- SelectItem,
1524
- SelectLabel,
1525
- SelectScrollDownButton,
1526
- SelectScrollUpButton,
1527
- SelectSeparator,
1528
- SelectTrigger,
1529
- SelectValue,
1530
- Separator,
1531
34
  SessionProvider,
1532
- Sheet,
1533
- SheetClose,
1534
- SheetContent,
1535
- SheetDescription,
1536
- SheetFooter,
1537
- SheetHeader,
1538
- SheetTitle,
1539
- SheetTrigger,
1540
35
  StudioShell,
1541
- Table,
1542
- TableBody,
1543
- TableCaption,
1544
- TableCell,
1545
- TableFooter,
1546
- TableHead,
1547
- TableHeader,
1548
- TableRow,
1549
- Tabs,
1550
- TabsContent,
1551
- TabsList,
1552
- TabsTrigger,
1553
- Textarea,
1554
36
  ThemeProvider,
1555
37
  ThemeSwitcher,
1556
- badgeVariants,
1557
- buttonVariants,
1558
38
  cn,
1559
- tabsListVariants,
1560
39
  useThemeName
1561
40
  };
1562
41
  //# sourceMappingURL=index.js.map