@otfdashkit/ui 0.1.2 → 0.1.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +4 -4
- package/dist/index.js +1139 -542
- package/dist/index.mjs +1001 -411
- package/package.json +1 -1
- package/src/index.ts +7 -1
- package/src/primitives/Button/Button.tsx +2 -131
- package/src/primitives/button.tsx +52 -0
- package/src/primitives/cart-line-item.tsx +81 -0
- package/src/primitives/empty-cart.tsx +52 -0
- package/src/primitives/price-tag.tsx +62 -0
- package/src/primitives/quantity-stepper.tsx +92 -0
- package/src/primitives/variant-picker.tsx +74 -0
package/dist/index.js
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
var clsx = require('clsx');
|
|
4
4
|
var tailwindMerge = require('tailwind-merge');
|
|
5
|
-
var
|
|
5
|
+
var React137 = require('react');
|
|
6
6
|
var AccordionPrimitive = require('@radix-ui/react-accordion');
|
|
7
7
|
var lucideReact = require('lucide-react');
|
|
8
8
|
var jsxRuntime = require('react/jsx-runtime');
|
|
@@ -60,9 +60,9 @@ var zod = require('@hookform/resolvers/zod');
|
|
|
60
60
|
var z = require('zod');
|
|
61
61
|
var reactColorful = require('react-colorful');
|
|
62
62
|
var react = require('motion/react');
|
|
63
|
+
var reactVirtual = require('@tanstack/react-virtual');
|
|
63
64
|
var ReactCrop = require('react-image-crop');
|
|
64
65
|
require('react-image-crop/dist/ReactCrop.css');
|
|
65
|
-
var reactVirtual = require('@tanstack/react-virtual');
|
|
66
66
|
|
|
67
67
|
function _interopDefault (e) { return e && e.__esModule ? e : { default: e }; }
|
|
68
68
|
|
|
@@ -84,7 +84,7 @@ function _interopNamespace(e) {
|
|
|
84
84
|
return Object.freeze(n);
|
|
85
85
|
}
|
|
86
86
|
|
|
87
|
-
var
|
|
87
|
+
var React137__namespace = /*#__PURE__*/_interopNamespace(React137);
|
|
88
88
|
var AccordionPrimitive__namespace = /*#__PURE__*/_interopNamespace(AccordionPrimitive);
|
|
89
89
|
var AlertDialogPrimitive__namespace = /*#__PURE__*/_interopNamespace(AlertDialogPrimitive);
|
|
90
90
|
var AspectRatioPrimitive__namespace = /*#__PURE__*/_interopNamespace(AspectRatioPrimitive);
|
|
@@ -124,7 +124,7 @@ function cn(...inputs) {
|
|
|
124
124
|
return tailwindMerge.twMerge(clsx.clsx(inputs));
|
|
125
125
|
}
|
|
126
126
|
var Accordion = AccordionPrimitive__namespace.Root;
|
|
127
|
-
var AccordionItem =
|
|
127
|
+
var AccordionItem = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
128
128
|
AccordionPrimitive__namespace.Item,
|
|
129
129
|
{
|
|
130
130
|
ref,
|
|
@@ -133,7 +133,7 @@ var AccordionItem = React131__namespace.forwardRef(({ className, ...props }, ref
|
|
|
133
133
|
}
|
|
134
134
|
));
|
|
135
135
|
AccordionItem.displayName = "AccordionItem";
|
|
136
|
-
var AccordionTrigger =
|
|
136
|
+
var AccordionTrigger = React137__namespace.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(AccordionPrimitive__namespace.Header, { className: "flex", children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
137
137
|
AccordionPrimitive__namespace.Trigger,
|
|
138
138
|
{
|
|
139
139
|
ref,
|
|
@@ -149,7 +149,7 @@ var AccordionTrigger = React131__namespace.forwardRef(({ className, children, ..
|
|
|
149
149
|
}
|
|
150
150
|
) }));
|
|
151
151
|
AccordionTrigger.displayName = AccordionPrimitive__namespace.Trigger.displayName;
|
|
152
|
-
var AccordionContent =
|
|
152
|
+
var AccordionContent = React137__namespace.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
153
153
|
AccordionPrimitive__namespace.Content,
|
|
154
154
|
{
|
|
155
155
|
ref,
|
|
@@ -169,29 +169,67 @@ var buttonVariants = classVarianceAuthority.cva(
|
|
|
169
169
|
outline: "border border-border bg-transparent hover:bg-accent hover:text-accent-foreground",
|
|
170
170
|
ghost: "hover:bg-accent hover:text-accent-foreground",
|
|
171
171
|
destructive: "bg-destructive text-destructive-foreground hover:bg-destructive/90",
|
|
172
|
-
link: "text-primary underline-offset-4 hover:underline"
|
|
172
|
+
link: "text-primary underline-offset-4 hover:underline",
|
|
173
|
+
gradient: [
|
|
174
|
+
"bg-gradient-to-b from-primary to-[hsl(var(--primary)/0.8)]",
|
|
175
|
+
"text-primary-foreground",
|
|
176
|
+
"shadow-[0_1px_0_0_rgba(255,255,255,0.1)_inset,0_-1px_0_0_rgba(0,0,0,0.25)_inset]",
|
|
177
|
+
"hover:from-[hsl(var(--primary)/0.9)] hover:to-[hsl(var(--primary)/0.7)]",
|
|
178
|
+
"active:from-[hsl(var(--primary)/0.8)] active:to-[hsl(var(--primary)/0.6)]"
|
|
179
|
+
].join(" "),
|
|
180
|
+
texture: [
|
|
181
|
+
"relative border border-border/40",
|
|
182
|
+
"bg-gradient-to-b from-card to-[hsl(var(--card)/0.9)]",
|
|
183
|
+
"text-foreground",
|
|
184
|
+
"shadow-[0_0_0_1px_hsl(var(--border)/0.2)_inset]",
|
|
185
|
+
"hover:border-border/60 hover:bg-accent",
|
|
186
|
+
"active:shadow-none"
|
|
187
|
+
].join(" "),
|
|
188
|
+
// Loud by design: keep for primary CTAs. The sweep keyframe ships in themes/base.css.
|
|
189
|
+
shimmer: [
|
|
190
|
+
"relative isolate overflow-hidden",
|
|
191
|
+
"bg-primary text-primary-foreground",
|
|
192
|
+
"shadow-[0_1px_0_rgba(255,255,255,0.18)_inset,0_-1px_0_rgba(0,0,0,0.25)_inset]",
|
|
193
|
+
"hover:bg-primary/95",
|
|
194
|
+
"before:absolute before:inset-[-1px] before:rounded-[inherit] before:-z-10",
|
|
195
|
+
"before:bg-[conic-gradient(from_0deg,transparent_0deg,transparent_70deg,rgba(255,255,255,0.55)_90deg,transparent_110deg,transparent_360deg)]",
|
|
196
|
+
"before:animate-[shimmer-rotate_2.6s_linear_infinite] motion-reduce:before:animate-none",
|
|
197
|
+
"after:absolute after:inset-0 after:rounded-[inherit] after:pointer-events-none",
|
|
198
|
+
"after:bg-[linear-gradient(115deg,transparent_30%,rgba(255,255,255,0.22)_50%,transparent_70%)]",
|
|
199
|
+
"after:translate-x-[-120%] hover:after:translate-x-[120%] after:transition-transform after:duration-[900ms] after:ease-out"
|
|
200
|
+
].join(" ")
|
|
173
201
|
},
|
|
174
202
|
size: {
|
|
175
203
|
sm: "h-8 px-3 text-xs",
|
|
176
204
|
default: "h-9 px-4 py-2",
|
|
177
205
|
lg: "h-11 px-6 text-base",
|
|
178
|
-
|
|
206
|
+
xl: "h-12 px-8 text-base",
|
|
207
|
+
icon: "h-9 w-9",
|
|
208
|
+
"icon-sm": "h-7 w-7 p-0 text-xs"
|
|
179
209
|
}
|
|
180
210
|
},
|
|
181
211
|
defaultVariants: { variant: "default", size: "default" }
|
|
182
212
|
}
|
|
183
213
|
);
|
|
184
|
-
var Button =
|
|
214
|
+
var Button = React137__namespace.default.forwardRef(
|
|
185
215
|
({ className, variant, size, asChild = false, ...props }, ref) => {
|
|
186
216
|
const Comp = asChild ? reactSlot.Slot : "button";
|
|
187
217
|
return /* @__PURE__ */ jsxRuntime.jsx(Comp, { className: cn(buttonVariants({ variant, size }), className), ref, ...props });
|
|
188
218
|
}
|
|
189
219
|
);
|
|
190
220
|
Button.displayName = "Button";
|
|
221
|
+
var IconButton = React137__namespace.default.forwardRef(
|
|
222
|
+
({ icon, label, size = "default", variant = "ghost", className, asChild = false, ...props }, ref) => {
|
|
223
|
+
const Comp = asChild ? reactSlot.Slot : "button";
|
|
224
|
+
const sizeClass = size === "sm" ? "h-7 w-7" : size === "lg" ? "h-10 w-10" : "h-9 w-9";
|
|
225
|
+
return /* @__PURE__ */ jsxRuntime.jsx(Comp, { ref, "aria-label": label, className: cn(buttonVariants({ variant }), sizeClass, "p-0 shrink-0", className), ...props, children: icon });
|
|
226
|
+
}
|
|
227
|
+
);
|
|
228
|
+
IconButton.displayName = "IconButton";
|
|
191
229
|
var AlertDialog = AlertDialogPrimitive__namespace.Root;
|
|
192
230
|
var AlertDialogTrigger = AlertDialogPrimitive__namespace.Trigger;
|
|
193
231
|
var AlertDialogPortal = AlertDialogPrimitive__namespace.Portal;
|
|
194
|
-
var AlertDialogOverlay =
|
|
232
|
+
var AlertDialogOverlay = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
195
233
|
AlertDialogPrimitive__namespace.Overlay,
|
|
196
234
|
{
|
|
197
235
|
className: cn(
|
|
@@ -203,7 +241,7 @@ var AlertDialogOverlay = React131__namespace.forwardRef(({ className, ...props }
|
|
|
203
241
|
}
|
|
204
242
|
));
|
|
205
243
|
AlertDialogOverlay.displayName = AlertDialogPrimitive__namespace.Overlay.displayName;
|
|
206
|
-
var AlertDialogContent =
|
|
244
|
+
var AlertDialogContent = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(AlertDialogPortal, { children: [
|
|
207
245
|
/* @__PURE__ */ jsxRuntime.jsx(AlertDialogOverlay, {}),
|
|
208
246
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
209
247
|
AlertDialogPrimitive__namespace.Content,
|
|
@@ -246,7 +284,7 @@ var AlertDialogFooter = ({
|
|
|
246
284
|
}
|
|
247
285
|
);
|
|
248
286
|
AlertDialogFooter.displayName = "AlertDialogFooter";
|
|
249
|
-
var AlertDialogTitle =
|
|
287
|
+
var AlertDialogTitle = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
250
288
|
AlertDialogPrimitive__namespace.Title,
|
|
251
289
|
{
|
|
252
290
|
ref,
|
|
@@ -255,7 +293,7 @@ var AlertDialogTitle = React131__namespace.forwardRef(({ className, ...props },
|
|
|
255
293
|
}
|
|
256
294
|
));
|
|
257
295
|
AlertDialogTitle.displayName = AlertDialogPrimitive__namespace.Title.displayName;
|
|
258
|
-
var AlertDialogDescription =
|
|
296
|
+
var AlertDialogDescription = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
259
297
|
AlertDialogPrimitive__namespace.Description,
|
|
260
298
|
{
|
|
261
299
|
ref,
|
|
@@ -264,7 +302,7 @@ var AlertDialogDescription = React131__namespace.forwardRef(({ className, ...pro
|
|
|
264
302
|
}
|
|
265
303
|
));
|
|
266
304
|
AlertDialogDescription.displayName = AlertDialogPrimitive__namespace.Description.displayName;
|
|
267
|
-
var AlertDialogAction =
|
|
305
|
+
var AlertDialogAction = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
268
306
|
AlertDialogPrimitive__namespace.Action,
|
|
269
307
|
{
|
|
270
308
|
ref,
|
|
@@ -273,7 +311,7 @@ var AlertDialogAction = React131__namespace.forwardRef(({ className, ...props },
|
|
|
273
311
|
}
|
|
274
312
|
));
|
|
275
313
|
AlertDialogAction.displayName = AlertDialogPrimitive__namespace.Action.displayName;
|
|
276
|
-
var AlertDialogCancel =
|
|
314
|
+
var AlertDialogCancel = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
277
315
|
AlertDialogPrimitive__namespace.Cancel,
|
|
278
316
|
{
|
|
279
317
|
ref,
|
|
@@ -300,7 +338,7 @@ var alertVariants = classVarianceAuthority.cva(
|
|
|
300
338
|
}
|
|
301
339
|
}
|
|
302
340
|
);
|
|
303
|
-
var Alert =
|
|
341
|
+
var Alert = React137__namespace.forwardRef(({ className, variant, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
304
342
|
"div",
|
|
305
343
|
{
|
|
306
344
|
ref,
|
|
@@ -310,7 +348,7 @@ var Alert = React131__namespace.forwardRef(({ className, variant, ...props }, re
|
|
|
310
348
|
}
|
|
311
349
|
));
|
|
312
350
|
Alert.displayName = "Alert";
|
|
313
|
-
var AlertTitle =
|
|
351
|
+
var AlertTitle = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
314
352
|
"h5",
|
|
315
353
|
{
|
|
316
354
|
ref,
|
|
@@ -319,7 +357,7 @@ var AlertTitle = React131__namespace.forwardRef(({ className, ...props }, ref) =
|
|
|
319
357
|
}
|
|
320
358
|
));
|
|
321
359
|
AlertTitle.displayName = "AlertTitle";
|
|
322
|
-
var AlertDescription =
|
|
360
|
+
var AlertDescription = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
323
361
|
"div",
|
|
324
362
|
{
|
|
325
363
|
ref,
|
|
@@ -329,7 +367,7 @@ var AlertDescription = React131__namespace.forwardRef(({ className, ...props },
|
|
|
329
367
|
));
|
|
330
368
|
AlertDescription.displayName = "AlertDescription";
|
|
331
369
|
var AspectRatio = AspectRatioPrimitive__namespace.Root;
|
|
332
|
-
var Avatar =
|
|
370
|
+
var Avatar = React137__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
333
371
|
AvatarPrimitive__namespace.Root,
|
|
334
372
|
{
|
|
335
373
|
ref,
|
|
@@ -338,9 +376,9 @@ var Avatar = React131__namespace.default.forwardRef(({ className, ...props }, re
|
|
|
338
376
|
}
|
|
339
377
|
));
|
|
340
378
|
Avatar.displayName = AvatarPrimitive__namespace.Root.displayName;
|
|
341
|
-
var AvatarImage =
|
|
379
|
+
var AvatarImage = React137__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(AvatarPrimitive__namespace.Image, { ref, className: cn("aspect-square h-full w-full object-cover", className), ...props }));
|
|
342
380
|
AvatarImage.displayName = AvatarPrimitive__namespace.Image.displayName;
|
|
343
|
-
var AvatarFallback =
|
|
381
|
+
var AvatarFallback = React137__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
344
382
|
AvatarPrimitive__namespace.Fallback,
|
|
345
383
|
{
|
|
346
384
|
ref,
|
|
@@ -349,15 +387,15 @@ var AvatarFallback = React131__namespace.default.forwardRef(({ className, ...pro
|
|
|
349
387
|
}
|
|
350
388
|
));
|
|
351
389
|
AvatarFallback.displayName = AvatarPrimitive__namespace.Fallback.displayName;
|
|
352
|
-
var AvatarGroup =
|
|
390
|
+
var AvatarGroup = React137__namespace.default.forwardRef(
|
|
353
391
|
({ className, max = 4, size = 32, spacing, renderOverflow, children, ...props }, ref) => {
|
|
354
|
-
const items =
|
|
392
|
+
const items = React137__namespace.default.Children.toArray(children).filter(React137__namespace.default.isValidElement);
|
|
355
393
|
const overlap = spacing ?? Math.round(size / 3);
|
|
356
394
|
const visible = items.slice(0, max);
|
|
357
395
|
const remaining = Math.max(0, items.length - max);
|
|
358
396
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { ref, className: cn("flex items-center", className), "data-slot": "avatar-group", ...props, children: [
|
|
359
397
|
visible.map(
|
|
360
|
-
(child, i) =>
|
|
398
|
+
(child, i) => React137__namespace.default.cloneElement(child, {
|
|
361
399
|
key: child.key ?? i,
|
|
362
400
|
style: {
|
|
363
401
|
width: size,
|
|
@@ -563,8 +601,8 @@ function CalendarDayButton({
|
|
|
563
601
|
...props
|
|
564
602
|
}) {
|
|
565
603
|
const defaultClassNames = reactDayPicker.getDefaultClassNames();
|
|
566
|
-
const ref =
|
|
567
|
-
|
|
604
|
+
const ref = React137__namespace.useRef(null);
|
|
605
|
+
React137__namespace.useEffect(() => {
|
|
568
606
|
if (modifiers.focused) ref.current?.focus();
|
|
569
607
|
}, [modifiers.focused]);
|
|
570
608
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -587,7 +625,7 @@ function CalendarDayButton({
|
|
|
587
625
|
}
|
|
588
626
|
);
|
|
589
627
|
}
|
|
590
|
-
var Card =
|
|
628
|
+
var Card = React137__namespace.default.forwardRef(
|
|
591
629
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
592
630
|
"div",
|
|
593
631
|
{
|
|
@@ -598,35 +636,35 @@ var Card = React131__namespace.default.forwardRef(
|
|
|
598
636
|
)
|
|
599
637
|
);
|
|
600
638
|
Card.displayName = "Card";
|
|
601
|
-
var CardHeader =
|
|
639
|
+
var CardHeader = React137__namespace.default.forwardRef(
|
|
602
640
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("flex flex-col space-y-1.5 p-6", className), ...props })
|
|
603
641
|
);
|
|
604
642
|
CardHeader.displayName = "CardHeader";
|
|
605
|
-
var CardTitle =
|
|
643
|
+
var CardTitle = React137__namespace.default.forwardRef(
|
|
606
644
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("font-semibold leading-none tracking-tight", className), ...props })
|
|
607
645
|
);
|
|
608
646
|
CardTitle.displayName = "CardTitle";
|
|
609
|
-
var CardDescription =
|
|
647
|
+
var CardDescription = React137__namespace.default.forwardRef(
|
|
610
648
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("text-sm text-muted-foreground", className), ...props })
|
|
611
649
|
);
|
|
612
650
|
CardDescription.displayName = "CardDescription";
|
|
613
|
-
var CardContent =
|
|
651
|
+
var CardContent = React137__namespace.default.forwardRef(
|
|
614
652
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("p-6 pt-0", className), ...props })
|
|
615
653
|
);
|
|
616
654
|
CardContent.displayName = "CardContent";
|
|
617
|
-
var CardFooter =
|
|
655
|
+
var CardFooter = React137__namespace.default.forwardRef(
|
|
618
656
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("flex items-center p-6 pt-0", className), ...props })
|
|
619
657
|
);
|
|
620
658
|
CardFooter.displayName = "CardFooter";
|
|
621
|
-
var CarouselContext =
|
|
659
|
+
var CarouselContext = React137__namespace.createContext(null);
|
|
622
660
|
function useCarousel() {
|
|
623
|
-
const context =
|
|
661
|
+
const context = React137__namespace.useContext(CarouselContext);
|
|
624
662
|
if (!context) {
|
|
625
663
|
throw new Error("useCarousel must be used within a <Carousel />");
|
|
626
664
|
}
|
|
627
665
|
return context;
|
|
628
666
|
}
|
|
629
|
-
var Carousel =
|
|
667
|
+
var Carousel = React137__namespace.forwardRef(
|
|
630
668
|
({
|
|
631
669
|
orientation = "horizontal",
|
|
632
670
|
opts,
|
|
@@ -643,22 +681,22 @@ var Carousel = React131__namespace.forwardRef(
|
|
|
643
681
|
},
|
|
644
682
|
plugins
|
|
645
683
|
);
|
|
646
|
-
const [canScrollPrev, setCanScrollPrev] =
|
|
647
|
-
const [canScrollNext, setCanScrollNext] =
|
|
648
|
-
const onSelect =
|
|
684
|
+
const [canScrollPrev, setCanScrollPrev] = React137__namespace.useState(false);
|
|
685
|
+
const [canScrollNext, setCanScrollNext] = React137__namespace.useState(false);
|
|
686
|
+
const onSelect = React137__namespace.useCallback((api2) => {
|
|
649
687
|
if (!api2) {
|
|
650
688
|
return;
|
|
651
689
|
}
|
|
652
690
|
setCanScrollPrev(api2.canScrollPrev());
|
|
653
691
|
setCanScrollNext(api2.canScrollNext());
|
|
654
692
|
}, []);
|
|
655
|
-
const scrollPrev =
|
|
693
|
+
const scrollPrev = React137__namespace.useCallback(() => {
|
|
656
694
|
api?.scrollPrev();
|
|
657
695
|
}, [api]);
|
|
658
|
-
const scrollNext =
|
|
696
|
+
const scrollNext = React137__namespace.useCallback(() => {
|
|
659
697
|
api?.scrollNext();
|
|
660
698
|
}, [api]);
|
|
661
|
-
const handleKeyDown =
|
|
699
|
+
const handleKeyDown = React137__namespace.useCallback(
|
|
662
700
|
(event) => {
|
|
663
701
|
if (event.key === "ArrowLeft") {
|
|
664
702
|
event.preventDefault();
|
|
@@ -670,13 +708,13 @@ var Carousel = React131__namespace.forwardRef(
|
|
|
670
708
|
},
|
|
671
709
|
[scrollPrev, scrollNext]
|
|
672
710
|
);
|
|
673
|
-
|
|
711
|
+
React137__namespace.useEffect(() => {
|
|
674
712
|
if (!api || !setApi) {
|
|
675
713
|
return;
|
|
676
714
|
}
|
|
677
715
|
setApi(api);
|
|
678
716
|
}, [api, setApi]);
|
|
679
|
-
|
|
717
|
+
React137__namespace.useEffect(() => {
|
|
680
718
|
if (!api) {
|
|
681
719
|
return;
|
|
682
720
|
}
|
|
@@ -717,7 +755,7 @@ var Carousel = React131__namespace.forwardRef(
|
|
|
717
755
|
}
|
|
718
756
|
);
|
|
719
757
|
Carousel.displayName = "Carousel";
|
|
720
|
-
var CarouselContent =
|
|
758
|
+
var CarouselContent = React137__namespace.forwardRef(({ className, ...props }, ref) => {
|
|
721
759
|
const { carouselRef, orientation } = useCarousel();
|
|
722
760
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { ref: carouselRef, className: "overflow-hidden", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
723
761
|
"div",
|
|
@@ -733,7 +771,7 @@ var CarouselContent = React131__namespace.forwardRef(({ className, ...props }, r
|
|
|
733
771
|
) });
|
|
734
772
|
});
|
|
735
773
|
CarouselContent.displayName = "CarouselContent";
|
|
736
|
-
var CarouselItem =
|
|
774
|
+
var CarouselItem = React137__namespace.forwardRef(({ className, ...props }, ref) => {
|
|
737
775
|
const { orientation } = useCarousel();
|
|
738
776
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
739
777
|
"div",
|
|
@@ -751,7 +789,7 @@ var CarouselItem = React131__namespace.forwardRef(({ className, ...props }, ref)
|
|
|
751
789
|
);
|
|
752
790
|
});
|
|
753
791
|
CarouselItem.displayName = "CarouselItem";
|
|
754
|
-
var CarouselPrevious =
|
|
792
|
+
var CarouselPrevious = React137__namespace.forwardRef(({ className, variant = "outline", size = "icon", ...props }, ref) => {
|
|
755
793
|
const { orientation, scrollPrev, canScrollPrev } = useCarousel();
|
|
756
794
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
757
795
|
Button,
|
|
@@ -775,7 +813,7 @@ var CarouselPrevious = React131__namespace.forwardRef(({ className, variant = "o
|
|
|
775
813
|
);
|
|
776
814
|
});
|
|
777
815
|
CarouselPrevious.displayName = "CarouselPrevious";
|
|
778
|
-
var CarouselNext =
|
|
816
|
+
var CarouselNext = React137__namespace.forwardRef(({ className, variant = "outline", size = "icon", ...props }, ref) => {
|
|
779
817
|
const { orientation, scrollNext, canScrollNext } = useCarousel();
|
|
780
818
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
781
819
|
Button,
|
|
@@ -799,17 +837,173 @@ var CarouselNext = React131__namespace.forwardRef(({ className, variant = "outli
|
|
|
799
837
|
);
|
|
800
838
|
});
|
|
801
839
|
CarouselNext.displayName = "CarouselNext";
|
|
840
|
+
var SIZE = {
|
|
841
|
+
sm: { price: "text-sm", compare: "text-xs" },
|
|
842
|
+
md: { price: "text-lg", compare: "text-sm" },
|
|
843
|
+
lg: { price: "text-2xl", compare: "text-base" }
|
|
844
|
+
};
|
|
845
|
+
function formatMoney(minor, currency, locale) {
|
|
846
|
+
return new Intl.NumberFormat(locale, { style: "currency", currency }).format(minor / 100);
|
|
847
|
+
}
|
|
848
|
+
var PriceTag = React137__namespace.default.forwardRef(
|
|
849
|
+
({ amount, compareAt, currency = "USD", locale = "en-US", size = "md", showDiscount = true, className, ...props }, ref) => {
|
|
850
|
+
const onSale = compareAt !== void 0 && compareAt > amount;
|
|
851
|
+
const pct = onSale ? Math.round((1 - amount / compareAt) * 100) : 0;
|
|
852
|
+
const s = SIZE[size];
|
|
853
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("span", { ref, className: cn("inline-flex items-baseline gap-2 font-sans tabular-nums", className), ...props, children: [
|
|
854
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: cn("font-semibold tracking-tight text-foreground", s.price), children: formatMoney(amount, currency, locale) }),
|
|
855
|
+
onSale && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
856
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: cn("text-muted-foreground line-through", s.compare), children: formatMoney(compareAt, currency, locale) }),
|
|
857
|
+
showDiscount && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "rounded-full bg-destructive/10 px-2 py-0.5 text-xs font-semibold text-destructive", children: [
|
|
858
|
+
"\u2212",
|
|
859
|
+
pct,
|
|
860
|
+
"%"
|
|
861
|
+
] })
|
|
862
|
+
] })
|
|
863
|
+
] });
|
|
864
|
+
}
|
|
865
|
+
);
|
|
866
|
+
PriceTag.displayName = "PriceTag";
|
|
867
|
+
var QuantityStepper = React137__namespace.default.forwardRef(
|
|
868
|
+
({
|
|
869
|
+
value: valueProp,
|
|
870
|
+
defaultValue = 1,
|
|
871
|
+
onValueChange,
|
|
872
|
+
min = 1,
|
|
873
|
+
max = 99,
|
|
874
|
+
step = 1,
|
|
875
|
+
size = "md",
|
|
876
|
+
disabled = false,
|
|
877
|
+
className,
|
|
878
|
+
"aria-label": ariaLabel = "Quantity",
|
|
879
|
+
...props
|
|
880
|
+
}, ref) => {
|
|
881
|
+
const isControlled = valueProp !== void 0;
|
|
882
|
+
const [internal, setInternal] = React137__namespace.default.useState(defaultValue);
|
|
883
|
+
const value = isControlled ? valueProp : internal;
|
|
884
|
+
const commit = (next) => {
|
|
885
|
+
const clamped = Math.max(min, Math.min(max, next));
|
|
886
|
+
if (!isControlled) setInternal(clamped);
|
|
887
|
+
onValueChange?.(clamped);
|
|
888
|
+
};
|
|
889
|
+
const dim = size === "sm" ? "h-7 w-7" : "h-9 w-9";
|
|
890
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
891
|
+
"div",
|
|
892
|
+
{
|
|
893
|
+
ref,
|
|
894
|
+
role: "group",
|
|
895
|
+
"aria-label": ariaLabel,
|
|
896
|
+
className: cn("inline-flex items-center rounded-md border border-input", className),
|
|
897
|
+
...props,
|
|
898
|
+
children: [
|
|
899
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
900
|
+
Button,
|
|
901
|
+
{
|
|
902
|
+
type: "button",
|
|
903
|
+
variant: "ghost",
|
|
904
|
+
size: "icon",
|
|
905
|
+
className: cn("rounded-r-none", dim),
|
|
906
|
+
disabled: disabled || value <= min,
|
|
907
|
+
onClick: () => commit(value - step),
|
|
908
|
+
"aria-label": "Decrease quantity",
|
|
909
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Minus, { className: "h-4 w-4" })
|
|
910
|
+
}
|
|
911
|
+
),
|
|
912
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
913
|
+
"span",
|
|
914
|
+
{
|
|
915
|
+
"aria-live": "polite",
|
|
916
|
+
className: cn("select-none text-center text-sm font-medium tabular-nums", size === "sm" ? "min-w-7" : "min-w-8"),
|
|
917
|
+
children: value
|
|
918
|
+
}
|
|
919
|
+
),
|
|
920
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
921
|
+
Button,
|
|
922
|
+
{
|
|
923
|
+
type: "button",
|
|
924
|
+
variant: "ghost",
|
|
925
|
+
size: "icon",
|
|
926
|
+
className: cn("rounded-l-none", dim),
|
|
927
|
+
disabled: disabled || value >= max,
|
|
928
|
+
onClick: () => commit(value + step),
|
|
929
|
+
"aria-label": "Increase quantity",
|
|
930
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Plus, { className: "h-4 w-4" })
|
|
931
|
+
}
|
|
932
|
+
)
|
|
933
|
+
]
|
|
934
|
+
}
|
|
935
|
+
);
|
|
936
|
+
}
|
|
937
|
+
);
|
|
938
|
+
QuantityStepper.displayName = "QuantityStepper";
|
|
939
|
+
var CartLineItem = React137__namespace.default.forwardRef(
|
|
940
|
+
({
|
|
941
|
+
image,
|
|
942
|
+
title,
|
|
943
|
+
variant,
|
|
944
|
+
price,
|
|
945
|
+
compareAt,
|
|
946
|
+
currency = "USD",
|
|
947
|
+
quantity,
|
|
948
|
+
onQuantityChange,
|
|
949
|
+
onRemove,
|
|
950
|
+
minQuantity = 1,
|
|
951
|
+
maxQuantity = 99,
|
|
952
|
+
className,
|
|
953
|
+
...props
|
|
954
|
+
}, ref) => {
|
|
955
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
956
|
+
"div",
|
|
957
|
+
{
|
|
958
|
+
ref,
|
|
959
|
+
className: cn("flex items-center gap-4 rounded-lg border border-border bg-card p-3", className),
|
|
960
|
+
...props,
|
|
961
|
+
children: [
|
|
962
|
+
image && /* @__PURE__ */ jsxRuntime.jsx("img", { src: image, alt: "", className: "h-16 w-16 flex-none rounded-md object-cover" }),
|
|
963
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex min-w-0 flex-1 flex-col gap-1", children: [
|
|
964
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "truncate font-medium text-card-foreground", children: title }),
|
|
965
|
+
variant && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "truncate text-sm text-muted-foreground", children: variant }),
|
|
966
|
+
/* @__PURE__ */ jsxRuntime.jsx(PriceTag, { amount: price, compareAt, currency, size: "sm" })
|
|
967
|
+
] }),
|
|
968
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
969
|
+
QuantityStepper,
|
|
970
|
+
{
|
|
971
|
+
value: quantity,
|
|
972
|
+
min: minQuantity,
|
|
973
|
+
max: maxQuantity,
|
|
974
|
+
onValueChange: onQuantityChange,
|
|
975
|
+
size: "sm"
|
|
976
|
+
}
|
|
977
|
+
),
|
|
978
|
+
onRemove && /* @__PURE__ */ jsxRuntime.jsx(
|
|
979
|
+
Button,
|
|
980
|
+
{
|
|
981
|
+
type: "button",
|
|
982
|
+
variant: "ghost",
|
|
983
|
+
size: "icon",
|
|
984
|
+
className: "h-8 w-8 text-muted-foreground hover:text-destructive",
|
|
985
|
+
onClick: onRemove,
|
|
986
|
+
"aria-label": `Remove ${title}`,
|
|
987
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.X, { className: "h-4 w-4" })
|
|
988
|
+
}
|
|
989
|
+
)
|
|
990
|
+
]
|
|
991
|
+
}
|
|
992
|
+
);
|
|
993
|
+
}
|
|
994
|
+
);
|
|
995
|
+
CartLineItem.displayName = "CartLineItem";
|
|
802
996
|
var THEMES = { light: "", dark: ".dark" };
|
|
803
|
-
var ChartContext =
|
|
997
|
+
var ChartContext = React137__namespace.createContext(null);
|
|
804
998
|
function useChart() {
|
|
805
|
-
const context =
|
|
999
|
+
const context = React137__namespace.useContext(ChartContext);
|
|
806
1000
|
if (!context) {
|
|
807
1001
|
throw new Error("useChart must be used within a <ChartContainer />");
|
|
808
1002
|
}
|
|
809
1003
|
return context;
|
|
810
1004
|
}
|
|
811
|
-
var ChartContainer =
|
|
812
|
-
const uniqueId =
|
|
1005
|
+
var ChartContainer = React137__namespace.forwardRef(({ id, className, children, config, ...props }, ref) => {
|
|
1006
|
+
const uniqueId = React137__namespace.useId();
|
|
813
1007
|
const chartId = `chart-${id || uniqueId.replace(/:/g, "")}`;
|
|
814
1008
|
return /* @__PURE__ */ jsxRuntime.jsx(ChartContext.Provider, { value: { config }, children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
815
1009
|
"div",
|
|
@@ -855,7 +1049,7 @@ ${colorConfig.map(([key, itemConfig]) => {
|
|
|
855
1049
|
);
|
|
856
1050
|
};
|
|
857
1051
|
var ChartTooltip = RechartsPrimitive__namespace.Tooltip;
|
|
858
|
-
var ChartTooltipContent =
|
|
1052
|
+
var ChartTooltipContent = React137__namespace.forwardRef(
|
|
859
1053
|
({
|
|
860
1054
|
active,
|
|
861
1055
|
payload,
|
|
@@ -872,7 +1066,7 @@ var ChartTooltipContent = React131__namespace.forwardRef(
|
|
|
872
1066
|
labelKey
|
|
873
1067
|
}, ref) => {
|
|
874
1068
|
const { config } = useChart();
|
|
875
|
-
const tooltipLabel =
|
|
1069
|
+
const tooltipLabel = React137__namespace.useMemo(() => {
|
|
876
1070
|
if (hideLabel || !payload?.length) {
|
|
877
1071
|
return null;
|
|
878
1072
|
}
|
|
@@ -968,7 +1162,7 @@ var ChartTooltipContent = React131__namespace.forwardRef(
|
|
|
968
1162
|
);
|
|
969
1163
|
ChartTooltipContent.displayName = "ChartTooltip";
|
|
970
1164
|
var ChartLegend = RechartsPrimitive__namespace.Legend;
|
|
971
|
-
var ChartLegendContent =
|
|
1165
|
+
var ChartLegendContent = React137__namespace.forwardRef(
|
|
972
1166
|
({ className, hideIcon = false, payload, verticalAlign = "bottom", nameKey }, ref) => {
|
|
973
1167
|
const { config } = useChart();
|
|
974
1168
|
if (!payload?.length) {
|
|
@@ -1026,7 +1220,7 @@ function getPayloadConfigFromPayload(config, payload, key) {
|
|
|
1026
1220
|
}
|
|
1027
1221
|
return configLabelKey in config ? config[configLabelKey] : config[key];
|
|
1028
1222
|
}
|
|
1029
|
-
var Checkbox =
|
|
1223
|
+
var Checkbox = React137__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1030
1224
|
CheckboxPrimitive__namespace.Root,
|
|
1031
1225
|
{
|
|
1032
1226
|
ref,
|
|
@@ -1066,7 +1260,7 @@ function detectTheme(node) {
|
|
|
1066
1260
|
}
|
|
1067
1261
|
return document.documentElement.classList.contains("dark") ? "dark" : "light";
|
|
1068
1262
|
}
|
|
1069
|
-
var CodeBlock =
|
|
1263
|
+
var CodeBlock = React137__namespace.default.forwardRef(
|
|
1070
1264
|
({
|
|
1071
1265
|
code,
|
|
1072
1266
|
language = "tsx",
|
|
@@ -1077,10 +1271,10 @@ var CodeBlock = React131__namespace.default.forwardRef(
|
|
|
1077
1271
|
className,
|
|
1078
1272
|
...props
|
|
1079
1273
|
}, ref) => {
|
|
1080
|
-
const containerRef =
|
|
1081
|
-
const [html, setHtml] =
|
|
1082
|
-
const [copied, setCopied] =
|
|
1083
|
-
|
|
1274
|
+
const containerRef = React137__namespace.default.useRef(null);
|
|
1275
|
+
const [html, setHtml] = React137__namespace.default.useState(null);
|
|
1276
|
+
const [copied, setCopied] = React137__namespace.default.useState(false);
|
|
1277
|
+
React137__namespace.default.useEffect(() => {
|
|
1084
1278
|
let cancelled = false;
|
|
1085
1279
|
getHighlighter().then((hl) => {
|
|
1086
1280
|
if (cancelled) return;
|
|
@@ -1095,7 +1289,7 @@ var CodeBlock = React131__namespace.default.forwardRef(
|
|
|
1095
1289
|
cancelled = true;
|
|
1096
1290
|
};
|
|
1097
1291
|
}, [code, language, theme]);
|
|
1098
|
-
const onCopy =
|
|
1292
|
+
const onCopy = React137__namespace.default.useCallback(async () => {
|
|
1099
1293
|
try {
|
|
1100
1294
|
await navigator.clipboard.writeText(code);
|
|
1101
1295
|
setCopied(true);
|
|
@@ -1103,7 +1297,7 @@ var CodeBlock = React131__namespace.default.forwardRef(
|
|
|
1103
1297
|
} catch {
|
|
1104
1298
|
}
|
|
1105
1299
|
}, [code]);
|
|
1106
|
-
const lines =
|
|
1300
|
+
const lines = React137__namespace.default.useMemo(() => code.split("\n"), [code]);
|
|
1107
1301
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
1108
1302
|
"div",
|
|
1109
1303
|
{
|
|
@@ -1171,7 +1365,7 @@ var Dialog = DialogPrimitive__namespace.Root;
|
|
|
1171
1365
|
var DialogTrigger = DialogPrimitive__namespace.Trigger;
|
|
1172
1366
|
var DialogPortal = DialogPrimitive__namespace.Portal;
|
|
1173
1367
|
var DialogClose = DialogPrimitive__namespace.Close;
|
|
1174
|
-
var DialogOverlay =
|
|
1368
|
+
var DialogOverlay = React137__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1175
1369
|
DialogPrimitive__namespace.Overlay,
|
|
1176
1370
|
{
|
|
1177
1371
|
ref,
|
|
@@ -1185,7 +1379,7 @@ var DialogOverlay = React131__namespace.default.forwardRef(({ className, ...prop
|
|
|
1185
1379
|
}
|
|
1186
1380
|
));
|
|
1187
1381
|
DialogOverlay.displayName = DialogPrimitive__namespace.Overlay.displayName;
|
|
1188
|
-
var DialogContent =
|
|
1382
|
+
var DialogContent = React137__namespace.default.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(DialogPortal, { children: [
|
|
1189
1383
|
/* @__PURE__ */ jsxRuntime.jsx(DialogOverlay, {}),
|
|
1190
1384
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
1191
1385
|
DialogPrimitive__namespace.Content,
|
|
@@ -1215,7 +1409,7 @@ var DialogHeader = ({ className, ...props }) => /* @__PURE__ */ jsxRuntime.jsx("
|
|
|
1215
1409
|
DialogHeader.displayName = "DialogHeader";
|
|
1216
1410
|
var DialogFooter = ({ className, ...props }) => /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2", className), ...props });
|
|
1217
1411
|
DialogFooter.displayName = "DialogFooter";
|
|
1218
|
-
var DialogTitle =
|
|
1412
|
+
var DialogTitle = React137__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1219
1413
|
DialogPrimitive__namespace.Title,
|
|
1220
1414
|
{
|
|
1221
1415
|
ref,
|
|
@@ -1224,7 +1418,7 @@ var DialogTitle = React131__namespace.default.forwardRef(({ className, ...props
|
|
|
1224
1418
|
}
|
|
1225
1419
|
));
|
|
1226
1420
|
DialogTitle.displayName = DialogPrimitive__namespace.Title.displayName;
|
|
1227
|
-
var DialogDescription =
|
|
1421
|
+
var DialogDescription = React137__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1228
1422
|
DialogPrimitive__namespace.Description,
|
|
1229
1423
|
{
|
|
1230
1424
|
ref,
|
|
@@ -1233,7 +1427,7 @@ var DialogDescription = React131__namespace.default.forwardRef(({ className, ...
|
|
|
1233
1427
|
}
|
|
1234
1428
|
));
|
|
1235
1429
|
DialogDescription.displayName = DialogPrimitive__namespace.Description.displayName;
|
|
1236
|
-
var Command =
|
|
1430
|
+
var Command = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1237
1431
|
cmdk.Command,
|
|
1238
1432
|
{
|
|
1239
1433
|
ref,
|
|
@@ -1248,7 +1442,7 @@ Command.displayName = cmdk.Command.displayName;
|
|
|
1248
1442
|
var CommandDialog = ({ children, ...props }) => {
|
|
1249
1443
|
return /* @__PURE__ */ jsxRuntime.jsx(Dialog, { ...props, children: /* @__PURE__ */ jsxRuntime.jsx(DialogContent, { className: "overflow-hidden p-0", children: /* @__PURE__ */ jsxRuntime.jsx(Command, { className: "[&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground [&_[cmdk-group]:not([hidden])_~[cmdk-group]]:pt-0 [&_[cmdk-group]]:px-2 [&_[cmdk-input-wrapper]_svg]:h-5 [&_[cmdk-input-wrapper]_svg]:w-5 [&_[cmdk-input]]:h-12 [&_[cmdk-item]]:px-2 [&_[cmdk-item]]:py-3 [&_[cmdk-item]_svg]:h-5 [&_[cmdk-item]_svg]:w-5", children }) }) });
|
|
1250
1444
|
};
|
|
1251
|
-
var CommandInput =
|
|
1445
|
+
var CommandInput = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center border-b px-3", "cmdk-input-wrapper": "", children: [
|
|
1252
1446
|
/* @__PURE__ */ jsxRuntime.jsx(lucideReact.Search, { className: "mr-2 h-4 w-4 shrink-0 opacity-50" }),
|
|
1253
1447
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1254
1448
|
cmdk.Command.Input,
|
|
@@ -1263,7 +1457,7 @@ var CommandInput = React131__namespace.forwardRef(({ className, ...props }, ref)
|
|
|
1263
1457
|
)
|
|
1264
1458
|
] }));
|
|
1265
1459
|
CommandInput.displayName = cmdk.Command.Input.displayName;
|
|
1266
|
-
var CommandList =
|
|
1460
|
+
var CommandList = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1267
1461
|
cmdk.Command.List,
|
|
1268
1462
|
{
|
|
1269
1463
|
ref,
|
|
@@ -1272,7 +1466,7 @@ var CommandList = React131__namespace.forwardRef(({ className, ...props }, ref)
|
|
|
1272
1466
|
}
|
|
1273
1467
|
));
|
|
1274
1468
|
CommandList.displayName = cmdk.Command.List.displayName;
|
|
1275
|
-
var CommandEmpty =
|
|
1469
|
+
var CommandEmpty = React137__namespace.forwardRef((props, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1276
1470
|
cmdk.Command.Empty,
|
|
1277
1471
|
{
|
|
1278
1472
|
ref,
|
|
@@ -1281,7 +1475,7 @@ var CommandEmpty = React131__namespace.forwardRef((props, ref) => /* @__PURE__ *
|
|
|
1281
1475
|
}
|
|
1282
1476
|
));
|
|
1283
1477
|
CommandEmpty.displayName = cmdk.Command.Empty.displayName;
|
|
1284
|
-
var CommandGroup =
|
|
1478
|
+
var CommandGroup = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1285
1479
|
cmdk.Command.Group,
|
|
1286
1480
|
{
|
|
1287
1481
|
ref,
|
|
@@ -1293,7 +1487,7 @@ var CommandGroup = React131__namespace.forwardRef(({ className, ...props }, ref)
|
|
|
1293
1487
|
}
|
|
1294
1488
|
));
|
|
1295
1489
|
CommandGroup.displayName = cmdk.Command.Group.displayName;
|
|
1296
|
-
var CommandSeparator =
|
|
1490
|
+
var CommandSeparator = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1297
1491
|
cmdk.Command.Separator,
|
|
1298
1492
|
{
|
|
1299
1493
|
ref,
|
|
@@ -1302,7 +1496,7 @@ var CommandSeparator = React131__namespace.forwardRef(({ className, ...props },
|
|
|
1302
1496
|
}
|
|
1303
1497
|
));
|
|
1304
1498
|
CommandSeparator.displayName = cmdk.Command.Separator.displayName;
|
|
1305
|
-
var CommandItem =
|
|
1499
|
+
var CommandItem = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1306
1500
|
cmdk.Command.Item,
|
|
1307
1501
|
{
|
|
1308
1502
|
ref,
|
|
@@ -1330,7 +1524,7 @@ var CommandShortcut = ({
|
|
|
1330
1524
|
);
|
|
1331
1525
|
};
|
|
1332
1526
|
CommandShortcut.displayName = "CommandShortcut";
|
|
1333
|
-
var Comparison =
|
|
1527
|
+
var Comparison = React137__namespace.default.forwardRef(
|
|
1334
1528
|
({
|
|
1335
1529
|
before,
|
|
1336
1530
|
after,
|
|
@@ -1346,10 +1540,10 @@ var Comparison = React131__namespace.default.forwardRef(
|
|
|
1346
1540
|
...props
|
|
1347
1541
|
}, ref) => {
|
|
1348
1542
|
const isControlled = valueProp !== void 0;
|
|
1349
|
-
const [internal, setInternal] =
|
|
1543
|
+
const [internal, setInternal] = React137__namespace.default.useState(defaultValue);
|
|
1350
1544
|
const value = Math.max(0, Math.min(100, isControlled ? valueProp : internal));
|
|
1351
|
-
const containerRef =
|
|
1352
|
-
const commit =
|
|
1545
|
+
const containerRef = React137__namespace.default.useRef(null);
|
|
1546
|
+
const commit = React137__namespace.default.useCallback(
|
|
1353
1547
|
(next) => {
|
|
1354
1548
|
const clamped = Math.max(0, Math.min(100, next));
|
|
1355
1549
|
if (!isControlled) setInternal(clamped);
|
|
@@ -1357,7 +1551,7 @@ var Comparison = React131__namespace.default.forwardRef(
|
|
|
1357
1551
|
},
|
|
1358
1552
|
[isControlled, onValueChange]
|
|
1359
1553
|
);
|
|
1360
|
-
const updateFromPointer =
|
|
1554
|
+
const updateFromPointer = React137__namespace.default.useCallback(
|
|
1361
1555
|
(clientX, clientY) => {
|
|
1362
1556
|
const el = containerRef.current;
|
|
1363
1557
|
if (!el) return;
|
|
@@ -1480,30 +1674,30 @@ var ContextMenuSub = ContextMenuPrimitive__namespace.Sub;
|
|
|
1480
1674
|
var ContextMenuRadioGroup = ContextMenuPrimitive__namespace.RadioGroup;
|
|
1481
1675
|
var contentStyle = "z-50 min-w-[8rem] overflow-hidden rounded-md border border-[hsl(var(--border))] bg-[hsl(var(--popover))] p-1 text-[hsl(var(--popover-foreground))] shadow-md animate-in fade-in-80";
|
|
1482
1676
|
var itemStyle = "relative flex cursor-default select-none items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-none transition-colors focus:bg-[hsl(var(--accent))] focus:text-[hsl(var(--accent-foreground))] data-[disabled]:pointer-events-none data-[disabled]:opacity-50";
|
|
1483
|
-
var ContextMenuContent =
|
|
1677
|
+
var ContextMenuContent = React137__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(ContextMenuPrimitive__namespace.Portal, { children: /* @__PURE__ */ jsxRuntime.jsx(ContextMenuPrimitive__namespace.Content, { ref, className: cn(contentStyle, className), ...props }) }));
|
|
1484
1678
|
ContextMenuContent.displayName = ContextMenuPrimitive__namespace.Content.displayName;
|
|
1485
|
-
var ContextMenuItem =
|
|
1679
|
+
var ContextMenuItem = React137__namespace.default.forwardRef(({ className, inset, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(ContextMenuPrimitive__namespace.Item, { ref, className: cn(itemStyle, inset && "pl-8", className), ...props }));
|
|
1486
1680
|
ContextMenuItem.displayName = ContextMenuPrimitive__namespace.Item.displayName;
|
|
1487
|
-
var ContextMenuCheckboxItem =
|
|
1681
|
+
var ContextMenuCheckboxItem = React137__namespace.default.forwardRef(({ className, children, checked, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(ContextMenuPrimitive__namespace.CheckboxItem, { ref, className: cn(itemStyle, "pl-8", className), checked, ...props, children: [
|
|
1488
1682
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ jsxRuntime.jsx(ContextMenuPrimitive__namespace.ItemIndicator, { children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Check, { className: "h-4 w-4" }) }) }),
|
|
1489
1683
|
children
|
|
1490
1684
|
] }));
|
|
1491
1685
|
ContextMenuCheckboxItem.displayName = ContextMenuPrimitive__namespace.CheckboxItem.displayName;
|
|
1492
|
-
var ContextMenuRadioItem =
|
|
1686
|
+
var ContextMenuRadioItem = React137__namespace.default.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(ContextMenuPrimitive__namespace.RadioItem, { ref, className: cn(itemStyle, "pl-8", className), ...props, children: [
|
|
1493
1687
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ jsxRuntime.jsx(ContextMenuPrimitive__namespace.ItemIndicator, { children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Circle, { className: "h-2 w-2 fill-current" }) }) }),
|
|
1494
1688
|
children
|
|
1495
1689
|
] }));
|
|
1496
1690
|
ContextMenuRadioItem.displayName = ContextMenuPrimitive__namespace.RadioItem.displayName;
|
|
1497
|
-
var ContextMenuLabel =
|
|
1691
|
+
var ContextMenuLabel = React137__namespace.default.forwardRef(({ className, inset, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(ContextMenuPrimitive__namespace.Label, { ref, className: cn("px-2 py-1.5 text-xs font-semibold text-[hsl(var(--muted-foreground))]", inset && "pl-8", className), ...props }));
|
|
1498
1692
|
ContextMenuLabel.displayName = ContextMenuPrimitive__namespace.Label.displayName;
|
|
1499
|
-
var ContextMenuSeparator =
|
|
1693
|
+
var ContextMenuSeparator = React137__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(ContextMenuPrimitive__namespace.Separator, { ref, className: cn("-mx-1 my-1 h-px bg-[hsl(var(--muted))]", className), ...props }));
|
|
1500
1694
|
ContextMenuSeparator.displayName = ContextMenuPrimitive__namespace.Separator.displayName;
|
|
1501
|
-
var ContextMenuSubTrigger =
|
|
1695
|
+
var ContextMenuSubTrigger = React137__namespace.default.forwardRef(({ className, inset, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(ContextMenuPrimitive__namespace.SubTrigger, { ref, className: cn(itemStyle, inset && "pl-8", className), ...props, children: [
|
|
1502
1696
|
children,
|
|
1503
1697
|
/* @__PURE__ */ jsxRuntime.jsx(lucideReact.ChevronRight, { className: "ml-auto h-4 w-4" })
|
|
1504
1698
|
] }));
|
|
1505
1699
|
ContextMenuSubTrigger.displayName = ContextMenuPrimitive__namespace.SubTrigger.displayName;
|
|
1506
|
-
var ContextMenuSubContent =
|
|
1700
|
+
var ContextMenuSubContent = React137__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(ContextMenuPrimitive__namespace.SubContent, { ref, className: cn(contentStyle, className), ...props }));
|
|
1507
1701
|
ContextMenuSubContent.displayName = ContextMenuPrimitive__namespace.SubContent.displayName;
|
|
1508
1702
|
var ContextMenuShortcut = ({ className, ...props }) => /* @__PURE__ */ jsxRuntime.jsx("span", { className: cn("ml-auto text-xs tracking-widest opacity-60", className), ...props });
|
|
1509
1703
|
var Drawer = ({
|
|
@@ -1520,7 +1714,7 @@ Drawer.displayName = "Drawer";
|
|
|
1520
1714
|
var DrawerTrigger = vaul.Drawer.Trigger;
|
|
1521
1715
|
var DrawerPortal = vaul.Drawer.Portal;
|
|
1522
1716
|
var DrawerClose = vaul.Drawer.Close;
|
|
1523
|
-
var DrawerOverlay =
|
|
1717
|
+
var DrawerOverlay = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1524
1718
|
vaul.Drawer.Overlay,
|
|
1525
1719
|
{
|
|
1526
1720
|
ref,
|
|
@@ -1529,7 +1723,7 @@ var DrawerOverlay = React131__namespace.forwardRef(({ className, ...props }, ref
|
|
|
1529
1723
|
}
|
|
1530
1724
|
));
|
|
1531
1725
|
DrawerOverlay.displayName = vaul.Drawer.Overlay.displayName;
|
|
1532
|
-
var DrawerContent =
|
|
1726
|
+
var DrawerContent = React137__namespace.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(DrawerPortal, { children: [
|
|
1533
1727
|
/* @__PURE__ */ jsxRuntime.jsx(DrawerOverlay, {}),
|
|
1534
1728
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
1535
1729
|
vaul.Drawer.Content,
|
|
@@ -1570,7 +1764,7 @@ var DrawerFooter = ({
|
|
|
1570
1764
|
}
|
|
1571
1765
|
);
|
|
1572
1766
|
DrawerFooter.displayName = "DrawerFooter";
|
|
1573
|
-
var DrawerTitle =
|
|
1767
|
+
var DrawerTitle = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1574
1768
|
vaul.Drawer.Title,
|
|
1575
1769
|
{
|
|
1576
1770
|
ref,
|
|
@@ -1582,7 +1776,7 @@ var DrawerTitle = React131__namespace.forwardRef(({ className, ...props }, ref)
|
|
|
1582
1776
|
}
|
|
1583
1777
|
));
|
|
1584
1778
|
DrawerTitle.displayName = vaul.Drawer.Title.displayName;
|
|
1585
|
-
var DrawerDescription =
|
|
1779
|
+
var DrawerDescription = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1586
1780
|
vaul.Drawer.Description,
|
|
1587
1781
|
{
|
|
1588
1782
|
ref,
|
|
@@ -1607,36 +1801,65 @@ var itemStyle2 = cn(
|
|
|
1607
1801
|
"focus:bg-[hsl(var(--accent))] focus:text-[hsl(var(--accent-foreground))]",
|
|
1608
1802
|
"data-[disabled]:pointer-events-none data-[disabled]:opacity-50"
|
|
1609
1803
|
);
|
|
1610
|
-
var DropdownMenuContent =
|
|
1804
|
+
var DropdownMenuContent = React137__namespace.default.forwardRef(({ className, sideOffset = 4, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(DropdownMenuPrimitive__namespace.Portal, { children: /* @__PURE__ */ jsxRuntime.jsx(DropdownMenuPrimitive__namespace.Content, { ref, sideOffset, className: cn(contentStyle2, className), ...props }) }));
|
|
1611
1805
|
DropdownMenuContent.displayName = DropdownMenuPrimitive__namespace.Content.displayName;
|
|
1612
|
-
var DropdownMenuItem =
|
|
1806
|
+
var DropdownMenuItem = React137__namespace.default.forwardRef(({ className, inset, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(DropdownMenuPrimitive__namespace.Item, { ref, className: cn(itemStyle2, inset && "pl-8", className), ...props }));
|
|
1613
1807
|
DropdownMenuItem.displayName = DropdownMenuPrimitive__namespace.Item.displayName;
|
|
1614
|
-
var DropdownMenuCheckboxItem =
|
|
1808
|
+
var DropdownMenuCheckboxItem = React137__namespace.default.forwardRef(({ className, children, checked, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(DropdownMenuPrimitive__namespace.CheckboxItem, { ref, className: cn(itemStyle2, "pl-8", className), checked, ...props, children: [
|
|
1615
1809
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ jsxRuntime.jsx(DropdownMenuPrimitive__namespace.ItemIndicator, { children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Check, { className: "h-4 w-4" }) }) }),
|
|
1616
1810
|
children
|
|
1617
1811
|
] }));
|
|
1618
1812
|
DropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive__namespace.CheckboxItem.displayName;
|
|
1619
|
-
var DropdownMenuRadioItem =
|
|
1813
|
+
var DropdownMenuRadioItem = React137__namespace.default.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(DropdownMenuPrimitive__namespace.RadioItem, { ref, className: cn(itemStyle2, "pl-8", className), ...props, children: [
|
|
1620
1814
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ jsxRuntime.jsx(DropdownMenuPrimitive__namespace.ItemIndicator, { children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Circle, { className: "h-2 w-2 fill-current" }) }) }),
|
|
1621
1815
|
children
|
|
1622
1816
|
] }));
|
|
1623
1817
|
DropdownMenuRadioItem.displayName = DropdownMenuPrimitive__namespace.RadioItem.displayName;
|
|
1624
|
-
var DropdownMenuLabel =
|
|
1818
|
+
var DropdownMenuLabel = React137__namespace.default.forwardRef(({ className, inset, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(DropdownMenuPrimitive__namespace.Label, { ref, className: cn("px-2 py-1.5 text-xs font-semibold text-[hsl(var(--muted-foreground))]", inset && "pl-8", className), ...props }));
|
|
1625
1819
|
DropdownMenuLabel.displayName = DropdownMenuPrimitive__namespace.Label.displayName;
|
|
1626
|
-
var DropdownMenuSeparator =
|
|
1820
|
+
var DropdownMenuSeparator = React137__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(DropdownMenuPrimitive__namespace.Separator, { ref, className: cn("-mx-1 my-1 h-px bg-[hsl(var(--muted))]", className), ...props }));
|
|
1627
1821
|
DropdownMenuSeparator.displayName = DropdownMenuPrimitive__namespace.Separator.displayName;
|
|
1628
|
-
var DropdownMenuSubTrigger =
|
|
1822
|
+
var DropdownMenuSubTrigger = React137__namespace.default.forwardRef(({ className, inset, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(DropdownMenuPrimitive__namespace.SubTrigger, { ref, className: cn(itemStyle2, inset && "pl-8", "data-[state=open]:bg-[hsl(var(--accent))]", className), ...props, children: [
|
|
1629
1823
|
children,
|
|
1630
1824
|
/* @__PURE__ */ jsxRuntime.jsx(lucideReact.ChevronRight, { className: "ml-auto h-4 w-4" })
|
|
1631
1825
|
] }));
|
|
1632
1826
|
DropdownMenuSubTrigger.displayName = DropdownMenuPrimitive__namespace.SubTrigger.displayName;
|
|
1633
|
-
var DropdownMenuSubContent =
|
|
1827
|
+
var DropdownMenuSubContent = React137__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(DropdownMenuPrimitive__namespace.SubContent, { ref, className: cn(contentStyle2, className), ...props }));
|
|
1634
1828
|
DropdownMenuSubContent.displayName = DropdownMenuPrimitive__namespace.SubContent.displayName;
|
|
1635
1829
|
var DropdownMenuShortcut = ({ className, ...props }) => /* @__PURE__ */ jsxRuntime.jsx("span", { className: cn("ml-auto text-xs tracking-widest opacity-60", className), ...props });
|
|
1636
1830
|
DropdownMenuShortcut.displayName = "DropdownMenuShortcut";
|
|
1831
|
+
var EmptyCart = React137__namespace.default.forwardRef(
|
|
1832
|
+
({
|
|
1833
|
+
title = "Your cart is empty",
|
|
1834
|
+
description = "Browse the catalog and add something you love.",
|
|
1835
|
+
actionLabel = "Continue shopping",
|
|
1836
|
+
onAction,
|
|
1837
|
+
icon,
|
|
1838
|
+
className,
|
|
1839
|
+
...props
|
|
1840
|
+
}, ref) => {
|
|
1841
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
1842
|
+
"div",
|
|
1843
|
+
{
|
|
1844
|
+
ref,
|
|
1845
|
+
className: cn("flex flex-col items-center justify-center gap-4 px-6 py-12 text-center", className),
|
|
1846
|
+
...props,
|
|
1847
|
+
children: [
|
|
1848
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex h-14 w-14 items-center justify-center rounded-full bg-[hsl(var(--muted))] text-[hsl(var(--muted-foreground))]", children: icon ?? /* @__PURE__ */ jsxRuntime.jsx(lucideReact.ShoppingCart, { className: "h-6 w-6", strokeWidth: 1.5 }) }),
|
|
1849
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col gap-1", children: [
|
|
1850
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-base font-semibold text-foreground", children: title }),
|
|
1851
|
+
description && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "max-w-xs text-sm text-muted-foreground", children: description })
|
|
1852
|
+
] }),
|
|
1853
|
+
actionLabel && onAction && /* @__PURE__ */ jsxRuntime.jsx(Button, { onClick: onAction, className: "mt-1", children: actionLabel })
|
|
1854
|
+
]
|
|
1855
|
+
}
|
|
1856
|
+
);
|
|
1857
|
+
}
|
|
1858
|
+
);
|
|
1859
|
+
EmptyCart.displayName = "EmptyCart";
|
|
1637
1860
|
var HoverCard = HoverCardPrimitive__namespace.Root;
|
|
1638
1861
|
var HoverCardTrigger = HoverCardPrimitive__namespace.Trigger;
|
|
1639
|
-
var HoverCardContent =
|
|
1862
|
+
var HoverCardContent = React137__namespace.forwardRef(({ className, align = "center", sideOffset = 4, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1640
1863
|
HoverCardPrimitive__namespace.Content,
|
|
1641
1864
|
{
|
|
1642
1865
|
ref,
|
|
@@ -1650,7 +1873,7 @@ var HoverCardContent = React131__namespace.forwardRef(({ className, align = "cen
|
|
|
1650
1873
|
}
|
|
1651
1874
|
));
|
|
1652
1875
|
HoverCardContent.displayName = HoverCardPrimitive__namespace.Content.displayName;
|
|
1653
|
-
var InputOTP =
|
|
1876
|
+
var InputOTP = React137__namespace.forwardRef(({ className, containerClassName, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1654
1877
|
inputOtp.OTPInput,
|
|
1655
1878
|
{
|
|
1656
1879
|
ref,
|
|
@@ -1663,10 +1886,10 @@ var InputOTP = React131__namespace.forwardRef(({ className, containerClassName,
|
|
|
1663
1886
|
}
|
|
1664
1887
|
));
|
|
1665
1888
|
InputOTP.displayName = "InputOTP";
|
|
1666
|
-
var InputOTPGroup =
|
|
1889
|
+
var InputOTPGroup = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("flex items-center", className), ...props }));
|
|
1667
1890
|
InputOTPGroup.displayName = "InputOTPGroup";
|
|
1668
|
-
var InputOTPSlot =
|
|
1669
|
-
const inputOTPContext =
|
|
1891
|
+
var InputOTPSlot = React137__namespace.forwardRef(({ index, className, ...props }, ref) => {
|
|
1892
|
+
const inputOTPContext = React137__namespace.useContext(inputOtp.OTPInputContext);
|
|
1670
1893
|
const { char, hasFakeCaret, isActive } = inputOTPContext.slots[index];
|
|
1671
1894
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
1672
1895
|
"div",
|
|
@@ -1686,9 +1909,9 @@ var InputOTPSlot = React131__namespace.forwardRef(({ index, className, ...props
|
|
|
1686
1909
|
);
|
|
1687
1910
|
});
|
|
1688
1911
|
InputOTPSlot.displayName = "InputOTPSlot";
|
|
1689
|
-
var InputOTPSeparator =
|
|
1912
|
+
var InputOTPSeparator = React137__namespace.forwardRef(({ ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, role: "separator", ...props, children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Minus, {}) }));
|
|
1690
1913
|
InputOTPSeparator.displayName = "InputOTPSeparator";
|
|
1691
|
-
var Input =
|
|
1914
|
+
var Input = React137__namespace.default.forwardRef(
|
|
1692
1915
|
({ className, type, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1693
1916
|
"input",
|
|
1694
1917
|
{
|
|
@@ -1710,7 +1933,7 @@ Input.displayName = "Input";
|
|
|
1710
1933
|
var labelVariants = classVarianceAuthority.cva(
|
|
1711
1934
|
"text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"
|
|
1712
1935
|
);
|
|
1713
|
-
var Label3 =
|
|
1936
|
+
var Label3 = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1714
1937
|
LabelPrimitive__namespace.Root,
|
|
1715
1938
|
{
|
|
1716
1939
|
ref,
|
|
@@ -1719,7 +1942,7 @@ var Label3 = React131__namespace.forwardRef(({ className, ...props }, ref) => /*
|
|
|
1719
1942
|
}
|
|
1720
1943
|
));
|
|
1721
1944
|
Label3.displayName = LabelPrimitive__namespace.Root.displayName;
|
|
1722
|
-
var LogoCarousel =
|
|
1945
|
+
var LogoCarousel = React137__namespace.default.forwardRef(
|
|
1723
1946
|
({
|
|
1724
1947
|
className,
|
|
1725
1948
|
logos,
|
|
@@ -1813,7 +2036,7 @@ var SPEED_DURATION = {
|
|
|
1813
2036
|
normal: "40s",
|
|
1814
2037
|
fast: "20s"
|
|
1815
2038
|
};
|
|
1816
|
-
var Marquee =
|
|
2039
|
+
var Marquee = React137__namespace.default.forwardRef(
|
|
1817
2040
|
({
|
|
1818
2041
|
children,
|
|
1819
2042
|
speed = "normal",
|
|
@@ -1877,7 +2100,7 @@ function MenubarSub({
|
|
|
1877
2100
|
}) {
|
|
1878
2101
|
return /* @__PURE__ */ jsxRuntime.jsx(MenubarPrimitive__namespace.Sub, { "data-slot": "menubar-sub", ...props });
|
|
1879
2102
|
}
|
|
1880
|
-
var Menubar =
|
|
2103
|
+
var Menubar = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1881
2104
|
MenubarPrimitive__namespace.Root,
|
|
1882
2105
|
{
|
|
1883
2106
|
ref,
|
|
@@ -1889,7 +2112,7 @@ var Menubar = React131__namespace.forwardRef(({ className, ...props }, ref) => /
|
|
|
1889
2112
|
}
|
|
1890
2113
|
));
|
|
1891
2114
|
Menubar.displayName = MenubarPrimitive__namespace.Root.displayName;
|
|
1892
|
-
var MenubarTrigger =
|
|
2115
|
+
var MenubarTrigger = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1893
2116
|
MenubarPrimitive__namespace.Trigger,
|
|
1894
2117
|
{
|
|
1895
2118
|
ref,
|
|
@@ -1901,7 +2124,7 @@ var MenubarTrigger = React131__namespace.forwardRef(({ className, ...props }, re
|
|
|
1901
2124
|
}
|
|
1902
2125
|
));
|
|
1903
2126
|
MenubarTrigger.displayName = MenubarPrimitive__namespace.Trigger.displayName;
|
|
1904
|
-
var MenubarSubTrigger =
|
|
2127
|
+
var MenubarSubTrigger = React137__namespace.forwardRef(({ className, inset, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
1905
2128
|
MenubarPrimitive__namespace.SubTrigger,
|
|
1906
2129
|
{
|
|
1907
2130
|
ref,
|
|
@@ -1918,7 +2141,7 @@ var MenubarSubTrigger = React131__namespace.forwardRef(({ className, inset, chil
|
|
|
1918
2141
|
}
|
|
1919
2142
|
));
|
|
1920
2143
|
MenubarSubTrigger.displayName = MenubarPrimitive__namespace.SubTrigger.displayName;
|
|
1921
|
-
var MenubarSubContent =
|
|
2144
|
+
var MenubarSubContent = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1922
2145
|
MenubarPrimitive__namespace.SubContent,
|
|
1923
2146
|
{
|
|
1924
2147
|
ref,
|
|
@@ -1930,7 +2153,7 @@ var MenubarSubContent = React131__namespace.forwardRef(({ className, ...props },
|
|
|
1930
2153
|
}
|
|
1931
2154
|
));
|
|
1932
2155
|
MenubarSubContent.displayName = MenubarPrimitive__namespace.SubContent.displayName;
|
|
1933
|
-
var MenubarContent =
|
|
2156
|
+
var MenubarContent = React137__namespace.forwardRef(
|
|
1934
2157
|
({ className, align = "start", alignOffset = -4, sideOffset = 8, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(MenubarPrimitive__namespace.Portal, { children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
1935
2158
|
MenubarPrimitive__namespace.Content,
|
|
1936
2159
|
{
|
|
@@ -1947,7 +2170,7 @@ var MenubarContent = React131__namespace.forwardRef(
|
|
|
1947
2170
|
) })
|
|
1948
2171
|
);
|
|
1949
2172
|
MenubarContent.displayName = MenubarPrimitive__namespace.Content.displayName;
|
|
1950
|
-
var MenubarItem =
|
|
2173
|
+
var MenubarItem = React137__namespace.forwardRef(({ className, inset, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1951
2174
|
MenubarPrimitive__namespace.Item,
|
|
1952
2175
|
{
|
|
1953
2176
|
ref,
|
|
@@ -1960,7 +2183,7 @@ var MenubarItem = React131__namespace.forwardRef(({ className, inset, ...props }
|
|
|
1960
2183
|
}
|
|
1961
2184
|
));
|
|
1962
2185
|
MenubarItem.displayName = MenubarPrimitive__namespace.Item.displayName;
|
|
1963
|
-
var MenubarCheckboxItem =
|
|
2186
|
+
var MenubarCheckboxItem = React137__namespace.forwardRef(({ className, children, checked, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
1964
2187
|
MenubarPrimitive__namespace.CheckboxItem,
|
|
1965
2188
|
{
|
|
1966
2189
|
ref,
|
|
@@ -1977,7 +2200,7 @@ var MenubarCheckboxItem = React131__namespace.forwardRef(({ className, children,
|
|
|
1977
2200
|
}
|
|
1978
2201
|
));
|
|
1979
2202
|
MenubarCheckboxItem.displayName = MenubarPrimitive__namespace.CheckboxItem.displayName;
|
|
1980
|
-
var MenubarRadioItem =
|
|
2203
|
+
var MenubarRadioItem = React137__namespace.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
1981
2204
|
MenubarPrimitive__namespace.RadioItem,
|
|
1982
2205
|
{
|
|
1983
2206
|
ref,
|
|
@@ -1993,7 +2216,7 @@ var MenubarRadioItem = React131__namespace.forwardRef(({ className, children, ..
|
|
|
1993
2216
|
}
|
|
1994
2217
|
));
|
|
1995
2218
|
MenubarRadioItem.displayName = MenubarPrimitive__namespace.RadioItem.displayName;
|
|
1996
|
-
var MenubarLabel =
|
|
2219
|
+
var MenubarLabel = React137__namespace.forwardRef(({ className, inset, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1997
2220
|
MenubarPrimitive__namespace.Label,
|
|
1998
2221
|
{
|
|
1999
2222
|
ref,
|
|
@@ -2006,7 +2229,7 @@ var MenubarLabel = React131__namespace.forwardRef(({ className, inset, ...props
|
|
|
2006
2229
|
}
|
|
2007
2230
|
));
|
|
2008
2231
|
MenubarLabel.displayName = MenubarPrimitive__namespace.Label.displayName;
|
|
2009
|
-
var MenubarSeparator =
|
|
2232
|
+
var MenubarSeparator = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2010
2233
|
MenubarPrimitive__namespace.Separator,
|
|
2011
2234
|
{
|
|
2012
2235
|
ref,
|
|
@@ -2031,7 +2254,7 @@ var MenubarShortcut = ({
|
|
|
2031
2254
|
);
|
|
2032
2255
|
};
|
|
2033
2256
|
MenubarShortcut.displayname = "MenubarShortcut";
|
|
2034
|
-
var NavigationMenu =
|
|
2257
|
+
var NavigationMenu = React137__namespace.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2035
2258
|
NavigationMenuPrimitive__namespace.Root,
|
|
2036
2259
|
{
|
|
2037
2260
|
ref,
|
|
@@ -2047,7 +2270,7 @@ var NavigationMenu = React131__namespace.forwardRef(({ className, children, ...p
|
|
|
2047
2270
|
}
|
|
2048
2271
|
));
|
|
2049
2272
|
NavigationMenu.displayName = NavigationMenuPrimitive__namespace.Root.displayName;
|
|
2050
|
-
var NavigationMenuList =
|
|
2273
|
+
var NavigationMenuList = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2051
2274
|
NavigationMenuPrimitive__namespace.List,
|
|
2052
2275
|
{
|
|
2053
2276
|
ref,
|
|
@@ -2063,7 +2286,7 @@ var NavigationMenuItem = NavigationMenuPrimitive__namespace.Item;
|
|
|
2063
2286
|
var navigationMenuTriggerStyle = classVarianceAuthority.cva(
|
|
2064
2287
|
"group inline-flex h-9 w-max items-center justify-center rounded-md bg-background px-4 py-2 text-sm font-medium transition-colors hover:bg-accent hover:text-accent-foreground focus:bg-accent focus:text-accent-foreground focus:outline-none disabled:pointer-events-none disabled:opacity-50 data-[state=open]:text-accent-foreground data-[state=open]:bg-accent/50 data-[state=open]:hover:bg-accent data-[state=open]:focus:bg-accent"
|
|
2065
2288
|
);
|
|
2066
|
-
var NavigationMenuTrigger =
|
|
2289
|
+
var NavigationMenuTrigger = React137__namespace.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2067
2290
|
NavigationMenuPrimitive__namespace.Trigger,
|
|
2068
2291
|
{
|
|
2069
2292
|
ref,
|
|
@@ -2083,7 +2306,7 @@ var NavigationMenuTrigger = React131__namespace.forwardRef(({ className, childre
|
|
|
2083
2306
|
}
|
|
2084
2307
|
));
|
|
2085
2308
|
NavigationMenuTrigger.displayName = NavigationMenuPrimitive__namespace.Trigger.displayName;
|
|
2086
|
-
var NavigationMenuContent =
|
|
2309
|
+
var NavigationMenuContent = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2087
2310
|
NavigationMenuPrimitive__namespace.Content,
|
|
2088
2311
|
{
|
|
2089
2312
|
ref,
|
|
@@ -2096,7 +2319,7 @@ var NavigationMenuContent = React131__namespace.forwardRef(({ className, ...prop
|
|
|
2096
2319
|
));
|
|
2097
2320
|
NavigationMenuContent.displayName = NavigationMenuPrimitive__namespace.Content.displayName;
|
|
2098
2321
|
var NavigationMenuLink = NavigationMenuPrimitive__namespace.Link;
|
|
2099
|
-
var NavigationMenuViewport =
|
|
2322
|
+
var NavigationMenuViewport = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn("absolute left-0 top-full flex justify-center"), children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
2100
2323
|
NavigationMenuPrimitive__namespace.Viewport,
|
|
2101
2324
|
{
|
|
2102
2325
|
className: cn(
|
|
@@ -2108,7 +2331,7 @@ var NavigationMenuViewport = React131__namespace.forwardRef(({ className, ...pro
|
|
|
2108
2331
|
}
|
|
2109
2332
|
) }));
|
|
2110
2333
|
NavigationMenuViewport.displayName = NavigationMenuPrimitive__namespace.Viewport.displayName;
|
|
2111
|
-
var NavigationMenuIndicator =
|
|
2334
|
+
var NavigationMenuIndicator = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2112
2335
|
NavigationMenuPrimitive__namespace.Indicator,
|
|
2113
2336
|
{
|
|
2114
2337
|
ref,
|
|
@@ -2131,7 +2354,7 @@ var Pagination = ({ className, ...props }) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
|
2131
2354
|
}
|
|
2132
2355
|
);
|
|
2133
2356
|
Pagination.displayName = "Pagination";
|
|
2134
|
-
var PaginationContent =
|
|
2357
|
+
var PaginationContent = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2135
2358
|
"ul",
|
|
2136
2359
|
{
|
|
2137
2360
|
ref,
|
|
@@ -2140,7 +2363,7 @@ var PaginationContent = React131__namespace.forwardRef(({ className, ...props },
|
|
|
2140
2363
|
}
|
|
2141
2364
|
));
|
|
2142
2365
|
PaginationContent.displayName = "PaginationContent";
|
|
2143
|
-
var PaginationItem =
|
|
2366
|
+
var PaginationItem = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("li", { ref, className: cn("", className), ...props }));
|
|
2144
2367
|
PaginationItem.displayName = "PaginationItem";
|
|
2145
2368
|
var PaginationLink = ({
|
|
2146
2369
|
className,
|
|
@@ -2215,7 +2438,7 @@ PaginationEllipsis.displayName = "PaginationEllipsis";
|
|
|
2215
2438
|
var Popover = PopoverPrimitive__namespace.Root;
|
|
2216
2439
|
var PopoverTrigger = PopoverPrimitive__namespace.Trigger;
|
|
2217
2440
|
var PopoverAnchor = PopoverPrimitive__namespace.Anchor;
|
|
2218
|
-
var PopoverContent =
|
|
2441
|
+
var PopoverContent = React137__namespace.default.forwardRef(({ className, align = "center", sideOffset = 4, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(PopoverPrimitive__namespace.Portal, { children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
2219
2442
|
PopoverPrimitive__namespace.Content,
|
|
2220
2443
|
{
|
|
2221
2444
|
ref,
|
|
@@ -2232,7 +2455,7 @@ var PopoverContent = React131__namespace.default.forwardRef(({ className, align
|
|
|
2232
2455
|
}
|
|
2233
2456
|
) }));
|
|
2234
2457
|
PopoverContent.displayName = PopoverPrimitive__namespace.Content.displayName;
|
|
2235
|
-
var Progress =
|
|
2458
|
+
var Progress = React137__namespace.default.forwardRef(({ className, value, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2236
2459
|
ProgressPrimitive__namespace.Root,
|
|
2237
2460
|
{
|
|
2238
2461
|
ref,
|
|
@@ -2248,7 +2471,7 @@ var Progress = React131__namespace.default.forwardRef(({ className, value, ...pr
|
|
|
2248
2471
|
}
|
|
2249
2472
|
));
|
|
2250
2473
|
Progress.displayName = ProgressPrimitive__namespace.Root.displayName;
|
|
2251
|
-
var QrCode =
|
|
2474
|
+
var QrCode = React137__namespace.default.forwardRef(
|
|
2252
2475
|
({
|
|
2253
2476
|
value,
|
|
2254
2477
|
size = 192,
|
|
@@ -2305,9 +2528,9 @@ var QrCode = React131__namespace.default.forwardRef(
|
|
|
2305
2528
|
}
|
|
2306
2529
|
);
|
|
2307
2530
|
QrCode.displayName = "QrCode";
|
|
2308
|
-
var RadioGroup4 =
|
|
2531
|
+
var RadioGroup4 = React137__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(RadioGroupPrimitive__namespace.Root, { className: cn("grid gap-2", className), ref, ...props }));
|
|
2309
2532
|
RadioGroup4.displayName = RadioGroupPrimitive__namespace.Root.displayName;
|
|
2310
|
-
var RadioGroupItem =
|
|
2533
|
+
var RadioGroupItem = React137__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2311
2534
|
RadioGroupPrimitive__namespace.Item,
|
|
2312
2535
|
{
|
|
2313
2536
|
ref,
|
|
@@ -2322,12 +2545,12 @@ var RadioGroupItem = React131__namespace.default.forwardRef(({ className, ...pro
|
|
|
2322
2545
|
}
|
|
2323
2546
|
));
|
|
2324
2547
|
RadioGroupItem.displayName = RadioGroupPrimitive__namespace.Item.displayName;
|
|
2325
|
-
var
|
|
2548
|
+
var SIZE2 = {
|
|
2326
2549
|
sm: "h-4 w-4",
|
|
2327
2550
|
md: "h-5 w-5",
|
|
2328
2551
|
lg: "h-6 w-6"
|
|
2329
2552
|
};
|
|
2330
|
-
var Rating =
|
|
2553
|
+
var Rating = React137__namespace.default.forwardRef(
|
|
2331
2554
|
({
|
|
2332
2555
|
value: valueProp,
|
|
2333
2556
|
defaultValue = 0,
|
|
@@ -2343,10 +2566,10 @@ var Rating = React131__namespace.default.forwardRef(
|
|
|
2343
2566
|
...props
|
|
2344
2567
|
}, ref) => {
|
|
2345
2568
|
const isControlled = valueProp !== void 0;
|
|
2346
|
-
const [internal, setInternal] =
|
|
2569
|
+
const [internal, setInternal] = React137__namespace.default.useState(defaultValue);
|
|
2347
2570
|
const value = isControlled ? valueProp : internal;
|
|
2348
2571
|
const step = allowHalf ? 0.5 : 1;
|
|
2349
|
-
const commit =
|
|
2572
|
+
const commit = React137__namespace.default.useCallback(
|
|
2350
2573
|
(next) => {
|
|
2351
2574
|
const clamped = Math.max(0, Math.min(max, next));
|
|
2352
2575
|
if (!isControlled) setInternal(clamped);
|
|
@@ -2393,13 +2616,13 @@ var Rating = React131__namespace.default.forwardRef(
|
|
|
2393
2616
|
children: Array.from({ length: max }).map((_, i) => {
|
|
2394
2617
|
const fillPercent = Math.max(0, Math.min(1, value - i)) * 100;
|
|
2395
2618
|
const Icon2 = /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "relative inline-block leading-none", children: [
|
|
2396
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: cn("block text-muted-foreground/40",
|
|
2619
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: cn("block text-muted-foreground/40", SIZE2[size]), children: emptyIcon ?? /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Star, { className: "h-full w-full", strokeWidth: 1.5 }) }),
|
|
2397
2620
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2398
2621
|
"span",
|
|
2399
2622
|
{
|
|
2400
2623
|
className: cn(
|
|
2401
2624
|
"absolute inset-0 overflow-hidden text-[hsl(var(--primary))]",
|
|
2402
|
-
|
|
2625
|
+
SIZE2[size]
|
|
2403
2626
|
),
|
|
2404
2627
|
style: { width: `${fillPercent}%` },
|
|
2405
2628
|
"aria-hidden": "true",
|
|
@@ -2460,7 +2683,7 @@ var ResizableHandle = ({
|
|
|
2460
2683
|
children: withHandle && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "z-10 flex h-4 w-3 items-center justify-center rounded-sm border bg-border", children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.GripVertical, { className: "h-2.5 w-2.5" }) })
|
|
2461
2684
|
}
|
|
2462
2685
|
);
|
|
2463
|
-
var ScrollArea =
|
|
2686
|
+
var ScrollArea = React137__namespace.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2464
2687
|
ScrollAreaPrimitive__namespace.Root,
|
|
2465
2688
|
{
|
|
2466
2689
|
ref,
|
|
@@ -2474,7 +2697,7 @@ var ScrollArea = React131__namespace.forwardRef(({ className, children, ...props
|
|
|
2474
2697
|
}
|
|
2475
2698
|
));
|
|
2476
2699
|
ScrollArea.displayName = ScrollAreaPrimitive__namespace.Root.displayName;
|
|
2477
|
-
var ScrollBar =
|
|
2700
|
+
var ScrollBar = React137__namespace.forwardRef(({ className, orientation = "vertical", ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2478
2701
|
ScrollAreaPrimitive__namespace.ScrollAreaScrollbar,
|
|
2479
2702
|
{
|
|
2480
2703
|
ref,
|
|
@@ -2493,7 +2716,7 @@ ScrollBar.displayName = ScrollAreaPrimitive__namespace.ScrollAreaScrollbar.displ
|
|
|
2493
2716
|
var Select = SelectPrimitive__namespace.Root;
|
|
2494
2717
|
var SelectGroup = SelectPrimitive__namespace.Group;
|
|
2495
2718
|
var SelectValue = SelectPrimitive__namespace.Value;
|
|
2496
|
-
var SelectTrigger =
|
|
2719
|
+
var SelectTrigger = React137__namespace.default.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2497
2720
|
SelectPrimitive__namespace.Trigger,
|
|
2498
2721
|
{
|
|
2499
2722
|
ref,
|
|
@@ -2513,7 +2736,7 @@ var SelectTrigger = React131__namespace.default.forwardRef(({ className, childre
|
|
|
2513
2736
|
}
|
|
2514
2737
|
));
|
|
2515
2738
|
SelectTrigger.displayName = SelectPrimitive__namespace.Trigger.displayName;
|
|
2516
|
-
var SelectScrollUpButton =
|
|
2739
|
+
var SelectScrollUpButton = React137__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2517
2740
|
SelectPrimitive__namespace.ScrollUpButton,
|
|
2518
2741
|
{
|
|
2519
2742
|
ref,
|
|
@@ -2523,7 +2746,7 @@ var SelectScrollUpButton = React131__namespace.default.forwardRef(({ className,
|
|
|
2523
2746
|
}
|
|
2524
2747
|
));
|
|
2525
2748
|
SelectScrollUpButton.displayName = SelectPrimitive__namespace.ScrollUpButton.displayName;
|
|
2526
|
-
var SelectScrollDownButton =
|
|
2749
|
+
var SelectScrollDownButton = React137__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2527
2750
|
SelectPrimitive__namespace.ScrollDownButton,
|
|
2528
2751
|
{
|
|
2529
2752
|
ref,
|
|
@@ -2533,7 +2756,7 @@ var SelectScrollDownButton = React131__namespace.default.forwardRef(({ className
|
|
|
2533
2756
|
}
|
|
2534
2757
|
));
|
|
2535
2758
|
SelectScrollDownButton.displayName = SelectPrimitive__namespace.ScrollDownButton.displayName;
|
|
2536
|
-
var SelectContent =
|
|
2759
|
+
var SelectContent = React137__namespace.default.forwardRef(({ className, children, position = "popper", ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(SelectPrimitive__namespace.Portal, { children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2537
2760
|
SelectPrimitive__namespace.Content,
|
|
2538
2761
|
{
|
|
2539
2762
|
ref,
|
|
@@ -2560,7 +2783,7 @@ var SelectContent = React131__namespace.default.forwardRef(({ className, childre
|
|
|
2560
2783
|
}
|
|
2561
2784
|
) }));
|
|
2562
2785
|
SelectContent.displayName = SelectPrimitive__namespace.Content.displayName;
|
|
2563
|
-
var SelectLabel =
|
|
2786
|
+
var SelectLabel = React137__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2564
2787
|
SelectPrimitive__namespace.Label,
|
|
2565
2788
|
{
|
|
2566
2789
|
ref,
|
|
@@ -2569,7 +2792,7 @@ var SelectLabel = React131__namespace.default.forwardRef(({ className, ...props
|
|
|
2569
2792
|
}
|
|
2570
2793
|
));
|
|
2571
2794
|
SelectLabel.displayName = SelectPrimitive__namespace.Label.displayName;
|
|
2572
|
-
var SelectItem =
|
|
2795
|
+
var SelectItem = React137__namespace.default.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2573
2796
|
SelectPrimitive__namespace.Item,
|
|
2574
2797
|
{
|
|
2575
2798
|
ref,
|
|
@@ -2587,7 +2810,7 @@ var SelectItem = React131__namespace.default.forwardRef(({ className, children,
|
|
|
2587
2810
|
}
|
|
2588
2811
|
));
|
|
2589
2812
|
SelectItem.displayName = SelectPrimitive__namespace.Item.displayName;
|
|
2590
|
-
var SelectSeparator =
|
|
2813
|
+
var SelectSeparator = React137__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2591
2814
|
SelectPrimitive__namespace.Separator,
|
|
2592
2815
|
{
|
|
2593
2816
|
ref,
|
|
@@ -2596,7 +2819,7 @@ var SelectSeparator = React131__namespace.default.forwardRef(({ className, ...pr
|
|
|
2596
2819
|
}
|
|
2597
2820
|
));
|
|
2598
2821
|
SelectSeparator.displayName = SelectPrimitive__namespace.Separator.displayName;
|
|
2599
|
-
var Separator6 =
|
|
2822
|
+
var Separator6 = React137__namespace.default.forwardRef(({ className, orientation = "horizontal", decorative = true, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2600
2823
|
SeparatorPrimitive__namespace.Root,
|
|
2601
2824
|
{
|
|
2602
2825
|
ref,
|
|
@@ -2615,7 +2838,7 @@ var Sheet = DialogPrimitive__namespace.Root;
|
|
|
2615
2838
|
var SheetTrigger = DialogPrimitive__namespace.Trigger;
|
|
2616
2839
|
var SheetClose = DialogPrimitive__namespace.Close;
|
|
2617
2840
|
var SheetPortal = DialogPrimitive__namespace.Portal;
|
|
2618
|
-
var SheetOverlay =
|
|
2841
|
+
var SheetOverlay = React137__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2619
2842
|
DialogPrimitive__namespace.Overlay,
|
|
2620
2843
|
{
|
|
2621
2844
|
ref,
|
|
@@ -2643,7 +2866,7 @@ var sheetVariants = classVarianceAuthority.cva(
|
|
|
2643
2866
|
defaultVariants: { side: "right" }
|
|
2644
2867
|
}
|
|
2645
2868
|
);
|
|
2646
|
-
var SheetContent =
|
|
2869
|
+
var SheetContent = React137__namespace.default.forwardRef(({ side = "right", className, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(SheetPortal, { children: [
|
|
2647
2870
|
/* @__PURE__ */ jsxRuntime.jsx(SheetOverlay, {}),
|
|
2648
2871
|
/* @__PURE__ */ jsxRuntime.jsxs(DialogPrimitive__namespace.Content, { ref, className: cn(sheetVariants({ side }), className), ...props, children: [
|
|
2649
2872
|
/* @__PURE__ */ jsxRuntime.jsxs(DialogPrimitive__namespace.Close, { className: "absolute right-4 top-4 rounded-sm opacity-70 hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-[hsl(var(--ring))]", children: [
|
|
@@ -2656,9 +2879,9 @@ var SheetContent = React131__namespace.default.forwardRef(({ side = "right", cla
|
|
|
2656
2879
|
SheetContent.displayName = DialogPrimitive__namespace.Content.displayName;
|
|
2657
2880
|
var SheetHeader = ({ className, ...props }) => /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn("flex flex-col space-y-2 text-center sm:text-left", className), ...props });
|
|
2658
2881
|
var SheetFooter = ({ className, ...props }) => /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2", className), ...props });
|
|
2659
|
-
var SheetTitle =
|
|
2882
|
+
var SheetTitle = React137__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(DialogPrimitive__namespace.Title, { ref, className: cn("text-lg font-semibold", className), ...props }));
|
|
2660
2883
|
SheetTitle.displayName = DialogPrimitive__namespace.Title.displayName;
|
|
2661
|
-
var SheetDescription =
|
|
2884
|
+
var SheetDescription = React137__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(DialogPrimitive__namespace.Description, { ref, className: cn("text-sm text-[hsl(var(--muted-foreground))]", className), ...props }));
|
|
2662
2885
|
SheetDescription.displayName = DialogPrimitive__namespace.Description.displayName;
|
|
2663
2886
|
function Skeleton({ className, ...props }) {
|
|
2664
2887
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -2669,7 +2892,7 @@ function Skeleton({ className, ...props }) {
|
|
|
2669
2892
|
}
|
|
2670
2893
|
);
|
|
2671
2894
|
}
|
|
2672
|
-
var Slider =
|
|
2895
|
+
var Slider = React137__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2673
2896
|
SliderPrimitive__namespace.Root,
|
|
2674
2897
|
{
|
|
2675
2898
|
ref,
|
|
@@ -2693,7 +2916,7 @@ function Spinner({ className, ...props }) {
|
|
|
2693
2916
|
}
|
|
2694
2917
|
);
|
|
2695
2918
|
}
|
|
2696
|
-
var Switch =
|
|
2919
|
+
var Switch = React137__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2697
2920
|
SwitchPrimitive__namespace.Root,
|
|
2698
2921
|
{
|
|
2699
2922
|
ref,
|
|
@@ -2719,7 +2942,7 @@ var Switch = React131__namespace.default.forwardRef(({ className, ...props }, re
|
|
|
2719
2942
|
}
|
|
2720
2943
|
));
|
|
2721
2944
|
Switch.displayName = SwitchPrimitive__namespace.Root.displayName;
|
|
2722
|
-
var Table =
|
|
2945
|
+
var Table = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { className: "relative w-full overflow-auto", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
2723
2946
|
"table",
|
|
2724
2947
|
{
|
|
2725
2948
|
ref,
|
|
@@ -2728,9 +2951,9 @@ var Table = React131__namespace.forwardRef(({ className, ...props }, ref) => /*
|
|
|
2728
2951
|
}
|
|
2729
2952
|
) }));
|
|
2730
2953
|
Table.displayName = "Table";
|
|
2731
|
-
var TableHeader =
|
|
2954
|
+
var TableHeader = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("thead", { ref, className: cn("[&_tr]:border-b", className), ...props }));
|
|
2732
2955
|
TableHeader.displayName = "TableHeader";
|
|
2733
|
-
var TableBody =
|
|
2956
|
+
var TableBody = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2734
2957
|
"tbody",
|
|
2735
2958
|
{
|
|
2736
2959
|
ref,
|
|
@@ -2739,7 +2962,7 @@ var TableBody = React131__namespace.forwardRef(({ className, ...props }, ref) =>
|
|
|
2739
2962
|
}
|
|
2740
2963
|
));
|
|
2741
2964
|
TableBody.displayName = "TableBody";
|
|
2742
|
-
var TableFooter =
|
|
2965
|
+
var TableFooter = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2743
2966
|
"tfoot",
|
|
2744
2967
|
{
|
|
2745
2968
|
ref,
|
|
@@ -2751,7 +2974,7 @@ var TableFooter = React131__namespace.forwardRef(({ className, ...props }, ref)
|
|
|
2751
2974
|
}
|
|
2752
2975
|
));
|
|
2753
2976
|
TableFooter.displayName = "TableFooter";
|
|
2754
|
-
var TableRow =
|
|
2977
|
+
var TableRow = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2755
2978
|
"tr",
|
|
2756
2979
|
{
|
|
2757
2980
|
ref,
|
|
@@ -2763,7 +2986,7 @@ var TableRow = React131__namespace.forwardRef(({ className, ...props }, ref) =>
|
|
|
2763
2986
|
}
|
|
2764
2987
|
));
|
|
2765
2988
|
TableRow.displayName = "TableRow";
|
|
2766
|
-
var TableHead =
|
|
2989
|
+
var TableHead = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2767
2990
|
"th",
|
|
2768
2991
|
{
|
|
2769
2992
|
ref,
|
|
@@ -2775,7 +2998,7 @@ var TableHead = React131__namespace.forwardRef(({ className, ...props }, ref) =>
|
|
|
2775
2998
|
}
|
|
2776
2999
|
));
|
|
2777
3000
|
TableHead.displayName = "TableHead";
|
|
2778
|
-
var TableCell =
|
|
3001
|
+
var TableCell = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2779
3002
|
"td",
|
|
2780
3003
|
{
|
|
2781
3004
|
ref,
|
|
@@ -2787,7 +3010,7 @@ var TableCell = React131__namespace.forwardRef(({ className, ...props }, ref) =>
|
|
|
2787
3010
|
}
|
|
2788
3011
|
));
|
|
2789
3012
|
TableCell.displayName = "TableCell";
|
|
2790
|
-
var TableCaption =
|
|
3013
|
+
var TableCaption = React137__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2791
3014
|
"caption",
|
|
2792
3015
|
{
|
|
2793
3016
|
ref,
|
|
@@ -2797,7 +3020,7 @@ var TableCaption = React131__namespace.forwardRef(({ className, ...props }, ref)
|
|
|
2797
3020
|
));
|
|
2798
3021
|
TableCaption.displayName = "TableCaption";
|
|
2799
3022
|
var Tabs = TabsPrimitive__namespace.Root;
|
|
2800
|
-
var TabsList =
|
|
3023
|
+
var TabsList = React137__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2801
3024
|
TabsPrimitive__namespace.List,
|
|
2802
3025
|
{
|
|
2803
3026
|
ref,
|
|
@@ -2809,7 +3032,7 @@ var TabsList = React131__namespace.default.forwardRef(({ className, ...props },
|
|
|
2809
3032
|
}
|
|
2810
3033
|
));
|
|
2811
3034
|
TabsList.displayName = TabsPrimitive__namespace.List.displayName;
|
|
2812
|
-
var TabsTrigger =
|
|
3035
|
+
var TabsTrigger = React137__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2813
3036
|
TabsPrimitive__namespace.Trigger,
|
|
2814
3037
|
{
|
|
2815
3038
|
ref,
|
|
@@ -2824,7 +3047,7 @@ var TabsTrigger = React131__namespace.default.forwardRef(({ className, ...props
|
|
|
2824
3047
|
}
|
|
2825
3048
|
));
|
|
2826
3049
|
TabsTrigger.displayName = TabsPrimitive__namespace.Trigger.displayName;
|
|
2827
|
-
var TabsContent =
|
|
3050
|
+
var TabsContent = React137__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2828
3051
|
TabsPrimitive__namespace.Content,
|
|
2829
3052
|
{
|
|
2830
3053
|
ref,
|
|
@@ -2836,7 +3059,7 @@ var TabsContent = React131__namespace.default.forwardRef(({ className, ...props
|
|
|
2836
3059
|
}
|
|
2837
3060
|
));
|
|
2838
3061
|
TabsContent.displayName = TabsPrimitive__namespace.Content.displayName;
|
|
2839
|
-
var Textarea =
|
|
3062
|
+
var Textarea = React137__namespace.default.forwardRef(
|
|
2840
3063
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2841
3064
|
"textarea",
|
|
2842
3065
|
{
|
|
@@ -2854,7 +3077,7 @@ var Textarea = React131__namespace.default.forwardRef(
|
|
|
2854
3077
|
)
|
|
2855
3078
|
);
|
|
2856
3079
|
Textarea.displayName = "Textarea";
|
|
2857
|
-
var TextureCard =
|
|
3080
|
+
var TextureCard = React137__namespace.forwardRef(
|
|
2858
3081
|
({ children, className, padding = true, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2859
3082
|
"div",
|
|
2860
3083
|
{
|
|
@@ -2871,15 +3094,15 @@ var TextureCard = React131__namespace.forwardRef(
|
|
|
2871
3094
|
)
|
|
2872
3095
|
);
|
|
2873
3096
|
TextureCard.displayName = "TextureCard";
|
|
2874
|
-
var TextureCardHeader =
|
|
3097
|
+
var TextureCardHeader = React137__namespace.forwardRef(
|
|
2875
3098
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("flex flex-col gap-1.5 mb-4", className), ...props })
|
|
2876
3099
|
);
|
|
2877
3100
|
TextureCardHeader.displayName = "TextureCardHeader";
|
|
2878
|
-
var TextureCardTitle =
|
|
3101
|
+
var TextureCardTitle = React137__namespace.forwardRef(
|
|
2879
3102
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("h3", { ref, className: cn("font-semibold text-base leading-tight tracking-tight text-foreground", className), ...props })
|
|
2880
3103
|
);
|
|
2881
3104
|
TextureCardTitle.displayName = "TextureCardTitle";
|
|
2882
|
-
var TextureCardDescription =
|
|
3105
|
+
var TextureCardDescription = React137__namespace.forwardRef(
|
|
2883
3106
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("p", { ref, className: cn("text-sm text-muted-foreground", className), ...props })
|
|
2884
3107
|
);
|
|
2885
3108
|
TextureCardDescription.displayName = "TextureCardDescription";
|
|
@@ -2903,7 +3126,7 @@ var toggleVariants = classVarianceAuthority.cva(
|
|
|
2903
3126
|
}
|
|
2904
3127
|
}
|
|
2905
3128
|
);
|
|
2906
|
-
var Toggle =
|
|
3129
|
+
var Toggle = React137__namespace.forwardRef(({ className, variant, size, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2907
3130
|
TogglePrimitive__namespace.Root,
|
|
2908
3131
|
{
|
|
2909
3132
|
ref,
|
|
@@ -2912,11 +3135,11 @@ var Toggle = React131__namespace.forwardRef(({ className, variant, size, ...prop
|
|
|
2912
3135
|
}
|
|
2913
3136
|
));
|
|
2914
3137
|
Toggle.displayName = TogglePrimitive__namespace.Root.displayName;
|
|
2915
|
-
var ToggleGroupContext =
|
|
3138
|
+
var ToggleGroupContext = React137__namespace.createContext({
|
|
2916
3139
|
size: "default",
|
|
2917
3140
|
variant: "default"
|
|
2918
3141
|
});
|
|
2919
|
-
var ToggleGroup =
|
|
3142
|
+
var ToggleGroup = React137__namespace.forwardRef(({ className, variant, size, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2920
3143
|
ToggleGroupPrimitive__namespace.Root,
|
|
2921
3144
|
{
|
|
2922
3145
|
ref,
|
|
@@ -2926,8 +3149,8 @@ var ToggleGroup = React131__namespace.forwardRef(({ className, variant, size, ch
|
|
|
2926
3149
|
}
|
|
2927
3150
|
));
|
|
2928
3151
|
ToggleGroup.displayName = ToggleGroupPrimitive__namespace.Root.displayName;
|
|
2929
|
-
var ToggleGroupItem =
|
|
2930
|
-
const context =
|
|
3152
|
+
var ToggleGroupItem = React137__namespace.forwardRef(({ className, children, variant, size, ...props }, ref) => {
|
|
3153
|
+
const context = React137__namespace.useContext(ToggleGroupContext);
|
|
2931
3154
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
2932
3155
|
ToggleGroupPrimitive__namespace.Item,
|
|
2933
3156
|
{
|
|
@@ -2948,7 +3171,7 @@ ToggleGroupItem.displayName = ToggleGroupPrimitive__namespace.Item.displayName;
|
|
|
2948
3171
|
var TooltipProvider = TooltipPrimitive__namespace.Provider;
|
|
2949
3172
|
var Tooltip2 = TooltipPrimitive__namespace.Root;
|
|
2950
3173
|
var TooltipTrigger = TooltipPrimitive__namespace.Trigger;
|
|
2951
|
-
var TooltipContent =
|
|
3174
|
+
var TooltipContent = React137__namespace.default.forwardRef(({ className, sideOffset = 4, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(TooltipPrimitive__namespace.Portal, { children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
2952
3175
|
TooltipPrimitive__namespace.Content,
|
|
2953
3176
|
{
|
|
2954
3177
|
ref,
|
|
@@ -2964,6 +3187,52 @@ var TooltipContent = React131__namespace.default.forwardRef(({ className, sideOf
|
|
|
2964
3187
|
}
|
|
2965
3188
|
) }));
|
|
2966
3189
|
TooltipContent.displayName = TooltipPrimitive__namespace.Content.displayName;
|
|
3190
|
+
var VariantPicker = React137__namespace.default.forwardRef(
|
|
3191
|
+
({ label, options, value: valueProp, defaultValue, onValueChange, className, ...props }, ref) => {
|
|
3192
|
+
const isControlled = valueProp !== void 0;
|
|
3193
|
+
const [internal, setInternal] = React137__namespace.default.useState(defaultValue);
|
|
3194
|
+
const value = isControlled ? valueProp : internal;
|
|
3195
|
+
const select = (v) => {
|
|
3196
|
+
if (!isControlled) setInternal(v);
|
|
3197
|
+
onValueChange?.(v);
|
|
3198
|
+
};
|
|
3199
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { ref, role: "radiogroup", "aria-label": label, className: cn("flex flex-col gap-2", className), ...props, children: [
|
|
3200
|
+
label && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-xs font-semibold uppercase tracking-wide text-muted-foreground", children: label }),
|
|
3201
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex flex-wrap gap-2", children: options.map((opt) => {
|
|
3202
|
+
const selected = value === opt.value;
|
|
3203
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
3204
|
+
"button",
|
|
3205
|
+
{
|
|
3206
|
+
type: "button",
|
|
3207
|
+
role: "radio",
|
|
3208
|
+
"aria-checked": selected,
|
|
3209
|
+
disabled: opt.disabled,
|
|
3210
|
+
onClick: () => select(opt.value),
|
|
3211
|
+
className: cn(
|
|
3212
|
+
"inline-flex items-center gap-2 rounded-md border px-3 py-1.5 text-sm font-medium transition-colors",
|
|
3213
|
+
"focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",
|
|
3214
|
+
selected ? "border-primary bg-primary/10 text-[hsl(var(--primary))]" : "border-border hover:bg-accent hover:text-accent-foreground",
|
|
3215
|
+
opt.disabled && "cursor-not-allowed text-muted-foreground line-through opacity-50"
|
|
3216
|
+
),
|
|
3217
|
+
children: [
|
|
3218
|
+
opt.swatch && /* @__PURE__ */ jsxRuntime.jsx(
|
|
3219
|
+
"span",
|
|
3220
|
+
{
|
|
3221
|
+
"aria-hidden": "true",
|
|
3222
|
+
className: "h-4 w-4 rounded-full border border-border",
|
|
3223
|
+
style: { backgroundColor: opt.swatch }
|
|
3224
|
+
}
|
|
3225
|
+
),
|
|
3226
|
+
opt.label
|
|
3227
|
+
]
|
|
3228
|
+
},
|
|
3229
|
+
opt.value
|
|
3230
|
+
);
|
|
3231
|
+
}) })
|
|
3232
|
+
] });
|
|
3233
|
+
}
|
|
3234
|
+
);
|
|
3235
|
+
VariantPicker.displayName = "VariantPicker";
|
|
2967
3236
|
var bannerVariants = classVarianceAuthority.cva(
|
|
2968
3237
|
"relative flex items-start gap-3 rounded-lg border px-4 py-3.5 text-sm transition-all",
|
|
2969
3238
|
{
|
|
@@ -3060,8 +3329,8 @@ function Banner({
|
|
|
3060
3329
|
className,
|
|
3061
3330
|
children
|
|
3062
3331
|
}) {
|
|
3063
|
-
const [dismissed, setDismissed] =
|
|
3064
|
-
const [exiting, setExiting] =
|
|
3332
|
+
const [dismissed, setDismissed] = React137__namespace.default.useState(false);
|
|
3333
|
+
const [exiting, setExiting] = React137__namespace.default.useState(false);
|
|
3065
3334
|
const handleDismiss = () => {
|
|
3066
3335
|
setExiting(true);
|
|
3067
3336
|
setTimeout(() => {
|
|
@@ -3122,7 +3391,7 @@ function BreadcrumbSeparator({ className }) {
|
|
|
3122
3391
|
return /* @__PURE__ */ jsxRuntime.jsx("li", { role: "presentation", "aria-hidden": "true", className: cn("flex items-center text-[hsl(var(--muted-foreground))]", className), children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.ChevronRight, { className: "h-3.5 w-3.5" }) });
|
|
3123
3392
|
}
|
|
3124
3393
|
function Breadcrumb({ children, className }) {
|
|
3125
|
-
const items =
|
|
3394
|
+
const items = React137__namespace.default.Children.toArray(children);
|
|
3126
3395
|
const withSeparators = [];
|
|
3127
3396
|
items.forEach((item, i) => {
|
|
3128
3397
|
withSeparators.push(item);
|
|
@@ -3152,8 +3421,8 @@ function CommandItem2({ icon, label, description, shortcut, active, onClick, cla
|
|
|
3152
3421
|
);
|
|
3153
3422
|
}
|
|
3154
3423
|
function EditableCell({ value: initial, onSave }) {
|
|
3155
|
-
const [editing, setEditing] =
|
|
3156
|
-
const [val, setVal] =
|
|
3424
|
+
const [editing, setEditing] = React137__namespace.default.useState(false);
|
|
3425
|
+
const [val, setVal] = React137__namespace.default.useState(String(initial ?? ""));
|
|
3157
3426
|
const commit = () => {
|
|
3158
3427
|
onSave(val);
|
|
3159
3428
|
setEditing(false);
|
|
@@ -3184,10 +3453,10 @@ var selectionCol = () => ({
|
|
|
3184
3453
|
enableResizing: false
|
|
3185
3454
|
});
|
|
3186
3455
|
function DataGrid({ columns, data: initialData, onDataChange, editable, className }) {
|
|
3187
|
-
const [data, setData] =
|
|
3188
|
-
const [rowSelection, setRowSelection] =
|
|
3456
|
+
const [data, setData] = React137__namespace.default.useState(initialData);
|
|
3457
|
+
const [rowSelection, setRowSelection] = React137__namespace.default.useState({});
|
|
3189
3458
|
const columnResizeMode = "onChange";
|
|
3190
|
-
const editableColumns =
|
|
3459
|
+
const editableColumns = React137__namespace.default.useMemo(() => {
|
|
3191
3460
|
if (!editable) return columns;
|
|
3192
3461
|
return columns.map((col) => ({
|
|
3193
3462
|
...col,
|
|
@@ -3206,7 +3475,7 @@ function DataGrid({ columns, data: initialData, onDataChange, editable, classNam
|
|
|
3206
3475
|
)
|
|
3207
3476
|
}));
|
|
3208
3477
|
}, [columns, data, editable, onDataChange]);
|
|
3209
|
-
const allColumns =
|
|
3478
|
+
const allColumns = React137__namespace.default.useMemo(() => [selectionCol(), ...editableColumns], [editableColumns]);
|
|
3210
3479
|
const table = reactTable.useReactTable({
|
|
3211
3480
|
data,
|
|
3212
3481
|
columns: allColumns,
|
|
@@ -3277,7 +3546,7 @@ function DataTableToolbar({ table, searchColumn }) {
|
|
|
3277
3546
|
) });
|
|
3278
3547
|
}
|
|
3279
3548
|
function DataTable({ columns, data, pageSize = 10, searchable, searchColumn, loading }) {
|
|
3280
|
-
const [sorting, setSorting] =
|
|
3549
|
+
const [sorting, setSorting] = React137__namespace.default.useState([]);
|
|
3281
3550
|
const table = reactTable.useReactTable({
|
|
3282
3551
|
data,
|
|
3283
3552
|
columns,
|
|
@@ -3302,7 +3571,7 @@ function DataTable({ columns, data, pageSize = 10, searchable, searchColumn, loa
|
|
|
3302
3571
|
/* @__PURE__ */ jsxRuntime.jsx(DataTablePagination, { table })
|
|
3303
3572
|
] });
|
|
3304
3573
|
}
|
|
3305
|
-
var EmptyStateIcon =
|
|
3574
|
+
var EmptyStateIcon = React137__namespace.default.forwardRef(
|
|
3306
3575
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("flex h-12 w-12 items-center justify-center rounded-full bg-[hsl(var(--muted))] text-[hsl(var(--muted-foreground))]", className), ...props })
|
|
3307
3576
|
);
|
|
3308
3577
|
EmptyStateIcon.displayName = "EmptyStateIcon";
|
|
@@ -3417,7 +3686,7 @@ function Persona({ name, subtitle, src, size = "md", badge, className }) {
|
|
|
3417
3686
|
] })
|
|
3418
3687
|
] });
|
|
3419
3688
|
}
|
|
3420
|
-
var PropertyList =
|
|
3689
|
+
var PropertyList = React137__namespace.default.forwardRef(
|
|
3421
3690
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("dl", { ref, className: cn("divide-y divide-[hsl(var(--border))]", className), ...props })
|
|
3422
3691
|
);
|
|
3423
3692
|
PropertyList.displayName = "PropertyList";
|
|
@@ -3503,7 +3772,7 @@ function StructuredListItem({ left, title, description, right, onClick, classNam
|
|
|
3503
3772
|
}
|
|
3504
3773
|
);
|
|
3505
3774
|
}
|
|
3506
|
-
var StructuredList =
|
|
3775
|
+
var StructuredList = React137__namespace.default.forwardRef(
|
|
3507
3776
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("space-y-4", className), ...props })
|
|
3508
3777
|
);
|
|
3509
3778
|
StructuredList.displayName = "StructuredList";
|
|
@@ -3513,7 +3782,7 @@ var dotColors = {
|
|
|
3513
3782
|
error: "bg-red-500",
|
|
3514
3783
|
warning: "bg-yellow-500"
|
|
3515
3784
|
};
|
|
3516
|
-
var TimelineContent =
|
|
3785
|
+
var TimelineContent = React137__namespace.default.forwardRef(
|
|
3517
3786
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("pb-1", className), ...props })
|
|
3518
3787
|
);
|
|
3519
3788
|
TimelineContent.displayName = "TimelineContent";
|
|
@@ -3536,9 +3805,9 @@ function TimelineItem({ icon, title, description, timestamp, variant = "default"
|
|
|
3536
3805
|
] });
|
|
3537
3806
|
}
|
|
3538
3807
|
function Timeline({ children, className }) {
|
|
3539
|
-
const items =
|
|
3808
|
+
const items = React137__namespace.default.Children.toArray(children);
|
|
3540
3809
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn("", className), children: items.map(
|
|
3541
|
-
(child, i) =>
|
|
3810
|
+
(child, i) => React137__namespace.default.isValidElement(child) ? React137__namespace.default.cloneElement(child, { isLast: i === items.length - 1 }) : child
|
|
3542
3811
|
) });
|
|
3543
3812
|
}
|
|
3544
3813
|
var INITIAL_MESSAGES = [
|
|
@@ -3563,8 +3832,8 @@ function ChatBubble({ msg }) {
|
|
|
3563
3832
|
] });
|
|
3564
3833
|
}
|
|
3565
3834
|
function ChatDetail({ className }) {
|
|
3566
|
-
const [messages, setMessages] =
|
|
3567
|
-
const [input, setInput] =
|
|
3835
|
+
const [messages, setMessages] = React137.useState(INITIAL_MESSAGES);
|
|
3836
|
+
const [input, setInput] = React137.useState("");
|
|
3568
3837
|
const send = () => {
|
|
3569
3838
|
if (!input.trim()) return;
|
|
3570
3839
|
const now = (/* @__PURE__ */ new Date()).toLocaleTimeString([], { hour: "2-digit", minute: "2-digit" });
|
|
@@ -3597,9 +3866,9 @@ function ChatDetail({ className }) {
|
|
|
3597
3866
|
}
|
|
3598
3867
|
var REACTIONS = ["\u{1F60A}", "\u{1F610}", "\u{1F615}", "\u{1F621}", "\u{1F929}"];
|
|
3599
3868
|
function FeedbackModal({ onSubmit, className }) {
|
|
3600
|
-
const [reaction, setReaction] =
|
|
3601
|
-
const [text, setText] =
|
|
3602
|
-
const [submitted, setSubmitted] =
|
|
3869
|
+
const [reaction, setReaction] = React137.useState("");
|
|
3870
|
+
const [text, setText] = React137.useState("");
|
|
3871
|
+
const [submitted, setSubmitted] = React137.useState(false);
|
|
3603
3872
|
const handleSubmit = () => {
|
|
3604
3873
|
onSubmit?.({ reaction, text });
|
|
3605
3874
|
setSubmitted(true);
|
|
@@ -3722,7 +3991,7 @@ function FileRow({ file, onDelete }) {
|
|
|
3722
3991
|
] });
|
|
3723
3992
|
}
|
|
3724
3993
|
function FilesList({ className }) {
|
|
3725
|
-
const [files, setFiles] =
|
|
3994
|
+
const [files, setFiles] = React137__namespace.default.useState(FILES2);
|
|
3726
3995
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn("rounded-md border border-[hsl(var(--border))] overflow-hidden", className), children: /* @__PURE__ */ jsxRuntime.jsxs("table", { className: "w-full", children: [
|
|
3727
3996
|
/* @__PURE__ */ jsxRuntime.jsx("thead", { className: "bg-[hsl(var(--muted)/0.5)]", children: /* @__PURE__ */ jsxRuntime.jsx("tr", { children: ["Name", "Type", "Size", "Modified", ""].map((h) => /* @__PURE__ */ jsxRuntime.jsx("th", { className: "px-4 py-2.5 text-left text-xs font-medium text-[hsl(var(--muted-foreground))]", children: h }, h)) }) }),
|
|
3728
3997
|
/* @__PURE__ */ jsxRuntime.jsx("tbody", { children: files.map((f) => /* @__PURE__ */ jsxRuntime.jsx(FileRow, { file: f, onDelete: () => setFiles((fs) => fs.filter((x) => x.id !== f.id)) }, f.id)) })
|
|
@@ -3735,7 +4004,7 @@ function IntegrationCard({
|
|
|
3735
4004
|
connected = false,
|
|
3736
4005
|
className
|
|
3737
4006
|
}) {
|
|
3738
|
-
const [isConnected, setIsConnected] =
|
|
4007
|
+
const [isConnected, setIsConnected] = React137.useState(connected);
|
|
3739
4008
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: cn("flex items-center gap-4 rounded-md border border-[hsl(var(--border))] bg-[hsl(var(--card))] p-4", className), children: [
|
|
3740
4009
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex h-10 w-10 shrink-0 items-center justify-center rounded-md bg-[hsl(var(--muted))] text-[hsl(var(--muted-foreground))]", children: icon ?? /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-base font-bold", children: name[0] }) }),
|
|
3741
4010
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex-1 min-w-0", children: [
|
|
@@ -3769,9 +4038,9 @@ var PENDING = [
|
|
|
3769
4038
|
{ email: "sam@startup.io", role: "Viewer" }
|
|
3770
4039
|
];
|
|
3771
4040
|
function InviteModal({ className }) {
|
|
3772
|
-
const [email, setEmail] =
|
|
3773
|
-
const [role, setRole] =
|
|
3774
|
-
const [pending, setPending] =
|
|
4041
|
+
const [email, setEmail] = React137.useState("");
|
|
4042
|
+
const [role, setRole] = React137.useState("Member");
|
|
4043
|
+
const [pending, setPending] = React137.useState(PENDING);
|
|
3775
4044
|
const invite = () => {
|
|
3776
4045
|
if (!email.trim()) return;
|
|
3777
4046
|
setPending((p) => [...p, { email: email.trim(), role }]);
|
|
@@ -3818,9 +4087,9 @@ var INITIAL_TAGS = [
|
|
|
3818
4087
|
{ id: "4", name: "Research", color: "bg-purple-500" }
|
|
3819
4088
|
];
|
|
3820
4089
|
function ManageTagsModal({ className }) {
|
|
3821
|
-
const [tags, setTags] =
|
|
3822
|
-
const [newTag, setNewTag] =
|
|
3823
|
-
const [colorIdx, setColorIdx] =
|
|
4090
|
+
const [tags, setTags] = React137.useState(INITIAL_TAGS);
|
|
4091
|
+
const [newTag, setNewTag] = React137.useState("");
|
|
4092
|
+
const [colorIdx, setColorIdx] = React137.useState(0);
|
|
3824
4093
|
const addTag = () => {
|
|
3825
4094
|
if (!newTag.trim()) return;
|
|
3826
4095
|
const id = `tag-${Date.now()}`;
|
|
@@ -4022,13 +4291,13 @@ function Heatmap({
|
|
|
4022
4291
|
showLegend = true,
|
|
4023
4292
|
formatTooltip
|
|
4024
4293
|
}) {
|
|
4025
|
-
const valueByDate =
|
|
4294
|
+
const valueByDate = React137.useMemo(() => {
|
|
4026
4295
|
const m = /* @__PURE__ */ new Map();
|
|
4027
4296
|
for (const d of data) m.set(d.date, d.value);
|
|
4028
4297
|
return m;
|
|
4029
4298
|
}, [data]);
|
|
4030
|
-
const max =
|
|
4031
|
-
const grid =
|
|
4299
|
+
const max = React137.useMemo(() => Math.max(1, ...data.map((d) => d.value)), [data]);
|
|
4300
|
+
const grid = React137.useMemo(() => {
|
|
4032
4301
|
const end = startOfWeek(endDate);
|
|
4033
4302
|
end.setDate(end.getDate() + 6);
|
|
4034
4303
|
const cols = [];
|
|
@@ -4046,7 +4315,7 @@ function Heatmap({
|
|
|
4046
4315
|
}
|
|
4047
4316
|
return cols;
|
|
4048
4317
|
}, [endDate, weeks, valueByDate]);
|
|
4049
|
-
const monthLabels =
|
|
4318
|
+
const monthLabels = React137.useMemo(() => {
|
|
4050
4319
|
const labels = [];
|
|
4051
4320
|
let lastMonth = -1;
|
|
4052
4321
|
grid.forEach((col, i) => {
|
|
@@ -4217,9 +4486,9 @@ function apply(mode) {
|
|
|
4217
4486
|
document.documentElement.classList.toggle("dark", isDark);
|
|
4218
4487
|
}
|
|
4219
4488
|
function ThemeSwitch({ defaultMode, onChange, className, variant = "segmented" }) {
|
|
4220
|
-
const [mode, setMode] =
|
|
4221
|
-
const didMount =
|
|
4222
|
-
|
|
4489
|
+
const [mode, setMode] = React137__namespace.default.useState(() => defaultMode ?? readInitial());
|
|
4490
|
+
const didMount = React137__namespace.default.useRef(false);
|
|
4491
|
+
React137__namespace.default.useEffect(() => {
|
|
4223
4492
|
if (!didMount.current) {
|
|
4224
4493
|
didMount.current = true;
|
|
4225
4494
|
return;
|
|
@@ -4231,7 +4500,7 @@ function ThemeSwitch({ defaultMode, onChange, className, variant = "segmented" }
|
|
|
4231
4500
|
}
|
|
4232
4501
|
onChange?.(mode);
|
|
4233
4502
|
}, [mode, onChange]);
|
|
4234
|
-
|
|
4503
|
+
React137__namespace.default.useEffect(() => {
|
|
4235
4504
|
if (mode !== "system" || typeof window === "undefined") return;
|
|
4236
4505
|
const mql = window.matchMedia("(prefers-color-scheme: dark)");
|
|
4237
4506
|
const handler = () => apply("system");
|
|
@@ -4322,7 +4591,7 @@ function FloatingActionButton({
|
|
|
4322
4591
|
position = "bottom-right",
|
|
4323
4592
|
className
|
|
4324
4593
|
}) {
|
|
4325
|
-
const [open, setOpen] =
|
|
4594
|
+
const [open, setOpen] = React137__namespace.default.useState(false);
|
|
4326
4595
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
4327
4596
|
"div",
|
|
4328
4597
|
{
|
|
@@ -4363,7 +4632,7 @@ function FloatingActionButton({
|
|
|
4363
4632
|
] }),
|
|
4364
4633
|
sections.length > 0 && /* @__PURE__ */ jsxRuntime.jsx(Separator6, {})
|
|
4365
4634
|
] }),
|
|
4366
|
-
sections.length > 0 && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "px-3 py-2.5 space-y-3", children: sections.map((section, i) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
4635
|
+
sections.length > 0 && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "px-3 py-2.5 space-y-3", children: sections.map((section, i) => /* @__PURE__ */ jsxRuntime.jsxs(React137__namespace.default.Fragment, { children: [
|
|
4367
4636
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
4368
4637
|
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-[9px] font-semibold uppercase tracking-widest text-muted-foreground mb-1.5", children: section.label }),
|
|
4369
4638
|
section.content
|
|
@@ -4405,7 +4674,7 @@ function applyTheme(val) {
|
|
|
4405
4674
|
}
|
|
4406
4675
|
}
|
|
4407
4676
|
function PaletteSwatches({ options = DEFAULT_THEME_OPTIONS }) {
|
|
4408
|
-
const [activeValue, setActiveValue] =
|
|
4677
|
+
const [activeValue, setActiveValue] = React137__namespace.default.useState(readStoredTheme);
|
|
4409
4678
|
const activeOption = options.find((o) => o.value === activeValue) ?? options[0];
|
|
4410
4679
|
const handleSelect = (value) => {
|
|
4411
4680
|
setActiveValue(value);
|
|
@@ -4482,7 +4751,7 @@ function NotifRow({ label, description, checked, onChange }) {
|
|
|
4482
4751
|
] });
|
|
4483
4752
|
}
|
|
4484
4753
|
function NotificationSettings({ className }) {
|
|
4485
|
-
const [states, setStates] =
|
|
4754
|
+
const [states, setStates] = React137.useState(
|
|
4486
4755
|
Object.fromEntries(NOTIFICATIONS.map((n) => [n.id, n.default]))
|
|
4487
4756
|
);
|
|
4488
4757
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: cn("rounded-md border border-[hsl(var(--border))] bg-[hsl(var(--card))] p-6", className), children: [
|
|
@@ -4502,16 +4771,16 @@ function NotificationSettings({ className }) {
|
|
|
4502
4771
|
)) })
|
|
4503
4772
|
] });
|
|
4504
4773
|
}
|
|
4505
|
-
var SidebarCtx =
|
|
4774
|
+
var SidebarCtx = React137.createContext({
|
|
4506
4775
|
collapsed: false,
|
|
4507
4776
|
toggleCollapsed: () => {
|
|
4508
4777
|
}
|
|
4509
4778
|
});
|
|
4510
4779
|
function useSidebar() {
|
|
4511
|
-
return
|
|
4780
|
+
return React137.useContext(SidebarCtx);
|
|
4512
4781
|
}
|
|
4513
4782
|
function SidebarRoot({ children, storageKey = "sidebar-collapsed", defaultCollapsed = false, className }) {
|
|
4514
|
-
const [collapsed, setCollapsed] =
|
|
4783
|
+
const [collapsed, setCollapsed] = React137.useState(() => {
|
|
4515
4784
|
if (typeof window === "undefined") return defaultCollapsed;
|
|
4516
4785
|
try {
|
|
4517
4786
|
return JSON.parse(localStorage.getItem(storageKey) ?? String(defaultCollapsed));
|
|
@@ -4519,7 +4788,7 @@ function SidebarRoot({ children, storageKey = "sidebar-collapsed", defaultCollap
|
|
|
4519
4788
|
return defaultCollapsed;
|
|
4520
4789
|
}
|
|
4521
4790
|
});
|
|
4522
|
-
const toggleCollapsed =
|
|
4791
|
+
const toggleCollapsed = React137.useCallback(() => {
|
|
4523
4792
|
setCollapsed((v) => {
|
|
4524
4793
|
const next = !v;
|
|
4525
4794
|
try {
|
|
@@ -4647,7 +4916,7 @@ function OrgMenu({
|
|
|
4647
4916
|
onCreateOrg,
|
|
4648
4917
|
className
|
|
4649
4918
|
}) {
|
|
4650
|
-
const [internalId, setInternalId] =
|
|
4919
|
+
const [internalId, setInternalId] = React137.useState(defaultOrgId ?? ORGS[0]?.id ?? "1");
|
|
4651
4920
|
const activeId = currentOrgId ?? internalId;
|
|
4652
4921
|
const current = ORGS.find((o) => o.id === activeId) ?? ORGS[0];
|
|
4653
4922
|
const { collapsed } = useSidebar();
|
|
@@ -4696,7 +4965,7 @@ var ROLES = [
|
|
|
4696
4965
|
{ value: "viewer", label: "Viewer", description: "Read-only access" }
|
|
4697
4966
|
];
|
|
4698
4967
|
function RolesMenu({ value = "member", onChange, className }) {
|
|
4699
|
-
const [role, setRole] =
|
|
4968
|
+
const [role, setRole] = React137.useState(value);
|
|
4700
4969
|
const current = ROLES.find((r) => r.value === role) ?? ROLES[0];
|
|
4701
4970
|
const handleChange = (v) => {
|
|
4702
4971
|
setRole(v);
|
|
@@ -4726,8 +4995,8 @@ var USERS = [
|
|
|
4726
4995
|
{ id: "6", name: "Mike Liu", email: "mike@acme.com", initials: "ML" }
|
|
4727
4996
|
];
|
|
4728
4997
|
function SelectUsersModal({ onConfirm, className }) {
|
|
4729
|
-
const [query, setQuery] =
|
|
4730
|
-
const [selected, setSelected] =
|
|
4998
|
+
const [query, setQuery] = React137.useState("");
|
|
4999
|
+
const [selected, setSelected] = React137.useState(/* @__PURE__ */ new Set());
|
|
4731
5000
|
const filtered = USERS.filter(
|
|
4732
5001
|
(u) => u.name.toLowerCase().includes(query.toLowerCase()) || u.email.toLowerCase().includes(query.toLowerCase())
|
|
4733
5002
|
);
|
|
@@ -4937,7 +5206,7 @@ function SidebarLayoutSearch({
|
|
|
4937
5206
|
children,
|
|
4938
5207
|
className
|
|
4939
5208
|
}) {
|
|
4940
|
-
const [query, setQuery] =
|
|
5209
|
+
const [query, setQuery] = React137.useState("");
|
|
4941
5210
|
const filtered = ALL_ITEMS.filter((i) => i.label.toLowerCase().includes(query.toLowerCase()));
|
|
4942
5211
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: cn("flex h-[600px] overflow-hidden rounded-md border border-[hsl(var(--border))] bg-[hsl(var(--background))]", className), children: [
|
|
4943
5212
|
/* @__PURE__ */ jsxRuntime.jsxs("aside", { className: "flex w-60 flex-col border-r border-[hsl(var(--border))] bg-[hsl(var(--card))]", children: [
|
|
@@ -5028,7 +5297,7 @@ function TaskRow({ task, onToggle }) {
|
|
|
5028
5297
|
] });
|
|
5029
5298
|
}
|
|
5030
5299
|
function SortableTaskList({ className }) {
|
|
5031
|
-
const [tasks, setTasks] =
|
|
5300
|
+
const [tasks, setTasks] = React137.useState(TASKS);
|
|
5032
5301
|
const toggle = (id) => setTasks((ts) => ts.map((t) => t.id === id ? { ...t, done: !t.done } : t));
|
|
5033
5302
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn("rounded-md border border-[hsl(var(--border))] bg-[hsl(var(--card))] p-4 space-y-4", className), children: SECTIONS.map((section) => {
|
|
5034
5303
|
const items = tasks.filter((t) => t.status === section);
|
|
@@ -5082,8 +5351,8 @@ function StackedLayoutTabs({
|
|
|
5082
5351
|
children,
|
|
5083
5352
|
className
|
|
5084
5353
|
}) {
|
|
5085
|
-
const [activeTab, setActiveTab] =
|
|
5086
|
-
const [activeNav, setActiveNav] =
|
|
5354
|
+
const [activeTab, setActiveTab] = React137.useState(0);
|
|
5355
|
+
const [activeNav, setActiveNav] = React137.useState(0);
|
|
5087
5356
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: cn("flex h-[600px] flex-col overflow-hidden rounded-md border border-[hsl(var(--border))] bg-[hsl(var(--background))]", className), children: [
|
|
5088
5357
|
/* @__PURE__ */ jsxRuntime.jsxs("nav", { className: "flex h-14 items-center gap-6 border-b border-[hsl(var(--border))] bg-[hsl(var(--card))] px-4", children: [
|
|
5089
5358
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "font-semibold text-sm shrink-0", children: brandName }),
|
|
@@ -5226,8 +5495,8 @@ var MEMBERS = [
|
|
|
5226
5495
|
];
|
|
5227
5496
|
var roleVariant = (role) => role === "Owner" ? "default" : role === "Admin" ? "secondary" : "outline";
|
|
5228
5497
|
function WorkspaceMembers({ className }) {
|
|
5229
|
-
const [query, setQuery] =
|
|
5230
|
-
const [members, setMembers] =
|
|
5498
|
+
const [query, setQuery] = React137.useState("");
|
|
5499
|
+
const [members, setMembers] = React137.useState(MEMBERS);
|
|
5231
5500
|
const filtered = members.filter(
|
|
5232
5501
|
(m) => m.name.toLowerCase().includes(query.toLowerCase()) || m.email.toLowerCase().includes(query.toLowerCase())
|
|
5233
5502
|
);
|
|
@@ -5281,8 +5550,8 @@ function BulkActions({ count, actions, onClear, className }) {
|
|
|
5281
5550
|
] });
|
|
5282
5551
|
}
|
|
5283
5552
|
function useCommandBar() {
|
|
5284
|
-
const [open, setOpen] =
|
|
5285
|
-
|
|
5553
|
+
const [open, setOpen] = React137__namespace.default.useState(false);
|
|
5554
|
+
React137__namespace.default.useEffect(() => {
|
|
5286
5555
|
const handler = (e) => {
|
|
5287
5556
|
if ((e.metaKey || e.ctrlKey) && e.key === "k") {
|
|
5288
5557
|
e.preventDefault();
|
|
@@ -5322,12 +5591,12 @@ function CommandBarItem({ icon, label, shortcut, onSelect, active, className })
|
|
|
5322
5591
|
);
|
|
5323
5592
|
}
|
|
5324
5593
|
function CommandBar({ open, onOpenChange, children, placeholder = "Search commands...", onSearch }) {
|
|
5325
|
-
const [query, setQuery] =
|
|
5594
|
+
const [query, setQuery] = React137__namespace.default.useState("");
|
|
5326
5595
|
const handleSearch = (v) => {
|
|
5327
5596
|
setQuery(v);
|
|
5328
5597
|
onSearch?.(v);
|
|
5329
5598
|
};
|
|
5330
|
-
const items =
|
|
5599
|
+
const items = React137__namespace.default.useRef(null);
|
|
5331
5600
|
const handleKeyDown = (e) => {
|
|
5332
5601
|
if (e.key === "Escape") {
|
|
5333
5602
|
onOpenChange(false);
|
|
@@ -5368,10 +5637,10 @@ function CommandBar({ open, onOpenChange, children, placeholder = "Search comman
|
|
|
5368
5637
|
var textOps = ["contains", "equals", "starts with"];
|
|
5369
5638
|
var numOps = ["=", ">", "<", ">=", "<="];
|
|
5370
5639
|
function AddFilterPopover({ filters, onAdd }) {
|
|
5371
|
-
const [open, setOpen] =
|
|
5372
|
-
const [key, setKey] =
|
|
5373
|
-
const [op, setOp] =
|
|
5374
|
-
const [val, setVal] =
|
|
5640
|
+
const [open, setOpen] = React137__namespace.default.useState(false);
|
|
5641
|
+
const [key, setKey] = React137__namespace.default.useState("");
|
|
5642
|
+
const [op, setOp] = React137__namespace.default.useState("");
|
|
5643
|
+
const [val, setVal] = React137__namespace.default.useState("");
|
|
5375
5644
|
const def = filters.find((f) => f.key === key);
|
|
5376
5645
|
const ops = def?.type === "number" ? numOps : textOps;
|
|
5377
5646
|
const handleAdd = () => {
|
|
@@ -5483,7 +5752,7 @@ function formatColumnSubLabel(date, scale) {
|
|
|
5483
5752
|
function snapDate(date, scale) {
|
|
5484
5753
|
return startOfScale(date, scale);
|
|
5485
5754
|
}
|
|
5486
|
-
var Gantt =
|
|
5755
|
+
var Gantt = React137__namespace.default.forwardRef(
|
|
5487
5756
|
({
|
|
5488
5757
|
items,
|
|
5489
5758
|
scale = "days",
|
|
@@ -5501,7 +5770,7 @@ var Gantt = React131__namespace.default.forwardRef(
|
|
|
5501
5770
|
}, ref) => {
|
|
5502
5771
|
const interactive = !!onItemMove || !!onItemResize;
|
|
5503
5772
|
const columnWidth = DEFAULT_COLUMN_WIDTH[scale];
|
|
5504
|
-
const viewport =
|
|
5773
|
+
const viewport = React137__namespace.default.useMemo(() => {
|
|
5505
5774
|
const earliest = startDate ?? (items.length ? new Date(Math.min(...items.map((i) => i.start.getTime()))) : /* @__PURE__ */ new Date());
|
|
5506
5775
|
const latest = endDate ?? (items.length ? new Date(Math.max(...items.map((i) => i.end.getTime()))) : dateFns.addDays(/* @__PURE__ */ new Date(), 14));
|
|
5507
5776
|
return {
|
|
@@ -5511,7 +5780,7 @@ var Gantt = React131__namespace.default.forwardRef(
|
|
|
5511
5780
|
}, [items, startDate, endDate, scale]);
|
|
5512
5781
|
const colCount = totalColumns(viewport.start, viewport.end, scale);
|
|
5513
5782
|
const timelineWidth = colCount * columnWidth;
|
|
5514
|
-
const grouped =
|
|
5783
|
+
const grouped = React137__namespace.default.useMemo(() => {
|
|
5515
5784
|
const map = /* @__PURE__ */ new Map();
|
|
5516
5785
|
for (const it of items) {
|
|
5517
5786
|
const k = it.group ?? void 0;
|
|
@@ -5521,7 +5790,7 @@ var Gantt = React131__namespace.default.forwardRef(
|
|
|
5521
5790
|
return Array.from(map.entries());
|
|
5522
5791
|
}, [items]);
|
|
5523
5792
|
const hasGroups = grouped.some(([k]) => k !== void 0);
|
|
5524
|
-
const [collapsed, setCollapsed] =
|
|
5793
|
+
const [collapsed, setCollapsed] = React137__namespace.default.useState(() => /* @__PURE__ */ new Set());
|
|
5525
5794
|
const toggleGroup = (key) => {
|
|
5526
5795
|
setCollapsed((prev) => {
|
|
5527
5796
|
const next = new Set(prev);
|
|
@@ -5530,7 +5799,7 @@ var Gantt = React131__namespace.default.forwardRef(
|
|
|
5530
5799
|
return next;
|
|
5531
5800
|
});
|
|
5532
5801
|
};
|
|
5533
|
-
const rows =
|
|
5802
|
+
const rows = React137__namespace.default.useMemo(() => {
|
|
5534
5803
|
const out = [];
|
|
5535
5804
|
for (const [groupKey, list] of grouped) {
|
|
5536
5805
|
if (groupKey !== void 0) {
|
|
@@ -5541,21 +5810,21 @@ var Gantt = React131__namespace.default.forwardRef(
|
|
|
5541
5810
|
}
|
|
5542
5811
|
return out;
|
|
5543
5812
|
}, [grouped, collapsed]);
|
|
5544
|
-
const itemRowIndex =
|
|
5813
|
+
const itemRowIndex = React137__namespace.default.useMemo(() => {
|
|
5545
5814
|
const m = /* @__PURE__ */ new Map();
|
|
5546
5815
|
rows.forEach((r, i) => {
|
|
5547
5816
|
if (r.kind === "item") m.set(r.item.id, i);
|
|
5548
5817
|
});
|
|
5549
5818
|
return m;
|
|
5550
5819
|
}, [rows]);
|
|
5551
|
-
const todayOffsetPx =
|
|
5820
|
+
const todayOffsetPx = React137__namespace.default.useMemo(() => {
|
|
5552
5821
|
if (!showToday) return null;
|
|
5553
5822
|
const now = /* @__PURE__ */ new Date();
|
|
5554
5823
|
const u = unitsBetween(viewport.start, now, scale);
|
|
5555
5824
|
if (u < 0 || u > colCount) return null;
|
|
5556
5825
|
return u * columnWidth;
|
|
5557
5826
|
}, [showToday, viewport.start, scale, colCount, columnWidth]);
|
|
5558
|
-
const columnDates =
|
|
5827
|
+
const columnDates = React137__namespace.default.useMemo(() => {
|
|
5559
5828
|
return Array.from(
|
|
5560
5829
|
{ length: colCount },
|
|
5561
5830
|
(_, i) => addUnits(viewport.start, i, scale)
|
|
@@ -5779,12 +6048,12 @@ function GanttBar({
|
|
|
5779
6048
|
}) {
|
|
5780
6049
|
const color = item.color ?? DEFAULT_COLOR2;
|
|
5781
6050
|
const progress = Math.max(0, Math.min(100, item.progress ?? 0));
|
|
5782
|
-
const [previewLeftDelta, setPreviewLeftDelta] =
|
|
5783
|
-
const [previewRightDelta, setPreviewRightDelta] =
|
|
5784
|
-
const dragMode =
|
|
5785
|
-
const startX =
|
|
5786
|
-
const longPressTimer =
|
|
5787
|
-
const moved =
|
|
6051
|
+
const [previewLeftDelta, setPreviewLeftDelta] = React137__namespace.default.useState(0);
|
|
6052
|
+
const [previewRightDelta, setPreviewRightDelta] = React137__namespace.default.useState(0);
|
|
6053
|
+
const dragMode = React137__namespace.default.useRef(null);
|
|
6054
|
+
const startX = React137__namespace.default.useRef(0);
|
|
6055
|
+
const longPressTimer = React137__namespace.default.useRef(null);
|
|
6056
|
+
const moved = React137__namespace.default.useRef(false);
|
|
5788
6057
|
const baseLeft = unitsBetween(viewportStart, item.start, scale) * columnWidth;
|
|
5789
6058
|
const baseRight = unitsBetween(viewportStart, item.end, scale) * columnWidth;
|
|
5790
6059
|
const baseWidth = Math.max(columnWidth * 0.25, baseRight - baseLeft);
|
|
@@ -5990,7 +6259,7 @@ function DependencyLayer({
|
|
|
5990
6259
|
timelineWidth,
|
|
5991
6260
|
totalHeight
|
|
5992
6261
|
}) {
|
|
5993
|
-
const itemById =
|
|
6262
|
+
const itemById = React137__namespace.default.useMemo(() => {
|
|
5994
6263
|
const m = /* @__PURE__ */ new Map();
|
|
5995
6264
|
for (const it of items) m.set(it.id, it);
|
|
5996
6265
|
return m;
|
|
@@ -6089,9 +6358,9 @@ function KanbanColumn({ column, isOver }) {
|
|
|
6089
6358
|
] });
|
|
6090
6359
|
}
|
|
6091
6360
|
function Kanban({ columns: initialColumns, onMoveCard, className }) {
|
|
6092
|
-
const [cols, setCols] =
|
|
6093
|
-
const [activeCard, setActiveCard] =
|
|
6094
|
-
const [overColId, setOverColId] =
|
|
6361
|
+
const [cols, setCols] = React137__namespace.default.useState(initialColumns);
|
|
6362
|
+
const [activeCard, setActiveCard] = React137__namespace.default.useState(null);
|
|
6363
|
+
const [overColId, setOverColId] = React137__namespace.default.useState(null);
|
|
6095
6364
|
const sensors = core.useSensors(core.useSensor(core.PointerSensor, { activationConstraint: { distance: 5 } }));
|
|
6096
6365
|
const findColByCard = (cardId) => cols.find((c) => c.cards.some((card) => card.id === cardId));
|
|
6097
6366
|
const onDragStart = ({ active }) => {
|
|
@@ -6160,10 +6429,10 @@ function ToolbarButton({
|
|
|
6160
6429
|
] });
|
|
6161
6430
|
}
|
|
6162
6431
|
function LinkPopover({ editor }) {
|
|
6163
|
-
const [open, setOpen] =
|
|
6164
|
-
const [url, setUrl] =
|
|
6432
|
+
const [open, setOpen] = React137__namespace.default.useState(false);
|
|
6433
|
+
const [url, setUrl] = React137__namespace.default.useState("");
|
|
6165
6434
|
const isActive = editor.isActive("link");
|
|
6166
|
-
|
|
6435
|
+
React137__namespace.default.useEffect(() => {
|
|
6167
6436
|
if (!open) return;
|
|
6168
6437
|
const current = editor.getAttributes("link")?.href;
|
|
6169
6438
|
setUrl(current ?? "");
|
|
@@ -6628,7 +6897,7 @@ var proseClasses = cn(
|
|
|
6628
6897
|
// Selected cells in tables
|
|
6629
6898
|
"[&_.selectedCell]:bg-[hsl(var(--accent))]/40"
|
|
6630
6899
|
);
|
|
6631
|
-
var RichEditor =
|
|
6900
|
+
var RichEditor = React137__namespace.default.forwardRef(
|
|
6632
6901
|
function RichEditor2({
|
|
6633
6902
|
value,
|
|
6634
6903
|
defaultValue,
|
|
@@ -6642,12 +6911,12 @@ var RichEditor = React131__namespace.default.forwardRef(
|
|
|
6642
6911
|
}, ref) {
|
|
6643
6912
|
const isControlled = value !== void 0;
|
|
6644
6913
|
const initialContent = isControlled ? value ?? "" : defaultValue ?? "";
|
|
6645
|
-
const debounceRef =
|
|
6646
|
-
const onChangeRef =
|
|
6647
|
-
|
|
6914
|
+
const debounceRef = React137__namespace.default.useRef(null);
|
|
6915
|
+
const onChangeRef = React137__namespace.default.useRef(onChange);
|
|
6916
|
+
React137__namespace.default.useEffect(() => {
|
|
6648
6917
|
onChangeRef.current = onChange;
|
|
6649
6918
|
}, [onChange]);
|
|
6650
|
-
const [charCount, setCharCount] =
|
|
6919
|
+
const [charCount, setCharCount] = React137__namespace.default.useState(0);
|
|
6651
6920
|
const editor = react$1.useEditor({
|
|
6652
6921
|
editable,
|
|
6653
6922
|
content: initialContent,
|
|
@@ -6690,18 +6959,18 @@ var RichEditor = React131__namespace.default.forwardRef(
|
|
|
6690
6959
|
}, 100);
|
|
6691
6960
|
}
|
|
6692
6961
|
});
|
|
6693
|
-
|
|
6962
|
+
React137__namespace.default.useEffect(() => {
|
|
6694
6963
|
if (!editor || !isControlled) return;
|
|
6695
6964
|
const current = editor.getHTML();
|
|
6696
6965
|
if ((value ?? "") !== current) {
|
|
6697
6966
|
editor.commands.setContent(value ?? "", { emitUpdate: false });
|
|
6698
6967
|
}
|
|
6699
6968
|
}, [editor, isControlled, value]);
|
|
6700
|
-
|
|
6969
|
+
React137__namespace.default.useEffect(() => {
|
|
6701
6970
|
if (!editor) return;
|
|
6702
6971
|
if (editor.isEditable !== editable) editor.setEditable(editable);
|
|
6703
6972
|
}, [editor, editable]);
|
|
6704
|
-
|
|
6973
|
+
React137__namespace.default.useEffect(() => {
|
|
6705
6974
|
return () => {
|
|
6706
6975
|
if (debounceRef.current) clearTimeout(debounceRef.current);
|
|
6707
6976
|
};
|
|
@@ -6799,10 +7068,10 @@ function ToggleButtonGroup(props) {
|
|
|
6799
7068
|
props.onChange(val);
|
|
6800
7069
|
}
|
|
6801
7070
|
};
|
|
6802
|
-
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn("inline-flex items-center gap-1 rounded-md border border-[hsl(var(--border))] bg-[hsl(var(--muted)/0.4)] p-0.5", className), children:
|
|
6803
|
-
if (!
|
|
7071
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn("inline-flex items-center gap-1 rounded-md border border-[hsl(var(--border))] bg-[hsl(var(--muted)/0.4)] p-0.5", className), children: React137__namespace.default.Children.map(children, (child) => {
|
|
7072
|
+
if (!React137__namespace.default.isValidElement(child)) return child;
|
|
6804
7073
|
const tb = child;
|
|
6805
|
-
return
|
|
7074
|
+
return React137__namespace.default.cloneElement(tb, {
|
|
6806
7075
|
pressed: isPressed(tb.props.value),
|
|
6807
7076
|
onClick: () => handleClick(tb.props.value)
|
|
6808
7077
|
});
|
|
@@ -7086,24 +7355,24 @@ function Beacon({ color = "primary", size = "md", children, className }) {
|
|
|
7086
7355
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "absolute -top-1 -right-1 flex", children: /* @__PURE__ */ jsxRuntime.jsx(BeaconDot, { color, size }) })
|
|
7087
7356
|
] });
|
|
7088
7357
|
}
|
|
7089
|
-
var TourContext =
|
|
7358
|
+
var TourContext = React137.createContext(null);
|
|
7090
7359
|
function useTour() {
|
|
7091
|
-
const ctx =
|
|
7360
|
+
const ctx = React137.useContext(TourContext);
|
|
7092
7361
|
if (!ctx) throw new Error("useTour must be used within <Tour>");
|
|
7093
7362
|
return ctx;
|
|
7094
7363
|
}
|
|
7095
7364
|
function Tour({ totalSteps, children }) {
|
|
7096
|
-
const [currentStep, setCurrentStep] =
|
|
7097
|
-
const [isActive, setIsActive] =
|
|
7098
|
-
const stop =
|
|
7099
|
-
const start =
|
|
7365
|
+
const [currentStep, setCurrentStep] = React137.useState(0);
|
|
7366
|
+
const [isActive, setIsActive] = React137.useState(false);
|
|
7367
|
+
const stop = React137.useCallback(() => setIsActive(false), []);
|
|
7368
|
+
const start = React137.useCallback(() => {
|
|
7100
7369
|
setCurrentStep(0);
|
|
7101
7370
|
setIsActive(true);
|
|
7102
7371
|
}, []);
|
|
7103
|
-
const next =
|
|
7104
|
-
const prev =
|
|
7105
|
-
const goTo =
|
|
7106
|
-
|
|
7372
|
+
const next = React137.useCallback(() => setCurrentStep((s) => Math.min(s + 1, totalSteps - 1)), [totalSteps]);
|
|
7373
|
+
const prev = React137.useCallback(() => setCurrentStep((s) => Math.max(s - 1, 0)), []);
|
|
7374
|
+
const goTo = React137.useCallback((step) => setCurrentStep(Math.max(0, Math.min(step, totalSteps - 1))), [totalSteps]);
|
|
7375
|
+
React137.useEffect(() => {
|
|
7107
7376
|
if (!isActive) return;
|
|
7108
7377
|
const onKey = (e) => {
|
|
7109
7378
|
if (e.key === "Escape") stop();
|
|
@@ -7151,13 +7420,13 @@ function TourStep({ step, title, description, placement = "bottom", children })
|
|
|
7151
7420
|
] })
|
|
7152
7421
|
] });
|
|
7153
7422
|
}
|
|
7154
|
-
var ChecklistContext =
|
|
7423
|
+
var ChecklistContext = React137.createContext(null);
|
|
7155
7424
|
function useChecklist() {
|
|
7156
|
-
const ctx =
|
|
7425
|
+
const ctx = React137.useContext(ChecklistContext);
|
|
7157
7426
|
if (!ctx) throw new Error("<ChecklistItem> must be used inside <Checklist>");
|
|
7158
7427
|
return ctx;
|
|
7159
7428
|
}
|
|
7160
|
-
var Checklist =
|
|
7429
|
+
var Checklist = React137__namespace.default.forwardRef(
|
|
7161
7430
|
({
|
|
7162
7431
|
title = "Getting started",
|
|
7163
7432
|
description,
|
|
@@ -7171,32 +7440,32 @@ var Checklist = React131__namespace.default.forwardRef(
|
|
|
7171
7440
|
children,
|
|
7172
7441
|
...props
|
|
7173
7442
|
}, ref) => {
|
|
7174
|
-
const [internalCompleted, setInternalCompleted] =
|
|
7175
|
-
const [open, setOpen] =
|
|
7176
|
-
const completedFiredRef =
|
|
7443
|
+
const [internalCompleted, setInternalCompleted] = React137.useState({});
|
|
7444
|
+
const [open, setOpen] = React137.useState(defaultOpen);
|
|
7445
|
+
const completedFiredRef = React137__namespace.default.useRef(false);
|
|
7177
7446
|
const isControlled = controlledCompleted !== void 0;
|
|
7178
7447
|
const completed = isControlled ? controlledCompleted : internalCompleted;
|
|
7179
|
-
const setCompleted =
|
|
7448
|
+
const setCompleted = React137.useCallback(
|
|
7180
7449
|
(id, value) => {
|
|
7181
7450
|
if (!isControlled) setInternalCompleted((prev) => ({ ...prev, [id]: value }));
|
|
7182
7451
|
onItemChange?.(id, value);
|
|
7183
7452
|
},
|
|
7184
7453
|
[isControlled, onItemChange]
|
|
7185
7454
|
);
|
|
7186
|
-
const total =
|
|
7455
|
+
const total = React137.useMemo(() => {
|
|
7187
7456
|
let n = 0;
|
|
7188
|
-
|
|
7189
|
-
if (
|
|
7457
|
+
React137__namespace.default.Children.forEach(children, (child) => {
|
|
7458
|
+
if (React137__namespace.default.isValidElement(child) && child.type.displayName === "ChecklistItem") {
|
|
7190
7459
|
n++;
|
|
7191
7460
|
}
|
|
7192
7461
|
});
|
|
7193
7462
|
return n;
|
|
7194
7463
|
}, [children]);
|
|
7195
|
-
const doneCount =
|
|
7464
|
+
const doneCount = React137.useMemo(
|
|
7196
7465
|
() => Object.values(completed).filter(Boolean).length,
|
|
7197
7466
|
[completed]
|
|
7198
7467
|
);
|
|
7199
|
-
|
|
7468
|
+
React137__namespace.default.useEffect(() => {
|
|
7200
7469
|
if (!completedFiredRef.current && total > 0 && doneCount >= total) {
|
|
7201
7470
|
completedFiredRef.current = true;
|
|
7202
7471
|
onComplete?.();
|
|
@@ -7257,11 +7526,11 @@ var Checklist = React131__namespace.default.forwardRef(
|
|
|
7257
7526
|
}
|
|
7258
7527
|
);
|
|
7259
7528
|
Checklist.displayName = "Checklist";
|
|
7260
|
-
var ChecklistItem =
|
|
7529
|
+
var ChecklistItem = React137__namespace.default.forwardRef(
|
|
7261
7530
|
({ id, title, description, action, onActivate, className, ...props }, ref) => {
|
|
7262
7531
|
const { completed, setCompleted } = useChecklist();
|
|
7263
7532
|
const done = !!completed[id];
|
|
7264
|
-
const toggle =
|
|
7533
|
+
const toggle = React137.useCallback(() => {
|
|
7265
7534
|
setCompleted(id, !done);
|
|
7266
7535
|
}, [id, done, setCompleted]);
|
|
7267
7536
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
@@ -7340,9 +7609,9 @@ function IntroDisclosure({
|
|
|
7340
7609
|
finishLabel = "Get started"
|
|
7341
7610
|
}) {
|
|
7342
7611
|
const isControlled = controlledOpen !== void 0;
|
|
7343
|
-
const [internalOpen, setInternalOpen] =
|
|
7344
|
-
const [step, setStep] =
|
|
7345
|
-
|
|
7612
|
+
const [internalOpen, setInternalOpen] = React137.useState(false);
|
|
7613
|
+
const [step, setStep] = React137.useState(0);
|
|
7614
|
+
React137.useEffect(() => {
|
|
7346
7615
|
if (isControlled) return;
|
|
7347
7616
|
if (typeof window === "undefined") return;
|
|
7348
7617
|
if (!storageKey) {
|
|
@@ -7355,19 +7624,19 @@ function IntroDisclosure({
|
|
|
7355
7624
|
const isOpen = isControlled ? controlledOpen : internalOpen;
|
|
7356
7625
|
const total = steps.length;
|
|
7357
7626
|
const isLast = step === total - 1;
|
|
7358
|
-
const close =
|
|
7627
|
+
const close = React137.useCallback(() => {
|
|
7359
7628
|
if (!isControlled) {
|
|
7360
7629
|
setInternalOpen(false);
|
|
7361
7630
|
if (storageKey && typeof window !== "undefined") window.localStorage.setItem(storageKey, "1");
|
|
7362
7631
|
}
|
|
7363
7632
|
onOpenChange?.(false);
|
|
7364
7633
|
}, [isControlled, onOpenChange, storageKey]);
|
|
7365
|
-
const next =
|
|
7634
|
+
const next = React137.useCallback(() => {
|
|
7366
7635
|
if (isLast) close();
|
|
7367
7636
|
else setStep((s) => s + 1);
|
|
7368
7637
|
}, [isLast, close]);
|
|
7369
|
-
const prev =
|
|
7370
|
-
|
|
7638
|
+
const prev = React137.useCallback(() => setStep((s) => Math.max(0, s - 1)), []);
|
|
7639
|
+
React137.useEffect(() => {
|
|
7371
7640
|
if (!isOpen) return;
|
|
7372
7641
|
const onKey = (e) => {
|
|
7373
7642
|
if (e.key === "Escape") close();
|
|
@@ -7377,7 +7646,7 @@ function IntroDisclosure({
|
|
|
7377
7646
|
window.addEventListener("keydown", onKey);
|
|
7378
7647
|
return () => window.removeEventListener("keydown", onKey);
|
|
7379
7648
|
}, [isOpen, close, next, prev]);
|
|
7380
|
-
const current =
|
|
7649
|
+
const current = React137.useMemo(() => steps[Math.min(step, total - 1)], [steps, step, total]);
|
|
7381
7650
|
if (!isOpen || total === 0 || !current) return null;
|
|
7382
7651
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
7383
7652
|
"div",
|
|
@@ -7557,9 +7826,9 @@ function CalendarGrid({ year, month, selected, onSelect }) {
|
|
|
7557
7826
|
] });
|
|
7558
7827
|
}
|
|
7559
7828
|
function DatePicker({ value, onChange, placeholder = "Pick a date", disabled, className }) {
|
|
7560
|
-
const [open, setOpen] =
|
|
7829
|
+
const [open, setOpen] = React137.useState(false);
|
|
7561
7830
|
const now = value ?? /* @__PURE__ */ new Date();
|
|
7562
|
-
const [view, setView] =
|
|
7831
|
+
const [view, setView] = React137.useState({ year: now.getFullYear(), month: now.getMonth() });
|
|
7563
7832
|
function navigate(delta) {
|
|
7564
7833
|
setView((v) => {
|
|
7565
7834
|
const date = new Date(v.year, v.month + delta);
|
|
@@ -7605,7 +7874,7 @@ function Field({ label, description, error, required, children, className }) {
|
|
|
7605
7874
|
error && /* @__PURE__ */ jsxRuntime.jsx(FieldError, { children: error })
|
|
7606
7875
|
] });
|
|
7607
7876
|
}
|
|
7608
|
-
var FieldLabel =
|
|
7877
|
+
var FieldLabel = React137__namespace.default.forwardRef(
|
|
7609
7878
|
({ className, required, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
7610
7879
|
"label",
|
|
7611
7880
|
{
|
|
@@ -7620,7 +7889,7 @@ var FieldLabel = React131__namespace.default.forwardRef(
|
|
|
7620
7889
|
)
|
|
7621
7890
|
);
|
|
7622
7891
|
FieldLabel.displayName = "FieldLabel";
|
|
7623
|
-
var FieldDescription =
|
|
7892
|
+
var FieldDescription = React137__namespace.default.forwardRef(
|
|
7624
7893
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
7625
7894
|
"p",
|
|
7626
7895
|
{
|
|
@@ -7631,7 +7900,7 @@ var FieldDescription = React131__namespace.default.forwardRef(
|
|
|
7631
7900
|
)
|
|
7632
7901
|
);
|
|
7633
7902
|
FieldDescription.displayName = "FieldDescription";
|
|
7634
|
-
var FieldError =
|
|
7903
|
+
var FieldError = React137__namespace.default.forwardRef(
|
|
7635
7904
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
7636
7905
|
"p",
|
|
7637
7906
|
{
|
|
@@ -7732,7 +8001,7 @@ function defaultFor(format3, showAlpha) {
|
|
|
7732
8001
|
if (format3 === "rgb") return showAlpha ? "rgba(59, 130, 246, 1)" : "rgb(59, 130, 246)";
|
|
7733
8002
|
return showAlpha ? "hsla(217, 91%, 60%, 1)" : "hsl(217, 91%, 60%)";
|
|
7734
8003
|
}
|
|
7735
|
-
var ColorPicker =
|
|
8004
|
+
var ColorPicker = React137__namespace.default.forwardRef(
|
|
7736
8005
|
({
|
|
7737
8006
|
value: valueProp,
|
|
7738
8007
|
defaultValue,
|
|
@@ -7747,21 +8016,21 @@ var ColorPicker = React131__namespace.default.forwardRef(
|
|
|
7747
8016
|
}, ref) => {
|
|
7748
8017
|
const fallback = defaultValue ?? defaultFor(format3, showAlpha);
|
|
7749
8018
|
const isControlled = valueProp !== void 0;
|
|
7750
|
-
const [internal, setInternal] =
|
|
8019
|
+
const [internal, setInternal] = React137__namespace.default.useState(fallback);
|
|
7751
8020
|
const value = isControlled ? valueProp : internal;
|
|
7752
|
-
const [draft, setDraft] =
|
|
7753
|
-
const [draftValid, setDraftValid] =
|
|
7754
|
-
|
|
8021
|
+
const [draft, setDraft] = React137__namespace.default.useState(value);
|
|
8022
|
+
const [draftValid, setDraftValid] = React137__namespace.default.useState(true);
|
|
8023
|
+
React137__namespace.default.useEffect(() => {
|
|
7755
8024
|
setDraft(value);
|
|
7756
8025
|
setDraftValid(true);
|
|
7757
8026
|
}, [value]);
|
|
7758
|
-
const [eyeDropperSupported, setEyeDropperSupported] =
|
|
7759
|
-
|
|
8027
|
+
const [eyeDropperSupported, setEyeDropperSupported] = React137__namespace.default.useState(false);
|
|
8028
|
+
React137__namespace.default.useEffect(() => {
|
|
7760
8029
|
if (typeof window !== "undefined" && "EyeDropper" in window) {
|
|
7761
8030
|
setEyeDropperSupported(true);
|
|
7762
8031
|
}
|
|
7763
8032
|
}, []);
|
|
7764
|
-
const commit =
|
|
8033
|
+
const commit = React137__namespace.default.useCallback(
|
|
7765
8034
|
(next) => {
|
|
7766
8035
|
if (!isControlled) setInternal(next);
|
|
7767
8036
|
onValueChange?.(next);
|
|
@@ -7924,8 +8193,8 @@ function filterBySize(files, maxSize) {
|
|
|
7924
8193
|
return maxSize ? files.filter((f) => f.size <= maxSize) : files;
|
|
7925
8194
|
}
|
|
7926
8195
|
function FileUpload({ accept, multiple, maxSize, onFiles, className, disabled }) {
|
|
7927
|
-
const inputRef =
|
|
7928
|
-
const [dragging, setDragging] =
|
|
8196
|
+
const inputRef = React137.useRef(null);
|
|
8197
|
+
const [dragging, setDragging] = React137.useState(false);
|
|
7929
8198
|
function handleFiles(raw) {
|
|
7930
8199
|
if (!raw) return;
|
|
7931
8200
|
const files = filterBySize(Array.from(raw), maxSize);
|
|
@@ -7998,15 +8267,15 @@ function FileUploadPreview({ files, onRemove, className }) {
|
|
|
7998
8267
|
] })
|
|
7999
8268
|
] }, i)) });
|
|
8000
8269
|
}
|
|
8001
|
-
var FloatingLabelInput =
|
|
8270
|
+
var FloatingLabelInput = React137__namespace.default.forwardRef(
|
|
8002
8271
|
({ label, error, hint, wrapperClassName, className, id, value, defaultValue, onFocus, onBlur, onChange, ...props }, ref) => {
|
|
8003
|
-
const autoId =
|
|
8272
|
+
const autoId = React137.useId();
|
|
8004
8273
|
const inputId = id ?? autoId;
|
|
8005
8274
|
const errorId = error ? `${inputId}-error` : void 0;
|
|
8006
8275
|
const hintId = hint ? `${inputId}-hint` : void 0;
|
|
8007
8276
|
const describedBy = [errorId, hintId].filter(Boolean).join(" ") || void 0;
|
|
8008
|
-
const [focused, setFocused] =
|
|
8009
|
-
const [filled, setFilled] =
|
|
8277
|
+
const [focused, setFocused] = React137.useState(false);
|
|
8278
|
+
const [filled, setFilled] = React137.useState(() => {
|
|
8010
8279
|
if (value !== void 0 && value !== null && value !== "") return true;
|
|
8011
8280
|
if (defaultValue !== void 0 && defaultValue !== null && defaultValue !== "") return true;
|
|
8012
8281
|
return false;
|
|
@@ -8082,7 +8351,7 @@ function FormField(props) {
|
|
|
8082
8351
|
function FormItem({ className, ...props }) {
|
|
8083
8352
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn("flex flex-col gap-1.5", className), ...props });
|
|
8084
8353
|
}
|
|
8085
|
-
var FormLabel =
|
|
8354
|
+
var FormLabel = React137__namespace.default.forwardRef(
|
|
8086
8355
|
({ className, error, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
8087
8356
|
"label",
|
|
8088
8357
|
{
|
|
@@ -8097,9 +8366,9 @@ var FormLabel = React131__namespace.default.forwardRef(
|
|
|
8097
8366
|
)
|
|
8098
8367
|
);
|
|
8099
8368
|
FormLabel.displayName = "FormLabel";
|
|
8100
|
-
var FormControl =
|
|
8369
|
+
var FormControl = React137__namespace.default.forwardRef(
|
|
8101
8370
|
({ ...props }, ref) => {
|
|
8102
|
-
const id =
|
|
8371
|
+
const id = React137.useId();
|
|
8103
8372
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { ref, id, ...props });
|
|
8104
8373
|
}
|
|
8105
8374
|
);
|
|
@@ -8122,7 +8391,7 @@ function ObjectField({
|
|
|
8122
8391
|
children,
|
|
8123
8392
|
className
|
|
8124
8393
|
}) {
|
|
8125
|
-
const [open, setOpen] =
|
|
8394
|
+
const [open, setOpen] = React137.useState(defaultOpen);
|
|
8126
8395
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: cn("rounded-md border border-[hsl(var(--border))] overflow-hidden", className), children: [
|
|
8127
8396
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
8128
8397
|
"div",
|
|
@@ -8154,9 +8423,9 @@ function getStrength(value) {
|
|
|
8154
8423
|
if (score <= 3) return { level: "medium", width: "w-2/3", color: "bg-yellow-500" };
|
|
8155
8424
|
return { level: "strong", width: "w-full", color: "bg-green-500" };
|
|
8156
8425
|
}
|
|
8157
|
-
var PasswordInput =
|
|
8426
|
+
var PasswordInput = React137__namespace.default.forwardRef(
|
|
8158
8427
|
({ className, strength, ...props }, ref) => {
|
|
8159
|
-
const [show, setShow] =
|
|
8428
|
+
const [show, setShow] = React137.useState(false);
|
|
8160
8429
|
const value = String(props.value ?? "");
|
|
8161
8430
|
const str = getStrength(value);
|
|
8162
8431
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col gap-1.5", children: [
|
|
@@ -8189,9 +8458,9 @@ var PasswordInput = React131__namespace.default.forwardRef(
|
|
|
8189
8458
|
}
|
|
8190
8459
|
);
|
|
8191
8460
|
PasswordInput.displayName = "PasswordInput";
|
|
8192
|
-
var SearchInput =
|
|
8461
|
+
var SearchInput = React137__namespace.default.forwardRef(
|
|
8193
8462
|
({ className, shortcut, onClear, onChange, value: valueProp, defaultValue, ...props }, ref) => {
|
|
8194
|
-
const [internalValue, setInternalValue] =
|
|
8463
|
+
const [internalValue, setInternalValue] = React137.useState(defaultValue ?? "");
|
|
8195
8464
|
const isControlled = valueProp !== void 0;
|
|
8196
8465
|
const value = isControlled ? String(valueProp) : String(internalValue);
|
|
8197
8466
|
function handleChange(e) {
|
|
@@ -8234,14 +8503,14 @@ var SearchInput = React131__namespace.default.forwardRef(
|
|
|
8234
8503
|
}
|
|
8235
8504
|
);
|
|
8236
8505
|
SearchInput.displayName = "SearchInput";
|
|
8237
|
-
var StepFormContext =
|
|
8506
|
+
var StepFormContext = React137.createContext(null);
|
|
8238
8507
|
function useStepForm() {
|
|
8239
|
-
const ctx =
|
|
8508
|
+
const ctx = React137.useContext(StepFormContext);
|
|
8240
8509
|
if (!ctx) throw new Error("useStepForm must be used within StepForm");
|
|
8241
8510
|
return ctx;
|
|
8242
8511
|
}
|
|
8243
8512
|
function StepForm({ steps, onSubmit, children, className }) {
|
|
8244
|
-
const [currentStep, setCurrentStep] =
|
|
8513
|
+
const [currentStep, setCurrentStep] = React137.useState(0);
|
|
8245
8514
|
const totalSteps = steps.length;
|
|
8246
8515
|
const ctx = {
|
|
8247
8516
|
currentStep,
|
|
@@ -8252,7 +8521,7 @@ function StepForm({ steps, onSubmit, children, className }) {
|
|
|
8252
8521
|
isFirst: currentStep === 0,
|
|
8253
8522
|
isLast: currentStep === totalSteps - 1
|
|
8254
8523
|
};
|
|
8255
|
-
const childArray =
|
|
8524
|
+
const childArray = React137__namespace.default.Children.toArray(children);
|
|
8256
8525
|
const currentChild = childArray[currentStep];
|
|
8257
8526
|
return /* @__PURE__ */ jsxRuntime.jsx(StepFormContext.Provider, { value: ctx, children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: cn("flex flex-col gap-6", className), children: [
|
|
8258
8527
|
/* @__PURE__ */ jsxRuntime.jsx(StepIndicator, { steps, currentStep }),
|
|
@@ -8261,7 +8530,7 @@ function StepForm({ steps, onSubmit, children, className }) {
|
|
|
8261
8530
|
] }) });
|
|
8262
8531
|
}
|
|
8263
8532
|
function StepIndicator({ steps, currentStep }) {
|
|
8264
|
-
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center gap-2", children: steps.map((label, i) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
8533
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center gap-2", children: steps.map((label, i) => /* @__PURE__ */ jsxRuntime.jsxs(React137__namespace.default.Fragment, { children: [
|
|
8265
8534
|
i > 0 && /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn("h-px flex-1 bg-[hsl(var(--border))]", i <= currentStep && "bg-[hsl(var(--primary))]") }),
|
|
8266
8535
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-1", children: [
|
|
8267
8536
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: cn(
|
|
@@ -8290,7 +8559,7 @@ function StepFormNavigation({ onSubmit, submitLabel = "Submit" }) {
|
|
|
8290
8559
|
isLast ? /* @__PURE__ */ jsxRuntime.jsx(Button, { type: "button", onClick: onSubmit, children: submitLabel }) : /* @__PURE__ */ jsxRuntime.jsx(Button, { type: "button", onClick: next, children: "Next" })
|
|
8291
8560
|
] });
|
|
8292
8561
|
}
|
|
8293
|
-
var Tags =
|
|
8562
|
+
var Tags = React137__namespace.default.forwardRef(
|
|
8294
8563
|
({
|
|
8295
8564
|
value: valueProp,
|
|
8296
8565
|
defaultValue,
|
|
@@ -8306,25 +8575,25 @@ var Tags = React131__namespace.default.forwardRef(
|
|
|
8306
8575
|
...props
|
|
8307
8576
|
}, ref) => {
|
|
8308
8577
|
const isControlled = valueProp !== void 0;
|
|
8309
|
-
const [internal, setInternal] =
|
|
8578
|
+
const [internal, setInternal] = React137__namespace.default.useState(defaultValue ?? []);
|
|
8310
8579
|
const tags = isControlled ? valueProp : internal;
|
|
8311
|
-
const [input, setInput] =
|
|
8312
|
-
const [error, setError] =
|
|
8313
|
-
const [focused, setFocused] =
|
|
8314
|
-
const [activeIndex, setActiveIndex] =
|
|
8315
|
-
const inputRef =
|
|
8316
|
-
const containerRef =
|
|
8317
|
-
|
|
8580
|
+
const [input, setInput] = React137__namespace.default.useState("");
|
|
8581
|
+
const [error, setError] = React137__namespace.default.useState(null);
|
|
8582
|
+
const [focused, setFocused] = React137__namespace.default.useState(false);
|
|
8583
|
+
const [activeIndex, setActiveIndex] = React137__namespace.default.useState(0);
|
|
8584
|
+
const inputRef = React137__namespace.default.useRef(null);
|
|
8585
|
+
const containerRef = React137__namespace.default.useRef(null);
|
|
8586
|
+
React137__namespace.default.useImperativeHandle(ref, () => containerRef.current);
|
|
8318
8587
|
const atMax = maxTags !== void 0 && tags.length >= maxTags;
|
|
8319
8588
|
const inputDisabled = disabled || atMax;
|
|
8320
|
-
const commit =
|
|
8589
|
+
const commit = React137__namespace.default.useCallback(
|
|
8321
8590
|
(next) => {
|
|
8322
8591
|
if (!isControlled) setInternal(next);
|
|
8323
8592
|
onValueChange?.(next);
|
|
8324
8593
|
},
|
|
8325
8594
|
[isControlled, onValueChange]
|
|
8326
8595
|
);
|
|
8327
|
-
const addTag =
|
|
8596
|
+
const addTag = React137__namespace.default.useCallback(
|
|
8328
8597
|
(raw) => {
|
|
8329
8598
|
const tag = raw.trim();
|
|
8330
8599
|
if (!tag) return false;
|
|
@@ -8350,20 +8619,20 @@ var Tags = React131__namespace.default.forwardRef(
|
|
|
8350
8619
|
},
|
|
8351
8620
|
[tags, allowDuplicates, validate, atMax, commit]
|
|
8352
8621
|
);
|
|
8353
|
-
const removeTag =
|
|
8622
|
+
const removeTag = React137__namespace.default.useCallback(
|
|
8354
8623
|
(index) => {
|
|
8355
8624
|
commit(tags.filter((_, i) => i !== index));
|
|
8356
8625
|
setError(null);
|
|
8357
8626
|
},
|
|
8358
8627
|
[tags, commit]
|
|
8359
8628
|
);
|
|
8360
|
-
const filteredSuggestions =
|
|
8629
|
+
const filteredSuggestions = React137__namespace.default.useMemo(() => {
|
|
8361
8630
|
if (!suggestions || !input.trim()) return [];
|
|
8362
8631
|
const q = input.trim().toLowerCase();
|
|
8363
8632
|
return suggestions.filter((s) => s.toLowerCase().includes(q)).filter((s) => allowDuplicates || !tags.includes(s)).slice(0, 8);
|
|
8364
8633
|
}, [suggestions, input, tags, allowDuplicates]);
|
|
8365
8634
|
const showPopover = focused && !inputDisabled && filteredSuggestions.length > 0;
|
|
8366
|
-
|
|
8635
|
+
React137__namespace.default.useEffect(() => {
|
|
8367
8636
|
if (activeIndex >= filteredSuggestions.length) setActiveIndex(0);
|
|
8368
8637
|
}, [filteredSuggestions.length, activeIndex]);
|
|
8369
8638
|
const handleKeyDown = (e) => {
|
|
@@ -8505,7 +8774,7 @@ var Tags = React131__namespace.default.forwardRef(
|
|
|
8505
8774
|
}
|
|
8506
8775
|
);
|
|
8507
8776
|
Tags.displayName = "Tags";
|
|
8508
|
-
var AppShellCtx =
|
|
8777
|
+
var AppShellCtx = React137__namespace.default.createContext({
|
|
8509
8778
|
collapsed: false,
|
|
8510
8779
|
setCollapsed: () => {
|
|
8511
8780
|
},
|
|
@@ -8513,12 +8782,12 @@ var AppShellCtx = React131__namespace.default.createContext({
|
|
|
8513
8782
|
setMobileOpen: () => {
|
|
8514
8783
|
}
|
|
8515
8784
|
});
|
|
8516
|
-
var useAppShell = () =>
|
|
8517
|
-
var AppShell =
|
|
8785
|
+
var useAppShell = () => React137__namespace.default.useContext(AppShellCtx);
|
|
8786
|
+
var AppShell = React137__namespace.default.forwardRef(
|
|
8518
8787
|
({ className, defaultCollapsed = false, children, ...props }, ref) => {
|
|
8519
|
-
const [collapsed, setCollapsed] =
|
|
8520
|
-
const [mobileOpen, setMobileOpen] =
|
|
8521
|
-
|
|
8788
|
+
const [collapsed, setCollapsed] = React137__namespace.default.useState(defaultCollapsed);
|
|
8789
|
+
const [mobileOpen, setMobileOpen] = React137__namespace.default.useState(false);
|
|
8790
|
+
React137__namespace.default.useEffect(() => {
|
|
8522
8791
|
const handleClick = (e) => {
|
|
8523
8792
|
const target = e.target;
|
|
8524
8793
|
if (target.closest("a[href]") || target.closest("[data-mobile-close]")) {
|
|
@@ -8549,7 +8818,7 @@ var AppShell = React131__namespace.default.forwardRef(
|
|
|
8549
8818
|
}
|
|
8550
8819
|
);
|
|
8551
8820
|
AppShell.displayName = "AppShell";
|
|
8552
|
-
var AppShellSidebar =
|
|
8821
|
+
var AppShellSidebar = React137__namespace.default.forwardRef(
|
|
8553
8822
|
({ className, ...props }, ref) => {
|
|
8554
8823
|
const { mobileOpen } = useAppShell();
|
|
8555
8824
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -8570,11 +8839,11 @@ var AppShellSidebar = React131__namespace.default.forwardRef(
|
|
|
8570
8839
|
}
|
|
8571
8840
|
);
|
|
8572
8841
|
AppShellSidebar.displayName = "AppShellSidebar";
|
|
8573
|
-
var AppShellMain =
|
|
8842
|
+
var AppShellMain = React137__namespace.default.forwardRef(
|
|
8574
8843
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("flex-1 min-w-0 flex flex-col overflow-auto", className), ...props })
|
|
8575
8844
|
);
|
|
8576
8845
|
AppShellMain.displayName = "AppShellMain";
|
|
8577
|
-
var MobileSidebarTrigger =
|
|
8846
|
+
var MobileSidebarTrigger = React137__namespace.default.forwardRef(
|
|
8578
8847
|
({ className, ...props }, ref) => {
|
|
8579
8848
|
const { mobileOpen, setMobileOpen } = useAppShell();
|
|
8580
8849
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -8603,7 +8872,7 @@ var sizeMap5 = {
|
|
|
8603
8872
|
xl: "max-w-screen-xl",
|
|
8604
8873
|
full: "max-w-full"
|
|
8605
8874
|
};
|
|
8606
|
-
var Container =
|
|
8875
|
+
var Container = React137__namespace.default.forwardRef(
|
|
8607
8876
|
({ className, size = "lg", noPadding = false, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
8608
8877
|
"div",
|
|
8609
8878
|
{
|
|
@@ -8619,7 +8888,7 @@ var Container = React131__namespace.default.forwardRef(
|
|
|
8619
8888
|
)
|
|
8620
8889
|
);
|
|
8621
8890
|
Container.displayName = "Container";
|
|
8622
|
-
var Navbar =
|
|
8891
|
+
var Navbar = React137__namespace.default.forwardRef(
|
|
8623
8892
|
({ className, sticky = false, border = true, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
8624
8893
|
"nav",
|
|
8625
8894
|
{
|
|
@@ -8635,7 +8904,7 @@ var Navbar = React131__namespace.default.forwardRef(
|
|
|
8635
8904
|
)
|
|
8636
8905
|
);
|
|
8637
8906
|
Navbar.displayName = "Navbar";
|
|
8638
|
-
var NavbarBrand =
|
|
8907
|
+
var NavbarBrand = React137__namespace.default.forwardRef(
|
|
8639
8908
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("flex items-center gap-2 px-4 shrink-0", className), ...props })
|
|
8640
8909
|
);
|
|
8641
8910
|
NavbarBrand.displayName = "NavbarBrand";
|
|
@@ -8644,7 +8913,7 @@ var alignMap = {
|
|
|
8644
8913
|
center: "justify-center flex-1",
|
|
8645
8914
|
end: "justify-end ml-auto"
|
|
8646
8915
|
};
|
|
8647
|
-
var NavbarContent =
|
|
8916
|
+
var NavbarContent = React137__namespace.default.forwardRef(
|
|
8648
8917
|
({ className, align = "start", ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
8649
8918
|
"div",
|
|
8650
8919
|
{
|
|
@@ -8655,11 +8924,11 @@ var NavbarContent = React131__namespace.default.forwardRef(
|
|
|
8655
8924
|
)
|
|
8656
8925
|
);
|
|
8657
8926
|
NavbarContent.displayName = "NavbarContent";
|
|
8658
|
-
var NavbarItem =
|
|
8927
|
+
var NavbarItem = React137__namespace.default.forwardRef(
|
|
8659
8928
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("flex items-center", className), ...props })
|
|
8660
8929
|
);
|
|
8661
8930
|
NavbarItem.displayName = "NavbarItem";
|
|
8662
|
-
var Page =
|
|
8931
|
+
var Page = React137__namespace.default.forwardRef(
|
|
8663
8932
|
({ className, maxWidth, style, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
8664
8933
|
"div",
|
|
8665
8934
|
{
|
|
@@ -8671,7 +8940,7 @@ var Page = React131__namespace.default.forwardRef(
|
|
|
8671
8940
|
)
|
|
8672
8941
|
);
|
|
8673
8942
|
Page.displayName = "Page";
|
|
8674
|
-
var PageHeader =
|
|
8943
|
+
var PageHeader = React137__namespace.default.forwardRef(
|
|
8675
8944
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
8676
8945
|
"div",
|
|
8677
8946
|
{
|
|
@@ -8682,7 +8951,7 @@ var PageHeader = React131__namespace.default.forwardRef(
|
|
|
8682
8951
|
)
|
|
8683
8952
|
);
|
|
8684
8953
|
PageHeader.displayName = "PageHeader";
|
|
8685
|
-
var PageTitle =
|
|
8954
|
+
var PageTitle = React137__namespace.default.forwardRef(
|
|
8686
8955
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
8687
8956
|
"h1",
|
|
8688
8957
|
{
|
|
@@ -8693,19 +8962,19 @@ var PageTitle = React131__namespace.default.forwardRef(
|
|
|
8693
8962
|
)
|
|
8694
8963
|
);
|
|
8695
8964
|
PageTitle.displayName = "PageTitle";
|
|
8696
|
-
var PageDescription =
|
|
8965
|
+
var PageDescription = React137__namespace.default.forwardRef(
|
|
8697
8966
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("p", { ref, className: cn("text-sm text-[hsl(var(--muted-foreground))] mt-1", className), ...props })
|
|
8698
8967
|
);
|
|
8699
8968
|
PageDescription.displayName = "PageDescription";
|
|
8700
|
-
var PageActions =
|
|
8969
|
+
var PageActions = React137__namespace.default.forwardRef(
|
|
8701
8970
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("flex items-center gap-2 shrink-0", className), ...props })
|
|
8702
8971
|
);
|
|
8703
8972
|
PageActions.displayName = "PageActions";
|
|
8704
|
-
var PageBody =
|
|
8973
|
+
var PageBody = React137__namespace.default.forwardRef(
|
|
8705
8974
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("flex-1 p-6 flex flex-col gap-6", className), ...props })
|
|
8706
8975
|
);
|
|
8707
8976
|
PageBody.displayName = "PageBody";
|
|
8708
|
-
var ResizeBox =
|
|
8977
|
+
var ResizeBox = React137__namespace.default.forwardRef(
|
|
8709
8978
|
({ className, resize = "both", minWidth = 100, minHeight = 100, style, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
8710
8979
|
"div",
|
|
8711
8980
|
{
|
|
@@ -8722,7 +8991,7 @@ var HandleIcon = () => /* @__PURE__ */ jsxRuntime.jsxs("svg", { width: "10", hei
|
|
|
8722
8991
|
/* @__PURE__ */ jsxRuntime.jsx("path", { d: "M8 5L5 8", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round" }),
|
|
8723
8992
|
/* @__PURE__ */ jsxRuntime.jsx("path", { d: "M8 8L8 8", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round" })
|
|
8724
8993
|
] });
|
|
8725
|
-
var ResizeHandle =
|
|
8994
|
+
var ResizeHandle = React137__namespace.default.forwardRef(
|
|
8726
8995
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
8727
8996
|
"div",
|
|
8728
8997
|
{
|
|
@@ -8738,16 +9007,16 @@ var ResizeHandle = React131__namespace.default.forwardRef(
|
|
|
8738
9007
|
)
|
|
8739
9008
|
);
|
|
8740
9009
|
ResizeHandle.displayName = "ResizeHandle";
|
|
8741
|
-
var SidebarCtx2 =
|
|
8742
|
-
var useSidebarCtx = () =>
|
|
9010
|
+
var SidebarCtx2 = React137__namespace.default.createContext({ collapsed: false });
|
|
9011
|
+
var useSidebarCtx = () => React137__namespace.default.useContext(SidebarCtx2);
|
|
8743
9012
|
var makeSlot = (name, cls) => {
|
|
8744
|
-
const C =
|
|
9013
|
+
const C = React137__namespace.default.forwardRef(
|
|
8745
9014
|
({ className, ...p }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn(cls, className), ...p })
|
|
8746
9015
|
);
|
|
8747
9016
|
C.displayName = name;
|
|
8748
9017
|
return C;
|
|
8749
9018
|
};
|
|
8750
|
-
var Sidebar2 =
|
|
9019
|
+
var Sidebar2 = React137__namespace.default.forwardRef(
|
|
8751
9020
|
({ className, collapsed = false, onCollapse, width = "240px", style, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(SidebarCtx2.Provider, { value: { collapsed }, children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
8752
9021
|
"div",
|
|
8753
9022
|
{
|
|
@@ -8775,7 +9044,7 @@ var SidebarContent = makeSlot("SidebarContent", "flex-1 overflow-y-auto py-2");
|
|
|
8775
9044
|
var SidebarFooter2 = makeSlot("SidebarFooter", "px-3 py-3 border-t border-[hsl(var(--border))] shrink-0");
|
|
8776
9045
|
var SidebarGroup = makeSlot("SidebarGroup", "mb-2");
|
|
8777
9046
|
var SidebarSeparator2 = makeSlot("SidebarSeparator", "h-px bg-[hsl(var(--border))] mx-3 my-2");
|
|
8778
|
-
var SidebarGroupLabel =
|
|
9047
|
+
var SidebarGroupLabel = React137__namespace.default.forwardRef(
|
|
8779
9048
|
({ className, ...props }, ref) => {
|
|
8780
9049
|
const { collapsed } = useSidebarCtx();
|
|
8781
9050
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -8789,7 +9058,7 @@ var SidebarGroupLabel = React131__namespace.default.forwardRef(
|
|
|
8789
9058
|
}
|
|
8790
9059
|
);
|
|
8791
9060
|
SidebarGroupLabel.displayName = "SidebarGroupLabel";
|
|
8792
|
-
var SidebarItem2 =
|
|
9061
|
+
var SidebarItem2 = React137__namespace.default.forwardRef(
|
|
8793
9062
|
({ className, icon, label, active, href, badge, onClick, ...props }, ref) => {
|
|
8794
9063
|
const { collapsed } = useSidebarCtx();
|
|
8795
9064
|
const cls = cn(
|
|
@@ -8808,11 +9077,11 @@ var SidebarItem2 = React131__namespace.default.forwardRef(
|
|
|
8808
9077
|
}
|
|
8809
9078
|
);
|
|
8810
9079
|
SidebarItem2.displayName = "SidebarItem";
|
|
8811
|
-
var SplitPage =
|
|
9080
|
+
var SplitPage = React137__namespace.default.forwardRef(
|
|
8812
9081
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("flex h-full w-full overflow-hidden", className), ...props })
|
|
8813
9082
|
);
|
|
8814
9083
|
SplitPage.displayName = "SplitPage";
|
|
8815
|
-
var SplitPageList =
|
|
9084
|
+
var SplitPageList = React137__namespace.default.forwardRef(
|
|
8816
9085
|
({ className, width = "320px", style, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
8817
9086
|
"div",
|
|
8818
9087
|
{
|
|
@@ -8824,7 +9093,7 @@ var SplitPageList = React131__namespace.default.forwardRef(
|
|
|
8824
9093
|
)
|
|
8825
9094
|
);
|
|
8826
9095
|
SplitPageList.displayName = "SplitPageList";
|
|
8827
|
-
var SplitPageDetail =
|
|
9096
|
+
var SplitPageDetail = React137__namespace.default.forwardRef(
|
|
8828
9097
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("flex-1 min-w-0 h-full overflow-auto", className), ...props })
|
|
8829
9098
|
);
|
|
8830
9099
|
SplitPageDetail.displayName = "SplitPageDetail";
|
|
@@ -8849,7 +9118,7 @@ var justifyMap = {
|
|
|
8849
9118
|
around: "justify-around",
|
|
8850
9119
|
evenly: "justify-evenly"
|
|
8851
9120
|
};
|
|
8852
|
-
var Stack =
|
|
9121
|
+
var Stack = React137__namespace.default.forwardRef(
|
|
8853
9122
|
({ className, gap, direction = "col", align, justify, wrap, style, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
8854
9123
|
"div",
|
|
8855
9124
|
{
|
|
@@ -8868,15 +9137,15 @@ var Stack = React131__namespace.default.forwardRef(
|
|
|
8868
9137
|
)
|
|
8869
9138
|
);
|
|
8870
9139
|
Stack.displayName = "Stack";
|
|
8871
|
-
var HStack =
|
|
9140
|
+
var HStack = React137__namespace.default.forwardRef(
|
|
8872
9141
|
(props, ref) => /* @__PURE__ */ jsxRuntime.jsx(Stack, { ref, direction: "row", ...props })
|
|
8873
9142
|
);
|
|
8874
9143
|
HStack.displayName = "HStack";
|
|
8875
|
-
var VStack =
|
|
9144
|
+
var VStack = React137__namespace.default.forwardRef(
|
|
8876
9145
|
(props, ref) => /* @__PURE__ */ jsxRuntime.jsx(Stack, { ref, direction: "col", ...props })
|
|
8877
9146
|
);
|
|
8878
9147
|
VStack.displayName = "VStack";
|
|
8879
|
-
var PageLayout =
|
|
9148
|
+
var PageLayout = React137__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
8880
9149
|
"div",
|
|
8881
9150
|
{
|
|
8882
9151
|
ref,
|
|
@@ -8886,7 +9155,7 @@ var PageLayout = React131__namespace.default.forwardRef(({ className, ...props }
|
|
|
8886
9155
|
}
|
|
8887
9156
|
));
|
|
8888
9157
|
PageLayout.displayName = "PageLayout";
|
|
8889
|
-
var PageHeader2 =
|
|
9158
|
+
var PageHeader2 = React137__namespace.default.forwardRef(
|
|
8890
9159
|
({ className, title, description, actions, back, children }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
8891
9160
|
"div",
|
|
8892
9161
|
{
|
|
@@ -8908,7 +9177,7 @@ var PageHeader2 = React131__namespace.default.forwardRef(
|
|
|
8908
9177
|
)
|
|
8909
9178
|
);
|
|
8910
9179
|
PageHeader2.displayName = "PageHeader";
|
|
8911
|
-
var PageContainer =
|
|
9180
|
+
var PageContainer = React137__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
8912
9181
|
"div",
|
|
8913
9182
|
{
|
|
8914
9183
|
ref,
|
|
@@ -8922,7 +9191,7 @@ var PageContainer = React131__namespace.default.forwardRef(({ className, ...prop
|
|
|
8922
9191
|
}
|
|
8923
9192
|
));
|
|
8924
9193
|
PageContainer.displayName = "PageContainer";
|
|
8925
|
-
var PageMain =
|
|
9194
|
+
var PageMain = React137__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
8926
9195
|
"div",
|
|
8927
9196
|
{
|
|
8928
9197
|
ref,
|
|
@@ -8937,7 +9206,7 @@ var PageMain = React131__namespace.default.forwardRef(({ className, ...props },
|
|
|
8937
9206
|
}
|
|
8938
9207
|
));
|
|
8939
9208
|
PageMain.displayName = "PageMain";
|
|
8940
|
-
var CommandPaletteCtx =
|
|
9209
|
+
var CommandPaletteCtx = React137.createContext({
|
|
8941
9210
|
open: false,
|
|
8942
9211
|
setOpen: () => {
|
|
8943
9212
|
},
|
|
@@ -8947,9 +9216,9 @@ var CommandPaletteCtx = React131.createContext({
|
|
|
8947
9216
|
function CommandPaletteProvider({
|
|
8948
9217
|
children
|
|
8949
9218
|
}) {
|
|
8950
|
-
const [open, setOpen] =
|
|
8951
|
-
const toggle =
|
|
8952
|
-
|
|
9219
|
+
const [open, setOpen] = React137.useState(false);
|
|
9220
|
+
const toggle = React137.useCallback(() => setOpen((v) => !v), []);
|
|
9221
|
+
React137.useEffect(() => {
|
|
8953
9222
|
const down = (e) => {
|
|
8954
9223
|
if (e.key === "k" && (e.metaKey || e.ctrlKey) || e.key === "/") {
|
|
8955
9224
|
if (e.key === "/" && e.target.tagName !== "BODY") return;
|
|
@@ -8963,7 +9232,7 @@ function CommandPaletteProvider({
|
|
|
8963
9232
|
return /* @__PURE__ */ jsxRuntime.jsx(CommandPaletteCtx.Provider, { value: { open, setOpen, toggle }, children });
|
|
8964
9233
|
}
|
|
8965
9234
|
function useCommandPalette() {
|
|
8966
|
-
return
|
|
9235
|
+
return React137.useContext(CommandPaletteCtx);
|
|
8967
9236
|
}
|
|
8968
9237
|
function CommandPalette({
|
|
8969
9238
|
open,
|
|
@@ -9071,7 +9340,7 @@ function CommandPalette({
|
|
|
9071
9340
|
)
|
|
9072
9341
|
] });
|
|
9073
9342
|
}
|
|
9074
|
-
var HotkeysCtx =
|
|
9343
|
+
var HotkeysCtx = React137.createContext({
|
|
9075
9344
|
hotkeys: [],
|
|
9076
9345
|
registerHotkeys: () => () => {
|
|
9077
9346
|
}
|
|
@@ -9094,16 +9363,16 @@ function HotkeysProvider({
|
|
|
9094
9363
|
children,
|
|
9095
9364
|
hotkeys: initialHotkeys = []
|
|
9096
9365
|
}) {
|
|
9097
|
-
const [hotkeys, setHotkeys] =
|
|
9098
|
-
const seqRef =
|
|
9099
|
-
const seqTimerRef =
|
|
9100
|
-
const registerHotkeys =
|
|
9366
|
+
const [hotkeys, setHotkeys] = React137.useState(initialHotkeys);
|
|
9367
|
+
const seqRef = React137.useRef([]);
|
|
9368
|
+
const seqTimerRef = React137.useRef(null);
|
|
9369
|
+
const registerHotkeys = React137.useCallback((newHotkeys) => {
|
|
9101
9370
|
setHotkeys((prev) => [...prev, ...newHotkeys]);
|
|
9102
9371
|
return () => {
|
|
9103
9372
|
setHotkeys((prev) => prev.filter((h) => !newHotkeys.includes(h)));
|
|
9104
9373
|
};
|
|
9105
9374
|
}, []);
|
|
9106
|
-
|
|
9375
|
+
React137.useEffect(() => {
|
|
9107
9376
|
const handleKeyDown = (e) => {
|
|
9108
9377
|
const target = e.target;
|
|
9109
9378
|
if (target.tagName === "INPUT" || target.tagName === "TEXTAREA" || target.tagName === "SELECT" || target.isContentEditable) {
|
|
@@ -9143,14 +9412,14 @@ function HotkeysProvider({
|
|
|
9143
9412
|
return /* @__PURE__ */ jsxRuntime.jsx(HotkeysCtx.Provider, { value: { hotkeys, registerHotkeys }, children });
|
|
9144
9413
|
}
|
|
9145
9414
|
function useHotkeys() {
|
|
9146
|
-
return
|
|
9415
|
+
return React137.useContext(HotkeysCtx);
|
|
9147
9416
|
}
|
|
9148
9417
|
function HelpSheet({
|
|
9149
9418
|
open,
|
|
9150
9419
|
onClose
|
|
9151
9420
|
}) {
|
|
9152
9421
|
const { hotkeys } = useHotkeys();
|
|
9153
|
-
|
|
9422
|
+
React137.useEffect(() => {
|
|
9154
9423
|
const handleEsc = (e) => {
|
|
9155
9424
|
if (e.key === "Escape" && open) onClose();
|
|
9156
9425
|
};
|
|
@@ -9304,9 +9573,9 @@ function ToastItem({ toast: t, onDismiss }) {
|
|
|
9304
9573
|
);
|
|
9305
9574
|
}
|
|
9306
9575
|
function Toaster() {
|
|
9307
|
-
const [toasts, setToasts] =
|
|
9308
|
-
const timers =
|
|
9309
|
-
const dismiss =
|
|
9576
|
+
const [toasts, setToasts] = React137.useState([]);
|
|
9577
|
+
const timers = React137.useRef(/* @__PURE__ */ new Map());
|
|
9578
|
+
const dismiss = React137.useCallback((id) => {
|
|
9310
9579
|
setToasts(
|
|
9311
9580
|
(prev) => prev.map((t) => t.id === id ? { ...t, visible: false } : t)
|
|
9312
9581
|
);
|
|
@@ -9319,7 +9588,7 @@ function Toaster() {
|
|
|
9319
9588
|
timers.current.delete(id);
|
|
9320
9589
|
}
|
|
9321
9590
|
}, []);
|
|
9322
|
-
|
|
9591
|
+
React137.useEffect(() => {
|
|
9323
9592
|
const unsubToast = toastEmitter.onToast((event) => {
|
|
9324
9593
|
setToasts((prev) => {
|
|
9325
9594
|
const next = [
|
|
@@ -9368,7 +9637,7 @@ var directionClasses = {
|
|
|
9368
9637
|
bl: "bg-gradient-to-bl",
|
|
9369
9638
|
l: "bg-gradient-to-l"
|
|
9370
9639
|
};
|
|
9371
|
-
var GradientHeading =
|
|
9640
|
+
var GradientHeading = React137__namespace.default.forwardRef(
|
|
9372
9641
|
({
|
|
9373
9642
|
as: Tag = "h2",
|
|
9374
9643
|
preset = "primary",
|
|
@@ -9414,7 +9683,7 @@ function formatNumber(value, decimals, format3, locale) {
|
|
|
9414
9683
|
}
|
|
9415
9684
|
return decimals > 0 ? value.toFixed(decimals) : String(Math.round(value));
|
|
9416
9685
|
}
|
|
9417
|
-
var AnimatedNumber =
|
|
9686
|
+
var AnimatedNumber = React137__namespace.default.forwardRef(
|
|
9418
9687
|
({
|
|
9419
9688
|
value,
|
|
9420
9689
|
from = 0,
|
|
@@ -9429,12 +9698,12 @@ var AnimatedNumber = React131__namespace.default.forwardRef(
|
|
|
9429
9698
|
className,
|
|
9430
9699
|
...props
|
|
9431
9700
|
}, ref) => {
|
|
9432
|
-
const [displayed, setDisplayed] =
|
|
9433
|
-
const rafRef =
|
|
9434
|
-
const startTimeRef =
|
|
9435
|
-
const containerRef =
|
|
9436
|
-
const hasStarted =
|
|
9437
|
-
const runAnimation =
|
|
9701
|
+
const [displayed, setDisplayed] = React137.useState(autoStart ? from : value);
|
|
9702
|
+
const rafRef = React137.useRef(null);
|
|
9703
|
+
const startTimeRef = React137.useRef(null);
|
|
9704
|
+
const containerRef = React137.useRef(null);
|
|
9705
|
+
const hasStarted = React137.useRef(false);
|
|
9706
|
+
const runAnimation = React137__namespace.default.useCallback(
|
|
9438
9707
|
(startFrom) => {
|
|
9439
9708
|
if (rafRef.current !== null) cancelAnimationFrame(rafRef.current);
|
|
9440
9709
|
startTimeRef.current = null;
|
|
@@ -9457,7 +9726,7 @@ var AnimatedNumber = React131__namespace.default.forwardRef(
|
|
|
9457
9726
|
},
|
|
9458
9727
|
[value, duration, easing]
|
|
9459
9728
|
);
|
|
9460
|
-
|
|
9729
|
+
React137.useEffect(() => {
|
|
9461
9730
|
if (!autoStart) return void 0;
|
|
9462
9731
|
if (typeof IntersectionObserver !== "undefined") {
|
|
9463
9732
|
const el = containerRef.current;
|
|
@@ -9478,11 +9747,11 @@ var AnimatedNumber = React131__namespace.default.forwardRef(
|
|
|
9478
9747
|
return void 0;
|
|
9479
9748
|
}
|
|
9480
9749
|
}, []);
|
|
9481
|
-
|
|
9750
|
+
React137.useEffect(() => {
|
|
9482
9751
|
if (!hasStarted.current) return;
|
|
9483
9752
|
runAnimation(displayed);
|
|
9484
9753
|
}, [value]);
|
|
9485
|
-
|
|
9754
|
+
React137.useEffect(() => {
|
|
9486
9755
|
return () => {
|
|
9487
9756
|
if (rafRef.current !== null) cancelAnimationFrame(rafRef.current);
|
|
9488
9757
|
};
|
|
@@ -9522,9 +9791,9 @@ function TextReveal({
|
|
|
9522
9791
|
className,
|
|
9523
9792
|
style
|
|
9524
9793
|
}) {
|
|
9525
|
-
const [revealed, setRevealed] =
|
|
9526
|
-
const containerRef =
|
|
9527
|
-
|
|
9794
|
+
const [revealed, setRevealed] = React137.useState(false);
|
|
9795
|
+
const containerRef = React137.useRef(null);
|
|
9796
|
+
React137.useEffect(() => {
|
|
9528
9797
|
if (!autoStart) return void 0;
|
|
9529
9798
|
const el = containerRef.current;
|
|
9530
9799
|
if (!el) return void 0;
|
|
@@ -9546,7 +9815,7 @@ function TextReveal({
|
|
|
9546
9815
|
}
|
|
9547
9816
|
}, [autoStart, delay]);
|
|
9548
9817
|
const units = mode === "chars" ? text.split("") : mode === "words" ? text.split(" ") : [text];
|
|
9549
|
-
return
|
|
9818
|
+
return React137__namespace.default.createElement(
|
|
9550
9819
|
Tag,
|
|
9551
9820
|
{
|
|
9552
9821
|
ref: containerRef,
|
|
@@ -9586,16 +9855,16 @@ function Typewriter({
|
|
|
9586
9855
|
className,
|
|
9587
9856
|
style
|
|
9588
9857
|
}) {
|
|
9589
|
-
const [display, setDisplay] =
|
|
9590
|
-
const [phase, setPhase] =
|
|
9591
|
-
const [wordIdx, setWordIdx] =
|
|
9592
|
-
const [cursorVisible, setCursorVisible] =
|
|
9593
|
-
const timerRef =
|
|
9594
|
-
|
|
9858
|
+
const [display, setDisplay] = React137.useState("");
|
|
9859
|
+
const [phase, setPhase] = React137.useState("typing");
|
|
9860
|
+
const [wordIdx, setWordIdx] = React137.useState(0);
|
|
9861
|
+
const [cursorVisible, setCursorVisible] = React137.useState(true);
|
|
9862
|
+
const timerRef = React137.useRef(null);
|
|
9863
|
+
React137.useEffect(() => {
|
|
9595
9864
|
const id = setInterval(() => setCursorVisible((v) => !v), 530);
|
|
9596
9865
|
return () => clearInterval(id);
|
|
9597
9866
|
}, []);
|
|
9598
|
-
|
|
9867
|
+
React137.useEffect(() => {
|
|
9599
9868
|
if (!words.length) return void 0;
|
|
9600
9869
|
const word = words[wordIdx] ?? "";
|
|
9601
9870
|
if (phase === "typing") {
|
|
@@ -9626,7 +9895,7 @@ function Typewriter({
|
|
|
9626
9895
|
if (timerRef.current) clearTimeout(timerRef.current);
|
|
9627
9896
|
};
|
|
9628
9897
|
}, [display, phase, wordIdx, words, typeSpeed, deleteSpeed, pauseAfter, loop]);
|
|
9629
|
-
return
|
|
9898
|
+
return React137__namespace.default.createElement(
|
|
9630
9899
|
Tag,
|
|
9631
9900
|
{
|
|
9632
9901
|
"data-slot": "typewriter",
|
|
@@ -9665,9 +9934,9 @@ var headingVariants = classVarianceAuthority.cva("font-heading tracking-tight te
|
|
|
9665
9934
|
},
|
|
9666
9935
|
defaultVariants: { size: "lg", tone: "default" }
|
|
9667
9936
|
});
|
|
9668
|
-
var Heading =
|
|
9937
|
+
var Heading = React137__namespace.default.forwardRef(
|
|
9669
9938
|
({ as: Tag = "h2", size, tone, className, ...props }, ref) => {
|
|
9670
|
-
return
|
|
9939
|
+
return React137__namespace.default.createElement(Tag, {
|
|
9671
9940
|
ref,
|
|
9672
9941
|
"data-slot": "heading",
|
|
9673
9942
|
className: cn(headingVariants({ size, tone }), className),
|
|
@@ -9697,9 +9966,9 @@ var bodyVariants = classVarianceAuthority.cva("font-sans", {
|
|
|
9697
9966
|
},
|
|
9698
9967
|
defaultVariants: { size: "md", tone: "default", weight: "normal" }
|
|
9699
9968
|
});
|
|
9700
|
-
var Body =
|
|
9969
|
+
var Body = React137__namespace.default.forwardRef(
|
|
9701
9970
|
({ as: Tag = "p", size, tone, weight, className, ...props }, ref) => {
|
|
9702
|
-
return
|
|
9971
|
+
return React137__namespace.default.createElement(Tag, {
|
|
9703
9972
|
ref,
|
|
9704
9973
|
"data-slot": "body",
|
|
9705
9974
|
className: cn(bodyVariants({ size, tone, weight }), className),
|
|
@@ -9718,7 +9987,7 @@ var captionVariants = classVarianceAuthority.cva("font-sans text-[11px] font-sem
|
|
|
9718
9987
|
},
|
|
9719
9988
|
defaultVariants: { tone: "default" }
|
|
9720
9989
|
});
|
|
9721
|
-
var Caption =
|
|
9990
|
+
var Caption = React137__namespace.default.forwardRef(
|
|
9722
9991
|
({ tone, className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
9723
9992
|
"span",
|
|
9724
9993
|
{
|
|
@@ -9730,7 +9999,7 @@ var Caption = React131__namespace.default.forwardRef(
|
|
|
9730
9999
|
)
|
|
9731
10000
|
);
|
|
9732
10001
|
Caption.displayName = "Caption";
|
|
9733
|
-
var Code3 =
|
|
10002
|
+
var Code3 = React137__namespace.default.forwardRef(
|
|
9734
10003
|
({ block, className, children, ...props }, ref) => {
|
|
9735
10004
|
if (block) {
|
|
9736
10005
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -9782,7 +10051,7 @@ var presetStyles = {
|
|
|
9782
10051
|
},
|
|
9783
10052
|
custom: {}
|
|
9784
10053
|
};
|
|
9785
|
-
var GradientBackground =
|
|
10054
|
+
var GradientBackground = React137__namespace.default.forwardRef(
|
|
9786
10055
|
({
|
|
9787
10056
|
fixed = false,
|
|
9788
10057
|
preset = "slate",
|
|
@@ -9841,7 +10110,7 @@ var DEFAULT_COLORS4 = [
|
|
|
9841
10110
|
"hsl(280 100% 70% / 0.25)",
|
|
9842
10111
|
"hsl(217 33% 17% / 0.4)"
|
|
9843
10112
|
];
|
|
9844
|
-
var AnimatedGradient =
|
|
10113
|
+
var AnimatedGradient = React137__namespace.default.forwardRef(
|
|
9845
10114
|
({
|
|
9846
10115
|
colors = DEFAULT_COLORS4,
|
|
9847
10116
|
speed = 1,
|
|
@@ -9852,7 +10121,7 @@ var AnimatedGradient = React131__namespace.default.forwardRef(
|
|
|
9852
10121
|
style,
|
|
9853
10122
|
...props
|
|
9854
10123
|
}, ref) => {
|
|
9855
|
-
const idRef =
|
|
10124
|
+
const idRef = React137.useRef(`ag-${Math.random().toString(36).slice(2, 7)}`);
|
|
9856
10125
|
idRef.current;
|
|
9857
10126
|
const [c0 = DEFAULT_COLORS4[0], c1 = DEFAULT_COLORS4[1], c2 = DEFAULT_COLORS4[2]] = colors;
|
|
9858
10127
|
const duration0 = (12 / speed).toFixed(1);
|
|
@@ -9960,7 +10229,7 @@ var AnimatedGradient = React131__namespace.default.forwardRef(
|
|
|
9960
10229
|
}
|
|
9961
10230
|
);
|
|
9962
10231
|
AnimatedGradient.displayName = "AnimatedGradient";
|
|
9963
|
-
var DottedBackground =
|
|
10232
|
+
var DottedBackground = React137__namespace.default.forwardRef(
|
|
9964
10233
|
({
|
|
9965
10234
|
color,
|
|
9966
10235
|
dotSize = 1,
|
|
@@ -10007,7 +10276,7 @@ var DottedBackground = React131__namespace.default.forwardRef(
|
|
|
10007
10276
|
}
|
|
10008
10277
|
);
|
|
10009
10278
|
DottedBackground.displayName = "DottedBackground";
|
|
10010
|
-
var NoiseBackground =
|
|
10279
|
+
var NoiseBackground = React137__namespace.default.forwardRef(
|
|
10011
10280
|
({
|
|
10012
10281
|
opacity = 0.04,
|
|
10013
10282
|
frequency = 0.65,
|
|
@@ -10103,7 +10372,7 @@ var DEFAULT_COLORS5 = [
|
|
|
10103
10372
|
[0.55, 0.3, 0.95]
|
|
10104
10373
|
// chart-3 violet
|
|
10105
10374
|
];
|
|
10106
|
-
var HeroShaderA =
|
|
10375
|
+
var HeroShaderA = React137__namespace.default.forwardRef(
|
|
10107
10376
|
({
|
|
10108
10377
|
className,
|
|
10109
10378
|
colors = DEFAULT_COLORS5,
|
|
@@ -10114,11 +10383,11 @@ var HeroShaderA = React131__namespace.default.forwardRef(
|
|
|
10114
10383
|
style,
|
|
10115
10384
|
...props
|
|
10116
10385
|
}, ref) => {
|
|
10117
|
-
const wrapRef =
|
|
10118
|
-
const canvasRef =
|
|
10119
|
-
const fallbackRef =
|
|
10120
|
-
|
|
10121
|
-
|
|
10386
|
+
const wrapRef = React137.useRef(null);
|
|
10387
|
+
const canvasRef = React137.useRef(null);
|
|
10388
|
+
const fallbackRef = React137.useRef(false);
|
|
10389
|
+
React137__namespace.default.useImperativeHandle(ref, () => wrapRef.current);
|
|
10390
|
+
React137.useEffect(() => {
|
|
10122
10391
|
if (typeof window === "undefined") return;
|
|
10123
10392
|
const reduceMotion = window.matchMedia("(prefers-reduced-motion: reduce)").matches;
|
|
10124
10393
|
const canvas = canvasRef.current;
|
|
@@ -10254,7 +10523,7 @@ var HeroShaderA = React131__namespace.default.forwardRef(
|
|
|
10254
10523
|
}
|
|
10255
10524
|
);
|
|
10256
10525
|
HeroShaderA.displayName = "HeroShaderA";
|
|
10257
|
-
var ScrollHeader =
|
|
10526
|
+
var ScrollHeader = React137__namespace.default.forwardRef(
|
|
10258
10527
|
({
|
|
10259
10528
|
title,
|
|
10260
10529
|
subtitle,
|
|
@@ -10266,8 +10535,8 @@ var ScrollHeader = React131__namespace.default.forwardRef(
|
|
|
10266
10535
|
sticky = true,
|
|
10267
10536
|
className
|
|
10268
10537
|
}, ref) => {
|
|
10269
|
-
const [scrolled, setScrolled] =
|
|
10270
|
-
|
|
10538
|
+
const [scrolled, setScrolled] = React137.useState(false);
|
|
10539
|
+
React137.useEffect(() => {
|
|
10271
10540
|
const container = scrollRef?.current ?? window;
|
|
10272
10541
|
const handleScroll = () => {
|
|
10273
10542
|
const scrollY = container === window ? window.scrollY : container.scrollTop;
|
|
@@ -10341,7 +10610,7 @@ var DEFAULT_TRANSITION = {
|
|
|
10341
10610
|
ease: [0.16, 1, 0.3, 1]
|
|
10342
10611
|
// ease-out-expo (BezierDefinition)
|
|
10343
10612
|
};
|
|
10344
|
-
var FadeIn =
|
|
10613
|
+
var FadeIn = React137__namespace.default.forwardRef(
|
|
10345
10614
|
({ delay = 0, duration, children, ...props }, ref) => {
|
|
10346
10615
|
const transition = {
|
|
10347
10616
|
...DEFAULT_TRANSITION,
|
|
@@ -10369,7 +10638,7 @@ var DIRECTION_PRESET_MAP = {
|
|
|
10369
10638
|
left: "slideLeft",
|
|
10370
10639
|
right: "slideRight"
|
|
10371
10640
|
};
|
|
10372
|
-
var SlideIn =
|
|
10641
|
+
var SlideIn = React137__namespace.default.forwardRef(
|
|
10373
10642
|
({ direction = "up", delay = 0, duration, children, ...props }, ref) => {
|
|
10374
10643
|
const preset = MOTION_PRESETS[DIRECTION_PRESET_MAP[direction]];
|
|
10375
10644
|
const transition = {
|
|
@@ -10392,7 +10661,7 @@ var SlideIn = React131__namespace.default.forwardRef(
|
|
|
10392
10661
|
}
|
|
10393
10662
|
);
|
|
10394
10663
|
SlideIn.displayName = "SlideIn";
|
|
10395
|
-
var ScaleIn =
|
|
10664
|
+
var ScaleIn = React137__namespace.default.forwardRef(
|
|
10396
10665
|
({ delay = 0, duration, children, ...props }, ref) => {
|
|
10397
10666
|
const transition = {
|
|
10398
10667
|
...DEFAULT_TRANSITION,
|
|
@@ -10415,7 +10684,7 @@ var ScaleIn = React131__namespace.default.forwardRef(
|
|
|
10415
10684
|
);
|
|
10416
10685
|
ScaleIn.displayName = "ScaleIn";
|
|
10417
10686
|
function Reveal({ preset = "fadeIn", delay = 0, once = true, children, className }) {
|
|
10418
|
-
const ref =
|
|
10687
|
+
const ref = React137.useRef(null);
|
|
10419
10688
|
const isInView = react.useInView(ref, { once });
|
|
10420
10689
|
const variants = MOTION_PRESETS[preset];
|
|
10421
10690
|
const transition = { ...DEFAULT_TRANSITION, delay };
|
|
@@ -10433,7 +10702,7 @@ function Reveal({ preset = "fadeIn", delay = 0, once = true, children, className
|
|
|
10433
10702
|
);
|
|
10434
10703
|
}
|
|
10435
10704
|
function Stagger({ staggerDelay = 0.05, preset = "fadeIn", children, className, once = true }) {
|
|
10436
|
-
const ref =
|
|
10705
|
+
const ref = React137.useRef(null);
|
|
10437
10706
|
const isInView = react.useInView(ref, { once });
|
|
10438
10707
|
const childVariants = MOTION_PRESETS[preset];
|
|
10439
10708
|
const containerVariants = {
|
|
@@ -10456,19 +10725,19 @@ function Stagger({ staggerDelay = 0.05, preset = "fadeIn", children, className,
|
|
|
10456
10725
|
initial: "hidden",
|
|
10457
10726
|
animate: isInView ? "visible" : "hidden",
|
|
10458
10727
|
className,
|
|
10459
|
-
children:
|
|
10728
|
+
children: React137__namespace.default.Children.map(children, (child, i) => /* @__PURE__ */ jsxRuntime.jsx(react.motion.div, { variants: itemVariants, children: child }, i))
|
|
10460
10729
|
}
|
|
10461
10730
|
);
|
|
10462
10731
|
}
|
|
10463
|
-
var Morph =
|
|
10732
|
+
var Morph = React137__namespace.default.forwardRef(
|
|
10464
10733
|
({ layoutId, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(react.motion.div, { ref, layoutId, layout: true, ...props, children })
|
|
10465
10734
|
);
|
|
10466
10735
|
Morph.displayName = "Morph";
|
|
10467
10736
|
var rippleCounter = 0;
|
|
10468
|
-
var Ripple =
|
|
10737
|
+
var Ripple = React137__namespace.default.forwardRef(
|
|
10469
10738
|
({ color = "currentColor", duration = 0.6, children, style, ...props }, ref) => {
|
|
10470
|
-
const [ripples, setRipples] =
|
|
10471
|
-
const handlePointerDown =
|
|
10739
|
+
const [ripples, setRipples] = React137.useState([]);
|
|
10740
|
+
const handlePointerDown = React137.useCallback(
|
|
10472
10741
|
(e) => {
|
|
10473
10742
|
const rect = e.currentTarget.getBoundingClientRect();
|
|
10474
10743
|
const x = e.clientX - rect.left;
|
|
@@ -10479,7 +10748,7 @@ var Ripple = React131__namespace.default.forwardRef(
|
|
|
10479
10748
|
},
|
|
10480
10749
|
[]
|
|
10481
10750
|
);
|
|
10482
|
-
const removeRipple =
|
|
10751
|
+
const removeRipple = React137.useCallback((key) => {
|
|
10483
10752
|
setRipples((prev) => prev.filter((r) => r.key !== key));
|
|
10484
10753
|
}, []);
|
|
10485
10754
|
const rippleTransition = {
|
|
@@ -10521,9 +10790,9 @@ var Ripple = React131__namespace.default.forwardRef(
|
|
|
10521
10790
|
}
|
|
10522
10791
|
);
|
|
10523
10792
|
Ripple.displayName = "Ripple";
|
|
10524
|
-
var Parallax =
|
|
10793
|
+
var Parallax = React137__namespace.default.forwardRef(
|
|
10525
10794
|
({ offset = 50, scrollRef, children, style, ...props }, ref) => {
|
|
10526
|
-
const innerRef =
|
|
10795
|
+
const innerRef = React137.useRef(null);
|
|
10527
10796
|
const resolvedRef = ref ?? innerRef;
|
|
10528
10797
|
const { scrollYProgress } = react.useScroll({
|
|
10529
10798
|
target: resolvedRef,
|
|
@@ -10544,13 +10813,334 @@ var Parallax = React131__namespace.default.forwardRef(
|
|
|
10544
10813
|
);
|
|
10545
10814
|
Parallax.displayName = "Parallax";
|
|
10546
10815
|
function useLayoutId(key) {
|
|
10547
|
-
const id =
|
|
10816
|
+
const id = React137.useId();
|
|
10548
10817
|
return `${key}-${id}`;
|
|
10549
10818
|
}
|
|
10550
10819
|
function Transition({ show = true, children, mode = "wait" }) {
|
|
10551
10820
|
return /* @__PURE__ */ jsxRuntime.jsx(react.AnimatePresence, { mode, children: show ? children : null });
|
|
10552
10821
|
}
|
|
10553
|
-
|
|
10822
|
+
function Checkbox2({
|
|
10823
|
+
checked,
|
|
10824
|
+
onCheckedChange,
|
|
10825
|
+
className
|
|
10826
|
+
}) {
|
|
10827
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
10828
|
+
"input",
|
|
10829
|
+
{
|
|
10830
|
+
type: "checkbox",
|
|
10831
|
+
checked: checked === true,
|
|
10832
|
+
ref: (el) => {
|
|
10833
|
+
if (el) el.indeterminate = checked === "indeterminate";
|
|
10834
|
+
},
|
|
10835
|
+
onChange: (e) => onCheckedChange(e.target.checked),
|
|
10836
|
+
className: cn(
|
|
10837
|
+
"h-4 w-4 rounded border border-input accent-primary cursor-pointer",
|
|
10838
|
+
"focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-1",
|
|
10839
|
+
className
|
|
10840
|
+
)
|
|
10841
|
+
}
|
|
10842
|
+
);
|
|
10843
|
+
}
|
|
10844
|
+
function SortIcon({ dir }) {
|
|
10845
|
+
if (dir === "asc") return /* @__PURE__ */ jsxRuntime.jsx(lucideReact.ArrowUp, { className: "h-3.5 w-3.5 shrink-0" });
|
|
10846
|
+
if (dir === "desc") return /* @__PURE__ */ jsxRuntime.jsx(lucideReact.ArrowDown, { className: "h-3.5 w-3.5 shrink-0" });
|
|
10847
|
+
return /* @__PURE__ */ jsxRuntime.jsx(lucideReact.ArrowUpDown, { className: "h-3.5 w-3.5 shrink-0 opacity-30" });
|
|
10848
|
+
}
|
|
10849
|
+
function ColumnVisibilityDropdown({
|
|
10850
|
+
columns,
|
|
10851
|
+
visibility,
|
|
10852
|
+
onVisibilityChange
|
|
10853
|
+
}) {
|
|
10854
|
+
const [open, setOpen] = React137.useState(false);
|
|
10855
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "relative", children: [
|
|
10856
|
+
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
10857
|
+
"button",
|
|
10858
|
+
{
|
|
10859
|
+
onClick: () => setOpen((v) => !v),
|
|
10860
|
+
className: cn(
|
|
10861
|
+
"inline-flex items-center gap-1.5 rounded-md border border-border px-2.5 py-1.5 text-xs font-medium",
|
|
10862
|
+
"bg-transparent text-muted-foreground hover:bg-accent hover:text-accent-foreground",
|
|
10863
|
+
"focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
|
|
10864
|
+
"transition-colors"
|
|
10865
|
+
),
|
|
10866
|
+
children: [
|
|
10867
|
+
/* @__PURE__ */ jsxRuntime.jsx(lucideReact.Columns3, { className: "h-3.5 w-3.5" }),
|
|
10868
|
+
"Columns",
|
|
10869
|
+
/* @__PURE__ */ jsxRuntime.jsx(lucideReact.ChevronDown, { className: "h-3 w-3" })
|
|
10870
|
+
]
|
|
10871
|
+
}
|
|
10872
|
+
),
|
|
10873
|
+
open && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
10874
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "fixed inset-0 z-10", onClick: () => setOpen(false) }),
|
|
10875
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute right-0 top-full mt-1 z-20 min-w-[140px] rounded-md border border-border bg-popover shadow-lg py-1", children: columns.map((col) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
10876
|
+
"label",
|
|
10877
|
+
{
|
|
10878
|
+
className: "flex items-center gap-2 px-3 py-1.5 text-xs text-foreground hover:bg-accent cursor-pointer",
|
|
10879
|
+
children: [
|
|
10880
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
10881
|
+
"input",
|
|
10882
|
+
{
|
|
10883
|
+
type: "checkbox",
|
|
10884
|
+
className: "h-3.5 w-3.5 accent-primary",
|
|
10885
|
+
checked: visibility[col.id] !== false,
|
|
10886
|
+
onChange: (e) => onVisibilityChange(col.id, e.target.checked)
|
|
10887
|
+
}
|
|
10888
|
+
),
|
|
10889
|
+
col.label
|
|
10890
|
+
]
|
|
10891
|
+
},
|
|
10892
|
+
col.id
|
|
10893
|
+
)) })
|
|
10894
|
+
] })
|
|
10895
|
+
] });
|
|
10896
|
+
}
|
|
10897
|
+
function SkeletonRow({ cols }) {
|
|
10898
|
+
return /* @__PURE__ */ jsxRuntime.jsx("tr", { className: "border-t border-border", children: Array.from({ length: cols }, (_, i) => /* @__PURE__ */ jsxRuntime.jsx("td", { className: "px-3 py-2.5", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
10899
|
+
"div",
|
|
10900
|
+
{
|
|
10901
|
+
className: "h-4 rounded bg-gradient-to-r from-muted via-muted/50 to-muted bg-[length:400%_100%] animate-[shimmer_2s_ease-in-out_infinite]",
|
|
10902
|
+
style: { width: `${60 + Math.random() * 30}%` }
|
|
10903
|
+
}
|
|
10904
|
+
) }, i)) });
|
|
10905
|
+
}
|
|
10906
|
+
function DataGrid2({
|
|
10907
|
+
columns,
|
|
10908
|
+
data,
|
|
10909
|
+
selectable = false,
|
|
10910
|
+
onSelectionChange,
|
|
10911
|
+
sortable = true,
|
|
10912
|
+
columnVisibility: showColumnVisibility = false,
|
|
10913
|
+
resizable = true,
|
|
10914
|
+
filterable = false,
|
|
10915
|
+
virtual = false,
|
|
10916
|
+
virtualHeight = 480,
|
|
10917
|
+
rowHeight = 40,
|
|
10918
|
+
emptyState,
|
|
10919
|
+
loading = false,
|
|
10920
|
+
skeletonRows = 5,
|
|
10921
|
+
className,
|
|
10922
|
+
onRowClick
|
|
10923
|
+
}) {
|
|
10924
|
+
const [rowSelection, setRowSelection] = React137.useState({});
|
|
10925
|
+
const [sorting, setSorting] = React137.useState([]);
|
|
10926
|
+
const [columnFilters, setColumnFilters] = React137.useState([]);
|
|
10927
|
+
const [colVisibility, setColVisibility] = React137.useState({});
|
|
10928
|
+
const scrollContainerRef = React137__namespace.default.useRef(null);
|
|
10929
|
+
const selectionColumn = React137.useMemo(
|
|
10930
|
+
() => ({
|
|
10931
|
+
id: "_select",
|
|
10932
|
+
size: 40,
|
|
10933
|
+
enableResizing: false,
|
|
10934
|
+
enableSorting: false,
|
|
10935
|
+
header: ({ table: table2 }) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
10936
|
+
Checkbox2,
|
|
10937
|
+
{
|
|
10938
|
+
checked: table2.getIsAllPageRowsSelected() ? true : table2.getIsSomePageRowsSelected() ? "indeterminate" : false,
|
|
10939
|
+
onCheckedChange: (v) => table2.toggleAllPageRowsSelected(v)
|
|
10940
|
+
}
|
|
10941
|
+
),
|
|
10942
|
+
cell: ({ row }) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
10943
|
+
Checkbox2,
|
|
10944
|
+
{
|
|
10945
|
+
checked: row.getIsSelected(),
|
|
10946
|
+
onCheckedChange: (v) => row.toggleSelected(v)
|
|
10947
|
+
}
|
|
10948
|
+
)
|
|
10949
|
+
}),
|
|
10950
|
+
[]
|
|
10951
|
+
);
|
|
10952
|
+
const allColumns = React137.useMemo(
|
|
10953
|
+
() => selectable ? [selectionColumn, ...columns] : columns,
|
|
10954
|
+
[selectable, selectionColumn, columns]
|
|
10955
|
+
);
|
|
10956
|
+
const table = reactTable.useReactTable({
|
|
10957
|
+
data,
|
|
10958
|
+
columns: allColumns,
|
|
10959
|
+
columnResizeMode: "onChange",
|
|
10960
|
+
state: {
|
|
10961
|
+
rowSelection,
|
|
10962
|
+
sorting,
|
|
10963
|
+
columnFilters,
|
|
10964
|
+
columnVisibility: colVisibility
|
|
10965
|
+
},
|
|
10966
|
+
onRowSelectionChange: (updater) => {
|
|
10967
|
+
const next = typeof updater === "function" ? updater(rowSelection) : updater;
|
|
10968
|
+
setRowSelection(next);
|
|
10969
|
+
if (onSelectionChange) {
|
|
10970
|
+
const selectedRows = Object.keys(next).filter((k) => next[k]).map((k) => data[Number(k)]).filter(Boolean);
|
|
10971
|
+
onSelectionChange(selectedRows);
|
|
10972
|
+
}
|
|
10973
|
+
},
|
|
10974
|
+
onSortingChange: setSorting,
|
|
10975
|
+
onColumnFiltersChange: setColumnFilters,
|
|
10976
|
+
onColumnVisibilityChange: setColVisibility,
|
|
10977
|
+
getCoreRowModel: reactTable.getCoreRowModel(),
|
|
10978
|
+
getSortedRowModel: sortable ? reactTable.getSortedRowModel() : void 0,
|
|
10979
|
+
getFilteredRowModel: filterable ? reactTable.getFilteredRowModel() : void 0,
|
|
10980
|
+
enableColumnResizing: resizable,
|
|
10981
|
+
enableRowSelection: selectable
|
|
10982
|
+
});
|
|
10983
|
+
const { rows } = table.getRowModel();
|
|
10984
|
+
const virtualizer = reactVirtual.useVirtualizer({
|
|
10985
|
+
count: virtual ? rows.length : 0,
|
|
10986
|
+
getScrollElement: () => scrollContainerRef.current,
|
|
10987
|
+
estimateSize: () => rowHeight,
|
|
10988
|
+
overscan: 10
|
|
10989
|
+
});
|
|
10990
|
+
const visibleColumnDefs = table.getAllLeafColumns().filter((c) => c.id !== "_select" && c.getIsVisible());
|
|
10991
|
+
const columnVisibilityItems = visibleColumnDefs.map((c) => ({
|
|
10992
|
+
id: c.id,
|
|
10993
|
+
label: typeof c.columnDef.header === "string" ? c.columnDef.header : c.id
|
|
10994
|
+
}));
|
|
10995
|
+
const renderRows = () => {
|
|
10996
|
+
if (loading) {
|
|
10997
|
+
return Array.from({ length: skeletonRows }, (_, i) => /* @__PURE__ */ jsxRuntime.jsx(SkeletonRow, { cols: allColumns.length }, i));
|
|
10998
|
+
}
|
|
10999
|
+
if (rows.length === 0) {
|
|
11000
|
+
return /* @__PURE__ */ jsxRuntime.jsx("tr", { children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
11001
|
+
"td",
|
|
11002
|
+
{
|
|
11003
|
+
colSpan: allColumns.length,
|
|
11004
|
+
className: "py-16 text-center text-sm text-muted-foreground",
|
|
11005
|
+
children: emptyState ?? "No results."
|
|
11006
|
+
}
|
|
11007
|
+
) });
|
|
11008
|
+
}
|
|
11009
|
+
if (virtual) {
|
|
11010
|
+
const virtualItems = virtualizer.getVirtualItems();
|
|
11011
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
11012
|
+
virtualItems.length > 0 && /* @__PURE__ */ jsxRuntime.jsx("tr", { style: { height: virtualItems[0].start }, children: /* @__PURE__ */ jsxRuntime.jsx("td", { colSpan: allColumns.length }) }),
|
|
11013
|
+
virtualItems.map((vRow) => {
|
|
11014
|
+
const row = rows[vRow.index];
|
|
11015
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
11016
|
+
"tr",
|
|
11017
|
+
{
|
|
11018
|
+
"data-index": vRow.index,
|
|
11019
|
+
className: cn(
|
|
11020
|
+
"border-t border-border transition-colors",
|
|
11021
|
+
onRowClick && "cursor-pointer",
|
|
11022
|
+
row.getIsSelected() ? "bg-primary/5" : "hover:bg-accent/40"
|
|
11023
|
+
),
|
|
11024
|
+
onClick: () => onRowClick?.(row.original),
|
|
11025
|
+
children: row.getVisibleCells().map((cell) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
11026
|
+
"td",
|
|
11027
|
+
{
|
|
11028
|
+
style: { width: cell.column.getSize() },
|
|
11029
|
+
className: "px-3 py-2 text-sm border-r border-border last:border-r-0 truncate max-w-0",
|
|
11030
|
+
children: reactTable.flexRender(cell.column.columnDef.cell, cell.getContext())
|
|
11031
|
+
},
|
|
11032
|
+
cell.id
|
|
11033
|
+
))
|
|
11034
|
+
},
|
|
11035
|
+
row.id
|
|
11036
|
+
);
|
|
11037
|
+
}),
|
|
11038
|
+
virtualItems.length > 0 && /* @__PURE__ */ jsxRuntime.jsx(
|
|
11039
|
+
"tr",
|
|
11040
|
+
{
|
|
11041
|
+
style: {
|
|
11042
|
+
height: virtualizer.getTotalSize() - (virtualItems[virtualItems.length - 1]?.end ?? 0)
|
|
11043
|
+
},
|
|
11044
|
+
children: /* @__PURE__ */ jsxRuntime.jsx("td", { colSpan: allColumns.length })
|
|
11045
|
+
}
|
|
11046
|
+
)
|
|
11047
|
+
] });
|
|
11048
|
+
}
|
|
11049
|
+
return rows.map((row) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
11050
|
+
"tr",
|
|
11051
|
+
{
|
|
11052
|
+
className: cn(
|
|
11053
|
+
"border-t border-border transition-colors",
|
|
11054
|
+
onRowClick && "cursor-pointer",
|
|
11055
|
+
row.getIsSelected() ? "bg-primary/5" : "hover:bg-accent/40"
|
|
11056
|
+
),
|
|
11057
|
+
onClick: () => onRowClick?.(row.original),
|
|
11058
|
+
children: row.getVisibleCells().map((cell) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
11059
|
+
"td",
|
|
11060
|
+
{
|
|
11061
|
+
style: { width: cell.column.getSize() },
|
|
11062
|
+
className: "px-3 py-2 text-sm border-r border-border last:border-r-0 truncate max-w-0",
|
|
11063
|
+
children: reactTable.flexRender(cell.column.columnDef.cell, cell.getContext())
|
|
11064
|
+
},
|
|
11065
|
+
cell.id
|
|
11066
|
+
))
|
|
11067
|
+
},
|
|
11068
|
+
row.id
|
|
11069
|
+
));
|
|
11070
|
+
};
|
|
11071
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-slot": "data-grid", className: cn("flex flex-col gap-2", className), children: [
|
|
11072
|
+
showColumnVisibility && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center justify-end gap-2", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
11073
|
+
ColumnVisibilityDropdown,
|
|
11074
|
+
{
|
|
11075
|
+
columns: columnVisibilityItems,
|
|
11076
|
+
visibility: colVisibility,
|
|
11077
|
+
onVisibilityChange: (id, visible) => setColVisibility((prev) => ({ ...prev, [id]: visible }))
|
|
11078
|
+
}
|
|
11079
|
+
) }),
|
|
11080
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
11081
|
+
"div",
|
|
11082
|
+
{
|
|
11083
|
+
ref: virtual ? scrollContainerRef : void 0,
|
|
11084
|
+
className: "overflow-auto rounded-md border border-border",
|
|
11085
|
+
style: virtual ? { height: virtualHeight } : void 0,
|
|
11086
|
+
children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
11087
|
+
"table",
|
|
11088
|
+
{
|
|
11089
|
+
className: "w-full text-sm",
|
|
11090
|
+
style: { width: table.getCenterTotalSize() },
|
|
11091
|
+
children: [
|
|
11092
|
+
/* @__PURE__ */ jsxRuntime.jsx("thead", { className: "sticky top-0 z-10 bg-muted/60 backdrop-blur-sm", children: table.getHeaderGroups().map((hg) => /* @__PURE__ */ jsxRuntime.jsx("tr", { children: hg.headers.map((h) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
11093
|
+
"th",
|
|
11094
|
+
{
|
|
11095
|
+
style: { width: h.getSize() },
|
|
11096
|
+
className: "relative px-3 py-2.5 text-left text-xs font-semibold text-muted-foreground uppercase tracking-wider border-r border-border last:border-r-0 whitespace-nowrap",
|
|
11097
|
+
children: [
|
|
11098
|
+
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
11099
|
+
"div",
|
|
11100
|
+
{
|
|
11101
|
+
className: cn(
|
|
11102
|
+
"flex items-center gap-1.5 select-none",
|
|
11103
|
+
h.column.getCanSort() && "cursor-pointer hover:text-foreground transition-colors"
|
|
11104
|
+
),
|
|
11105
|
+
onClick: h.column.getCanSort() ? h.column.getToggleSortingHandler() : void 0,
|
|
11106
|
+
children: [
|
|
11107
|
+
h.isPlaceholder ? null : reactTable.flexRender(h.column.columnDef.header, h.getContext()),
|
|
11108
|
+
h.column.getCanSort() && /* @__PURE__ */ jsxRuntime.jsx(SortIcon, { dir: h.column.getIsSorted() })
|
|
11109
|
+
]
|
|
11110
|
+
}
|
|
11111
|
+
),
|
|
11112
|
+
h.column.getCanResize() && /* @__PURE__ */ jsxRuntime.jsx(
|
|
11113
|
+
"div",
|
|
11114
|
+
{
|
|
11115
|
+
onMouseDown: h.getResizeHandler(),
|
|
11116
|
+
onTouchStart: h.getResizeHandler(),
|
|
11117
|
+
className: cn(
|
|
11118
|
+
"absolute right-0 top-0 h-full w-1 cursor-col-resize touch-none select-none",
|
|
11119
|
+
"hover:bg-primary/40",
|
|
11120
|
+
h.column.getIsResizing() && "bg-primary/60"
|
|
11121
|
+
)
|
|
11122
|
+
}
|
|
11123
|
+
)
|
|
11124
|
+
]
|
|
11125
|
+
},
|
|
11126
|
+
h.id
|
|
11127
|
+
)) }, hg.id)) }),
|
|
11128
|
+
/* @__PURE__ */ jsxRuntime.jsx("tbody", { children: renderRows() })
|
|
11129
|
+
]
|
|
11130
|
+
}
|
|
11131
|
+
)
|
|
11132
|
+
}
|
|
11133
|
+
),
|
|
11134
|
+
selectable && Object.keys(rowSelection).length > 0 && /* @__PURE__ */ jsxRuntime.jsxs("p", { className: "text-xs text-muted-foreground", children: [
|
|
11135
|
+
Object.keys(rowSelection).filter((k) => rowSelection[k]).length,
|
|
11136
|
+
" of",
|
|
11137
|
+
" ",
|
|
11138
|
+
data.length,
|
|
11139
|
+
" row(s) selected"
|
|
11140
|
+
] })
|
|
11141
|
+
] });
|
|
11142
|
+
}
|
|
11143
|
+
var DataList = React137__namespace.default.forwardRef(
|
|
10554
11144
|
({ divided = true, bordered = true, className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
10555
11145
|
"ul",
|
|
10556
11146
|
{
|
|
@@ -10567,7 +11157,7 @@ var DataList = React131__namespace.default.forwardRef(
|
|
|
10567
11157
|
)
|
|
10568
11158
|
);
|
|
10569
11159
|
DataList.displayName = "DataList";
|
|
10570
|
-
var DataListItem =
|
|
11160
|
+
var DataListItem = React137__namespace.default.forwardRef(
|
|
10571
11161
|
({ left, title, description, right, interactive, onSelect, className, children, ...props }, ref) => {
|
|
10572
11162
|
const clickable = interactive || !!onSelect;
|
|
10573
11163
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
@@ -10627,7 +11217,7 @@ function getWeekDays(date, weekStartsOn) {
|
|
|
10627
11217
|
const start = dateFns.startOfWeek(date, { weekStartsOn });
|
|
10628
11218
|
return Array.from({ length: 7 }, (_, i) => dateFns.addDays(start, i));
|
|
10629
11219
|
}
|
|
10630
|
-
var EventCalendar =
|
|
11220
|
+
var EventCalendar = React137__namespace.default.forwardRef(
|
|
10631
11221
|
({
|
|
10632
11222
|
events,
|
|
10633
11223
|
view: viewProp,
|
|
@@ -10642,20 +11232,20 @@ var EventCalendar = React131__namespace.default.forwardRef(
|
|
|
10642
11232
|
className,
|
|
10643
11233
|
...props
|
|
10644
11234
|
}, ref) => {
|
|
10645
|
-
const [internalView, setInternalView] =
|
|
11235
|
+
const [internalView, setInternalView] = React137__namespace.default.useState("month");
|
|
10646
11236
|
const view = viewProp ?? internalView;
|
|
10647
|
-
const commitView =
|
|
11237
|
+
const commitView = React137__namespace.default.useCallback(
|
|
10648
11238
|
(next) => {
|
|
10649
11239
|
if (viewProp === void 0) setInternalView(next);
|
|
10650
11240
|
onViewChange?.(next);
|
|
10651
11241
|
},
|
|
10652
11242
|
[viewProp, onViewChange]
|
|
10653
11243
|
);
|
|
10654
|
-
const [internalDate, setInternalDate] =
|
|
11244
|
+
const [internalDate, setInternalDate] = React137__namespace.default.useState(
|
|
10655
11245
|
() => defaultDate ?? /* @__PURE__ */ new Date()
|
|
10656
11246
|
);
|
|
10657
11247
|
const date = dateProp ?? internalDate;
|
|
10658
|
-
const commitDate =
|
|
11248
|
+
const commitDate = React137__namespace.default.useCallback(
|
|
10659
11249
|
(next) => {
|
|
10660
11250
|
if (dateProp === void 0) setInternalDate(next);
|
|
10661
11251
|
onDateChange?.(next);
|
|
@@ -10681,7 +11271,7 @@ var EventCalendar = React131__namespace.default.forwardRef(
|
|
|
10681
11271
|
handleToday();
|
|
10682
11272
|
}
|
|
10683
11273
|
};
|
|
10684
|
-
const headerLabel =
|
|
11274
|
+
const headerLabel = React137__namespace.default.useMemo(() => {
|
|
10685
11275
|
if (view === "month") return dateFns.format(date, "MMMM yyyy");
|
|
10686
11276
|
if (view === "week") {
|
|
10687
11277
|
const start = dateFns.startOfWeek(date, { weekStartsOn });
|
|
@@ -10830,11 +11420,11 @@ function MonthView({
|
|
|
10830
11420
|
onEventCreate,
|
|
10831
11421
|
onDayPick
|
|
10832
11422
|
}) {
|
|
10833
|
-
const cells =
|
|
11423
|
+
const cells = React137__namespace.default.useMemo(
|
|
10834
11424
|
() => getMonthMatrix(date, weekStartsOn),
|
|
10835
11425
|
[date, weekStartsOn]
|
|
10836
11426
|
);
|
|
10837
|
-
const weekdayLabels =
|
|
11427
|
+
const weekdayLabels = React137__namespace.default.useMemo(() => {
|
|
10838
11428
|
const start = dateFns.startOfWeek(/* @__PURE__ */ new Date(), { weekStartsOn });
|
|
10839
11429
|
return Array.from({ length: 7 }, (_, i) => dateFns.format(dateFns.addDays(start, i), "EEE"));
|
|
10840
11430
|
}, [weekStartsOn]);
|
|
@@ -10981,7 +11571,7 @@ function HourGrid({
|
|
|
10981
11571
|
onEventCreate,
|
|
10982
11572
|
onEventResize
|
|
10983
11573
|
}) {
|
|
10984
|
-
const hours =
|
|
11574
|
+
const hours = React137__namespace.default.useMemo(() => Array.from({ length: 24 }, (_, i) => i), []);
|
|
10985
11575
|
const today = /* @__PURE__ */ new Date();
|
|
10986
11576
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
10987
11577
|
"div",
|
|
@@ -11035,7 +11625,7 @@ function DayColumn({
|
|
|
11035
11625
|
onEventResize,
|
|
11036
11626
|
showHeader
|
|
11037
11627
|
}) {
|
|
11038
|
-
const bodyRef =
|
|
11628
|
+
const bodyRef = React137__namespace.default.useRef(null);
|
|
11039
11629
|
const handleEmptyClick = (e) => {
|
|
11040
11630
|
if (e.target.closest("[data-event-block]")) return;
|
|
11041
11631
|
if (!onEventCreate) return;
|
|
@@ -11116,10 +11706,10 @@ function EventBlock({ event, day, onClick, onResize }) {
|
|
|
11116
11706
|
dateFns.differenceInMinutes(visibleEnd, visibleStart)
|
|
11117
11707
|
);
|
|
11118
11708
|
const top = startMinutes / 60 * HOUR_ROW_PX;
|
|
11119
|
-
const [resizingDelta, setResizingDelta] =
|
|
11709
|
+
const [resizingDelta, setResizingDelta] = React137__namespace.default.useState(0);
|
|
11120
11710
|
const height = durationMinutes / 60 * HOUR_ROW_PX + resizingDelta;
|
|
11121
|
-
const isResizing =
|
|
11122
|
-
const startY =
|
|
11711
|
+
const isResizing = React137__namespace.default.useRef(false);
|
|
11712
|
+
const startY = React137__namespace.default.useRef(0);
|
|
11123
11713
|
const handleResizePointerDown = (e) => {
|
|
11124
11714
|
if (!onResize) return;
|
|
11125
11715
|
e.preventDefault();
|
|
@@ -11208,7 +11798,7 @@ function WeekView({
|
|
|
11208
11798
|
onEventCreate,
|
|
11209
11799
|
onEventResize
|
|
11210
11800
|
}) {
|
|
11211
|
-
const days =
|
|
11801
|
+
const days = React137__namespace.default.useMemo(
|
|
11212
11802
|
() => getWeekDays(date, weekStartsOn),
|
|
11213
11803
|
[date, weekStartsOn]
|
|
11214
11804
|
);
|
|
@@ -11241,7 +11831,7 @@ function DayView({
|
|
|
11241
11831
|
}
|
|
11242
11832
|
) });
|
|
11243
11833
|
}
|
|
11244
|
-
var GridList =
|
|
11834
|
+
var GridList = React137__namespace.default.forwardRef(
|
|
11245
11835
|
({ minItemWidth = 240, gap = 1, className, style, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
11246
11836
|
"ul",
|
|
11247
11837
|
{
|
|
@@ -11258,7 +11848,7 @@ var GridList = React131__namespace.default.forwardRef(
|
|
|
11258
11848
|
)
|
|
11259
11849
|
);
|
|
11260
11850
|
GridList.displayName = "GridList";
|
|
11261
|
-
var GridListItem =
|
|
11851
|
+
var GridListItem = React137__namespace.default.forwardRef(
|
|
11262
11852
|
({ interactive, onSelect, className, ...props }, ref) => {
|
|
11263
11853
|
const clickable = interactive || !!onSelect;
|
|
11264
11854
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -11329,7 +11919,7 @@ async function extractCroppedDataUrl(image, crop, format3, quality) {
|
|
|
11329
11919
|
const mime = format3 === "jpeg" ? "image/jpeg" : format3 === "webp" ? "image/webp" : "image/png";
|
|
11330
11920
|
return canvas.toDataURL(mime, quality);
|
|
11331
11921
|
}
|
|
11332
|
-
var ImageCrop =
|
|
11922
|
+
var ImageCrop = React137__namespace.default.forwardRef(
|
|
11333
11923
|
({
|
|
11334
11924
|
src,
|
|
11335
11925
|
aspect,
|
|
@@ -11344,13 +11934,13 @@ var ImageCrop = React131__namespace.default.forwardRef(
|
|
|
11344
11934
|
className,
|
|
11345
11935
|
...props
|
|
11346
11936
|
}, ref) => {
|
|
11347
|
-
const [crop, setCrop] =
|
|
11348
|
-
const imgRef =
|
|
11349
|
-
const timerRef =
|
|
11350
|
-
|
|
11937
|
+
const [crop, setCrop] = React137__namespace.default.useState(void 0);
|
|
11938
|
+
const imgRef = React137__namespace.default.useRef(null);
|
|
11939
|
+
const timerRef = React137__namespace.default.useRef(null);
|
|
11940
|
+
React137__namespace.default.useEffect(() => {
|
|
11351
11941
|
setCrop(void 0);
|
|
11352
11942
|
}, [src]);
|
|
11353
|
-
|
|
11943
|
+
React137__namespace.default.useEffect(() => {
|
|
11354
11944
|
return () => {
|
|
11355
11945
|
if (timerRef.current) clearTimeout(timerRef.current);
|
|
11356
11946
|
};
|
|
@@ -11575,7 +12165,7 @@ function TreeRow({
|
|
|
11575
12165
|
}
|
|
11576
12166
|
);
|
|
11577
12167
|
}
|
|
11578
|
-
var Tree =
|
|
12168
|
+
var Tree = React137__namespace.default.forwardRef(
|
|
11579
12169
|
({
|
|
11580
12170
|
data,
|
|
11581
12171
|
defaultExpandedIds,
|
|
@@ -11591,21 +12181,21 @@ var Tree = React131__namespace.default.forwardRef(
|
|
|
11591
12181
|
...props
|
|
11592
12182
|
}, ref) => {
|
|
11593
12183
|
const isControlled = expandedIds !== void 0;
|
|
11594
|
-
const [internalExpanded, setInternalExpanded] =
|
|
12184
|
+
const [internalExpanded, setInternalExpanded] = React137__namespace.default.useState(
|
|
11595
12185
|
() => new Set(defaultExpandedIds ?? [])
|
|
11596
12186
|
);
|
|
11597
|
-
const expandedSet =
|
|
12187
|
+
const expandedSet = React137__namespace.default.useMemo(
|
|
11598
12188
|
() => isControlled ? new Set(expandedIds) : internalExpanded,
|
|
11599
12189
|
[isControlled, expandedIds, internalExpanded]
|
|
11600
12190
|
);
|
|
11601
|
-
const commitExpanded =
|
|
12191
|
+
const commitExpanded = React137__namespace.default.useCallback(
|
|
11602
12192
|
(next) => {
|
|
11603
12193
|
if (!isControlled) setInternalExpanded(next);
|
|
11604
12194
|
onExpandedChange?.(Array.from(next));
|
|
11605
12195
|
},
|
|
11606
12196
|
[isControlled, onExpandedChange]
|
|
11607
12197
|
);
|
|
11608
|
-
const toggle =
|
|
12198
|
+
const toggle = React137__namespace.default.useCallback(
|
|
11609
12199
|
(id) => {
|
|
11610
12200
|
const next = new Set(expandedSet);
|
|
11611
12201
|
if (next.has(id)) next.delete(id);
|
|
@@ -11614,7 +12204,7 @@ var Tree = React131__namespace.default.forwardRef(
|
|
|
11614
12204
|
},
|
|
11615
12205
|
[expandedSet, commitExpanded]
|
|
11616
12206
|
);
|
|
11617
|
-
const expand =
|
|
12207
|
+
const expand = React137__namespace.default.useCallback(
|
|
11618
12208
|
(id) => {
|
|
11619
12209
|
if (expandedSet.has(id)) return;
|
|
11620
12210
|
const next = new Set(expandedSet);
|
|
@@ -11623,7 +12213,7 @@ var Tree = React131__namespace.default.forwardRef(
|
|
|
11623
12213
|
},
|
|
11624
12214
|
[expandedSet, commitExpanded]
|
|
11625
12215
|
);
|
|
11626
|
-
const collapse =
|
|
12216
|
+
const collapse = React137__namespace.default.useCallback(
|
|
11627
12217
|
(id) => {
|
|
11628
12218
|
if (!expandedSet.has(id)) return;
|
|
11629
12219
|
const next = new Set(expandedSet);
|
|
@@ -11632,27 +12222,27 @@ var Tree = React131__namespace.default.forwardRef(
|
|
|
11632
12222
|
},
|
|
11633
12223
|
[expandedSet, commitExpanded]
|
|
11634
12224
|
);
|
|
11635
|
-
const rows =
|
|
12225
|
+
const rows = React137__namespace.default.useMemo(
|
|
11636
12226
|
() => flatten(data, expandedSet),
|
|
11637
12227
|
[data, expandedSet]
|
|
11638
12228
|
);
|
|
11639
|
-
const [focusedId, setFocusedId] =
|
|
12229
|
+
const [focusedId, setFocusedId] = React137__namespace.default.useState(
|
|
11640
12230
|
() => selectedId ?? data[0]?.id ?? null
|
|
11641
12231
|
);
|
|
11642
|
-
const rowRefs =
|
|
11643
|
-
const registerRef =
|
|
12232
|
+
const rowRefs = React137__namespace.default.useRef(/* @__PURE__ */ new Map());
|
|
12233
|
+
const registerRef = React137__namespace.default.useCallback(
|
|
11644
12234
|
(id, el) => {
|
|
11645
12235
|
if (el) rowRefs.current.set(id, el);
|
|
11646
12236
|
else rowRefs.current.delete(id);
|
|
11647
12237
|
},
|
|
11648
12238
|
[]
|
|
11649
12239
|
);
|
|
11650
|
-
const moveFocus =
|
|
12240
|
+
const moveFocus = React137__namespace.default.useCallback((id) => {
|
|
11651
12241
|
setFocusedId(id);
|
|
11652
12242
|
const el = rowRefs.current.get(id);
|
|
11653
12243
|
el?.focus();
|
|
11654
12244
|
}, []);
|
|
11655
|
-
const onRowKeyDown =
|
|
12245
|
+
const onRowKeyDown = React137__namespace.default.useCallback(
|
|
11656
12246
|
(e, row) => {
|
|
11657
12247
|
const idx = rows.findIndex((r) => r.node.id === row.node.id);
|
|
11658
12248
|
if (idx === -1) return;
|
|
@@ -11702,11 +12292,11 @@ var Tree = React131__namespace.default.forwardRef(
|
|
|
11702
12292
|
core.useSensor(core.PointerSensor, { activationConstraint: { distance: 5 } }),
|
|
11703
12293
|
core.useSensor(core.KeyboardSensor)
|
|
11704
12294
|
);
|
|
11705
|
-
const [activeDragId, setActiveDragId] =
|
|
11706
|
-
const handleDragStart =
|
|
12295
|
+
const [activeDragId, setActiveDragId] = React137__namespace.default.useState(null);
|
|
12296
|
+
const handleDragStart = React137__namespace.default.useCallback((e) => {
|
|
11707
12297
|
setActiveDragId(String(e.active.id));
|
|
11708
12298
|
}, []);
|
|
11709
|
-
const handleDragEnd =
|
|
12299
|
+
const handleDragEnd = React137__namespace.default.useCallback(
|
|
11710
12300
|
(e) => {
|
|
11711
12301
|
setActiveDragId(null);
|
|
11712
12302
|
const { active, over } = e;
|
|
@@ -11722,8 +12312,8 @@ var Tree = React131__namespace.default.forwardRef(
|
|
|
11722
12312
|
},
|
|
11723
12313
|
[onMove]
|
|
11724
12314
|
);
|
|
11725
|
-
const handleDragCancel =
|
|
11726
|
-
const scrollerRef =
|
|
12315
|
+
const handleDragCancel = React137__namespace.default.useCallback(() => setActiveDragId(null), []);
|
|
12316
|
+
const scrollerRef = React137__namespace.default.useRef(null);
|
|
11727
12317
|
const virtualizer = reactVirtual.useVirtualizer({
|
|
11728
12318
|
count: virtualize ? rows.length : 0,
|
|
11729
12319
|
getScrollElement: () => scrollerRef.current,
|
|
@@ -11825,7 +12415,7 @@ async function exitFs() {
|
|
|
11825
12415
|
if (d.exitFullscreen) return void d.exitFullscreen();
|
|
11826
12416
|
if (d.webkitExitFullscreen) return void d.webkitExitFullscreen();
|
|
11827
12417
|
}
|
|
11828
|
-
var VideoPlayer =
|
|
12418
|
+
var VideoPlayer = React137__namespace.default.forwardRef(
|
|
11829
12419
|
({
|
|
11830
12420
|
src,
|
|
11831
12421
|
poster,
|
|
@@ -11842,33 +12432,33 @@ var VideoPlayer = React131__namespace.default.forwardRef(
|
|
|
11842
12432
|
muted: mutedProp,
|
|
11843
12433
|
...videoProps
|
|
11844
12434
|
}, ref) => {
|
|
11845
|
-
const containerRef =
|
|
11846
|
-
const videoRef =
|
|
11847
|
-
const hideTimerRef =
|
|
11848
|
-
const [isPlaying, setIsPlaying] =
|
|
11849
|
-
const [hasPlayed, setHasPlayed] =
|
|
11850
|
-
const [currentTime, setCurrentTime] =
|
|
11851
|
-
const [duration, setDuration] =
|
|
11852
|
-
const [buffered, setBuffered] =
|
|
11853
|
-
const [volume, setVolume] =
|
|
11854
|
-
const [isMuted, setIsMuted] =
|
|
11855
|
-
const [isFullscreen, setIsFullscreen] =
|
|
11856
|
-
const [showControls, setShowControls] =
|
|
11857
|
-
|
|
11858
|
-
|
|
12435
|
+
const containerRef = React137__namespace.default.useRef(null);
|
|
12436
|
+
const videoRef = React137__namespace.default.useRef(null);
|
|
12437
|
+
const hideTimerRef = React137__namespace.default.useRef(null);
|
|
12438
|
+
const [isPlaying, setIsPlaying] = React137__namespace.default.useState(false);
|
|
12439
|
+
const [hasPlayed, setHasPlayed] = React137__namespace.default.useState(Boolean(autoPlay));
|
|
12440
|
+
const [currentTime, setCurrentTime] = React137__namespace.default.useState(0);
|
|
12441
|
+
const [duration, setDuration] = React137__namespace.default.useState(0);
|
|
12442
|
+
const [buffered, setBuffered] = React137__namespace.default.useState(0);
|
|
12443
|
+
const [volume, setVolume] = React137__namespace.default.useState(1);
|
|
12444
|
+
const [isMuted, setIsMuted] = React137__namespace.default.useState(Boolean(mutedProp ?? autoPlay));
|
|
12445
|
+
const [isFullscreen, setIsFullscreen] = React137__namespace.default.useState(false);
|
|
12446
|
+
const [showControls, setShowControls] = React137__namespace.default.useState(true);
|
|
12447
|
+
React137__namespace.default.useImperativeHandle(ref, () => containerRef.current);
|
|
12448
|
+
React137__namespace.default.useEffect(() => {
|
|
11859
12449
|
const v = videoRef.current;
|
|
11860
12450
|
if (!v) return;
|
|
11861
12451
|
v.volume = volume;
|
|
11862
12452
|
v.muted = isMuted;
|
|
11863
12453
|
}, [volume, isMuted]);
|
|
11864
|
-
const showAndScheduleHide =
|
|
12454
|
+
const showAndScheduleHide = React137__namespace.default.useCallback(() => {
|
|
11865
12455
|
setShowControls(true);
|
|
11866
12456
|
if (hideTimerRef.current) clearTimeout(hideTimerRef.current);
|
|
11867
12457
|
if (isPlaying) {
|
|
11868
12458
|
hideTimerRef.current = setTimeout(() => setShowControls(false), 3e3);
|
|
11869
12459
|
}
|
|
11870
12460
|
}, [isPlaying]);
|
|
11871
|
-
|
|
12461
|
+
React137__namespace.default.useEffect(() => {
|
|
11872
12462
|
if (!isPlaying) {
|
|
11873
12463
|
if (hideTimerRef.current) clearTimeout(hideTimerRef.current);
|
|
11874
12464
|
setShowControls(true);
|
|
@@ -11879,7 +12469,7 @@ var VideoPlayer = React131__namespace.default.forwardRef(
|
|
|
11879
12469
|
if (hideTimerRef.current) clearTimeout(hideTimerRef.current);
|
|
11880
12470
|
};
|
|
11881
12471
|
}, [isPlaying]);
|
|
11882
|
-
|
|
12472
|
+
React137__namespace.default.useEffect(() => {
|
|
11883
12473
|
const onFsChange = () => setIsFullscreen(isFullscreenActive());
|
|
11884
12474
|
document.addEventListener("fullscreenchange", onFsChange);
|
|
11885
12475
|
document.addEventListener("webkitfullscreenchange", onFsChange);
|
|
@@ -11888,7 +12478,7 @@ var VideoPlayer = React131__namespace.default.forwardRef(
|
|
|
11888
12478
|
document.removeEventListener("webkitfullscreenchange", onFsChange);
|
|
11889
12479
|
};
|
|
11890
12480
|
}, []);
|
|
11891
|
-
const togglePlay =
|
|
12481
|
+
const togglePlay = React137__namespace.default.useCallback(() => {
|
|
11892
12482
|
const v = videoRef.current;
|
|
11893
12483
|
if (!v) return;
|
|
11894
12484
|
if (v.paused) {
|
|
@@ -11897,22 +12487,22 @@ var VideoPlayer = React131__namespace.default.forwardRef(
|
|
|
11897
12487
|
v.pause();
|
|
11898
12488
|
}
|
|
11899
12489
|
}, []);
|
|
11900
|
-
const toggleMute =
|
|
12490
|
+
const toggleMute = React137__namespace.default.useCallback(() => {
|
|
11901
12491
|
setIsMuted((m) => !m);
|
|
11902
12492
|
}, []);
|
|
11903
|
-
const toggleFullscreen =
|
|
12493
|
+
const toggleFullscreen = React137__namespace.default.useCallback(() => {
|
|
11904
12494
|
const el = containerRef.current;
|
|
11905
12495
|
if (!el) return;
|
|
11906
12496
|
if (isFullscreenActive()) void exitFs();
|
|
11907
12497
|
else void requestFs(el);
|
|
11908
12498
|
}, []);
|
|
11909
|
-
const seekTo =
|
|
12499
|
+
const seekTo = React137__namespace.default.useCallback((time) => {
|
|
11910
12500
|
const v = videoRef.current;
|
|
11911
12501
|
if (!v) return;
|
|
11912
12502
|
const clamped = Math.max(0, Math.min(v.duration || 0, time));
|
|
11913
12503
|
v.currentTime = clamped;
|
|
11914
12504
|
}, []);
|
|
11915
|
-
const seekBy =
|
|
12505
|
+
const seekBy = React137__namespace.default.useCallback(
|
|
11916
12506
|
(delta) => {
|
|
11917
12507
|
seekTo((videoRef.current?.currentTime ?? 0) + delta);
|
|
11918
12508
|
},
|
|
@@ -12260,7 +12850,7 @@ function Combobox({
|
|
|
12260
12850
|
className,
|
|
12261
12851
|
contentWidth = "trigger"
|
|
12262
12852
|
}) {
|
|
12263
|
-
const [open, setOpen] =
|
|
12853
|
+
const [open, setOpen] = React137__namespace.default.useState(false);
|
|
12264
12854
|
const selected = options.find((o) => o.value === value);
|
|
12265
12855
|
return /* @__PURE__ */ jsxRuntime.jsxs(Popover, { open, onOpenChange: setOpen, children: [
|
|
12266
12856
|
/* @__PURE__ */ jsxRuntime.jsx(PopoverTrigger, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
@@ -12354,9 +12944,9 @@ function ColorSchemeSelect({
|
|
|
12354
12944
|
className
|
|
12355
12945
|
}) {
|
|
12356
12946
|
const fallback = defaultValue ?? options[0]?.value ?? "";
|
|
12357
|
-
const [value, setValue] =
|
|
12358
|
-
const didMount =
|
|
12359
|
-
|
|
12947
|
+
const [value, setValue] = React137__namespace.default.useState(() => readInitial2(fallback));
|
|
12948
|
+
const didMount = React137__namespace.default.useRef(false);
|
|
12949
|
+
React137__namespace.default.useEffect(() => {
|
|
12360
12950
|
if (!didMount.current) {
|
|
12361
12951
|
didMount.current = true;
|
|
12362
12952
|
return;
|
|
@@ -12401,10 +12991,10 @@ function SidebarResizer({
|
|
|
12401
12991
|
onWidthChange,
|
|
12402
12992
|
className
|
|
12403
12993
|
}) {
|
|
12404
|
-
const [isDragging, setIsDragging] =
|
|
12405
|
-
const startX =
|
|
12406
|
-
const startWidth =
|
|
12407
|
-
|
|
12994
|
+
const [isDragging, setIsDragging] = React137.useState(false);
|
|
12995
|
+
const startX = React137.useRef(0);
|
|
12996
|
+
const startWidth = React137.useRef(defaultWidth);
|
|
12997
|
+
React137.useEffect(() => {
|
|
12408
12998
|
if (typeof window === "undefined") return;
|
|
12409
12999
|
try {
|
|
12410
13000
|
const stored = localStorage.getItem(storageKey);
|
|
@@ -12416,7 +13006,7 @@ function SidebarResizer({
|
|
|
12416
13006
|
} catch {
|
|
12417
13007
|
}
|
|
12418
13008
|
}, [storageKey, min, max, onWidthChange]);
|
|
12419
|
-
const handlePointerDown =
|
|
13009
|
+
const handlePointerDown = React137.useCallback(
|
|
12420
13010
|
(e) => {
|
|
12421
13011
|
e.preventDefault();
|
|
12422
13012
|
e.currentTarget.setPointerCapture(e.pointerId);
|
|
@@ -12429,7 +13019,7 @@ function SidebarResizer({
|
|
|
12429
13019
|
},
|
|
12430
13020
|
[]
|
|
12431
13021
|
);
|
|
12432
|
-
const handlePointerMove =
|
|
13022
|
+
const handlePointerMove = React137.useCallback(
|
|
12433
13023
|
(e) => {
|
|
12434
13024
|
if (!isDragging) return;
|
|
12435
13025
|
const delta = e.clientX - startX.current;
|
|
@@ -12442,7 +13032,7 @@ function SidebarResizer({
|
|
|
12442
13032
|
},
|
|
12443
13033
|
[isDragging, min, max, onWidthChange]
|
|
12444
13034
|
);
|
|
12445
|
-
const handlePointerUp =
|
|
13035
|
+
const handlePointerUp = React137.useCallback(
|
|
12446
13036
|
(e) => {
|
|
12447
13037
|
if (!isDragging) return;
|
|
12448
13038
|
setIsDragging(false);
|
|
@@ -12480,10 +13070,10 @@ function getInitials(name) {
|
|
|
12480
13070
|
}
|
|
12481
13071
|
function WorkspacesMenu({ workspaces, current, onSelect, className }) {
|
|
12482
13072
|
const { collapsed } = useSidebar();
|
|
12483
|
-
const [open, setOpen] =
|
|
12484
|
-
const ref =
|
|
13073
|
+
const [open, setOpen] = React137.useState(false);
|
|
13074
|
+
const ref = React137.useRef(null);
|
|
12485
13075
|
const currentWorkspace = workspaces.find((w) => w.id === current);
|
|
12486
|
-
|
|
13076
|
+
React137.useEffect(() => {
|
|
12487
13077
|
if (!open) return;
|
|
12488
13078
|
function handleClickOutside(e) {
|
|
12489
13079
|
if (ref.current && !ref.current.contains(e.target)) {
|
|
@@ -12566,9 +13156,9 @@ function getInitials2(name) {
|
|
|
12566
13156
|
}
|
|
12567
13157
|
function AppShellUserMenu({ name, email, avatar, onSignOut, onProfile, onSettings, className }) {
|
|
12568
13158
|
const { collapsed } = useSidebar();
|
|
12569
|
-
const [open, setOpen] =
|
|
12570
|
-
const ref =
|
|
12571
|
-
|
|
13159
|
+
const [open, setOpen] = React137.useState(false);
|
|
13160
|
+
const ref = React137.useRef(null);
|
|
13161
|
+
React137.useEffect(() => {
|
|
12572
13162
|
if (!open) return;
|
|
12573
13163
|
function handleClickOutside(e) {
|
|
12574
13164
|
if (ref.current && !ref.current.contains(e.target)) {
|
|
@@ -12839,6 +13429,7 @@ exports.AccordionContent = AccordionContent;
|
|
|
12839
13429
|
exports.AccordionItem = AccordionItem;
|
|
12840
13430
|
exports.AccordionTrigger = AccordionTrigger;
|
|
12841
13431
|
exports.ActivityHeatmap = ActivityHeatmap;
|
|
13432
|
+
exports.AdvancedDataGrid = DataGrid2;
|
|
12842
13433
|
exports.Alert = Alert;
|
|
12843
13434
|
exports.AlertDescription = AlertDescription;
|
|
12844
13435
|
exports.AlertDialog = AlertDialog;
|
|
@@ -12895,6 +13486,7 @@ exports.CarouselContent = CarouselContent;
|
|
|
12895
13486
|
exports.CarouselItem = CarouselItem;
|
|
12896
13487
|
exports.CarouselNext = CarouselNext;
|
|
12897
13488
|
exports.CarouselPrevious = CarouselPrevious;
|
|
13489
|
+
exports.CartLineItem = CartLineItem;
|
|
12898
13490
|
exports.ChartContainer = ChartContainer;
|
|
12899
13491
|
exports.ChartLegend = ChartLegend;
|
|
12900
13492
|
exports.ChartLegendContent = ChartLegendContent;
|
|
@@ -12992,6 +13584,7 @@ exports.DropdownMenuSub = DropdownMenuSub;
|
|
|
12992
13584
|
exports.DropdownMenuSubContent = DropdownMenuSubContent;
|
|
12993
13585
|
exports.DropdownMenuSubTrigger = DropdownMenuSubTrigger;
|
|
12994
13586
|
exports.DropdownMenuTrigger = DropdownMenuTrigger;
|
|
13587
|
+
exports.EmptyCart = EmptyCart;
|
|
12995
13588
|
exports.EmptyState = EmptyState;
|
|
12996
13589
|
exports.EmptyStateIcon = EmptyStateIcon;
|
|
12997
13590
|
exports.EventCalendar = EventCalendar;
|
|
@@ -13034,6 +13627,7 @@ exports.HoverCard = HoverCard;
|
|
|
13034
13627
|
exports.HoverCardContent = HoverCardContent;
|
|
13035
13628
|
exports.HoverCardTrigger = HoverCardTrigger;
|
|
13036
13629
|
exports.IconBadge = IconBadge;
|
|
13630
|
+
exports.IconButton = IconButton;
|
|
13037
13631
|
exports.ImageCrop = ImageCrop;
|
|
13038
13632
|
exports.Input = Input;
|
|
13039
13633
|
exports.InputOTP = InputOTP;
|
|
@@ -13115,10 +13709,12 @@ exports.Popover = Popover;
|
|
|
13115
13709
|
exports.PopoverAnchor = PopoverAnchor;
|
|
13116
13710
|
exports.PopoverContent = PopoverContent;
|
|
13117
13711
|
exports.PopoverTrigger = PopoverTrigger;
|
|
13712
|
+
exports.PriceTag = PriceTag;
|
|
13118
13713
|
exports.Progress = Progress;
|
|
13119
13714
|
exports.PropertyItem = PropertyItem;
|
|
13120
13715
|
exports.PropertyList = PropertyList;
|
|
13121
13716
|
exports.QrCode = QrCode;
|
|
13717
|
+
exports.QuantityStepper = QuantityStepper;
|
|
13122
13718
|
exports.RadioGroup = RadioGroup4;
|
|
13123
13719
|
exports.RadioGroupItem = RadioGroupItem;
|
|
13124
13720
|
exports.Rating = Rating;
|
|
@@ -13241,6 +13837,7 @@ exports.Tree = Tree;
|
|
|
13241
13837
|
exports.Typewriter = Typewriter;
|
|
13242
13838
|
exports.UserMenu = UserMenu;
|
|
13243
13839
|
exports.VStack = VStack;
|
|
13840
|
+
exports.VariantPicker = VariantPicker;
|
|
13244
13841
|
exports.VideoPlayer = VideoPlayer;
|
|
13245
13842
|
exports.WorkspaceMembers = WorkspaceMembers;
|
|
13246
13843
|
exports.WorkspacesMenu = WorkspacesMenu;
|