@arcadeai/design-system 0.7.3 → 0.7.5
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/dist/components/index.js +109 -108
- package/dist/components/ui/atoms/accordion.js +1 -1
- package/dist/components/ui/atoms/avatar.js +200 -82
- package/dist/components/ui/atoms/breadcrumb.js +25 -37
- package/dist/components/ui/atoms/chart.js +115 -10378
- package/dist/components/ui/atoms/command.js +158 -168
- package/dist/components/ui/atoms/dialog.js +30 -29
- package/dist/components/ui/atoms/dropdown-menu.js +153 -162
- package/dist/components/ui/atoms/form.js +57 -250
- package/dist/components/ui/atoms/hover-card.js +1 -1
- package/dist/components/ui/atoms/index.js +109 -108
- package/dist/components/ui/atoms/popover.js +1 -1
- package/dist/components/ui/atoms/resizable.js +359 -372
- package/dist/components/ui/atoms/select.js +101 -110
- package/dist/components/ui/atoms/sheet.js +24 -23
- package/dist/components/ui/atoms/sidebar.js +80 -89
- package/dist/components/ui/atoms/tooltip.js +1 -1
- package/dist/components/ui/index.js +109 -108
- package/dist/{index-f0YS5Ufh.js → index-PlrlSrPo.js} +266 -259
- package/dist/{index-DLfXSskr.js → index-toVHZ337.js} +49 -61
- package/dist/main.js +109 -108
- package/package.json +4 -3
- package/dist/check-B5h1DvDs.js +0 -11
- package/dist/chevron-down-DmZMdOiC.js +0 -11
- package/dist/chevron-right-BYYHEJjK.js +0 -11
- package/dist/createLucideIcon-XRdN60yz.js +0 -94
- package/dist/index-CJFGOBPb.js +0 -122
package/dist/components/index.js
CHANGED
|
@@ -2,35 +2,36 @@ import { Accordion as o, AccordionContent as t, AccordionItem as a, AccordionTri
|
|
|
2
2
|
import { Alert as l, AlertDescription as d, AlertTitle as p } from "./ui/atoms/alert.js";
|
|
3
3
|
import { Avatar as S, AvatarFallback as b, AvatarImage as u } from "./ui/atoms/avatar.js";
|
|
4
4
|
import { Badge as g, badgeVariants as c } from "./ui/atoms/badge.js";
|
|
5
|
-
import { Breadcrumb as
|
|
5
|
+
import { Breadcrumb as T, BreadcrumbEllipsis as f, BreadcrumbItem as s, BreadcrumbLink as D, BreadcrumbList as M, BreadcrumbPage as h, BreadcrumbSeparator as w } from "./ui/atoms/breadcrumb.js";
|
|
6
6
|
import { Button as B, buttonVariants as A } from "./ui/atoms/button.js";
|
|
7
7
|
import { Card as v, CardAction as P, CardContent as L, CardDescription as H, CardFooter as G, CardHeader as R, CardTitle as k } from "./ui/atoms/card.js";
|
|
8
8
|
import { ChartContainer as V, ChartLegend as z, ChartLegendContent as E, ChartStyle as O, ChartTooltip as U, ChartTooltipContent as j } from "./ui/atoms/chart.js";
|
|
9
9
|
import { Collapsible as J, CollapsibleContent as K, CollapsibleTrigger as N } from "./ui/atoms/collapsible.js";
|
|
10
10
|
import { Command as W, CommandDialog as X, CommandEmpty as Y, CommandGroup as Z, CommandInput as _, CommandItem as $, CommandList as ee, CommandSeparator as re, CommandShortcut as oe } from "./ui/atoms/command.js";
|
|
11
11
|
import { Dialog as ae, DialogClose as ne, DialogContent as ie, DialogDescription as le, DialogFooter as de, DialogHeader as pe, DialogOverlay as me, DialogPortal as Se, DialogTitle as be, DialogTrigger as ue } from "./ui/atoms/dialog.js";
|
|
12
|
-
import { DropdownMenu as ge, DropdownMenuCheckboxItem as ce, DropdownMenuContent as
|
|
13
|
-
import { Form as Le, FormControl as He, FormDescription as Ge, FormField as Re, FormItem as ke, FormLabel as ye, FormMessage as Ve,
|
|
14
|
-
import { HoverCard as
|
|
15
|
-
import { Input as
|
|
16
|
-
import { Label as
|
|
17
|
-
import { Popover as
|
|
18
|
-
import { Progress as
|
|
19
|
-
import { ResizableHandle as
|
|
20
|
-
import { ScrollArea as
|
|
21
|
-
import { Select as
|
|
12
|
+
import { DropdownMenu as ge, DropdownMenuCheckboxItem as ce, DropdownMenuContent as xe, DropdownMenuGroup as Te, DropdownMenuItem as fe, DropdownMenuLabel as se, DropdownMenuPortal as De, DropdownMenuRadioGroup as Me, DropdownMenuRadioItem as he, DropdownMenuSeparator as we, DropdownMenuShortcut as Fe, DropdownMenuSub as Be, DropdownMenuSubContent as Ae, DropdownMenuSubTrigger as Ie, DropdownMenuTrigger as ve } from "./ui/atoms/dropdown-menu.js";
|
|
13
|
+
import { Form as Le, FormControl as He, FormDescription as Ge, FormField as Re, FormItem as ke, FormLabel as ye, FormMessage as Ve, useFormField as ze } from "./ui/atoms/form.js";
|
|
14
|
+
import { HoverCard as Oe, HoverCardContent as Ue, HoverCardTrigger as je } from "./ui/atoms/hover-card.js";
|
|
15
|
+
import { Input as Je } from "./ui/atoms/input.js";
|
|
16
|
+
import { Label as Ne } from "./ui/atoms/label.js";
|
|
17
|
+
import { Popover as We, PopoverAnchor as Xe, PopoverContent as Ye, PopoverTrigger as Ze } from "./ui/atoms/popover.js";
|
|
18
|
+
import { Progress as $e } from "./ui/atoms/progress.js";
|
|
19
|
+
import { ResizableHandle as rr, ResizablePanel as or, ResizablePanelGroup as tr } from "./ui/atoms/resizable.js";
|
|
20
|
+
import { ScrollArea as nr, ScrollBar as ir } from "./ui/atoms/scroll-area.js";
|
|
21
|
+
import { Select as dr, SelectContent as pr, SelectGroup as mr, SelectItem as Sr, SelectLabel as br, SelectScrollDownButton as ur, SelectScrollUpButton as Cr, SelectSeparator as gr, SelectTrigger as cr, SelectValue as xr } from "./ui/atoms/select.js";
|
|
22
22
|
import { Separator as fr } from "./ui/atoms/separator.js";
|
|
23
|
-
import { Sheet as
|
|
24
|
-
import { Sidebar as
|
|
25
|
-
import { Skeleton as
|
|
26
|
-
import { Slider as
|
|
27
|
-
import { Toaster as
|
|
28
|
-
import { Switch as
|
|
29
|
-
import { Table as
|
|
30
|
-
import { Tabs as fo, TabsContent as
|
|
31
|
-
import { Textarea as
|
|
32
|
-
import { Toggle as
|
|
33
|
-
import { Tooltip as
|
|
23
|
+
import { Sheet as Dr, SheetClose as Mr, SheetContent as hr, SheetDescription as wr, SheetFooter as Fr, SheetHeader as Br, SheetTitle as Ar, SheetTrigger as Ir } from "./ui/atoms/sheet.js";
|
|
24
|
+
import { Sidebar as Pr, SidebarContent as Lr, SidebarFooter as Hr, SidebarGroup as Gr, SidebarGroupAction as Rr, SidebarGroupContent as kr, SidebarGroupLabel as yr, SidebarHeader as Vr, SidebarInput as zr, SidebarInset as Er, SidebarMenu as Or, SidebarMenuAction as Ur, SidebarMenuBadge as jr, SidebarMenuButton as qr, SidebarMenuItem as Jr, SidebarMenuSkeleton as Kr, SidebarMenuSub as Nr, SidebarMenuSubButton as Qr, SidebarMenuSubItem as Wr, SidebarProvider as Xr, SidebarRail as Yr, SidebarSeparator as Zr, SidebarTrigger as _r, useSidebar as $r } from "./ui/atoms/sidebar.js";
|
|
25
|
+
import { Skeleton as ro } from "./ui/atoms/skeleton.js";
|
|
26
|
+
import { Slider as to } from "./ui/atoms/slider.js";
|
|
27
|
+
import { Toaster as no } from "./ui/atoms/sonner.js";
|
|
28
|
+
import { Switch as lo } from "./ui/atoms/switch.js";
|
|
29
|
+
import { Table as mo, TableBody as So, TableCaption as bo, TableCell as uo, TableFooter as Co, TableHead as go, TableHeader as co, TableRow as xo } from "./ui/atoms/table.js";
|
|
30
|
+
import { Tabs as fo, TabsContent as so, TabsList as Do, TabsTrigger as Mo } from "./ui/atoms/tabs.js";
|
|
31
|
+
import { Textarea as wo } from "./ui/atoms/textarea.js";
|
|
32
|
+
import { Toggle as Bo, toggleVariants as Ao } from "./ui/atoms/toggle.js";
|
|
33
|
+
import { Tooltip as vo, TooltipContent as Po, TooltipProvider as Lo, TooltipTrigger as Ho } from "./ui/atoms/tooltip.js";
|
|
34
|
+
import { useFormContext as Ro } from "react-hook-form";
|
|
34
35
|
export {
|
|
35
36
|
o as Accordion,
|
|
36
37
|
t as AccordionContent,
|
|
@@ -43,9 +44,9 @@ export {
|
|
|
43
44
|
b as AvatarFallback,
|
|
44
45
|
u as AvatarImage,
|
|
45
46
|
g as Badge,
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
47
|
+
T as Breadcrumb,
|
|
48
|
+
f as BreadcrumbEllipsis,
|
|
49
|
+
s as BreadcrumbItem,
|
|
49
50
|
D as BreadcrumbLink,
|
|
50
51
|
M as BreadcrumbList,
|
|
51
52
|
h as BreadcrumbPage,
|
|
@@ -88,10 +89,10 @@ export {
|
|
|
88
89
|
ue as DialogTrigger,
|
|
89
90
|
ge as DropdownMenu,
|
|
90
91
|
ce as DropdownMenuCheckboxItem,
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
92
|
+
xe as DropdownMenuContent,
|
|
93
|
+
Te as DropdownMenuGroup,
|
|
94
|
+
fe as DropdownMenuItem,
|
|
95
|
+
se as DropdownMenuLabel,
|
|
95
96
|
De as DropdownMenuPortal,
|
|
96
97
|
Me as DropdownMenuRadioGroup,
|
|
97
98
|
he as DropdownMenuRadioItem,
|
|
@@ -108,89 +109,89 @@ export {
|
|
|
108
109
|
ke as FormItem,
|
|
109
110
|
ye as FormLabel,
|
|
110
111
|
Ve as FormMessage,
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
112
|
+
Oe as HoverCard,
|
|
113
|
+
Ue as HoverCardContent,
|
|
114
|
+
je as HoverCardTrigger,
|
|
115
|
+
Je as Input,
|
|
116
|
+
Ne as Label,
|
|
117
|
+
We as Popover,
|
|
118
|
+
Xe as PopoverAnchor,
|
|
119
|
+
Ye as PopoverContent,
|
|
120
|
+
Ze as PopoverTrigger,
|
|
121
|
+
$e as Progress,
|
|
122
|
+
rr as ResizableHandle,
|
|
123
|
+
or as ResizablePanel,
|
|
124
|
+
tr as ResizablePanelGroup,
|
|
125
|
+
nr as ScrollArea,
|
|
126
|
+
ir as ScrollBar,
|
|
127
|
+
dr as Select,
|
|
128
|
+
pr as SelectContent,
|
|
129
|
+
mr as SelectGroup,
|
|
130
|
+
Sr as SelectItem,
|
|
131
|
+
br as SelectLabel,
|
|
132
|
+
ur as SelectScrollDownButton,
|
|
133
|
+
Cr as SelectScrollUpButton,
|
|
134
|
+
gr as SelectSeparator,
|
|
135
|
+
cr as SelectTrigger,
|
|
135
136
|
xr as SelectValue,
|
|
136
137
|
fr as Separator,
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
138
|
+
Dr as Sheet,
|
|
139
|
+
Mr as SheetClose,
|
|
140
|
+
hr as SheetContent,
|
|
141
|
+
wr as SheetDescription,
|
|
142
|
+
Fr as SheetFooter,
|
|
143
|
+
Br as SheetHeader,
|
|
144
|
+
Ar as SheetTitle,
|
|
145
|
+
Ir as SheetTrigger,
|
|
146
|
+
Pr as Sidebar,
|
|
147
|
+
Lr as SidebarContent,
|
|
148
|
+
Hr as SidebarFooter,
|
|
149
|
+
Gr as SidebarGroup,
|
|
150
|
+
Rr as SidebarGroupAction,
|
|
151
|
+
kr as SidebarGroupContent,
|
|
152
|
+
yr as SidebarGroupLabel,
|
|
153
|
+
Vr as SidebarHeader,
|
|
154
|
+
zr as SidebarInput,
|
|
155
|
+
Er as SidebarInset,
|
|
156
|
+
Or as SidebarMenu,
|
|
157
|
+
Ur as SidebarMenuAction,
|
|
158
|
+
jr as SidebarMenuBadge,
|
|
159
|
+
qr as SidebarMenuButton,
|
|
160
|
+
Jr as SidebarMenuItem,
|
|
161
|
+
Kr as SidebarMenuSkeleton,
|
|
162
|
+
Nr as SidebarMenuSub,
|
|
163
|
+
Qr as SidebarMenuSubButton,
|
|
164
|
+
Wr as SidebarMenuSubItem,
|
|
165
|
+
Xr as SidebarProvider,
|
|
166
|
+
Yr as SidebarRail,
|
|
167
|
+
Zr as SidebarSeparator,
|
|
168
|
+
_r as SidebarTrigger,
|
|
169
|
+
ro as Skeleton,
|
|
170
|
+
to as Slider,
|
|
171
|
+
lo as Switch,
|
|
172
|
+
mo as Table,
|
|
173
|
+
So as TableBody,
|
|
174
|
+
bo as TableCaption,
|
|
175
|
+
uo as TableCell,
|
|
176
|
+
Co as TableFooter,
|
|
177
|
+
go as TableHead,
|
|
178
|
+
co as TableHeader,
|
|
178
179
|
xo as TableRow,
|
|
179
180
|
fo as Tabs,
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
181
|
+
so as TabsContent,
|
|
182
|
+
Do as TabsList,
|
|
183
|
+
Mo as TabsTrigger,
|
|
184
|
+
wo as Textarea,
|
|
185
|
+
no as Toaster,
|
|
186
|
+
Bo as Toggle,
|
|
187
|
+
vo as Tooltip,
|
|
188
|
+
Po as TooltipContent,
|
|
189
|
+
Lo as TooltipProvider,
|
|
190
|
+
Ho as TooltipTrigger,
|
|
190
191
|
c as badgeVariants,
|
|
191
192
|
A as buttonVariants,
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
193
|
+
Ao as toggleVariants,
|
|
194
|
+
Ro as useFormContext,
|
|
195
|
+
ze as useFormField,
|
|
196
|
+
$r as useSidebar
|
|
196
197
|
};
|
|
@@ -9,8 +9,8 @@ import { P as M } from "../../../index-CpDnqHCm.js";
|
|
|
9
9
|
import { c as V, R as oe, T as re, b as te } from "../../../index-CtSXVDca.js";
|
|
10
10
|
import { u as ne } from "../../../index-Cv867SGx.js";
|
|
11
11
|
import { u as ce } from "../../../index-ByaXH_ih.js";
|
|
12
|
+
import { ChevronDownIcon as ae } from "lucide-react";
|
|
12
13
|
import { c as S } from "../../../utils-CRiPKpXj.js";
|
|
13
|
-
import { C as ae } from "../../../chevron-down-DmZMdOiC.js";
|
|
14
14
|
var d = "Accordion", ie = ["Home", "End", "ArrowDown", "ArrowUp", "ArrowLeft", "ArrowRight"], [E, se, le] = X(d), [b, Oe] = W(d, [
|
|
15
15
|
le,
|
|
16
16
|
V
|
|
@@ -1,130 +1,248 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import * as
|
|
3
|
-
import
|
|
4
|
-
import {
|
|
5
|
-
import { u as
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import { c as
|
|
9
|
-
var y =
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
1
|
+
import { jsx as g } from "react/jsx-runtime";
|
|
2
|
+
import * as _ from "react";
|
|
3
|
+
import N from "react";
|
|
4
|
+
import { c as H } from "../../../index-DFZozV_h.js";
|
|
5
|
+
import { u as U } from "../../../index-0ioNhtNM.js";
|
|
6
|
+
import { u as O } from "../../../index-CCKe-Mpx.js";
|
|
7
|
+
import { P as w } from "../../../index-CpDnqHCm.js";
|
|
8
|
+
import { c as x } from "../../../utils-CRiPKpXj.js";
|
|
9
|
+
var h = { exports: {} }, y = {};
|
|
10
|
+
/**
|
|
11
|
+
* @license React
|
|
12
|
+
* use-sync-external-store-shim.production.js
|
|
13
|
+
*
|
|
14
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
15
|
+
*
|
|
16
|
+
* This source code is licensed under the MIT license found in the
|
|
17
|
+
* LICENSE file in the root directory of this source tree.
|
|
18
|
+
*/
|
|
19
|
+
var I;
|
|
20
|
+
function q() {
|
|
21
|
+
if (I) return y;
|
|
22
|
+
I = 1;
|
|
23
|
+
var e = N;
|
|
24
|
+
function t(a, d) {
|
|
25
|
+
return a === d && (a !== 0 || 1 / a === 1 / d) || a !== a && d !== d;
|
|
26
|
+
}
|
|
27
|
+
var i = typeof Object.is == "function" ? Object.is : t, c = e.useState, o = e.useEffect, r = e.useLayoutEffect, S = e.useDebugValue;
|
|
28
|
+
function f(a, d) {
|
|
29
|
+
var n = d(), u = c({ inst: { value: n, getSnapshot: d } }), s = u[0].inst, p = u[1];
|
|
30
|
+
return r(
|
|
31
|
+
function() {
|
|
32
|
+
s.value = n, s.getSnapshot = d, l(s) && p({ inst: s });
|
|
33
|
+
},
|
|
34
|
+
[a, n, d]
|
|
35
|
+
), o(
|
|
36
|
+
function() {
|
|
37
|
+
return l(s) && p({ inst: s }), a(function() {
|
|
38
|
+
l(s) && p({ inst: s });
|
|
39
|
+
});
|
|
40
|
+
},
|
|
41
|
+
[a]
|
|
42
|
+
), S(n), n;
|
|
43
|
+
}
|
|
44
|
+
function l(a) {
|
|
45
|
+
var d = a.getSnapshot;
|
|
46
|
+
a = a.value;
|
|
47
|
+
try {
|
|
48
|
+
var n = d();
|
|
49
|
+
return !i(a, n);
|
|
50
|
+
} catch {
|
|
51
|
+
return !0;
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
function v(a, d) {
|
|
55
|
+
return d();
|
|
56
|
+
}
|
|
57
|
+
var E = typeof window > "u" || typeof window.document > "u" || typeof window.document.createElement > "u" ? v : f;
|
|
58
|
+
return y.useSyncExternalStore = e.useSyncExternalStore !== void 0 ? e.useSyncExternalStore : E, y;
|
|
59
|
+
}
|
|
60
|
+
var A = {};
|
|
61
|
+
/**
|
|
62
|
+
* @license React
|
|
63
|
+
* use-sync-external-store-shim.development.js
|
|
64
|
+
*
|
|
65
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
66
|
+
*
|
|
67
|
+
* This source code is licensed under the MIT license found in the
|
|
68
|
+
* LICENSE file in the root directory of this source tree.
|
|
69
|
+
*/
|
|
70
|
+
var C;
|
|
71
|
+
function B() {
|
|
72
|
+
return C || (C = 1, process.env.NODE_ENV !== "production" && function() {
|
|
73
|
+
function e(n, u) {
|
|
74
|
+
return n === u && (n !== 0 || 1 / n === 1 / u) || n !== n && u !== u;
|
|
75
|
+
}
|
|
76
|
+
function t(n, u) {
|
|
77
|
+
E || o.startTransition === void 0 || (E = !0, console.error(
|
|
78
|
+
"You are using an outdated, pre-release alpha of React 18 that does not support useSyncExternalStore. The use-sync-external-store shim will not work correctly. Upgrade to a newer pre-release."
|
|
79
|
+
));
|
|
80
|
+
var s = u();
|
|
81
|
+
if (!a) {
|
|
82
|
+
var p = u();
|
|
83
|
+
r(s, p) || (console.error(
|
|
84
|
+
"The result of getSnapshot should be cached to avoid an infinite loop"
|
|
85
|
+
), a = !0);
|
|
86
|
+
}
|
|
87
|
+
p = S({
|
|
88
|
+
inst: { value: s, getSnapshot: u }
|
|
89
|
+
});
|
|
90
|
+
var m = p[0].inst, L = p[1];
|
|
91
|
+
return l(
|
|
92
|
+
function() {
|
|
93
|
+
m.value = s, m.getSnapshot = u, i(m) && L({ inst: m });
|
|
94
|
+
},
|
|
95
|
+
[n, s, u]
|
|
96
|
+
), f(
|
|
97
|
+
function() {
|
|
98
|
+
return i(m) && L({ inst: m }), n(function() {
|
|
99
|
+
i(m) && L({ inst: m });
|
|
100
|
+
});
|
|
101
|
+
},
|
|
102
|
+
[n]
|
|
103
|
+
), v(s), s;
|
|
104
|
+
}
|
|
105
|
+
function i(n) {
|
|
106
|
+
var u = n.getSnapshot;
|
|
107
|
+
n = n.value;
|
|
108
|
+
try {
|
|
109
|
+
var s = u();
|
|
110
|
+
return !r(n, s);
|
|
111
|
+
} catch {
|
|
112
|
+
return !0;
|
|
113
|
+
}
|
|
114
|
+
}
|
|
115
|
+
function c(n, u) {
|
|
116
|
+
return u();
|
|
117
|
+
}
|
|
118
|
+
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ < "u" && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart == "function" && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());
|
|
119
|
+
var o = N, r = typeof Object.is == "function" ? Object.is : e, S = o.useState, f = o.useEffect, l = o.useLayoutEffect, v = o.useDebugValue, E = !1, a = !1, d = typeof window > "u" || typeof window.document > "u" || typeof window.document.createElement > "u" ? c : t;
|
|
120
|
+
A.useSyncExternalStore = o.useSyncExternalStore !== void 0 ? o.useSyncExternalStore : d, typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ < "u" && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop == "function" && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error());
|
|
121
|
+
}()), A;
|
|
122
|
+
}
|
|
123
|
+
var T;
|
|
124
|
+
function K() {
|
|
125
|
+
return T || (T = 1, process.env.NODE_ENV === "production" ? h.exports = q() : h.exports = B()), h.exports;
|
|
126
|
+
}
|
|
127
|
+
var $ = K();
|
|
128
|
+
function F() {
|
|
129
|
+
return $.useSyncExternalStore(
|
|
130
|
+
P,
|
|
13
131
|
() => !0,
|
|
14
132
|
() => !1
|
|
15
133
|
);
|
|
16
134
|
}
|
|
17
|
-
function
|
|
135
|
+
function P() {
|
|
18
136
|
return () => {
|
|
19
137
|
};
|
|
20
138
|
}
|
|
21
|
-
var
|
|
22
|
-
(
|
|
23
|
-
const { __scopeAvatar:
|
|
24
|
-
return /* @__PURE__ */
|
|
25
|
-
|
|
139
|
+
var R = "Avatar", [z, ue] = H(R), [W, D] = z(R), k = _.forwardRef(
|
|
140
|
+
(e, t) => {
|
|
141
|
+
const { __scopeAvatar: i, ...c } = e, [o, r] = _.useState("idle");
|
|
142
|
+
return /* @__PURE__ */ g(
|
|
143
|
+
W,
|
|
26
144
|
{
|
|
27
|
-
scope:
|
|
145
|
+
scope: i,
|
|
28
146
|
imageLoadingStatus: o,
|
|
29
|
-
onImageLoadingStatusChange:
|
|
30
|
-
children: /* @__PURE__ */
|
|
147
|
+
onImageLoadingStatusChange: r,
|
|
148
|
+
children: /* @__PURE__ */ g(w.span, { ...c, ref: t })
|
|
31
149
|
}
|
|
32
150
|
);
|
|
33
151
|
}
|
|
34
152
|
);
|
|
35
|
-
|
|
36
|
-
var
|
|
37
|
-
(
|
|
38
|
-
const { __scopeAvatar:
|
|
39
|
-
}, ...
|
|
40
|
-
o(
|
|
153
|
+
k.displayName = R;
|
|
154
|
+
var G = "AvatarImage", V = _.forwardRef(
|
|
155
|
+
(e, t) => {
|
|
156
|
+
const { __scopeAvatar: i, src: c, onLoadingStatusChange: o = () => {
|
|
157
|
+
}, ...r } = e, S = D(G, i), f = Y(c, r), l = U((v) => {
|
|
158
|
+
o(v), S.onImageLoadingStatusChange(v);
|
|
41
159
|
});
|
|
42
|
-
return
|
|
43
|
-
|
|
44
|
-
}, [
|
|
160
|
+
return O(() => {
|
|
161
|
+
f !== "idle" && l(f);
|
|
162
|
+
}, [f, l]), f === "loaded" ? /* @__PURE__ */ g(w.img, { ...r, ref: t, src: c }) : null;
|
|
45
163
|
}
|
|
46
164
|
);
|
|
47
|
-
|
|
48
|
-
var
|
|
49
|
-
(
|
|
50
|
-
const { __scopeAvatar:
|
|
51
|
-
return
|
|
52
|
-
if (
|
|
53
|
-
const
|
|
54
|
-
return () => window.clearTimeout(
|
|
165
|
+
V.displayName = G;
|
|
166
|
+
var M = "AvatarFallback", j = _.forwardRef(
|
|
167
|
+
(e, t) => {
|
|
168
|
+
const { __scopeAvatar: i, delayMs: c, ...o } = e, r = D(M, i), [S, f] = _.useState(c === void 0);
|
|
169
|
+
return _.useEffect(() => {
|
|
170
|
+
if (c !== void 0) {
|
|
171
|
+
const l = window.setTimeout(() => f(!0), c);
|
|
172
|
+
return () => window.clearTimeout(l);
|
|
55
173
|
}
|
|
56
|
-
}, [
|
|
174
|
+
}, [c]), S && r.imageLoadingStatus !== "loaded" ? /* @__PURE__ */ g(w.span, { ...o, ref: t }) : null;
|
|
57
175
|
}
|
|
58
176
|
);
|
|
59
|
-
|
|
60
|
-
function
|
|
61
|
-
return
|
|
177
|
+
j.displayName = M;
|
|
178
|
+
function b(e, t) {
|
|
179
|
+
return e ? t ? (e.src !== t && (e.src = t), e.complete && e.naturalWidth > 0 ? "loaded" : "loading") : "error" : "idle";
|
|
62
180
|
}
|
|
63
|
-
function
|
|
64
|
-
const
|
|
65
|
-
() =>
|
|
181
|
+
function Y(e, { referrerPolicy: t, crossOrigin: i }) {
|
|
182
|
+
const c = F(), o = _.useRef(null), r = c ? (o.current || (o.current = new window.Image()), o.current) : null, [S, f] = _.useState(
|
|
183
|
+
() => b(r, e)
|
|
66
184
|
);
|
|
67
|
-
return
|
|
68
|
-
|
|
69
|
-
}, [
|
|
70
|
-
const
|
|
71
|
-
|
|
185
|
+
return O(() => {
|
|
186
|
+
f(b(r, e));
|
|
187
|
+
}, [r, e]), O(() => {
|
|
188
|
+
const l = (a) => () => {
|
|
189
|
+
f(a);
|
|
72
190
|
};
|
|
73
|
-
if (!
|
|
74
|
-
const
|
|
75
|
-
return
|
|
76
|
-
|
|
191
|
+
if (!r) return;
|
|
192
|
+
const v = l("loaded"), E = l("error");
|
|
193
|
+
return r.addEventListener("load", v), r.addEventListener("error", E), t && (r.referrerPolicy = t), typeof i == "string" && (r.crossOrigin = i), () => {
|
|
194
|
+
r.removeEventListener("load", v), r.removeEventListener("error", E);
|
|
77
195
|
};
|
|
78
|
-
}, [
|
|
196
|
+
}, [r, i, t]), S;
|
|
79
197
|
}
|
|
80
|
-
var
|
|
81
|
-
function
|
|
82
|
-
className:
|
|
83
|
-
...
|
|
198
|
+
var J = k, Q = V, X = j;
|
|
199
|
+
function se({
|
|
200
|
+
className: e,
|
|
201
|
+
...t
|
|
84
202
|
}) {
|
|
85
|
-
return /* @__PURE__ */
|
|
86
|
-
|
|
203
|
+
return /* @__PURE__ */ g(
|
|
204
|
+
J,
|
|
87
205
|
{
|
|
88
|
-
className:
|
|
206
|
+
className: x(
|
|
89
207
|
"relative flex size-8 shrink-0 overflow-hidden rounded-full",
|
|
90
|
-
|
|
208
|
+
e
|
|
91
209
|
),
|
|
92
210
|
"data-slot": "avatar",
|
|
93
|
-
...
|
|
211
|
+
...t
|
|
94
212
|
}
|
|
95
213
|
);
|
|
96
214
|
}
|
|
97
|
-
function
|
|
98
|
-
className:
|
|
99
|
-
...
|
|
215
|
+
function ie({
|
|
216
|
+
className: e,
|
|
217
|
+
...t
|
|
100
218
|
}) {
|
|
101
|
-
return /* @__PURE__ */
|
|
102
|
-
|
|
219
|
+
return /* @__PURE__ */ g(
|
|
220
|
+
Q,
|
|
103
221
|
{
|
|
104
|
-
className:
|
|
222
|
+
className: x("aspect-square size-full", e),
|
|
105
223
|
"data-slot": "avatar-image",
|
|
106
|
-
...
|
|
224
|
+
...t
|
|
107
225
|
}
|
|
108
226
|
);
|
|
109
227
|
}
|
|
110
|
-
function
|
|
111
|
-
className:
|
|
112
|
-
...
|
|
228
|
+
function ce({
|
|
229
|
+
className: e,
|
|
230
|
+
...t
|
|
113
231
|
}) {
|
|
114
|
-
return /* @__PURE__ */
|
|
115
|
-
|
|
232
|
+
return /* @__PURE__ */ g(
|
|
233
|
+
X,
|
|
116
234
|
{
|
|
117
|
-
className:
|
|
235
|
+
className: x(
|
|
118
236
|
"flex size-full items-center justify-center rounded-full bg-muted",
|
|
119
|
-
|
|
237
|
+
e
|
|
120
238
|
),
|
|
121
239
|
"data-slot": "avatar-fallback",
|
|
122
|
-
...
|
|
240
|
+
...t
|
|
123
241
|
}
|
|
124
242
|
);
|
|
125
243
|
}
|
|
126
244
|
export {
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
245
|
+
se as Avatar,
|
|
246
|
+
ce as AvatarFallback,
|
|
247
|
+
ie as AvatarImage
|
|
130
248
|
};
|