@dimasbaguspm/versaur 0.0.44 → 0.0.46
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/js/forms/index.js +18 -20
- package/dist/js/{image-rectangle-DjuCYHbk.js → image-rectangle-B4nXH4Q5.js} +990 -1158
- package/dist/js/index.js +60 -64
- package/dist/js/layouts/index.js +1 -1
- package/dist/js/navigation/index.js +1 -1
- package/dist/js/overlays/index.js +5 -6
- package/dist/js/primitive/index.js +25 -26
- package/dist/js/{tabs-CiZ2DPDD.js → tabs-BAzThVka.js} +1 -1
- package/dist/js/{bottom-sheet-input-C9Ht9cxQ.js → time-picker-input-DrZ4dyEB.js} +875 -800
- package/dist/js/tooltip-D6fUigp2.js +691 -0
- package/dist/js/{top-bar-CKo6k1eW.js → top-bar-Dx0JVXms.js} +1 -1
- package/dist/types/forms/index.d.ts +7 -9
- package/dist/types/forms/pin-field/index.d.ts +2 -0
- package/dist/types/forms/pin-field/pin-field.d.ts +9 -0
- package/dist/types/forms/pin-field/types.d.ts +86 -0
- package/dist/types/primitive/action-card/action-card.atoms.d.ts +18 -0
- package/dist/types/primitive/action-card/action-card.d.ts +4 -0
- package/dist/types/primitive/action-card/index.d.ts +2 -0
- package/dist/types/primitive/action-card/types.d.ts +57 -0
- package/dist/types/primitive/brand/types.d.ts +1 -1
- package/dist/types/primitive/index.d.ts +1 -2
- package/dist/utils/enforce-subpath-import.js +2 -5
- package/package.json +1 -1
- package/dist/js/bottom-sheet-BSN0J8ji.js +0 -615
- package/dist/js/tooltip-nOXyn9AX.js +0 -81
- package/dist/types/forms/bottom-sheet-input/bottom-sheet-input.d.ts +0 -7
- package/dist/types/forms/bottom-sheet-input/index.d.ts +0 -2
- package/dist/types/forms/bottom-sheet-input/types.d.ts +0 -17
- package/dist/types/forms/drawer-input/drawer-input.d.ts +0 -6
- package/dist/types/forms/drawer-input/index.d.ts +0 -2
- package/dist/types/forms/drawer-input/types.d.ts +0 -18
- package/dist/types/forms/modal-input/index.d.ts +0 -2
- package/dist/types/forms/modal-input/modal-input.d.ts +0 -6
- package/dist/types/forms/modal-input/types.d.ts +0 -18
- package/dist/types/primitive/button-float/button-float.d.ts +0 -8
- package/dist/types/primitive/button-float/index.d.ts +0 -2
- package/dist/types/primitive/button-float/types.d.ts +0 -31
- package/dist/types/primitive/button-float/use-floating-position.d.ts +0 -12
- package/dist/types/primitive/calculator/calculator.atoms.d.ts +0 -2
- package/dist/types/primitive/calculator/calculator.d.ts +0 -2
- package/dist/types/primitive/calculator/index.d.ts +0 -2
- package/dist/types/primitive/calculator/types.d.ts +0 -29
- package/dist/types/primitive/calculator/use-calculator.d.ts +0 -11
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
import { c as
|
|
2
|
-
import * as
|
|
3
|
-
import
|
|
4
|
-
import { ChevronDown, CheckIcon, EllipsisVerticalIcon
|
|
5
|
-
import
|
|
6
|
-
import { S as
|
|
7
|
-
const
|
|
1
|
+
import { c as w, j as r, a as u } from "./index-DOdDlCoL.js";
|
|
2
|
+
import * as a from "react";
|
|
3
|
+
import H, { createContext as P, useContext as F, forwardRef as f, useState as L, useEffect as A, useCallback as J, useRef as _, useId as le, cloneElement as ce } from "react";
|
|
4
|
+
import { ChevronDown as de, ChevronRight as ge, CheckIcon as he, EllipsisVerticalIcon as ue, XIcon as fe, ImageOff as be } from "lucide-react";
|
|
5
|
+
import me from "react-dom";
|
|
6
|
+
import { S as we } from "./skeleton-BNZyaRjo.js";
|
|
7
|
+
const K = P(
|
|
8
8
|
null
|
|
9
|
-
),
|
|
10
|
-
const e =
|
|
9
|
+
), Q = () => {
|
|
10
|
+
const e = F(K);
|
|
11
11
|
if (!e)
|
|
12
12
|
throw new Error(
|
|
13
13
|
"Accordion compound components must be used within Accordion"
|
|
14
14
|
);
|
|
15
15
|
return e;
|
|
16
|
-
},
|
|
16
|
+
}, ve = w(
|
|
17
17
|
"border-b border-border bg-background overflow-hidden",
|
|
18
18
|
{
|
|
19
19
|
variants: {
|
|
@@ -26,7 +26,7 @@ const AccordionContext = createContext(
|
|
|
26
26
|
disabled: !1
|
|
27
27
|
}
|
|
28
28
|
}
|
|
29
|
-
),
|
|
29
|
+
), xe = w(
|
|
30
30
|
"flex items-center justify-between w-full p-4 text-left transition-colors duration-200 focus:outline-none focus-visible:ring-2 focus-visible:ring-primary-light focus-visible:ring-inset",
|
|
31
31
|
{
|
|
32
32
|
variants: {
|
|
@@ -44,7 +44,7 @@ const AccordionContext = createContext(
|
|
|
44
44
|
isOpen: !1
|
|
45
45
|
}
|
|
46
46
|
}
|
|
47
|
-
),
|
|
47
|
+
), pe = w(
|
|
48
48
|
"overflow-hidden transition-all duration-300",
|
|
49
49
|
{
|
|
50
50
|
variants: {
|
|
@@ -57,7 +57,7 @@ const AccordionContext = createContext(
|
|
|
57
57
|
isOpen: !1
|
|
58
58
|
}
|
|
59
59
|
}
|
|
60
|
-
),
|
|
60
|
+
), ye = w("p-4 pt-0"), je = w("transition-transform duration-200", {
|
|
61
61
|
variants: {
|
|
62
62
|
isOpen: {
|
|
63
63
|
true: "rotate-180",
|
|
@@ -67,7 +67,7 @@ const AccordionContext = createContext(
|
|
|
67
67
|
defaultVariants: {
|
|
68
68
|
isOpen: !1
|
|
69
69
|
}
|
|
70
|
-
}),
|
|
70
|
+
}), ke = w("", {
|
|
71
71
|
variants: {
|
|
72
72
|
color: {
|
|
73
73
|
primary: "text-primary",
|
|
@@ -121,7 +121,7 @@ const AccordionContext = createContext(
|
|
|
121
121
|
level: {
|
|
122
122
|
1: "font-bold text-2xl leading-loose",
|
|
123
123
|
2: "font-semibold text-xl leading-relaxed",
|
|
124
|
-
3: "font-
|
|
124
|
+
3: "font-semibold text-lg leading-relaxed",
|
|
125
125
|
4: "font-bold text-sm leading-normal",
|
|
126
126
|
5: "font-semibold text-sm leading-normal",
|
|
127
127
|
6: "font-medium text-xs leading-normal"
|
|
@@ -138,48 +138,48 @@ const AccordionContext = createContext(
|
|
|
138
138
|
ellipsis: !1,
|
|
139
139
|
level: 1
|
|
140
140
|
}
|
|
141
|
-
}),
|
|
141
|
+
}), Z = f(
|
|
142
142
|
({
|
|
143
143
|
level: e = 3,
|
|
144
|
-
color: t = "
|
|
145
|
-
hasUnderline:
|
|
146
|
-
isCapitalize:
|
|
144
|
+
color: t = "black",
|
|
145
|
+
hasUnderline: i = !1,
|
|
146
|
+
isCapitalize: n = !1,
|
|
147
147
|
hasMargin: s = !1,
|
|
148
|
-
align:
|
|
149
|
-
italic:
|
|
150
|
-
clamp:
|
|
151
|
-
ellipsis:
|
|
152
|
-
className:
|
|
153
|
-
children:
|
|
154
|
-
...
|
|
155
|
-
},
|
|
156
|
-
const
|
|
157
|
-
return /* @__PURE__ */
|
|
158
|
-
|
|
159
|
-
{
|
|
160
|
-
ref:
|
|
161
|
-
className:
|
|
162
|
-
|
|
148
|
+
align: o = "left",
|
|
149
|
+
italic: l = !1,
|
|
150
|
+
clamp: d = "none",
|
|
151
|
+
ellipsis: g = !1,
|
|
152
|
+
className: h,
|
|
153
|
+
children: m,
|
|
154
|
+
...c
|
|
155
|
+
}, v) => {
|
|
156
|
+
const y = `h${e}`;
|
|
157
|
+
return /* @__PURE__ */ r.jsx(
|
|
158
|
+
y,
|
|
159
|
+
{
|
|
160
|
+
ref: v,
|
|
161
|
+
className: u(
|
|
162
|
+
ke({
|
|
163
163
|
color: t,
|
|
164
|
-
hasUnderline:
|
|
165
|
-
isCapitalize:
|
|
164
|
+
hasUnderline: i,
|
|
165
|
+
isCapitalize: n,
|
|
166
166
|
hasMargin: s,
|
|
167
|
-
align:
|
|
168
|
-
italic:
|
|
169
|
-
clamp:
|
|
170
|
-
ellipsis:
|
|
167
|
+
align: o,
|
|
168
|
+
italic: l,
|
|
169
|
+
clamp: d,
|
|
170
|
+
ellipsis: g,
|
|
171
171
|
level: e
|
|
172
172
|
}),
|
|
173
|
-
|
|
173
|
+
h
|
|
174
174
|
),
|
|
175
|
-
...
|
|
176
|
-
children:
|
|
175
|
+
...c,
|
|
176
|
+
children: m
|
|
177
177
|
}
|
|
178
178
|
);
|
|
179
179
|
}
|
|
180
180
|
);
|
|
181
|
-
|
|
182
|
-
const
|
|
181
|
+
Z.displayName = "Heading";
|
|
182
|
+
const Ne = w("inline-flex items-center justify-center", {
|
|
183
183
|
variants: {
|
|
184
184
|
size: {
|
|
185
185
|
xs: "w-3 h-3",
|
|
@@ -209,116 +209,366 @@ const iconVariants = cva("inline-flex items-center justify-center", {
|
|
|
209
209
|
size: "md",
|
|
210
210
|
color: "primary"
|
|
211
211
|
}
|
|
212
|
-
}),
|
|
213
|
-
return /* @__PURE__ */
|
|
212
|
+
}), R = H.forwardRef(function({ as: t, color: i = "primary", size: n = "md", className: s, ...o }, l) {
|
|
213
|
+
return /* @__PURE__ */ r.jsx(
|
|
214
214
|
t,
|
|
215
215
|
{
|
|
216
|
-
ref:
|
|
217
|
-
className:
|
|
218
|
-
...
|
|
216
|
+
ref: l,
|
|
217
|
+
className: Ne({ color: i, size: n, className: s }),
|
|
218
|
+
...o
|
|
219
219
|
}
|
|
220
220
|
);
|
|
221
|
-
}),
|
|
222
|
-
return /* @__PURE__ */
|
|
223
|
-
|
|
221
|
+
}), Ee = f(function({ className: t, children: i, ...n }, s) {
|
|
222
|
+
return /* @__PURE__ */ r.jsx(
|
|
223
|
+
Z,
|
|
224
224
|
{
|
|
225
225
|
ref: s,
|
|
226
226
|
level: 4,
|
|
227
|
-
className:
|
|
228
|
-
...
|
|
227
|
+
className: u("font-medium", t),
|
|
228
|
+
...n,
|
|
229
229
|
color: "black",
|
|
230
|
-
children:
|
|
230
|
+
children: i
|
|
231
231
|
}
|
|
232
232
|
);
|
|
233
|
-
}),
|
|
234
|
-
const { isOpen:
|
|
235
|
-
return /* @__PURE__ */
|
|
233
|
+
}), Ce = f(function({ className: t, children: i, ...n }, s) {
|
|
234
|
+
const { isOpen: o } = Q();
|
|
235
|
+
return /* @__PURE__ */ r.jsx(
|
|
236
236
|
"div",
|
|
237
237
|
{
|
|
238
238
|
ref: s,
|
|
239
|
-
className:
|
|
240
|
-
...
|
|
241
|
-
children: /* @__PURE__ */
|
|
239
|
+
className: u(pe({ isOpen: o }), t),
|
|
240
|
+
...n,
|
|
241
|
+
children: /* @__PURE__ */ r.jsx("div", { className: ye(), children: i })
|
|
242
242
|
}
|
|
243
243
|
);
|
|
244
|
-
}),
|
|
245
|
-
const { isOpen: s } =
|
|
246
|
-
return /* @__PURE__ */
|
|
247
|
-
|
|
244
|
+
}), ee = f(function({ as: t, ...i }, n) {
|
|
245
|
+
const { isOpen: s } = Q();
|
|
246
|
+
return /* @__PURE__ */ r.jsx(
|
|
247
|
+
R,
|
|
248
248
|
{
|
|
249
|
-
ref:
|
|
249
|
+
ref: n,
|
|
250
250
|
as: t,
|
|
251
251
|
color: "ghost",
|
|
252
252
|
size: "sm",
|
|
253
|
-
className:
|
|
254
|
-
...
|
|
253
|
+
className: je({ isOpen: s }),
|
|
254
|
+
...i
|
|
255
255
|
}
|
|
256
256
|
);
|
|
257
|
-
}),
|
|
257
|
+
}), ze = f(
|
|
258
258
|
function({
|
|
259
259
|
title: t,
|
|
260
|
-
subtitle:
|
|
261
|
-
isDefaultOpen:
|
|
260
|
+
subtitle: i,
|
|
261
|
+
isDefaultOpen: n = !1,
|
|
262
262
|
disabled: s = !1,
|
|
263
|
-
hasMargin:
|
|
264
|
-
className:
|
|
265
|
-
children:
|
|
266
|
-
...
|
|
267
|
-
},
|
|
268
|
-
const [
|
|
269
|
-
s ||
|
|
270
|
-
},
|
|
271
|
-
isOpen:
|
|
272
|
-
toggle:
|
|
263
|
+
hasMargin: o,
|
|
264
|
+
className: l,
|
|
265
|
+
children: d,
|
|
266
|
+
...g
|
|
267
|
+
}, h) {
|
|
268
|
+
const [m, c] = L(n), v = () => {
|
|
269
|
+
s || c((j) => !j);
|
|
270
|
+
}, y = {
|
|
271
|
+
isOpen: m,
|
|
272
|
+
toggle: v,
|
|
273
273
|
disabled: s
|
|
274
274
|
};
|
|
275
|
-
return /* @__PURE__ */
|
|
275
|
+
return /* @__PURE__ */ r.jsx(K.Provider, { value: y, children: /* @__PURE__ */ r.jsxs(
|
|
276
276
|
"div",
|
|
277
277
|
{
|
|
278
|
-
ref:
|
|
279
|
-
className:
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
278
|
+
ref: h,
|
|
279
|
+
className: u(
|
|
280
|
+
ve({ disabled: s }),
|
|
281
|
+
l,
|
|
282
|
+
o && "mb-4"
|
|
283
283
|
),
|
|
284
|
-
...
|
|
284
|
+
...g,
|
|
285
285
|
children: [
|
|
286
|
-
/* @__PURE__ */
|
|
286
|
+
/* @__PURE__ */ r.jsx(
|
|
287
287
|
"div",
|
|
288
288
|
{
|
|
289
289
|
role: "button",
|
|
290
|
-
className:
|
|
291
|
-
onClick:
|
|
290
|
+
className: xe({ disabled: s, isOpen: m }),
|
|
291
|
+
onClick: v,
|
|
292
292
|
"aria-disabled": s,
|
|
293
|
-
"aria-expanded":
|
|
294
|
-
children: /* @__PURE__ */
|
|
295
|
-
/* @__PURE__ */
|
|
296
|
-
/* @__PURE__ */
|
|
297
|
-
|
|
293
|
+
"aria-expanded": m,
|
|
294
|
+
children: /* @__PURE__ */ r.jsxs("div", { className: "flex items-center justify-between w-full gap-2", children: [
|
|
295
|
+
/* @__PURE__ */ r.jsxs("div", { className: "flex items-center gap-3 flex-grow", children: [
|
|
296
|
+
/* @__PURE__ */ r.jsx("div", { className: "flex-1", children: t }),
|
|
297
|
+
i && /* @__PURE__ */ r.jsx("div", { className: "flex-shrink-0", children: i })
|
|
298
298
|
] }),
|
|
299
|
-
/* @__PURE__ */
|
|
299
|
+
/* @__PURE__ */ r.jsx(ee, { as: de })
|
|
300
300
|
] })
|
|
301
301
|
}
|
|
302
302
|
),
|
|
303
|
-
/* @__PURE__ */
|
|
303
|
+
/* @__PURE__ */ r.jsx(
|
|
304
304
|
"div",
|
|
305
305
|
{
|
|
306
|
-
className:
|
|
306
|
+
className: u(
|
|
307
307
|
"overflow-hidden transition-all duration-300",
|
|
308
|
-
|
|
308
|
+
m ? "max-h-screen opacity-100" : "max-h-0 opacity-0"
|
|
309
309
|
),
|
|
310
|
-
children: /* @__PURE__ */
|
|
310
|
+
children: /* @__PURE__ */ r.jsx("div", { className: "p-4 pt-2", children: d })
|
|
311
311
|
}
|
|
312
312
|
)
|
|
313
313
|
]
|
|
314
314
|
}
|
|
315
315
|
) });
|
|
316
316
|
}
|
|
317
|
-
),
|
|
318
|
-
Title:
|
|
319
|
-
Content:
|
|
320
|
-
Icon:
|
|
321
|
-
}),
|
|
317
|
+
), $t = Object.assign(ze, {
|
|
318
|
+
Title: Ee,
|
|
319
|
+
Content: Ce,
|
|
320
|
+
Icon: ee
|
|
321
|
+
}), Ve = w(
|
|
322
|
+
"group flex items-center justify-between transition-all duration-200 w-full",
|
|
323
|
+
{
|
|
324
|
+
variants: {
|
|
325
|
+
size: {
|
|
326
|
+
sm: "p-3",
|
|
327
|
+
md: "p-4",
|
|
328
|
+
lg: "p-5"
|
|
329
|
+
},
|
|
330
|
+
as: {
|
|
331
|
+
button: "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-primary-light hover:bg-gray-50 cursor-pointer",
|
|
332
|
+
div: ""
|
|
333
|
+
}
|
|
334
|
+
},
|
|
335
|
+
defaultVariants: {
|
|
336
|
+
size: "md",
|
|
337
|
+
as: "button"
|
|
338
|
+
}
|
|
339
|
+
}
|
|
340
|
+
), Ie = w(
|
|
341
|
+
"bg-gradient-to-br from-gray-100 to-gray-200 rounded-xl flex items-center justify-center group-hover:from-primary-soft group-hover:to-primary-light duration-200",
|
|
342
|
+
{
|
|
343
|
+
variants: {
|
|
344
|
+
size: {
|
|
345
|
+
sm: "w-8 h-8",
|
|
346
|
+
md: "w-10 h-10",
|
|
347
|
+
lg: "w-12 h-12"
|
|
348
|
+
}
|
|
349
|
+
},
|
|
350
|
+
defaultVariants: {
|
|
351
|
+
size: "md"
|
|
352
|
+
}
|
|
353
|
+
}
|
|
354
|
+
), Le = w(
|
|
355
|
+
"inline-flex items-center justify-center text-ghost-bold transition-colors duration-200",
|
|
356
|
+
{
|
|
357
|
+
variants: {
|
|
358
|
+
size: {
|
|
359
|
+
sm: "w-3 h-3",
|
|
360
|
+
md: "w-4 h-4",
|
|
361
|
+
lg: "w-5 h-5"
|
|
362
|
+
}
|
|
363
|
+
},
|
|
364
|
+
defaultVariants: {
|
|
365
|
+
size: "md"
|
|
366
|
+
}
|
|
367
|
+
}
|
|
368
|
+
), Ae = w("", {
|
|
369
|
+
variants: {
|
|
370
|
+
color: {
|
|
371
|
+
primary: "text-primary",
|
|
372
|
+
secondary: "text-secondary",
|
|
373
|
+
tertiary: "text-tertiary",
|
|
374
|
+
ghost: "text-ghost",
|
|
375
|
+
neutral: "text-ghost",
|
|
376
|
+
success: "text-success",
|
|
377
|
+
info: "text-info",
|
|
378
|
+
warning: "text-warning",
|
|
379
|
+
danger: "text-danger",
|
|
380
|
+
inherit: "",
|
|
381
|
+
gray: "text-gray-500",
|
|
382
|
+
black: "text-black",
|
|
383
|
+
white: "text-white"
|
|
384
|
+
},
|
|
385
|
+
hasUnderline: {
|
|
386
|
+
true: "underline",
|
|
387
|
+
false: ""
|
|
388
|
+
},
|
|
389
|
+
isCapitalize: {
|
|
390
|
+
true: "capitalize",
|
|
391
|
+
false: ""
|
|
392
|
+
},
|
|
393
|
+
align: {
|
|
394
|
+
left: "text-left",
|
|
395
|
+
center: "text-center",
|
|
396
|
+
right: "text-right",
|
|
397
|
+
justify: "text-justify"
|
|
398
|
+
},
|
|
399
|
+
italic: {
|
|
400
|
+
true: "italic",
|
|
401
|
+
false: ""
|
|
402
|
+
},
|
|
403
|
+
clamp: {
|
|
404
|
+
1: "line-clamp-1",
|
|
405
|
+
2: "line-clamp-2",
|
|
406
|
+
3: "line-clamp-3",
|
|
407
|
+
4: "line-clamp-4",
|
|
408
|
+
5: "line-clamp-5",
|
|
409
|
+
none: ""
|
|
410
|
+
},
|
|
411
|
+
ellipsis: {
|
|
412
|
+
true: "truncate",
|
|
413
|
+
false: ""
|
|
414
|
+
},
|
|
415
|
+
as: {
|
|
416
|
+
h1: "font-bold text-4xl leading-loose",
|
|
417
|
+
h2: "font-semibold text-3xl leading-relaxed",
|
|
418
|
+
h3: "font-medium text-2xl leading-relaxed",
|
|
419
|
+
h4: "font-bold text-xl leading-normal",
|
|
420
|
+
h5: "font-semibold text-lg leading-normal",
|
|
421
|
+
h6: "font-medium text-base leading-normal",
|
|
422
|
+
p: "font-normal text-base leading-normal",
|
|
423
|
+
span: "font-normal text-base leading-normal",
|
|
424
|
+
label: "font-normal text-xs leading-normal"
|
|
425
|
+
}
|
|
426
|
+
},
|
|
427
|
+
defaultVariants: {
|
|
428
|
+
color: "neutral",
|
|
429
|
+
hasUnderline: !1,
|
|
430
|
+
isCapitalize: !1,
|
|
431
|
+
align: "left",
|
|
432
|
+
italic: !1,
|
|
433
|
+
clamp: "none",
|
|
434
|
+
ellipsis: !1,
|
|
435
|
+
as: "span"
|
|
436
|
+
}
|
|
437
|
+
}), z = f(
|
|
438
|
+
({
|
|
439
|
+
as: e = "span",
|
|
440
|
+
color: t = "ghost",
|
|
441
|
+
hasUnderline: i = !1,
|
|
442
|
+
isCapitalize: n = !1,
|
|
443
|
+
align: s = "left",
|
|
444
|
+
italic: o = !1,
|
|
445
|
+
clamp: l = "none",
|
|
446
|
+
ellipsis: d = !1,
|
|
447
|
+
fontSize: g,
|
|
448
|
+
fontWeight: h,
|
|
449
|
+
className: m,
|
|
450
|
+
children: c,
|
|
451
|
+
...v
|
|
452
|
+
}, y) => {
|
|
453
|
+
const C = [
|
|
454
|
+
"h1",
|
|
455
|
+
"h2",
|
|
456
|
+
"h3",
|
|
457
|
+
"h4",
|
|
458
|
+
"h5",
|
|
459
|
+
"h6",
|
|
460
|
+
"p",
|
|
461
|
+
"span",
|
|
462
|
+
"label"
|
|
463
|
+
].includes(e) ? e : "span", N = g ? `text-${g}` : "", I = h ? `font-${h}` : "";
|
|
464
|
+
return /* @__PURE__ */ r.jsx(
|
|
465
|
+
e,
|
|
466
|
+
{
|
|
467
|
+
ref: y,
|
|
468
|
+
className: u(
|
|
469
|
+
Ae({
|
|
470
|
+
color: t,
|
|
471
|
+
hasUnderline: i,
|
|
472
|
+
isCapitalize: n,
|
|
473
|
+
align: s,
|
|
474
|
+
italic: o,
|
|
475
|
+
clamp: l,
|
|
476
|
+
ellipsis: d,
|
|
477
|
+
// @ts-expect-error - `as` is not a valid variant
|
|
478
|
+
as: C
|
|
479
|
+
}),
|
|
480
|
+
N,
|
|
481
|
+
I,
|
|
482
|
+
m
|
|
483
|
+
),
|
|
484
|
+
...v,
|
|
485
|
+
children: c
|
|
486
|
+
}
|
|
487
|
+
);
|
|
488
|
+
}
|
|
489
|
+
), Me = f(
|
|
490
|
+
({ children: e, className: t }, i) => /* @__PURE__ */ r.jsx(
|
|
491
|
+
"div",
|
|
492
|
+
{
|
|
493
|
+
ref: i,
|
|
494
|
+
className: u(
|
|
495
|
+
"bg-background border border-border rounded-lg overflow-hidden",
|
|
496
|
+
"divide-y divide-border",
|
|
497
|
+
t
|
|
498
|
+
),
|
|
499
|
+
role: "group",
|
|
500
|
+
children: e
|
|
501
|
+
}
|
|
502
|
+
)
|
|
503
|
+
), Re = f(
|
|
504
|
+
({
|
|
505
|
+
size: e = "md",
|
|
506
|
+
icon: t,
|
|
507
|
+
title: i,
|
|
508
|
+
subtitle: n,
|
|
509
|
+
badge: s,
|
|
510
|
+
showArrow: o = !0,
|
|
511
|
+
as: l = "button",
|
|
512
|
+
className: d,
|
|
513
|
+
...g
|
|
514
|
+
}, h) => /* @__PURE__ */ r.jsxs(
|
|
515
|
+
l,
|
|
516
|
+
{
|
|
517
|
+
ref: h,
|
|
518
|
+
className: u(Ve({ size: e, as: l }), d),
|
|
519
|
+
...g,
|
|
520
|
+
children: [
|
|
521
|
+
/* @__PURE__ */ r.jsxs("div", { className: "flex items-center gap-4 flex-1", children: [
|
|
522
|
+
t && /* @__PURE__ */ r.jsx("div", { className: u(Ie({ size: e })), children: t }),
|
|
523
|
+
/* @__PURE__ */ r.jsxs("div", { className: "flex-1", children: [
|
|
524
|
+
/* @__PURE__ */ r.jsxs("div", { className: "flex items-center gap-3 mb-1", children: [
|
|
525
|
+
/* @__PURE__ */ r.jsx(
|
|
526
|
+
z,
|
|
527
|
+
{
|
|
528
|
+
as: "span",
|
|
529
|
+
fontSize: e === "sm" ? "sm" : "base",
|
|
530
|
+
fontWeight: "semibold",
|
|
531
|
+
color: "ghost",
|
|
532
|
+
className: "text-left leading-normal",
|
|
533
|
+
children: i
|
|
534
|
+
}
|
|
535
|
+
),
|
|
536
|
+
s && /* @__PURE__ */ r.jsx(
|
|
537
|
+
"div",
|
|
538
|
+
{
|
|
539
|
+
className: "flex flex-wrap items-center flex-row justify-start gap-3",
|
|
540
|
+
role: "group",
|
|
541
|
+
children: s
|
|
542
|
+
}
|
|
543
|
+
)
|
|
544
|
+
] }),
|
|
545
|
+
n && /* @__PURE__ */ r.jsx(
|
|
546
|
+
z,
|
|
547
|
+
{
|
|
548
|
+
as: "p",
|
|
549
|
+
fontSize: "sm",
|
|
550
|
+
color: "gray",
|
|
551
|
+
className: "text-left leading-normal",
|
|
552
|
+
children: n
|
|
553
|
+
}
|
|
554
|
+
)
|
|
555
|
+
] })
|
|
556
|
+
] }),
|
|
557
|
+
o && /* @__PURE__ */ r.jsx("div", { className: "flex items-center gap-3", children: /* @__PURE__ */ r.jsx(
|
|
558
|
+
R,
|
|
559
|
+
{
|
|
560
|
+
as: ge,
|
|
561
|
+
className: u(Le({ size: e })),
|
|
562
|
+
color: "ghost",
|
|
563
|
+
"aria-hidden": "true"
|
|
564
|
+
}
|
|
565
|
+
) })
|
|
566
|
+
]
|
|
567
|
+
}
|
|
568
|
+
)
|
|
569
|
+
), Xt = Object.assign(Re, {
|
|
570
|
+
Group: Me
|
|
571
|
+
}), Se = w(
|
|
322
572
|
"relative flex items-center gap-2 rounded-md p-2 text-sm transition-all duration-200",
|
|
323
573
|
{
|
|
324
574
|
variants: {
|
|
@@ -439,7 +689,7 @@ const iconVariants = cva("inline-flex items-center justify-center", {
|
|
|
439
689
|
color: "neutral"
|
|
440
690
|
}
|
|
441
691
|
}
|
|
442
|
-
),
|
|
692
|
+
), We = w(
|
|
443
693
|
"flex-shrink-0 flex justify-center items-center ",
|
|
444
694
|
{
|
|
445
695
|
variants: {
|
|
@@ -453,32 +703,32 @@ const iconVariants = cva("inline-flex items-center justify-center", {
|
|
|
453
703
|
size: "md"
|
|
454
704
|
}
|
|
455
705
|
}
|
|
456
|
-
),
|
|
457
|
-
({ className: e, children: t, ...
|
|
458
|
-
),
|
|
706
|
+
), te = f(
|
|
707
|
+
({ className: e, children: t, ...i }, n) => /* @__PURE__ */ r.jsx("div", { ref: n, className: u(We(), e), ...i, children: t })
|
|
708
|
+
), Be = f(
|
|
459
709
|
({
|
|
460
710
|
variant: e = "default",
|
|
461
711
|
color: t = "neutral",
|
|
462
|
-
icon:
|
|
463
|
-
className:
|
|
712
|
+
icon: i,
|
|
713
|
+
className: n,
|
|
464
714
|
children: s,
|
|
465
|
-
...
|
|
466
|
-
},
|
|
715
|
+
...o
|
|
716
|
+
}, l) => /* @__PURE__ */ r.jsxs(
|
|
467
717
|
"div",
|
|
468
718
|
{
|
|
469
|
-
ref:
|
|
719
|
+
ref: l,
|
|
470
720
|
role: "alert",
|
|
471
|
-
className:
|
|
472
|
-
...
|
|
721
|
+
className: u(Se({ variant: e, color: t }), n),
|
|
722
|
+
...o,
|
|
473
723
|
children: [
|
|
474
|
-
|
|
475
|
-
/* @__PURE__ */
|
|
724
|
+
i && /* @__PURE__ */ r.jsx(te, { children: i }),
|
|
725
|
+
/* @__PURE__ */ r.jsx("div", { className: "flex-1", children: s })
|
|
476
726
|
]
|
|
477
727
|
}
|
|
478
728
|
)
|
|
479
|
-
),
|
|
480
|
-
Icon:
|
|
481
|
-
}),
|
|
729
|
+
), Yt = Object.assign(Be, {
|
|
730
|
+
Icon: te
|
|
731
|
+
}), Oe = w(
|
|
482
732
|
[
|
|
483
733
|
"inline-flex items-center transition-colors focus:outline-none focus-visible:ring-2 focus-visible:ring-offset-2",
|
|
484
734
|
// pseudo selectors for anchor
|
|
@@ -535,159 +785,38 @@ const iconVariants = cva("inline-flex items-center justify-center", {
|
|
|
535
785
|
quiet: !1
|
|
536
786
|
}
|
|
537
787
|
}
|
|
538
|
-
),
|
|
788
|
+
), Dt = f(
|
|
539
789
|
({
|
|
540
790
|
children: e,
|
|
541
791
|
className: t,
|
|
542
|
-
color:
|
|
543
|
-
fontSize:
|
|
792
|
+
color: i = "primary",
|
|
793
|
+
fontSize: n = "base",
|
|
544
794
|
fontWeight: s = "medium",
|
|
545
|
-
quiet:
|
|
546
|
-
...
|
|
547
|
-
},
|
|
795
|
+
quiet: o = !1,
|
|
796
|
+
...l
|
|
797
|
+
}, d) => /* @__PURE__ */ r.jsx(
|
|
548
798
|
"a",
|
|
549
799
|
{
|
|
550
|
-
ref:
|
|
551
|
-
className:
|
|
552
|
-
|
|
800
|
+
ref: d,
|
|
801
|
+
className: u(
|
|
802
|
+
Oe({ color: i, fontSize: n, fontWeight: s, quiet: o }),
|
|
553
803
|
t
|
|
554
804
|
),
|
|
555
|
-
...
|
|
805
|
+
...l,
|
|
556
806
|
children: e
|
|
557
807
|
}
|
|
558
808
|
)
|
|
559
|
-
),
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
primary: "text-primary",
|
|
563
|
-
secondary: "text-secondary",
|
|
564
|
-
tertiary: "text-tertiary",
|
|
565
|
-
ghost: "text-ghost",
|
|
566
|
-
neutral: "text-ghost",
|
|
567
|
-
success: "text-success",
|
|
568
|
-
info: "text-info",
|
|
569
|
-
warning: "text-warning",
|
|
570
|
-
danger: "text-danger",
|
|
571
|
-
inherit: "",
|
|
572
|
-
gray: "text-gray-500",
|
|
573
|
-
black: "text-black",
|
|
574
|
-
white: "text-white"
|
|
575
|
-
},
|
|
576
|
-
hasUnderline: {
|
|
577
|
-
true: "underline",
|
|
578
|
-
false: ""
|
|
579
|
-
},
|
|
580
|
-
isCapitalize: {
|
|
581
|
-
true: "capitalize",
|
|
582
|
-
false: ""
|
|
583
|
-
},
|
|
584
|
-
align: {
|
|
585
|
-
left: "text-left",
|
|
586
|
-
center: "text-center",
|
|
587
|
-
right: "text-right",
|
|
588
|
-
justify: "text-justify"
|
|
589
|
-
},
|
|
590
|
-
italic: {
|
|
591
|
-
true: "italic",
|
|
592
|
-
false: ""
|
|
593
|
-
},
|
|
594
|
-
clamp: {
|
|
595
|
-
1: "line-clamp-1",
|
|
596
|
-
2: "line-clamp-2",
|
|
597
|
-
3: "line-clamp-3",
|
|
598
|
-
4: "line-clamp-4",
|
|
599
|
-
5: "line-clamp-5",
|
|
600
|
-
none: ""
|
|
601
|
-
},
|
|
602
|
-
ellipsis: {
|
|
603
|
-
true: "truncate",
|
|
604
|
-
false: ""
|
|
605
|
-
},
|
|
606
|
-
as: {
|
|
607
|
-
h1: "font-bold text-4xl leading-loose",
|
|
608
|
-
h2: "font-semibold text-3xl leading-relaxed",
|
|
609
|
-
h3: "font-medium text-2xl leading-relaxed",
|
|
610
|
-
h4: "font-bold text-xl leading-normal",
|
|
611
|
-
h5: "font-semibold text-lg leading-normal",
|
|
612
|
-
h6: "font-medium text-base leading-normal",
|
|
613
|
-
p: "font-normal text-base leading-normal",
|
|
614
|
-
span: "font-normal text-base leading-normal",
|
|
615
|
-
label: "font-normal text-xs leading-normal"
|
|
616
|
-
}
|
|
617
|
-
},
|
|
618
|
-
defaultVariants: {
|
|
619
|
-
color: "neutral",
|
|
620
|
-
hasUnderline: !1,
|
|
621
|
-
isCapitalize: !1,
|
|
622
|
-
align: "left",
|
|
623
|
-
italic: !1,
|
|
624
|
-
clamp: "none",
|
|
625
|
-
ellipsis: !1,
|
|
626
|
-
as: "span"
|
|
627
|
-
}
|
|
628
|
-
}), Text = forwardRef(
|
|
629
|
-
({
|
|
630
|
-
as: e = "span",
|
|
631
|
-
color: t = "ghost",
|
|
632
|
-
hasUnderline: r = !1,
|
|
633
|
-
isCapitalize: i = !1,
|
|
634
|
-
align: s = "left",
|
|
635
|
-
italic: n = !1,
|
|
636
|
-
clamp: a = "none",
|
|
637
|
-
ellipsis: l = !1,
|
|
638
|
-
fontSize: u,
|
|
639
|
-
fontWeight: c,
|
|
640
|
-
className: f,
|
|
641
|
-
children: o,
|
|
642
|
-
...d
|
|
643
|
-
}, h) => {
|
|
644
|
-
const y = [
|
|
645
|
-
"h1",
|
|
646
|
-
"h2",
|
|
647
|
-
"h3",
|
|
648
|
-
"h4",
|
|
649
|
-
"h5",
|
|
650
|
-
"h6",
|
|
651
|
-
"p",
|
|
652
|
-
"span",
|
|
653
|
-
"label"
|
|
654
|
-
].includes(e) ? e : "span", w = u ? `text-${u}` : "", j = c ? `font-${c}` : "";
|
|
655
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
656
|
-
e,
|
|
657
|
-
{
|
|
658
|
-
ref: h,
|
|
659
|
-
className: cn(
|
|
660
|
-
textVariants({
|
|
661
|
-
color: t,
|
|
662
|
-
hasUnderline: r,
|
|
663
|
-
isCapitalize: i,
|
|
664
|
-
align: s,
|
|
665
|
-
italic: n,
|
|
666
|
-
clamp: a,
|
|
667
|
-
ellipsis: l,
|
|
668
|
-
// @ts-expect-error - `as` is not a valid variant
|
|
669
|
-
as: y
|
|
670
|
-
}),
|
|
671
|
-
w,
|
|
672
|
-
j,
|
|
673
|
-
f
|
|
674
|
-
),
|
|
675
|
-
...d,
|
|
676
|
-
children: o
|
|
677
|
-
}
|
|
678
|
-
);
|
|
679
|
-
}
|
|
680
|
-
), Attribute = forwardRef(
|
|
681
|
-
function({ title: t, children: r, className: i, hasMargin: s, ...n }, a) {
|
|
682
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
809
|
+
), He = f(
|
|
810
|
+
function({ title: t, children: i, className: n, hasMargin: s, ...o }, l) {
|
|
811
|
+
return /* @__PURE__ */ r.jsxs(
|
|
683
812
|
"div",
|
|
684
813
|
{
|
|
685
|
-
ref:
|
|
686
|
-
className:
|
|
687
|
-
...
|
|
814
|
+
ref: l,
|
|
815
|
+
className: u("space-y-1", n, s && "mb-4"),
|
|
816
|
+
...o,
|
|
688
817
|
children: [
|
|
689
|
-
/* @__PURE__ */
|
|
690
|
-
|
|
818
|
+
/* @__PURE__ */ r.jsx(
|
|
819
|
+
z,
|
|
691
820
|
{
|
|
692
821
|
as: "h4",
|
|
693
822
|
fontSize: "sm",
|
|
@@ -697,13 +826,13 @@ const iconVariants = cva("inline-flex items-center justify-center", {
|
|
|
697
826
|
children: t
|
|
698
827
|
}
|
|
699
828
|
),
|
|
700
|
-
/* @__PURE__ */
|
|
829
|
+
/* @__PURE__ */ r.jsx(z, { as: "p", fontSize: "base", fontWeight: "normal", children: i })
|
|
701
830
|
]
|
|
702
831
|
}
|
|
703
832
|
);
|
|
704
833
|
}
|
|
705
834
|
);
|
|
706
|
-
function
|
|
835
|
+
function Te(e = 1) {
|
|
707
836
|
switch (e) {
|
|
708
837
|
case 1:
|
|
709
838
|
return "col-span-1";
|
|
@@ -733,7 +862,7 @@ function getColSpan(e = 1) {
|
|
|
733
862
|
return "col-span-1";
|
|
734
863
|
}
|
|
735
864
|
}
|
|
736
|
-
function
|
|
865
|
+
function qe(e = 4) {
|
|
737
866
|
switch (e) {
|
|
738
867
|
case 1:
|
|
739
868
|
return "grid-cols-1";
|
|
@@ -763,25 +892,25 @@ function getGridCols(e = 4) {
|
|
|
763
892
|
return "grid-cols-4";
|
|
764
893
|
}
|
|
765
894
|
}
|
|
766
|
-
const
|
|
767
|
-
const
|
|
768
|
-
return /* @__PURE__ */
|
|
769
|
-
}),
|
|
770
|
-
function({ children: t, className:
|
|
771
|
-
const
|
|
772
|
-
return /* @__PURE__ */
|
|
895
|
+
const _e = f(function({ children: t, className: i, span: n = 1, title: s, ...o }, l) {
|
|
896
|
+
const d = Te(n);
|
|
897
|
+
return /* @__PURE__ */ r.jsx("li", { ref: l, className: u(d, i), ...o, children: /* @__PURE__ */ r.jsx(He, { title: s, children: t }) });
|
|
898
|
+
}), Pe = f(
|
|
899
|
+
function({ children: t, className: i, columns: n = 4, ...s }, o) {
|
|
900
|
+
const l = qe(n);
|
|
901
|
+
return /* @__PURE__ */ r.jsx(
|
|
773
902
|
"ul",
|
|
774
903
|
{
|
|
775
|
-
ref:
|
|
776
|
-
className:
|
|
904
|
+
ref: o,
|
|
905
|
+
className: u("grid gap-4", l, i),
|
|
777
906
|
...s,
|
|
778
907
|
children: t
|
|
779
908
|
}
|
|
780
909
|
);
|
|
781
910
|
}
|
|
782
|
-
),
|
|
783
|
-
Item:
|
|
784
|
-
}),
|
|
911
|
+
), Jt = Object.assign(Pe, {
|
|
912
|
+
Item: _e
|
|
913
|
+
}), Fe = w(
|
|
785
914
|
"inline-flex items-center justify-center font-medium text-white overflow-hidden transition-all duration-200 select-none relative",
|
|
786
915
|
{
|
|
787
916
|
variants: {
|
|
@@ -821,55 +950,55 @@ const AttributeListItem = forwardRef(function({ children: t, className: r, span:
|
|
|
821
950
|
shape: "circle"
|
|
822
951
|
}
|
|
823
952
|
}
|
|
824
|
-
),
|
|
953
|
+
), Ue = w(
|
|
825
954
|
"absolute inset-0 h-full w-full object-cover"
|
|
826
|
-
),
|
|
955
|
+
), Ge = f(
|
|
827
956
|
({
|
|
828
957
|
variant: e = "primary",
|
|
829
958
|
size: t = "md",
|
|
830
|
-
shape:
|
|
831
|
-
className:
|
|
959
|
+
shape: i = "circle",
|
|
960
|
+
className: n,
|
|
832
961
|
children: s,
|
|
833
|
-
...
|
|
834
|
-
},
|
|
962
|
+
...o
|
|
963
|
+
}, l) => /* @__PURE__ */ r.jsx(
|
|
835
964
|
"div",
|
|
836
965
|
{
|
|
837
|
-
ref:
|
|
838
|
-
className:
|
|
839
|
-
...
|
|
966
|
+
ref: l,
|
|
967
|
+
className: u(Fe({ variant: e, size: t, shape: i }), n),
|
|
968
|
+
...o,
|
|
840
969
|
children: s
|
|
841
970
|
}
|
|
842
971
|
)
|
|
843
|
-
),
|
|
844
|
-
({ src: e, alt: t, className:
|
|
845
|
-
const [
|
|
846
|
-
|
|
847
|
-
|
|
972
|
+
), $e = f(
|
|
973
|
+
({ src: e, alt: t, className: i, onError: n, ...s }, o) => {
|
|
974
|
+
const [l, d] = L(!1);
|
|
975
|
+
A(() => {
|
|
976
|
+
d(!1);
|
|
848
977
|
}, [e]);
|
|
849
|
-
const
|
|
850
|
-
(
|
|
851
|
-
|
|
978
|
+
const g = J(
|
|
979
|
+
(h) => {
|
|
980
|
+
d(!0), n?.(h);
|
|
852
981
|
},
|
|
853
|
-
[
|
|
982
|
+
[n]
|
|
854
983
|
);
|
|
855
|
-
return
|
|
984
|
+
return l ? null : /* @__PURE__ */ r.jsx(
|
|
856
985
|
"img",
|
|
857
986
|
{
|
|
858
|
-
ref:
|
|
987
|
+
ref: o,
|
|
859
988
|
src: e,
|
|
860
989
|
alt: t,
|
|
861
|
-
className:
|
|
862
|
-
onError:
|
|
990
|
+
className: u(Ue(), i),
|
|
991
|
+
onError: g,
|
|
863
992
|
...s
|
|
864
993
|
}
|
|
865
994
|
);
|
|
866
995
|
}
|
|
867
|
-
),
|
|
996
|
+
), Kt = Object.assign(Ge, {
|
|
868
997
|
/**
|
|
869
998
|
* AvatarImage sub-component for displaying images with fallback behavior
|
|
870
999
|
*/
|
|
871
|
-
Image:
|
|
872
|
-
}),
|
|
1000
|
+
Image: $e
|
|
1001
|
+
}), Xe = w(
|
|
873
1002
|
"inline-flex items-center justify-center font-medium transition-all duration-200 select-none gap-1 min-h-[1.25rem]",
|
|
874
1003
|
{
|
|
875
1004
|
variants: {
|
|
@@ -1056,49 +1185,49 @@ const AttributeListItem = forwardRef(function({ children: t, className: r, span:
|
|
|
1056
1185
|
iconOnly: !1
|
|
1057
1186
|
}
|
|
1058
1187
|
}
|
|
1059
|
-
),
|
|
1188
|
+
), Qt = f(
|
|
1060
1189
|
({
|
|
1061
1190
|
variant: e = "default",
|
|
1062
1191
|
shape: t = "square",
|
|
1063
|
-
color:
|
|
1064
|
-
size:
|
|
1192
|
+
color: i = "primary",
|
|
1193
|
+
size: n = "md",
|
|
1065
1194
|
iconLeft: s,
|
|
1066
|
-
iconRight:
|
|
1067
|
-
className:
|
|
1068
|
-
children:
|
|
1069
|
-
...
|
|
1070
|
-
},
|
|
1071
|
-
const
|
|
1072
|
-
return /* @__PURE__ */
|
|
1195
|
+
iconRight: o,
|
|
1196
|
+
className: l,
|
|
1197
|
+
children: d,
|
|
1198
|
+
...g
|
|
1199
|
+
}, h) => {
|
|
1200
|
+
const v = !(d != null && d !== "") && !!(s || o);
|
|
1201
|
+
return /* @__PURE__ */ r.jsx(
|
|
1073
1202
|
"span",
|
|
1074
1203
|
{
|
|
1075
|
-
ref:
|
|
1076
|
-
className:
|
|
1077
|
-
|
|
1204
|
+
ref: h,
|
|
1205
|
+
className: u(
|
|
1206
|
+
Xe({
|
|
1078
1207
|
variant: e,
|
|
1079
|
-
color:
|
|
1208
|
+
color: i,
|
|
1080
1209
|
shape: t,
|
|
1081
|
-
size:
|
|
1082
|
-
iconOnly:
|
|
1210
|
+
size: n,
|
|
1211
|
+
iconOnly: v
|
|
1083
1212
|
}),
|
|
1084
|
-
|
|
1213
|
+
l
|
|
1085
1214
|
),
|
|
1086
|
-
...
|
|
1087
|
-
children:
|
|
1215
|
+
...g,
|
|
1216
|
+
children: v ? (
|
|
1088
1217
|
// Icon-only mode: display only the icon
|
|
1089
|
-
s ||
|
|
1218
|
+
s || o
|
|
1090
1219
|
) : (
|
|
1091
1220
|
// Normal mode: display icon(s) and text
|
|
1092
|
-
/* @__PURE__ */
|
|
1221
|
+
/* @__PURE__ */ r.jsxs(r.Fragment, { children: [
|
|
1093
1222
|
s,
|
|
1094
|
-
|
|
1095
|
-
|
|
1223
|
+
d,
|
|
1224
|
+
o
|
|
1096
1225
|
] })
|
|
1097
1226
|
)
|
|
1098
1227
|
}
|
|
1099
1228
|
);
|
|
1100
1229
|
}
|
|
1101
|
-
),
|
|
1230
|
+
), X = (e) => /* @__PURE__ */ a.createElement("svg", { width: 32, height: 32, viewBox: "0 0 32 32", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e }, /* @__PURE__ */ a.createElement("title", null, "Spenicle"), /* @__PURE__ */ a.createElement("rect", { width: 32, height: 32, fill: "#e07a5f" }), /* @__PURE__ */ a.createElement("g", { transform: "translate(16, 16) scale(0.625) translate(-12, -12)" }, /* @__PURE__ */ a.createElement("path", { d: "M4 14a1 1 0 0 1-.78-1.63l9.9-10.2a.5.5 0 0 1 .86.46l-1.92 6.02A1 1 0 0 0 13 10h7a1 1 0 0 1 .78 1.63l-9.9 10.2a.5.5 0 0 1-.86-.46l1.92-6.02A1 1 0 0 0 11 14z", fill: "white" }))), Ye = (e) => /* @__PURE__ */ a.createElement("svg", { width: 32, height: 32, viewBox: "0 0 32 32", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e }, /* @__PURE__ */ a.createElement("title", null, "Spenicle"), /* @__PURE__ */ a.createElement("rect", { width: 32, height: 32, rx: 8, fill: "#e07a5f" }), /* @__PURE__ */ a.createElement("g", { transform: "translate(16, 16) scale(0.625) translate(-12, -12)" }, /* @__PURE__ */ a.createElement("path", { d: "M4 14a1 1 0 0 1-.78-1.63l9.9-10.2a.5.5 0 0 1 .86.46l-1.92 6.02A1 1 0 0 0 13 10h7a1 1 0 0 1 .78 1.63l-9.9 10.2a.5.5 0 0 1-.86-.46l1.92-6.02A1 1 0 0 0 11 14z", fill: "white" }))), De = (e) => /* @__PURE__ */ a.createElement("svg", { width: 32, height: 32, viewBox: "0 0 32 32", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e }, /* @__PURE__ */ a.createElement("title", null, "Spenicle"), /* @__PURE__ */ a.createElement("circle", { cx: 16, cy: 16, r: 16, fill: "#e07a5f" }), /* @__PURE__ */ a.createElement("g", { transform: "translate(16, 16) scale(0.625) translate(-12, -12)" }, /* @__PURE__ */ a.createElement("path", { d: "M4 14a1 1 0 0 1-.78-1.63l9.9-10.2a.5.5 0 0 1 .86.46l-1.92 6.02A1 1 0 0 0 13 10h7a1 1 0 0 1 .78 1.63l-9.9 10.2a.5.5 0 0 1-.86-.46l1.92-6.02A1 1 0 0 0 11 14z", fill: "white" }))), Je = (e) => /* @__PURE__ */ a.createElement("svg", { width: 32, height: 32, viewBox: "0 0 32 32", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e }, /* @__PURE__ */ a.createElement("title", null, "Hub (Square)"), /* @__PURE__ */ a.createElement("rect", { x: 0, y: 0, width: 32, height: 32, rx: 0, fill: "#e07a5f" }), /* @__PURE__ */ a.createElement("g", { transform: "translate(16, 16) scale(0.625) translate(-12, -12)" }, /* @__PURE__ */ a.createElement("path", { d: "M20.341 6.484A10 10 0 0 1 10.266 21.85", stroke: "white", strokeWidth: 2, fill: "none" }), /* @__PURE__ */ a.createElement("path", { d: "M3.659 17.516A10 10 0 0 1 13.74 2.152", stroke: "white", strokeWidth: 2, fill: "none" }), /* @__PURE__ */ a.createElement("circle", { cx: 12, cy: 12, r: 3, fill: "white" }), /* @__PURE__ */ a.createElement("circle", { cx: 19, cy: 5, r: 2, fill: "white" }), /* @__PURE__ */ a.createElement("circle", { cx: 5, cy: 19, r: 2, fill: "white" }))), Ke = (e) => /* @__PURE__ */ a.createElement("svg", { width: 32, height: 32, viewBox: "0 0 32 32", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e }, /* @__PURE__ */ a.createElement("title", null, "Hub (Rounded)"), /* @__PURE__ */ a.createElement("rect", { x: 0, y: 0, width: 32, height: 32, rx: 8, fill: "#e07a5f" }), /* @__PURE__ */ a.createElement("g", { transform: "translate(16, 16) scale(0.625) translate(-12, -12)" }, /* @__PURE__ */ a.createElement("path", { d: "M20.341 6.484A10 10 0 0 1 10.266 21.85", stroke: "white", strokeWidth: 2, fill: "none" }), /* @__PURE__ */ a.createElement("path", { d: "M3.659 17.516A10 10 0 0 1 13.74 2.152", stroke: "white", strokeWidth: 2, fill: "none" }), /* @__PURE__ */ a.createElement("circle", { cx: 12, cy: 12, r: 3, fill: "white" }), /* @__PURE__ */ a.createElement("circle", { cx: 19, cy: 5, r: 2, fill: "white" }), /* @__PURE__ */ a.createElement("circle", { cx: 5, cy: 19, r: 2, fill: "white" }))), Qe = (e) => /* @__PURE__ */ a.createElement("svg", { width: 32, height: 32, viewBox: "0 0 32 32", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e }, /* @__PURE__ */ a.createElement("title", null, "Hub (Circle)"), /* @__PURE__ */ a.createElement("circle", { cx: 16, cy: 16, r: 16, fill: "#e07a5f" }), /* @__PURE__ */ a.createElement("g", { transform: "translate(16, 16) scale(0.625) translate(-12, -12)" }, /* @__PURE__ */ a.createElement("path", { d: "M20.341 6.484A10 10 0 0 1 10.266 21.85", stroke: "white", strokeWidth: 2, fill: "none" }), /* @__PURE__ */ a.createElement("path", { d: "M3.659 17.516A10 10 0 0 1 13.74 2.152", stroke: "white", strokeWidth: 2, fill: "none" }), /* @__PURE__ */ a.createElement("circle", { cx: 12, cy: 12, r: 3, fill: "white" }), /* @__PURE__ */ a.createElement("circle", { cx: 19, cy: 5, r: 2, fill: "white" }), /* @__PURE__ */ a.createElement("circle", { cx: 5, cy: 19, r: 2, fill: "white" }))), Ze = (e) => /* @__PURE__ */ a.createElement("svg", { width: 32, height: 32, viewBox: "0 0 32 32", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e }, /* @__PURE__ */ a.createElement("title", null, "Notunic"), /* @__PURE__ */ a.createElement("rect", { width: 32, height: 32, fill: "#e07a5f" }), /* @__PURE__ */ a.createElement("g", { transform: "translate(16, 16) scale(0.625) translate(-12, -12)" }, /* @__PURE__ */ a.createElement("path", { d: "M13.4 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2v-7.4", fill: "none", stroke: "white", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round" }), /* @__PURE__ */ a.createElement("path", { d: "M2 6h4", fill: "none", stroke: "white", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round" }), /* @__PURE__ */ a.createElement("path", { d: "M2 10h4", fill: "none", stroke: "white", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round" }), /* @__PURE__ */ a.createElement("path", { d: "M2 14h4", fill: "none", stroke: "white", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round" }), /* @__PURE__ */ a.createElement("path", { d: "M2 18h4", fill: "none", stroke: "white", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round" }), /* @__PURE__ */ a.createElement("path", { d: "M21.378 5.626a1 1 0 1 0-3.004-3.004l-5.01 5.012a2 2 0 0 0-.506.854l-.837 2.87a.5.5 0 0 0 .62.62l2.87-.837a2 2 0 0 0 .854-.506z", fill: "white" }))), et = (e) => /* @__PURE__ */ a.createElement("svg", { width: 32, height: 32, viewBox: "0 0 32 32", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e }, /* @__PURE__ */ a.createElement("title", null, "Notunic"), /* @__PURE__ */ a.createElement("rect", { width: 32, height: 32, rx: 8, fill: "#e07a5f" }), /* @__PURE__ */ a.createElement("g", { transform: "translate(16, 16) scale(0.625) translate(-12, -12)" }, /* @__PURE__ */ a.createElement("path", { d: "M13.4 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2v-7.4", fill: "none", stroke: "white", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round" }), /* @__PURE__ */ a.createElement("path", { d: "M2 6h4", fill: "none", stroke: "white", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round" }), /* @__PURE__ */ a.createElement("path", { d: "M2 10h4", fill: "none", stroke: "white", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round" }), /* @__PURE__ */ a.createElement("path", { d: "M2 14h4", fill: "none", stroke: "white", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round" }), /* @__PURE__ */ a.createElement("path", { d: "M2 18h4", fill: "none", stroke: "white", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round" }), /* @__PURE__ */ a.createElement("path", { d: "M21.378 5.626a1 1 0 1 0-3.004-3.004l-5.01 5.012a2 2 0 0 0-.506.854l-.837 2.87a.5.5 0 0 0 .62.62l2.87-.837a2 2 0 0 0 .854-.506z", fill: "white" }))), tt = (e) => /* @__PURE__ */ a.createElement("svg", { width: 32, height: 32, viewBox: "0 0 32 32", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e }, /* @__PURE__ */ a.createElement("title", null, "Notunic"), /* @__PURE__ */ a.createElement("circle", { cx: 16, cy: 16, r: 16, fill: "#e07a5f" }), /* @__PURE__ */ a.createElement("g", { transform: "translate(16, 16) scale(0.625) translate(-12, -12)" }, /* @__PURE__ */ a.createElement("path", { d: "M13.4 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2v-7.4", fill: "none", stroke: "white", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round" }), /* @__PURE__ */ a.createElement("path", { d: "M2 6h4", fill: "none", stroke: "white", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round" }), /* @__PURE__ */ a.createElement("path", { d: "M2 10h4", fill: "none", stroke: "white", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round" }), /* @__PURE__ */ a.createElement("path", { d: "M2 14h4", fill: "none", stroke: "white", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round" }), /* @__PURE__ */ a.createElement("path", { d: "M2 18h4", fill: "none", stroke: "white", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round" }), /* @__PURE__ */ a.createElement("path", { d: "M21.378 5.626a1 1 0 1 0-3.004-3.004l-5.01 5.012a2 2 0 0 0-.506.854l-.837 2.87a.5.5 0 0 0 .62.62l2.87-.837a2 2 0 0 0 .854-.506z", fill: "white" }))), rt = w("", {
|
|
1102
1231
|
variants: {
|
|
1103
1232
|
size: {
|
|
1104
1233
|
xs: "h-6 w-6",
|
|
@@ -1111,40 +1240,45 @@ const AttributeListItem = forwardRef(function({ children: t, className: r, span:
|
|
|
1111
1240
|
defaultVariants: {
|
|
1112
1241
|
size: "md"
|
|
1113
1242
|
}
|
|
1114
|
-
}),
|
|
1115
|
-
({ shape: e = "square", size: t, name:
|
|
1116
|
-
const
|
|
1243
|
+
}), it = f(
|
|
1244
|
+
({ shape: e = "square", size: t, name: i = "spenicle", ...n }, s) => {
|
|
1245
|
+
const o = {
|
|
1117
1246
|
spenicle: {
|
|
1118
|
-
square:
|
|
1119
|
-
rounded:
|
|
1120
|
-
circle:
|
|
1247
|
+
square: X,
|
|
1248
|
+
rounded: Ye,
|
|
1249
|
+
circle: De
|
|
1121
1250
|
},
|
|
1122
1251
|
hub: {
|
|
1123
|
-
square:
|
|
1124
|
-
rounded:
|
|
1125
|
-
circle:
|
|
1252
|
+
square: Je,
|
|
1253
|
+
rounded: Ke,
|
|
1254
|
+
circle: Qe
|
|
1255
|
+
},
|
|
1256
|
+
notunic: {
|
|
1257
|
+
square: Ze,
|
|
1258
|
+
rounded: et,
|
|
1259
|
+
circle: tt
|
|
1126
1260
|
}
|
|
1127
|
-
},
|
|
1128
|
-
return /* @__PURE__ */
|
|
1129
|
-
|
|
1261
|
+
}, d = (o[i] || o.spenicle)[e || "square"] || X;
|
|
1262
|
+
return /* @__PURE__ */ r.jsx(
|
|
1263
|
+
d,
|
|
1130
1264
|
{
|
|
1131
1265
|
ref: s,
|
|
1132
|
-
...
|
|
1133
|
-
className:
|
|
1266
|
+
...n,
|
|
1267
|
+
className: u("inline-block", rt({ size: t }))
|
|
1134
1268
|
}
|
|
1135
1269
|
);
|
|
1136
1270
|
}
|
|
1137
|
-
),
|
|
1138
|
-
({ name: e = "spenicle", size: t = "md", shape:
|
|
1271
|
+
), Zt = f(
|
|
1272
|
+
({ name: e = "spenicle", size: t = "md", shape: i, ...n }, s) => /* @__PURE__ */ r.jsx(
|
|
1139
1273
|
"span",
|
|
1140
1274
|
{
|
|
1141
1275
|
ref: s,
|
|
1142
|
-
className:
|
|
1143
|
-
...
|
|
1144
|
-
children: /* @__PURE__ */
|
|
1276
|
+
className: u("inline-flex items-center gap-2"),
|
|
1277
|
+
...n,
|
|
1278
|
+
children: /* @__PURE__ */ r.jsx(it, { name: e, shape: i, size: t, "aria-hidden": "true" })
|
|
1145
1279
|
}
|
|
1146
1280
|
)
|
|
1147
|
-
),
|
|
1281
|
+
), st = w(
|
|
1148
1282
|
"inline-flex items-center justify-center gap-2 rounded-md font-medium transition-all duration-200 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:opacity-50 disabled:pointer-events-none active:scale-[0.98] select-none cursor-pointer",
|
|
1149
1283
|
{
|
|
1150
1284
|
variants: {
|
|
@@ -1203,39 +1337,39 @@ const AttributeListItem = forwardRef(function({ children: t, className: r, span:
|
|
|
1203
1337
|
size: "md"
|
|
1204
1338
|
}
|
|
1205
1339
|
}
|
|
1206
|
-
),
|
|
1340
|
+
), re = H.forwardRef(
|
|
1207
1341
|
function({
|
|
1208
1342
|
className: t,
|
|
1209
|
-
variant:
|
|
1210
|
-
size:
|
|
1343
|
+
variant: i = "primary",
|
|
1344
|
+
size: n = "md",
|
|
1211
1345
|
disabled: s = !1,
|
|
1212
|
-
type:
|
|
1213
|
-
children:
|
|
1214
|
-
...
|
|
1215
|
-
},
|
|
1216
|
-
return /* @__PURE__ */
|
|
1346
|
+
type: o = "button",
|
|
1347
|
+
children: l,
|
|
1348
|
+
...d
|
|
1349
|
+
}, g) {
|
|
1350
|
+
return /* @__PURE__ */ r.jsx(
|
|
1217
1351
|
"button",
|
|
1218
1352
|
{
|
|
1219
|
-
ref:
|
|
1220
|
-
type:
|
|
1221
|
-
className:
|
|
1353
|
+
ref: g,
|
|
1354
|
+
type: o,
|
|
1355
|
+
className: u(st({ variant: i, size: n }), t),
|
|
1222
1356
|
disabled: s,
|
|
1223
1357
|
"aria-disabled": s,
|
|
1224
1358
|
inert: s ? !0 : void 0,
|
|
1225
|
-
...
|
|
1226
|
-
children:
|
|
1359
|
+
...d,
|
|
1360
|
+
children: l
|
|
1227
1361
|
}
|
|
1228
1362
|
);
|
|
1229
1363
|
}
|
|
1230
|
-
),
|
|
1364
|
+
), nt = ({
|
|
1231
1365
|
container: e,
|
|
1232
1366
|
children: t
|
|
1233
1367
|
}) => {
|
|
1234
1368
|
if (typeof window > "u" || typeof document > "u")
|
|
1235
|
-
return /* @__PURE__ */
|
|
1236
|
-
const
|
|
1237
|
-
return
|
|
1238
|
-
},
|
|
1369
|
+
return /* @__PURE__ */ r.jsx(r.Fragment, { children: t });
|
|
1370
|
+
const i = e ?? document.body;
|
|
1371
|
+
return i ? me.createPortal(t, i) : /* @__PURE__ */ r.jsx(r.Fragment, { children: t });
|
|
1372
|
+
}, Y = w(
|
|
1239
1373
|
"z-70 min-w-40 bg-background rounded-lg border border-border transition-all duration-200 ease-out will-change-transform shadow-lg",
|
|
1240
1374
|
{
|
|
1241
1375
|
variants: {
|
|
@@ -1254,219 +1388,219 @@ const AttributeListItem = forwardRef(function({ children: t, className: r, span:
|
|
|
1254
1388
|
}
|
|
1255
1389
|
}
|
|
1256
1390
|
);
|
|
1257
|
-
function
|
|
1258
|
-
|
|
1391
|
+
function ot(e, t, i, n) {
|
|
1392
|
+
A(() => {
|
|
1259
1393
|
if (!e) return;
|
|
1260
|
-
function s(
|
|
1261
|
-
!t.current?.contains(
|
|
1394
|
+
function s(o) {
|
|
1395
|
+
!t.current?.contains(o.target) && !i.current?.contains(o.target) && n();
|
|
1262
1396
|
}
|
|
1263
1397
|
return document.addEventListener("mousedown", s), () => document.removeEventListener("mousedown", s);
|
|
1264
|
-
}, [e,
|
|
1398
|
+
}, [e, n, t, i]);
|
|
1265
1399
|
}
|
|
1266
|
-
function
|
|
1400
|
+
function D(e) {
|
|
1267
1401
|
const t = [];
|
|
1268
|
-
let
|
|
1269
|
-
for (;
|
|
1270
|
-
const
|
|
1271
|
-
(
|
|
1402
|
+
let i = e.parentElement;
|
|
1403
|
+
for (; i && i !== document.documentElement; ) {
|
|
1404
|
+
const n = getComputedStyle(i);
|
|
1405
|
+
(n.overflow === "auto" || n.overflow === "scroll" || n.overflowY === "auto" || n.overflowY === "scroll" || n.overflowX === "auto" || n.overflowX === "scroll") && t.push(i), i = i.parentElement;
|
|
1272
1406
|
}
|
|
1273
1407
|
return t.push(document.documentElement), t;
|
|
1274
1408
|
}
|
|
1275
|
-
function
|
|
1276
|
-
const
|
|
1277
|
-
if (
|
|
1409
|
+
function at(e, t) {
|
|
1410
|
+
const i = e.getBoundingClientRect();
|
|
1411
|
+
if (i.bottom < 0 || i.top > window.innerHeight || i.right < 0 || i.left > window.innerWidth)
|
|
1278
1412
|
return !1;
|
|
1279
|
-
for (const
|
|
1280
|
-
if (
|
|
1281
|
-
const s =
|
|
1282
|
-
if (
|
|
1413
|
+
for (const n of t) {
|
|
1414
|
+
if (n === document.documentElement) continue;
|
|
1415
|
+
const s = n.getBoundingClientRect();
|
|
1416
|
+
if (i.bottom < s.top || i.top > s.bottom || i.right < s.left || i.left > s.right)
|
|
1283
1417
|
return !1;
|
|
1284
1418
|
}
|
|
1285
1419
|
return !0;
|
|
1286
1420
|
}
|
|
1287
|
-
function
|
|
1288
|
-
const [
|
|
1421
|
+
function lt(e, t, i, n = "bottom-start", s) {
|
|
1422
|
+
const [o, l] = L({ isReady: !1 }), d = J(() => {
|
|
1289
1423
|
if (!e || !t.current) {
|
|
1290
|
-
|
|
1424
|
+
l({ isReady: !1 });
|
|
1291
1425
|
return;
|
|
1292
1426
|
}
|
|
1293
|
-
if (!
|
|
1294
|
-
const
|
|
1295
|
-
|
|
1427
|
+
if (!i.current) {
|
|
1428
|
+
const k = setTimeout(() => {
|
|
1429
|
+
l({ isReady: !1 });
|
|
1296
1430
|
}, 0);
|
|
1297
|
-
return () => clearTimeout(
|
|
1431
|
+
return () => clearTimeout(k);
|
|
1298
1432
|
}
|
|
1299
|
-
const
|
|
1300
|
-
if (!
|
|
1301
|
-
|
|
1433
|
+
const g = t.current, h = i.current, m = D(g);
|
|
1434
|
+
if (!at(g, m)) {
|
|
1435
|
+
l({ isReady: !1 });
|
|
1302
1436
|
return;
|
|
1303
1437
|
}
|
|
1304
|
-
const
|
|
1305
|
-
let
|
|
1306
|
-
s && ("getBoundingClientRect" in s ?
|
|
1307
|
-
const
|
|
1308
|
-
|
|
1309
|
-
const
|
|
1310
|
-
|
|
1311
|
-
const
|
|
1312
|
-
let
|
|
1313
|
-
if (
|
|
1314
|
-
const
|
|
1438
|
+
const c = g.getBoundingClientRect(), v = window.innerWidth, y = window.innerHeight;
|
|
1439
|
+
let j = null;
|
|
1440
|
+
s && ("getBoundingClientRect" in s ? j = s : "current" in s && (j = s.current));
|
|
1441
|
+
const C = j || document.documentElement, N = C === document.documentElement ? { top: 0, bottom: y, left: 0, right: v } : C.getBoundingClientRect(), I = h.style.visibility, S = h.style.position, W = h.style.opacity;
|
|
1442
|
+
h.style.visibility = "hidden", h.style.position = "absolute", h.style.opacity = "0";
|
|
1443
|
+
const p = h.getBoundingClientRect();
|
|
1444
|
+
h.style.visibility = I, h.style.position = S, h.style.opacity = W;
|
|
1445
|
+
const B = N.bottom - c.bottom - 8, O = c.top - N.top - 8, T = N.right - c.left - 8, q = c.right - N.left - 8;
|
|
1446
|
+
let E = n;
|
|
1447
|
+
if (n === "auto") {
|
|
1448
|
+
const x = [
|
|
1315
1449
|
{
|
|
1316
1450
|
name: "bottom-start",
|
|
1317
|
-
fits:
|
|
1318
|
-
spaceUsed:
|
|
1451
|
+
fits: B >= p.height && T >= p.width,
|
|
1452
|
+
spaceUsed: B,
|
|
1319
1453
|
priority: 1
|
|
1320
1454
|
// Prefer bottom-start as default
|
|
1321
1455
|
},
|
|
1322
1456
|
{
|
|
1323
1457
|
name: "bottom-end",
|
|
1324
|
-
fits:
|
|
1325
|
-
spaceUsed:
|
|
1458
|
+
fits: B >= p.height && q >= p.width,
|
|
1459
|
+
spaceUsed: B,
|
|
1326
1460
|
priority: 2
|
|
1327
1461
|
},
|
|
1328
1462
|
{
|
|
1329
1463
|
name: "top-start",
|
|
1330
|
-
fits:
|
|
1331
|
-
spaceUsed:
|
|
1464
|
+
fits: O >= p.height && T >= p.width,
|
|
1465
|
+
spaceUsed: O,
|
|
1332
1466
|
priority: 3
|
|
1333
1467
|
},
|
|
1334
1468
|
{
|
|
1335
1469
|
name: "top-end",
|
|
1336
|
-
fits:
|
|
1337
|
-
spaceUsed:
|
|
1470
|
+
fits: O >= p.height && q >= p.width,
|
|
1471
|
+
spaceUsed: O,
|
|
1338
1472
|
priority: 4
|
|
1339
1473
|
}
|
|
1340
|
-
].filter((
|
|
1341
|
-
|
|
1342
|
-
(
|
|
1343
|
-
)[0].name :
|
|
1474
|
+
].filter((V) => V.fits);
|
|
1475
|
+
x.length > 0 ? E = x.sort(
|
|
1476
|
+
(V, ae) => V.priority - ae.priority
|
|
1477
|
+
)[0].name : B >= O ? E = T >= q ? "bottom-start" : "bottom-end" : E = T >= q ? "top-start" : "top-end";
|
|
1344
1478
|
}
|
|
1345
|
-
const
|
|
1479
|
+
const b = {};
|
|
1346
1480
|
if (s)
|
|
1347
|
-
switch (
|
|
1481
|
+
switch (b.position = "fixed", E) {
|
|
1348
1482
|
case "bottom-start":
|
|
1349
|
-
|
|
1483
|
+
b.top = c.bottom + 4, b.left = c.left;
|
|
1350
1484
|
break;
|
|
1351
1485
|
case "bottom-end":
|
|
1352
|
-
|
|
1486
|
+
b.top = c.bottom + 4, b.right = window.innerWidth - c.right;
|
|
1353
1487
|
break;
|
|
1354
1488
|
case "top-start":
|
|
1355
|
-
|
|
1489
|
+
b.bottom = window.innerHeight - c.top + 4, b.left = c.left;
|
|
1356
1490
|
break;
|
|
1357
1491
|
case "top-end":
|
|
1358
|
-
|
|
1492
|
+
b.bottom = window.innerHeight - c.top + 4, b.right = window.innerWidth - c.right;
|
|
1359
1493
|
break;
|
|
1360
1494
|
}
|
|
1361
1495
|
else
|
|
1362
|
-
switch (
|
|
1496
|
+
switch (b.position = "absolute", E) {
|
|
1363
1497
|
case "bottom-start":
|
|
1364
|
-
|
|
1498
|
+
b.top = c.height + 4, b.left = 0;
|
|
1365
1499
|
break;
|
|
1366
1500
|
case "bottom-end":
|
|
1367
|
-
|
|
1501
|
+
b.top = c.height + 4, b.right = 0;
|
|
1368
1502
|
break;
|
|
1369
1503
|
case "top-start":
|
|
1370
|
-
|
|
1504
|
+
b.bottom = c.height + 4, b.left = 0;
|
|
1371
1505
|
break;
|
|
1372
1506
|
case "top-end":
|
|
1373
|
-
|
|
1507
|
+
b.bottom = c.height + 4, b.right = 0;
|
|
1374
1508
|
break;
|
|
1375
1509
|
}
|
|
1376
1510
|
if (s) {
|
|
1377
|
-
const
|
|
1378
|
-
top:
|
|
1379
|
-
left:
|
|
1380
|
-
width:
|
|
1381
|
-
height:
|
|
1511
|
+
const k = {
|
|
1512
|
+
top: E.startsWith("bottom") ? c.bottom + 4 : c.top - p.height - 4,
|
|
1513
|
+
left: E.endsWith("start") ? c.left : c.right - p.width,
|
|
1514
|
+
width: p.width,
|
|
1515
|
+
height: p.height
|
|
1382
1516
|
};
|
|
1383
|
-
if (
|
|
1384
|
-
const
|
|
1385
|
-
|
|
1386
|
-
} else if (
|
|
1387
|
-
const
|
|
1388
|
-
|
|
1517
|
+
if (k.left < N.left + 8) {
|
|
1518
|
+
const x = N.left + 8 - k.left;
|
|
1519
|
+
E.endsWith("start") ? b.left = (b.left || 0) + x : b.right = (b.right || 0) - x;
|
|
1520
|
+
} else if (k.left + k.width > N.right - 8) {
|
|
1521
|
+
const x = k.left + k.width - (N.right - 8);
|
|
1522
|
+
E.endsWith("start") ? b.left = (b.left || 0) - x : b.right = (b.right || 0) + x;
|
|
1389
1523
|
}
|
|
1390
|
-
if (
|
|
1391
|
-
const
|
|
1524
|
+
if (E.startsWith("bottom")) {
|
|
1525
|
+
const x = Math.max(
|
|
1392
1526
|
50,
|
|
1393
|
-
|
|
1527
|
+
N.bottom - c.bottom - 16
|
|
1394
1528
|
);
|
|
1395
|
-
|
|
1529
|
+
p.height > x && (b.maxHeight = x);
|
|
1396
1530
|
} else {
|
|
1397
|
-
const
|
|
1531
|
+
const x = Math.max(
|
|
1398
1532
|
50,
|
|
1399
|
-
|
|
1533
|
+
c.top - N.top - 16
|
|
1400
1534
|
);
|
|
1401
|
-
|
|
1535
|
+
p.height > x && (b.maxHeight = x);
|
|
1402
1536
|
}
|
|
1403
1537
|
} else {
|
|
1404
|
-
const
|
|
1405
|
-
top:
|
|
1406
|
-
left:
|
|
1407
|
-
width:
|
|
1408
|
-
height:
|
|
1409
|
-
},
|
|
1410
|
-
left:
|
|
1411
|
-
right:
|
|
1412
|
-
top:
|
|
1413
|
-
bottom:
|
|
1538
|
+
const k = {
|
|
1539
|
+
top: E.startsWith("bottom") ? c.height + 4 : -p.height - 4,
|
|
1540
|
+
left: E.endsWith("start") ? 0 : -p.width,
|
|
1541
|
+
width: p.width,
|
|
1542
|
+
height: p.height
|
|
1543
|
+
}, x = {
|
|
1544
|
+
left: c.left,
|
|
1545
|
+
right: c.right,
|
|
1546
|
+
top: c.top,
|
|
1547
|
+
bottom: c.bottom
|
|
1414
1548
|
};
|
|
1415
|
-
if (
|
|
1416
|
-
const
|
|
1417
|
-
|
|
1418
|
-
} else if (
|
|
1419
|
-
const
|
|
1420
|
-
|
|
1549
|
+
if (x.left + k.left < 8) {
|
|
1550
|
+
const V = 8 - (x.left + k.left);
|
|
1551
|
+
E.endsWith("start") ? b.left = (b.left || 0) + V : b.right = (b.right || 0) - V;
|
|
1552
|
+
} else if (x.left + k.left + k.width > v - 8) {
|
|
1553
|
+
const V = x.left + k.left + k.width - (v - 8);
|
|
1554
|
+
E.endsWith("start") ? b.left = (b.left || 0) - V : b.right = (b.right || 0) + V;
|
|
1421
1555
|
}
|
|
1422
1556
|
}
|
|
1423
|
-
|
|
1424
|
-
}, [e,
|
|
1425
|
-
return
|
|
1426
|
-
|
|
1427
|
-
}, [
|
|
1557
|
+
b.isReady = !0, l(b);
|
|
1558
|
+
}, [e, n, t, i, s]);
|
|
1559
|
+
return A(() => {
|
|
1560
|
+
d();
|
|
1561
|
+
}, [d]), A(() => {
|
|
1428
1562
|
if (!e || !t.current) return;
|
|
1429
|
-
const
|
|
1430
|
-
let
|
|
1431
|
-
const
|
|
1432
|
-
|
|
1433
|
-
|
|
1434
|
-
}),
|
|
1563
|
+
const g = t.current, h = D(g);
|
|
1564
|
+
let m = !1;
|
|
1565
|
+
const c = () => {
|
|
1566
|
+
m || (requestAnimationFrame(() => {
|
|
1567
|
+
d(), m = !1;
|
|
1568
|
+
}), m = !0);
|
|
1435
1569
|
};
|
|
1436
|
-
return
|
|
1437
|
-
|
|
1570
|
+
return h.forEach((v) => {
|
|
1571
|
+
v === document.documentElement ? (window.addEventListener("scroll", c, { passive: !0 }), window.addEventListener("resize", c, { passive: !0 })) : v.addEventListener("scroll", c, { passive: !0 });
|
|
1438
1572
|
}), () => {
|
|
1439
|
-
|
|
1440
|
-
|
|
1573
|
+
h.forEach((v) => {
|
|
1574
|
+
v === document.documentElement ? (window.removeEventListener("scroll", c), window.removeEventListener("resize", c)) : v.removeEventListener("scroll", c);
|
|
1441
1575
|
});
|
|
1442
1576
|
};
|
|
1443
|
-
}, [e,
|
|
1577
|
+
}, [e, d, t]), o;
|
|
1444
1578
|
}
|
|
1445
|
-
const
|
|
1446
|
-
const e =
|
|
1579
|
+
const ie = P(void 0), ct = ie.Provider, dt = () => {
|
|
1580
|
+
const e = F(ie);
|
|
1447
1581
|
if (!e)
|
|
1448
1582
|
throw new Error("useMenuProvider must be used within a MenuProvider");
|
|
1449
1583
|
return e;
|
|
1450
|
-
},
|
|
1451
|
-
({ children: e }, t) => /* @__PURE__ */
|
|
1452
|
-
),
|
|
1453
|
-
({ children: e, disabled: t, onClick:
|
|
1454
|
-
const { preserve:
|
|
1455
|
-
|
|
1584
|
+
}, gt = f(
|
|
1585
|
+
({ children: e }, t) => /* @__PURE__ */ r.jsx("ul", { ref: t, className: "flex flex-col gap-1", children: e })
|
|
1586
|
+
), ht = f(
|
|
1587
|
+
({ children: e, disabled: t, onClick: i, active: n, ...s }, o) => {
|
|
1588
|
+
const { preserve: l, onClose: d } = dt(), g = (h) => {
|
|
1589
|
+
i?.(h), l || d();
|
|
1456
1590
|
};
|
|
1457
|
-
return /* @__PURE__ */
|
|
1458
|
-
|
|
1591
|
+
return /* @__PURE__ */ r.jsx("li", { ref: o, ...s, children: /* @__PURE__ */ r.jsxs(
|
|
1592
|
+
re,
|
|
1459
1593
|
{
|
|
1460
1594
|
variant: "ghost",
|
|
1461
|
-
className:
|
|
1595
|
+
className: u("justify-start w-full gap-2"),
|
|
1462
1596
|
disabled: t,
|
|
1463
|
-
onClick:
|
|
1597
|
+
onClick: g,
|
|
1464
1598
|
children: [
|
|
1465
1599
|
e,
|
|
1466
|
-
|
|
1467
|
-
|
|
1600
|
+
n && /* @__PURE__ */ r.jsx(
|
|
1601
|
+
R,
|
|
1468
1602
|
{
|
|
1469
|
-
as:
|
|
1603
|
+
as: he,
|
|
1470
1604
|
color: "inherit",
|
|
1471
1605
|
className: "ml-auto",
|
|
1472
1606
|
size: "sm"
|
|
@@ -1476,59 +1610,59 @@ const MenuContext = createContext(void 0), MenuProvider = MenuContext.Provider,
|
|
|
1476
1610
|
}
|
|
1477
1611
|
) });
|
|
1478
1612
|
}
|
|
1479
|
-
),
|
|
1613
|
+
), ut = ({
|
|
1480
1614
|
isOpen: e,
|
|
1481
1615
|
onOutsideClick: t,
|
|
1482
|
-
size:
|
|
1483
|
-
content:
|
|
1616
|
+
size: i = "md",
|
|
1617
|
+
content: n,
|
|
1484
1618
|
children: s,
|
|
1485
|
-
placement:
|
|
1486
|
-
container:
|
|
1487
|
-
preserve:
|
|
1619
|
+
placement: o = "auto",
|
|
1620
|
+
container: l,
|
|
1621
|
+
preserve: d
|
|
1488
1622
|
}) => {
|
|
1489
|
-
const
|
|
1490
|
-
|
|
1491
|
-
const
|
|
1623
|
+
const g = _(null), h = _(null), m = le();
|
|
1624
|
+
ot(e, h, g, t);
|
|
1625
|
+
const c = lt(
|
|
1492
1626
|
e,
|
|
1493
|
-
|
|
1494
|
-
|
|
1495
|
-
|
|
1496
|
-
|
|
1497
|
-
),
|
|
1498
|
-
...
|
|
1499
|
-
position:
|
|
1500
|
-
overflowY:
|
|
1501
|
-
overflowX:
|
|
1502
|
-
},
|
|
1627
|
+
g,
|
|
1628
|
+
h,
|
|
1629
|
+
o,
|
|
1630
|
+
l || null
|
|
1631
|
+
), v = {
|
|
1632
|
+
...c,
|
|
1633
|
+
position: c.position || "absolute",
|
|
1634
|
+
overflowY: c.maxHeight ? "auto" : void 0,
|
|
1635
|
+
overflowX: c.maxWidth ? "auto" : void 0
|
|
1636
|
+
}, y = e && c.isReady, j = /* @__PURE__ */ r.jsx(
|
|
1503
1637
|
"div",
|
|
1504
1638
|
{
|
|
1505
|
-
id:
|
|
1506
|
-
ref:
|
|
1507
|
-
className:
|
|
1508
|
-
style:
|
|
1639
|
+
id: m,
|
|
1640
|
+
ref: h,
|
|
1641
|
+
className: u(Y({ size: i, open: y })),
|
|
1642
|
+
style: v,
|
|
1509
1643
|
role: "menu",
|
|
1510
|
-
"aria-hidden": !
|
|
1511
|
-
children:
|
|
1644
|
+
"aria-hidden": !y,
|
|
1645
|
+
children: n
|
|
1512
1646
|
}
|
|
1513
1647
|
);
|
|
1514
|
-
return /* @__PURE__ */
|
|
1515
|
-
|
|
1648
|
+
return /* @__PURE__ */ r.jsx(
|
|
1649
|
+
ct,
|
|
1516
1650
|
{
|
|
1517
|
-
value: { onClose: t, preserve: !!
|
|
1518
|
-
children: /* @__PURE__ */
|
|
1519
|
-
|
|
1651
|
+
value: { onClose: t, preserve: !!d },
|
|
1652
|
+
children: /* @__PURE__ */ r.jsxs("div", { className: "relative w-fit", children: [
|
|
1653
|
+
ce(s, {
|
|
1520
1654
|
// @ts-expect-error: ref is valid for button or forwardRef components
|
|
1521
|
-
ref:
|
|
1655
|
+
ref: g,
|
|
1522
1656
|
"aria-haspopup": "menu",
|
|
1523
1657
|
"aria-expanded": e,
|
|
1524
|
-
"aria-controls":
|
|
1658
|
+
"aria-controls": m
|
|
1525
1659
|
}),
|
|
1526
|
-
e && /* @__PURE__ */
|
|
1527
|
-
!
|
|
1660
|
+
e && /* @__PURE__ */ r.jsxs(r.Fragment, { children: [
|
|
1661
|
+
!c.isReady && /* @__PURE__ */ r.jsx(
|
|
1528
1662
|
"div",
|
|
1529
1663
|
{
|
|
1530
|
-
ref:
|
|
1531
|
-
className:
|
|
1664
|
+
ref: h,
|
|
1665
|
+
className: u(Y({ size: i, open: !1 })),
|
|
1532
1666
|
style: {
|
|
1533
1667
|
position: "absolute",
|
|
1534
1668
|
visibility: "hidden",
|
|
@@ -1537,54 +1671,54 @@ const MenuContext = createContext(void 0), MenuProvider = MenuContext.Provider,
|
|
|
1537
1671
|
},
|
|
1538
1672
|
role: "menu",
|
|
1539
1673
|
"aria-hidden": !0,
|
|
1540
|
-
children:
|
|
1674
|
+
children: n
|
|
1541
1675
|
}
|
|
1542
1676
|
),
|
|
1543
|
-
|
|
1677
|
+
c.isReady && /* @__PURE__ */ r.jsx(r.Fragment, { children: c.position === "fixed" ? /* @__PURE__ */ r.jsx(nt, { children: j }) : j })
|
|
1544
1678
|
] })
|
|
1545
1679
|
] })
|
|
1546
1680
|
}
|
|
1547
1681
|
);
|
|
1548
|
-
},
|
|
1549
|
-
Content:
|
|
1550
|
-
Item:
|
|
1551
|
-
}),
|
|
1682
|
+
}, M = Object.assign(ut, {
|
|
1683
|
+
Content: gt,
|
|
1684
|
+
Item: ht
|
|
1685
|
+
}), ft = f(
|
|
1552
1686
|
(e, t) => {
|
|
1553
1687
|
const {
|
|
1554
|
-
children:
|
|
1555
|
-
onOpenChange:
|
|
1688
|
+
children: i,
|
|
1689
|
+
onOpenChange: n,
|
|
1556
1690
|
onClick: s,
|
|
1557
|
-
placement:
|
|
1558
|
-
container:
|
|
1559
|
-
preserve:
|
|
1560
|
-
label:
|
|
1561
|
-
...
|
|
1562
|
-
} = e ?? {}, [
|
|
1563
|
-
|
|
1564
|
-
|
|
1565
|
-
}, [
|
|
1566
|
-
const
|
|
1567
|
-
|
|
1568
|
-
},
|
|
1569
|
-
|
|
1691
|
+
placement: o,
|
|
1692
|
+
container: l,
|
|
1693
|
+
preserve: d,
|
|
1694
|
+
label: g,
|
|
1695
|
+
...h
|
|
1696
|
+
} = e ?? {}, [m, c] = L(!1);
|
|
1697
|
+
A(() => {
|
|
1698
|
+
n?.(m);
|
|
1699
|
+
}, [m, n]);
|
|
1700
|
+
const v = () => {
|
|
1701
|
+
c(!1);
|
|
1702
|
+
}, y = (j) => {
|
|
1703
|
+
c((C) => !C), s?.(j);
|
|
1570
1704
|
};
|
|
1571
|
-
return /* @__PURE__ */
|
|
1572
|
-
|
|
1573
|
-
{
|
|
1574
|
-
isOpen:
|
|
1575
|
-
onOutsideClick:
|
|
1576
|
-
placement:
|
|
1577
|
-
container:
|
|
1578
|
-
preserve:
|
|
1579
|
-
content: /* @__PURE__ */
|
|
1580
|
-
children: /* @__PURE__ */
|
|
1705
|
+
return /* @__PURE__ */ r.jsx(
|
|
1706
|
+
M,
|
|
1707
|
+
{
|
|
1708
|
+
isOpen: m,
|
|
1709
|
+
onOutsideClick: v,
|
|
1710
|
+
placement: o,
|
|
1711
|
+
container: l,
|
|
1712
|
+
preserve: d,
|
|
1713
|
+
content: /* @__PURE__ */ r.jsx(M.Content, { children: i }),
|
|
1714
|
+
children: /* @__PURE__ */ r.jsx(re, { ref: t, onClick: y, ...h, children: g })
|
|
1581
1715
|
}
|
|
1582
1716
|
);
|
|
1583
1717
|
}
|
|
1584
|
-
),
|
|
1585
|
-
Item:
|
|
1718
|
+
), er = Object.assign(ft, {
|
|
1719
|
+
Item: M.Item
|
|
1586
1720
|
});
|
|
1587
|
-
function
|
|
1721
|
+
function bt(e = "primary") {
|
|
1588
1722
|
const t = e.split("-");
|
|
1589
1723
|
if (t.length === 1)
|
|
1590
1724
|
switch (t[0]) {
|
|
@@ -1619,7 +1753,7 @@ function getIconColorFromVariant(e = "primary") {
|
|
|
1619
1753
|
return "neutral";
|
|
1620
1754
|
}
|
|
1621
1755
|
}
|
|
1622
|
-
const
|
|
1756
|
+
const mt = w(
|
|
1623
1757
|
"inline-flex items-center justify-center font-medium transition-all duration-200 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:opacity-50 disabled:pointer-events-none active:scale-[0.98] select-none cursor-pointer",
|
|
1624
1758
|
{
|
|
1625
1759
|
variants: {
|
|
@@ -1672,383 +1806,82 @@ const buttonIconVariants = cva(
|
|
|
1672
1806
|
shape: "rounded"
|
|
1673
1807
|
}
|
|
1674
1808
|
}
|
|
1675
|
-
),
|
|
1809
|
+
), wt = H.forwardRef(
|
|
1676
1810
|
function({
|
|
1677
1811
|
className: t,
|
|
1678
|
-
variant:
|
|
1679
|
-
size:
|
|
1812
|
+
variant: i = "primary",
|
|
1813
|
+
size: n = "md",
|
|
1680
1814
|
shape: s = "rounded",
|
|
1681
|
-
disabled:
|
|
1682
|
-
as:
|
|
1683
|
-
"aria-label":
|
|
1684
|
-
...
|
|
1685
|
-
},
|
|
1686
|
-
return /* @__PURE__ */
|
|
1815
|
+
disabled: o = !1,
|
|
1816
|
+
as: l,
|
|
1817
|
+
"aria-label": d,
|
|
1818
|
+
...g
|
|
1819
|
+
}, h) {
|
|
1820
|
+
return /* @__PURE__ */ r.jsx(
|
|
1687
1821
|
"button",
|
|
1688
1822
|
{
|
|
1689
|
-
ref:
|
|
1823
|
+
ref: h,
|
|
1690
1824
|
type: "button",
|
|
1691
|
-
className:
|
|
1692
|
-
|
|
1693
|
-
variant:
|
|
1694
|
-
size:
|
|
1825
|
+
className: u(
|
|
1826
|
+
mt({
|
|
1827
|
+
variant: i,
|
|
1828
|
+
size: n,
|
|
1695
1829
|
shape: s
|
|
1696
1830
|
}),
|
|
1697
1831
|
t
|
|
1698
1832
|
),
|
|
1699
|
-
disabled:
|
|
1700
|
-
"aria-disabled":
|
|
1701
|
-
"aria-label":
|
|
1702
|
-
inert:
|
|
1703
|
-
...
|
|
1704
|
-
children: /* @__PURE__ */
|
|
1705
|
-
|
|
1833
|
+
disabled: o,
|
|
1834
|
+
"aria-disabled": o,
|
|
1835
|
+
"aria-label": d,
|
|
1836
|
+
inert: o ? !0 : void 0,
|
|
1837
|
+
...g,
|
|
1838
|
+
children: /* @__PURE__ */ r.jsx(
|
|
1839
|
+
R,
|
|
1706
1840
|
{
|
|
1707
|
-
as:
|
|
1841
|
+
as: l,
|
|
1708
1842
|
size: "sm",
|
|
1709
|
-
color:
|
|
1843
|
+
color: bt(i)
|
|
1710
1844
|
}
|
|
1711
1845
|
)
|
|
1712
1846
|
}
|
|
1713
1847
|
);
|
|
1714
1848
|
}
|
|
1715
|
-
),
|
|
1849
|
+
), vt = f(
|
|
1716
1850
|
(e, t) => {
|
|
1717
1851
|
const {
|
|
1718
|
-
as:
|
|
1719
|
-
children:
|
|
1852
|
+
as: i = ue,
|
|
1853
|
+
children: n,
|
|
1720
1854
|
onOpenChange: s,
|
|
1721
|
-
onClick:
|
|
1722
|
-
placement:
|
|
1723
|
-
container:
|
|
1724
|
-
preserve:
|
|
1725
|
-
...
|
|
1726
|
-
} = e ?? {}, [
|
|
1727
|
-
|
|
1728
|
-
s?.(
|
|
1729
|
-
}, [
|
|
1730
|
-
const
|
|
1731
|
-
|
|
1732
|
-
},
|
|
1733
|
-
|
|
1734
|
-
};
|
|
1735
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
1736
|
-
Menu,
|
|
1737
|
-
{
|
|
1738
|
-
isOpen: f,
|
|
1739
|
-
onOutsideClick: d,
|
|
1740
|
-
placement: a,
|
|
1741
|
-
container: l,
|
|
1742
|
-
preserve: u,
|
|
1743
|
-
content: /* @__PURE__ */ jsxRuntimeExports.jsx(Menu.Content, { children: i }),
|
|
1744
|
-
children: /* @__PURE__ */ jsxRuntimeExports.jsx(ButtonIcon, { ref: t, as: r, onClick: h, ...c })
|
|
1745
|
-
}
|
|
1746
|
-
);
|
|
1747
|
-
}
|
|
1748
|
-
), ButtonMenuIcon = Object.assign(ButtonMenuIconRoot, {
|
|
1749
|
-
Item: Menu.Item
|
|
1750
|
-
}), buttonFloatVariants = cva(
|
|
1751
|
-
[
|
|
1752
|
-
"inline-flex items-center justify-center gap-2",
|
|
1753
|
-
"rounded-lg",
|
|
1754
|
-
"font-medium",
|
|
1755
|
-
"transition-all",
|
|
1756
|
-
"duration-200",
|
|
1757
|
-
"focus-visible:outline-none",
|
|
1758
|
-
"focus-visible:ring-2",
|
|
1759
|
-
"focus-visible:ring-offset-2",
|
|
1760
|
-
"disabled:opacity-50",
|
|
1761
|
-
"disabled:pointer-events-none",
|
|
1762
|
-
"select-none",
|
|
1763
|
-
"shadow-lg",
|
|
1764
|
-
"transition-transform",
|
|
1765
|
-
"transition-shadow",
|
|
1766
|
-
"will-change-transform,opacity,box-shadow",
|
|
1767
|
-
"hover:scale-105",
|
|
1768
|
-
"active:scale-95",
|
|
1769
|
-
"focus-visible:shadow-xl",
|
|
1770
|
-
"hover:shadow-xl",
|
|
1771
|
-
"active:shadow-md"
|
|
1772
|
-
].join(" "),
|
|
1773
|
-
{
|
|
1774
|
-
variants: {
|
|
1775
|
-
variant: {
|
|
1776
|
-
primary: "bg-primary text-white hover:bg-primary/90 focus-visible:ring-primary-light focus-visible:ring-offset-white shadow-sm hover:shadow-md",
|
|
1777
|
-
secondary: "bg-secondary text-white hover:bg-secondary/90 focus-visible:ring-secondary-light focus-visible:ring-offset-white shadow-sm hover:shadow-md",
|
|
1778
|
-
tertiary: "bg-tertiary text-white hover:bg-tertiary/90 focus-visible:ring-tertiary-light focus-visible:ring-offset-white shadow-sm hover:shadow-md",
|
|
1779
|
-
ghost: "bg-white text-foreground hover:bg-ghost-soft focus-visible:ring-ghost-light focus-visible:ring-offset-white",
|
|
1780
|
-
neutral: "bg-neutral text-foreground border border-border hover:bg-neutral/80 focus-visible:ring-foreground-light focus-visible:ring-offset-white shadow-sm",
|
|
1781
|
-
"primary-outline": "border border-primary text-primary bg-white hover:bg-primary hover:text-white focus-visible:ring-primary-light focus-visible:ring-offset-white transition-all",
|
|
1782
|
-
"secondary-outline": "border border-secondary text-secondary bg-white hover:bg-secondary hover:text-white focus-visible:ring-secondary-light focus-visible:ring-offset-white transition-all",
|
|
1783
|
-
"tertiary-outline": "border border-tertiary text-tertiary bg-white hover:bg-tertiary hover:text-white focus-visible:ring-tertiary-light focus-visible:ring-offset-white transition-all",
|
|
1784
|
-
"ghost-outline": "border border-ghost text-ghost bg-white hover:bg-ghost hover:text-white focus-visible:ring-ghost-light focus-visible:ring-offset-white transition-all",
|
|
1785
|
-
"neutral-outline": "border border-border text-foreground bg-white hover:bg-neutral hover:text-foreground focus-visible:ring-foreground-light focus-visible:ring-offset-white transition-all",
|
|
1786
|
-
"primary-ghost": "text-primary bg-white hover:bg-primary/20 focus-visible:ring-primary focus-visible:ring-offset-white",
|
|
1787
|
-
"secondary-ghost": "text-secondary bg-white hover:bg-secondary/20 focus-visible:ring-secondary focus-visible:ring-offset-white",
|
|
1788
|
-
"tertiary-ghost": "text-tertiary bg-white hover:bg-tertiary/20 focus-visible:ring-tertiary focus-visible:ring-offset-white",
|
|
1789
|
-
"neutral-ghost": "text-foreground bg-white hover:bg-neutral/50 focus-visible:ring-foreground focus-visible:ring-offset-white",
|
|
1790
|
-
success: "bg-success text-white hover:bg-success/90 focus-visible:ring-success-light focus-visible:ring-offset-white shadow-sm hover:shadow-md",
|
|
1791
|
-
"success-outline": "border border-success text-success bg-white hover:bg-success hover:text-white focus-visible:ring-success-light focus-visible:ring-offset-white transition-all",
|
|
1792
|
-
"success-ghost": "text-success bg-white hover:bg-success/20 focus-visible:ring-success-light focus-visible:ring-offset-white",
|
|
1793
|
-
info: "bg-info text-white hover:bg-info/90 focus-visible:ring-info-light focus-visible:ring-offset-white shadow-sm hover:shadow-md",
|
|
1794
|
-
"info-outline": "border border-info text-info bg-white hover:bg-info hover:text-white focus-visible:ring-info-light focus-visible:ring-offset-white transition-all",
|
|
1795
|
-
"info-ghost": "text-info bg-white hover:bg-info/20 focus-visible:ring-info-light focus-visible:ring-offset-white",
|
|
1796
|
-
warning: "bg-warning text-white hover:bg-warning/90 focus-visible:ring-warning-light focus-visible:ring-offset-white shadow-sm hover:shadow-md",
|
|
1797
|
-
"warning-outline": "border border-warning text-warning bg-white hover:bg-warning hover:text-white focus-visible:ring-warning-light focus-visible:ring-offset-white transition-all",
|
|
1798
|
-
"warning-ghost": "text-warning bg-white hover:bg-warning/20 focus-visible:ring-warning-light focus-visible:ring-offset-white",
|
|
1799
|
-
danger: "bg-danger text-white hover:bg-danger/90 focus-visible:ring-danger-light focus-visible:ring-offset-white shadow-sm hover:shadow-md",
|
|
1800
|
-
"danger-outline": "border border-danger text-danger bg-white hover:bg-danger hover:text-white focus-visible:ring-danger-light focus-visible:ring-offset-white transition-all",
|
|
1801
|
-
"danger-ghost": "text-danger bg-white hover:bg-danger/20 focus-visible:ring-danger-light focus-visible:ring-offset-white",
|
|
1802
|
-
outline: "border border-border text-foreground bg-white hover:bg-accent-soft focus-visible:ring-accent-soft focus-visible:ring-offset-white transition-all",
|
|
1803
|
-
destructive: "bg-danger text-white hover:bg-danger/90 focus-visible:ring-danger-soft focus-visible:ring-offset-white shadow-sm hover:shadow-md"
|
|
1804
|
-
},
|
|
1805
|
-
size: {
|
|
1806
|
-
sm: "h-12 w-12 min-w-12 min-h-12 text-base",
|
|
1807
|
-
md: "h-14 w-14 min-w-14 min-h-14 text-lg",
|
|
1808
|
-
lg: "h-16 w-16 min-w-16 min-h-16 text-xl"
|
|
1809
|
-
}
|
|
1810
|
-
},
|
|
1811
|
-
defaultVariants: {
|
|
1812
|
-
variant: "primary",
|
|
1813
|
-
size: "md"
|
|
1814
|
-
}
|
|
1815
|
-
}
|
|
1816
|
-
);
|
|
1817
|
-
function useFloatingPosition(e, t = "1rem") {
|
|
1818
|
-
const r = useRef(null), [i, s] = useState({}), [n, a] = useState("fixed bottom-4 right-4"), l = useCallback(() => {
|
|
1819
|
-
const c = r.current;
|
|
1820
|
-
if (!c) return;
|
|
1821
|
-
const o = c.getBoundingClientRect().height > window.innerHeight;
|
|
1822
|
-
let d = {}, h = "";
|
|
1823
|
-
o ? (d = {
|
|
1824
|
-
position: "fixed",
|
|
1825
|
-
bottom: t,
|
|
1826
|
-
zIndex: 50,
|
|
1827
|
-
transform: `translateY(${c.scrollTop}px)`
|
|
1828
|
-
}, h = `fixed bottom-4 ${e}-4`) : (d = {
|
|
1829
|
-
position: "fixed",
|
|
1830
|
-
bottom: t,
|
|
1831
|
-
zIndex: 50
|
|
1832
|
-
}, h = `fixed bottom-4 ${e}-4`), s(d), a(h);
|
|
1833
|
-
}, [e, t]);
|
|
1834
|
-
return useEffect(() => {
|
|
1835
|
-
l();
|
|
1836
|
-
const c = r.current;
|
|
1837
|
-
return c && c.addEventListener("scroll", l), window.addEventListener("resize", l), () => {
|
|
1838
|
-
c && c.removeEventListener("scroll", l), window.removeEventListener("resize", l);
|
|
1839
|
-
};
|
|
1840
|
-
}, [l]), useEffect(() => {
|
|
1841
|
-
r.current && l();
|
|
1842
|
-
}, [e, t, l]), [useCallback(
|
|
1843
|
-
(c) => {
|
|
1844
|
-
r.current = c, c && l();
|
|
1845
|
-
},
|
|
1846
|
-
[l]
|
|
1847
|
-
), i, n];
|
|
1848
|
-
}
|
|
1849
|
-
const ButtonFloat = forwardRef(
|
|
1850
|
-
function({
|
|
1851
|
-
className: t,
|
|
1852
|
-
variant: r = "primary",
|
|
1853
|
-
size: i = "md",
|
|
1854
|
-
side: s = "right",
|
|
1855
|
-
offset: n = "1rem",
|
|
1856
|
-
...a
|
|
1857
|
-
}, l) {
|
|
1858
|
-
const [u, c, f] = useFloatingPosition(
|
|
1859
|
-
s,
|
|
1860
|
-
n
|
|
1861
|
-
), [o, d] = useState(!1);
|
|
1862
|
-
return useEffect(() => {
|
|
1863
|
-
d(!0);
|
|
1864
|
-
}, []), /* @__PURE__ */ jsxRuntimeExports.jsx("div", { ref: u, children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
1865
|
-
"button",
|
|
1866
|
-
{
|
|
1867
|
-
ref: l,
|
|
1868
|
-
type: a.type || "button",
|
|
1869
|
-
className: cn(
|
|
1870
|
-
buttonFloatVariants({ variant: r, size: i }),
|
|
1871
|
-
f,
|
|
1872
|
-
o && "animate-fab-in",
|
|
1873
|
-
t
|
|
1874
|
-
),
|
|
1875
|
-
style: c,
|
|
1876
|
-
...a
|
|
1877
|
-
}
|
|
1878
|
-
) });
|
|
1879
|
-
}
|
|
1880
|
-
), calculatorRootVariants = cva(
|
|
1881
|
-
"flex flex-col w-full max-w-xs rounded-lg bg-background",
|
|
1882
|
-
{
|
|
1883
|
-
variants: {
|
|
1884
|
-
disabled: {
|
|
1885
|
-
true: "opacity-60 pointer-events-none",
|
|
1886
|
-
false: ""
|
|
1887
|
-
}
|
|
1888
|
-
},
|
|
1889
|
-
defaultVariants: {
|
|
1890
|
-
disabled: !1
|
|
1891
|
-
}
|
|
1892
|
-
}
|
|
1893
|
-
), calculatorButtonVariants = cva(
|
|
1894
|
-
"flex-1 min-w-0 h-12 m-0.5 rounded text-lg font-medium transition-colors select-none",
|
|
1895
|
-
{
|
|
1896
|
-
variants: {
|
|
1897
|
-
variant: {
|
|
1898
|
-
default: "bg-neutral text-foreground hover:bg-neutral-soft hover:text-neutral",
|
|
1899
|
-
action: "bg-primary text-white hover:bg-primary-soft hover:text-primary",
|
|
1900
|
-
operator: "bg-secondary text-white hover:bg-secondary-soft hover:text-secondary",
|
|
1901
|
-
danger: "bg-danger text-white hover:bg-danger-soft hover:text-danger"
|
|
1902
|
-
},
|
|
1903
|
-
disabled: {
|
|
1904
|
-
true: "opacity-50 pointer-events-none",
|
|
1905
|
-
false: ""
|
|
1906
|
-
}
|
|
1907
|
-
},
|
|
1908
|
-
defaultVariants: {
|
|
1909
|
-
variant: "default",
|
|
1910
|
-
disabled: !1
|
|
1911
|
-
}
|
|
1912
|
-
}
|
|
1913
|
-
), CalculatorButton = forwardRef(({ variant: e = "default", className: t, ...r }, i) => /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
1914
|
-
"button",
|
|
1915
|
-
{
|
|
1916
|
-
ref: i,
|
|
1917
|
-
type: "button",
|
|
1918
|
-
className: cn(
|
|
1919
|
-
calculatorButtonVariants({ variant: e, disabled: r.disabled }),
|
|
1920
|
-
t
|
|
1921
|
-
),
|
|
1922
|
-
...r
|
|
1923
|
-
}
|
|
1924
|
-
));
|
|
1925
|
-
function useCalculator({
|
|
1926
|
-
initialValue = "",
|
|
1927
|
-
disabled,
|
|
1928
|
-
onChange
|
|
1929
|
-
}) {
|
|
1930
|
-
const [input, setInput] = useState(String(initialValue)), inputRef = useRef(null);
|
|
1931
|
-
useEffect(() => {
|
|
1932
|
-
setInput(String(initialValue));
|
|
1933
|
-
}, [initialValue]);
|
|
1934
|
-
const evaluate = useCallback((expr) => {
|
|
1935
|
-
try {
|
|
1936
|
-
if (!/^[-+*/.\d\s]+$/.test(expr)) return "";
|
|
1937
|
-
const result = eval(expr);
|
|
1938
|
-
return result?.toString() ?? "";
|
|
1939
|
-
} catch {
|
|
1940
|
-
return "";
|
|
1941
|
-
}
|
|
1942
|
-
}, []), handleButton = useCallback(
|
|
1943
|
-
(e) => {
|
|
1944
|
-
if (!disabled)
|
|
1945
|
-
if (e === "C")
|
|
1946
|
-
setInput("");
|
|
1947
|
-
else if (e === "⌫")
|
|
1948
|
-
setInput((t) => t.slice(0, -1));
|
|
1949
|
-
else if (e === "=") {
|
|
1950
|
-
const t = evaluate(input);
|
|
1951
|
-
setInput(t);
|
|
1952
|
-
} else
|
|
1953
|
-
setInput((t) => t + e);
|
|
1954
|
-
},
|
|
1955
|
-
[disabled, input, evaluate]
|
|
1956
|
-
);
|
|
1957
|
-
useEffect(() => {
|
|
1958
|
-
if (onChange) {
|
|
1959
|
-
const e = evaluate(input);
|
|
1960
|
-
onChange(e);
|
|
1961
|
-
}
|
|
1962
|
-
}, [evaluate, input, onChange]), useEffect(() => {
|
|
1963
|
-
if (disabled) return;
|
|
1964
|
-
const e = (t) => {
|
|
1965
|
-
if (document.activeElement !== inputRef.current && document.activeElement?.tagName !== "BODY")
|
|
1966
|
-
return;
|
|
1967
|
-
const r = t.key;
|
|
1968
|
-
r === "Enter" || r === "=" ? (handleButton("="), t.preventDefault()) : r === "Backspace" ? (handleButton("⌫"), t.preventDefault()) : r === "Escape" || r === "C" || r === "c" ? (handleButton("C"), t.preventDefault()) : (/^[0-9]$/.test(r) || ["/", "*", "-", "+", "."].includes(r)) && (handleButton(r), t.preventDefault());
|
|
1855
|
+
onClick: o,
|
|
1856
|
+
placement: l,
|
|
1857
|
+
container: d,
|
|
1858
|
+
preserve: g,
|
|
1859
|
+
...h
|
|
1860
|
+
} = e ?? {}, [m, c] = L(!1);
|
|
1861
|
+
A(() => {
|
|
1862
|
+
s?.(m);
|
|
1863
|
+
}, [m, s]);
|
|
1864
|
+
const v = () => {
|
|
1865
|
+
c(!1);
|
|
1866
|
+
}, y = (j) => {
|
|
1867
|
+
c((C) => !C), o?.(j);
|
|
1969
1868
|
};
|
|
1970
|
-
return
|
|
1971
|
-
|
|
1972
|
-
|
|
1973
|
-
|
|
1974
|
-
|
|
1975
|
-
|
|
1976
|
-
|
|
1977
|
-
|
|
1978
|
-
|
|
1979
|
-
|
|
1980
|
-
inputRef,
|
|
1981
|
-
handleButton,
|
|
1982
|
-
handleInput
|
|
1983
|
-
};
|
|
1984
|
-
}
|
|
1985
|
-
const BUTTONS = [
|
|
1986
|
-
["7", "8", "9", "/"],
|
|
1987
|
-
["4", "5", "6", "*"],
|
|
1988
|
-
["1", "2", "3", "-"],
|
|
1989
|
-
["0", ".", "=", "+"]
|
|
1990
|
-
], Calculator = forwardRef(
|
|
1991
|
-
({
|
|
1992
|
-
initialValue: e = "",
|
|
1993
|
-
onChange: t,
|
|
1994
|
-
disabled: r,
|
|
1995
|
-
className: i,
|
|
1996
|
-
"aria-label": s
|
|
1997
|
-
}, n) => {
|
|
1998
|
-
const { input: a, inputRef: l, handleButton: u, handleInput: c } = useCalculator({
|
|
1999
|
-
initialValue: e,
|
|
2000
|
-
disabled: r,
|
|
2001
|
-
onChange: t
|
|
2002
|
-
});
|
|
2003
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
2004
|
-
"div",
|
|
2005
|
-
{
|
|
2006
|
-
ref: n,
|
|
2007
|
-
className: cn(calculatorRootVariants({ disabled: r }), i),
|
|
2008
|
-
"aria-label": s || "Calculator",
|
|
2009
|
-
role: "region",
|
|
2010
|
-
children: [
|
|
2011
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
2012
|
-
"input",
|
|
2013
|
-
{
|
|
2014
|
-
ref: l,
|
|
2015
|
-
className: "w-full mb-3 px-3 py-2 rounded border border-[var(--color-neutral)] bg-[var(--color-neutral-soft)] text-right text-xl font-mono focus:outline-none focus:ring-2 focus:ring-[var(--color-primary)]",
|
|
2016
|
-
value: a,
|
|
2017
|
-
onChange: c,
|
|
2018
|
-
disabled: r,
|
|
2019
|
-
inputMode: "decimal",
|
|
2020
|
-
"aria-label": "Calculator input"
|
|
2021
|
-
}
|
|
2022
|
-
),
|
|
2023
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex flex-col gap-1 mb-3", children: BUTTONS.map((f, o) => /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex w-full", children: f.map((d) => d === "⌫" ? /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
2024
|
-
ButtonIcon,
|
|
2025
|
-
{
|
|
2026
|
-
as: X,
|
|
2027
|
-
variant: "danger-ghost",
|
|
2028
|
-
"aria-label": "Backspace",
|
|
2029
|
-
size: "md",
|
|
2030
|
-
onClick: () => u("⌫"),
|
|
2031
|
-
disabled: r
|
|
2032
|
-
},
|
|
2033
|
-
"backspace"
|
|
2034
|
-
) : /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
2035
|
-
CalculatorButton,
|
|
2036
|
-
{
|
|
2037
|
-
variant: d === "=" ? "action" : d === "C" ? "danger" : ["/", "*", "-", "+", "/"].includes(d) ? "operator" : "default",
|
|
2038
|
-
onClick: () => u(d),
|
|
2039
|
-
disabled: r,
|
|
2040
|
-
"aria-label": d,
|
|
2041
|
-
children: d
|
|
2042
|
-
},
|
|
2043
|
-
d
|
|
2044
|
-
)) }, o)) })
|
|
2045
|
-
]
|
|
1869
|
+
return /* @__PURE__ */ r.jsx(
|
|
1870
|
+
M,
|
|
1871
|
+
{
|
|
1872
|
+
isOpen: m,
|
|
1873
|
+
onOutsideClick: v,
|
|
1874
|
+
placement: l,
|
|
1875
|
+
container: d,
|
|
1876
|
+
preserve: g,
|
|
1877
|
+
content: /* @__PURE__ */ r.jsx(M.Content, { children: n }),
|
|
1878
|
+
children: /* @__PURE__ */ r.jsx(wt, { ref: t, as: i, onClick: y, ...h })
|
|
2046
1879
|
}
|
|
2047
1880
|
);
|
|
2048
1881
|
}
|
|
2049
|
-
)
|
|
2050
|
-
|
|
2051
|
-
|
|
1882
|
+
), tr = Object.assign(vt, {
|
|
1883
|
+
Item: M.Item
|
|
1884
|
+
}), xt = w(
|
|
2052
1885
|
"flex justify-between transition-colors duration-200 w-full",
|
|
2053
1886
|
{
|
|
2054
1887
|
variants: {
|
|
@@ -2080,8 +1913,8 @@ const cardVariants = cva(
|
|
|
2080
1913
|
as: "button"
|
|
2081
1914
|
}
|
|
2082
1915
|
}
|
|
2083
|
-
),
|
|
2084
|
-
({ children: e }, t) => /* @__PURE__ */
|
|
1916
|
+
), pt = f(
|
|
1917
|
+
({ children: e }, t) => /* @__PURE__ */ r.jsx(
|
|
2085
1918
|
"ul",
|
|
2086
1919
|
{
|
|
2087
1920
|
ref: t,
|
|
@@ -2089,76 +1922,76 @@ const cardVariants = cva(
|
|
|
2089
1922
|
children: e
|
|
2090
1923
|
}
|
|
2091
1924
|
)
|
|
2092
|
-
),
|
|
2093
|
-
({ children: e }, t) => /* @__PURE__ */
|
|
1925
|
+
), yt = f(
|
|
1926
|
+
({ children: e }, t) => /* @__PURE__ */ r.jsx(
|
|
2094
1927
|
"li",
|
|
2095
1928
|
{
|
|
2096
1929
|
ref: t,
|
|
2097
1930
|
className: "flex items-center min-w-0 flex-shrink-0 after:content-[''] after:inline-block after:mx-1.5 @sm/card:after:mx-2 after:w-1 after:h-1 after:rounded-full after:bg-ghost last:after:hidden after:flex-shrink-0",
|
|
2098
|
-
children: /* @__PURE__ */
|
|
1931
|
+
children: /* @__PURE__ */ r.jsx(z, { as: "span", fontSize: "sm", color: "gray", ellipsis: !0, clamp: 1, children: e })
|
|
2099
1932
|
}
|
|
2100
1933
|
)
|
|
2101
|
-
),
|
|
1934
|
+
), jt = f(
|
|
2102
1935
|
({
|
|
2103
1936
|
size: e = "md",
|
|
2104
1937
|
shape: t = "rounded",
|
|
2105
|
-
avatar:
|
|
2106
|
-
title:
|
|
1938
|
+
avatar: i,
|
|
1939
|
+
title: n,
|
|
2107
1940
|
subtitle: s,
|
|
2108
|
-
badge:
|
|
2109
|
-
supplementaryInfo:
|
|
2110
|
-
bordered:
|
|
2111
|
-
as:
|
|
2112
|
-
className:
|
|
2113
|
-
...
|
|
2114
|
-
},
|
|
2115
|
-
|
|
1941
|
+
badge: o,
|
|
1942
|
+
supplementaryInfo: l,
|
|
1943
|
+
bordered: d = !1,
|
|
1944
|
+
as: g = "button",
|
|
1945
|
+
className: h,
|
|
1946
|
+
...m
|
|
1947
|
+
}, c) => /* @__PURE__ */ r.jsx(
|
|
1948
|
+
g,
|
|
2116
1949
|
{
|
|
2117
|
-
ref:
|
|
2118
|
-
className:
|
|
2119
|
-
|
|
2120
|
-
|
|
1950
|
+
ref: c,
|
|
1951
|
+
className: u(
|
|
1952
|
+
xt({ size: e, shape: t, bordered: d, as: g }),
|
|
1953
|
+
h,
|
|
2121
1954
|
"@container/card"
|
|
2122
1955
|
),
|
|
2123
|
-
...
|
|
2124
|
-
children: /* @__PURE__ */
|
|
2125
|
-
|
|
2126
|
-
/* @__PURE__ */
|
|
2127
|
-
/* @__PURE__ */
|
|
2128
|
-
/* @__PURE__ */
|
|
2129
|
-
|
|
1956
|
+
...m,
|
|
1957
|
+
children: /* @__PURE__ */ r.jsxs("div", { className: "flex items-start gap-3 @sm/card:gap-4 w-full", children: [
|
|
1958
|
+
i && /* @__PURE__ */ r.jsx("div", { className: "flex-shrink-0", children: i }),
|
|
1959
|
+
/* @__PURE__ */ r.jsxs("div", { className: "w-full min-w-0", children: [
|
|
1960
|
+
/* @__PURE__ */ r.jsx("div", { className: "mb-2", children: /* @__PURE__ */ r.jsx("div", { className: "flex items-start justify-between gap-2", children: /* @__PURE__ */ r.jsxs("div", { className: "flex-1 min-w-0", children: [
|
|
1961
|
+
/* @__PURE__ */ r.jsx(
|
|
1962
|
+
z,
|
|
2130
1963
|
{
|
|
2131
1964
|
as: "h3",
|
|
2132
1965
|
fontSize: "base",
|
|
2133
1966
|
fontWeight: "semibold",
|
|
2134
1967
|
className: "break-words leading-tight",
|
|
2135
|
-
children:
|
|
1968
|
+
children: n
|
|
2136
1969
|
}
|
|
2137
1970
|
),
|
|
2138
|
-
s && /* @__PURE__ */
|
|
1971
|
+
s && /* @__PURE__ */ r.jsx("div", { className: "mt-1", children: typeof s == "string" ? /* @__PURE__ */ r.jsx(z, { as: "p", fontSize: "sm", color: "gray", children: s }) : /* @__PURE__ */ r.jsx("div", { className: "min-w-0 overflow-hidden", children: s }) })
|
|
2139
1972
|
] }) }) }),
|
|
2140
|
-
/* @__PURE__ */
|
|
2141
|
-
|
|
2142
|
-
|
|
2143
|
-
|
|
1973
|
+
/* @__PURE__ */ r.jsxs("div", { className: "flex flex-col gap-2 @sm/card:flex-row @sm/card:justify-between @sm/card:items-center", children: [
|
|
1974
|
+
o && /* @__PURE__ */ r.jsx("div", { className: "order-1 @sm/card:order-none overflow-hidden", children: o }),
|
|
1975
|
+
l && /* @__PURE__ */ r.jsx("div", { className: "flex-shrink-0 order-2 @sm/card:order-none @sm/card:ml-auto", children: typeof l == "string" ? /* @__PURE__ */ r.jsx(
|
|
1976
|
+
z,
|
|
2144
1977
|
{
|
|
2145
1978
|
as: "p",
|
|
2146
1979
|
fontSize: "sm",
|
|
2147
1980
|
color: "gray",
|
|
2148
1981
|
className: "truncate",
|
|
2149
1982
|
align: "right",
|
|
2150
|
-
children:
|
|
1983
|
+
children: l
|
|
2151
1984
|
}
|
|
2152
|
-
) : /* @__PURE__ */
|
|
1985
|
+
) : /* @__PURE__ */ r.jsx("div", { className: "overflow-hidden", children: l }) })
|
|
2153
1986
|
] })
|
|
2154
1987
|
] })
|
|
2155
1988
|
] })
|
|
2156
1989
|
}
|
|
2157
1990
|
)
|
|
2158
|
-
),
|
|
2159
|
-
List:
|
|
2160
|
-
ListItem:
|
|
2161
|
-
}),
|
|
1991
|
+
), rr = Object.assign(jt, {
|
|
1992
|
+
List: pt,
|
|
1993
|
+
ListItem: yt
|
|
1994
|
+
}), kt = w(
|
|
2162
1995
|
"inline-flex items-center gap-1.5 rounded-full font-medium transition-all duration-200 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:opacity-50 disabled:pointer-events-none select-none cursor-pointer text-sm leading-none",
|
|
2163
1996
|
{
|
|
2164
1997
|
variants: {
|
|
@@ -2196,34 +2029,34 @@ const cardVariants = cva(
|
|
|
2196
2029
|
size: "md"
|
|
2197
2030
|
}
|
|
2198
2031
|
}
|
|
2199
|
-
),
|
|
2200
|
-
function
|
|
2032
|
+
), ir = H.forwardRef(
|
|
2033
|
+
function({
|
|
2201
2034
|
className: t,
|
|
2202
|
-
variant:
|
|
2203
|
-
size:
|
|
2035
|
+
variant: i = "neutral-outline",
|
|
2036
|
+
size: n = "md",
|
|
2204
2037
|
disabled: s = !1,
|
|
2205
|
-
children:
|
|
2206
|
-
...
|
|
2207
|
-
},
|
|
2208
|
-
return /* @__PURE__ */
|
|
2038
|
+
children: o,
|
|
2039
|
+
...l
|
|
2040
|
+
}, d) {
|
|
2041
|
+
return /* @__PURE__ */ r.jsxs(
|
|
2209
2042
|
"button",
|
|
2210
2043
|
{
|
|
2211
|
-
ref:
|
|
2044
|
+
ref: d,
|
|
2212
2045
|
type: "button",
|
|
2213
|
-
className:
|
|
2046
|
+
className: u(kt({ variant: i, size: n }), t),
|
|
2214
2047
|
disabled: s,
|
|
2215
2048
|
"aria-disabled": s,
|
|
2216
|
-
"aria-label": `${
|
|
2049
|
+
"aria-label": `${o}, removable`,
|
|
2217
2050
|
inert: s ? !0 : void 0,
|
|
2218
|
-
...
|
|
2051
|
+
...l,
|
|
2219
2052
|
children: [
|
|
2220
|
-
/* @__PURE__ */
|
|
2221
|
-
/* @__PURE__ */
|
|
2053
|
+
/* @__PURE__ */ r.jsx("span", { className: "flex-shrink-0", children: o }),
|
|
2054
|
+
/* @__PURE__ */ r.jsx(R, { as: fe, color: "inherit", size: n === "lg" ? "md" : "sm" })
|
|
2222
2055
|
]
|
|
2223
2056
|
}
|
|
2224
2057
|
);
|
|
2225
2058
|
}
|
|
2226
|
-
),
|
|
2059
|
+
), Nt = w("h-px w-full bg-border border-0", {
|
|
2227
2060
|
variants: {
|
|
2228
2061
|
hasMargin: {
|
|
2229
2062
|
true: "mb-4",
|
|
@@ -2233,16 +2066,16 @@ const cardVariants = cva(
|
|
|
2233
2066
|
defaultVariants: {
|
|
2234
2067
|
hasMargin: !1
|
|
2235
2068
|
}
|
|
2236
|
-
}),
|
|
2237
|
-
({ hasMargin: e = !1, className: t, ...
|
|
2069
|
+
}), sr = f(
|
|
2070
|
+
({ hasMargin: e = !1, className: t, ...i }, n) => /* @__PURE__ */ r.jsx(
|
|
2238
2071
|
"hr",
|
|
2239
2072
|
{
|
|
2240
|
-
ref:
|
|
2241
|
-
className:
|
|
2242
|
-
...
|
|
2073
|
+
ref: n,
|
|
2074
|
+
className: u(Nt({ hasMargin: e }), t),
|
|
2075
|
+
...i
|
|
2243
2076
|
}
|
|
2244
2077
|
)
|
|
2245
|
-
),
|
|
2078
|
+
), Et = w(
|
|
2246
2079
|
"flex flex-col items-center justify-center text-center border border-border rounded-lg bg-background",
|
|
2247
2080
|
{
|
|
2248
2081
|
variants: {
|
|
@@ -2261,37 +2094,37 @@ const cardVariants = cva(
|
|
|
2261
2094
|
hasGrayBackground: !1
|
|
2262
2095
|
}
|
|
2263
2096
|
}
|
|
2264
|
-
),
|
|
2097
|
+
), Ct = w(
|
|
2265
2098
|
"flex flex-row items-center gap-3 mb-2"
|
|
2266
|
-
),
|
|
2267
|
-
function
|
|
2268
|
-
return /* @__PURE__ */
|
|
2099
|
+
), nr = H.forwardRef(
|
|
2100
|
+
function({ icon: t, title: i, subtitle: n, action: s, className: o, hasGrayBackground: l, ...d }, g) {
|
|
2101
|
+
return /* @__PURE__ */ r.jsxs(
|
|
2269
2102
|
"section",
|
|
2270
2103
|
{
|
|
2271
|
-
ref:
|
|
2272
|
-
className:
|
|
2104
|
+
ref: g,
|
|
2105
|
+
className: u(Et({ hasGrayBackground: l }), o),
|
|
2273
2106
|
role: "status",
|
|
2274
2107
|
"aria-label": "No results found",
|
|
2275
|
-
...
|
|
2108
|
+
...d,
|
|
2276
2109
|
children: [
|
|
2277
|
-
/* @__PURE__ */
|
|
2278
|
-
/* @__PURE__ */
|
|
2279
|
-
/* @__PURE__ */
|
|
2110
|
+
/* @__PURE__ */ r.jsxs("header", { className: Ct(), children: [
|
|
2111
|
+
/* @__PURE__ */ r.jsx(R, { as: t, size: "lg", color: "ghost", "aria-hidden": "true" }),
|
|
2112
|
+
/* @__PURE__ */ r.jsx(z, { as: "h2", fontSize: "lg", children: i })
|
|
2280
2113
|
] }),
|
|
2281
|
-
|
|
2282
|
-
s && /* @__PURE__ */
|
|
2114
|
+
n && /* @__PURE__ */ r.jsx(z, { as: "p", align: "center", color: "gray", className: "mb-4", children: n }),
|
|
2115
|
+
s && /* @__PURE__ */ r.jsx("div", { role: "group", "aria-label": "Available actions", children: s })
|
|
2283
2116
|
]
|
|
2284
2117
|
}
|
|
2285
2118
|
);
|
|
2286
2119
|
}
|
|
2287
|
-
),
|
|
2288
|
-
function
|
|
2289
|
-
const e =
|
|
2120
|
+
), se = P(null), zt = se.Provider;
|
|
2121
|
+
function U() {
|
|
2122
|
+
const e = F(se);
|
|
2290
2123
|
if (!e)
|
|
2291
2124
|
throw new Error("Table compound components must be used within <Table>");
|
|
2292
2125
|
return e;
|
|
2293
2126
|
}
|
|
2294
|
-
const
|
|
2127
|
+
const G = (e) => {
|
|
2295
2128
|
if (e < 1 || e > 12)
|
|
2296
2129
|
throw new Error("Column span must be between 1 and 12");
|
|
2297
2130
|
switch (e) {
|
|
@@ -2322,7 +2155,7 @@ const getTableColumnClass = (e) => {
|
|
|
2322
2155
|
default:
|
|
2323
2156
|
return "grid-cols-2";
|
|
2324
2157
|
}
|
|
2325
|
-
},
|
|
2158
|
+
}, Vt = (e) => {
|
|
2326
2159
|
if (e < 1 || e > 12)
|
|
2327
2160
|
throw new Error("Column span must be between 1 and 12");
|
|
2328
2161
|
switch (e) {
|
|
@@ -2353,124 +2186,124 @@ const getTableColumnClass = (e) => {
|
|
|
2353
2186
|
default:
|
|
2354
2187
|
return "col-span-2";
|
|
2355
2188
|
}
|
|
2356
|
-
},
|
|
2357
|
-
({ children: e, className: t, ...
|
|
2358
|
-
const { columns: s } =
|
|
2359
|
-
return /* @__PURE__ */
|
|
2189
|
+
}, It = f(
|
|
2190
|
+
({ children: e, className: t, ...i }, n) => {
|
|
2191
|
+
const { columns: s } = U();
|
|
2192
|
+
return /* @__PURE__ */ r.jsx(
|
|
2360
2193
|
"div",
|
|
2361
2194
|
{
|
|
2362
2195
|
role: "rowgroup",
|
|
2363
|
-
className:
|
|
2364
|
-
...
|
|
2365
|
-
ref:
|
|
2366
|
-
children: /* @__PURE__ */
|
|
2196
|
+
className: u("bg-neutral-soft", t),
|
|
2197
|
+
...i,
|
|
2198
|
+
ref: n,
|
|
2199
|
+
children: /* @__PURE__ */ r.jsx(
|
|
2367
2200
|
"div",
|
|
2368
2201
|
{
|
|
2369
2202
|
role: "row",
|
|
2370
|
-
className:
|
|
2203
|
+
className: u("grid gap-4", G(s)),
|
|
2371
2204
|
children: e
|
|
2372
2205
|
}
|
|
2373
2206
|
)
|
|
2374
2207
|
}
|
|
2375
2208
|
);
|
|
2376
2209
|
}
|
|
2377
|
-
),
|
|
2378
|
-
({ children: e, className: t, ...
|
|
2379
|
-
),
|
|
2380
|
-
({ children: e, className: t, ...
|
|
2381
|
-
const { columns: s } =
|
|
2382
|
-
return /* @__PURE__ */
|
|
2210
|
+
), Lt = f(
|
|
2211
|
+
({ children: e, className: t, ...i }, n) => /* @__PURE__ */ r.jsx("div", { role: "rowgroup", ref: n, className: u(t), ...i, children: e })
|
|
2212
|
+
), At = f(
|
|
2213
|
+
({ children: e, className: t, ...i }, n) => {
|
|
2214
|
+
const { columns: s } = U();
|
|
2215
|
+
return /* @__PURE__ */ r.jsx(
|
|
2383
2216
|
"div",
|
|
2384
2217
|
{
|
|
2385
2218
|
role: "rowgroup",
|
|
2386
|
-
className:
|
|
2387
|
-
...
|
|
2388
|
-
ref:
|
|
2389
|
-
children: /* @__PURE__ */
|
|
2219
|
+
className: u("bg-neutral-soft", t),
|
|
2220
|
+
...i,
|
|
2221
|
+
ref: n,
|
|
2222
|
+
children: /* @__PURE__ */ r.jsx(
|
|
2390
2223
|
"div",
|
|
2391
2224
|
{
|
|
2392
2225
|
role: "row",
|
|
2393
|
-
className:
|
|
2226
|
+
className: u("grid gap-4", G(s)),
|
|
2394
2227
|
children: e
|
|
2395
2228
|
}
|
|
2396
2229
|
)
|
|
2397
2230
|
}
|
|
2398
2231
|
);
|
|
2399
2232
|
}
|
|
2400
|
-
),
|
|
2401
|
-
({ children: e, className: t, ...
|
|
2402
|
-
const { columns: s } =
|
|
2403
|
-
return /* @__PURE__ */
|
|
2233
|
+
), Mt = f(
|
|
2234
|
+
({ children: e, className: t, ...i }, n) => {
|
|
2235
|
+
const { columns: s } = U();
|
|
2236
|
+
return /* @__PURE__ */ r.jsx(
|
|
2404
2237
|
"div",
|
|
2405
2238
|
{
|
|
2406
2239
|
role: "row",
|
|
2407
|
-
className:
|
|
2240
|
+
className: u(
|
|
2408
2241
|
"grid gap-4",
|
|
2409
|
-
|
|
2242
|
+
G(s),
|
|
2410
2243
|
"border-b border-border last:border-0",
|
|
2411
2244
|
t
|
|
2412
2245
|
),
|
|
2413
|
-
ref:
|
|
2414
|
-
...
|
|
2246
|
+
ref: n,
|
|
2247
|
+
...i,
|
|
2415
2248
|
children: e
|
|
2416
2249
|
}
|
|
2417
2250
|
);
|
|
2418
2251
|
}
|
|
2419
|
-
),
|
|
2420
|
-
({ as: e = "td", span: t, align:
|
|
2421
|
-
const
|
|
2422
|
-
let
|
|
2423
|
-
return
|
|
2252
|
+
), ne = f(
|
|
2253
|
+
({ as: e = "td", span: t, align: i = "left", children: n, className: s, ...o }, l) => {
|
|
2254
|
+
const d = e === "th" ? "columnheader" : "cell";
|
|
2255
|
+
let g = "text-left";
|
|
2256
|
+
return i === "center" ? g = "text-center" : i === "right" && (g = "text-right"), /* @__PURE__ */ r.jsx(
|
|
2424
2257
|
"div",
|
|
2425
2258
|
{
|
|
2426
|
-
ref:
|
|
2427
|
-
role:
|
|
2428
|
-
className:
|
|
2259
|
+
ref: l,
|
|
2260
|
+
role: d,
|
|
2261
|
+
className: u(
|
|
2429
2262
|
"px-4 py-2",
|
|
2430
2263
|
"[&:not(:last-child)]:border-r [&:not(:last-child)]:border-border",
|
|
2431
|
-
|
|
2432
|
-
|
|
2264
|
+
Vt(t),
|
|
2265
|
+
g,
|
|
2433
2266
|
"truncate overflow-hidden whitespace-nowrap",
|
|
2434
2267
|
s
|
|
2435
2268
|
),
|
|
2436
|
-
...
|
|
2437
|
-
children:
|
|
2269
|
+
...o,
|
|
2270
|
+
children: n
|
|
2438
2271
|
}
|
|
2439
2272
|
);
|
|
2440
2273
|
}
|
|
2441
|
-
),
|
|
2442
|
-
(e, t) => /* @__PURE__ */
|
|
2443
|
-
|
|
2274
|
+
), Rt = f(
|
|
2275
|
+
(e, t) => /* @__PURE__ */ r.jsx(
|
|
2276
|
+
ne,
|
|
2444
2277
|
{
|
|
2445
2278
|
...e,
|
|
2446
2279
|
as: "td",
|
|
2447
2280
|
ref: t,
|
|
2448
|
-
className:
|
|
2281
|
+
className: u(
|
|
2449
2282
|
"truncate overflow-hidden whitespace-nowrap",
|
|
2450
2283
|
e.className
|
|
2451
2284
|
)
|
|
2452
2285
|
}
|
|
2453
2286
|
)
|
|
2454
|
-
),
|
|
2455
|
-
(e, t) => /* @__PURE__ */
|
|
2456
|
-
|
|
2287
|
+
), St = f(
|
|
2288
|
+
(e, t) => /* @__PURE__ */ r.jsx(
|
|
2289
|
+
ne,
|
|
2457
2290
|
{
|
|
2458
2291
|
...e,
|
|
2459
2292
|
as: "th",
|
|
2460
2293
|
ref: t,
|
|
2461
|
-
className:
|
|
2294
|
+
className: u(
|
|
2462
2295
|
"truncate overflow-hidden whitespace-nowrap",
|
|
2463
2296
|
e.className
|
|
2464
2297
|
)
|
|
2465
2298
|
}
|
|
2466
2299
|
)
|
|
2467
|
-
),
|
|
2468
|
-
({ children: e, className: t, columns:
|
|
2300
|
+
), Wt = f(
|
|
2301
|
+
({ children: e, className: t, columns: i = 12, ...n }, s) => /* @__PURE__ */ r.jsx(zt, { value: { columns: i }, children: /* @__PURE__ */ r.jsx(
|
|
2469
2302
|
"div",
|
|
2470
2303
|
{
|
|
2471
2304
|
ref: s,
|
|
2472
2305
|
role: "table",
|
|
2473
|
-
className:
|
|
2306
|
+
className: u(
|
|
2474
2307
|
// Versaur design system: border, background, shadow, rounded, spacing
|
|
2475
2308
|
"w-full overflow-x-auto border border-border bg-background rounded-lg ",
|
|
2476
2309
|
"text-foreground",
|
|
@@ -2478,18 +2311,18 @@ const getTableColumnClass = (e) => {
|
|
|
2478
2311
|
"transition-colors",
|
|
2479
2312
|
t
|
|
2480
2313
|
),
|
|
2481
|
-
...
|
|
2314
|
+
...n,
|
|
2482
2315
|
children: e
|
|
2483
2316
|
}
|
|
2484
2317
|
) })
|
|
2485
|
-
),
|
|
2486
|
-
Header:
|
|
2487
|
-
HeaderItem:
|
|
2488
|
-
Body:
|
|
2489
|
-
Footer:
|
|
2490
|
-
Row:
|
|
2491
|
-
RowItem:
|
|
2492
|
-
}),
|
|
2318
|
+
), or = Object.assign(Wt, {
|
|
2319
|
+
Header: It,
|
|
2320
|
+
HeaderItem: St,
|
|
2321
|
+
Body: Lt,
|
|
2322
|
+
Footer: At,
|
|
2323
|
+
Row: Mt,
|
|
2324
|
+
RowItem: Rt
|
|
2325
|
+
}), Bt = w(
|
|
2493
2326
|
// Base classes
|
|
2494
2327
|
"block transition-colors duration-200",
|
|
2495
2328
|
{
|
|
@@ -2524,40 +2357,40 @@ const getTableColumnClass = (e) => {
|
|
|
2524
2357
|
shape: "rounded"
|
|
2525
2358
|
}
|
|
2526
2359
|
}
|
|
2527
|
-
),
|
|
2528
|
-
({ variant: e = "white", size: t = "md", shape:
|
|
2360
|
+
), ar = f(
|
|
2361
|
+
({ variant: e = "white", size: t = "md", shape: i = "rounded", className: n, ...s }, o) => /* @__PURE__ */ r.jsx(
|
|
2529
2362
|
"div",
|
|
2530
2363
|
{
|
|
2531
|
-
ref:
|
|
2532
|
-
className:
|
|
2364
|
+
ref: o,
|
|
2365
|
+
className: u(Bt({ variant: e, size: t, shape: i }), n),
|
|
2533
2366
|
...s
|
|
2534
2367
|
}
|
|
2535
2368
|
)
|
|
2536
2369
|
);
|
|
2537
|
-
function
|
|
2538
|
-
const [t,
|
|
2539
|
-
|
|
2540
|
-
},
|
|
2370
|
+
function Ot({ src: e }) {
|
|
2371
|
+
const [t, i] = L(!1), [n, s] = L(!1), o = _(!1), l = () => {
|
|
2372
|
+
i(!0);
|
|
2373
|
+
}, d = () => {
|
|
2541
2374
|
s(!0);
|
|
2542
2375
|
};
|
|
2543
|
-
return
|
|
2376
|
+
return A(() => {
|
|
2544
2377
|
if (!e) return;
|
|
2545
|
-
const
|
|
2546
|
-
return
|
|
2547
|
-
|
|
2548
|
-
},
|
|
2549
|
-
|
|
2378
|
+
const g = new Image();
|
|
2379
|
+
return g.src = e, g.onload = () => {
|
|
2380
|
+
o.current || i(!0);
|
|
2381
|
+
}, g.onerror = () => {
|
|
2382
|
+
o.current || s(!0);
|
|
2550
2383
|
}, () => {
|
|
2551
|
-
|
|
2384
|
+
o.current = !0;
|
|
2552
2385
|
};
|
|
2553
2386
|
}, [e]), {
|
|
2554
2387
|
loaded: t,
|
|
2555
|
-
errored:
|
|
2556
|
-
handleLoad:
|
|
2557
|
-
handleError:
|
|
2388
|
+
errored: n,
|
|
2389
|
+
handleLoad: l,
|
|
2390
|
+
handleError: d
|
|
2558
2391
|
};
|
|
2559
2392
|
}
|
|
2560
|
-
const
|
|
2393
|
+
const Ht = w("block object-cover", {
|
|
2561
2394
|
variants: {
|
|
2562
2395
|
position: {
|
|
2563
2396
|
cover: "object-cover",
|
|
@@ -2587,7 +2420,7 @@ const imageVariants = cva("block object-cover", {
|
|
|
2587
2420
|
size: "auto",
|
|
2588
2421
|
shape: "rectangle"
|
|
2589
2422
|
}
|
|
2590
|
-
}),
|
|
2423
|
+
}), oe = w(
|
|
2591
2424
|
"flex items-center justify-center bg-neutral-soft text-ghost border border-border",
|
|
2592
2425
|
{
|
|
2593
2426
|
variants: {
|
|
@@ -2610,140 +2443,139 @@ const imageVariants = cva("block object-cover", {
|
|
|
2610
2443
|
}
|
|
2611
2444
|
}
|
|
2612
2445
|
);
|
|
2613
|
-
function
|
|
2446
|
+
function Tt({
|
|
2614
2447
|
className: e,
|
|
2615
2448
|
shape: t,
|
|
2616
|
-
size:
|
|
2617
|
-
height:
|
|
2449
|
+
size: i,
|
|
2450
|
+
height: n,
|
|
2618
2451
|
width: s
|
|
2619
2452
|
}) {
|
|
2620
|
-
return /* @__PURE__ */
|
|
2621
|
-
|
|
2453
|
+
return /* @__PURE__ */ r.jsx(
|
|
2454
|
+
we,
|
|
2622
2455
|
{
|
|
2623
|
-
className:
|
|
2624
|
-
style: { height:
|
|
2456
|
+
className: u(oe({ shape: t, size: i }), e),
|
|
2457
|
+
style: { height: n, width: s }
|
|
2625
2458
|
}
|
|
2626
2459
|
);
|
|
2627
2460
|
}
|
|
2628
|
-
function
|
|
2461
|
+
function qt({
|
|
2629
2462
|
alt: e,
|
|
2630
2463
|
width: t,
|
|
2631
|
-
height:
|
|
2632
|
-
className:
|
|
2464
|
+
height: i,
|
|
2465
|
+
className: n,
|
|
2633
2466
|
style: s,
|
|
2634
|
-
shape:
|
|
2635
|
-
size:
|
|
2467
|
+
shape: o,
|
|
2468
|
+
size: l
|
|
2636
2469
|
}) {
|
|
2637
|
-
return /* @__PURE__ */
|
|
2470
|
+
return /* @__PURE__ */ r.jsxs(
|
|
2638
2471
|
"div",
|
|
2639
2472
|
{
|
|
2640
|
-
className:
|
|
2641
|
-
style: { width: t, height:
|
|
2473
|
+
className: oe({ shape: o, size: l, className: n }),
|
|
2474
|
+
style: { width: t, height: i, ...s },
|
|
2642
2475
|
"aria-label": e,
|
|
2643
2476
|
role: "img",
|
|
2644
2477
|
children: [
|
|
2645
|
-
/* @__PURE__ */
|
|
2646
|
-
|
|
2478
|
+
/* @__PURE__ */ r.jsx(
|
|
2479
|
+
be,
|
|
2647
2480
|
{
|
|
2648
2481
|
size: 32,
|
|
2649
2482
|
style: { opacity: 0.5, marginRight: 4 },
|
|
2650
2483
|
"aria-hidden": "true"
|
|
2651
2484
|
}
|
|
2652
2485
|
),
|
|
2653
|
-
/* @__PURE__ */
|
|
2486
|
+
/* @__PURE__ */ r.jsx("span", { style: { opacity: 0.7 }, children: e })
|
|
2654
2487
|
]
|
|
2655
2488
|
}
|
|
2656
2489
|
);
|
|
2657
2490
|
}
|
|
2658
|
-
const
|
|
2491
|
+
const $ = f(
|
|
2659
2492
|
({
|
|
2660
2493
|
src: e,
|
|
2661
2494
|
alt: t,
|
|
2662
|
-
onLoad:
|
|
2663
|
-
onError:
|
|
2495
|
+
onLoad: i,
|
|
2496
|
+
onError: n,
|
|
2664
2497
|
width: s,
|
|
2665
|
-
height:
|
|
2666
|
-
loading:
|
|
2667
|
-
position:
|
|
2668
|
-
size:
|
|
2669
|
-
shape:
|
|
2670
|
-
className:
|
|
2671
|
-
...
|
|
2672
|
-
},
|
|
2673
|
-
const { loaded:
|
|
2498
|
+
height: o,
|
|
2499
|
+
loading: l = "lazy",
|
|
2500
|
+
position: d = "cover",
|
|
2501
|
+
size: g = "auto",
|
|
2502
|
+
shape: h,
|
|
2503
|
+
className: m,
|
|
2504
|
+
...c
|
|
2505
|
+
}, v) => {
|
|
2506
|
+
const { loaded: y, errored: j, handleLoad: C, handleError: N } = Ot({
|
|
2674
2507
|
src: e
|
|
2675
|
-
}),
|
|
2676
|
-
return !
|
|
2677
|
-
|
|
2508
|
+
}), I = typeof s == "number" ? s : Number(s), S = typeof o == "number" ? o : Number(o);
|
|
2509
|
+
return !y && !j ? /* @__PURE__ */ r.jsx(
|
|
2510
|
+
Tt,
|
|
2678
2511
|
{
|
|
2679
|
-
shape:
|
|
2680
|
-
width:
|
|
2681
|
-
height:
|
|
2512
|
+
shape: h,
|
|
2513
|
+
width: I,
|
|
2514
|
+
height: S
|
|
2682
2515
|
}
|
|
2683
|
-
) :
|
|
2684
|
-
|
|
2516
|
+
) : j ? /* @__PURE__ */ r.jsx(
|
|
2517
|
+
qt,
|
|
2685
2518
|
{
|
|
2686
|
-
shape:
|
|
2519
|
+
shape: h,
|
|
2687
2520
|
alt: t,
|
|
2688
|
-
width:
|
|
2689
|
-
height:
|
|
2521
|
+
width: I,
|
|
2522
|
+
height: S
|
|
2690
2523
|
}
|
|
2691
|
-
) : /* @__PURE__ */
|
|
2524
|
+
) : /* @__PURE__ */ r.jsx(
|
|
2692
2525
|
"img",
|
|
2693
2526
|
{
|
|
2694
|
-
ref:
|
|
2527
|
+
ref: v,
|
|
2695
2528
|
src: e,
|
|
2696
2529
|
alt: t,
|
|
2697
|
-
width:
|
|
2698
|
-
height:
|
|
2699
|
-
loading:
|
|
2700
|
-
className:
|
|
2701
|
-
|
|
2702
|
-
position:
|
|
2703
|
-
size:
|
|
2704
|
-
shape:
|
|
2530
|
+
width: I,
|
|
2531
|
+
height: S,
|
|
2532
|
+
loading: l,
|
|
2533
|
+
className: u(
|
|
2534
|
+
Ht({
|
|
2535
|
+
position: d,
|
|
2536
|
+
size: g,
|
|
2537
|
+
shape: h
|
|
2705
2538
|
}),
|
|
2706
|
-
|
|
2539
|
+
m
|
|
2707
2540
|
),
|
|
2708
|
-
onLoad: (
|
|
2709
|
-
|
|
2541
|
+
onLoad: (W) => {
|
|
2542
|
+
C(), i?.(W);
|
|
2710
2543
|
},
|
|
2711
|
-
onError: (
|
|
2712
|
-
|
|
2544
|
+
onError: (W) => {
|
|
2545
|
+
N(), n?.(W);
|
|
2713
2546
|
},
|
|
2714
|
-
...
|
|
2547
|
+
...c
|
|
2715
2548
|
}
|
|
2716
2549
|
);
|
|
2717
2550
|
}
|
|
2718
|
-
),
|
|
2551
|
+
), lr = f((e, t) => /* @__PURE__ */ r.jsx($, { ref: t, ...e, shape: "circle" })), cr = f((e, t) => /* @__PURE__ */ r.jsx($, { ref: t, ...e, shape: "square" })), dr = f((e, t) => /* @__PURE__ */ r.jsx($, { ref: t, ...e, shape: "rectangle" }));
|
|
2719
2552
|
export {
|
|
2720
|
-
|
|
2721
|
-
|
|
2722
|
-
|
|
2723
|
-
|
|
2724
|
-
|
|
2725
|
-
|
|
2726
|
-
|
|
2727
|
-
|
|
2728
|
-
|
|
2729
|
-
|
|
2730
|
-
|
|
2731
|
-
|
|
2732
|
-
|
|
2733
|
-
|
|
2734
|
-
|
|
2735
|
-
|
|
2736
|
-
|
|
2737
|
-
|
|
2738
|
-
|
|
2739
|
-
|
|
2740
|
-
|
|
2741
|
-
|
|
2742
|
-
|
|
2743
|
-
|
|
2744
|
-
|
|
2745
|
-
|
|
2746
|
-
|
|
2747
|
-
|
|
2748
|
-
BaseImage as s
|
|
2553
|
+
$t as A,
|
|
2554
|
+
Qt as B,
|
|
2555
|
+
rr as C,
|
|
2556
|
+
ir as F,
|
|
2557
|
+
Z as H,
|
|
2558
|
+
R as I,
|
|
2559
|
+
M,
|
|
2560
|
+
nr as N,
|
|
2561
|
+
nt as O,
|
|
2562
|
+
or as T,
|
|
2563
|
+
Xt as a,
|
|
2564
|
+
Yt as b,
|
|
2565
|
+
Dt as c,
|
|
2566
|
+
He as d,
|
|
2567
|
+
Jt as e,
|
|
2568
|
+
Kt as f,
|
|
2569
|
+
Zt as g,
|
|
2570
|
+
re as h,
|
|
2571
|
+
er as i,
|
|
2572
|
+
tr as j,
|
|
2573
|
+
wt as k,
|
|
2574
|
+
sr as l,
|
|
2575
|
+
z as m,
|
|
2576
|
+
ar as n,
|
|
2577
|
+
lr as o,
|
|
2578
|
+
cr as p,
|
|
2579
|
+
dr as q,
|
|
2580
|
+
$ as r
|
|
2749
2581
|
};
|