@tradalab/lyra 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.
- package/README.md +62 -0
- package/dist/blocks/index.d.ts +128 -0
- package/dist/blocks/index.js +421 -0
- package/dist/blocks/index.js.map +1 -0
- package/dist/breadcrumb-CGzHbSCd.d.ts +96 -0
- package/dist/chunk-BEAQYKGM.js +253 -0
- package/dist/chunk-BEAQYKGM.js.map +1 -0
- package/dist/chunk-E2QCV5QI.js +911 -0
- package/dist/chunk-E2QCV5QI.js.map +1 -0
- package/dist/chunk-KFQOYZ64.js +58 -0
- package/dist/chunk-KFQOYZ64.js.map +1 -0
- package/dist/chunk-QYA2HGKW.js +20 -0
- package/dist/chunk-QYA2HGKW.js.map +1 -0
- package/dist/chunk-X2BCIKOJ.js +342 -0
- package/dist/chunk-X2BCIKOJ.js.map +1 -0
- package/dist/chunk-XH55BHUU.js +11 -0
- package/dist/chunk-XH55BHUU.js.map +1 -0
- package/dist/data-table/index.d.ts +63 -0
- package/dist/data-table/index.js +85 -0
- package/dist/data-table/index.js.map +1 -0
- package/dist/hooks/index.d.ts +9 -0
- package/dist/hooks/index.js +4 -0
- package/dist/hooks/index.js.map +1 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +3 -0
- package/dist/index.js.map +1 -0
- package/dist/shell/index.d.ts +84 -0
- package/dist/shell/index.js +93 -0
- package/dist/shell/index.js.map +1 -0
- package/dist/ui/index.d.ts +416 -0
- package/dist/ui/index.js +2373 -0
- package/dist/ui/index.js.map +1 -0
- package/dist/utils/index.d.ts +14 -0
- package/dist/utils/index.js +3 -0
- package/dist/utils/index.js.map +1 -0
- package/package.json +133 -0
- package/styles/globals.css +151 -0
package/dist/ui/index.js
ADDED
|
@@ -0,0 +1,2373 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { Dialog, DialogHeader, DialogTitle, DialogDescription, DialogContent, Label } from '../chunk-BEAQYKGM.js';
|
|
3
|
+
export { Card, CardAction, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, Label } from '../chunk-BEAQYKGM.js';
|
|
4
|
+
import { DropdownMenu, DropdownMenuTrigger, DropdownMenuContent, DropdownMenuLabel, DropdownMenuSeparator, DropdownMenuItem } from '../chunk-X2BCIKOJ.js';
|
|
5
|
+
export { DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableRow } from '../chunk-X2BCIKOJ.js';
|
|
6
|
+
import { Separator, Input } from '../chunk-E2QCV5QI.js';
|
|
7
|
+
export { Breadcrumb, BreadcrumbEllipsis, BreadcrumbItem, BreadcrumbLink, BreadcrumbList, BreadcrumbPage, BreadcrumbSeparator, Input, Separator, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetTitle, SheetTrigger, Sidebar, SidebarContent, SidebarFooter, SidebarGroup, SidebarGroupAction, SidebarGroupContent, SidebarGroupLabel, SidebarHeader, SidebarInput, SidebarInset, SidebarMenu, SidebarMenuAction, SidebarMenuBadge, SidebarMenuButton, SidebarMenuItem, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubButton, SidebarMenuSubItem, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, Skeleton, Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, useSidebar } from '../chunk-E2QCV5QI.js';
|
|
8
|
+
import '../chunk-QYA2HGKW.js';
|
|
9
|
+
import { Button } from '../chunk-KFQOYZ64.js';
|
|
10
|
+
export { Button, buttonVariants } from '../chunk-KFQOYZ64.js';
|
|
11
|
+
import { cn } from '../chunk-XH55BHUU.js';
|
|
12
|
+
import * as React26 from 'react';
|
|
13
|
+
import { useMemo } from 'react';
|
|
14
|
+
import { Accordion as Accordion$1, AlertDialog as AlertDialog$1, AspectRatio as AspectRatio$1, Avatar as Avatar$1, Slot, Checkbox as Checkbox$1, Collapsible as Collapsible$1, ContextMenu as ContextMenu$1, HoverCard as HoverCard$1, Menubar as Menubar$1, NavigationMenu as NavigationMenu$1, Popover as Popover$1, Progress as Progress$1, RadioGroup as RadioGroup$1, ScrollArea as ScrollArea$1, Select as Select$1, Slider as Slider$1, Switch as Switch$1, Tabs as Tabs$1, Toggle as Toggle$1, ToggleGroup as ToggleGroup$1 } from 'radix-ui';
|
|
15
|
+
import { ChevronDownIcon, ChevronUpIcon, CheckIcon, SearchIcon, ChevronRightIcon, MinusIcon, ChevronLeftIcon, MoreHorizontalIcon, Loader2Icon, OctagonXIcon, TriangleAlertIcon, InfoIcon, CircleCheckIcon, CircleUser, Users, LogOut, LogIn } from 'lucide-react';
|
|
16
|
+
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
17
|
+
import { cva } from 'class-variance-authority';
|
|
18
|
+
import { Command as Command$1 } from 'cmdk';
|
|
19
|
+
import { Drawer as Drawer$1 } from 'vaul';
|
|
20
|
+
import { OTPInput, OTPInputContext } from 'input-otp';
|
|
21
|
+
import * as ResizablePrimitive from 'react-resizable-panels';
|
|
22
|
+
import { useTheme } from 'next-themes';
|
|
23
|
+
import { Toaster as Toaster$1 } from 'sonner';
|
|
24
|
+
export { toast } from 'sonner';
|
|
25
|
+
|
|
26
|
+
function Accordion({
|
|
27
|
+
className,
|
|
28
|
+
...props
|
|
29
|
+
}) {
|
|
30
|
+
return /* @__PURE__ */ jsx(
|
|
31
|
+
Accordion$1.Root,
|
|
32
|
+
{
|
|
33
|
+
"data-slot": "accordion",
|
|
34
|
+
className: cn("flex w-full flex-col", className),
|
|
35
|
+
...props
|
|
36
|
+
}
|
|
37
|
+
);
|
|
38
|
+
}
|
|
39
|
+
function AccordionItem({
|
|
40
|
+
className,
|
|
41
|
+
...props
|
|
42
|
+
}) {
|
|
43
|
+
return /* @__PURE__ */ jsx(
|
|
44
|
+
Accordion$1.Item,
|
|
45
|
+
{
|
|
46
|
+
"data-slot": "accordion-item",
|
|
47
|
+
className: cn("not-last:border-b", className),
|
|
48
|
+
...props
|
|
49
|
+
}
|
|
50
|
+
);
|
|
51
|
+
}
|
|
52
|
+
function AccordionTrigger({
|
|
53
|
+
className,
|
|
54
|
+
children,
|
|
55
|
+
...props
|
|
56
|
+
}) {
|
|
57
|
+
return /* @__PURE__ */ jsx(Accordion$1.Header, { className: "flex", children: /* @__PURE__ */ jsxs(
|
|
58
|
+
Accordion$1.Trigger,
|
|
59
|
+
{
|
|
60
|
+
"data-slot": "accordion-trigger",
|
|
61
|
+
className: cn(
|
|
62
|
+
"group/accordion-trigger relative flex flex-1 items-start justify-between rounded-none border border-transparent py-2.5 text-left text-xs font-medium transition-all outline-none hover:underline focus-visible:border-ring focus-visible:ring-1 focus-visible:ring-ring/50 focus-visible:after:border-ring disabled:pointer-events-none disabled:opacity-50 **:data-[slot=accordion-trigger-icon]:ml-auto **:data-[slot=accordion-trigger-icon]:size-4 **:data-[slot=accordion-trigger-icon]:text-muted-foreground",
|
|
63
|
+
className
|
|
64
|
+
),
|
|
65
|
+
...props,
|
|
66
|
+
children: [
|
|
67
|
+
children,
|
|
68
|
+
/* @__PURE__ */ jsx(ChevronDownIcon, { "data-slot": "accordion-trigger-icon", className: "pointer-events-none shrink-0 group-aria-expanded/accordion-trigger:hidden" }),
|
|
69
|
+
/* @__PURE__ */ jsx(ChevronUpIcon, { "data-slot": "accordion-trigger-icon", className: "pointer-events-none hidden shrink-0 group-aria-expanded/accordion-trigger:inline" })
|
|
70
|
+
]
|
|
71
|
+
}
|
|
72
|
+
) });
|
|
73
|
+
}
|
|
74
|
+
function AccordionContent({
|
|
75
|
+
className,
|
|
76
|
+
children,
|
|
77
|
+
...props
|
|
78
|
+
}) {
|
|
79
|
+
return /* @__PURE__ */ jsx(
|
|
80
|
+
Accordion$1.Content,
|
|
81
|
+
{
|
|
82
|
+
"data-slot": "accordion-content",
|
|
83
|
+
className: "overflow-hidden text-xs data-open:animate-accordion-down data-closed:animate-accordion-up",
|
|
84
|
+
...props,
|
|
85
|
+
children: /* @__PURE__ */ jsx(
|
|
86
|
+
"div",
|
|
87
|
+
{
|
|
88
|
+
className: cn(
|
|
89
|
+
"h-(--radix-accordion-content-height) pt-0 pb-2.5 [&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground [&_p:not(:last-child)]:mb-4",
|
|
90
|
+
className
|
|
91
|
+
),
|
|
92
|
+
children
|
|
93
|
+
}
|
|
94
|
+
)
|
|
95
|
+
}
|
|
96
|
+
);
|
|
97
|
+
}
|
|
98
|
+
var alertVariants = cva(
|
|
99
|
+
"group/alert relative grid w-full gap-0.5 rounded-none border px-2.5 py-2 text-left text-xs has-data-[slot=alert-action]:relative has-data-[slot=alert-action]:pr-18 has-[>svg]:grid-cols-[auto_1fr] has-[>svg]:gap-x-2 *:[svg]:row-span-2 *:[svg]:translate-y-0 *:[svg]:text-current *:[svg:not([class*='size-'])]:size-4",
|
|
100
|
+
{
|
|
101
|
+
variants: {
|
|
102
|
+
variant: {
|
|
103
|
+
default: "bg-card text-card-foreground",
|
|
104
|
+
destructive: "bg-card text-destructive *:data-[slot=alert-description]:text-destructive/90 *:[svg]:text-current"
|
|
105
|
+
}
|
|
106
|
+
},
|
|
107
|
+
defaultVariants: {
|
|
108
|
+
variant: "default"
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
);
|
|
112
|
+
function Alert({ className, variant, ...props }) {
|
|
113
|
+
return /* @__PURE__ */ jsx("div", { "data-slot": "alert", role: "alert", className: cn(alertVariants({ variant }), className), ...props });
|
|
114
|
+
}
|
|
115
|
+
function AlertTitle({ className, ...props }) {
|
|
116
|
+
return /* @__PURE__ */ jsx(
|
|
117
|
+
"div",
|
|
118
|
+
{
|
|
119
|
+
"data-slot": "alert-title",
|
|
120
|
+
className: cn("font-medium group-has-[>svg]/alert:col-start-2 [&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground", className),
|
|
121
|
+
...props
|
|
122
|
+
}
|
|
123
|
+
);
|
|
124
|
+
}
|
|
125
|
+
function AlertDescription({ className, ...props }) {
|
|
126
|
+
return /* @__PURE__ */ jsx(
|
|
127
|
+
"div",
|
|
128
|
+
{
|
|
129
|
+
"data-slot": "alert-description",
|
|
130
|
+
className: cn(
|
|
131
|
+
"text-xs/relaxed text-balance text-muted-foreground md:text-pretty [&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground [&_p:not(:last-child)]:mb-2",
|
|
132
|
+
className
|
|
133
|
+
),
|
|
134
|
+
...props
|
|
135
|
+
}
|
|
136
|
+
);
|
|
137
|
+
}
|
|
138
|
+
function AlertAction({ className, ...props }) {
|
|
139
|
+
return /* @__PURE__ */ jsx("div", { "data-slot": "alert-action", className: cn("absolute top-[calc(--spacing(1.25))] right-[calc(--spacing(1.25))]", className), ...props });
|
|
140
|
+
}
|
|
141
|
+
function AlertDialog({
|
|
142
|
+
...props
|
|
143
|
+
}) {
|
|
144
|
+
return /* @__PURE__ */ jsx(AlertDialog$1.Root, { "data-slot": "alert-dialog", ...props });
|
|
145
|
+
}
|
|
146
|
+
function AlertDialogTrigger({
|
|
147
|
+
...props
|
|
148
|
+
}) {
|
|
149
|
+
return /* @__PURE__ */ jsx(AlertDialog$1.Trigger, { "data-slot": "alert-dialog-trigger", ...props });
|
|
150
|
+
}
|
|
151
|
+
function AlertDialogPortal({
|
|
152
|
+
...props
|
|
153
|
+
}) {
|
|
154
|
+
return /* @__PURE__ */ jsx(AlertDialog$1.Portal, { "data-slot": "alert-dialog-portal", ...props });
|
|
155
|
+
}
|
|
156
|
+
function AlertDialogOverlay({
|
|
157
|
+
className,
|
|
158
|
+
...props
|
|
159
|
+
}) {
|
|
160
|
+
return /* @__PURE__ */ jsx(
|
|
161
|
+
AlertDialog$1.Overlay,
|
|
162
|
+
{
|
|
163
|
+
"data-slot": "alert-dialog-overlay",
|
|
164
|
+
className: cn(
|
|
165
|
+
"fixed inset-0 z-50 bg-black/10 duration-100 supports-backdrop-filter:backdrop-blur-xs data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0",
|
|
166
|
+
className
|
|
167
|
+
),
|
|
168
|
+
...props
|
|
169
|
+
}
|
|
170
|
+
);
|
|
171
|
+
}
|
|
172
|
+
function AlertDialogContent({
|
|
173
|
+
className,
|
|
174
|
+
size = "default",
|
|
175
|
+
...props
|
|
176
|
+
}) {
|
|
177
|
+
return /* @__PURE__ */ jsxs(AlertDialogPortal, { children: [
|
|
178
|
+
/* @__PURE__ */ jsx(AlertDialogOverlay, {}),
|
|
179
|
+
/* @__PURE__ */ jsx(
|
|
180
|
+
AlertDialog$1.Content,
|
|
181
|
+
{
|
|
182
|
+
"data-slot": "alert-dialog-content",
|
|
183
|
+
"data-size": size,
|
|
184
|
+
className: cn(
|
|
185
|
+
"group/alert-dialog-content fixed top-1/2 left-1/2 z-50 grid w-full -translate-x-1/2 -translate-y-1/2 gap-4 rounded-none bg-popover p-4 text-popover-foreground ring-1 ring-foreground/10 duration-100 outline-none data-[size=default]:max-w-xs data-[size=sm]:max-w-xs data-[size=default]:sm:max-w-sm data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",
|
|
186
|
+
className
|
|
187
|
+
),
|
|
188
|
+
...props
|
|
189
|
+
}
|
|
190
|
+
)
|
|
191
|
+
] });
|
|
192
|
+
}
|
|
193
|
+
function AlertDialogHeader({
|
|
194
|
+
className,
|
|
195
|
+
...props
|
|
196
|
+
}) {
|
|
197
|
+
return /* @__PURE__ */ jsx(
|
|
198
|
+
"div",
|
|
199
|
+
{
|
|
200
|
+
"data-slot": "alert-dialog-header",
|
|
201
|
+
className: cn(
|
|
202
|
+
"grid grid-rows-[auto_1fr] place-items-center gap-1.5 text-center has-data-[slot=alert-dialog-media]:grid-rows-[auto_auto_1fr] has-data-[slot=alert-dialog-media]:gap-x-4 sm:group-data-[size=default]/alert-dialog-content:place-items-start sm:group-data-[size=default]/alert-dialog-content:text-left sm:group-data-[size=default]/alert-dialog-content:has-data-[slot=alert-dialog-media]:grid-rows-[auto_1fr]",
|
|
203
|
+
className
|
|
204
|
+
),
|
|
205
|
+
...props
|
|
206
|
+
}
|
|
207
|
+
);
|
|
208
|
+
}
|
|
209
|
+
function AlertDialogFooter({
|
|
210
|
+
className,
|
|
211
|
+
...props
|
|
212
|
+
}) {
|
|
213
|
+
return /* @__PURE__ */ jsx(
|
|
214
|
+
"div",
|
|
215
|
+
{
|
|
216
|
+
"data-slot": "alert-dialog-footer",
|
|
217
|
+
className: cn(
|
|
218
|
+
"flex flex-col-reverse gap-2 group-data-[size=sm]/alert-dialog-content:grid group-data-[size=sm]/alert-dialog-content:grid-cols-2 sm:flex-row sm:justify-end",
|
|
219
|
+
className
|
|
220
|
+
),
|
|
221
|
+
...props
|
|
222
|
+
}
|
|
223
|
+
);
|
|
224
|
+
}
|
|
225
|
+
function AlertDialogMedia({
|
|
226
|
+
className,
|
|
227
|
+
...props
|
|
228
|
+
}) {
|
|
229
|
+
return /* @__PURE__ */ jsx(
|
|
230
|
+
"div",
|
|
231
|
+
{
|
|
232
|
+
"data-slot": "alert-dialog-media",
|
|
233
|
+
className: cn(
|
|
234
|
+
"mb-2 inline-flex size-10 items-center justify-center rounded-none bg-muted sm:group-data-[size=default]/alert-dialog-content:row-span-2 *:[svg:not([class*='size-'])]:size-6",
|
|
235
|
+
className
|
|
236
|
+
),
|
|
237
|
+
...props
|
|
238
|
+
}
|
|
239
|
+
);
|
|
240
|
+
}
|
|
241
|
+
function AlertDialogTitle({
|
|
242
|
+
className,
|
|
243
|
+
...props
|
|
244
|
+
}) {
|
|
245
|
+
return /* @__PURE__ */ jsx(
|
|
246
|
+
AlertDialog$1.Title,
|
|
247
|
+
{
|
|
248
|
+
"data-slot": "alert-dialog-title",
|
|
249
|
+
className: cn(
|
|
250
|
+
"font-heading text-sm font-medium sm:group-data-[size=default]/alert-dialog-content:group-has-data-[slot=alert-dialog-media]/alert-dialog-content:col-start-2",
|
|
251
|
+
className
|
|
252
|
+
),
|
|
253
|
+
...props
|
|
254
|
+
}
|
|
255
|
+
);
|
|
256
|
+
}
|
|
257
|
+
function AlertDialogDescription({
|
|
258
|
+
className,
|
|
259
|
+
...props
|
|
260
|
+
}) {
|
|
261
|
+
return /* @__PURE__ */ jsx(
|
|
262
|
+
AlertDialog$1.Description,
|
|
263
|
+
{
|
|
264
|
+
"data-slot": "alert-dialog-description",
|
|
265
|
+
className: cn(
|
|
266
|
+
"text-xs/relaxed text-balance text-muted-foreground md:text-pretty *:[a]:underline *:[a]:underline-offset-3 *:[a]:hover:text-foreground",
|
|
267
|
+
className
|
|
268
|
+
),
|
|
269
|
+
...props
|
|
270
|
+
}
|
|
271
|
+
);
|
|
272
|
+
}
|
|
273
|
+
function AlertDialogAction({
|
|
274
|
+
className,
|
|
275
|
+
variant = "default",
|
|
276
|
+
size = "default",
|
|
277
|
+
...props
|
|
278
|
+
}) {
|
|
279
|
+
return /* @__PURE__ */ jsx(Button, { variant, size, asChild: true, children: /* @__PURE__ */ jsx(
|
|
280
|
+
AlertDialog$1.Action,
|
|
281
|
+
{
|
|
282
|
+
"data-slot": "alert-dialog-action",
|
|
283
|
+
className: cn(className),
|
|
284
|
+
...props
|
|
285
|
+
}
|
|
286
|
+
) });
|
|
287
|
+
}
|
|
288
|
+
function AlertDialogCancel({
|
|
289
|
+
className,
|
|
290
|
+
variant = "outline",
|
|
291
|
+
size = "default",
|
|
292
|
+
...props
|
|
293
|
+
}) {
|
|
294
|
+
return /* @__PURE__ */ jsx(Button, { variant, size, asChild: true, children: /* @__PURE__ */ jsx(
|
|
295
|
+
AlertDialog$1.Cancel,
|
|
296
|
+
{
|
|
297
|
+
"data-slot": "alert-dialog-cancel",
|
|
298
|
+
className: cn(className),
|
|
299
|
+
...props
|
|
300
|
+
}
|
|
301
|
+
) });
|
|
302
|
+
}
|
|
303
|
+
function AspectRatio({ ...props }) {
|
|
304
|
+
return /* @__PURE__ */ jsx(AspectRatio$1.Root, { "data-slot": "aspect-ratio", ...props });
|
|
305
|
+
}
|
|
306
|
+
function Avatar({
|
|
307
|
+
className,
|
|
308
|
+
size = "default",
|
|
309
|
+
...props
|
|
310
|
+
}) {
|
|
311
|
+
return /* @__PURE__ */ jsx(
|
|
312
|
+
Avatar$1.Root,
|
|
313
|
+
{
|
|
314
|
+
"data-slot": "avatar",
|
|
315
|
+
"data-size": size,
|
|
316
|
+
className: cn(
|
|
317
|
+
"group/avatar relative flex size-8 shrink-0 rounded-full select-none after:absolute after:inset-0 after:rounded-full after:border after:border-border after:mix-blend-darken data-[size=lg]:size-10 data-[size=sm]:size-6 dark:after:mix-blend-lighten",
|
|
318
|
+
className
|
|
319
|
+
),
|
|
320
|
+
...props
|
|
321
|
+
}
|
|
322
|
+
);
|
|
323
|
+
}
|
|
324
|
+
function AvatarImage({
|
|
325
|
+
className,
|
|
326
|
+
...props
|
|
327
|
+
}) {
|
|
328
|
+
return /* @__PURE__ */ jsx(
|
|
329
|
+
Avatar$1.Image,
|
|
330
|
+
{
|
|
331
|
+
"data-slot": "avatar-image",
|
|
332
|
+
className: cn(
|
|
333
|
+
"aspect-square size-full rounded-full object-cover",
|
|
334
|
+
className
|
|
335
|
+
),
|
|
336
|
+
...props
|
|
337
|
+
}
|
|
338
|
+
);
|
|
339
|
+
}
|
|
340
|
+
function AvatarFallback({
|
|
341
|
+
className,
|
|
342
|
+
...props
|
|
343
|
+
}) {
|
|
344
|
+
return /* @__PURE__ */ jsx(
|
|
345
|
+
Avatar$1.Fallback,
|
|
346
|
+
{
|
|
347
|
+
"data-slot": "avatar-fallback",
|
|
348
|
+
className: cn(
|
|
349
|
+
"flex size-full items-center justify-center rounded-full bg-muted text-sm text-muted-foreground group-data-[size=sm]/avatar:text-xs",
|
|
350
|
+
className
|
|
351
|
+
),
|
|
352
|
+
...props
|
|
353
|
+
}
|
|
354
|
+
);
|
|
355
|
+
}
|
|
356
|
+
function AvatarBadge({ className, ...props }) {
|
|
357
|
+
return /* @__PURE__ */ jsx(
|
|
358
|
+
"span",
|
|
359
|
+
{
|
|
360
|
+
"data-slot": "avatar-badge",
|
|
361
|
+
className: cn(
|
|
362
|
+
"absolute right-0 bottom-0 z-10 inline-flex items-center justify-center rounded-full bg-primary text-primary-foreground bg-blend-color ring-2 ring-background select-none",
|
|
363
|
+
"group-data-[size=sm]/avatar:size-2 group-data-[size=sm]/avatar:[&>svg]:hidden",
|
|
364
|
+
"group-data-[size=default]/avatar:size-2.5 group-data-[size=default]/avatar:[&>svg]:size-2",
|
|
365
|
+
"group-data-[size=lg]/avatar:size-3 group-data-[size=lg]/avatar:[&>svg]:size-2",
|
|
366
|
+
className
|
|
367
|
+
),
|
|
368
|
+
...props
|
|
369
|
+
}
|
|
370
|
+
);
|
|
371
|
+
}
|
|
372
|
+
function AvatarGroup({ className, ...props }) {
|
|
373
|
+
return /* @__PURE__ */ jsx(
|
|
374
|
+
"div",
|
|
375
|
+
{
|
|
376
|
+
"data-slot": "avatar-group",
|
|
377
|
+
className: cn(
|
|
378
|
+
"group/avatar-group flex -space-x-2 *:data-[slot=avatar]:ring-2 *:data-[slot=avatar]:ring-background",
|
|
379
|
+
className
|
|
380
|
+
),
|
|
381
|
+
...props
|
|
382
|
+
}
|
|
383
|
+
);
|
|
384
|
+
}
|
|
385
|
+
function AvatarGroupCount({
|
|
386
|
+
className,
|
|
387
|
+
...props
|
|
388
|
+
}) {
|
|
389
|
+
return /* @__PURE__ */ jsx(
|
|
390
|
+
"div",
|
|
391
|
+
{
|
|
392
|
+
"data-slot": "avatar-group-count",
|
|
393
|
+
className: cn(
|
|
394
|
+
"relative flex size-8 shrink-0 items-center justify-center rounded-full bg-muted text-xs 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",
|
|
395
|
+
className
|
|
396
|
+
),
|
|
397
|
+
...props
|
|
398
|
+
}
|
|
399
|
+
);
|
|
400
|
+
}
|
|
401
|
+
var badgeVariants = cva(
|
|
402
|
+
"group/badge inline-flex h-5 w-fit shrink-0 items-center justify-center gap-1 overflow-hidden rounded-none border border-transparent px-2 py-0.5 text-xs font-medium whitespace-nowrap transition-all focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&>svg]:pointer-events-none [&>svg]:size-3!",
|
|
403
|
+
{
|
|
404
|
+
variants: {
|
|
405
|
+
variant: {
|
|
406
|
+
default: "bg-primary text-primary-foreground [a]:hover:bg-primary/80",
|
|
407
|
+
secondary: "bg-secondary text-secondary-foreground [a]:hover:bg-secondary/80",
|
|
408
|
+
destructive: "bg-destructive/10 text-destructive focus-visible:ring-destructive/20 dark:bg-destructive/20 dark:focus-visible:ring-destructive/40 [a]:hover:bg-destructive/20",
|
|
409
|
+
outline: "border-border text-foreground [a]:hover:bg-muted [a]:hover:text-muted-foreground",
|
|
410
|
+
ghost: "hover:bg-muted hover:text-muted-foreground dark:hover:bg-muted/50",
|
|
411
|
+
link: "text-primary underline-offset-4 hover:underline"
|
|
412
|
+
}
|
|
413
|
+
},
|
|
414
|
+
defaultVariants: {
|
|
415
|
+
variant: "default"
|
|
416
|
+
}
|
|
417
|
+
}
|
|
418
|
+
);
|
|
419
|
+
function Badge({
|
|
420
|
+
className,
|
|
421
|
+
variant = "default",
|
|
422
|
+
asChild = false,
|
|
423
|
+
...props
|
|
424
|
+
}) {
|
|
425
|
+
const Comp = asChild ? Slot.Root : "span";
|
|
426
|
+
return /* @__PURE__ */ jsx(
|
|
427
|
+
Comp,
|
|
428
|
+
{
|
|
429
|
+
"data-slot": "badge",
|
|
430
|
+
"data-variant": variant,
|
|
431
|
+
className: cn(badgeVariants({ variant }), className),
|
|
432
|
+
...props
|
|
433
|
+
}
|
|
434
|
+
);
|
|
435
|
+
}
|
|
436
|
+
var buttonGroupVariants = cva(
|
|
437
|
+
"group/button-group flex w-fit items-stretch rounded-none *:focus-visible:relative *:focus-visible:z-10 has-[>[data-slot=button-group]]:gap-2 has-[select[aria-hidden=true]:last-child]:[&>[data-slot=select-trigger]:last-of-type]:rounded-none [&>[data-slot=select-trigger]:not([class*='w-'])]:w-fit [&>input]:flex-1",
|
|
438
|
+
{
|
|
439
|
+
variants: {
|
|
440
|
+
orientation: {
|
|
441
|
+
horizontal: "[&>*:not(:first-child)]:rounded-l-none [&>*:not(:first-child)]:border-l-0 [&>*:not(:last-child)]:rounded-r-none",
|
|
442
|
+
vertical: "flex-col [&>*:not(:first-child)]:rounded-t-none [&>*:not(:first-child)]:border-t-0 [&>*:not(:last-child)]:rounded-b-none"
|
|
443
|
+
}
|
|
444
|
+
},
|
|
445
|
+
defaultVariants: {
|
|
446
|
+
orientation: "horizontal"
|
|
447
|
+
}
|
|
448
|
+
}
|
|
449
|
+
);
|
|
450
|
+
function ButtonGroup({
|
|
451
|
+
className,
|
|
452
|
+
orientation,
|
|
453
|
+
...props
|
|
454
|
+
}) {
|
|
455
|
+
return /* @__PURE__ */ jsx(
|
|
456
|
+
"div",
|
|
457
|
+
{
|
|
458
|
+
role: "group",
|
|
459
|
+
"data-slot": "button-group",
|
|
460
|
+
"data-orientation": orientation,
|
|
461
|
+
className: cn(buttonGroupVariants({ orientation }), className),
|
|
462
|
+
...props
|
|
463
|
+
}
|
|
464
|
+
);
|
|
465
|
+
}
|
|
466
|
+
function ButtonGroupText({
|
|
467
|
+
className,
|
|
468
|
+
asChild = false,
|
|
469
|
+
...props
|
|
470
|
+
}) {
|
|
471
|
+
const Comp = asChild ? Slot.Root : "div";
|
|
472
|
+
return /* @__PURE__ */ jsx(
|
|
473
|
+
Comp,
|
|
474
|
+
{
|
|
475
|
+
className: cn(
|
|
476
|
+
"flex items-center gap-2 rounded-none border bg-muted px-2.5 text-xs font-medium [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4",
|
|
477
|
+
className
|
|
478
|
+
),
|
|
479
|
+
...props
|
|
480
|
+
}
|
|
481
|
+
);
|
|
482
|
+
}
|
|
483
|
+
function ButtonGroupSeparator({
|
|
484
|
+
className,
|
|
485
|
+
orientation = "vertical",
|
|
486
|
+
...props
|
|
487
|
+
}) {
|
|
488
|
+
return /* @__PURE__ */ jsx(
|
|
489
|
+
Separator,
|
|
490
|
+
{
|
|
491
|
+
"data-slot": "button-group-separator",
|
|
492
|
+
orientation,
|
|
493
|
+
className: cn(
|
|
494
|
+
"relative self-stretch bg-input data-horizontal:mx-px data-horizontal:w-auto data-vertical:my-px data-vertical:h-auto",
|
|
495
|
+
className
|
|
496
|
+
),
|
|
497
|
+
...props
|
|
498
|
+
}
|
|
499
|
+
);
|
|
500
|
+
}
|
|
501
|
+
function Checkbox({
|
|
502
|
+
className,
|
|
503
|
+
...props
|
|
504
|
+
}) {
|
|
505
|
+
return /* @__PURE__ */ jsx(
|
|
506
|
+
Checkbox$1.Root,
|
|
507
|
+
{
|
|
508
|
+
"data-slot": "checkbox",
|
|
509
|
+
className: cn(
|
|
510
|
+
"peer relative flex size-4 shrink-0 items-center justify-center rounded-none border border-input transition-colors outline-none group-has-disabled/field:opacity-50 after:absolute after:-inset-x-3 after:-inset-y-2 focus-visible:border-ring focus-visible:ring-1 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-1 aria-invalid:ring-destructive/20 aria-invalid:aria-checked:border-primary dark:bg-input/30 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 data-checked:border-primary data-checked:bg-primary data-checked:text-primary-foreground dark:data-checked:bg-primary",
|
|
511
|
+
className
|
|
512
|
+
),
|
|
513
|
+
...props,
|
|
514
|
+
children: /* @__PURE__ */ jsx(
|
|
515
|
+
Checkbox$1.Indicator,
|
|
516
|
+
{
|
|
517
|
+
"data-slot": "checkbox-indicator",
|
|
518
|
+
className: "grid place-content-center text-current transition-none [&>svg]:size-3.5",
|
|
519
|
+
children: /* @__PURE__ */ jsx(
|
|
520
|
+
CheckIcon,
|
|
521
|
+
{}
|
|
522
|
+
)
|
|
523
|
+
}
|
|
524
|
+
)
|
|
525
|
+
}
|
|
526
|
+
);
|
|
527
|
+
}
|
|
528
|
+
function Collapsible({
|
|
529
|
+
...props
|
|
530
|
+
}) {
|
|
531
|
+
return /* @__PURE__ */ jsx(Collapsible$1.Root, { "data-slot": "collapsible", ...props });
|
|
532
|
+
}
|
|
533
|
+
function CollapsibleTrigger({
|
|
534
|
+
...props
|
|
535
|
+
}) {
|
|
536
|
+
return /* @__PURE__ */ jsx(
|
|
537
|
+
Collapsible$1.CollapsibleTrigger,
|
|
538
|
+
{
|
|
539
|
+
"data-slot": "collapsible-trigger",
|
|
540
|
+
...props
|
|
541
|
+
}
|
|
542
|
+
);
|
|
543
|
+
}
|
|
544
|
+
function CollapsibleContent({
|
|
545
|
+
...props
|
|
546
|
+
}) {
|
|
547
|
+
return /* @__PURE__ */ jsx(
|
|
548
|
+
Collapsible$1.CollapsibleContent,
|
|
549
|
+
{
|
|
550
|
+
"data-slot": "collapsible-content",
|
|
551
|
+
...props
|
|
552
|
+
}
|
|
553
|
+
);
|
|
554
|
+
}
|
|
555
|
+
function Textarea({ className, ...props }) {
|
|
556
|
+
return /* @__PURE__ */ jsx(
|
|
557
|
+
"textarea",
|
|
558
|
+
{
|
|
559
|
+
"data-slot": "textarea",
|
|
560
|
+
className: cn(
|
|
561
|
+
"flex field-sizing-content min-h-16 w-full rounded-none border border-input bg-transparent px-2.5 py-2 text-xs transition-colors outline-none placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-1 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:bg-input/50 disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-1 aria-invalid:ring-destructive/20 md:text-xs dark:bg-input/30 dark:disabled:bg-input/80 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40",
|
|
562
|
+
className
|
|
563
|
+
),
|
|
564
|
+
...props
|
|
565
|
+
}
|
|
566
|
+
);
|
|
567
|
+
}
|
|
568
|
+
function InputGroup({ className, ...props }) {
|
|
569
|
+
return /* @__PURE__ */ jsx(
|
|
570
|
+
"div",
|
|
571
|
+
{
|
|
572
|
+
"data-slot": "input-group",
|
|
573
|
+
role: "group",
|
|
574
|
+
className: cn(
|
|
575
|
+
"group/input-group relative flex h-8 w-full min-w-0 items-center rounded-none border border-input transition-colors outline-none in-data-[slot=combobox-content]:focus-within:border-inherit in-data-[slot=combobox-content]:focus-within:ring-0 has-disabled:bg-input/50 has-disabled:opacity-50 has-[[data-slot=input-group-control]:focus-visible]:border-ring has-[[data-slot=input-group-control]:focus-visible]:ring-1 has-[[data-slot=input-group-control]:focus-visible]:ring-ring/50 has-[[data-slot][aria-invalid=true]]:border-destructive has-[[data-slot][aria-invalid=true]]:ring-1 has-[[data-slot][aria-invalid=true]]:ring-destructive/20 has-[>[data-align=block-end]]:h-auto has-[>[data-align=block-end]]:flex-col has-[>[data-align=block-start]]:h-auto has-[>[data-align=block-start]]:flex-col has-[>textarea]:h-auto dark:bg-input/30 dark:has-disabled:bg-input/80 dark:has-[[data-slot][aria-invalid=true]]:ring-destructive/40 has-[>[data-align=block-end]]:[&>input]:pt-3 has-[>[data-align=block-start]]:[&>input]:pb-3 has-[>[data-align=inline-end]]:[&>input]:pr-1.5 has-[>[data-align=inline-start]]:[&>input]:pl-1.5",
|
|
576
|
+
className
|
|
577
|
+
),
|
|
578
|
+
...props
|
|
579
|
+
}
|
|
580
|
+
);
|
|
581
|
+
}
|
|
582
|
+
var inputGroupAddonVariants = cva(
|
|
583
|
+
"flex h-auto cursor-text items-center justify-center gap-2 py-1.5 text-xs font-medium text-muted-foreground select-none group-data-[disabled=true]/input-group:opacity-50 [&>kbd]:rounded-none [&>svg:not([class*='size-'])]:size-4",
|
|
584
|
+
{
|
|
585
|
+
variants: {
|
|
586
|
+
align: {
|
|
587
|
+
"inline-start": "order-first pl-2 has-[>button]:ml-[-0.3rem] has-[>kbd]:ml-[-0.15rem]",
|
|
588
|
+
"inline-end": "order-last pr-2 has-[>button]:mr-[-0.3rem] has-[>kbd]:mr-[-0.15rem]",
|
|
589
|
+
"block-start": "order-first w-full justify-start px-2.5 pt-2 group-has-[>input]/input-group:pt-2 [.border-b]:pb-2",
|
|
590
|
+
"block-end": "order-last w-full justify-start px-2.5 pb-2 group-has-[>input]/input-group:pb-2 [.border-t]:pt-2"
|
|
591
|
+
}
|
|
592
|
+
},
|
|
593
|
+
defaultVariants: {
|
|
594
|
+
align: "inline-start"
|
|
595
|
+
}
|
|
596
|
+
}
|
|
597
|
+
);
|
|
598
|
+
function InputGroupAddon({
|
|
599
|
+
className,
|
|
600
|
+
align = "inline-start",
|
|
601
|
+
...props
|
|
602
|
+
}) {
|
|
603
|
+
return /* @__PURE__ */ jsx(
|
|
604
|
+
"div",
|
|
605
|
+
{
|
|
606
|
+
role: "group",
|
|
607
|
+
"data-slot": "input-group-addon",
|
|
608
|
+
"data-align": align,
|
|
609
|
+
className: cn(inputGroupAddonVariants({ align }), className),
|
|
610
|
+
onClick: (e) => {
|
|
611
|
+
if (e.target.closest("button")) {
|
|
612
|
+
return;
|
|
613
|
+
}
|
|
614
|
+
e.currentTarget.parentElement?.querySelector("input")?.focus();
|
|
615
|
+
},
|
|
616
|
+
...props
|
|
617
|
+
}
|
|
618
|
+
);
|
|
619
|
+
}
|
|
620
|
+
var inputGroupButtonVariants = cva(
|
|
621
|
+
"flex items-center gap-2 text-xs shadow-none",
|
|
622
|
+
{
|
|
623
|
+
variants: {
|
|
624
|
+
size: {
|
|
625
|
+
xs: "h-6 gap-1 rounded-none px-1.5 [&>svg:not([class*='size-'])]:size-3.5",
|
|
626
|
+
sm: "gap-1",
|
|
627
|
+
"icon-xs": "size-6 rounded-none p-0 has-[>svg]:p-0",
|
|
628
|
+
"icon-sm": "size-7 p-0 has-[>svg]:p-0"
|
|
629
|
+
}
|
|
630
|
+
},
|
|
631
|
+
defaultVariants: {
|
|
632
|
+
size: "xs"
|
|
633
|
+
}
|
|
634
|
+
}
|
|
635
|
+
);
|
|
636
|
+
function InputGroupButton({
|
|
637
|
+
className,
|
|
638
|
+
type = "button",
|
|
639
|
+
variant = "ghost",
|
|
640
|
+
size = "xs",
|
|
641
|
+
...props
|
|
642
|
+
}) {
|
|
643
|
+
return /* @__PURE__ */ jsx(
|
|
644
|
+
Button,
|
|
645
|
+
{
|
|
646
|
+
type,
|
|
647
|
+
"data-size": size,
|
|
648
|
+
variant,
|
|
649
|
+
className: cn(inputGroupButtonVariants({ size }), className),
|
|
650
|
+
...props
|
|
651
|
+
}
|
|
652
|
+
);
|
|
653
|
+
}
|
|
654
|
+
function InputGroupText({ className, ...props }) {
|
|
655
|
+
return /* @__PURE__ */ jsx(
|
|
656
|
+
"span",
|
|
657
|
+
{
|
|
658
|
+
className: cn(
|
|
659
|
+
"flex items-center gap-2 text-xs text-muted-foreground [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4",
|
|
660
|
+
className
|
|
661
|
+
),
|
|
662
|
+
...props
|
|
663
|
+
}
|
|
664
|
+
);
|
|
665
|
+
}
|
|
666
|
+
function InputGroupInput({
|
|
667
|
+
className,
|
|
668
|
+
...props
|
|
669
|
+
}) {
|
|
670
|
+
return /* @__PURE__ */ jsx(
|
|
671
|
+
Input,
|
|
672
|
+
{
|
|
673
|
+
"data-slot": "input-group-control",
|
|
674
|
+
className: cn(
|
|
675
|
+
"flex-1 rounded-none border-0 bg-transparent shadow-none ring-0 focus-visible:ring-0 disabled:bg-transparent aria-invalid:ring-0 dark:bg-transparent dark:disabled:bg-transparent",
|
|
676
|
+
className
|
|
677
|
+
),
|
|
678
|
+
...props
|
|
679
|
+
}
|
|
680
|
+
);
|
|
681
|
+
}
|
|
682
|
+
function InputGroupTextarea({
|
|
683
|
+
className,
|
|
684
|
+
...props
|
|
685
|
+
}) {
|
|
686
|
+
return /* @__PURE__ */ jsx(
|
|
687
|
+
Textarea,
|
|
688
|
+
{
|
|
689
|
+
"data-slot": "input-group-control",
|
|
690
|
+
className: cn(
|
|
691
|
+
"flex-1 resize-none rounded-none border-0 bg-transparent py-2 shadow-none ring-0 focus-visible:ring-0 disabled:bg-transparent aria-invalid:ring-0 dark:bg-transparent dark:disabled:bg-transparent",
|
|
692
|
+
className
|
|
693
|
+
),
|
|
694
|
+
...props
|
|
695
|
+
}
|
|
696
|
+
);
|
|
697
|
+
}
|
|
698
|
+
function Command({
|
|
699
|
+
className,
|
|
700
|
+
...props
|
|
701
|
+
}) {
|
|
702
|
+
return /* @__PURE__ */ jsx(
|
|
703
|
+
Command$1,
|
|
704
|
+
{
|
|
705
|
+
"data-slot": "command",
|
|
706
|
+
className: cn(
|
|
707
|
+
"flex size-full flex-col overflow-hidden rounded-none bg-popover text-popover-foreground",
|
|
708
|
+
className
|
|
709
|
+
),
|
|
710
|
+
...props
|
|
711
|
+
}
|
|
712
|
+
);
|
|
713
|
+
}
|
|
714
|
+
function CommandDialog({
|
|
715
|
+
title = "Command Palette",
|
|
716
|
+
description = "Search for a command to run...",
|
|
717
|
+
children,
|
|
718
|
+
className,
|
|
719
|
+
showCloseButton = false,
|
|
720
|
+
...props
|
|
721
|
+
}) {
|
|
722
|
+
return /* @__PURE__ */ jsxs(Dialog, { ...props, children: [
|
|
723
|
+
/* @__PURE__ */ jsxs(DialogHeader, { className: "sr-only", children: [
|
|
724
|
+
/* @__PURE__ */ jsx(DialogTitle, { children: title }),
|
|
725
|
+
/* @__PURE__ */ jsx(DialogDescription, { children: description })
|
|
726
|
+
] }),
|
|
727
|
+
/* @__PURE__ */ jsx(
|
|
728
|
+
DialogContent,
|
|
729
|
+
{
|
|
730
|
+
className: cn(
|
|
731
|
+
"top-1/3 translate-y-0 overflow-hidden rounded-none p-0",
|
|
732
|
+
className
|
|
733
|
+
),
|
|
734
|
+
showCloseButton,
|
|
735
|
+
children
|
|
736
|
+
}
|
|
737
|
+
)
|
|
738
|
+
] });
|
|
739
|
+
}
|
|
740
|
+
function CommandInput({
|
|
741
|
+
className,
|
|
742
|
+
...props
|
|
743
|
+
}) {
|
|
744
|
+
return /* @__PURE__ */ jsx("div", { "data-slot": "command-input-wrapper", className: "border-b pb-0", children: /* @__PURE__ */ jsxs(InputGroup, { className: "h-8 border-none border-input/30 bg-input/30 shadow-none! *:data-[slot=input-group-addon]:pl-2!", children: [
|
|
745
|
+
/* @__PURE__ */ jsx(
|
|
746
|
+
Command$1.Input,
|
|
747
|
+
{
|
|
748
|
+
"data-slot": "command-input",
|
|
749
|
+
className: cn(
|
|
750
|
+
"w-full text-xs outline-hidden disabled:cursor-not-allowed disabled:opacity-50",
|
|
751
|
+
className
|
|
752
|
+
),
|
|
753
|
+
...props
|
|
754
|
+
}
|
|
755
|
+
),
|
|
756
|
+
/* @__PURE__ */ jsx(InputGroupAddon, { children: /* @__PURE__ */ jsx(SearchIcon, { className: "size-4 shrink-0 opacity-50" }) })
|
|
757
|
+
] }) });
|
|
758
|
+
}
|
|
759
|
+
function CommandList({
|
|
760
|
+
className,
|
|
761
|
+
...props
|
|
762
|
+
}) {
|
|
763
|
+
return /* @__PURE__ */ jsx(
|
|
764
|
+
Command$1.List,
|
|
765
|
+
{
|
|
766
|
+
"data-slot": "command-list",
|
|
767
|
+
className: cn(
|
|
768
|
+
"no-scrollbar max-h-72 scroll-py-0 overflow-x-hidden overflow-y-auto outline-none",
|
|
769
|
+
className
|
|
770
|
+
),
|
|
771
|
+
...props
|
|
772
|
+
}
|
|
773
|
+
);
|
|
774
|
+
}
|
|
775
|
+
function CommandEmpty({
|
|
776
|
+
className,
|
|
777
|
+
...props
|
|
778
|
+
}) {
|
|
779
|
+
return /* @__PURE__ */ jsx(
|
|
780
|
+
Command$1.Empty,
|
|
781
|
+
{
|
|
782
|
+
"data-slot": "command-empty",
|
|
783
|
+
className: cn("py-6 text-center text-xs", className),
|
|
784
|
+
...props
|
|
785
|
+
}
|
|
786
|
+
);
|
|
787
|
+
}
|
|
788
|
+
function CommandGroup({
|
|
789
|
+
className,
|
|
790
|
+
...props
|
|
791
|
+
}) {
|
|
792
|
+
return /* @__PURE__ */ jsx(
|
|
793
|
+
Command$1.Group,
|
|
794
|
+
{
|
|
795
|
+
"data-slot": "command-group",
|
|
796
|
+
className: cn(
|
|
797
|
+
"overflow-hidden text-foreground **:[[cmdk-group-heading]]:px-2 **:[[cmdk-group-heading]]:py-1.5 **:[[cmdk-group-heading]]:text-xs **:[[cmdk-group-heading]]:text-muted-foreground",
|
|
798
|
+
className
|
|
799
|
+
),
|
|
800
|
+
...props
|
|
801
|
+
}
|
|
802
|
+
);
|
|
803
|
+
}
|
|
804
|
+
function CommandSeparator({
|
|
805
|
+
className,
|
|
806
|
+
...props
|
|
807
|
+
}) {
|
|
808
|
+
return /* @__PURE__ */ jsx(
|
|
809
|
+
Command$1.Separator,
|
|
810
|
+
{
|
|
811
|
+
"data-slot": "command-separator",
|
|
812
|
+
className: cn("-mx-1 h-px bg-border", className),
|
|
813
|
+
...props
|
|
814
|
+
}
|
|
815
|
+
);
|
|
816
|
+
}
|
|
817
|
+
function CommandItem({
|
|
818
|
+
className,
|
|
819
|
+
children,
|
|
820
|
+
...props
|
|
821
|
+
}) {
|
|
822
|
+
return /* @__PURE__ */ jsxs(
|
|
823
|
+
Command$1.Item,
|
|
824
|
+
{
|
|
825
|
+
"data-slot": "command-item",
|
|
826
|
+
className: cn(
|
|
827
|
+
"group/command-item relative flex cursor-default items-center gap-2 rounded-none px-2 py-2 text-xs outline-hidden select-none in-data-[slot=dialog-content]:rounded-none! data-[disabled=true]:pointer-events-none data-[disabled=true]:opacity-50 data-selected:bg-muted data-selected:text-foreground [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 data-selected:*:[svg]:text-foreground",
|
|
828
|
+
className
|
|
829
|
+
),
|
|
830
|
+
...props,
|
|
831
|
+
children: [
|
|
832
|
+
children,
|
|
833
|
+
/* @__PURE__ */ jsx(CheckIcon, { className: "ml-auto opacity-0 group-has-data-[slot=command-shortcut]/command-item:hidden group-data-[checked=true]/command-item:opacity-100" })
|
|
834
|
+
]
|
|
835
|
+
}
|
|
836
|
+
);
|
|
837
|
+
}
|
|
838
|
+
function CommandShortcut({
|
|
839
|
+
className,
|
|
840
|
+
...props
|
|
841
|
+
}) {
|
|
842
|
+
return /* @__PURE__ */ jsx(
|
|
843
|
+
"span",
|
|
844
|
+
{
|
|
845
|
+
"data-slot": "command-shortcut",
|
|
846
|
+
className: cn(
|
|
847
|
+
"ml-auto text-xs tracking-widest text-muted-foreground group-data-selected/command-item:text-foreground",
|
|
848
|
+
className
|
|
849
|
+
),
|
|
850
|
+
...props
|
|
851
|
+
}
|
|
852
|
+
);
|
|
853
|
+
}
|
|
854
|
+
function ContextMenu({ ...props }) {
|
|
855
|
+
return /* @__PURE__ */ jsx(ContextMenu$1.Root, { "data-slot": "context-menu", ...props });
|
|
856
|
+
}
|
|
857
|
+
function ContextMenuTrigger({ className, ...props }) {
|
|
858
|
+
return /* @__PURE__ */ jsx(ContextMenu$1.Trigger, { "data-slot": "context-menu-trigger", className: cn("select-none", className), ...props });
|
|
859
|
+
}
|
|
860
|
+
function ContextMenuGroup({ ...props }) {
|
|
861
|
+
return /* @__PURE__ */ jsx(ContextMenu$1.Group, { "data-slot": "context-menu-group", ...props });
|
|
862
|
+
}
|
|
863
|
+
function ContextMenuPortal({ ...props }) {
|
|
864
|
+
return /* @__PURE__ */ jsx(ContextMenu$1.Portal, { "data-slot": "context-menu-portal", ...props });
|
|
865
|
+
}
|
|
866
|
+
function ContextMenuSub({ ...props }) {
|
|
867
|
+
return /* @__PURE__ */ jsx(ContextMenu$1.Sub, { "data-slot": "context-menu-sub", ...props });
|
|
868
|
+
}
|
|
869
|
+
function ContextMenuRadioGroup({ ...props }) {
|
|
870
|
+
return /* @__PURE__ */ jsx(ContextMenu$1.RadioGroup, { "data-slot": "context-menu-radio-group", ...props });
|
|
871
|
+
}
|
|
872
|
+
function ContextMenuContent({
|
|
873
|
+
className,
|
|
874
|
+
...props
|
|
875
|
+
}) {
|
|
876
|
+
return /* @__PURE__ */ jsx(ContextMenu$1.Portal, { children: /* @__PURE__ */ jsx(
|
|
877
|
+
ContextMenu$1.Content,
|
|
878
|
+
{
|
|
879
|
+
"data-slot": "context-menu-content",
|
|
880
|
+
className: cn(
|
|
881
|
+
"z-50 max-h-(--radix-context-menu-content-available-height) min-w-36 origin-(--radix-context-menu-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-none bg-popover text-popover-foreground shadow-md ring-1 ring-foreground/10 duration-100 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-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",
|
|
882
|
+
className
|
|
883
|
+
),
|
|
884
|
+
...props
|
|
885
|
+
}
|
|
886
|
+
) });
|
|
887
|
+
}
|
|
888
|
+
function ContextMenuItem({
|
|
889
|
+
className,
|
|
890
|
+
inset,
|
|
891
|
+
variant = "default",
|
|
892
|
+
...props
|
|
893
|
+
}) {
|
|
894
|
+
return /* @__PURE__ */ jsx(
|
|
895
|
+
ContextMenu$1.Item,
|
|
896
|
+
{
|
|
897
|
+
"data-slot": "context-menu-item",
|
|
898
|
+
"data-inset": inset,
|
|
899
|
+
"data-variant": variant,
|
|
900
|
+
className: cn(
|
|
901
|
+
"group/context-menu-item relative flex cursor-default items-center gap-2 rounded-none px-2 py-2 text-xs outline-hidden select-none focus:bg-accent focus:text-accent-foreground data-inset:pl-7 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 data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 focus:*:[svg]:text-accent-foreground data-[variant=destructive]:*:[svg]:text-destructive",
|
|
902
|
+
className
|
|
903
|
+
),
|
|
904
|
+
...props
|
|
905
|
+
}
|
|
906
|
+
);
|
|
907
|
+
}
|
|
908
|
+
function ContextMenuSubTrigger({
|
|
909
|
+
className,
|
|
910
|
+
inset,
|
|
911
|
+
children,
|
|
912
|
+
...props
|
|
913
|
+
}) {
|
|
914
|
+
return /* @__PURE__ */ jsxs(
|
|
915
|
+
ContextMenu$1.SubTrigger,
|
|
916
|
+
{
|
|
917
|
+
"data-slot": "context-menu-sub-trigger",
|
|
918
|
+
"data-inset": inset,
|
|
919
|
+
className: cn(
|
|
920
|
+
"flex cursor-default items-center gap-2 rounded-none px-2 py-2 text-xs outline-hidden select-none focus:bg-accent focus:text-accent-foreground data-inset:pl-7 data-open:bg-accent data-open:text-accent-foreground [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
|
|
921
|
+
className
|
|
922
|
+
),
|
|
923
|
+
...props,
|
|
924
|
+
children: [
|
|
925
|
+
children,
|
|
926
|
+
/* @__PURE__ */ jsx(ChevronRightIcon, { className: "ml-auto" })
|
|
927
|
+
]
|
|
928
|
+
}
|
|
929
|
+
);
|
|
930
|
+
}
|
|
931
|
+
function ContextMenuSubContent({ className, ...props }) {
|
|
932
|
+
return /* @__PURE__ */ jsx(
|
|
933
|
+
ContextMenu$1.SubContent,
|
|
934
|
+
{
|
|
935
|
+
"data-slot": "context-menu-sub-content",
|
|
936
|
+
className: cn(
|
|
937
|
+
"z-50 min-w-32 origin-(--radix-context-menu-content-transform-origin) overflow-hidden rounded-none border bg-popover text-popover-foreground shadow-lg duration-100 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-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",
|
|
938
|
+
className
|
|
939
|
+
),
|
|
940
|
+
...props
|
|
941
|
+
}
|
|
942
|
+
);
|
|
943
|
+
}
|
|
944
|
+
function ContextMenuCheckboxItem({
|
|
945
|
+
className,
|
|
946
|
+
children,
|
|
947
|
+
checked,
|
|
948
|
+
inset,
|
|
949
|
+
...props
|
|
950
|
+
}) {
|
|
951
|
+
return /* @__PURE__ */ jsxs(
|
|
952
|
+
ContextMenu$1.CheckboxItem,
|
|
953
|
+
{
|
|
954
|
+
"data-slot": "context-menu-checkbox-item",
|
|
955
|
+
"data-inset": inset,
|
|
956
|
+
className: cn(
|
|
957
|
+
"relative flex cursor-default items-center gap-2 rounded-none py-2 pr-8 pl-2 text-xs outline-hidden select-none focus:bg-accent focus:text-accent-foreground data-inset:pl-7 data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
|
|
958
|
+
className
|
|
959
|
+
),
|
|
960
|
+
checked,
|
|
961
|
+
...props,
|
|
962
|
+
children: [
|
|
963
|
+
/* @__PURE__ */ jsx("span", { className: "pointer-events-none absolute right-2", children: /* @__PURE__ */ jsx(ContextMenu$1.ItemIndicator, { children: /* @__PURE__ */ jsx(CheckIcon, {}) }) }),
|
|
964
|
+
children
|
|
965
|
+
]
|
|
966
|
+
}
|
|
967
|
+
);
|
|
968
|
+
}
|
|
969
|
+
function ContextMenuRadioItem({
|
|
970
|
+
className,
|
|
971
|
+
children,
|
|
972
|
+
inset,
|
|
973
|
+
...props
|
|
974
|
+
}) {
|
|
975
|
+
return /* @__PURE__ */ jsxs(
|
|
976
|
+
ContextMenu$1.RadioItem,
|
|
977
|
+
{
|
|
978
|
+
"data-slot": "context-menu-radio-item",
|
|
979
|
+
"data-inset": inset,
|
|
980
|
+
className: cn(
|
|
981
|
+
"relative flex cursor-default items-center gap-2 rounded-none py-2 pr-8 pl-2 text-xs outline-hidden select-none focus:bg-accent focus:text-accent-foreground data-inset:pl-7 data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
|
|
982
|
+
className
|
|
983
|
+
),
|
|
984
|
+
...props,
|
|
985
|
+
children: [
|
|
986
|
+
/* @__PURE__ */ jsx("span", { className: "pointer-events-none absolute right-2", children: /* @__PURE__ */ jsx(ContextMenu$1.ItemIndicator, { children: /* @__PURE__ */ jsx(CheckIcon, {}) }) }),
|
|
987
|
+
children
|
|
988
|
+
]
|
|
989
|
+
}
|
|
990
|
+
);
|
|
991
|
+
}
|
|
992
|
+
function ContextMenuLabel({
|
|
993
|
+
className,
|
|
994
|
+
inset,
|
|
995
|
+
...props
|
|
996
|
+
}) {
|
|
997
|
+
return /* @__PURE__ */ jsx(
|
|
998
|
+
ContextMenu$1.Label,
|
|
999
|
+
{
|
|
1000
|
+
"data-slot": "context-menu-label",
|
|
1001
|
+
"data-inset": inset,
|
|
1002
|
+
className: cn("px-2 py-2 text-xs text-muted-foreground data-inset:pl-7", className),
|
|
1003
|
+
...props
|
|
1004
|
+
}
|
|
1005
|
+
);
|
|
1006
|
+
}
|
|
1007
|
+
function ContextMenuSeparator({ className, ...props }) {
|
|
1008
|
+
return /* @__PURE__ */ jsx(ContextMenu$1.Separator, { "data-slot": "context-menu-separator", className: cn("-mx-1 h-px bg-border", className), ...props });
|
|
1009
|
+
}
|
|
1010
|
+
function ContextMenuShortcut({ className, ...props }) {
|
|
1011
|
+
return /* @__PURE__ */ jsx(
|
|
1012
|
+
"span",
|
|
1013
|
+
{
|
|
1014
|
+
"data-slot": "context-menu-shortcut",
|
|
1015
|
+
className: cn("ml-auto text-xs tracking-widest text-muted-foreground group-focus/context-menu-item:text-accent-foreground", className),
|
|
1016
|
+
...props
|
|
1017
|
+
}
|
|
1018
|
+
);
|
|
1019
|
+
}
|
|
1020
|
+
function Drawer({
|
|
1021
|
+
...props
|
|
1022
|
+
}) {
|
|
1023
|
+
return /* @__PURE__ */ jsx(Drawer$1.Root, { "data-slot": "drawer", ...props });
|
|
1024
|
+
}
|
|
1025
|
+
function DrawerTrigger({
|
|
1026
|
+
...props
|
|
1027
|
+
}) {
|
|
1028
|
+
return /* @__PURE__ */ jsx(Drawer$1.Trigger, { "data-slot": "drawer-trigger", ...props });
|
|
1029
|
+
}
|
|
1030
|
+
function DrawerPortal({
|
|
1031
|
+
...props
|
|
1032
|
+
}) {
|
|
1033
|
+
return /* @__PURE__ */ jsx(Drawer$1.Portal, { "data-slot": "drawer-portal", ...props });
|
|
1034
|
+
}
|
|
1035
|
+
function DrawerClose({
|
|
1036
|
+
...props
|
|
1037
|
+
}) {
|
|
1038
|
+
return /* @__PURE__ */ jsx(Drawer$1.Close, { "data-slot": "drawer-close", ...props });
|
|
1039
|
+
}
|
|
1040
|
+
function DrawerOverlay({
|
|
1041
|
+
className,
|
|
1042
|
+
...props
|
|
1043
|
+
}) {
|
|
1044
|
+
return /* @__PURE__ */ jsx(
|
|
1045
|
+
Drawer$1.Overlay,
|
|
1046
|
+
{
|
|
1047
|
+
"data-slot": "drawer-overlay",
|
|
1048
|
+
className: cn(
|
|
1049
|
+
"fixed inset-0 z-50 bg-black/10 supports-backdrop-filter:backdrop-blur-xs data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0",
|
|
1050
|
+
className
|
|
1051
|
+
),
|
|
1052
|
+
...props
|
|
1053
|
+
}
|
|
1054
|
+
);
|
|
1055
|
+
}
|
|
1056
|
+
function DrawerContent({
|
|
1057
|
+
className,
|
|
1058
|
+
children,
|
|
1059
|
+
...props
|
|
1060
|
+
}) {
|
|
1061
|
+
return /* @__PURE__ */ jsxs(DrawerPortal, { "data-slot": "drawer-portal", children: [
|
|
1062
|
+
/* @__PURE__ */ jsx(DrawerOverlay, {}),
|
|
1063
|
+
/* @__PURE__ */ jsxs(
|
|
1064
|
+
Drawer$1.Content,
|
|
1065
|
+
{
|
|
1066
|
+
"data-slot": "drawer-content",
|
|
1067
|
+
className: cn(
|
|
1068
|
+
"group/drawer-content fixed z-50 flex h-auto flex-col bg-popover text-xs/relaxed text-popover-foreground data-[vaul-drawer-direction=bottom]:inset-x-0 data-[vaul-drawer-direction=bottom]:bottom-0 data-[vaul-drawer-direction=bottom]:mt-24 data-[vaul-drawer-direction=bottom]:max-h-[80vh] data-[vaul-drawer-direction=bottom]:rounded-none data-[vaul-drawer-direction=bottom]:border-t data-[vaul-drawer-direction=left]:inset-y-0 data-[vaul-drawer-direction=left]:left-0 data-[vaul-drawer-direction=left]:w-3/4 data-[vaul-drawer-direction=left]:rounded-none data-[vaul-drawer-direction=left]:border-r data-[vaul-drawer-direction=right]:inset-y-0 data-[vaul-drawer-direction=right]:right-0 data-[vaul-drawer-direction=right]:w-3/4 data-[vaul-drawer-direction=right]:rounded-none data-[vaul-drawer-direction=right]:border-l data-[vaul-drawer-direction=top]:inset-x-0 data-[vaul-drawer-direction=top]:top-0 data-[vaul-drawer-direction=top]:mb-24 data-[vaul-drawer-direction=top]:max-h-[80vh] data-[vaul-drawer-direction=top]:rounded-none data-[vaul-drawer-direction=top]:border-b data-[vaul-drawer-direction=left]:sm:max-w-sm data-[vaul-drawer-direction=right]:sm:max-w-sm",
|
|
1069
|
+
className
|
|
1070
|
+
),
|
|
1071
|
+
...props,
|
|
1072
|
+
children: [
|
|
1073
|
+
/* @__PURE__ */ jsx("div", { className: "mx-auto mt-4 hidden h-1 w-[100px] shrink-0 rounded-none bg-muted group-data-[vaul-drawer-direction=bottom]/drawer-content:block" }),
|
|
1074
|
+
children
|
|
1075
|
+
]
|
|
1076
|
+
}
|
|
1077
|
+
)
|
|
1078
|
+
] });
|
|
1079
|
+
}
|
|
1080
|
+
function DrawerHeader({ className, ...props }) {
|
|
1081
|
+
return /* @__PURE__ */ jsx(
|
|
1082
|
+
"div",
|
|
1083
|
+
{
|
|
1084
|
+
"data-slot": "drawer-header",
|
|
1085
|
+
className: cn(
|
|
1086
|
+
"flex flex-col gap-0.5 p-4 group-data-[vaul-drawer-direction=bottom]/drawer-content:text-center group-data-[vaul-drawer-direction=top]/drawer-content:text-center md:gap-0.5 md:text-left",
|
|
1087
|
+
className
|
|
1088
|
+
),
|
|
1089
|
+
...props
|
|
1090
|
+
}
|
|
1091
|
+
);
|
|
1092
|
+
}
|
|
1093
|
+
function DrawerFooter({ className, ...props }) {
|
|
1094
|
+
return /* @__PURE__ */ jsx(
|
|
1095
|
+
"div",
|
|
1096
|
+
{
|
|
1097
|
+
"data-slot": "drawer-footer",
|
|
1098
|
+
className: cn("mt-auto flex flex-col gap-2 p-4", className),
|
|
1099
|
+
...props
|
|
1100
|
+
}
|
|
1101
|
+
);
|
|
1102
|
+
}
|
|
1103
|
+
function DrawerTitle({
|
|
1104
|
+
className,
|
|
1105
|
+
...props
|
|
1106
|
+
}) {
|
|
1107
|
+
return /* @__PURE__ */ jsx(
|
|
1108
|
+
Drawer$1.Title,
|
|
1109
|
+
{
|
|
1110
|
+
"data-slot": "drawer-title",
|
|
1111
|
+
className: cn(
|
|
1112
|
+
"font-heading text-sm font-medium text-foreground",
|
|
1113
|
+
className
|
|
1114
|
+
),
|
|
1115
|
+
...props
|
|
1116
|
+
}
|
|
1117
|
+
);
|
|
1118
|
+
}
|
|
1119
|
+
function DrawerDescription({
|
|
1120
|
+
className,
|
|
1121
|
+
...props
|
|
1122
|
+
}) {
|
|
1123
|
+
return /* @__PURE__ */ jsx(
|
|
1124
|
+
Drawer$1.Description,
|
|
1125
|
+
{
|
|
1126
|
+
"data-slot": "drawer-description",
|
|
1127
|
+
className: cn("text-xs/relaxed text-muted-foreground", className),
|
|
1128
|
+
...props
|
|
1129
|
+
}
|
|
1130
|
+
);
|
|
1131
|
+
}
|
|
1132
|
+
function FieldSet({ className, ...props }) {
|
|
1133
|
+
return /* @__PURE__ */ jsx(
|
|
1134
|
+
"fieldset",
|
|
1135
|
+
{
|
|
1136
|
+
"data-slot": "field-set",
|
|
1137
|
+
className: cn("flex flex-col gap-4 has-[>[data-slot=checkbox-group]]:gap-3 has-[>[data-slot=radio-group]]:gap-3", className),
|
|
1138
|
+
...props
|
|
1139
|
+
}
|
|
1140
|
+
);
|
|
1141
|
+
}
|
|
1142
|
+
function FieldLegend({ className, variant = "legend", ...props }) {
|
|
1143
|
+
return /* @__PURE__ */ jsx(
|
|
1144
|
+
"legend",
|
|
1145
|
+
{
|
|
1146
|
+
"data-slot": "field-legend",
|
|
1147
|
+
"data-variant": variant,
|
|
1148
|
+
className: cn("mb-2.5 font-medium data-[variant=label]:text-xs data-[variant=legend]:text-sm", className),
|
|
1149
|
+
...props
|
|
1150
|
+
}
|
|
1151
|
+
);
|
|
1152
|
+
}
|
|
1153
|
+
function FieldGroup({ className, ...props }) {
|
|
1154
|
+
return /* @__PURE__ */ jsx(
|
|
1155
|
+
"div",
|
|
1156
|
+
{
|
|
1157
|
+
"data-slot": "field-group",
|
|
1158
|
+
className: cn(
|
|
1159
|
+
"group/field-group @container/field-group flex w-full flex-col gap-5 data-[slot=checkbox-group]:gap-3 *:data-[slot=field-group]:gap-4",
|
|
1160
|
+
className
|
|
1161
|
+
),
|
|
1162
|
+
...props
|
|
1163
|
+
}
|
|
1164
|
+
);
|
|
1165
|
+
}
|
|
1166
|
+
var fieldVariants = cva("group/field flex w-full gap-2 data-[invalid=true]:text-destructive", {
|
|
1167
|
+
variants: {
|
|
1168
|
+
orientation: {
|
|
1169
|
+
vertical: "flex-col *:w-full [&>.sr-only]:w-auto",
|
|
1170
|
+
horizontal: "flex-row items-center has-[>[data-slot=field-content]]:items-start *:data-[slot=field-label]:flex-auto has-[>[data-slot=field-content]]:[&>[role=checkbox],[role=radio]]:mt-px",
|
|
1171
|
+
responsive: "flex-col *:w-full @md/field-group:flex-row @md/field-group:items-center @md/field-group:*:w-auto @md/field-group:has-[>[data-slot=field-content]]:items-start @md/field-group:*:data-[slot=field-label]:flex-auto [&>.sr-only]:w-auto @md/field-group:has-[>[data-slot=field-content]]:[&>[role=checkbox],[role=radio]]:mt-px"
|
|
1172
|
+
}
|
|
1173
|
+
},
|
|
1174
|
+
defaultVariants: {
|
|
1175
|
+
orientation: "vertical"
|
|
1176
|
+
}
|
|
1177
|
+
});
|
|
1178
|
+
function Field({ className, orientation = "vertical", ...props }) {
|
|
1179
|
+
return /* @__PURE__ */ jsx("div", { role: "group", "data-slot": "field", "data-orientation": orientation, className: cn(fieldVariants({ orientation }), className), ...props });
|
|
1180
|
+
}
|
|
1181
|
+
function FieldContent({ className, ...props }) {
|
|
1182
|
+
return /* @__PURE__ */ jsx("div", { "data-slot": "field-content", className: cn("group/field-content flex flex-1 flex-col gap-0.5 leading-snug", className), ...props });
|
|
1183
|
+
}
|
|
1184
|
+
function FieldLabel({ className, ...props }) {
|
|
1185
|
+
return /* @__PURE__ */ jsx(
|
|
1186
|
+
Label,
|
|
1187
|
+
{
|
|
1188
|
+
"data-slot": "field-label",
|
|
1189
|
+
className: cn(
|
|
1190
|
+
"group/field-label peer/field-label flex w-fit gap-2 leading-snug group-data-[disabled=true]/field:opacity-50 has-data-checked:border-primary/30 has-data-checked:bg-primary/5 has-[>[data-slot=field]]:rounded-none has-[>[data-slot=field]]:border *:data-[slot=field]:p-2 dark:has-data-checked:border-primary/20 dark:has-data-checked:bg-primary/10",
|
|
1191
|
+
"has-[>[data-slot=field]]:w-full has-[>[data-slot=field]]:flex-col",
|
|
1192
|
+
className
|
|
1193
|
+
),
|
|
1194
|
+
...props
|
|
1195
|
+
}
|
|
1196
|
+
);
|
|
1197
|
+
}
|
|
1198
|
+
function FieldTitle({ className, ...props }) {
|
|
1199
|
+
return /* @__PURE__ */ jsx(
|
|
1200
|
+
"div",
|
|
1201
|
+
{
|
|
1202
|
+
"data-slot": "field-label",
|
|
1203
|
+
className: cn("flex w-fit items-center gap-2 text-xs/relaxed group-data-[disabled=true]/field:opacity-50", className),
|
|
1204
|
+
...props
|
|
1205
|
+
}
|
|
1206
|
+
);
|
|
1207
|
+
}
|
|
1208
|
+
function FieldDescription({ className, ...props }) {
|
|
1209
|
+
return /* @__PURE__ */ jsx(
|
|
1210
|
+
"p",
|
|
1211
|
+
{
|
|
1212
|
+
"data-slot": "field-description",
|
|
1213
|
+
className: cn(
|
|
1214
|
+
"text-left text-xs/relaxed leading-normal font-normal text-muted-foreground group-has-data-horizontal/field:text-balance [[data-variant=legend]+&]:-mt-1.5",
|
|
1215
|
+
"last:mt-0 nth-last-2:-mt-1",
|
|
1216
|
+
"[&>a]:underline [&>a]:underline-offset-4 [&>a:hover]:text-primary",
|
|
1217
|
+
className
|
|
1218
|
+
),
|
|
1219
|
+
...props
|
|
1220
|
+
}
|
|
1221
|
+
);
|
|
1222
|
+
}
|
|
1223
|
+
function FieldSeparator({
|
|
1224
|
+
children,
|
|
1225
|
+
className,
|
|
1226
|
+
...props
|
|
1227
|
+
}) {
|
|
1228
|
+
return /* @__PURE__ */ jsxs(
|
|
1229
|
+
"div",
|
|
1230
|
+
{
|
|
1231
|
+
"data-slot": "field-separator",
|
|
1232
|
+
"data-content": !!children,
|
|
1233
|
+
className: cn("relative -my-2 h-5 text-xs group-data-[variant=outline]/field-group:-mb-2", className),
|
|
1234
|
+
...props,
|
|
1235
|
+
children: [
|
|
1236
|
+
/* @__PURE__ */ jsx(Separator, { className: "absolute inset-0 top-1/2" }),
|
|
1237
|
+
children && /* @__PURE__ */ jsx("span", { className: "relative mx-auto block w-fit bg-background px-2 text-muted-foreground", "data-slot": "field-separator-content", children })
|
|
1238
|
+
]
|
|
1239
|
+
}
|
|
1240
|
+
);
|
|
1241
|
+
}
|
|
1242
|
+
function FieldError({
|
|
1243
|
+
className,
|
|
1244
|
+
children,
|
|
1245
|
+
errors,
|
|
1246
|
+
...props
|
|
1247
|
+
}) {
|
|
1248
|
+
const content = useMemo(() => {
|
|
1249
|
+
if (children) {
|
|
1250
|
+
return children;
|
|
1251
|
+
}
|
|
1252
|
+
if (!errors?.length) {
|
|
1253
|
+
return null;
|
|
1254
|
+
}
|
|
1255
|
+
const uniqueErrors = [...new Map(errors.map((error) => [error?.message, error])).values()];
|
|
1256
|
+
if (uniqueErrors?.length == 1) {
|
|
1257
|
+
return uniqueErrors[0]?.message;
|
|
1258
|
+
}
|
|
1259
|
+
return /* @__PURE__ */ jsx("ul", { className: "ml-4 flex list-disc flex-col gap-1", children: uniqueErrors.map((error, index) => error?.message && /* @__PURE__ */ jsx("li", { children: error.message }, index)) });
|
|
1260
|
+
}, [children, errors]);
|
|
1261
|
+
if (!content) {
|
|
1262
|
+
return null;
|
|
1263
|
+
}
|
|
1264
|
+
return /* @__PURE__ */ jsx("div", { role: "alert", "data-slot": "field-error", className: cn("text-xs font-normal text-destructive", className), ...props, children: content });
|
|
1265
|
+
}
|
|
1266
|
+
function HoverCard({ ...props }) {
|
|
1267
|
+
return /* @__PURE__ */ jsx(HoverCard$1.Root, { "data-slot": "hover-card", ...props });
|
|
1268
|
+
}
|
|
1269
|
+
function HoverCardTrigger({ ...props }) {
|
|
1270
|
+
return /* @__PURE__ */ jsx(HoverCard$1.Trigger, { "data-slot": "hover-card-trigger", ...props });
|
|
1271
|
+
}
|
|
1272
|
+
function HoverCardContent({ className, align = "center", sideOffset = 4, ...props }) {
|
|
1273
|
+
return /* @__PURE__ */ jsx(HoverCard$1.Portal, { "data-slot": "hover-card-portal", children: /* @__PURE__ */ jsx(
|
|
1274
|
+
HoverCard$1.Content,
|
|
1275
|
+
{
|
|
1276
|
+
"data-slot": "hover-card-content",
|
|
1277
|
+
align,
|
|
1278
|
+
sideOffset,
|
|
1279
|
+
className: cn(
|
|
1280
|
+
"z-50 w-64 origin-(--radix-hover-card-content-transform-origin) rounded-none bg-popover p-2.5 text-xs/relaxed text-popover-foreground shadow-md ring-1 ring-foreground/10 outline-hidden duration-100 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-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",
|
|
1281
|
+
className
|
|
1282
|
+
),
|
|
1283
|
+
...props
|
|
1284
|
+
}
|
|
1285
|
+
) });
|
|
1286
|
+
}
|
|
1287
|
+
function InputOTP({
|
|
1288
|
+
className,
|
|
1289
|
+
containerClassName,
|
|
1290
|
+
...props
|
|
1291
|
+
}) {
|
|
1292
|
+
return /* @__PURE__ */ jsx(
|
|
1293
|
+
OTPInput,
|
|
1294
|
+
{
|
|
1295
|
+
"data-slot": "input-otp",
|
|
1296
|
+
containerClassName: cn("cn-input-otp flex items-center has-disabled:opacity-50", containerClassName),
|
|
1297
|
+
spellCheck: false,
|
|
1298
|
+
className: cn("disabled:cursor-not-allowed", className),
|
|
1299
|
+
...props
|
|
1300
|
+
}
|
|
1301
|
+
);
|
|
1302
|
+
}
|
|
1303
|
+
function InputOTPGroup({ className, ...props }) {
|
|
1304
|
+
return /* @__PURE__ */ jsx(
|
|
1305
|
+
"div",
|
|
1306
|
+
{
|
|
1307
|
+
"data-slot": "input-otp-group",
|
|
1308
|
+
className: cn(
|
|
1309
|
+
"flex items-center rounded-none has-aria-invalid:border-destructive has-aria-invalid:ring-1 has-aria-invalid:ring-destructive/20 dark:has-aria-invalid:ring-destructive/40",
|
|
1310
|
+
className
|
|
1311
|
+
),
|
|
1312
|
+
...props
|
|
1313
|
+
}
|
|
1314
|
+
);
|
|
1315
|
+
}
|
|
1316
|
+
function InputOTPSlot({
|
|
1317
|
+
index,
|
|
1318
|
+
className,
|
|
1319
|
+
...props
|
|
1320
|
+
}) {
|
|
1321
|
+
const inputOTPContext = React26.useContext(OTPInputContext);
|
|
1322
|
+
const { char, hasFakeCaret, isActive } = inputOTPContext?.slots[index] ?? {};
|
|
1323
|
+
return /* @__PURE__ */ jsxs(
|
|
1324
|
+
"div",
|
|
1325
|
+
{
|
|
1326
|
+
"data-slot": "input-otp-slot",
|
|
1327
|
+
"data-active": isActive,
|
|
1328
|
+
className: cn(
|
|
1329
|
+
"relative flex size-8 items-center justify-center border-y border-r border-input text-xs transition-all outline-none first:rounded-none first:border-l last:rounded-none aria-invalid:border-destructive data-[active=true]:z-10 data-[active=true]:border-ring data-[active=true]:ring-1 data-[active=true]:ring-ring/50 data-[active=true]:aria-invalid:border-destructive data-[active=true]:aria-invalid:ring-destructive/20 dark:bg-input/30 dark:data-[active=true]:aria-invalid:ring-destructive/40",
|
|
1330
|
+
className
|
|
1331
|
+
),
|
|
1332
|
+
...props,
|
|
1333
|
+
children: [
|
|
1334
|
+
char,
|
|
1335
|
+
hasFakeCaret && /* @__PURE__ */ jsx("div", { className: "pointer-events-none absolute inset-0 flex items-center justify-center", children: /* @__PURE__ */ jsx("div", { className: "h-4 w-px animate-caret-blink bg-foreground duration-1000" }) })
|
|
1336
|
+
]
|
|
1337
|
+
}
|
|
1338
|
+
);
|
|
1339
|
+
}
|
|
1340
|
+
function InputOTPSeparator({ ...props }) {
|
|
1341
|
+
return /* @__PURE__ */ jsx("div", { "data-slot": "input-otp-separator", className: "flex items-center [&_svg:not([class*='size-'])]:size-4", role: "separator", ...props, children: /* @__PURE__ */ jsx(MinusIcon, {}) });
|
|
1342
|
+
}
|
|
1343
|
+
function Menubar({ className, ...props }) {
|
|
1344
|
+
return /* @__PURE__ */ jsx(Menubar$1.Root, { "data-slot": "menubar", className: cn("flex h-8 items-center gap-0.5 rounded-none border p-1", className), ...props });
|
|
1345
|
+
}
|
|
1346
|
+
function MenubarMenu({ ...props }) {
|
|
1347
|
+
return /* @__PURE__ */ jsx(Menubar$1.Menu, { "data-slot": "menubar-menu", ...props });
|
|
1348
|
+
}
|
|
1349
|
+
function MenubarGroup({ ...props }) {
|
|
1350
|
+
return /* @__PURE__ */ jsx(Menubar$1.Group, { "data-slot": "menubar-group", ...props });
|
|
1351
|
+
}
|
|
1352
|
+
function MenubarPortal({ ...props }) {
|
|
1353
|
+
return /* @__PURE__ */ jsx(Menubar$1.Portal, { "data-slot": "menubar-portal", ...props });
|
|
1354
|
+
}
|
|
1355
|
+
function MenubarRadioGroup({ ...props }) {
|
|
1356
|
+
return /* @__PURE__ */ jsx(Menubar$1.RadioGroup, { "data-slot": "menubar-radio-group", ...props });
|
|
1357
|
+
}
|
|
1358
|
+
function MenubarTrigger({ className, ...props }) {
|
|
1359
|
+
return /* @__PURE__ */ jsx(
|
|
1360
|
+
Menubar$1.Trigger,
|
|
1361
|
+
{
|
|
1362
|
+
"data-slot": "menubar-trigger",
|
|
1363
|
+
className: cn(
|
|
1364
|
+
"flex items-center rounded-none px-1.5 py-[calc(--spacing(0.8))] text-xs font-medium outline-hidden select-none hover:bg-muted aria-expanded:bg-muted",
|
|
1365
|
+
className
|
|
1366
|
+
),
|
|
1367
|
+
...props
|
|
1368
|
+
}
|
|
1369
|
+
);
|
|
1370
|
+
}
|
|
1371
|
+
function MenubarContent({ className, align = "start", alignOffset = -4, sideOffset = 8, ...props }) {
|
|
1372
|
+
return /* @__PURE__ */ jsx(MenubarPortal, { children: /* @__PURE__ */ jsx(
|
|
1373
|
+
Menubar$1.Content,
|
|
1374
|
+
{
|
|
1375
|
+
"data-slot": "menubar-content",
|
|
1376
|
+
align,
|
|
1377
|
+
alignOffset,
|
|
1378
|
+
sideOffset,
|
|
1379
|
+
className: cn(
|
|
1380
|
+
"z-50 min-w-36 origin-(--radix-menubar-content-transform-origin) overflow-hidden rounded-none bg-popover text-popover-foreground shadow-md ring-1 ring-foreground/10 duration-100 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-open:animate-in data-open:fade-in-0 data-open:zoom-in-95",
|
|
1381
|
+
className
|
|
1382
|
+
),
|
|
1383
|
+
...props
|
|
1384
|
+
}
|
|
1385
|
+
) });
|
|
1386
|
+
}
|
|
1387
|
+
function MenubarItem({
|
|
1388
|
+
className,
|
|
1389
|
+
inset,
|
|
1390
|
+
variant = "default",
|
|
1391
|
+
...props
|
|
1392
|
+
}) {
|
|
1393
|
+
return /* @__PURE__ */ jsx(
|
|
1394
|
+
Menubar$1.Item,
|
|
1395
|
+
{
|
|
1396
|
+
"data-slot": "menubar-item",
|
|
1397
|
+
"data-inset": inset,
|
|
1398
|
+
"data-variant": variant,
|
|
1399
|
+
className: cn(
|
|
1400
|
+
"group/menubar-item relative flex cursor-default items-center gap-2 rounded-none px-2 py-2 text-xs outline-hidden select-none focus:bg-accent focus:text-accent-foreground not-data-[variant=destructive]:focus:**:text-accent-foreground 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 data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 data-[variant=destructive]:*:[svg]:text-destructive!",
|
|
1401
|
+
className
|
|
1402
|
+
),
|
|
1403
|
+
...props
|
|
1404
|
+
}
|
|
1405
|
+
);
|
|
1406
|
+
}
|
|
1407
|
+
function MenubarCheckboxItem({
|
|
1408
|
+
className,
|
|
1409
|
+
children,
|
|
1410
|
+
checked,
|
|
1411
|
+
inset,
|
|
1412
|
+
...props
|
|
1413
|
+
}) {
|
|
1414
|
+
return /* @__PURE__ */ jsxs(
|
|
1415
|
+
Menubar$1.CheckboxItem,
|
|
1416
|
+
{
|
|
1417
|
+
"data-slot": "menubar-checkbox-item",
|
|
1418
|
+
"data-inset": inset,
|
|
1419
|
+
className: cn(
|
|
1420
|
+
"relative flex cursor-default items-center gap-2 rounded-none py-2 pr-28 pl-8 text-xs outline-hidden select-none focus:bg-accent focus:text-accent-foreground focus:**:text-accent-foreground data-inset:pl-8 data-disabled:pointer-events-none [&_svg]:pointer-events-none [&_svg]:shrink-0",
|
|
1421
|
+
className
|
|
1422
|
+
),
|
|
1423
|
+
checked,
|
|
1424
|
+
...props,
|
|
1425
|
+
children: [
|
|
1426
|
+
/* @__PURE__ */ jsx("span", { className: "pointer-events-none absolute left-1.5 flex size-4 items-center justify-center [&_svg:not([class*='size-'])]:size-4", children: /* @__PURE__ */ jsx(Menubar$1.ItemIndicator, { children: /* @__PURE__ */ jsx(CheckIcon, {}) }) }),
|
|
1427
|
+
children
|
|
1428
|
+
]
|
|
1429
|
+
}
|
|
1430
|
+
);
|
|
1431
|
+
}
|
|
1432
|
+
function MenubarRadioItem({
|
|
1433
|
+
className,
|
|
1434
|
+
children,
|
|
1435
|
+
inset,
|
|
1436
|
+
...props
|
|
1437
|
+
}) {
|
|
1438
|
+
return /* @__PURE__ */ jsxs(
|
|
1439
|
+
Menubar$1.RadioItem,
|
|
1440
|
+
{
|
|
1441
|
+
"data-slot": "menubar-radio-item",
|
|
1442
|
+
"data-inset": inset,
|
|
1443
|
+
className: cn(
|
|
1444
|
+
"relative flex cursor-default items-center gap-2 rounded-none py-2 pr-2 pl-8 text-xs outline-hidden select-none focus:bg-accent focus:text-accent-foreground focus:**:text-accent-foreground data-inset:pl-8 data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
|
|
1445
|
+
className
|
|
1446
|
+
),
|
|
1447
|
+
...props,
|
|
1448
|
+
children: [
|
|
1449
|
+
/* @__PURE__ */ jsx("span", { className: "pointer-events-none absolute left-1.5 flex size-4 items-center justify-center [&_svg:not([class*='size-'])]:size-4", children: /* @__PURE__ */ jsx(Menubar$1.ItemIndicator, { children: /* @__PURE__ */ jsx(CheckIcon, {}) }) }),
|
|
1450
|
+
children
|
|
1451
|
+
]
|
|
1452
|
+
}
|
|
1453
|
+
);
|
|
1454
|
+
}
|
|
1455
|
+
function MenubarLabel({
|
|
1456
|
+
className,
|
|
1457
|
+
inset,
|
|
1458
|
+
...props
|
|
1459
|
+
}) {
|
|
1460
|
+
return /* @__PURE__ */ jsx(Menubar$1.Label, { "data-slot": "menubar-label", "data-inset": inset, className: cn("px-2 py-2 text-xs data-inset:pl-8", className), ...props });
|
|
1461
|
+
}
|
|
1462
|
+
function MenubarSeparator({ className, ...props }) {
|
|
1463
|
+
return /* @__PURE__ */ jsx(Menubar$1.Separator, { "data-slot": "menubar-separator", className: cn("-mx-1 my-1 h-px bg-border", className), ...props });
|
|
1464
|
+
}
|
|
1465
|
+
function MenubarShortcut({ className, ...props }) {
|
|
1466
|
+
return /* @__PURE__ */ jsx(
|
|
1467
|
+
"span",
|
|
1468
|
+
{
|
|
1469
|
+
"data-slot": "menubar-shortcut",
|
|
1470
|
+
className: cn("ml-auto text-xs tracking-widest text-muted-foreground group-focus/menubar-item:text-accent-foreground", className),
|
|
1471
|
+
...props
|
|
1472
|
+
}
|
|
1473
|
+
);
|
|
1474
|
+
}
|
|
1475
|
+
function MenubarSub({ ...props }) {
|
|
1476
|
+
return /* @__PURE__ */ jsx(Menubar$1.Sub, { "data-slot": "menubar-sub", ...props });
|
|
1477
|
+
}
|
|
1478
|
+
function MenubarSubTrigger({
|
|
1479
|
+
className,
|
|
1480
|
+
inset,
|
|
1481
|
+
children,
|
|
1482
|
+
...props
|
|
1483
|
+
}) {
|
|
1484
|
+
return /* @__PURE__ */ jsxs(
|
|
1485
|
+
Menubar$1.SubTrigger,
|
|
1486
|
+
{
|
|
1487
|
+
"data-slot": "menubar-sub-trigger",
|
|
1488
|
+
"data-inset": inset,
|
|
1489
|
+
className: cn(
|
|
1490
|
+
"flex cursor-default items-center gap-2 rounded-none px-2 py-2 text-xs outline-none select-none focus:bg-accent focus:text-accent-foreground data-inset:pl-8 data-open:bg-accent data-open:text-accent-foreground [&_svg:not([class*='size-'])]:size-4",
|
|
1491
|
+
className
|
|
1492
|
+
),
|
|
1493
|
+
...props,
|
|
1494
|
+
children: [
|
|
1495
|
+
children,
|
|
1496
|
+
/* @__PURE__ */ jsx(ChevronRightIcon, { className: "ml-auto size-4" })
|
|
1497
|
+
]
|
|
1498
|
+
}
|
|
1499
|
+
);
|
|
1500
|
+
}
|
|
1501
|
+
function MenubarSubContent({ className, ...props }) {
|
|
1502
|
+
return /* @__PURE__ */ jsx(
|
|
1503
|
+
Menubar$1.SubContent,
|
|
1504
|
+
{
|
|
1505
|
+
"data-slot": "menubar-sub-content",
|
|
1506
|
+
className: cn(
|
|
1507
|
+
"z-50 min-w-32 origin-(--radix-menubar-content-transform-origin) overflow-hidden rounded-none bg-popover text-popover-foreground shadow-lg ring-1 ring-foreground/10 duration-100 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-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",
|
|
1508
|
+
className
|
|
1509
|
+
),
|
|
1510
|
+
...props
|
|
1511
|
+
}
|
|
1512
|
+
);
|
|
1513
|
+
}
|
|
1514
|
+
function NavigationMenu({
|
|
1515
|
+
className,
|
|
1516
|
+
children,
|
|
1517
|
+
viewport = true,
|
|
1518
|
+
...props
|
|
1519
|
+
}) {
|
|
1520
|
+
return /* @__PURE__ */ jsxs(
|
|
1521
|
+
NavigationMenu$1.Root,
|
|
1522
|
+
{
|
|
1523
|
+
"data-slot": "navigation-menu",
|
|
1524
|
+
"data-viewport": viewport,
|
|
1525
|
+
className: cn("group/navigation-menu relative flex max-w-max flex-1 items-center justify-center", className),
|
|
1526
|
+
...props,
|
|
1527
|
+
children: [
|
|
1528
|
+
children,
|
|
1529
|
+
viewport && /* @__PURE__ */ jsx(NavigationMenuViewport, {})
|
|
1530
|
+
]
|
|
1531
|
+
}
|
|
1532
|
+
);
|
|
1533
|
+
}
|
|
1534
|
+
function NavigationMenuList({ className, ...props }) {
|
|
1535
|
+
return /* @__PURE__ */ jsx(
|
|
1536
|
+
NavigationMenu$1.List,
|
|
1537
|
+
{
|
|
1538
|
+
"data-slot": "navigation-menu-list",
|
|
1539
|
+
className: cn("group flex flex-1 list-none items-center justify-center gap-0", className),
|
|
1540
|
+
...props
|
|
1541
|
+
}
|
|
1542
|
+
);
|
|
1543
|
+
}
|
|
1544
|
+
function NavigationMenuItem({ className, ...props }) {
|
|
1545
|
+
return /* @__PURE__ */ jsx(NavigationMenu$1.Item, { "data-slot": "navigation-menu-item", className: cn("relative", className), ...props });
|
|
1546
|
+
}
|
|
1547
|
+
var navigationMenuTriggerStyle = cva(
|
|
1548
|
+
"group/navigation-menu-trigger inline-flex h-9 w-max items-center justify-center rounded-none px-2.5 py-1.5 text-xs font-medium transition-all outline-none hover:bg-muted focus:bg-muted focus-visible:ring-1 focus-visible:ring-ring/50 focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 data-popup-open:bg-muted/50 data-popup-open:hover:bg-muted data-open:bg-muted/50 data-open:hover:bg-muted data-open:focus:bg-muted"
|
|
1549
|
+
);
|
|
1550
|
+
function NavigationMenuTrigger({ className, children, ...props }) {
|
|
1551
|
+
return /* @__PURE__ */ jsxs(NavigationMenu$1.Trigger, { "data-slot": "navigation-menu-trigger", className: cn(navigationMenuTriggerStyle(), "group", className), ...props, children: [
|
|
1552
|
+
children,
|
|
1553
|
+
" ",
|
|
1554
|
+
/* @__PURE__ */ jsx(
|
|
1555
|
+
ChevronDownIcon,
|
|
1556
|
+
{
|
|
1557
|
+
className: "relative top-px ml-1 size-3 transition duration-300 group-data-popup-open/navigation-menu-trigger:rotate-180 group-data-open/navigation-menu-trigger:rotate-180",
|
|
1558
|
+
"aria-hidden": "true"
|
|
1559
|
+
}
|
|
1560
|
+
)
|
|
1561
|
+
] });
|
|
1562
|
+
}
|
|
1563
|
+
function NavigationMenuContent({ className, ...props }) {
|
|
1564
|
+
return /* @__PURE__ */ jsx(
|
|
1565
|
+
NavigationMenu$1.Content,
|
|
1566
|
+
{
|
|
1567
|
+
"data-slot": "navigation-menu-content",
|
|
1568
|
+
className: cn(
|
|
1569
|
+
"top-0 left-0 w-full p-1 ease-[cubic-bezier(0.22,1,0.36,1)] group-data-[viewport=false]/navigation-menu:top-full group-data-[viewport=false]/navigation-menu:mt-1.5 group-data-[viewport=false]/navigation-menu:overflow-hidden group-data-[viewport=false]/navigation-menu:rounded-none group-data-[viewport=false]/navigation-menu:bg-popover group-data-[viewport=false]/navigation-menu:text-popover-foreground group-data-[viewport=false]/navigation-menu:shadow group-data-[viewport=false]/navigation-menu:ring-1 group-data-[viewport=false]/navigation-menu:ring-foreground/10 group-data-[viewport=false]/navigation-menu:duration-300 data-[motion=from-end]:slide-in-from-right-52 data-[motion=from-start]:slide-in-from-left-52 data-[motion=to-end]:slide-out-to-right-52 data-[motion=to-start]:slide-out-to-left-52 data-[motion^=from-]:animate-in data-[motion^=from-]:fade-in data-[motion^=to-]:animate-out data-[motion^=to-]:fade-out **:data-[slot=navigation-menu-link]:focus:ring-0 **:data-[slot=navigation-menu-link]:focus:outline-none md:absolute md:w-auto group-data-[viewport=false]/navigation-menu:data-open:animate-in group-data-[viewport=false]/navigation-menu:data-open:fade-in-0 group-data-[viewport=false]/navigation-menu:data-open:zoom-in-95 group-data-[viewport=false]/navigation-menu:data-closed:animate-out group-data-[viewport=false]/navigation-menu:data-closed:fade-out-0 group-data-[viewport=false]/navigation-menu:data-closed:zoom-out-95",
|
|
1570
|
+
className
|
|
1571
|
+
),
|
|
1572
|
+
...props
|
|
1573
|
+
}
|
|
1574
|
+
);
|
|
1575
|
+
}
|
|
1576
|
+
function NavigationMenuViewport({ className, ...props }) {
|
|
1577
|
+
return /* @__PURE__ */ jsx("div", { className: cn("absolute top-full left-0 isolate z-50 flex justify-center"), children: /* @__PURE__ */ jsx(
|
|
1578
|
+
NavigationMenu$1.Viewport,
|
|
1579
|
+
{
|
|
1580
|
+
"data-slot": "navigation-menu-viewport",
|
|
1581
|
+
className: cn(
|
|
1582
|
+
"origin-top-center relative mt-1.5 h-(--radix-navigation-menu-viewport-height) w-full overflow-hidden rounded-none bg-popover text-popover-foreground shadow ring-1 ring-foreground/10 duration-100 md:w-(--radix-navigation-menu-viewport-width) data-open:animate-in data-open:zoom-in-90 data-closed:animate-out data-closed:zoom-out-90",
|
|
1583
|
+
className
|
|
1584
|
+
),
|
|
1585
|
+
...props
|
|
1586
|
+
}
|
|
1587
|
+
) });
|
|
1588
|
+
}
|
|
1589
|
+
function NavigationMenuLink({ className, ...props }) {
|
|
1590
|
+
return /* @__PURE__ */ jsx(
|
|
1591
|
+
NavigationMenu$1.Link,
|
|
1592
|
+
{
|
|
1593
|
+
"data-slot": "navigation-menu-link",
|
|
1594
|
+
className: cn(
|
|
1595
|
+
"flex items-center gap-2 rounded-none p-2 text-xs transition-all outline-none hover:bg-muted focus:bg-muted focus-visible:ring-1 focus-visible:ring-ring/50 focus-visible:outline-1 in-data-[slot=navigation-menu-content]:rounded-none data-active:bg-muted/50 data-active:hover:bg-muted data-active:focus:bg-muted [&_svg:not([class*='size-'])]:size-4",
|
|
1596
|
+
className
|
|
1597
|
+
),
|
|
1598
|
+
...props
|
|
1599
|
+
}
|
|
1600
|
+
);
|
|
1601
|
+
}
|
|
1602
|
+
function NavigationMenuIndicator({ className, ...props }) {
|
|
1603
|
+
return /* @__PURE__ */ jsx(
|
|
1604
|
+
NavigationMenu$1.Indicator,
|
|
1605
|
+
{
|
|
1606
|
+
"data-slot": "navigation-menu-indicator",
|
|
1607
|
+
className: cn(
|
|
1608
|
+
"top-full z-1 flex h-1.5 items-end justify-center overflow-hidden data-[state=hidden]:animate-out data-[state=hidden]:fade-out data-[state=visible]:animate-in data-[state=visible]:fade-in",
|
|
1609
|
+
className
|
|
1610
|
+
),
|
|
1611
|
+
...props,
|
|
1612
|
+
children: /* @__PURE__ */ jsx("div", { className: "relative top-[60%] h-2 w-2 rotate-45 rounded-none bg-border shadow-md" })
|
|
1613
|
+
}
|
|
1614
|
+
);
|
|
1615
|
+
}
|
|
1616
|
+
function Pagination({ className, ...props }) {
|
|
1617
|
+
return /* @__PURE__ */ jsx("nav", { role: "navigation", "aria-label": "pagination", "data-slot": "pagination", className: cn("mx-auto flex w-full justify-center", className), ...props });
|
|
1618
|
+
}
|
|
1619
|
+
function PaginationContent({ className, ...props }) {
|
|
1620
|
+
return /* @__PURE__ */ jsx("ul", { "data-slot": "pagination-content", className: cn("flex items-center gap-0.5", className), ...props });
|
|
1621
|
+
}
|
|
1622
|
+
function PaginationItem({ ...props }) {
|
|
1623
|
+
return /* @__PURE__ */ jsx("li", { "data-slot": "pagination-item", ...props });
|
|
1624
|
+
}
|
|
1625
|
+
function PaginationLink({ className, isActive, size = "icon", ...props }) {
|
|
1626
|
+
return /* @__PURE__ */ jsx(Button, { asChild: true, variant: isActive ? "outline" : "ghost", size, className: cn(className), children: /* @__PURE__ */ jsx("a", { "aria-current": isActive ? "page" : void 0, "data-slot": "pagination-link", "data-active": isActive, ...props }) });
|
|
1627
|
+
}
|
|
1628
|
+
function PaginationPrevious({ className, text = "Previous", ...props }) {
|
|
1629
|
+
return /* @__PURE__ */ jsxs(PaginationLink, { "aria-label": "Go to previous page", size: "default", className: cn("pl-1.5!", className), ...props, children: [
|
|
1630
|
+
/* @__PURE__ */ jsx(ChevronLeftIcon, { "data-icon": "inline-start" }),
|
|
1631
|
+
/* @__PURE__ */ jsx("span", { className: "hidden sm:block", children: text })
|
|
1632
|
+
] });
|
|
1633
|
+
}
|
|
1634
|
+
function PaginationNext({ className, text = "Next", ...props }) {
|
|
1635
|
+
return /* @__PURE__ */ jsxs(PaginationLink, { "aria-label": "Go to next page", size: "default", className: cn("pr-1.5!", className), ...props, children: [
|
|
1636
|
+
/* @__PURE__ */ jsx("span", { className: "hidden sm:block", children: text }),
|
|
1637
|
+
/* @__PURE__ */ jsx(ChevronRightIcon, { "data-icon": "inline-end" })
|
|
1638
|
+
] });
|
|
1639
|
+
}
|
|
1640
|
+
function PaginationEllipsis({ className, ...props }) {
|
|
1641
|
+
return /* @__PURE__ */ jsxs(
|
|
1642
|
+
"span",
|
|
1643
|
+
{
|
|
1644
|
+
"aria-hidden": true,
|
|
1645
|
+
"data-slot": "pagination-ellipsis",
|
|
1646
|
+
className: cn("flex size-8 items-center justify-center [&_svg:not([class*='size-'])]:size-4", className),
|
|
1647
|
+
...props,
|
|
1648
|
+
children: [
|
|
1649
|
+
/* @__PURE__ */ jsx(MoreHorizontalIcon, {}),
|
|
1650
|
+
/* @__PURE__ */ jsx("span", { className: "sr-only", children: "More pages" })
|
|
1651
|
+
]
|
|
1652
|
+
}
|
|
1653
|
+
);
|
|
1654
|
+
}
|
|
1655
|
+
function Popover({
|
|
1656
|
+
...props
|
|
1657
|
+
}) {
|
|
1658
|
+
return /* @__PURE__ */ jsx(Popover$1.Root, { "data-slot": "popover", ...props });
|
|
1659
|
+
}
|
|
1660
|
+
function PopoverTrigger({
|
|
1661
|
+
...props
|
|
1662
|
+
}) {
|
|
1663
|
+
return /* @__PURE__ */ jsx(Popover$1.Trigger, { "data-slot": "popover-trigger", ...props });
|
|
1664
|
+
}
|
|
1665
|
+
function PopoverContent({
|
|
1666
|
+
className,
|
|
1667
|
+
align = "center",
|
|
1668
|
+
sideOffset = 4,
|
|
1669
|
+
...props
|
|
1670
|
+
}) {
|
|
1671
|
+
return /* @__PURE__ */ jsx(Popover$1.Portal, { children: /* @__PURE__ */ jsx(
|
|
1672
|
+
Popover$1.Content,
|
|
1673
|
+
{
|
|
1674
|
+
"data-slot": "popover-content",
|
|
1675
|
+
align,
|
|
1676
|
+
sideOffset,
|
|
1677
|
+
className: cn(
|
|
1678
|
+
"z-50 flex w-72 origin-(--radix-popover-content-transform-origin) flex-col gap-2.5 rounded-none bg-popover p-2.5 text-xs text-popover-foreground shadow-md ring-1 ring-foreground/10 outline-hidden duration-100 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-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",
|
|
1679
|
+
className
|
|
1680
|
+
),
|
|
1681
|
+
...props
|
|
1682
|
+
}
|
|
1683
|
+
) });
|
|
1684
|
+
}
|
|
1685
|
+
function PopoverAnchor({
|
|
1686
|
+
...props
|
|
1687
|
+
}) {
|
|
1688
|
+
return /* @__PURE__ */ jsx(Popover$1.Anchor, { "data-slot": "popover-anchor", ...props });
|
|
1689
|
+
}
|
|
1690
|
+
function PopoverHeader({ className, ...props }) {
|
|
1691
|
+
return /* @__PURE__ */ jsx(
|
|
1692
|
+
"div",
|
|
1693
|
+
{
|
|
1694
|
+
"data-slot": "popover-header",
|
|
1695
|
+
className: cn("flex flex-col gap-1 text-xs", className),
|
|
1696
|
+
...props
|
|
1697
|
+
}
|
|
1698
|
+
);
|
|
1699
|
+
}
|
|
1700
|
+
function PopoverTitle({ className, ...props }) {
|
|
1701
|
+
return /* @__PURE__ */ jsx(
|
|
1702
|
+
"div",
|
|
1703
|
+
{
|
|
1704
|
+
"data-slot": "popover-title",
|
|
1705
|
+
className: cn("text-sm font-medium", className),
|
|
1706
|
+
...props
|
|
1707
|
+
}
|
|
1708
|
+
);
|
|
1709
|
+
}
|
|
1710
|
+
function PopoverDescription({
|
|
1711
|
+
className,
|
|
1712
|
+
...props
|
|
1713
|
+
}) {
|
|
1714
|
+
return /* @__PURE__ */ jsx(
|
|
1715
|
+
"p",
|
|
1716
|
+
{
|
|
1717
|
+
"data-slot": "popover-description",
|
|
1718
|
+
className: cn("text-xs/relaxed text-muted-foreground", className),
|
|
1719
|
+
...props
|
|
1720
|
+
}
|
|
1721
|
+
);
|
|
1722
|
+
}
|
|
1723
|
+
function Progress({ className, value, ...props }) {
|
|
1724
|
+
return /* @__PURE__ */ jsx(
|
|
1725
|
+
Progress$1.Root,
|
|
1726
|
+
{
|
|
1727
|
+
"data-slot": "progress",
|
|
1728
|
+
className: cn("relative flex h-1 w-full items-center overflow-x-hidden rounded-none bg-muted", className),
|
|
1729
|
+
...props,
|
|
1730
|
+
children: /* @__PURE__ */ jsx(
|
|
1731
|
+
Progress$1.Indicator,
|
|
1732
|
+
{
|
|
1733
|
+
"data-slot": "progress-indicator",
|
|
1734
|
+
className: "size-full flex-1 bg-primary transition-all",
|
|
1735
|
+
style: { transform: `translateX(-${100 - (value || 0)}%)` }
|
|
1736
|
+
}
|
|
1737
|
+
)
|
|
1738
|
+
}
|
|
1739
|
+
);
|
|
1740
|
+
}
|
|
1741
|
+
function RadioGroup({ className, ...props }) {
|
|
1742
|
+
return /* @__PURE__ */ jsx(RadioGroup$1.Root, { "data-slot": "radio-group", className: cn("grid w-full gap-2", className), ...props });
|
|
1743
|
+
}
|
|
1744
|
+
function RadioGroupItem({ className, ...props }) {
|
|
1745
|
+
return /* @__PURE__ */ jsx(
|
|
1746
|
+
RadioGroup$1.Item,
|
|
1747
|
+
{
|
|
1748
|
+
"data-slot": "radio-group-item",
|
|
1749
|
+
className: cn(
|
|
1750
|
+
"group/radio-group-item peer relative flex aspect-square size-4 shrink-0 rounded-full border border-input outline-none after:absolute after:-inset-x-3 after:-inset-y-2 focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 aria-invalid:aria-checked:border-primary dark:bg-input/30 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 data-checked:border-primary data-checked:bg-primary data-checked:text-primary-foreground dark:data-checked:bg-primary",
|
|
1751
|
+
className
|
|
1752
|
+
),
|
|
1753
|
+
...props,
|
|
1754
|
+
children: /* @__PURE__ */ jsx(RadioGroup$1.Indicator, { "data-slot": "radio-group-indicator", className: "flex size-4 items-center justify-center", children: /* @__PURE__ */ jsx("span", { className: "absolute top-1/2 left-1/2 size-2 -translate-x-1/2 -translate-y-1/2 rounded-full bg-primary-foreground" }) })
|
|
1755
|
+
}
|
|
1756
|
+
);
|
|
1757
|
+
}
|
|
1758
|
+
function ResizablePanelGroup({ className, ...props }) {
|
|
1759
|
+
return /* @__PURE__ */ jsx(
|
|
1760
|
+
ResizablePrimitive.PanelGroup,
|
|
1761
|
+
{
|
|
1762
|
+
"data-slot": "resizable-panel-group",
|
|
1763
|
+
className: cn("flex h-full w-full aria-[orientation=vertical]:flex-col", className),
|
|
1764
|
+
...props
|
|
1765
|
+
}
|
|
1766
|
+
);
|
|
1767
|
+
}
|
|
1768
|
+
function ResizablePanel({ ...props }) {
|
|
1769
|
+
return /* @__PURE__ */ jsx(ResizablePrimitive.Panel, { "data-slot": "resizable-panel", ...props });
|
|
1770
|
+
}
|
|
1771
|
+
function ResizableHandle({
|
|
1772
|
+
withHandle,
|
|
1773
|
+
className,
|
|
1774
|
+
...props
|
|
1775
|
+
}) {
|
|
1776
|
+
return /* @__PURE__ */ jsx(
|
|
1777
|
+
ResizablePrimitive.PanelResizeHandle,
|
|
1778
|
+
{
|
|
1779
|
+
"data-slot": "resizable-handle",
|
|
1780
|
+
className: cn(
|
|
1781
|
+
"relative flex w-px items-center justify-center bg-border ring-offset-background after:absolute after:inset-y-0 after:left-1/2 after:w-1 after:-translate-x-1/2 focus-visible:ring-1 focus-visible:ring-ring focus-visible:outline-hidden aria-[orientation=horizontal]:h-px aria-[orientation=horizontal]:w-full aria-[orientation=horizontal]:after:left-0 aria-[orientation=horizontal]:after:h-1 aria-[orientation=horizontal]:after:w-full aria-[orientation=horizontal]:after:translate-x-0 aria-[orientation=horizontal]:after:-translate-y-1/2 [&[aria-orientation=horizontal]>div]:rotate-90",
|
|
1782
|
+
className
|
|
1783
|
+
),
|
|
1784
|
+
...props,
|
|
1785
|
+
children: withHandle && /* @__PURE__ */ jsx("div", { className: "z-10 flex h-6 w-1 shrink-0 rounded-none bg-border" })
|
|
1786
|
+
}
|
|
1787
|
+
);
|
|
1788
|
+
}
|
|
1789
|
+
function ScrollArea({
|
|
1790
|
+
className,
|
|
1791
|
+
children,
|
|
1792
|
+
...props
|
|
1793
|
+
}) {
|
|
1794
|
+
return /* @__PURE__ */ jsxs(
|
|
1795
|
+
ScrollArea$1.Root,
|
|
1796
|
+
{
|
|
1797
|
+
"data-slot": "scroll-area",
|
|
1798
|
+
className: cn("relative", className),
|
|
1799
|
+
...props,
|
|
1800
|
+
children: [
|
|
1801
|
+
/* @__PURE__ */ jsx(
|
|
1802
|
+
ScrollArea$1.Viewport,
|
|
1803
|
+
{
|
|
1804
|
+
"data-slot": "scroll-area-viewport",
|
|
1805
|
+
className: "size-full rounded-[inherit] transition-[color,box-shadow] outline-none focus-visible:ring-[3px] focus-visible:ring-ring/50 focus-visible:outline-1",
|
|
1806
|
+
children
|
|
1807
|
+
}
|
|
1808
|
+
),
|
|
1809
|
+
/* @__PURE__ */ jsx(ScrollBar, {}),
|
|
1810
|
+
/* @__PURE__ */ jsx(ScrollArea$1.Corner, {})
|
|
1811
|
+
]
|
|
1812
|
+
}
|
|
1813
|
+
);
|
|
1814
|
+
}
|
|
1815
|
+
function ScrollBar({
|
|
1816
|
+
className,
|
|
1817
|
+
orientation = "vertical",
|
|
1818
|
+
...props
|
|
1819
|
+
}) {
|
|
1820
|
+
return /* @__PURE__ */ jsx(
|
|
1821
|
+
ScrollArea$1.ScrollAreaScrollbar,
|
|
1822
|
+
{
|
|
1823
|
+
"data-slot": "scroll-area-scrollbar",
|
|
1824
|
+
"data-orientation": orientation,
|
|
1825
|
+
orientation,
|
|
1826
|
+
className: cn(
|
|
1827
|
+
"flex touch-none p-px transition-colors select-none data-horizontal:h-2.5 data-horizontal:flex-col data-horizontal:border-t data-horizontal:border-t-transparent data-vertical:h-full data-vertical:w-2.5 data-vertical:border-l data-vertical:border-l-transparent",
|
|
1828
|
+
className
|
|
1829
|
+
),
|
|
1830
|
+
...props,
|
|
1831
|
+
children: /* @__PURE__ */ jsx(
|
|
1832
|
+
ScrollArea$1.ScrollAreaThumb,
|
|
1833
|
+
{
|
|
1834
|
+
"data-slot": "scroll-area-thumb",
|
|
1835
|
+
className: "relative flex-1 rounded-none bg-border"
|
|
1836
|
+
}
|
|
1837
|
+
)
|
|
1838
|
+
}
|
|
1839
|
+
);
|
|
1840
|
+
}
|
|
1841
|
+
function Select({
|
|
1842
|
+
...props
|
|
1843
|
+
}) {
|
|
1844
|
+
return /* @__PURE__ */ jsx(Select$1.Root, { "data-slot": "select", ...props });
|
|
1845
|
+
}
|
|
1846
|
+
function SelectGroup({
|
|
1847
|
+
className,
|
|
1848
|
+
...props
|
|
1849
|
+
}) {
|
|
1850
|
+
return /* @__PURE__ */ jsx(
|
|
1851
|
+
Select$1.Group,
|
|
1852
|
+
{
|
|
1853
|
+
"data-slot": "select-group",
|
|
1854
|
+
className: cn("scroll-my-1", className),
|
|
1855
|
+
...props
|
|
1856
|
+
}
|
|
1857
|
+
);
|
|
1858
|
+
}
|
|
1859
|
+
function SelectValue({
|
|
1860
|
+
...props
|
|
1861
|
+
}) {
|
|
1862
|
+
return /* @__PURE__ */ jsx(Select$1.Value, { "data-slot": "select-value", ...props });
|
|
1863
|
+
}
|
|
1864
|
+
function SelectTrigger({
|
|
1865
|
+
className,
|
|
1866
|
+
size = "default",
|
|
1867
|
+
children,
|
|
1868
|
+
...props
|
|
1869
|
+
}) {
|
|
1870
|
+
return /* @__PURE__ */ jsxs(
|
|
1871
|
+
Select$1.Trigger,
|
|
1872
|
+
{
|
|
1873
|
+
"data-slot": "select-trigger",
|
|
1874
|
+
"data-size": size,
|
|
1875
|
+
className: cn(
|
|
1876
|
+
"flex w-fit items-center justify-between gap-1.5 rounded-none border border-input bg-transparent py-2 pr-2 pl-2.5 text-xs whitespace-nowrap transition-colors outline-none select-none focus-visible:border-ring focus-visible:ring-1 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-1 aria-invalid:ring-destructive/20 data-placeholder:text-muted-foreground data-[size=default]:h-8 data-[size=sm]:h-7 data-[size=sm]:rounded-none *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-1.5 dark:bg-input/30 dark:hover:bg-input/50 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
|
|
1877
|
+
className
|
|
1878
|
+
),
|
|
1879
|
+
...props,
|
|
1880
|
+
children: [
|
|
1881
|
+
children,
|
|
1882
|
+
/* @__PURE__ */ jsx(Select$1.Icon, { asChild: true, children: /* @__PURE__ */ jsx(ChevronDownIcon, { className: "pointer-events-none size-4 text-muted-foreground" }) })
|
|
1883
|
+
]
|
|
1884
|
+
}
|
|
1885
|
+
);
|
|
1886
|
+
}
|
|
1887
|
+
function SelectContent({
|
|
1888
|
+
className,
|
|
1889
|
+
children,
|
|
1890
|
+
position = "item-aligned",
|
|
1891
|
+
align = "center",
|
|
1892
|
+
...props
|
|
1893
|
+
}) {
|
|
1894
|
+
return /* @__PURE__ */ jsx(Select$1.Portal, { children: /* @__PURE__ */ jsxs(
|
|
1895
|
+
Select$1.Content,
|
|
1896
|
+
{
|
|
1897
|
+
"data-slot": "select-content",
|
|
1898
|
+
"data-align-trigger": position === "item-aligned",
|
|
1899
|
+
className: cn("relative z-50 max-h-(--radix-select-content-available-height) min-w-36 origin-(--radix-select-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-none bg-popover text-popover-foreground shadow-md ring-1 ring-foreground/10 duration-100 data-[align-trigger=true]:animate-none 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-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95", 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", className),
|
|
1900
|
+
position,
|
|
1901
|
+
align,
|
|
1902
|
+
...props,
|
|
1903
|
+
children: [
|
|
1904
|
+
/* @__PURE__ */ jsx(SelectScrollUpButton, {}),
|
|
1905
|
+
/* @__PURE__ */ jsx(
|
|
1906
|
+
Select$1.Viewport,
|
|
1907
|
+
{
|
|
1908
|
+
"data-position": position,
|
|
1909
|
+
className: cn(
|
|
1910
|
+
"data-[position=popper]:h-(--radix-select-trigger-height) data-[position=popper]:w-full data-[position=popper]:min-w-(--radix-select-trigger-width)",
|
|
1911
|
+
position === "popper" && ""
|
|
1912
|
+
),
|
|
1913
|
+
children
|
|
1914
|
+
}
|
|
1915
|
+
),
|
|
1916
|
+
/* @__PURE__ */ jsx(SelectScrollDownButton, {})
|
|
1917
|
+
]
|
|
1918
|
+
}
|
|
1919
|
+
) });
|
|
1920
|
+
}
|
|
1921
|
+
function SelectLabel({
|
|
1922
|
+
className,
|
|
1923
|
+
...props
|
|
1924
|
+
}) {
|
|
1925
|
+
return /* @__PURE__ */ jsx(
|
|
1926
|
+
Select$1.Label,
|
|
1927
|
+
{
|
|
1928
|
+
"data-slot": "select-label",
|
|
1929
|
+
className: cn("px-2 py-2 text-xs text-muted-foreground", className),
|
|
1930
|
+
...props
|
|
1931
|
+
}
|
|
1932
|
+
);
|
|
1933
|
+
}
|
|
1934
|
+
function SelectItem({
|
|
1935
|
+
className,
|
|
1936
|
+
children,
|
|
1937
|
+
...props
|
|
1938
|
+
}) {
|
|
1939
|
+
return /* @__PURE__ */ jsxs(
|
|
1940
|
+
Select$1.Item,
|
|
1941
|
+
{
|
|
1942
|
+
"data-slot": "select-item",
|
|
1943
|
+
className: cn(
|
|
1944
|
+
"relative flex w-full cursor-default items-center gap-2 rounded-none py-2 pr-8 pl-2 text-xs outline-hidden select-none focus:bg-accent focus:text-accent-foreground not-data-[variant=destructive]: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 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2",
|
|
1945
|
+
className
|
|
1946
|
+
),
|
|
1947
|
+
...props,
|
|
1948
|
+
children: [
|
|
1949
|
+
/* @__PURE__ */ jsx("span", { className: "pointer-events-none absolute right-2 flex size-4 items-center justify-center", children: /* @__PURE__ */ jsx(Select$1.ItemIndicator, { children: /* @__PURE__ */ jsx(CheckIcon, { className: "pointer-events-none" }) }) }),
|
|
1950
|
+
/* @__PURE__ */ jsx(Select$1.ItemText, { children })
|
|
1951
|
+
]
|
|
1952
|
+
}
|
|
1953
|
+
);
|
|
1954
|
+
}
|
|
1955
|
+
function SelectSeparator({
|
|
1956
|
+
className,
|
|
1957
|
+
...props
|
|
1958
|
+
}) {
|
|
1959
|
+
return /* @__PURE__ */ jsx(
|
|
1960
|
+
Select$1.Separator,
|
|
1961
|
+
{
|
|
1962
|
+
"data-slot": "select-separator",
|
|
1963
|
+
className: cn("pointer-events-none -mx-1 h-px bg-border", className),
|
|
1964
|
+
...props
|
|
1965
|
+
}
|
|
1966
|
+
);
|
|
1967
|
+
}
|
|
1968
|
+
function SelectScrollUpButton({
|
|
1969
|
+
className,
|
|
1970
|
+
...props
|
|
1971
|
+
}) {
|
|
1972
|
+
return /* @__PURE__ */ jsx(
|
|
1973
|
+
Select$1.ScrollUpButton,
|
|
1974
|
+
{
|
|
1975
|
+
"data-slot": "select-scroll-up-button",
|
|
1976
|
+
className: cn(
|
|
1977
|
+
"z-10 flex cursor-default items-center justify-center bg-popover py-1 [&_svg:not([class*='size-'])]:size-4",
|
|
1978
|
+
className
|
|
1979
|
+
),
|
|
1980
|
+
...props,
|
|
1981
|
+
children: /* @__PURE__ */ jsx(
|
|
1982
|
+
ChevronUpIcon,
|
|
1983
|
+
{}
|
|
1984
|
+
)
|
|
1985
|
+
}
|
|
1986
|
+
);
|
|
1987
|
+
}
|
|
1988
|
+
function SelectScrollDownButton({
|
|
1989
|
+
className,
|
|
1990
|
+
...props
|
|
1991
|
+
}) {
|
|
1992
|
+
return /* @__PURE__ */ jsx(
|
|
1993
|
+
Select$1.ScrollDownButton,
|
|
1994
|
+
{
|
|
1995
|
+
"data-slot": "select-scroll-down-button",
|
|
1996
|
+
className: cn(
|
|
1997
|
+
"z-10 flex cursor-default items-center justify-center bg-popover py-1 [&_svg:not([class*='size-'])]:size-4",
|
|
1998
|
+
className
|
|
1999
|
+
),
|
|
2000
|
+
...props,
|
|
2001
|
+
children: /* @__PURE__ */ jsx(
|
|
2002
|
+
ChevronDownIcon,
|
|
2003
|
+
{}
|
|
2004
|
+
)
|
|
2005
|
+
}
|
|
2006
|
+
);
|
|
2007
|
+
}
|
|
2008
|
+
function Slider({
|
|
2009
|
+
className,
|
|
2010
|
+
defaultValue,
|
|
2011
|
+
value,
|
|
2012
|
+
min = 0,
|
|
2013
|
+
max = 100,
|
|
2014
|
+
...props
|
|
2015
|
+
}) {
|
|
2016
|
+
const _values = React26.useMemo(
|
|
2017
|
+
() => Array.isArray(value) ? value : Array.isArray(defaultValue) ? defaultValue : [min, max],
|
|
2018
|
+
[value, defaultValue, min, max]
|
|
2019
|
+
);
|
|
2020
|
+
return /* @__PURE__ */ jsxs(
|
|
2021
|
+
Slider$1.Root,
|
|
2022
|
+
{
|
|
2023
|
+
"data-slot": "slider",
|
|
2024
|
+
defaultValue,
|
|
2025
|
+
value,
|
|
2026
|
+
min,
|
|
2027
|
+
max,
|
|
2028
|
+
className: cn(
|
|
2029
|
+
"relative flex w-full touch-none items-center select-none data-disabled:opacity-50 data-vertical:h-full data-vertical:min-h-40 data-vertical:w-auto data-vertical:flex-col",
|
|
2030
|
+
className
|
|
2031
|
+
),
|
|
2032
|
+
...props,
|
|
2033
|
+
children: [
|
|
2034
|
+
/* @__PURE__ */ jsx(
|
|
2035
|
+
Slider$1.Track,
|
|
2036
|
+
{
|
|
2037
|
+
"data-slot": "slider-track",
|
|
2038
|
+
className: "relative grow overflow-hidden rounded-none bg-muted data-horizontal:h-1 data-horizontal:w-full data-vertical:h-full data-vertical:w-1",
|
|
2039
|
+
children: /* @__PURE__ */ jsx(
|
|
2040
|
+
Slider$1.Range,
|
|
2041
|
+
{
|
|
2042
|
+
"data-slot": "slider-range",
|
|
2043
|
+
className: "absolute bg-primary select-none data-horizontal:h-full data-vertical:w-full"
|
|
2044
|
+
}
|
|
2045
|
+
)
|
|
2046
|
+
}
|
|
2047
|
+
),
|
|
2048
|
+
Array.from({ length: _values.length }, (_, index) => /* @__PURE__ */ jsx(
|
|
2049
|
+
Slider$1.Thumb,
|
|
2050
|
+
{
|
|
2051
|
+
"data-slot": "slider-thumb",
|
|
2052
|
+
className: "relative block size-3 shrink-0 rounded-none border border-ring bg-white ring-ring/50 transition-[color,box-shadow] select-none after:absolute after:-inset-2 hover:ring-1 focus-visible:ring-1 focus-visible:outline-hidden active:ring-1 disabled:pointer-events-none disabled:opacity-50"
|
|
2053
|
+
},
|
|
2054
|
+
index
|
|
2055
|
+
))
|
|
2056
|
+
]
|
|
2057
|
+
}
|
|
2058
|
+
);
|
|
2059
|
+
}
|
|
2060
|
+
var Toaster = ({ ...props }) => {
|
|
2061
|
+
const { theme = "system" } = useTheme();
|
|
2062
|
+
return /* @__PURE__ */ jsx(
|
|
2063
|
+
Toaster$1,
|
|
2064
|
+
{
|
|
2065
|
+
theme,
|
|
2066
|
+
className: "toaster group",
|
|
2067
|
+
icons: {
|
|
2068
|
+
success: /* @__PURE__ */ jsx(CircleCheckIcon, { className: "size-4" }),
|
|
2069
|
+
info: /* @__PURE__ */ jsx(InfoIcon, { className: "size-4" }),
|
|
2070
|
+
warning: /* @__PURE__ */ jsx(TriangleAlertIcon, { className: "size-4" }),
|
|
2071
|
+
error: /* @__PURE__ */ jsx(OctagonXIcon, { className: "size-4" }),
|
|
2072
|
+
loading: /* @__PURE__ */ jsx(Loader2Icon, { className: "size-4 animate-spin" })
|
|
2073
|
+
},
|
|
2074
|
+
style: {
|
|
2075
|
+
"--normal-bg": "var(--popover)",
|
|
2076
|
+
"--normal-text": "var(--popover-foreground)",
|
|
2077
|
+
"--normal-border": "var(--border)",
|
|
2078
|
+
"--border-radius": "var(--radius)"
|
|
2079
|
+
},
|
|
2080
|
+
toastOptions: {
|
|
2081
|
+
classNames: {
|
|
2082
|
+
toast: "cn-toast"
|
|
2083
|
+
}
|
|
2084
|
+
},
|
|
2085
|
+
...props
|
|
2086
|
+
}
|
|
2087
|
+
);
|
|
2088
|
+
};
|
|
2089
|
+
function Spinner({ className, ...props }) {
|
|
2090
|
+
return /* @__PURE__ */ jsx(Loader2Icon, { role: "status", "aria-label": "Loading", className: cn("size-4 animate-spin", className), ...props });
|
|
2091
|
+
}
|
|
2092
|
+
function Switch({
|
|
2093
|
+
className,
|
|
2094
|
+
size = "default",
|
|
2095
|
+
...props
|
|
2096
|
+
}) {
|
|
2097
|
+
return /* @__PURE__ */ jsx(
|
|
2098
|
+
Switch$1.Root,
|
|
2099
|
+
{
|
|
2100
|
+
"data-slot": "switch",
|
|
2101
|
+
"data-size": size,
|
|
2102
|
+
className: cn(
|
|
2103
|
+
"peer group/switch relative inline-flex shrink-0 items-center rounded-full border border-transparent transition-all outline-none after:absolute after:-inset-x-3 after:-inset-y-2 focus-visible:border-ring focus-visible:ring-1 focus-visible:ring-ring/50 aria-invalid:border-destructive aria-invalid:ring-1 aria-invalid:ring-destructive/20 data-[size=default]:h-[18.4px] data-[size=default]:w-[32px] data-[size=sm]:h-[14px] data-[size=sm]:w-[24px] dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 data-checked:bg-primary data-unchecked:bg-input dark:data-unchecked:bg-input/80 data-disabled:cursor-not-allowed data-disabled:opacity-50",
|
|
2104
|
+
className
|
|
2105
|
+
),
|
|
2106
|
+
...props,
|
|
2107
|
+
children: /* @__PURE__ */ jsx(
|
|
2108
|
+
Switch$1.Thumb,
|
|
2109
|
+
{
|
|
2110
|
+
"data-slot": "switch-thumb",
|
|
2111
|
+
className: "pointer-events-none block rounded-full bg-background ring-0 transition-transform group-data-[size=default]/switch:size-4 group-data-[size=sm]/switch:size-3 group-data-[size=default]/switch:data-checked:translate-x-[calc(100%-2px)] group-data-[size=sm]/switch:data-checked:translate-x-[calc(100%-2px)] dark:data-checked:bg-primary-foreground group-data-[size=default]/switch:data-unchecked:translate-x-0 group-data-[size=sm]/switch:data-unchecked:translate-x-0 dark:data-unchecked:bg-foreground"
|
|
2112
|
+
}
|
|
2113
|
+
)
|
|
2114
|
+
}
|
|
2115
|
+
);
|
|
2116
|
+
}
|
|
2117
|
+
function Tabs({
|
|
2118
|
+
className,
|
|
2119
|
+
orientation = "horizontal",
|
|
2120
|
+
...props
|
|
2121
|
+
}) {
|
|
2122
|
+
return /* @__PURE__ */ jsx(
|
|
2123
|
+
Tabs$1.Root,
|
|
2124
|
+
{
|
|
2125
|
+
"data-slot": "tabs",
|
|
2126
|
+
"data-orientation": orientation,
|
|
2127
|
+
className: cn(
|
|
2128
|
+
"group/tabs flex gap-2 data-horizontal:flex-col",
|
|
2129
|
+
className
|
|
2130
|
+
),
|
|
2131
|
+
...props
|
|
2132
|
+
}
|
|
2133
|
+
);
|
|
2134
|
+
}
|
|
2135
|
+
var tabsListVariants = cva(
|
|
2136
|
+
"group/tabs-list inline-flex w-fit items-center justify-center rounded-none p-[3px] text-muted-foreground group-data-horizontal/tabs:h-8 group-data-vertical/tabs:h-fit group-data-vertical/tabs:flex-col data-[variant=line]:rounded-none",
|
|
2137
|
+
{
|
|
2138
|
+
variants: {
|
|
2139
|
+
variant: {
|
|
2140
|
+
default: "bg-muted",
|
|
2141
|
+
line: "gap-1 bg-transparent"
|
|
2142
|
+
}
|
|
2143
|
+
},
|
|
2144
|
+
defaultVariants: {
|
|
2145
|
+
variant: "default"
|
|
2146
|
+
}
|
|
2147
|
+
}
|
|
2148
|
+
);
|
|
2149
|
+
function TabsList({
|
|
2150
|
+
className,
|
|
2151
|
+
variant = "default",
|
|
2152
|
+
...props
|
|
2153
|
+
}) {
|
|
2154
|
+
return /* @__PURE__ */ jsx(
|
|
2155
|
+
Tabs$1.List,
|
|
2156
|
+
{
|
|
2157
|
+
"data-slot": "tabs-list",
|
|
2158
|
+
"data-variant": variant,
|
|
2159
|
+
className: cn(tabsListVariants({ variant }), className),
|
|
2160
|
+
...props
|
|
2161
|
+
}
|
|
2162
|
+
);
|
|
2163
|
+
}
|
|
2164
|
+
function TabsTrigger({
|
|
2165
|
+
className,
|
|
2166
|
+
...props
|
|
2167
|
+
}) {
|
|
2168
|
+
return /* @__PURE__ */ jsx(
|
|
2169
|
+
Tabs$1.Trigger,
|
|
2170
|
+
{
|
|
2171
|
+
"data-slot": "tabs-trigger",
|
|
2172
|
+
className: cn(
|
|
2173
|
+
"relative inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center gap-1.5 rounded-none border border-transparent px-1.5 py-0.5 text-xs font-medium whitespace-nowrap text-foreground/60 transition-all group-data-vertical/tabs:w-full group-data-vertical/tabs:justify-start group-data-vertical/tabs:py-[calc(--spacing(1.25))] 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 has-data-[icon=inline-end]:pr-1 has-data-[icon=inline-start]:pl-1 dark:text-muted-foreground dark:hover:text-foreground [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
|
|
2174
|
+
"group-data-[variant=line]/tabs-list:bg-transparent group-data-[variant=line]/tabs-list:data-active:bg-transparent dark:group-data-[variant=line]/tabs-list:data-active:border-transparent dark:group-data-[variant=line]/tabs-list:data-active:bg-transparent",
|
|
2175
|
+
"data-active:bg-background data-active:text-foreground dark:data-active:border-input dark:data-active:bg-input/30 dark:data-active:text-foreground",
|
|
2176
|
+
"after:absolute after:bg-foreground after:opacity-0 after:transition-opacity group-data-horizontal/tabs:after:inset-x-0 group-data-horizontal/tabs:after:bottom-[-5px] group-data-horizontal/tabs:after:h-0.5 group-data-vertical/tabs:after:inset-y-0 group-data-vertical/tabs:after:-right-1 group-data-vertical/tabs:after:w-0.5 group-data-[variant=line]/tabs-list:data-active:after:opacity-100",
|
|
2177
|
+
className
|
|
2178
|
+
),
|
|
2179
|
+
...props
|
|
2180
|
+
}
|
|
2181
|
+
);
|
|
2182
|
+
}
|
|
2183
|
+
function TabsContent({
|
|
2184
|
+
className,
|
|
2185
|
+
...props
|
|
2186
|
+
}) {
|
|
2187
|
+
return /* @__PURE__ */ jsx(
|
|
2188
|
+
Tabs$1.Content,
|
|
2189
|
+
{
|
|
2190
|
+
"data-slot": "tabs-content",
|
|
2191
|
+
className: cn("flex-1 text-xs/relaxed outline-none", className),
|
|
2192
|
+
...props
|
|
2193
|
+
}
|
|
2194
|
+
);
|
|
2195
|
+
}
|
|
2196
|
+
var toggleVariants = cva(
|
|
2197
|
+
"group/toggle inline-flex items-center justify-center gap-1 rounded-none text-xs font-medium whitespace-nowrap transition-all outline-none hover:bg-muted hover:text-foreground 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 aria-pressed:bg-muted data-[state=on]:bg-muted dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
|
|
2198
|
+
{
|
|
2199
|
+
variants: {
|
|
2200
|
+
variant: {
|
|
2201
|
+
default: "bg-transparent",
|
|
2202
|
+
outline: "border border-input bg-transparent hover:bg-muted"
|
|
2203
|
+
},
|
|
2204
|
+
size: {
|
|
2205
|
+
default: "h-8 min-w-8 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2",
|
|
2206
|
+
sm: "h-7 min-w-7 rounded-none px-2.5 has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5",
|
|
2207
|
+
lg: "h-9 min-w-9 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2"
|
|
2208
|
+
}
|
|
2209
|
+
},
|
|
2210
|
+
defaultVariants: {
|
|
2211
|
+
variant: "default",
|
|
2212
|
+
size: "default"
|
|
2213
|
+
}
|
|
2214
|
+
}
|
|
2215
|
+
);
|
|
2216
|
+
function Toggle({
|
|
2217
|
+
className,
|
|
2218
|
+
variant = "default",
|
|
2219
|
+
size = "default",
|
|
2220
|
+
...props
|
|
2221
|
+
}) {
|
|
2222
|
+
return /* @__PURE__ */ jsx(Toggle$1.Root, { "data-slot": "toggle", className: cn(toggleVariants({ variant, size, className })), ...props });
|
|
2223
|
+
}
|
|
2224
|
+
var ToggleGroupContext = React26.createContext({
|
|
2225
|
+
size: "default",
|
|
2226
|
+
variant: "default",
|
|
2227
|
+
spacing: 0,
|
|
2228
|
+
orientation: "horizontal"
|
|
2229
|
+
});
|
|
2230
|
+
function ToggleGroup({
|
|
2231
|
+
className,
|
|
2232
|
+
variant,
|
|
2233
|
+
size,
|
|
2234
|
+
spacing = 0,
|
|
2235
|
+
orientation = "horizontal",
|
|
2236
|
+
children,
|
|
2237
|
+
...props
|
|
2238
|
+
}) {
|
|
2239
|
+
return /* @__PURE__ */ jsx(
|
|
2240
|
+
ToggleGroup$1.Root,
|
|
2241
|
+
{
|
|
2242
|
+
"data-slot": "toggle-group",
|
|
2243
|
+
"data-variant": variant,
|
|
2244
|
+
"data-size": size,
|
|
2245
|
+
"data-spacing": spacing,
|
|
2246
|
+
"data-orientation": orientation,
|
|
2247
|
+
style: { "--gap": spacing },
|
|
2248
|
+
className: cn(
|
|
2249
|
+
"group/toggle-group flex w-fit flex-row items-center gap-[--spacing(var(--gap))] rounded-none data-[size=sm]:rounded-none data-vertical:flex-col data-vertical:items-stretch",
|
|
2250
|
+
className
|
|
2251
|
+
),
|
|
2252
|
+
...props,
|
|
2253
|
+
children: /* @__PURE__ */ jsx(ToggleGroupContext.Provider, { value: { variant, size, spacing, orientation }, children })
|
|
2254
|
+
}
|
|
2255
|
+
);
|
|
2256
|
+
}
|
|
2257
|
+
function ToggleGroupItem({
|
|
2258
|
+
className,
|
|
2259
|
+
children,
|
|
2260
|
+
variant = "default",
|
|
2261
|
+
size = "default",
|
|
2262
|
+
...props
|
|
2263
|
+
}) {
|
|
2264
|
+
const context = React26.useContext(ToggleGroupContext);
|
|
2265
|
+
return /* @__PURE__ */ jsx(
|
|
2266
|
+
ToggleGroup$1.Item,
|
|
2267
|
+
{
|
|
2268
|
+
"data-slot": "toggle-group-item",
|
|
2269
|
+
"data-variant": context.variant || variant,
|
|
2270
|
+
"data-size": context.size || size,
|
|
2271
|
+
"data-spacing": context.spacing,
|
|
2272
|
+
className: cn(
|
|
2273
|
+
"shrink-0 group-data-[spacing=0]/toggle-group:rounded-none group-data-[spacing=0]/toggle-group:px-2 focus:z-10 focus-visible:z-10 group-data-[spacing=0]/toggle-group:has-data-[icon=inline-end]:pr-1.5 group-data-[spacing=0]/toggle-group:has-data-[icon=inline-start]:pl-1.5 group-data-horizontal/toggle-group:data-[spacing=0]:first:rounded-none group-data-vertical/toggle-group:data-[spacing=0]:first:rounded-none group-data-horizontal/toggle-group:data-[spacing=0]:last:rounded-none group-data-vertical/toggle-group:data-[spacing=0]:last:rounded-none group-data-horizontal/toggle-group:data-[spacing=0]:data-[variant=outline]:border-l-0 group-data-vertical/toggle-group:data-[spacing=0]:data-[variant=outline]:border-t-0 group-data-horizontal/toggle-group:data-[spacing=0]:data-[variant=outline]:first:border-l group-data-vertical/toggle-group:data-[spacing=0]:data-[variant=outline]:first:border-t",
|
|
2274
|
+
toggleVariants({
|
|
2275
|
+
variant: context.variant || variant,
|
|
2276
|
+
size: context.size || size
|
|
2277
|
+
}),
|
|
2278
|
+
className
|
|
2279
|
+
),
|
|
2280
|
+
...props,
|
|
2281
|
+
children
|
|
2282
|
+
}
|
|
2283
|
+
);
|
|
2284
|
+
}
|
|
2285
|
+
var defaultAccountMenuLabels = {
|
|
2286
|
+
account: "Account",
|
|
2287
|
+
guest: "Guest",
|
|
2288
|
+
signIn: "Sign in",
|
|
2289
|
+
switchAccount: "Switch account",
|
|
2290
|
+
signOut: "Sign out"
|
|
2291
|
+
};
|
|
2292
|
+
function AccountMenu({
|
|
2293
|
+
user,
|
|
2294
|
+
labels,
|
|
2295
|
+
onSignOut,
|
|
2296
|
+
onSwitchAccount,
|
|
2297
|
+
onSignIn,
|
|
2298
|
+
align = "end",
|
|
2299
|
+
children
|
|
2300
|
+
}) {
|
|
2301
|
+
const l = { ...defaultAccountMenuLabels, ...labels };
|
|
2302
|
+
const displayName = user?.name ?? user?.email ?? l.account;
|
|
2303
|
+
return /* @__PURE__ */ jsxs(DropdownMenu, { children: [
|
|
2304
|
+
/* @__PURE__ */ jsx(DropdownMenuTrigger, { asChild: true, children: user ? /* @__PURE__ */ jsxs(
|
|
2305
|
+
"button",
|
|
2306
|
+
{
|
|
2307
|
+
type: "button",
|
|
2308
|
+
"aria-label": l.account,
|
|
2309
|
+
className: cn(
|
|
2310
|
+
"focus-visible:ring-ring flex items-center gap-3 rounded-none outline-none focus-visible:ring-2"
|
|
2311
|
+
),
|
|
2312
|
+
children: [
|
|
2313
|
+
/* @__PURE__ */ jsxs("span", { className: "hidden text-right leading-tight sm:flex sm:flex-col", children: [
|
|
2314
|
+
/* @__PURE__ */ jsx("span", { className: "text-sm font-medium", children: user.name ?? "\u2014" }),
|
|
2315
|
+
user.email ? /* @__PURE__ */ jsx("span", { className: "text-muted-foreground text-xs", children: user.email }) : null
|
|
2316
|
+
] }),
|
|
2317
|
+
/* @__PURE__ */ jsxs(Avatar, { children: [
|
|
2318
|
+
user.image ? /* @__PURE__ */ jsx(AvatarImage, { src: user.image, alt: displayName }) : null,
|
|
2319
|
+
/* @__PURE__ */ jsx(AvatarFallback, { children: initialsOf(user.name ?? user.email) })
|
|
2320
|
+
] })
|
|
2321
|
+
]
|
|
2322
|
+
}
|
|
2323
|
+
) : /* @__PURE__ */ jsxs(
|
|
2324
|
+
"button",
|
|
2325
|
+
{
|
|
2326
|
+
type: "button",
|
|
2327
|
+
"aria-label": l.account,
|
|
2328
|
+
className: cn(
|
|
2329
|
+
"focus-visible:ring-ring text-muted-foreground flex items-center gap-2 rounded-none outline-none focus-visible:ring-2"
|
|
2330
|
+
),
|
|
2331
|
+
children: [
|
|
2332
|
+
/* @__PURE__ */ jsx("span", { className: "hidden text-sm sm:inline", children: l.guest }),
|
|
2333
|
+
/* @__PURE__ */ jsx(CircleUser, { className: "size-7" })
|
|
2334
|
+
]
|
|
2335
|
+
}
|
|
2336
|
+
) }),
|
|
2337
|
+
/* @__PURE__ */ jsxs(DropdownMenuContent, { align, className: "w-56", children: [
|
|
2338
|
+
user ? /* @__PURE__ */ jsxs(DropdownMenuLabel, { className: "flex flex-col gap-0.5", children: [
|
|
2339
|
+
/* @__PURE__ */ jsx("span", { className: "text-sm font-medium leading-tight", children: user.name ?? "\u2014" }),
|
|
2340
|
+
user.email ? /* @__PURE__ */ jsx("span", { className: "text-muted-foreground text-xs font-normal leading-tight", children: user.email }) : null
|
|
2341
|
+
] }) : /* @__PURE__ */ jsx(DropdownMenuLabel, { className: "text-muted-foreground font-normal", children: l.guest }),
|
|
2342
|
+
children ? /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
2343
|
+
/* @__PURE__ */ jsx(DropdownMenuSeparator, {}),
|
|
2344
|
+
children
|
|
2345
|
+
] }) : null,
|
|
2346
|
+
/* @__PURE__ */ jsx(DropdownMenuSeparator, {}),
|
|
2347
|
+
user ? /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
2348
|
+
onSwitchAccount ? /* @__PURE__ */ jsxs(DropdownMenuItem, { onSelect: onSwitchAccount, children: [
|
|
2349
|
+
/* @__PURE__ */ jsx(Users, { className: "mr-2" }),
|
|
2350
|
+
l.switchAccount
|
|
2351
|
+
] }) : null,
|
|
2352
|
+
onSignOut ? /* @__PURE__ */ jsxs(DropdownMenuItem, { variant: "destructive", onSelect: onSignOut, children: [
|
|
2353
|
+
/* @__PURE__ */ jsx(LogOut, { className: "mr-2" }),
|
|
2354
|
+
l.signOut
|
|
2355
|
+
] }) : null
|
|
2356
|
+
] }) : onSignIn ? /* @__PURE__ */ jsxs(DropdownMenuItem, { onSelect: onSignIn, children: [
|
|
2357
|
+
/* @__PURE__ */ jsx(LogIn, { className: "mr-2" }),
|
|
2358
|
+
l.signIn
|
|
2359
|
+
] }) : null
|
|
2360
|
+
] })
|
|
2361
|
+
] });
|
|
2362
|
+
}
|
|
2363
|
+
function initialsOf(value) {
|
|
2364
|
+
if (!value) return "?";
|
|
2365
|
+
const base = value.includes("@") ? value.split("@")[0] ?? value : value;
|
|
2366
|
+
const parts = base.split(/[\s._-]+/).filter(Boolean);
|
|
2367
|
+
const letters = (parts[0]?.[0] ?? "") + (parts[1]?.[0] ?? "");
|
|
2368
|
+
return (letters || base.slice(0, 2)).toUpperCase();
|
|
2369
|
+
}
|
|
2370
|
+
|
|
2371
|
+
export { Accordion, AccordionContent, AccordionItem, AccordionTrigger, AccountMenu, Alert, AlertAction, AlertDescription, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogMedia, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, AlertTitle, AspectRatio, Avatar, AvatarBadge, AvatarFallback, AvatarGroup, AvatarGroupCount, AvatarImage, Badge, ButtonGroup, ButtonGroupSeparator, ButtonGroupText, Checkbox, Collapsible, CollapsibleContent, CollapsibleTrigger, Command, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandSeparator, CommandShortcut, ContextMenu, ContextMenuCheckboxItem, ContextMenuContent, ContextMenuGroup, ContextMenuItem, ContextMenuLabel, ContextMenuPortal, ContextMenuRadioGroup, ContextMenuRadioItem, ContextMenuSeparator, ContextMenuShortcut, ContextMenuSub, ContextMenuSubContent, ContextMenuSubTrigger, ContextMenuTrigger, Drawer, DrawerClose, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerOverlay, DrawerPortal, DrawerTitle, DrawerTrigger, Field, FieldContent, FieldDescription, FieldError, FieldGroup, FieldLabel, FieldLegend, FieldSeparator, FieldSet, FieldTitle, HoverCard, HoverCardContent, HoverCardTrigger, InputGroup, InputGroupAddon, InputGroupButton, InputGroupInput, InputGroupText, InputGroupTextarea, InputOTP, InputOTPGroup, InputOTPSeparator, InputOTPSlot, Menubar, MenubarCheckboxItem, MenubarContent, MenubarGroup, MenubarItem, MenubarLabel, MenubarMenu, MenubarPortal, MenubarRadioGroup, MenubarRadioItem, MenubarSeparator, MenubarShortcut, MenubarSub, MenubarSubContent, MenubarSubTrigger, MenubarTrigger, NavigationMenu, NavigationMenuContent, NavigationMenuIndicator, NavigationMenuItem, NavigationMenuLink, NavigationMenuList, NavigationMenuTrigger, NavigationMenuViewport, Pagination, PaginationContent, PaginationEllipsis, PaginationItem, PaginationLink, PaginationNext, PaginationPrevious, Popover, PopoverAnchor, PopoverContent, PopoverDescription, PopoverHeader, PopoverTitle, PopoverTrigger, Progress, RadioGroup, RadioGroupItem, ResizableHandle, ResizablePanel, ResizablePanelGroup, ScrollArea, ScrollBar, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, Slider, Spinner, Switch, Tabs, TabsContent, TabsList, TabsTrigger, Textarea, Toaster, Toggle, ToggleGroup, ToggleGroupItem, badgeVariants, buttonGroupVariants, defaultAccountMenuLabels, navigationMenuTriggerStyle, tabsListVariants, toggleVariants };
|
|
2372
|
+
//# sourceMappingURL=index.js.map
|
|
2373
|
+
//# sourceMappingURL=index.js.map
|