@codapet/design-system 0.8.7 → 0.8.9
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/AGENTS.md +8 -3
- package/dist/index.d.mts +53 -6
- package/dist/index.mjs +1133 -1012
- package/dist/index.mjs.map +1 -1
- package/dist/styles.css +52 -0
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -14,15 +14,22 @@ function cn(...inputs) {
|
|
|
14
14
|
|
|
15
15
|
// src/components/ui/accordion.tsx
|
|
16
16
|
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
17
|
+
var ACCORDION_STAGGER_STEP_MS = 80;
|
|
17
18
|
var AccordionContext = React.createContext({
|
|
18
|
-
variant: "default"
|
|
19
|
+
variant: "default",
|
|
20
|
+
staggerReveal: false
|
|
19
21
|
});
|
|
20
22
|
function Accordion({
|
|
21
23
|
variant = "default",
|
|
24
|
+
staggerReveal = false,
|
|
22
25
|
className,
|
|
23
26
|
...props
|
|
24
27
|
}) {
|
|
25
|
-
|
|
28
|
+
const context = React.useMemo(
|
|
29
|
+
() => ({ variant, staggerReveal }),
|
|
30
|
+
[variant, staggerReveal]
|
|
31
|
+
);
|
|
32
|
+
return /* @__PURE__ */ jsx(AccordionContext.Provider, { value: context, children: /* @__PURE__ */ jsx(
|
|
26
33
|
AccordionPrimitive.Root,
|
|
27
34
|
{
|
|
28
35
|
"data-slot": "accordion",
|
|
@@ -37,31 +44,61 @@ function Accordion({
|
|
|
37
44
|
}
|
|
38
45
|
function AccordionItem({
|
|
39
46
|
className,
|
|
47
|
+
style,
|
|
48
|
+
revealIndex,
|
|
40
49
|
...props
|
|
41
50
|
}) {
|
|
42
|
-
const { variant } = React.useContext(AccordionContext);
|
|
51
|
+
const { variant, staggerReveal } = React.useContext(AccordionContext);
|
|
52
|
+
const staggerStyle = staggerReveal && revealIndex ? { animationDelay: `${revealIndex * ACCORDION_STAGGER_STEP_MS}ms` } : void 0;
|
|
43
53
|
return /* @__PURE__ */ jsx(
|
|
44
54
|
AccordionPrimitive.Item,
|
|
45
55
|
{
|
|
46
56
|
"data-slot": "accordion-item",
|
|
47
57
|
className: cn(
|
|
48
|
-
variant === "outlined" ?
|
|
58
|
+
variant === "outlined" ? cn(
|
|
59
|
+
"rounded-xl border border-border-default",
|
|
60
|
+
// Border warms to the brand stroke on pointer hover only — a
|
|
61
|
+
// touch device would otherwise keep the hover colour after a tap.
|
|
62
|
+
"transition-[border-color] duration-300 ease-out motion-reduce:transition-none",
|
|
63
|
+
"[@media(hover:hover)]:hover:border-primary-stroke-default/60"
|
|
64
|
+
) : "border-b last:border-b-0",
|
|
65
|
+
staggerReveal && "animate-accordion-item-in",
|
|
49
66
|
className
|
|
50
67
|
),
|
|
68
|
+
style: staggerStyle ? { ...staggerStyle, ...style } : style,
|
|
51
69
|
...props
|
|
52
70
|
}
|
|
53
71
|
);
|
|
54
72
|
}
|
|
73
|
+
function PlusMinusIcon({ className }) {
|
|
74
|
+
return /* @__PURE__ */ jsxs(
|
|
75
|
+
"span",
|
|
76
|
+
{
|
|
77
|
+
"aria-hidden": true,
|
|
78
|
+
className: cn(
|
|
79
|
+
"text-gray-icon-default pointer-events-none relative grid size-6 shrink-0 place-items-center",
|
|
80
|
+
className
|
|
81
|
+
),
|
|
82
|
+
children: [
|
|
83
|
+
/* @__PURE__ */ jsx("span", { className: "col-start-1 row-start-1 h-[1.8px] w-3.5 rounded-full bg-current" }),
|
|
84
|
+
/* @__PURE__ */ jsx("span", { className: "col-start-1 row-start-1 h-[1.8px] w-3.5 origin-center rotate-90 rounded-full bg-current transition-[rotate] duration-[280ms] ease-[cubic-bezier(0.33,1,0.68,1)] group-data-[state=open]:rotate-0 motion-reduce:transition-none" })
|
|
85
|
+
]
|
|
86
|
+
}
|
|
87
|
+
);
|
|
88
|
+
}
|
|
55
89
|
function AccordionTrigger({
|
|
56
90
|
className,
|
|
57
91
|
children,
|
|
58
92
|
expandedIcon,
|
|
59
93
|
collapsedIcon,
|
|
94
|
+
icon = "chevron",
|
|
95
|
+
iconClassName,
|
|
60
96
|
...props
|
|
61
97
|
}) {
|
|
62
98
|
const { variant } = React.useContext(AccordionContext);
|
|
63
99
|
const hasCustomIcon = expandedIcon !== void 0 || collapsedIcon !== void 0;
|
|
64
100
|
const animatedIconSwap = variant === "outlined" && collapsedIcon !== void 0 && expandedIcon !== void 0;
|
|
101
|
+
const usesChevron = !hasCustomIcon && icon === "chevron";
|
|
65
102
|
return /* @__PURE__ */ jsx(AccordionPrimitive.Header, { className: "flex", children: /* @__PURE__ */ jsxs(
|
|
66
103
|
AccordionPrimitive.Trigger,
|
|
67
104
|
{
|
|
@@ -69,7 +106,7 @@ function AccordionTrigger({
|
|
|
69
106
|
className: cn(
|
|
70
107
|
"group focus-visible:border-ring focus-visible:ring-ring/50 flex flex-1 items-start justify-between gap-4 rounded-md py-4 text-left text-sm font-medium transition-all outline-none hover:underline focus-visible:ring-[3px] disabled:pointer-events-none disabled:opacity-50",
|
|
71
108
|
variant === "outlined" && "min-h-16 items-center gap-8 px-5 py-4 text-base lg:px-6 lg:text-lg lg:leading-7 hover:no-underline",
|
|
72
|
-
|
|
109
|
+
usesChevron && "[&[data-state=open]>svg]:rotate-180",
|
|
73
110
|
className
|
|
74
111
|
),
|
|
75
112
|
...props,
|
|
@@ -81,7 +118,15 @@ function AccordionTrigger({
|
|
|
81
118
|
] }) : /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
82
119
|
collapsedIcon !== void 0 && /* @__PURE__ */ jsx("span", { className: "group-data-[state=open]:hidden pointer-events-none shrink-0 text-muted-foreground", children: collapsedIcon }),
|
|
83
120
|
expandedIcon !== void 0 && /* @__PURE__ */ jsx("span", { className: "group-data-[state=closed]:hidden pointer-events-none shrink-0 text-muted-foreground", children: expandedIcon })
|
|
84
|
-
] }) : /* @__PURE__ */ jsx(
|
|
121
|
+
] }) : icon === "plus-minus" ? /* @__PURE__ */ jsx(PlusMinusIcon, { className: iconClassName }) : /* @__PURE__ */ jsx(
|
|
122
|
+
ChevronDownIcon,
|
|
123
|
+
{
|
|
124
|
+
className: cn(
|
|
125
|
+
"text-muted-foreground pointer-events-none size-4 shrink-0 translate-y-0.5 transition-transform duration-400",
|
|
126
|
+
iconClassName
|
|
127
|
+
)
|
|
128
|
+
}
|
|
129
|
+
)
|
|
85
130
|
]
|
|
86
131
|
}
|
|
87
132
|
) });
|
|
@@ -96,7 +141,12 @@ function AccordionContent({
|
|
|
96
141
|
AccordionPrimitive.Content,
|
|
97
142
|
{
|
|
98
143
|
"data-slot": "accordion-content",
|
|
99
|
-
className:
|
|
144
|
+
className: cn(
|
|
145
|
+
"overflow-hidden text-sm",
|
|
146
|
+
// Outlined cards fade while they grow; the stripe variant keeps the
|
|
147
|
+
// shadcn height-only motion.
|
|
148
|
+
variant === "outlined" ? "data-[state=closed]:animate-accordion-up-fade data-[state=open]:animate-accordion-down-fade" : "data-[state=closed]:animate-accordion-up data-[state=open]:animate-accordion-down"
|
|
149
|
+
),
|
|
100
150
|
...props,
|
|
101
151
|
children: /* @__PURE__ */ jsx(
|
|
102
152
|
"div",
|
|
@@ -4233,536 +4283,888 @@ function DropdownSelectOption({
|
|
|
4233
4283
|
);
|
|
4234
4284
|
}
|
|
4235
4285
|
|
|
4236
|
-
// src/components/ui/
|
|
4286
|
+
// src/components/ui/faq-accordion.tsx
|
|
4237
4287
|
import * as React32 from "react";
|
|
4238
|
-
import "@radix-ui/react-label";
|
|
4239
|
-
import { Slot as Slot5 } from "@radix-ui/react-slot";
|
|
4240
|
-
import {
|
|
4241
|
-
Controller,
|
|
4242
|
-
FormProvider,
|
|
4243
|
-
useFormContext,
|
|
4244
|
-
useFormState
|
|
4245
|
-
} from "react-hook-form";
|
|
4246
4288
|
|
|
4247
|
-
// src/components/ui/
|
|
4289
|
+
// src/components/ui/typography.tsx
|
|
4248
4290
|
import { Slot as Slot4 } from "@radix-ui/react-slot";
|
|
4249
4291
|
import { cva as cva9 } from "class-variance-authority";
|
|
4250
4292
|
import "react";
|
|
4251
4293
|
import { jsx as jsx32 } from "react/jsx-runtime";
|
|
4252
|
-
var
|
|
4294
|
+
var displayTextVariants = cva9(
|
|
4295
|
+
"tracking-normal font-normal font-serif italic text-vibrant-text-display",
|
|
4296
|
+
{
|
|
4297
|
+
variants: {
|
|
4298
|
+
size: {
|
|
4299
|
+
lg: "text-4xl md:text-[3.25rem] leading-[44px] md:leading-[64px]",
|
|
4300
|
+
md: "text-[1.75rem] md:text-4xl leading-[36px] md:leading-[44px]",
|
|
4301
|
+
sm: "text-lg md:text-xl leading-[26px] md:leading-[28px]"
|
|
4302
|
+
}
|
|
4303
|
+
},
|
|
4304
|
+
defaultVariants: {
|
|
4305
|
+
size: "md"
|
|
4306
|
+
}
|
|
4307
|
+
}
|
|
4308
|
+
);
|
|
4309
|
+
function DisplayHeading({
|
|
4310
|
+
className,
|
|
4311
|
+
size,
|
|
4312
|
+
asChild = false,
|
|
4313
|
+
...props
|
|
4314
|
+
}) {
|
|
4315
|
+
const Comp = asChild ? Slot4 : "h1";
|
|
4316
|
+
return /* @__PURE__ */ jsx32(
|
|
4317
|
+
Comp,
|
|
4318
|
+
{
|
|
4319
|
+
"data-slot": "h1",
|
|
4320
|
+
className: cn(displayTextVariants({ size, className })),
|
|
4321
|
+
...props
|
|
4322
|
+
}
|
|
4323
|
+
);
|
|
4324
|
+
}
|
|
4325
|
+
var bodyTextVariants = cva9("font-sans text-vibrant-text-body", {
|
|
4253
4326
|
variants: {
|
|
4254
4327
|
size: {
|
|
4255
|
-
lg: "text-
|
|
4256
|
-
md: "
|
|
4257
|
-
sm: "
|
|
4258
|
-
xs: "text-xs leading-[
|
|
4328
|
+
lg: "text-lg md:text-xl leading-[26px] md:leading-[28px]",
|
|
4329
|
+
md: "text-base leading-[24px]",
|
|
4330
|
+
sm: "text-sm leading-[20px]",
|
|
4331
|
+
xs: "text-xs leading-[16px]"
|
|
4259
4332
|
}
|
|
4260
4333
|
},
|
|
4261
4334
|
defaultVariants: {
|
|
4262
4335
|
size: "md"
|
|
4263
4336
|
}
|
|
4264
4337
|
});
|
|
4265
|
-
function
|
|
4338
|
+
function Body({
|
|
4266
4339
|
className,
|
|
4267
4340
|
size,
|
|
4268
4341
|
asChild = false,
|
|
4269
4342
|
...props
|
|
4270
4343
|
}) {
|
|
4271
|
-
const Comp = asChild ? Slot4 : "
|
|
4344
|
+
const Comp = asChild ? Slot4 : "p";
|
|
4272
4345
|
return /* @__PURE__ */ jsx32(
|
|
4273
4346
|
Comp,
|
|
4274
4347
|
{
|
|
4275
|
-
"data-slot": "
|
|
4276
|
-
className: cn(
|
|
4348
|
+
"data-slot": "p",
|
|
4349
|
+
className: cn(bodyTextVariants({ size, className })),
|
|
4277
4350
|
...props
|
|
4278
4351
|
}
|
|
4279
4352
|
);
|
|
4280
4353
|
}
|
|
4281
|
-
|
|
4282
|
-
|
|
4283
|
-
|
|
4284
|
-
var Form = FormProvider;
|
|
4285
|
-
var FormFieldContext = React32.createContext(
|
|
4286
|
-
{}
|
|
4287
|
-
);
|
|
4288
|
-
var FormField = ({
|
|
4354
|
+
function HeadingXL({
|
|
4355
|
+
className,
|
|
4356
|
+
asChild = false,
|
|
4289
4357
|
...props
|
|
4290
|
-
})
|
|
4291
|
-
|
|
4292
|
-
|
|
4293
|
-
|
|
4294
|
-
const fieldContext = React32.useContext(FormFieldContext);
|
|
4295
|
-
const itemContext = React32.useContext(FormItemContext);
|
|
4296
|
-
const { getFieldState } = useFormContext();
|
|
4297
|
-
const formState = useFormState({ name: fieldContext.name });
|
|
4298
|
-
const fieldState = getFieldState(fieldContext.name, formState);
|
|
4299
|
-
if (!fieldContext) {
|
|
4300
|
-
throw new Error("useFormField should be used within <FormField>");
|
|
4301
|
-
}
|
|
4302
|
-
const { id } = itemContext;
|
|
4303
|
-
return {
|
|
4304
|
-
id,
|
|
4305
|
-
name: fieldContext.name,
|
|
4306
|
-
formItemId: `${id}-form-item`,
|
|
4307
|
-
formDescriptionId: `${id}-form-item-description`,
|
|
4308
|
-
formMessageId: `${id}-form-item-message`,
|
|
4309
|
-
...fieldState
|
|
4310
|
-
};
|
|
4311
|
-
};
|
|
4312
|
-
var FormItemContext = React32.createContext(
|
|
4313
|
-
{}
|
|
4314
|
-
);
|
|
4315
|
-
function FormItem({ className, ...props }) {
|
|
4316
|
-
const id = React32.useId();
|
|
4317
|
-
return /* @__PURE__ */ jsx33(FormItemContext.Provider, { value: { id }, children: /* @__PURE__ */ jsx33(
|
|
4318
|
-
"div",
|
|
4358
|
+
}) {
|
|
4359
|
+
const Comp = asChild ? Slot4 : "h1";
|
|
4360
|
+
return /* @__PURE__ */ jsx32(
|
|
4361
|
+
Comp,
|
|
4319
4362
|
{
|
|
4320
|
-
"data-slot": "
|
|
4321
|
-
className: cn(
|
|
4363
|
+
"data-slot": "h1",
|
|
4364
|
+
className: cn(
|
|
4365
|
+
"text-2xl md:text-[2rem] leading-[32px] md:leading-[40px] font-semibold font-sans text-vibrant-text-heading",
|
|
4366
|
+
className
|
|
4367
|
+
),
|
|
4322
4368
|
...props
|
|
4323
4369
|
}
|
|
4324
|
-
)
|
|
4370
|
+
);
|
|
4325
4371
|
}
|
|
4326
|
-
function
|
|
4372
|
+
function HeadingL({
|
|
4327
4373
|
className,
|
|
4374
|
+
asChild = false,
|
|
4328
4375
|
...props
|
|
4329
4376
|
}) {
|
|
4330
|
-
const
|
|
4331
|
-
return /* @__PURE__ */
|
|
4332
|
-
|
|
4377
|
+
const Comp = asChild ? Slot4 : "h2";
|
|
4378
|
+
return /* @__PURE__ */ jsx32(
|
|
4379
|
+
Comp,
|
|
4333
4380
|
{
|
|
4334
|
-
"data-slot": "
|
|
4335
|
-
|
|
4336
|
-
|
|
4337
|
-
|
|
4381
|
+
"data-slot": "h2",
|
|
4382
|
+
className: cn(
|
|
4383
|
+
"text-[1.25rem] md:text-[1.5rem] leading-[28px] md:leading-[32px] font-semibold font-sans text-vibrant-text-heading",
|
|
4384
|
+
className
|
|
4385
|
+
),
|
|
4338
4386
|
...props
|
|
4339
4387
|
}
|
|
4340
4388
|
);
|
|
4341
4389
|
}
|
|
4342
|
-
function
|
|
4343
|
-
|
|
4344
|
-
|
|
4345
|
-
|
|
4390
|
+
function HeadingM({
|
|
4391
|
+
className,
|
|
4392
|
+
asChild = false,
|
|
4393
|
+
...props
|
|
4394
|
+
}) {
|
|
4395
|
+
const Comp = asChild ? Slot4 : "h3";
|
|
4396
|
+
return /* @__PURE__ */ jsx32(
|
|
4397
|
+
Comp,
|
|
4346
4398
|
{
|
|
4347
|
-
"data-slot": "
|
|
4348
|
-
|
|
4349
|
-
|
|
4350
|
-
|
|
4399
|
+
"data-slot": "h3",
|
|
4400
|
+
className: cn(
|
|
4401
|
+
"text-[1.125rem] md:text-xl leading-[26px] md:leading-[28px] font-semibold font-sans text-vibrant-text-heading",
|
|
4402
|
+
className
|
|
4403
|
+
),
|
|
4351
4404
|
...props
|
|
4352
4405
|
}
|
|
4353
4406
|
);
|
|
4354
4407
|
}
|
|
4355
|
-
function
|
|
4356
|
-
|
|
4357
|
-
|
|
4358
|
-
|
|
4408
|
+
function HeadingS({
|
|
4409
|
+
className,
|
|
4410
|
+
asChild = false,
|
|
4411
|
+
...props
|
|
4412
|
+
}) {
|
|
4413
|
+
const Comp = asChild ? Slot4 : "h4";
|
|
4414
|
+
return /* @__PURE__ */ jsx32(
|
|
4415
|
+
Comp,
|
|
4359
4416
|
{
|
|
4360
|
-
"data-slot": "
|
|
4361
|
-
|
|
4362
|
-
|
|
4417
|
+
"data-slot": "h4",
|
|
4418
|
+
className: cn(
|
|
4419
|
+
"text-base leading-[24px] font-semibold font-sans text-vibrant-text-heading",
|
|
4420
|
+
className
|
|
4421
|
+
),
|
|
4363
4422
|
...props
|
|
4364
4423
|
}
|
|
4365
4424
|
);
|
|
4366
4425
|
}
|
|
4367
|
-
function
|
|
4368
|
-
|
|
4369
|
-
|
|
4370
|
-
|
|
4371
|
-
|
|
4372
|
-
|
|
4373
|
-
return /* @__PURE__ */
|
|
4374
|
-
|
|
4426
|
+
function HeadingXS({
|
|
4427
|
+
className,
|
|
4428
|
+
asChild = false,
|
|
4429
|
+
...props
|
|
4430
|
+
}) {
|
|
4431
|
+
const Comp = asChild ? Slot4 : "h5";
|
|
4432
|
+
return /* @__PURE__ */ jsx32(
|
|
4433
|
+
Comp,
|
|
4375
4434
|
{
|
|
4376
|
-
"data-slot": "
|
|
4377
|
-
|
|
4378
|
-
|
|
4379
|
-
|
|
4380
|
-
|
|
4435
|
+
"data-slot": "h5",
|
|
4436
|
+
className: cn(
|
|
4437
|
+
"text-sm leading-[20px] font-semibold font-sans text-vibrant-text-heading",
|
|
4438
|
+
className
|
|
4439
|
+
),
|
|
4440
|
+
...props
|
|
4381
4441
|
}
|
|
4382
4442
|
);
|
|
4383
4443
|
}
|
|
4384
|
-
|
|
4385
|
-
// src/components/ui/hover-card.tsx
|
|
4386
|
-
import "react";
|
|
4387
|
-
import * as HoverCardPrimitive from "@radix-ui/react-hover-card";
|
|
4388
|
-
import { jsx as jsx34 } from "react/jsx-runtime";
|
|
4389
|
-
function HoverCard({
|
|
4390
|
-
...props
|
|
4391
|
-
}) {
|
|
4392
|
-
return /* @__PURE__ */ jsx34(HoverCardPrimitive.Root, { "data-slot": "hover-card", ...props });
|
|
4393
|
-
}
|
|
4394
|
-
function HoverCardTrigger({
|
|
4395
|
-
...props
|
|
4396
|
-
}) {
|
|
4397
|
-
return /* @__PURE__ */ jsx34(HoverCardPrimitive.Trigger, { "data-slot": "hover-card-trigger", ...props });
|
|
4398
|
-
}
|
|
4399
|
-
function HoverCardContent({
|
|
4444
|
+
function HeadingXXS({
|
|
4400
4445
|
className,
|
|
4401
|
-
|
|
4402
|
-
sideOffset = 4,
|
|
4446
|
+
asChild = false,
|
|
4403
4447
|
...props
|
|
4404
4448
|
}) {
|
|
4405
|
-
|
|
4406
|
-
|
|
4449
|
+
const Comp = asChild ? Slot4 : "h6";
|
|
4450
|
+
return /* @__PURE__ */ jsx32(
|
|
4451
|
+
Comp,
|
|
4407
4452
|
{
|
|
4408
|
-
"data-slot": "
|
|
4409
|
-
align,
|
|
4410
|
-
sideOffset,
|
|
4453
|
+
"data-slot": "h6",
|
|
4411
4454
|
className: cn(
|
|
4412
|
-
"
|
|
4455
|
+
"text-xs leading-[16px] font-medium font-sans text-vibrant-text-heading",
|
|
4413
4456
|
className
|
|
4414
4457
|
),
|
|
4415
4458
|
...props
|
|
4416
4459
|
}
|
|
4417
|
-
)
|
|
4460
|
+
);
|
|
4418
4461
|
}
|
|
4419
|
-
|
|
4420
|
-
// src/components/ui/input-otp.tsx
|
|
4421
|
-
import * as React34 from "react";
|
|
4422
|
-
import { OTPInput, OTPInputContext } from "input-otp";
|
|
4423
|
-
import { MinusIcon } from "lucide-react";
|
|
4424
|
-
import { jsx as jsx35, jsxs as jsxs19 } from "react/jsx-runtime";
|
|
4425
|
-
var InputOTPErrorContext = React34.createContext(false);
|
|
4426
|
-
function InputOTP({
|
|
4462
|
+
function HeadingXLMedium({
|
|
4427
4463
|
className,
|
|
4428
|
-
|
|
4429
|
-
error,
|
|
4464
|
+
asChild = false,
|
|
4430
4465
|
...props
|
|
4431
4466
|
}) {
|
|
4432
|
-
|
|
4433
|
-
|
|
4467
|
+
const Comp = asChild ? Slot4 : "h1";
|
|
4468
|
+
return /* @__PURE__ */ jsx32(
|
|
4469
|
+
Comp,
|
|
4434
4470
|
{
|
|
4435
|
-
"data-slot": "
|
|
4436
|
-
|
|
4437
|
-
"
|
|
4438
|
-
|
|
4471
|
+
"data-slot": "h1",
|
|
4472
|
+
className: cn(
|
|
4473
|
+
"text-2xl md:text-[2rem] leading-[32px] md:leading-[40px] font-medium font-sans text-vibrant-text-heading",
|
|
4474
|
+
className
|
|
4439
4475
|
),
|
|
4440
|
-
className: cn("disabled:cursor-not-allowed", className),
|
|
4441
4476
|
...props
|
|
4442
4477
|
}
|
|
4443
|
-
)
|
|
4478
|
+
);
|
|
4444
4479
|
}
|
|
4445
|
-
function
|
|
4446
|
-
return /* @__PURE__ */ jsx35(
|
|
4447
|
-
"div",
|
|
4448
|
-
{
|
|
4449
|
-
"data-slot": "input-otp-group",
|
|
4450
|
-
className: cn("flex items-center", className),
|
|
4451
|
-
...props
|
|
4452
|
-
}
|
|
4453
|
-
);
|
|
4454
|
-
}
|
|
4455
|
-
function InputOTPSlot({
|
|
4456
|
-
index,
|
|
4480
|
+
function HeadingLMedium({
|
|
4457
4481
|
className,
|
|
4482
|
+
asChild = false,
|
|
4458
4483
|
...props
|
|
4459
4484
|
}) {
|
|
4460
|
-
const
|
|
4461
|
-
|
|
4462
|
-
|
|
4463
|
-
const error = React34.useContext(InputOTPErrorContext);
|
|
4464
|
-
return /* @__PURE__ */ jsxs19(
|
|
4465
|
-
"div",
|
|
4485
|
+
const Comp = asChild ? Slot4 : "h2";
|
|
4486
|
+
return /* @__PURE__ */ jsx32(
|
|
4487
|
+
Comp,
|
|
4466
4488
|
{
|
|
4467
|
-
"data-slot": "
|
|
4468
|
-
"data-active": isActive,
|
|
4489
|
+
"data-slot": "h2",
|
|
4469
4490
|
className: cn(
|
|
4470
|
-
|
|
4471
|
-
"relative flex size-10 items-center justify-center",
|
|
4472
|
-
"border-y border-r first:border-l text-sm font-medium leading-5",
|
|
4473
|
-
"transition-all outline-none",
|
|
4474
|
-
"first:rounded-l-[4px] last:rounded-r-[4px]",
|
|
4475
|
-
"text-foreground",
|
|
4476
|
-
// Default state (no error)
|
|
4477
|
-
!error && "border-gray-stroke-default bg-background",
|
|
4478
|
-
// Hover: all slots turn blue (non-error, non-active)
|
|
4479
|
-
!error && isHovering && !isActive && "border-focus-ring",
|
|
4480
|
-
// Active slot (non-error): 2px blue border
|
|
4481
|
-
!error && isActive && "z-10 border-2 border-focus-ring",
|
|
4482
|
-
// Error (non-active)
|
|
4483
|
-
error && !isActive && "border-error-stroke-default bg-error-surface-subtle",
|
|
4484
|
-
// Error + active
|
|
4485
|
-
error && isActive && "z-10 border-2 border-error-stroke-default bg-error-surface-subtle",
|
|
4491
|
+
"text-[1.25rem] md:text-[1.5rem] leading-[28px] md:leading-[32px] font-medium font-sans text-vibrant-text-heading",
|
|
4486
4492
|
className
|
|
4487
4493
|
),
|
|
4488
|
-
...props
|
|
4489
|
-
children: [
|
|
4490
|
-
char,
|
|
4491
|
-
hasFakeCaret && /* @__PURE__ */ jsx35("div", { className: "pointer-events-none absolute inset-0 flex items-center justify-center", children: /* @__PURE__ */ jsx35("div", { className: "animate-caret-blink bg-focus-ring h-4 w-px duration-1000" }) })
|
|
4492
|
-
]
|
|
4494
|
+
...props
|
|
4493
4495
|
}
|
|
4494
4496
|
);
|
|
4495
4497
|
}
|
|
4496
|
-
function
|
|
4497
|
-
return /* @__PURE__ */ jsx35("div", { "data-slot": "input-otp-separator", role: "separator", ...props, children: /* @__PURE__ */ jsx35(MinusIcon, {}) });
|
|
4498
|
-
}
|
|
4499
|
-
|
|
4500
|
-
// src/components/ui/menubar.tsx
|
|
4501
|
-
import "react";
|
|
4502
|
-
import * as MenubarPrimitive from "@radix-ui/react-menubar";
|
|
4503
|
-
import { CheckIcon as CheckIcon3, ChevronRightIcon as ChevronRightIcon4, CircleIcon as CircleIcon3 } from "lucide-react";
|
|
4504
|
-
import { jsx as jsx36, jsxs as jsxs20 } from "react/jsx-runtime";
|
|
4505
|
-
function Menubar({
|
|
4498
|
+
function HeadingMMedium({
|
|
4506
4499
|
className,
|
|
4500
|
+
asChild = false,
|
|
4507
4501
|
...props
|
|
4508
4502
|
}) {
|
|
4509
|
-
|
|
4510
|
-
|
|
4503
|
+
const Comp = asChild ? Slot4 : "h3";
|
|
4504
|
+
return /* @__PURE__ */ jsx32(
|
|
4505
|
+
Comp,
|
|
4511
4506
|
{
|
|
4512
|
-
"data-slot": "
|
|
4507
|
+
"data-slot": "h3",
|
|
4513
4508
|
className: cn(
|
|
4514
|
-
"
|
|
4509
|
+
"text-[1.125rem] md:text-xl leading-[26px] md:leading-[28px] font-medium font-sans text-vibrant-text-heading",
|
|
4515
4510
|
className
|
|
4516
4511
|
),
|
|
4517
4512
|
...props
|
|
4518
4513
|
}
|
|
4519
4514
|
);
|
|
4520
4515
|
}
|
|
4521
|
-
function
|
|
4522
|
-
...props
|
|
4523
|
-
}) {
|
|
4524
|
-
return /* @__PURE__ */ jsx36(MenubarPrimitive.Menu, { "data-slot": "menubar-menu", ...props });
|
|
4525
|
-
}
|
|
4526
|
-
function MenubarGroup({
|
|
4527
|
-
...props
|
|
4528
|
-
}) {
|
|
4529
|
-
return /* @__PURE__ */ jsx36(MenubarPrimitive.Group, { "data-slot": "menubar-group", ...props });
|
|
4530
|
-
}
|
|
4531
|
-
function MenubarPortal({
|
|
4532
|
-
...props
|
|
4533
|
-
}) {
|
|
4534
|
-
return /* @__PURE__ */ jsx36(MenubarPrimitive.Portal, { "data-slot": "menubar-portal", ...props });
|
|
4535
|
-
}
|
|
4536
|
-
function MenubarRadioGroup({
|
|
4537
|
-
...props
|
|
4538
|
-
}) {
|
|
4539
|
-
return /* @__PURE__ */ jsx36(MenubarPrimitive.RadioGroup, { "data-slot": "menubar-radio-group", ...props });
|
|
4540
|
-
}
|
|
4541
|
-
function MenubarTrigger({
|
|
4516
|
+
function HeadingSMedium({
|
|
4542
4517
|
className,
|
|
4518
|
+
asChild = false,
|
|
4543
4519
|
...props
|
|
4544
4520
|
}) {
|
|
4545
|
-
|
|
4546
|
-
|
|
4521
|
+
const Comp = asChild ? Slot4 : "h4";
|
|
4522
|
+
return /* @__PURE__ */ jsx32(
|
|
4523
|
+
Comp,
|
|
4547
4524
|
{
|
|
4548
|
-
"data-slot": "
|
|
4525
|
+
"data-slot": "h4",
|
|
4549
4526
|
className: cn(
|
|
4550
|
-
"
|
|
4527
|
+
"text-base leading-[24px] font-medium font-sans text-vibrant-text-heading",
|
|
4551
4528
|
className
|
|
4552
4529
|
),
|
|
4553
4530
|
...props
|
|
4554
4531
|
}
|
|
4555
4532
|
);
|
|
4556
4533
|
}
|
|
4557
|
-
function
|
|
4534
|
+
function HeadingXSMedium({
|
|
4558
4535
|
className,
|
|
4559
|
-
|
|
4560
|
-
alignOffset = -4,
|
|
4561
|
-
sideOffset = 8,
|
|
4536
|
+
asChild = false,
|
|
4562
4537
|
...props
|
|
4563
4538
|
}) {
|
|
4564
|
-
|
|
4565
|
-
|
|
4539
|
+
const Comp = asChild ? Slot4 : "h5";
|
|
4540
|
+
return /* @__PURE__ */ jsx32(
|
|
4541
|
+
Comp,
|
|
4566
4542
|
{
|
|
4567
|
-
"data-slot": "
|
|
4568
|
-
align,
|
|
4569
|
-
alignOffset,
|
|
4570
|
-
sideOffset,
|
|
4543
|
+
"data-slot": "h5",
|
|
4571
4544
|
className: cn(
|
|
4572
|
-
"
|
|
4545
|
+
"text-sm leading-[20px] font-medium font-sans text-vibrant-text-heading",
|
|
4573
4546
|
className
|
|
4574
4547
|
),
|
|
4575
4548
|
...props
|
|
4576
4549
|
}
|
|
4577
|
-
)
|
|
4550
|
+
);
|
|
4578
4551
|
}
|
|
4579
|
-
function
|
|
4552
|
+
function HeadingXXSMedium({
|
|
4580
4553
|
className,
|
|
4581
|
-
|
|
4582
|
-
variant = "default",
|
|
4554
|
+
asChild = false,
|
|
4583
4555
|
...props
|
|
4584
4556
|
}) {
|
|
4585
|
-
|
|
4586
|
-
|
|
4557
|
+
const Comp = asChild ? Slot4 : "h6";
|
|
4558
|
+
return /* @__PURE__ */ jsx32(
|
|
4559
|
+
Comp,
|
|
4587
4560
|
{
|
|
4588
|
-
"data-slot": "
|
|
4589
|
-
"data-inset": inset,
|
|
4590
|
-
"data-variant": variant,
|
|
4561
|
+
"data-slot": "h6",
|
|
4591
4562
|
className: cn(
|
|
4592
|
-
"
|
|
4563
|
+
"text-xs leading-[16px] font-medium font-sans text-vibrant-text-heading",
|
|
4593
4564
|
className
|
|
4594
4565
|
),
|
|
4595
4566
|
...props
|
|
4596
4567
|
}
|
|
4597
4568
|
);
|
|
4598
4569
|
}
|
|
4599
|
-
|
|
4600
|
-
|
|
4601
|
-
|
|
4602
|
-
|
|
4603
|
-
|
|
4604
|
-
|
|
4605
|
-
|
|
4606
|
-
|
|
4570
|
+
|
|
4571
|
+
// src/components/ui/faq-accordion.tsx
|
|
4572
|
+
import { jsx as jsx33, jsxs as jsxs19 } from "react/jsx-runtime";
|
|
4573
|
+
function FaqAccordion({
|
|
4574
|
+
faqs,
|
|
4575
|
+
className,
|
|
4576
|
+
staggerReveal = false,
|
|
4577
|
+
defaultOpenQuestion,
|
|
4578
|
+
questionClassName,
|
|
4579
|
+
answerClassName,
|
|
4580
|
+
itemClassName
|
|
4581
|
+
}) {
|
|
4582
|
+
const values = React32.useMemo(() => {
|
|
4583
|
+
const seen = /* @__PURE__ */ new Set();
|
|
4584
|
+
return faqs.map((faq, i) => {
|
|
4585
|
+
const value2 = seen.has(faq.question) ? `${faq.question}__${i}` : faq.question;
|
|
4586
|
+
seen.add(faq.question);
|
|
4587
|
+
return value2;
|
|
4588
|
+
});
|
|
4589
|
+
}, [faqs]);
|
|
4590
|
+
const valueFor = (question) => {
|
|
4591
|
+
if (!question) return "";
|
|
4592
|
+
const i = faqs.findIndex((faq) => faq.question === question);
|
|
4593
|
+
return i >= 0 ? values[i] : "";
|
|
4594
|
+
};
|
|
4595
|
+
const [value, setValue] = React32.useState(() => valueFor(defaultOpenQuestion));
|
|
4596
|
+
const [seenDefault, setSeenDefault] = React32.useState(defaultOpenQuestion);
|
|
4597
|
+
if (defaultOpenQuestion !== seenDefault) {
|
|
4598
|
+
setSeenDefault(defaultOpenQuestion);
|
|
4599
|
+
setValue(valueFor(defaultOpenQuestion));
|
|
4600
|
+
}
|
|
4601
|
+
return /* @__PURE__ */ jsx33(
|
|
4602
|
+
Accordion,
|
|
4607
4603
|
{
|
|
4608
|
-
|
|
4609
|
-
|
|
4610
|
-
|
|
4611
|
-
|
|
4612
|
-
|
|
4613
|
-
|
|
4614
|
-
|
|
4615
|
-
children:
|
|
4616
|
-
|
|
4617
|
-
|
|
4618
|
-
|
|
4604
|
+
type: "single",
|
|
4605
|
+
collapsible: true,
|
|
4606
|
+
variant: "outlined",
|
|
4607
|
+
staggerReveal,
|
|
4608
|
+
value,
|
|
4609
|
+
onValueChange: setValue,
|
|
4610
|
+
className,
|
|
4611
|
+
children: faqs.map((faq, i) => /* @__PURE__ */ jsxs19(
|
|
4612
|
+
AccordionItem,
|
|
4613
|
+
{
|
|
4614
|
+
value: values[i],
|
|
4615
|
+
revealIndex: i,
|
|
4616
|
+
className: cn("rounded-lg", itemClassName),
|
|
4617
|
+
children: [
|
|
4618
|
+
/* @__PURE__ */ jsx33(AccordionTrigger, { icon: "plus-minus", children: /* @__PURE__ */ jsx33("span", { className: cn("text-vibrant-text-heading", questionClassName), children: faq.question }) }),
|
|
4619
|
+
/* @__PURE__ */ jsx33(
|
|
4620
|
+
AccordionContent,
|
|
4621
|
+
{
|
|
4622
|
+
className: cn(
|
|
4623
|
+
bodyTextVariants({ size: "md" }),
|
|
4624
|
+
"font-normal [&_a]:text-primary-stroke-default [&_a]:underline",
|
|
4625
|
+
answerClassName
|
|
4626
|
+
),
|
|
4627
|
+
children: typeof faq.answer === "string" ? /* @__PURE__ */ jsx33("p", { children: faq.answer }) : faq.answer
|
|
4628
|
+
}
|
|
4629
|
+
)
|
|
4630
|
+
]
|
|
4631
|
+
},
|
|
4632
|
+
values[i]
|
|
4633
|
+
))
|
|
4619
4634
|
}
|
|
4620
4635
|
);
|
|
4621
4636
|
}
|
|
4622
|
-
|
|
4637
|
+
|
|
4638
|
+
// src/components/ui/form.tsx
|
|
4639
|
+
import * as React34 from "react";
|
|
4640
|
+
import "@radix-ui/react-label";
|
|
4641
|
+
import { Slot as Slot6 } from "@radix-ui/react-slot";
|
|
4642
|
+
import {
|
|
4643
|
+
Controller,
|
|
4644
|
+
FormProvider,
|
|
4645
|
+
useFormContext,
|
|
4646
|
+
useFormState
|
|
4647
|
+
} from "react-hook-form";
|
|
4648
|
+
|
|
4649
|
+
// src/components/ui/label.tsx
|
|
4650
|
+
import { Slot as Slot5 } from "@radix-ui/react-slot";
|
|
4651
|
+
import { cva as cva10 } from "class-variance-authority";
|
|
4652
|
+
import "react";
|
|
4653
|
+
import { jsx as jsx34 } from "react/jsx-runtime";
|
|
4654
|
+
var labelTextVariants = cva10("font-sans font-semibold text-vibrant-text-body", {
|
|
4655
|
+
variants: {
|
|
4656
|
+
size: {
|
|
4657
|
+
lg: "text-base md:text-lg md:leading-[1.625rem] leading-[1.5rem]",
|
|
4658
|
+
md: "md:text-base text-sm md:leading-[1.5rem] leading-[1.25rem] ",
|
|
4659
|
+
sm: "md:text-sm text-xs md:leading-[1.25rem] leading-[1.125rem] ",
|
|
4660
|
+
xs: "text-xs leading-[1.125rem]"
|
|
4661
|
+
}
|
|
4662
|
+
},
|
|
4663
|
+
defaultVariants: {
|
|
4664
|
+
size: "md"
|
|
4665
|
+
}
|
|
4666
|
+
});
|
|
4667
|
+
function Label3({
|
|
4623
4668
|
className,
|
|
4624
|
-
|
|
4669
|
+
size,
|
|
4670
|
+
asChild = false,
|
|
4625
4671
|
...props
|
|
4626
4672
|
}) {
|
|
4627
|
-
|
|
4628
|
-
|
|
4673
|
+
const Comp = asChild ? Slot5 : "label";
|
|
4674
|
+
return /* @__PURE__ */ jsx34(
|
|
4675
|
+
Comp,
|
|
4629
4676
|
{
|
|
4630
|
-
"data-slot": "
|
|
4631
|
-
className: cn(
|
|
4632
|
-
|
|
4633
|
-
className
|
|
4634
|
-
),
|
|
4635
|
-
...props,
|
|
4636
|
-
children: [
|
|
4637
|
-
/* @__PURE__ */ jsx36("span", { className: "pointer-events-none absolute left-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ jsx36(MenubarPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx36(CircleIcon3, { className: "size-2 fill-current" }) }) }),
|
|
4638
|
-
children
|
|
4639
|
-
]
|
|
4677
|
+
"data-slot": "label",
|
|
4678
|
+
className: cn(labelTextVariants({ size, className })),
|
|
4679
|
+
...props
|
|
4640
4680
|
}
|
|
4641
4681
|
);
|
|
4642
4682
|
}
|
|
4643
|
-
|
|
4644
|
-
|
|
4645
|
-
|
|
4683
|
+
|
|
4684
|
+
// src/components/ui/form.tsx
|
|
4685
|
+
import { jsx as jsx35 } from "react/jsx-runtime";
|
|
4686
|
+
var Form = FormProvider;
|
|
4687
|
+
var FormFieldContext = React34.createContext(
|
|
4688
|
+
{}
|
|
4689
|
+
);
|
|
4690
|
+
var FormField = ({
|
|
4646
4691
|
...props
|
|
4647
|
-
}) {
|
|
4648
|
-
return /* @__PURE__ */
|
|
4649
|
-
|
|
4692
|
+
}) => {
|
|
4693
|
+
return /* @__PURE__ */ jsx35(FormFieldContext.Provider, { value: { name: props.name }, children: /* @__PURE__ */ jsx35(Controller, { ...props }) });
|
|
4694
|
+
};
|
|
4695
|
+
var useFormField = () => {
|
|
4696
|
+
const fieldContext = React34.useContext(FormFieldContext);
|
|
4697
|
+
const itemContext = React34.useContext(FormItemContext);
|
|
4698
|
+
const { getFieldState } = useFormContext();
|
|
4699
|
+
const formState = useFormState({ name: fieldContext.name });
|
|
4700
|
+
const fieldState = getFieldState(fieldContext.name, formState);
|
|
4701
|
+
if (!fieldContext) {
|
|
4702
|
+
throw new Error("useFormField should be used within <FormField>");
|
|
4703
|
+
}
|
|
4704
|
+
const { id } = itemContext;
|
|
4705
|
+
return {
|
|
4706
|
+
id,
|
|
4707
|
+
name: fieldContext.name,
|
|
4708
|
+
formItemId: `${id}-form-item`,
|
|
4709
|
+
formDescriptionId: `${id}-form-item-description`,
|
|
4710
|
+
formMessageId: `${id}-form-item-message`,
|
|
4711
|
+
...fieldState
|
|
4712
|
+
};
|
|
4713
|
+
};
|
|
4714
|
+
var FormItemContext = React34.createContext(
|
|
4715
|
+
{}
|
|
4716
|
+
);
|
|
4717
|
+
function FormItem({ className, ...props }) {
|
|
4718
|
+
const id = React34.useId();
|
|
4719
|
+
return /* @__PURE__ */ jsx35(FormItemContext.Provider, { value: { id }, children: /* @__PURE__ */ jsx35(
|
|
4720
|
+
"div",
|
|
4650
4721
|
{
|
|
4651
|
-
"data-slot": "
|
|
4652
|
-
"
|
|
4653
|
-
className: cn(
|
|
4654
|
-
"px-2 py-1.5 text-sm font-medium data-[inset]:pl-8",
|
|
4655
|
-
className
|
|
4656
|
-
),
|
|
4722
|
+
"data-slot": "form-item",
|
|
4723
|
+
className: cn("grid gap-2", className),
|
|
4657
4724
|
...props
|
|
4658
4725
|
}
|
|
4659
|
-
);
|
|
4726
|
+
) });
|
|
4660
4727
|
}
|
|
4661
|
-
function
|
|
4728
|
+
function FormLabel({
|
|
4662
4729
|
className,
|
|
4663
4730
|
...props
|
|
4664
4731
|
}) {
|
|
4665
|
-
|
|
4666
|
-
|
|
4732
|
+
const { error, formItemId } = useFormField();
|
|
4733
|
+
return /* @__PURE__ */ jsx35(
|
|
4734
|
+
Label3,
|
|
4667
4735
|
{
|
|
4668
|
-
"data-slot": "
|
|
4669
|
-
|
|
4736
|
+
"data-slot": "form-label",
|
|
4737
|
+
"data-error": !!error,
|
|
4738
|
+
className: cn("data-[error=true]:text-destructive", className),
|
|
4739
|
+
htmlFor: formItemId,
|
|
4670
4740
|
...props
|
|
4671
4741
|
}
|
|
4672
4742
|
);
|
|
4673
4743
|
}
|
|
4674
|
-
function
|
|
4675
|
-
|
|
4676
|
-
|
|
4744
|
+
function FormControl({ ...props }) {
|
|
4745
|
+
const { error, formItemId, formDescriptionId, formMessageId } = useFormField();
|
|
4746
|
+
return /* @__PURE__ */ jsx35(
|
|
4747
|
+
Slot6,
|
|
4748
|
+
{
|
|
4749
|
+
"data-slot": "form-control",
|
|
4750
|
+
id: formItemId,
|
|
4751
|
+
"aria-describedby": !error ? `${formDescriptionId}` : `${formDescriptionId} ${formMessageId}`,
|
|
4752
|
+
"aria-invalid": !!error,
|
|
4753
|
+
...props
|
|
4754
|
+
}
|
|
4755
|
+
);
|
|
4756
|
+
}
|
|
4757
|
+
function FormDescription({ className, ...props }) {
|
|
4758
|
+
const { formDescriptionId } = useFormField();
|
|
4759
|
+
return /* @__PURE__ */ jsx35(
|
|
4760
|
+
"p",
|
|
4761
|
+
{
|
|
4762
|
+
"data-slot": "form-description",
|
|
4763
|
+
id: formDescriptionId,
|
|
4764
|
+
className: cn("text-muted-foreground text-sm", className),
|
|
4765
|
+
...props
|
|
4766
|
+
}
|
|
4767
|
+
);
|
|
4768
|
+
}
|
|
4769
|
+
function FormMessage({ className, ...props }) {
|
|
4770
|
+
const { error, formMessageId } = useFormField();
|
|
4771
|
+
const body = error ? String(error?.message ?? "") : props.children;
|
|
4772
|
+
if (!body) {
|
|
4773
|
+
return null;
|
|
4774
|
+
}
|
|
4775
|
+
return /* @__PURE__ */ jsx35(
|
|
4776
|
+
"p",
|
|
4777
|
+
{
|
|
4778
|
+
"data-slot": "form-message",
|
|
4779
|
+
id: formMessageId,
|
|
4780
|
+
className: cn("text-destructive text-sm", className),
|
|
4781
|
+
...props,
|
|
4782
|
+
children: body
|
|
4783
|
+
}
|
|
4784
|
+
);
|
|
4785
|
+
}
|
|
4786
|
+
|
|
4787
|
+
// src/components/ui/hover-card.tsx
|
|
4788
|
+
import "react";
|
|
4789
|
+
import * as HoverCardPrimitive from "@radix-ui/react-hover-card";
|
|
4790
|
+
import { jsx as jsx36 } from "react/jsx-runtime";
|
|
4791
|
+
function HoverCard({
|
|
4792
|
+
...props
|
|
4677
4793
|
}) {
|
|
4678
|
-
return /* @__PURE__ */ jsx36(
|
|
4679
|
-
|
|
4794
|
+
return /* @__PURE__ */ jsx36(HoverCardPrimitive.Root, { "data-slot": "hover-card", ...props });
|
|
4795
|
+
}
|
|
4796
|
+
function HoverCardTrigger({
|
|
4797
|
+
...props
|
|
4798
|
+
}) {
|
|
4799
|
+
return /* @__PURE__ */ jsx36(HoverCardPrimitive.Trigger, { "data-slot": "hover-card-trigger", ...props });
|
|
4800
|
+
}
|
|
4801
|
+
function HoverCardContent({
|
|
4802
|
+
className,
|
|
4803
|
+
align = "center",
|
|
4804
|
+
sideOffset = 4,
|
|
4805
|
+
...props
|
|
4806
|
+
}) {
|
|
4807
|
+
return /* @__PURE__ */ jsx36(HoverCardPrimitive.Portal, { "data-slot": "hover-card-portal", children: /* @__PURE__ */ jsx36(
|
|
4808
|
+
HoverCardPrimitive.Content,
|
|
4680
4809
|
{
|
|
4681
|
-
"data-slot": "
|
|
4810
|
+
"data-slot": "hover-card-content",
|
|
4811
|
+
align,
|
|
4812
|
+
sideOffset,
|
|
4682
4813
|
className: cn(
|
|
4683
|
-
"text-
|
|
4814
|
+
"bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 w-64 origin-(--radix-hover-card-content-transform-origin) rounded-md border p-4 shadow-md outline-hidden",
|
|
4684
4815
|
className
|
|
4685
4816
|
),
|
|
4686
4817
|
...props
|
|
4687
4818
|
}
|
|
4688
|
-
);
|
|
4819
|
+
) });
|
|
4689
4820
|
}
|
|
4690
|
-
|
|
4821
|
+
|
|
4822
|
+
// src/components/ui/input-otp.tsx
|
|
4823
|
+
import * as React36 from "react";
|
|
4824
|
+
import { OTPInput, OTPInputContext } from "input-otp";
|
|
4825
|
+
import { MinusIcon } from "lucide-react";
|
|
4826
|
+
import { jsx as jsx37, jsxs as jsxs20 } from "react/jsx-runtime";
|
|
4827
|
+
var InputOTPErrorContext = React36.createContext(false);
|
|
4828
|
+
function InputOTP({
|
|
4829
|
+
className,
|
|
4830
|
+
containerClassName,
|
|
4831
|
+
error,
|
|
4691
4832
|
...props
|
|
4692
4833
|
}) {
|
|
4693
|
-
return /* @__PURE__ */
|
|
4834
|
+
return /* @__PURE__ */ jsx37(InputOTPErrorContext.Provider, { value: error ?? false, children: /* @__PURE__ */ jsx37(
|
|
4835
|
+
OTPInput,
|
|
4836
|
+
{
|
|
4837
|
+
"data-slot": "input-otp",
|
|
4838
|
+
containerClassName: cn(
|
|
4839
|
+
"flex items-center gap-2 has-disabled:opacity-40",
|
|
4840
|
+
containerClassName
|
|
4841
|
+
),
|
|
4842
|
+
className: cn("disabled:cursor-not-allowed", className),
|
|
4843
|
+
...props
|
|
4844
|
+
}
|
|
4845
|
+
) });
|
|
4694
4846
|
}
|
|
4695
|
-
function
|
|
4847
|
+
function InputOTPGroup({ className, ...props }) {
|
|
4848
|
+
return /* @__PURE__ */ jsx37(
|
|
4849
|
+
"div",
|
|
4850
|
+
{
|
|
4851
|
+
"data-slot": "input-otp-group",
|
|
4852
|
+
className: cn("flex items-center", className),
|
|
4853
|
+
...props
|
|
4854
|
+
}
|
|
4855
|
+
);
|
|
4856
|
+
}
|
|
4857
|
+
function InputOTPSlot({
|
|
4858
|
+
index,
|
|
4696
4859
|
className,
|
|
4697
|
-
inset,
|
|
4698
|
-
children,
|
|
4699
4860
|
...props
|
|
4700
4861
|
}) {
|
|
4862
|
+
const inputOTPContext = React36.useContext(OTPInputContext);
|
|
4863
|
+
const { char, hasFakeCaret, isActive } = inputOTPContext?.slots[index] ?? {};
|
|
4864
|
+
const isHovering = inputOTPContext?.isHovering ?? false;
|
|
4865
|
+
const error = React36.useContext(InputOTPErrorContext);
|
|
4701
4866
|
return /* @__PURE__ */ jsxs20(
|
|
4702
|
-
|
|
4867
|
+
"div",
|
|
4703
4868
|
{
|
|
4704
|
-
"data-slot": "
|
|
4705
|
-
"data-
|
|
4869
|
+
"data-slot": "input-otp-slot",
|
|
4870
|
+
"data-active": isActive,
|
|
4706
4871
|
className: cn(
|
|
4707
|
-
|
|
4872
|
+
// Base layout & typography
|
|
4873
|
+
"relative flex size-10 items-center justify-center",
|
|
4874
|
+
"border-y border-r first:border-l text-sm font-medium leading-5",
|
|
4875
|
+
"transition-all outline-none",
|
|
4876
|
+
"first:rounded-l-[4px] last:rounded-r-[4px]",
|
|
4877
|
+
"text-foreground",
|
|
4878
|
+
// Default state (no error)
|
|
4879
|
+
!error && "border-gray-stroke-default bg-background",
|
|
4880
|
+
// Hover: all slots turn blue (non-error, non-active)
|
|
4881
|
+
!error && isHovering && !isActive && "border-focus-ring",
|
|
4882
|
+
// Active slot (non-error): 2px blue border
|
|
4883
|
+
!error && isActive && "z-10 border-2 border-focus-ring",
|
|
4884
|
+
// Error (non-active)
|
|
4885
|
+
error && !isActive && "border-error-stroke-default bg-error-surface-subtle",
|
|
4886
|
+
// Error + active
|
|
4887
|
+
error && isActive && "z-10 border-2 border-error-stroke-default bg-error-surface-subtle",
|
|
4708
4888
|
className
|
|
4709
4889
|
),
|
|
4710
4890
|
...props,
|
|
4711
4891
|
children: [
|
|
4712
|
-
|
|
4713
|
-
/* @__PURE__ */
|
|
4892
|
+
char,
|
|
4893
|
+
hasFakeCaret && /* @__PURE__ */ jsx37("div", { className: "pointer-events-none absolute inset-0 flex items-center justify-center", children: /* @__PURE__ */ jsx37("div", { className: "animate-caret-blink bg-focus-ring h-4 w-px duration-1000" }) })
|
|
4714
4894
|
]
|
|
4715
4895
|
}
|
|
4716
4896
|
);
|
|
4717
4897
|
}
|
|
4718
|
-
function
|
|
4898
|
+
function InputOTPSeparator({ ...props }) {
|
|
4899
|
+
return /* @__PURE__ */ jsx37("div", { "data-slot": "input-otp-separator", role: "separator", ...props, children: /* @__PURE__ */ jsx37(MinusIcon, {}) });
|
|
4900
|
+
}
|
|
4901
|
+
|
|
4902
|
+
// src/components/ui/menubar.tsx
|
|
4903
|
+
import "react";
|
|
4904
|
+
import * as MenubarPrimitive from "@radix-ui/react-menubar";
|
|
4905
|
+
import { CheckIcon as CheckIcon3, ChevronRightIcon as ChevronRightIcon4, CircleIcon as CircleIcon3 } from "lucide-react";
|
|
4906
|
+
import { jsx as jsx38, jsxs as jsxs21 } from "react/jsx-runtime";
|
|
4907
|
+
function Menubar({
|
|
4719
4908
|
className,
|
|
4720
4909
|
...props
|
|
4721
4910
|
}) {
|
|
4722
|
-
return /* @__PURE__ */
|
|
4723
|
-
MenubarPrimitive.
|
|
4911
|
+
return /* @__PURE__ */ jsx38(
|
|
4912
|
+
MenubarPrimitive.Root,
|
|
4724
4913
|
{
|
|
4725
|
-
"data-slot": "menubar
|
|
4914
|
+
"data-slot": "menubar",
|
|
4726
4915
|
className: cn(
|
|
4727
|
-
"bg-
|
|
4916
|
+
"bg-background flex h-9 items-center gap-1 rounded-md border p-1 shadow-xs",
|
|
4728
4917
|
className
|
|
4729
4918
|
),
|
|
4730
4919
|
...props
|
|
4731
4920
|
}
|
|
4732
4921
|
);
|
|
4733
4922
|
}
|
|
4734
|
-
|
|
4735
|
-
|
|
4736
|
-
|
|
4737
|
-
|
|
4738
|
-
|
|
4739
|
-
|
|
4740
|
-
|
|
4923
|
+
function MenubarMenu({
|
|
4924
|
+
...props
|
|
4925
|
+
}) {
|
|
4926
|
+
return /* @__PURE__ */ jsx38(MenubarPrimitive.Menu, { "data-slot": "menubar-menu", ...props });
|
|
4927
|
+
}
|
|
4928
|
+
function MenubarGroup({
|
|
4929
|
+
...props
|
|
4930
|
+
}) {
|
|
4931
|
+
return /* @__PURE__ */ jsx38(MenubarPrimitive.Group, { "data-slot": "menubar-group", ...props });
|
|
4932
|
+
}
|
|
4933
|
+
function MenubarPortal({
|
|
4934
|
+
...props
|
|
4935
|
+
}) {
|
|
4936
|
+
return /* @__PURE__ */ jsx38(MenubarPrimitive.Portal, { "data-slot": "menubar-portal", ...props });
|
|
4937
|
+
}
|
|
4938
|
+
function MenubarRadioGroup({
|
|
4939
|
+
...props
|
|
4940
|
+
}) {
|
|
4941
|
+
return /* @__PURE__ */ jsx38(MenubarPrimitive.RadioGroup, { "data-slot": "menubar-radio-group", ...props });
|
|
4942
|
+
}
|
|
4943
|
+
function MenubarTrigger({
|
|
4944
|
+
className,
|
|
4945
|
+
...props
|
|
4946
|
+
}) {
|
|
4947
|
+
return /* @__PURE__ */ jsx38(
|
|
4948
|
+
MenubarPrimitive.Trigger,
|
|
4949
|
+
{
|
|
4950
|
+
"data-slot": "menubar-trigger",
|
|
4951
|
+
className: cn(
|
|
4952
|
+
"focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground flex items-center rounded-sm px-2 py-1 text-sm font-medium outline-hidden select-none",
|
|
4953
|
+
className
|
|
4954
|
+
),
|
|
4955
|
+
...props
|
|
4956
|
+
}
|
|
4957
|
+
);
|
|
4958
|
+
}
|
|
4959
|
+
function MenubarContent({
|
|
4960
|
+
className,
|
|
4961
|
+
align = "start",
|
|
4962
|
+
alignOffset = -4,
|
|
4963
|
+
sideOffset = 8,
|
|
4964
|
+
...props
|
|
4965
|
+
}) {
|
|
4966
|
+
return /* @__PURE__ */ jsx38(MenubarPortal, { children: /* @__PURE__ */ jsx38(
|
|
4967
|
+
MenubarPrimitive.Content,
|
|
4968
|
+
{
|
|
4969
|
+
"data-slot": "menubar-content",
|
|
4970
|
+
align,
|
|
4971
|
+
alignOffset,
|
|
4972
|
+
sideOffset,
|
|
4973
|
+
className: cn(
|
|
4974
|
+
"bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 min-w-[12rem] origin-(--radix-menubar-content-transform-origin) overflow-hidden rounded-md border p-1 shadow-md",
|
|
4975
|
+
className
|
|
4976
|
+
),
|
|
4977
|
+
...props
|
|
4978
|
+
}
|
|
4979
|
+
) });
|
|
4980
|
+
}
|
|
4981
|
+
function MenubarItem({
|
|
4982
|
+
className,
|
|
4983
|
+
inset,
|
|
4984
|
+
variant = "default",
|
|
4985
|
+
...props
|
|
4986
|
+
}) {
|
|
4987
|
+
return /* @__PURE__ */ jsx38(
|
|
4988
|
+
MenubarPrimitive.Item,
|
|
4989
|
+
{
|
|
4990
|
+
"data-slot": "menubar-item",
|
|
4991
|
+
"data-inset": inset,
|
|
4992
|
+
"data-variant": variant,
|
|
4993
|
+
className: cn(
|
|
4994
|
+
"focus:bg-accent focus:text-accent-foreground data-[variant=destructive]:text-destructive data-[variant=destructive]:focus:bg-destructive/10 dark:data-[variant=destructive]:focus:bg-destructive/20 data-[variant=destructive]:focus:text-destructive data-[variant=destructive]:*:[svg]:!text-destructive [&_svg:not([class*='text-'])]:text-muted-foreground relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 data-[inset]:pl-8 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
|
|
4995
|
+
className
|
|
4996
|
+
),
|
|
4997
|
+
...props
|
|
4998
|
+
}
|
|
4999
|
+
);
|
|
5000
|
+
}
|
|
5001
|
+
function MenubarCheckboxItem({
|
|
5002
|
+
className,
|
|
5003
|
+
children,
|
|
5004
|
+
checked,
|
|
5005
|
+
...props
|
|
5006
|
+
}) {
|
|
4741
5007
|
return /* @__PURE__ */ jsxs21(
|
|
4742
|
-
|
|
5008
|
+
MenubarPrimitive.CheckboxItem,
|
|
4743
5009
|
{
|
|
4744
|
-
"data-slot": "
|
|
4745
|
-
className:
|
|
5010
|
+
"data-slot": "menubar-checkbox-item",
|
|
5011
|
+
className: cn(
|
|
5012
|
+
"focus:bg-accent focus:text-accent-foreground relative flex cursor-default items-center gap-2 rounded-xs py-1.5 pr-2 pl-8 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
|
|
5013
|
+
className
|
|
5014
|
+
),
|
|
5015
|
+
checked,
|
|
5016
|
+
...props,
|
|
4746
5017
|
children: [
|
|
4747
|
-
|
|
4748
|
-
|
|
4749
|
-
"button",
|
|
4750
|
-
{
|
|
4751
|
-
type: "button",
|
|
4752
|
-
onClick: (e) => {
|
|
4753
|
-
e.stopPropagation();
|
|
4754
|
-
onRemove();
|
|
4755
|
-
},
|
|
4756
|
-
className: "flex items-center justify-center size-[20px] text-primary-stroke-default hover:text-primary-surface-default transition-colors cursor-pointer",
|
|
4757
|
-
"aria-label": `Remove ${label}`,
|
|
4758
|
-
children: /* @__PURE__ */ jsx37(X3, { className: "size-[16px]" })
|
|
4759
|
-
}
|
|
4760
|
-
)
|
|
5018
|
+
/* @__PURE__ */ jsx38("span", { className: "pointer-events-none absolute left-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ jsx38(MenubarPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx38(CheckIcon3, { className: "size-4" }) }) }),
|
|
5019
|
+
children
|
|
4761
5020
|
]
|
|
4762
5021
|
}
|
|
4763
5022
|
);
|
|
4764
5023
|
}
|
|
4765
|
-
function
|
|
5024
|
+
function MenubarRadioItem({
|
|
5025
|
+
className,
|
|
5026
|
+
children,
|
|
5027
|
+
...props
|
|
5028
|
+
}) {
|
|
5029
|
+
return /* @__PURE__ */ jsxs21(
|
|
5030
|
+
MenubarPrimitive.RadioItem,
|
|
5031
|
+
{
|
|
5032
|
+
"data-slot": "menubar-radio-item",
|
|
5033
|
+
className: cn(
|
|
5034
|
+
"focus:bg-accent focus:text-accent-foreground relative flex cursor-default items-center gap-2 rounded-xs py-1.5 pr-2 pl-8 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
|
|
5035
|
+
className
|
|
5036
|
+
),
|
|
5037
|
+
...props,
|
|
5038
|
+
children: [
|
|
5039
|
+
/* @__PURE__ */ jsx38("span", { className: "pointer-events-none absolute left-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ jsx38(MenubarPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx38(CircleIcon3, { className: "size-2 fill-current" }) }) }),
|
|
5040
|
+
children
|
|
5041
|
+
]
|
|
5042
|
+
}
|
|
5043
|
+
);
|
|
5044
|
+
}
|
|
5045
|
+
function MenubarLabel({
|
|
5046
|
+
className,
|
|
5047
|
+
inset,
|
|
5048
|
+
...props
|
|
5049
|
+
}) {
|
|
5050
|
+
return /* @__PURE__ */ jsx38(
|
|
5051
|
+
MenubarPrimitive.Label,
|
|
5052
|
+
{
|
|
5053
|
+
"data-slot": "menubar-label",
|
|
5054
|
+
"data-inset": inset,
|
|
5055
|
+
className: cn(
|
|
5056
|
+
"px-2 py-1.5 text-sm font-medium data-[inset]:pl-8",
|
|
5057
|
+
className
|
|
5058
|
+
),
|
|
5059
|
+
...props
|
|
5060
|
+
}
|
|
5061
|
+
);
|
|
5062
|
+
}
|
|
5063
|
+
function MenubarSeparator({
|
|
5064
|
+
className,
|
|
5065
|
+
...props
|
|
5066
|
+
}) {
|
|
5067
|
+
return /* @__PURE__ */ jsx38(
|
|
5068
|
+
MenubarPrimitive.Separator,
|
|
5069
|
+
{
|
|
5070
|
+
"data-slot": "menubar-separator",
|
|
5071
|
+
className: cn("bg-border -mx-1 my-1 h-px", className),
|
|
5072
|
+
...props
|
|
5073
|
+
}
|
|
5074
|
+
);
|
|
5075
|
+
}
|
|
5076
|
+
function MenubarShortcut({
|
|
5077
|
+
className,
|
|
5078
|
+
...props
|
|
5079
|
+
}) {
|
|
5080
|
+
return /* @__PURE__ */ jsx38(
|
|
5081
|
+
"span",
|
|
5082
|
+
{
|
|
5083
|
+
"data-slot": "menubar-shortcut",
|
|
5084
|
+
className: cn(
|
|
5085
|
+
"text-muted-foreground ml-auto text-xs tracking-widest",
|
|
5086
|
+
className
|
|
5087
|
+
),
|
|
5088
|
+
...props
|
|
5089
|
+
}
|
|
5090
|
+
);
|
|
5091
|
+
}
|
|
5092
|
+
function MenubarSub({
|
|
5093
|
+
...props
|
|
5094
|
+
}) {
|
|
5095
|
+
return /* @__PURE__ */ jsx38(MenubarPrimitive.Sub, { "data-slot": "menubar-sub", ...props });
|
|
5096
|
+
}
|
|
5097
|
+
function MenubarSubTrigger({
|
|
5098
|
+
className,
|
|
5099
|
+
inset,
|
|
5100
|
+
children,
|
|
5101
|
+
...props
|
|
5102
|
+
}) {
|
|
5103
|
+
return /* @__PURE__ */ jsxs21(
|
|
5104
|
+
MenubarPrimitive.SubTrigger,
|
|
5105
|
+
{
|
|
5106
|
+
"data-slot": "menubar-sub-trigger",
|
|
5107
|
+
"data-inset": inset,
|
|
5108
|
+
className: cn(
|
|
5109
|
+
"focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground flex cursor-default items-center rounded-sm px-2 py-1.5 text-sm outline-none select-none data-[inset]:pl-8",
|
|
5110
|
+
className
|
|
5111
|
+
),
|
|
5112
|
+
...props,
|
|
5113
|
+
children: [
|
|
5114
|
+
children,
|
|
5115
|
+
/* @__PURE__ */ jsx38(ChevronRightIcon4, { className: "ml-auto h-4 w-4" })
|
|
5116
|
+
]
|
|
5117
|
+
}
|
|
5118
|
+
);
|
|
5119
|
+
}
|
|
5120
|
+
function MenubarSubContent({
|
|
5121
|
+
className,
|
|
5122
|
+
...props
|
|
5123
|
+
}) {
|
|
5124
|
+
return /* @__PURE__ */ jsx38(
|
|
5125
|
+
MenubarPrimitive.SubContent,
|
|
5126
|
+
{
|
|
5127
|
+
"data-slot": "menubar-sub-content",
|
|
5128
|
+
className: cn(
|
|
5129
|
+
"bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 min-w-[8rem] origin-(--radix-menubar-content-transform-origin) overflow-hidden rounded-md border p-1 shadow-lg",
|
|
5130
|
+
className
|
|
5131
|
+
),
|
|
5132
|
+
...props
|
|
5133
|
+
}
|
|
5134
|
+
);
|
|
5135
|
+
}
|
|
5136
|
+
|
|
5137
|
+
// src/components/ui/multi-select-free-text.tsx
|
|
5138
|
+
import * as React38 from "react";
|
|
5139
|
+
import * as PopoverPrimitive4 from "@radix-ui/react-popover";
|
|
5140
|
+
import { ChevronDown as ChevronDown2, X as X3 } from "lucide-react";
|
|
5141
|
+
import { jsx as jsx39, jsxs as jsxs22 } from "react/jsx-runtime";
|
|
5142
|
+
function Tag({ label, onRemove }) {
|
|
5143
|
+
return /* @__PURE__ */ jsxs22(
|
|
5144
|
+
"span",
|
|
5145
|
+
{
|
|
5146
|
+
"data-slot": "multi-select-tag",
|
|
5147
|
+
className: "inline-flex items-center gap-[8px] h-[32px] px-[12px] py-[8px] rounded-[8px] bg-primary-surface-subtle font-sans font-medium text-[14px] leading-[20px] text-primary-stroke-default shrink-0",
|
|
5148
|
+
children: [
|
|
5149
|
+
label,
|
|
5150
|
+
/* @__PURE__ */ jsx39(
|
|
5151
|
+
"button",
|
|
5152
|
+
{
|
|
5153
|
+
type: "button",
|
|
5154
|
+
onClick: (e) => {
|
|
5155
|
+
e.stopPropagation();
|
|
5156
|
+
onRemove();
|
|
5157
|
+
},
|
|
5158
|
+
className: "flex items-center justify-center size-[20px] text-primary-stroke-default hover:text-primary-surface-default transition-colors cursor-pointer",
|
|
5159
|
+
"aria-label": `Remove ${label}`,
|
|
5160
|
+
children: /* @__PURE__ */ jsx39(X3, { className: "size-[16px]" })
|
|
5161
|
+
}
|
|
5162
|
+
)
|
|
5163
|
+
]
|
|
5164
|
+
}
|
|
5165
|
+
);
|
|
5166
|
+
}
|
|
5167
|
+
function MultiSelectFreeText({
|
|
4766
5168
|
values: valuesProp,
|
|
4767
5169
|
defaultValues = [],
|
|
4768
5170
|
onValuesChange,
|
|
@@ -4774,22 +5176,22 @@ function MultiSelectFreeText({
|
|
|
4774
5176
|
disabled = false,
|
|
4775
5177
|
className
|
|
4776
5178
|
}) {
|
|
4777
|
-
const [internalValues, setInternalValues] =
|
|
4778
|
-
const [inputValue, setInputValue] =
|
|
4779
|
-
const [open, setOpen] =
|
|
4780
|
-
const [highlightedIndex, setHighlightedIndex] =
|
|
4781
|
-
const inputRef =
|
|
4782
|
-
const triggerRef =
|
|
5179
|
+
const [internalValues, setInternalValues] = React38.useState(defaultValues);
|
|
5180
|
+
const [inputValue, setInputValue] = React38.useState("");
|
|
5181
|
+
const [open, setOpen] = React38.useState(false);
|
|
5182
|
+
const [highlightedIndex, setHighlightedIndex] = React38.useState(-1);
|
|
5183
|
+
const inputRef = React38.useRef(null);
|
|
5184
|
+
const triggerRef = React38.useRef(null);
|
|
4783
5185
|
const isControlled = valuesProp !== void 0;
|
|
4784
5186
|
const values = isControlled ? valuesProp : internalValues;
|
|
4785
|
-
const updateValues =
|
|
5187
|
+
const updateValues = React38.useCallback(
|
|
4786
5188
|
(next) => {
|
|
4787
5189
|
if (!isControlled) setInternalValues(next);
|
|
4788
5190
|
onValuesChange?.(next);
|
|
4789
5191
|
},
|
|
4790
5192
|
[isControlled, onValuesChange]
|
|
4791
5193
|
);
|
|
4792
|
-
const addTag =
|
|
5194
|
+
const addTag = React38.useCallback(
|
|
4793
5195
|
(tag) => {
|
|
4794
5196
|
const trimmed = tag.trim();
|
|
4795
5197
|
if (!trimmed || values.includes(trimmed)) return;
|
|
@@ -4799,19 +5201,19 @@ function MultiSelectFreeText({
|
|
|
4799
5201
|
},
|
|
4800
5202
|
[values, updateValues]
|
|
4801
5203
|
);
|
|
4802
|
-
const removeTag =
|
|
5204
|
+
const removeTag = React38.useCallback(
|
|
4803
5205
|
(tag) => {
|
|
4804
5206
|
updateValues(values.filter((v) => v !== tag));
|
|
4805
5207
|
},
|
|
4806
5208
|
[values, updateValues]
|
|
4807
5209
|
);
|
|
4808
|
-
const filteredOptions =
|
|
5210
|
+
const filteredOptions = React38.useMemo(() => {
|
|
4809
5211
|
const lower = inputValue.toLowerCase();
|
|
4810
5212
|
return options.filter(
|
|
4811
5213
|
(opt) => !values.includes(opt.value) && (lower === "" || opt.label.toLowerCase().includes(lower))
|
|
4812
5214
|
);
|
|
4813
5215
|
}, [options, inputValue, values]);
|
|
4814
|
-
const handleKeyDown =
|
|
5216
|
+
const handleKeyDown = React38.useCallback(
|
|
4815
5217
|
(e) => {
|
|
4816
5218
|
if (e.key === "Enter") {
|
|
4817
5219
|
e.preventDefault();
|
|
@@ -4843,7 +5245,7 @@ function MultiSelectFreeText({
|
|
|
4843
5245
|
},
|
|
4844
5246
|
[highlightedIndex, filteredOptions, inputValue, values, addTag, removeTag, open]
|
|
4845
5247
|
);
|
|
4846
|
-
const handleInputChange =
|
|
5248
|
+
const handleInputChange = React38.useCallback(
|
|
4847
5249
|
(e) => {
|
|
4848
5250
|
setInputValue(e.target.value);
|
|
4849
5251
|
if (!open) setOpen(true);
|
|
@@ -4851,30 +5253,30 @@ function MultiSelectFreeText({
|
|
|
4851
5253
|
},
|
|
4852
5254
|
[open]
|
|
4853
5255
|
);
|
|
4854
|
-
const handleOptionClick =
|
|
5256
|
+
const handleOptionClick = React38.useCallback(
|
|
4855
5257
|
(optValue) => {
|
|
4856
5258
|
addTag(optValue);
|
|
4857
5259
|
inputRef.current?.focus();
|
|
4858
5260
|
},
|
|
4859
5261
|
[addTag]
|
|
4860
5262
|
);
|
|
4861
|
-
const handleTriggerClick =
|
|
5263
|
+
const handleTriggerClick = React38.useCallback(() => {
|
|
4862
5264
|
if (disabled) return;
|
|
4863
5265
|
inputRef.current?.focus();
|
|
4864
5266
|
if (!open) setOpen(true);
|
|
4865
5267
|
}, [disabled, open]);
|
|
4866
5268
|
const isFocused = open;
|
|
4867
|
-
return /* @__PURE__ */
|
|
5269
|
+
return /* @__PURE__ */ jsx39(PopoverPrimitive4.Root, { open, onOpenChange: disabled ? void 0 : setOpen, children: /* @__PURE__ */ jsxs22(
|
|
4868
5270
|
"div",
|
|
4869
5271
|
{
|
|
4870
5272
|
"data-slot": "multi-select-free-text",
|
|
4871
5273
|
className: cn("flex flex-col gap-[8px] items-start w-full", className),
|
|
4872
5274
|
children: [
|
|
4873
|
-
label && /* @__PURE__ */
|
|
5275
|
+
label && /* @__PURE__ */ jsxs22("div", { className: "flex items-center font-sans font-medium text-[14px] leading-[20px] text-vibrant-text-details", children: [
|
|
4874
5276
|
label,
|
|
4875
|
-
mandatory && /* @__PURE__ */
|
|
5277
|
+
mandatory && /* @__PURE__ */ jsx39("span", { className: "text-error-surface-default ml-0.5 text-[14px] leading-[20px]", children: "*" })
|
|
4876
5278
|
] }),
|
|
4877
|
-
/* @__PURE__ */
|
|
5279
|
+
/* @__PURE__ */ jsx39(PopoverPrimitive4.Anchor, { asChild: true, children: /* @__PURE__ */ jsxs22(
|
|
4878
5280
|
"div",
|
|
4879
5281
|
{
|
|
4880
5282
|
ref: triggerRef,
|
|
@@ -4886,10 +5288,10 @@ function MultiSelectFreeText({
|
|
|
4886
5288
|
disabled && "opacity-60 cursor-not-allowed"
|
|
4887
5289
|
),
|
|
4888
5290
|
children: [
|
|
4889
|
-
icon && /* @__PURE__ */
|
|
4890
|
-
/* @__PURE__ */
|
|
4891
|
-
values.map((tag) => /* @__PURE__ */
|
|
4892
|
-
/* @__PURE__ */
|
|
5291
|
+
icon && /* @__PURE__ */ jsx39("span", { className: "flex items-center justify-center shrink-0 size-[20px] [&_svg]:size-[20px] text-muted-foreground", children: icon }),
|
|
5292
|
+
/* @__PURE__ */ jsxs22("div", { className: "flex flex-wrap items-center gap-[8px] flex-1 min-w-0", children: [
|
|
5293
|
+
values.map((tag) => /* @__PURE__ */ jsx39(Tag, { label: tag, onRemove: () => removeTag(tag) }, tag)),
|
|
5294
|
+
/* @__PURE__ */ jsx39(
|
|
4893
5295
|
"input",
|
|
4894
5296
|
{
|
|
4895
5297
|
ref: inputRef,
|
|
@@ -4909,7 +5311,7 @@ function MultiSelectFreeText({
|
|
|
4909
5311
|
}
|
|
4910
5312
|
)
|
|
4911
5313
|
] }),
|
|
4912
|
-
/* @__PURE__ */
|
|
5314
|
+
/* @__PURE__ */ jsx39(
|
|
4913
5315
|
ChevronDown2,
|
|
4914
5316
|
{
|
|
4915
5317
|
className: cn(
|
|
@@ -4921,7 +5323,7 @@ function MultiSelectFreeText({
|
|
|
4921
5323
|
]
|
|
4922
5324
|
}
|
|
4923
5325
|
) }),
|
|
4924
|
-
/* @__PURE__ */
|
|
5326
|
+
/* @__PURE__ */ jsx39(PopoverPrimitive4.Portal, { children: /* @__PURE__ */ jsx39(
|
|
4925
5327
|
PopoverPrimitive4.Content,
|
|
4926
5328
|
{
|
|
4927
5329
|
"data-slot": "multi-select-free-text-content",
|
|
@@ -4935,10 +5337,10 @@ function MultiSelectFreeText({
|
|
|
4935
5337
|
"[&::-webkit-scrollbar]:w-[5px] [&::-webkit-scrollbar-track]:rounded-[3px] [&::-webkit-scrollbar-track]:bg-gray-surface-light [&::-webkit-scrollbar-thumb]:rounded-[3px] [&::-webkit-scrollbar-thumb]:bg-gray-surface-default",
|
|
4936
5338
|
"data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=top]:slide-in-from-bottom-2"
|
|
4937
5339
|
),
|
|
4938
|
-
children: /* @__PURE__ */
|
|
5340
|
+
children: /* @__PURE__ */ jsxs22("div", { role: "listbox", className: "flex flex-col", children: [
|
|
4939
5341
|
inputValue.trim() !== "" && !options.some(
|
|
4940
5342
|
(o) => o.label.toLowerCase() === inputValue.toLowerCase()
|
|
4941
|
-
) && /* @__PURE__ */
|
|
5343
|
+
) && /* @__PURE__ */ jsx39(
|
|
4942
5344
|
"div",
|
|
4943
5345
|
{
|
|
4944
5346
|
role: "option",
|
|
@@ -4955,7 +5357,7 @@ function MultiSelectFreeText({
|
|
|
4955
5357
|
children: inputValue.trim()
|
|
4956
5358
|
}
|
|
4957
5359
|
),
|
|
4958
|
-
filteredOptions.map((opt, idx) => /* @__PURE__ */
|
|
5360
|
+
filteredOptions.map((opt, idx) => /* @__PURE__ */ jsx39(
|
|
4959
5361
|
"div",
|
|
4960
5362
|
{
|
|
4961
5363
|
role: "option",
|
|
@@ -4973,7 +5375,7 @@ function MultiSelectFreeText({
|
|
|
4973
5375
|
},
|
|
4974
5376
|
opt.value
|
|
4975
5377
|
)),
|
|
4976
|
-
filteredOptions.length === 0 && inputValue.trim() === "" && /* @__PURE__ */
|
|
5378
|
+
filteredOptions.length === 0 && inputValue.trim() === "" && /* @__PURE__ */ jsx39("div", { className: "flex items-center h-[48px] px-[8px] font-sans font-medium text-[14px] leading-[20px] text-muted-foreground", children: "No options available" })
|
|
4977
5379
|
] })
|
|
4978
5380
|
}
|
|
4979
5381
|
) })
|
|
@@ -4985,16 +5387,16 @@ function MultiSelectFreeText({
|
|
|
4985
5387
|
// src/components/ui/navigation-menu.tsx
|
|
4986
5388
|
import "react";
|
|
4987
5389
|
import * as NavigationMenuPrimitive from "@radix-ui/react-navigation-menu";
|
|
4988
|
-
import { cva as
|
|
5390
|
+
import { cva as cva11 } from "class-variance-authority";
|
|
4989
5391
|
import { ChevronDownIcon as ChevronDownIcon3 } from "lucide-react";
|
|
4990
|
-
import { jsx as
|
|
5392
|
+
import { jsx as jsx40, jsxs as jsxs23 } from "react/jsx-runtime";
|
|
4991
5393
|
function NavigationMenu({
|
|
4992
5394
|
className,
|
|
4993
5395
|
children,
|
|
4994
5396
|
viewport = true,
|
|
4995
5397
|
...props
|
|
4996
5398
|
}) {
|
|
4997
|
-
return /* @__PURE__ */
|
|
5399
|
+
return /* @__PURE__ */ jsxs23(
|
|
4998
5400
|
NavigationMenuPrimitive.Root,
|
|
4999
5401
|
{
|
|
5000
5402
|
"data-slot": "navigation-menu",
|
|
@@ -5006,7 +5408,7 @@ function NavigationMenu({
|
|
|
5006
5408
|
...props,
|
|
5007
5409
|
children: [
|
|
5008
5410
|
children,
|
|
5009
|
-
viewport && /* @__PURE__ */
|
|
5411
|
+
viewport && /* @__PURE__ */ jsx40(NavigationMenuViewport, {})
|
|
5010
5412
|
]
|
|
5011
5413
|
}
|
|
5012
5414
|
);
|
|
@@ -5015,7 +5417,7 @@ function NavigationMenuList({
|
|
|
5015
5417
|
className,
|
|
5016
5418
|
...props
|
|
5017
5419
|
}) {
|
|
5018
|
-
return /* @__PURE__ */
|
|
5420
|
+
return /* @__PURE__ */ jsx40(
|
|
5019
5421
|
NavigationMenuPrimitive.List,
|
|
5020
5422
|
{
|
|
5021
5423
|
"data-slot": "navigation-menu-list",
|
|
@@ -5031,7 +5433,7 @@ function NavigationMenuItem({
|
|
|
5031
5433
|
className,
|
|
5032
5434
|
...props
|
|
5033
5435
|
}) {
|
|
5034
|
-
return /* @__PURE__ */
|
|
5436
|
+
return /* @__PURE__ */ jsx40(
|
|
5035
5437
|
NavigationMenuPrimitive.Item,
|
|
5036
5438
|
{
|
|
5037
5439
|
"data-slot": "navigation-menu-item",
|
|
@@ -5040,7 +5442,7 @@ function NavigationMenuItem({
|
|
|
5040
5442
|
}
|
|
5041
5443
|
);
|
|
5042
5444
|
}
|
|
5043
|
-
var navigationMenuTriggerStyle =
|
|
5445
|
+
var navigationMenuTriggerStyle = cva11(
|
|
5044
5446
|
"group inline-flex h-9 w-max items-center justify-center rounded-md bg-background px-4 py-2 text-sm font-medium hover:bg-accent hover:text-accent-foreground focus:bg-accent focus:text-accent-foreground disabled:pointer-events-none disabled:opacity-50 data-[state=open]:hover:bg-accent data-[state=open]:text-accent-foreground data-[state=open]:focus:bg-accent data-[state=open]:bg-accent/50 focus-visible:ring-ring/50 outline-none transition-[color,box-shadow] focus-visible:ring-[3px] focus-visible:outline-1"
|
|
5045
5447
|
);
|
|
5046
5448
|
function NavigationMenuTrigger({
|
|
@@ -5048,7 +5450,7 @@ function NavigationMenuTrigger({
|
|
|
5048
5450
|
children,
|
|
5049
5451
|
...props
|
|
5050
5452
|
}) {
|
|
5051
|
-
return /* @__PURE__ */
|
|
5453
|
+
return /* @__PURE__ */ jsxs23(
|
|
5052
5454
|
NavigationMenuPrimitive.Trigger,
|
|
5053
5455
|
{
|
|
5054
5456
|
"data-slot": "navigation-menu-trigger",
|
|
@@ -5057,7 +5459,7 @@ function NavigationMenuTrigger({
|
|
|
5057
5459
|
children: [
|
|
5058
5460
|
children,
|
|
5059
5461
|
" ",
|
|
5060
|
-
/* @__PURE__ */
|
|
5462
|
+
/* @__PURE__ */ jsx40(
|
|
5061
5463
|
ChevronDownIcon3,
|
|
5062
5464
|
{
|
|
5063
5465
|
className: "relative top-[1px] ml-1 size-3 transition duration-400 group-data-[state=open]:rotate-180",
|
|
@@ -5072,7 +5474,7 @@ function NavigationMenuContent({
|
|
|
5072
5474
|
className,
|
|
5073
5475
|
...props
|
|
5074
5476
|
}) {
|
|
5075
|
-
return /* @__PURE__ */
|
|
5477
|
+
return /* @__PURE__ */ jsx40(
|
|
5076
5478
|
NavigationMenuPrimitive.Content,
|
|
5077
5479
|
{
|
|
5078
5480
|
"data-slot": "navigation-menu-content",
|
|
@@ -5089,13 +5491,13 @@ function NavigationMenuViewport({
|
|
|
5089
5491
|
className,
|
|
5090
5492
|
...props
|
|
5091
5493
|
}) {
|
|
5092
|
-
return /* @__PURE__ */
|
|
5494
|
+
return /* @__PURE__ */ jsx40(
|
|
5093
5495
|
"div",
|
|
5094
5496
|
{
|
|
5095
5497
|
className: cn(
|
|
5096
5498
|
"absolute top-full left-0 isolate z-50 flex justify-center"
|
|
5097
5499
|
),
|
|
5098
|
-
children: /* @__PURE__ */
|
|
5500
|
+
children: /* @__PURE__ */ jsx40(
|
|
5099
5501
|
NavigationMenuPrimitive.Viewport,
|
|
5100
5502
|
{
|
|
5101
5503
|
"data-slot": "navigation-menu-viewport",
|
|
@@ -5113,7 +5515,7 @@ function NavigationMenuLink({
|
|
|
5113
5515
|
className,
|
|
5114
5516
|
...props
|
|
5115
5517
|
}) {
|
|
5116
|
-
return /* @__PURE__ */
|
|
5518
|
+
return /* @__PURE__ */ jsx40(
|
|
5117
5519
|
NavigationMenuPrimitive.Link,
|
|
5118
5520
|
{
|
|
5119
5521
|
"data-slot": "navigation-menu-link",
|
|
@@ -5129,7 +5531,7 @@ function NavigationMenuIndicator({
|
|
|
5129
5531
|
className,
|
|
5130
5532
|
...props
|
|
5131
5533
|
}) {
|
|
5132
|
-
return /* @__PURE__ */
|
|
5534
|
+
return /* @__PURE__ */ jsx40(
|
|
5133
5535
|
NavigationMenuPrimitive.Indicator,
|
|
5134
5536
|
{
|
|
5135
5537
|
"data-slot": "navigation-menu-indicator",
|
|
@@ -5138,17 +5540,17 @@ function NavigationMenuIndicator({
|
|
|
5138
5540
|
className
|
|
5139
5541
|
),
|
|
5140
5542
|
...props,
|
|
5141
|
-
children: /* @__PURE__ */
|
|
5543
|
+
children: /* @__PURE__ */ jsx40("div", { className: "bg-border relative top-[60%] h-2 w-2 rotate-45 rounded-tl-sm shadow-md" })
|
|
5142
5544
|
}
|
|
5143
5545
|
);
|
|
5144
5546
|
}
|
|
5145
5547
|
|
|
5146
5548
|
// src/components/ui/option-card.tsx
|
|
5147
|
-
import { cva as
|
|
5549
|
+
import { cva as cva12 } from "class-variance-authority";
|
|
5148
5550
|
import { Check as Check2, Circle } from "lucide-react";
|
|
5149
5551
|
import "react";
|
|
5150
|
-
import { jsx as
|
|
5151
|
-
var optionCardVariants =
|
|
5552
|
+
import { jsx as jsx41, jsxs as jsxs24 } from "react/jsx-runtime";
|
|
5553
|
+
var optionCardVariants = cva12(
|
|
5152
5554
|
"group flex items-center gap-2 h-12 p-2 cursor-pointer transition-all duration-200 font-medium text-base leading-6 outline-none select-none",
|
|
5153
5555
|
{
|
|
5154
5556
|
variants: {
|
|
@@ -5228,26 +5630,26 @@ var optionCardVariants = cva11(
|
|
|
5228
5630
|
}
|
|
5229
5631
|
);
|
|
5230
5632
|
function RadioIndicator({ selected }) {
|
|
5231
|
-
return /* @__PURE__ */
|
|
5633
|
+
return /* @__PURE__ */ jsx41(
|
|
5232
5634
|
"span",
|
|
5233
5635
|
{
|
|
5234
5636
|
className: cn(
|
|
5235
5637
|
"flex items-center justify-center shrink-0 size-5 rounded-full border-2 transition-colors duration-200",
|
|
5236
5638
|
selected ? "bg-primary-stroke-default border-primary-stroke-default" : "border-gray-stroke-default bg-transparent group-hover:border-primary-stroke-default"
|
|
5237
5639
|
),
|
|
5238
|
-
children: selected && /* @__PURE__ */
|
|
5640
|
+
children: selected && /* @__PURE__ */ jsx41(Circle, { className: "size-2 fill-white text-white" })
|
|
5239
5641
|
}
|
|
5240
5642
|
);
|
|
5241
5643
|
}
|
|
5242
5644
|
function CheckboxIndicator({ selected }) {
|
|
5243
|
-
return /* @__PURE__ */
|
|
5645
|
+
return /* @__PURE__ */ jsx41(
|
|
5244
5646
|
"span",
|
|
5245
5647
|
{
|
|
5246
5648
|
className: cn(
|
|
5247
5649
|
"flex items-center justify-center shrink-0 size-5 rounded-[4px] border-2 transition-colors duration-200",
|
|
5248
5650
|
selected ? "bg-primary-stroke-default border-primary-stroke-default" : "border-gray-stroke-default bg-transparent group-hover:border-primary-stroke-default"
|
|
5249
5651
|
),
|
|
5250
|
-
children: selected && /* @__PURE__ */
|
|
5652
|
+
children: selected && /* @__PURE__ */ jsx41(Check2, { className: "size-4 text-white" })
|
|
5251
5653
|
}
|
|
5252
5654
|
);
|
|
5253
5655
|
}
|
|
@@ -5264,8 +5666,8 @@ function OptionCard({
|
|
|
5264
5666
|
...props
|
|
5265
5667
|
}) {
|
|
5266
5668
|
const Indicator5 = selectionType === "single" ? RadioIndicator : CheckboxIndicator;
|
|
5267
|
-
const indicator = /* @__PURE__ */
|
|
5268
|
-
return /* @__PURE__ */
|
|
5669
|
+
const indicator = /* @__PURE__ */ jsx41(Indicator5, { selected });
|
|
5670
|
+
return /* @__PURE__ */ jsxs24(
|
|
5269
5671
|
"button",
|
|
5270
5672
|
{
|
|
5271
5673
|
type: "button",
|
|
@@ -5284,9 +5686,9 @@ function OptionCard({
|
|
|
5284
5686
|
...props,
|
|
5285
5687
|
children: [
|
|
5286
5688
|
selectorPosition === "left" && indicator,
|
|
5287
|
-
/* @__PURE__ */
|
|
5288
|
-
icon && /* @__PURE__ */
|
|
5289
|
-
/* @__PURE__ */
|
|
5689
|
+
/* @__PURE__ */ jsxs24("span", { className: "flex items-center gap-2 flex-1 min-w-0", children: [
|
|
5690
|
+
icon && /* @__PURE__ */ jsx41("span", { className: "flex items-center justify-center shrink-0 size-5 [&_svg]:size-5", children: icon }),
|
|
5691
|
+
/* @__PURE__ */ jsx41("span", { className: "truncate", children })
|
|
5290
5692
|
] }),
|
|
5291
5693
|
selectorPosition === "right" && indicator
|
|
5292
5694
|
]
|
|
@@ -5301,9 +5703,9 @@ import {
|
|
|
5301
5703
|
ChevronRightIcon as ChevronRightIcon5,
|
|
5302
5704
|
MoreHorizontalIcon
|
|
5303
5705
|
} from "lucide-react";
|
|
5304
|
-
import { jsx as
|
|
5706
|
+
import { jsx as jsx42, jsxs as jsxs25 } from "react/jsx-runtime";
|
|
5305
5707
|
function Pagination({ className, ...props }) {
|
|
5306
|
-
return /* @__PURE__ */
|
|
5708
|
+
return /* @__PURE__ */ jsx42(
|
|
5307
5709
|
"nav",
|
|
5308
5710
|
{
|
|
5309
5711
|
role: "navigation",
|
|
@@ -5318,7 +5720,7 @@ function PaginationContent({
|
|
|
5318
5720
|
className,
|
|
5319
5721
|
...props
|
|
5320
5722
|
}) {
|
|
5321
|
-
return /* @__PURE__ */
|
|
5723
|
+
return /* @__PURE__ */ jsx42(
|
|
5322
5724
|
"ul",
|
|
5323
5725
|
{
|
|
5324
5726
|
"data-slot": "pagination-content",
|
|
@@ -5328,7 +5730,7 @@ function PaginationContent({
|
|
|
5328
5730
|
);
|
|
5329
5731
|
}
|
|
5330
5732
|
function PaginationItem({ ...props }) {
|
|
5331
|
-
return /* @__PURE__ */
|
|
5733
|
+
return /* @__PURE__ */ jsx42("li", { "data-slot": "pagination-item", ...props });
|
|
5332
5734
|
}
|
|
5333
5735
|
function PaginationLink({
|
|
5334
5736
|
className,
|
|
@@ -5336,7 +5738,7 @@ function PaginationLink({
|
|
|
5336
5738
|
size = "icon",
|
|
5337
5739
|
...props
|
|
5338
5740
|
}) {
|
|
5339
|
-
return /* @__PURE__ */
|
|
5741
|
+
return /* @__PURE__ */ jsx42(
|
|
5340
5742
|
"a",
|
|
5341
5743
|
{
|
|
5342
5744
|
"aria-current": isActive ? "page" : void 0,
|
|
@@ -5357,7 +5759,7 @@ function PaginationPrevious({
|
|
|
5357
5759
|
className,
|
|
5358
5760
|
...props
|
|
5359
5761
|
}) {
|
|
5360
|
-
return /* @__PURE__ */
|
|
5762
|
+
return /* @__PURE__ */ jsxs25(
|
|
5361
5763
|
PaginationLink,
|
|
5362
5764
|
{
|
|
5363
5765
|
"aria-label": "Go to previous page",
|
|
@@ -5365,8 +5767,8 @@ function PaginationPrevious({
|
|
|
5365
5767
|
className: cn("gap-1 px-2.5 sm:pl-2.5", className),
|
|
5366
5768
|
...props,
|
|
5367
5769
|
children: [
|
|
5368
|
-
/* @__PURE__ */
|
|
5369
|
-
/* @__PURE__ */
|
|
5770
|
+
/* @__PURE__ */ jsx42(ChevronLeftIcon2, {}),
|
|
5771
|
+
/* @__PURE__ */ jsx42("span", { className: "hidden sm:block", children: "Previous" })
|
|
5370
5772
|
]
|
|
5371
5773
|
}
|
|
5372
5774
|
);
|
|
@@ -5375,7 +5777,7 @@ function PaginationNext({
|
|
|
5375
5777
|
className,
|
|
5376
5778
|
...props
|
|
5377
5779
|
}) {
|
|
5378
|
-
return /* @__PURE__ */
|
|
5780
|
+
return /* @__PURE__ */ jsxs25(
|
|
5379
5781
|
PaginationLink,
|
|
5380
5782
|
{
|
|
5381
5783
|
"aria-label": "Go to next page",
|
|
@@ -5383,8 +5785,8 @@ function PaginationNext({
|
|
|
5383
5785
|
className: cn("gap-1 px-2.5 sm:pr-2.5", className),
|
|
5384
5786
|
...props,
|
|
5385
5787
|
children: [
|
|
5386
|
-
/* @__PURE__ */
|
|
5387
|
-
/* @__PURE__ */
|
|
5788
|
+
/* @__PURE__ */ jsx42("span", { className: "hidden sm:block", children: "Next" }),
|
|
5789
|
+
/* @__PURE__ */ jsx42(ChevronRightIcon5, {})
|
|
5388
5790
|
]
|
|
5389
5791
|
}
|
|
5390
5792
|
);
|
|
@@ -5393,7 +5795,7 @@ function PaginationEllipsis({
|
|
|
5393
5795
|
className,
|
|
5394
5796
|
...props
|
|
5395
5797
|
}) {
|
|
5396
|
-
return /* @__PURE__ */
|
|
5798
|
+
return /* @__PURE__ */ jsxs25(
|
|
5397
5799
|
"span",
|
|
5398
5800
|
{
|
|
5399
5801
|
"aria-hidden": true,
|
|
@@ -5401,8 +5803,8 @@ function PaginationEllipsis({
|
|
|
5401
5803
|
className: cn("flex size-9 items-center justify-center", className),
|
|
5402
5804
|
...props,
|
|
5403
5805
|
children: [
|
|
5404
|
-
/* @__PURE__ */
|
|
5405
|
-
/* @__PURE__ */
|
|
5806
|
+
/* @__PURE__ */ jsx42(MoreHorizontalIcon, { className: "size-4" }),
|
|
5807
|
+
/* @__PURE__ */ jsx42("span", { className: "sr-only", children: "More pages" })
|
|
5406
5808
|
]
|
|
5407
5809
|
}
|
|
5408
5810
|
);
|
|
@@ -5411,13 +5813,13 @@ function PaginationEllipsis({
|
|
|
5411
5813
|
// src/components/ui/progress.tsx
|
|
5412
5814
|
import * as ProgressPrimitive from "@radix-ui/react-progress";
|
|
5413
5815
|
import "react";
|
|
5414
|
-
import { jsx as
|
|
5816
|
+
import { jsx as jsx43 } from "react/jsx-runtime";
|
|
5415
5817
|
function Progress({
|
|
5416
5818
|
className,
|
|
5417
5819
|
value,
|
|
5418
5820
|
...props
|
|
5419
5821
|
}) {
|
|
5420
|
-
return /* @__PURE__ */
|
|
5822
|
+
return /* @__PURE__ */ jsx43(
|
|
5421
5823
|
ProgressPrimitive.Root,
|
|
5422
5824
|
{
|
|
5423
5825
|
"data-slot": "progress",
|
|
@@ -5426,7 +5828,7 @@ function Progress({
|
|
|
5426
5828
|
className
|
|
5427
5829
|
),
|
|
5428
5830
|
...props,
|
|
5429
|
-
children: /* @__PURE__ */
|
|
5831
|
+
children: /* @__PURE__ */ jsx43(
|
|
5430
5832
|
ProgressPrimitive.Indicator,
|
|
5431
5833
|
{
|
|
5432
5834
|
"data-slot": "progress-indicator",
|
|
@@ -5439,10 +5841,10 @@ function Progress({
|
|
|
5439
5841
|
}
|
|
5440
5842
|
|
|
5441
5843
|
// src/components/ui/progress-bar.tsx
|
|
5442
|
-
import { cva as
|
|
5844
|
+
import { cva as cva13 } from "class-variance-authority";
|
|
5443
5845
|
import "react";
|
|
5444
|
-
import { jsx as
|
|
5445
|
-
var progressBarVariants =
|
|
5846
|
+
import { jsx as jsx44, jsxs as jsxs26 } from "react/jsx-runtime";
|
|
5847
|
+
var progressBarVariants = cva13("relative overflow-hidden rounded-[8px]", {
|
|
5446
5848
|
variants: {
|
|
5447
5849
|
device: {
|
|
5448
5850
|
desktop: "w-[360px] h-[4px]",
|
|
@@ -5462,7 +5864,7 @@ function ProgressBar({
|
|
|
5462
5864
|
...props
|
|
5463
5865
|
}) {
|
|
5464
5866
|
const percentage = value !== void 0 ? Math.min(100, Math.max(0, value)) : Math.min(100, Math.max(0, currentStep / totalSteps * 100));
|
|
5465
|
-
return /* @__PURE__ */
|
|
5867
|
+
return /* @__PURE__ */ jsxs26(
|
|
5466
5868
|
"div",
|
|
5467
5869
|
{
|
|
5468
5870
|
"data-slot": "progress-bar",
|
|
@@ -5473,8 +5875,8 @@ function ProgressBar({
|
|
|
5473
5875
|
"aria-valuemax": 100,
|
|
5474
5876
|
...props,
|
|
5475
5877
|
children: [
|
|
5476
|
-
/* @__PURE__ */
|
|
5477
|
-
/* @__PURE__ */
|
|
5878
|
+
/* @__PURE__ */ jsx44("div", { className: "absolute inset-0 rounded-[8px] bg-primary-surface-light" }),
|
|
5879
|
+
/* @__PURE__ */ jsx44(
|
|
5478
5880
|
"div",
|
|
5479
5881
|
{
|
|
5480
5882
|
"data-slot": "progress-bar-fill",
|
|
@@ -5491,12 +5893,12 @@ function ProgressBar({
|
|
|
5491
5893
|
import * as RadioGroupPrimitive from "@radix-ui/react-radio-group";
|
|
5492
5894
|
import { CircleIcon as CircleIcon4 } from "lucide-react";
|
|
5493
5895
|
import "react";
|
|
5494
|
-
import { jsx as
|
|
5896
|
+
import { jsx as jsx45 } from "react/jsx-runtime";
|
|
5495
5897
|
function RadioGroup4({
|
|
5496
5898
|
className,
|
|
5497
5899
|
...props
|
|
5498
5900
|
}) {
|
|
5499
|
-
return /* @__PURE__ */
|
|
5901
|
+
return /* @__PURE__ */ jsx45(
|
|
5500
5902
|
RadioGroupPrimitive.Root,
|
|
5501
5903
|
{
|
|
5502
5904
|
"data-slot": "radio-group",
|
|
@@ -5509,7 +5911,7 @@ function RadioGroupItem({
|
|
|
5509
5911
|
className,
|
|
5510
5912
|
...props
|
|
5511
5913
|
}) {
|
|
5512
|
-
return /* @__PURE__ */
|
|
5914
|
+
return /* @__PURE__ */ jsx45(
|
|
5513
5915
|
RadioGroupPrimitive.Item,
|
|
5514
5916
|
{
|
|
5515
5917
|
"data-slot": "radio-group-item",
|
|
@@ -5518,12 +5920,12 @@ function RadioGroupItem({
|
|
|
5518
5920
|
className
|
|
5519
5921
|
),
|
|
5520
5922
|
...props,
|
|
5521
|
-
children: /* @__PURE__ */
|
|
5923
|
+
children: /* @__PURE__ */ jsx45(
|
|
5522
5924
|
RadioGroupPrimitive.Indicator,
|
|
5523
5925
|
{
|
|
5524
5926
|
"data-slot": "radio-group-indicator",
|
|
5525
5927
|
className: "relative flex items-center justify-center",
|
|
5526
|
-
children: /* @__PURE__ */
|
|
5928
|
+
children: /* @__PURE__ */ jsx45(CircleIcon4, { className: "fill-white absolute top-1/2 left-1/2 size-2 -translate-x-1/2 -translate-y-1/2" })
|
|
5527
5929
|
}
|
|
5528
5930
|
)
|
|
5529
5931
|
}
|
|
@@ -5534,12 +5936,12 @@ function RadioGroupItem({
|
|
|
5534
5936
|
import "react";
|
|
5535
5937
|
import { GripVerticalIcon } from "lucide-react";
|
|
5536
5938
|
import * as ResizablePrimitive from "react-resizable-panels";
|
|
5537
|
-
import { jsx as
|
|
5939
|
+
import { jsx as jsx46 } from "react/jsx-runtime";
|
|
5538
5940
|
function ResizablePanelGroup({
|
|
5539
5941
|
className,
|
|
5540
5942
|
...props
|
|
5541
5943
|
}) {
|
|
5542
|
-
return /* @__PURE__ */
|
|
5944
|
+
return /* @__PURE__ */ jsx46(
|
|
5543
5945
|
ResizablePrimitive.PanelGroup,
|
|
5544
5946
|
{
|
|
5545
5947
|
"data-slot": "resizable-panel-group",
|
|
@@ -5554,14 +5956,14 @@ function ResizablePanelGroup({
|
|
|
5554
5956
|
function ResizablePanel({
|
|
5555
5957
|
...props
|
|
5556
5958
|
}) {
|
|
5557
|
-
return /* @__PURE__ */
|
|
5959
|
+
return /* @__PURE__ */ jsx46(ResizablePrimitive.Panel, { "data-slot": "resizable-panel", ...props });
|
|
5558
5960
|
}
|
|
5559
5961
|
function ResizableHandle({
|
|
5560
5962
|
withHandle,
|
|
5561
5963
|
className,
|
|
5562
5964
|
...props
|
|
5563
5965
|
}) {
|
|
5564
|
-
return /* @__PURE__ */
|
|
5966
|
+
return /* @__PURE__ */ jsx46(
|
|
5565
5967
|
ResizablePrimitive.PanelResizeHandle,
|
|
5566
5968
|
{
|
|
5567
5969
|
"data-slot": "resizable-handle",
|
|
@@ -5570,7 +5972,7 @@ function ResizableHandle({
|
|
|
5570
5972
|
className
|
|
5571
5973
|
),
|
|
5572
5974
|
...props,
|
|
5573
|
-
children: withHandle && /* @__PURE__ */
|
|
5975
|
+
children: withHandle && /* @__PURE__ */ jsx46("div", { className: "bg-border z-10 flex h-4 w-3 items-center justify-center rounded-xs border", children: /* @__PURE__ */ jsx46(GripVerticalIcon, { className: "size-2.5" }) })
|
|
5574
5976
|
}
|
|
5575
5977
|
);
|
|
5576
5978
|
}
|
|
@@ -5578,20 +5980,20 @@ function ResizableHandle({
|
|
|
5578
5980
|
// src/components/ui/scroll-area.tsx
|
|
5579
5981
|
import "react";
|
|
5580
5982
|
import * as ScrollAreaPrimitive from "@radix-ui/react-scroll-area";
|
|
5581
|
-
import { jsx as
|
|
5983
|
+
import { jsx as jsx47, jsxs as jsxs27 } from "react/jsx-runtime";
|
|
5582
5984
|
function ScrollArea({
|
|
5583
5985
|
className,
|
|
5584
5986
|
children,
|
|
5585
5987
|
...props
|
|
5586
5988
|
}) {
|
|
5587
|
-
return /* @__PURE__ */
|
|
5989
|
+
return /* @__PURE__ */ jsxs27(
|
|
5588
5990
|
ScrollAreaPrimitive.Root,
|
|
5589
5991
|
{
|
|
5590
5992
|
"data-slot": "scroll-area",
|
|
5591
5993
|
className: cn("relative", className),
|
|
5592
5994
|
...props,
|
|
5593
5995
|
children: [
|
|
5594
|
-
/* @__PURE__ */
|
|
5996
|
+
/* @__PURE__ */ jsx47(
|
|
5595
5997
|
ScrollAreaPrimitive.Viewport,
|
|
5596
5998
|
{
|
|
5597
5999
|
"data-slot": "scroll-area-viewport",
|
|
@@ -5599,8 +6001,8 @@ function ScrollArea({
|
|
|
5599
6001
|
children
|
|
5600
6002
|
}
|
|
5601
6003
|
),
|
|
5602
|
-
/* @__PURE__ */
|
|
5603
|
-
/* @__PURE__ */
|
|
6004
|
+
/* @__PURE__ */ jsx47(ScrollBar, {}),
|
|
6005
|
+
/* @__PURE__ */ jsx47(ScrollAreaPrimitive.Corner, {})
|
|
5604
6006
|
]
|
|
5605
6007
|
}
|
|
5606
6008
|
);
|
|
@@ -5610,7 +6012,7 @@ function ScrollBar({
|
|
|
5610
6012
|
orientation = "vertical",
|
|
5611
6013
|
...props
|
|
5612
6014
|
}) {
|
|
5613
|
-
return /* @__PURE__ */
|
|
6015
|
+
return /* @__PURE__ */ jsx47(
|
|
5614
6016
|
ScrollAreaPrimitive.ScrollAreaScrollbar,
|
|
5615
6017
|
{
|
|
5616
6018
|
"data-slot": "scroll-area-scrollbar",
|
|
@@ -5622,7 +6024,7 @@ function ScrollBar({
|
|
|
5622
6024
|
className
|
|
5623
6025
|
),
|
|
5624
6026
|
...props,
|
|
5625
|
-
children: /* @__PURE__ */
|
|
6027
|
+
children: /* @__PURE__ */ jsx47(
|
|
5626
6028
|
ScrollAreaPrimitive.ScrollAreaThumb,
|
|
5627
6029
|
{
|
|
5628
6030
|
"data-slot": "scroll-area-thumb",
|
|
@@ -5634,9 +6036,9 @@ function ScrollBar({
|
|
|
5634
6036
|
}
|
|
5635
6037
|
|
|
5636
6038
|
// src/components/ui/search-input.tsx
|
|
5637
|
-
import * as
|
|
6039
|
+
import * as React47 from "react";
|
|
5638
6040
|
import { Search, X as X4 } from "lucide-react";
|
|
5639
|
-
import { jsx as
|
|
6041
|
+
import { jsx as jsx48, jsxs as jsxs28 } from "react/jsx-runtime";
|
|
5640
6042
|
function SearchInput({
|
|
5641
6043
|
variant = "icon",
|
|
5642
6044
|
value: valueProp,
|
|
@@ -5655,23 +6057,23 @@ function SearchInput({
|
|
|
5655
6057
|
onSuggestionClick,
|
|
5656
6058
|
className
|
|
5657
6059
|
}) {
|
|
5658
|
-
const [internalValue, setInternalValue] =
|
|
5659
|
-
const [isFocused, setIsFocused] =
|
|
5660
|
-
const [showSuggestions, setShowSuggestions] =
|
|
5661
|
-
const inputRef =
|
|
5662
|
-
const containerRef =
|
|
6060
|
+
const [internalValue, setInternalValue] = React47.useState(defaultValue);
|
|
6061
|
+
const [isFocused, setIsFocused] = React47.useState(false);
|
|
6062
|
+
const [showSuggestions, setShowSuggestions] = React47.useState(false);
|
|
6063
|
+
const inputRef = React47.useRef(null);
|
|
6064
|
+
const containerRef = React47.useRef(null);
|
|
5663
6065
|
const isControlled = valueProp !== void 0;
|
|
5664
6066
|
const currentValue = isControlled ? valueProp : internalValue;
|
|
5665
6067
|
const hasValue = currentValue.trim().length > 0;
|
|
5666
6068
|
const isFilledEdit = hasValue && !isFocused && !error;
|
|
5667
|
-
const updateValue =
|
|
6069
|
+
const updateValue = React47.useCallback(
|
|
5668
6070
|
(next) => {
|
|
5669
6071
|
if (!isControlled) setInternalValue(next);
|
|
5670
6072
|
onValueChange?.(next);
|
|
5671
6073
|
},
|
|
5672
6074
|
[isControlled, onValueChange]
|
|
5673
6075
|
);
|
|
5674
|
-
const handleInputChange =
|
|
6076
|
+
const handleInputChange = React47.useCallback(
|
|
5675
6077
|
(e) => {
|
|
5676
6078
|
updateValue(e.target.value);
|
|
5677
6079
|
if (e.target.value.trim().length > 0 && suggestions.length > 0) {
|
|
@@ -5682,7 +6084,7 @@ function SearchInput({
|
|
|
5682
6084
|
},
|
|
5683
6085
|
[updateValue, suggestions.length]
|
|
5684
6086
|
);
|
|
5685
|
-
const handleKeyDown =
|
|
6087
|
+
const handleKeyDown = React47.useCallback(
|
|
5686
6088
|
(e) => {
|
|
5687
6089
|
if (e.key === "Enter") {
|
|
5688
6090
|
e.preventDefault();
|
|
@@ -5695,16 +6097,16 @@ function SearchInput({
|
|
|
5695
6097
|
},
|
|
5696
6098
|
[currentValue, onSearch]
|
|
5697
6099
|
);
|
|
5698
|
-
const handleClear =
|
|
6100
|
+
const handleClear = React47.useCallback(() => {
|
|
5699
6101
|
updateValue("");
|
|
5700
6102
|
onClear?.();
|
|
5701
6103
|
inputRef.current?.focus();
|
|
5702
6104
|
}, [updateValue, onClear]);
|
|
5703
|
-
const handleSearchClick =
|
|
6105
|
+
const handleSearchClick = React47.useCallback(() => {
|
|
5704
6106
|
onSearch?.(currentValue);
|
|
5705
6107
|
setShowSuggestions(false);
|
|
5706
6108
|
}, [currentValue, onSearch]);
|
|
5707
|
-
const handleSuggestionClick =
|
|
6109
|
+
const handleSuggestionClick = React47.useCallback(
|
|
5708
6110
|
(label2) => {
|
|
5709
6111
|
updateValue(label2);
|
|
5710
6112
|
onSuggestionClick?.(label2);
|
|
@@ -5713,14 +6115,14 @@ function SearchInput({
|
|
|
5713
6115
|
},
|
|
5714
6116
|
[updateValue, onSuggestionClick]
|
|
5715
6117
|
);
|
|
5716
|
-
const handleFocus =
|
|
6118
|
+
const handleFocus = React47.useCallback(() => {
|
|
5717
6119
|
if (disabled) return;
|
|
5718
6120
|
setIsFocused(true);
|
|
5719
6121
|
if (currentValue.trim().length > 0 && suggestions.length > 0) {
|
|
5720
6122
|
setShowSuggestions(true);
|
|
5721
6123
|
}
|
|
5722
6124
|
}, [disabled, currentValue, suggestions.length]);
|
|
5723
|
-
const handleBlur =
|
|
6125
|
+
const handleBlur = React47.useCallback(
|
|
5724
6126
|
(e) => {
|
|
5725
6127
|
if (containerRef.current?.contains(e.relatedTarget)) return;
|
|
5726
6128
|
setIsFocused(false);
|
|
@@ -5730,7 +6132,7 @@ function SearchInput({
|
|
|
5730
6132
|
);
|
|
5731
6133
|
const displayHelperText = error && errorMessage ? errorMessage : helperText;
|
|
5732
6134
|
const showClearButton = (isFilledEdit || error) && hasValue;
|
|
5733
|
-
return /* @__PURE__ */
|
|
6135
|
+
return /* @__PURE__ */ jsxs28(
|
|
5734
6136
|
"div",
|
|
5735
6137
|
{
|
|
5736
6138
|
ref: containerRef,
|
|
@@ -5738,8 +6140,8 @@ function SearchInput({
|
|
|
5738
6140
|
className: cn("flex flex-col gap-[8px] items-start w-full", className),
|
|
5739
6141
|
onBlur: handleBlur,
|
|
5740
6142
|
children: [
|
|
5741
|
-
label && /* @__PURE__ */
|
|
5742
|
-
/* @__PURE__ */
|
|
6143
|
+
label && /* @__PURE__ */ jsx48("div", { className: "flex items-center font-sans font-medium text-[14px] leading-[20px] text-vibrant-text-details", children: label }),
|
|
6144
|
+
/* @__PURE__ */ jsxs28(
|
|
5743
6145
|
"div",
|
|
5744
6146
|
{
|
|
5745
6147
|
className: cn(
|
|
@@ -5756,7 +6158,7 @@ function SearchInput({
|
|
|
5756
6158
|
disabled && "opacity-60 cursor-not-allowed"
|
|
5757
6159
|
),
|
|
5758
6160
|
children: [
|
|
5759
|
-
icon && /* @__PURE__ */
|
|
6161
|
+
icon && /* @__PURE__ */ jsx48(
|
|
5760
6162
|
"span",
|
|
5761
6163
|
{
|
|
5762
6164
|
className: cn(
|
|
@@ -5766,7 +6168,7 @@ function SearchInput({
|
|
|
5766
6168
|
children: icon
|
|
5767
6169
|
}
|
|
5768
6170
|
),
|
|
5769
|
-
/* @__PURE__ */
|
|
6171
|
+
/* @__PURE__ */ jsx48(
|
|
5770
6172
|
"input",
|
|
5771
6173
|
{
|
|
5772
6174
|
ref: inputRef,
|
|
@@ -5783,7 +6185,7 @@ function SearchInput({
|
|
|
5783
6185
|
)
|
|
5784
6186
|
}
|
|
5785
6187
|
),
|
|
5786
|
-
showClearButton ? /* @__PURE__ */
|
|
6188
|
+
showClearButton ? /* @__PURE__ */ jsx48(
|
|
5787
6189
|
"button",
|
|
5788
6190
|
{
|
|
5789
6191
|
type: "button",
|
|
@@ -5791,9 +6193,9 @@ function SearchInput({
|
|
|
5791
6193
|
className: "flex items-center justify-center shrink-0 size-[20px] text-muted-foreground hover:text-vibrant-text-heading transition-colors cursor-pointer",
|
|
5792
6194
|
"aria-label": "Clear search",
|
|
5793
6195
|
tabIndex: -1,
|
|
5794
|
-
children: /* @__PURE__ */
|
|
6196
|
+
children: /* @__PURE__ */ jsx48(X4, { className: "size-[16px]" })
|
|
5795
6197
|
}
|
|
5796
|
-
) : variant === "button" ? /* @__PURE__ */
|
|
6198
|
+
) : variant === "button" ? /* @__PURE__ */ jsx48(
|
|
5797
6199
|
"button",
|
|
5798
6200
|
{
|
|
5799
6201
|
type: "button",
|
|
@@ -5803,7 +6205,7 @@ function SearchInput({
|
|
|
5803
6205
|
tabIndex: -1,
|
|
5804
6206
|
children: "Search"
|
|
5805
6207
|
}
|
|
5806
|
-
) : /* @__PURE__ */
|
|
6208
|
+
) : /* @__PURE__ */ jsx48(
|
|
5807
6209
|
"button",
|
|
5808
6210
|
{
|
|
5809
6211
|
type: "button",
|
|
@@ -5812,13 +6214,13 @@ function SearchInput({
|
|
|
5812
6214
|
className: "flex items-center justify-center shrink-0 size-[36px] rounded-[6px] bg-primary-surface-default cursor-pointer disabled:cursor-not-allowed transition-colors",
|
|
5813
6215
|
"aria-label": "Search",
|
|
5814
6216
|
tabIndex: -1,
|
|
5815
|
-
children: /* @__PURE__ */
|
|
6217
|
+
children: /* @__PURE__ */ jsx48(Search, { className: "size-[20px] text-white" })
|
|
5816
6218
|
}
|
|
5817
6219
|
)
|
|
5818
6220
|
]
|
|
5819
6221
|
}
|
|
5820
6222
|
),
|
|
5821
|
-
displayHelperText && /* @__PURE__ */
|
|
6223
|
+
displayHelperText && /* @__PURE__ */ jsx48(
|
|
5822
6224
|
"p",
|
|
5823
6225
|
{
|
|
5824
6226
|
className: cn(
|
|
@@ -5828,12 +6230,12 @@ function SearchInput({
|
|
|
5828
6230
|
children: displayHelperText
|
|
5829
6231
|
}
|
|
5830
6232
|
),
|
|
5831
|
-
showSuggestions && suggestions.length > 0 && /* @__PURE__ */
|
|
6233
|
+
showSuggestions && suggestions.length > 0 && /* @__PURE__ */ jsx48(
|
|
5832
6234
|
"div",
|
|
5833
6235
|
{
|
|
5834
6236
|
"data-slot": "search-input-suggestions",
|
|
5835
6237
|
className: "w-full rounded-[8px] border border-gray-stroke-light bg-white dark:bg-card p-[12px] shadow-[0px_4px_24px_0px_rgba(0,0,0,0.05)] flex flex-col gap-[16px]",
|
|
5836
|
-
children: suggestions.map((suggestion, idx) => /* @__PURE__ */
|
|
6238
|
+
children: suggestions.map((suggestion, idx) => /* @__PURE__ */ jsxs28(
|
|
5837
6239
|
"button",
|
|
5838
6240
|
{
|
|
5839
6241
|
type: "button",
|
|
@@ -5841,8 +6243,8 @@ function SearchInput({
|
|
|
5841
6243
|
onMouseDown: (e) => e.preventDefault(),
|
|
5842
6244
|
className: "flex items-center gap-[13px] h-[40px] pr-[12px] rounded-[8px] w-full text-left hover:bg-gray-surface-light transition-colors cursor-pointer",
|
|
5843
6245
|
children: [
|
|
5844
|
-
suggestion.icon && /* @__PURE__ */
|
|
5845
|
-
/* @__PURE__ */
|
|
6246
|
+
suggestion.icon && /* @__PURE__ */ jsx48("span", { className: "flex items-center justify-center shrink-0 size-[40px] rounded-[8px] bg-gray-surface-light [&_svg]:size-[20px] text-muted-foreground", children: suggestion.icon }),
|
|
6247
|
+
/* @__PURE__ */ jsx48("span", { className: "flex-1 min-w-0 font-sans font-medium text-[16px] leading-[24px] text-vibrant-text-heading truncate", children: suggestion.label })
|
|
5846
6248
|
]
|
|
5847
6249
|
},
|
|
5848
6250
|
`${suggestion.label}-${idx}`
|
|
@@ -5855,12 +6257,12 @@ function SearchInput({
|
|
|
5855
6257
|
}
|
|
5856
6258
|
|
|
5857
6259
|
// src/components/ui/searchable-select.tsx
|
|
5858
|
-
import * as
|
|
6260
|
+
import * as React48 from "react";
|
|
5859
6261
|
import { CheckIcon as CheckIcon4, ChevronsUpDown, XIcon as XIcon3 } from "lucide-react";
|
|
5860
|
-
import { jsx as
|
|
5861
|
-
var SearchableSelectContext =
|
|
6262
|
+
import { jsx as jsx49, jsxs as jsxs29 } from "react/jsx-runtime";
|
|
6263
|
+
var SearchableSelectContext = React48.createContext(null);
|
|
5862
6264
|
function useSearchableSelect() {
|
|
5863
|
-
const ctx =
|
|
6265
|
+
const ctx = React48.useContext(SearchableSelectContext);
|
|
5864
6266
|
if (!ctx) {
|
|
5865
6267
|
throw new Error(
|
|
5866
6268
|
"SearchableSelect compound components must be used within <SearchableSelect>"
|
|
@@ -5886,11 +6288,11 @@ function SearchableSelect({
|
|
|
5886
6288
|
onOpenChange,
|
|
5887
6289
|
children
|
|
5888
6290
|
}) {
|
|
5889
|
-
const [internalOpen, setInternalOpen] =
|
|
5890
|
-
const [internalValue, setInternalValue] =
|
|
5891
|
-
const [internalValues, setInternalValues] =
|
|
6291
|
+
const [internalOpen, setInternalOpen] = React48.useState(false);
|
|
6292
|
+
const [internalValue, setInternalValue] = React48.useState(defaultValue);
|
|
6293
|
+
const [internalValues, setInternalValues] = React48.useState(defaultValues);
|
|
5892
6294
|
const open = controlledOpen ?? internalOpen;
|
|
5893
|
-
const setOpen =
|
|
6295
|
+
const setOpen = React48.useCallback(
|
|
5894
6296
|
(next) => {
|
|
5895
6297
|
if (controlledOpen !== void 0) {
|
|
5896
6298
|
onOpenChange?.(next);
|
|
@@ -5902,7 +6304,7 @@ function SearchableSelect({
|
|
|
5902
6304
|
[controlledOpen, onOpenChange]
|
|
5903
6305
|
);
|
|
5904
6306
|
const value = controlledValue ?? internalValue;
|
|
5905
|
-
const setValue =
|
|
6307
|
+
const setValue = React48.useCallback(
|
|
5906
6308
|
(next) => {
|
|
5907
6309
|
if (controlledValue === void 0) {
|
|
5908
6310
|
setInternalValue(next);
|
|
@@ -5912,7 +6314,7 @@ function SearchableSelect({
|
|
|
5912
6314
|
[controlledValue, onValueChange]
|
|
5913
6315
|
);
|
|
5914
6316
|
const values = controlledValues ?? internalValues;
|
|
5915
|
-
const setValues =
|
|
6317
|
+
const setValues = React48.useCallback(
|
|
5916
6318
|
(next) => {
|
|
5917
6319
|
if (controlledValues === void 0) {
|
|
5918
6320
|
setInternalValues(next);
|
|
@@ -5921,14 +6323,14 @@ function SearchableSelect({
|
|
|
5921
6323
|
},
|
|
5922
6324
|
[controlledValues, onValuesChange]
|
|
5923
6325
|
);
|
|
5924
|
-
const optionMap =
|
|
6326
|
+
const optionMap = React48.useMemo(() => {
|
|
5925
6327
|
const map = /* @__PURE__ */ new Map();
|
|
5926
6328
|
for (const opt of options) {
|
|
5927
6329
|
map.set(opt.value, opt.label);
|
|
5928
6330
|
}
|
|
5929
6331
|
return map;
|
|
5930
6332
|
}, [options]);
|
|
5931
|
-
const ctx =
|
|
6333
|
+
const ctx = React48.useMemo(
|
|
5932
6334
|
() => ({
|
|
5933
6335
|
open,
|
|
5934
6336
|
setOpen,
|
|
@@ -5962,7 +6364,7 @@ function SearchableSelect({
|
|
|
5962
6364
|
optionMap
|
|
5963
6365
|
]
|
|
5964
6366
|
);
|
|
5965
|
-
return /* @__PURE__ */
|
|
6367
|
+
return /* @__PURE__ */ jsx49(SearchableSelectContext.Provider, { value: ctx, children: /* @__PURE__ */ jsx49(Popover, { open, onOpenChange: setOpen, children }) });
|
|
5966
6368
|
}
|
|
5967
6369
|
function SearchableSelectTrigger({
|
|
5968
6370
|
className,
|
|
@@ -5975,7 +6377,7 @@ function SearchableSelectTrigger({
|
|
|
5975
6377
|
if (children) return children;
|
|
5976
6378
|
if (ctx.mode === "single") {
|
|
5977
6379
|
const label = ctx.optionMap.get(ctx.value);
|
|
5978
|
-
return /* @__PURE__ */
|
|
6380
|
+
return /* @__PURE__ */ jsx49(
|
|
5979
6381
|
"span",
|
|
5980
6382
|
{
|
|
5981
6383
|
"data-slot": "searchable-select-value",
|
|
@@ -5988,7 +6390,7 @@ function SearchableSelectTrigger({
|
|
|
5988
6390
|
);
|
|
5989
6391
|
}
|
|
5990
6392
|
if (ctx.values.length === 0) {
|
|
5991
|
-
return /* @__PURE__ */
|
|
6393
|
+
return /* @__PURE__ */ jsx49(
|
|
5992
6394
|
"span",
|
|
5993
6395
|
{
|
|
5994
6396
|
"data-slot": "searchable-select-value",
|
|
@@ -5999,20 +6401,20 @@ function SearchableSelectTrigger({
|
|
|
5999
6401
|
}
|
|
6000
6402
|
const visible = ctx.values.slice(0, ctx.maxCount);
|
|
6001
6403
|
const remaining = ctx.values.length - visible.length;
|
|
6002
|
-
return /* @__PURE__ */
|
|
6404
|
+
return /* @__PURE__ */ jsxs29(
|
|
6003
6405
|
"span",
|
|
6004
6406
|
{
|
|
6005
6407
|
"data-slot": "searchable-select-value",
|
|
6006
6408
|
className: "flex flex-wrap items-center gap-1",
|
|
6007
6409
|
children: [
|
|
6008
|
-
visible.map((v) => /* @__PURE__ */
|
|
6410
|
+
visible.map((v) => /* @__PURE__ */ jsxs29(
|
|
6009
6411
|
Badge,
|
|
6010
6412
|
{
|
|
6011
6413
|
variant: "secondary",
|
|
6012
6414
|
className: "gap-1 pr-1",
|
|
6013
6415
|
children: [
|
|
6014
|
-
/* @__PURE__ */
|
|
6015
|
-
/* @__PURE__ */
|
|
6416
|
+
/* @__PURE__ */ jsx49("span", { className: "truncate max-w-[120px]", children: ctx.optionMap.get(v) || v }),
|
|
6417
|
+
/* @__PURE__ */ jsx49(
|
|
6016
6418
|
"span",
|
|
6017
6419
|
{
|
|
6018
6420
|
role: "button",
|
|
@@ -6024,14 +6426,14 @@ function SearchableSelectTrigger({
|
|
|
6024
6426
|
e.stopPropagation();
|
|
6025
6427
|
ctx.setValues(ctx.values.filter((val) => val !== v));
|
|
6026
6428
|
},
|
|
6027
|
-
children: /* @__PURE__ */
|
|
6429
|
+
children: /* @__PURE__ */ jsx49(XIcon3, { className: "size-3" })
|
|
6028
6430
|
}
|
|
6029
6431
|
)
|
|
6030
6432
|
]
|
|
6031
6433
|
},
|
|
6032
6434
|
v
|
|
6033
6435
|
)),
|
|
6034
|
-
remaining > 0 && /* @__PURE__ */
|
|
6436
|
+
remaining > 0 && /* @__PURE__ */ jsxs29(Badge, { variant: "outline", className: "text-muted-foreground", children: [
|
|
6035
6437
|
"+",
|
|
6036
6438
|
remaining,
|
|
6037
6439
|
" more"
|
|
@@ -6040,7 +6442,7 @@ function SearchableSelectTrigger({
|
|
|
6040
6442
|
}
|
|
6041
6443
|
);
|
|
6042
6444
|
};
|
|
6043
|
-
return /* @__PURE__ */
|
|
6445
|
+
return /* @__PURE__ */ jsxs29(
|
|
6044
6446
|
PopoverTrigger,
|
|
6045
6447
|
{
|
|
6046
6448
|
"data-slot": "searchable-select-trigger",
|
|
@@ -6054,7 +6456,7 @@ function SearchableSelectTrigger({
|
|
|
6054
6456
|
...props,
|
|
6055
6457
|
children: [
|
|
6056
6458
|
renderContent(),
|
|
6057
|
-
/* @__PURE__ */
|
|
6459
|
+
/* @__PURE__ */ jsx49(ChevronsUpDown, { className: "size-4 shrink-0 opacity-50" })
|
|
6058
6460
|
]
|
|
6059
6461
|
}
|
|
6060
6462
|
);
|
|
@@ -6066,7 +6468,7 @@ function SearchableSelectContent({
|
|
|
6066
6468
|
...props
|
|
6067
6469
|
}) {
|
|
6068
6470
|
const ctx = useSearchableSelect();
|
|
6069
|
-
const groupedOptions =
|
|
6471
|
+
const groupedOptions = React48.useMemo(() => {
|
|
6070
6472
|
if (ctx.options.length === 0) return null;
|
|
6071
6473
|
const groups = /* @__PURE__ */ new Map();
|
|
6072
6474
|
for (const opt of ctx.options) {
|
|
@@ -6080,7 +6482,7 @@ function SearchableSelectContent({
|
|
|
6080
6482
|
if (!groupedOptions) return null;
|
|
6081
6483
|
const entries = Array.from(groupedOptions.entries());
|
|
6082
6484
|
if (entries.length === 1 && entries[0][0] === "") {
|
|
6083
|
-
return entries[0][1].map((opt) => /* @__PURE__ */
|
|
6485
|
+
return entries[0][1].map((opt) => /* @__PURE__ */ jsx49(
|
|
6084
6486
|
SearchableSelectItem,
|
|
6085
6487
|
{
|
|
6086
6488
|
value: opt.value,
|
|
@@ -6090,7 +6492,7 @@ function SearchableSelectContent({
|
|
|
6090
6492
|
opt.value
|
|
6091
6493
|
));
|
|
6092
6494
|
}
|
|
6093
|
-
return entries.map(([group, opts]) => /* @__PURE__ */
|
|
6495
|
+
return entries.map(([group, opts]) => /* @__PURE__ */ jsx49(SearchableSelectGroup, { heading: group || void 0, children: opts.map((opt) => /* @__PURE__ */ jsx49(
|
|
6094
6496
|
SearchableSelectItem,
|
|
6095
6497
|
{
|
|
6096
6498
|
value: opt.value,
|
|
@@ -6100,17 +6502,17 @@ function SearchableSelectContent({
|
|
|
6100
6502
|
opt.value
|
|
6101
6503
|
)) }, group));
|
|
6102
6504
|
};
|
|
6103
|
-
return /* @__PURE__ */
|
|
6505
|
+
return /* @__PURE__ */ jsx49(
|
|
6104
6506
|
PopoverContent,
|
|
6105
6507
|
{
|
|
6106
6508
|
"data-slot": "searchable-select-content",
|
|
6107
6509
|
className: cn("w-[var(--radix-popover-trigger-width)] p-0", className),
|
|
6108
6510
|
align: "start",
|
|
6109
6511
|
...props,
|
|
6110
|
-
children: /* @__PURE__ */
|
|
6111
|
-
ctx.searchable && /* @__PURE__ */
|
|
6112
|
-
/* @__PURE__ */
|
|
6113
|
-
/* @__PURE__ */
|
|
6512
|
+
children: /* @__PURE__ */ jsxs29(Command, { children: [
|
|
6513
|
+
ctx.searchable && /* @__PURE__ */ jsx49(CommandInput, { placeholder: ctx.searchPlaceholder }),
|
|
6514
|
+
/* @__PURE__ */ jsxs29(CommandList, { children: [
|
|
6515
|
+
/* @__PURE__ */ jsx49(CommandEmpty, { children: emptyText }),
|
|
6114
6516
|
children || renderAutoItems()
|
|
6115
6517
|
] })
|
|
6116
6518
|
] })
|
|
@@ -6137,7 +6539,7 @@ function SearchableSelectItem({
|
|
|
6137
6539
|
);
|
|
6138
6540
|
}
|
|
6139
6541
|
};
|
|
6140
|
-
return /* @__PURE__ */
|
|
6542
|
+
return /* @__PURE__ */ jsxs29(
|
|
6141
6543
|
CommandItem,
|
|
6142
6544
|
{
|
|
6143
6545
|
"data-slot": "searchable-select-item",
|
|
@@ -6150,18 +6552,18 @@ function SearchableSelectItem({
|
|
|
6150
6552
|
"data-disabled": disabled || void 0,
|
|
6151
6553
|
...props,
|
|
6152
6554
|
children: [
|
|
6153
|
-
ctx.mode === "multiple" && /* @__PURE__ */
|
|
6555
|
+
ctx.mode === "multiple" && /* @__PURE__ */ jsx49("span", { className: "absolute left-2 flex size-4 items-center justify-center", children: /* @__PURE__ */ jsx49(
|
|
6154
6556
|
"span",
|
|
6155
6557
|
{
|
|
6156
6558
|
className: cn(
|
|
6157
6559
|
"size-4 rounded-sm border border-primary transition-colors",
|
|
6158
6560
|
isSelected ? "bg-primary text-primary-foreground" : "bg-transparent"
|
|
6159
6561
|
),
|
|
6160
|
-
children: isSelected && /* @__PURE__ */
|
|
6562
|
+
children: isSelected && /* @__PURE__ */ jsx49(CheckIcon4, { className: "size-4 p-0.5" })
|
|
6161
6563
|
}
|
|
6162
6564
|
) }),
|
|
6163
|
-
/* @__PURE__ */
|
|
6164
|
-
ctx.mode === "single" && isSelected && /* @__PURE__ */
|
|
6565
|
+
/* @__PURE__ */ jsx49("span", { className: "flex-1 truncate", children }),
|
|
6566
|
+
ctx.mode === "single" && isSelected && /* @__PURE__ */ jsx49("span", { className: "absolute right-2 flex size-4 items-center justify-center", children: /* @__PURE__ */ jsx49(CheckIcon4, { className: "size-4" }) })
|
|
6165
6567
|
]
|
|
6166
6568
|
}
|
|
6167
6569
|
);
|
|
@@ -6170,7 +6572,7 @@ function SearchableSelectGroup({
|
|
|
6170
6572
|
className,
|
|
6171
6573
|
...props
|
|
6172
6574
|
}) {
|
|
6173
|
-
return /* @__PURE__ */
|
|
6575
|
+
return /* @__PURE__ */ jsx49(
|
|
6174
6576
|
CommandGroup,
|
|
6175
6577
|
{
|
|
6176
6578
|
"data-slot": "searchable-select-group",
|
|
@@ -6184,7 +6586,7 @@ function SearchableSelectEmpty({
|
|
|
6184
6586
|
children = "No results found.",
|
|
6185
6587
|
...props
|
|
6186
6588
|
}) {
|
|
6187
|
-
return /* @__PURE__ */
|
|
6589
|
+
return /* @__PURE__ */ jsx49(
|
|
6188
6590
|
CommandEmpty,
|
|
6189
6591
|
{
|
|
6190
6592
|
"data-slot": "searchable-select-empty",
|
|
@@ -6199,21 +6601,21 @@ function SearchableSelectEmpty({
|
|
|
6199
6601
|
import "react";
|
|
6200
6602
|
import * as SelectPrimitive from "@radix-ui/react-select";
|
|
6201
6603
|
import { CheckIcon as CheckIcon5, ChevronDownIcon as ChevronDownIcon4, ChevronUpIcon } from "lucide-react";
|
|
6202
|
-
import { jsx as
|
|
6604
|
+
import { jsx as jsx50, jsxs as jsxs30 } from "react/jsx-runtime";
|
|
6203
6605
|
function Select({
|
|
6204
6606
|
...props
|
|
6205
6607
|
}) {
|
|
6206
|
-
return /* @__PURE__ */
|
|
6608
|
+
return /* @__PURE__ */ jsx50(SelectPrimitive.Root, { "data-slot": "select", ...props });
|
|
6207
6609
|
}
|
|
6208
6610
|
function SelectGroup({
|
|
6209
6611
|
...props
|
|
6210
6612
|
}) {
|
|
6211
|
-
return /* @__PURE__ */
|
|
6613
|
+
return /* @__PURE__ */ jsx50(SelectPrimitive.Group, { "data-slot": "select-group", ...props });
|
|
6212
6614
|
}
|
|
6213
6615
|
function SelectValue({
|
|
6214
6616
|
...props
|
|
6215
6617
|
}) {
|
|
6216
|
-
return /* @__PURE__ */
|
|
6618
|
+
return /* @__PURE__ */ jsx50(SelectPrimitive.Value, { "data-slot": "select-value", ...props });
|
|
6217
6619
|
}
|
|
6218
6620
|
function SelectTrigger({
|
|
6219
6621
|
className,
|
|
@@ -6221,7 +6623,7 @@ function SelectTrigger({
|
|
|
6221
6623
|
children,
|
|
6222
6624
|
...props
|
|
6223
6625
|
}) {
|
|
6224
|
-
return /* @__PURE__ */
|
|
6626
|
+
return /* @__PURE__ */ jsxs30(
|
|
6225
6627
|
SelectPrimitive.Trigger,
|
|
6226
6628
|
{
|
|
6227
6629
|
"data-slot": "select-trigger",
|
|
@@ -6233,7 +6635,7 @@ function SelectTrigger({
|
|
|
6233
6635
|
...props,
|
|
6234
6636
|
children: [
|
|
6235
6637
|
children,
|
|
6236
|
-
/* @__PURE__ */
|
|
6638
|
+
/* @__PURE__ */ jsx50(SelectPrimitive.Icon, { asChild: true, children: /* @__PURE__ */ jsx50(ChevronDownIcon4, { className: "size-4 opacity-50" }) })
|
|
6237
6639
|
]
|
|
6238
6640
|
}
|
|
6239
6641
|
);
|
|
@@ -6244,7 +6646,7 @@ function SelectContent({
|
|
|
6244
6646
|
position = "popper",
|
|
6245
6647
|
...props
|
|
6246
6648
|
}) {
|
|
6247
|
-
return /* @__PURE__ */
|
|
6649
|
+
return /* @__PURE__ */ jsx50(SelectPrimitive.Portal, { children: /* @__PURE__ */ jsxs30(
|
|
6248
6650
|
SelectPrimitive.Content,
|
|
6249
6651
|
{
|
|
6250
6652
|
"data-slot": "select-content",
|
|
@@ -6256,8 +6658,8 @@ function SelectContent({
|
|
|
6256
6658
|
position,
|
|
6257
6659
|
...props,
|
|
6258
6660
|
children: [
|
|
6259
|
-
/* @__PURE__ */
|
|
6260
|
-
/* @__PURE__ */
|
|
6661
|
+
/* @__PURE__ */ jsx50(SelectScrollUpButton, {}),
|
|
6662
|
+
/* @__PURE__ */ jsx50(
|
|
6261
6663
|
SelectPrimitive.Viewport,
|
|
6262
6664
|
{
|
|
6263
6665
|
className: cn(
|
|
@@ -6267,7 +6669,7 @@ function SelectContent({
|
|
|
6267
6669
|
children
|
|
6268
6670
|
}
|
|
6269
6671
|
),
|
|
6270
|
-
/* @__PURE__ */
|
|
6672
|
+
/* @__PURE__ */ jsx50(SelectScrollDownButton, {})
|
|
6271
6673
|
]
|
|
6272
6674
|
}
|
|
6273
6675
|
) });
|
|
@@ -6276,7 +6678,7 @@ function SelectLabel({
|
|
|
6276
6678
|
className,
|
|
6277
6679
|
...props
|
|
6278
6680
|
}) {
|
|
6279
|
-
return /* @__PURE__ */
|
|
6681
|
+
return /* @__PURE__ */ jsx50(
|
|
6280
6682
|
SelectPrimitive.Label,
|
|
6281
6683
|
{
|
|
6282
6684
|
"data-slot": "select-label",
|
|
@@ -6290,7 +6692,7 @@ function SelectItem({
|
|
|
6290
6692
|
children,
|
|
6291
6693
|
...props
|
|
6292
6694
|
}) {
|
|
6293
|
-
return /* @__PURE__ */
|
|
6695
|
+
return /* @__PURE__ */ jsxs30(
|
|
6294
6696
|
SelectPrimitive.Item,
|
|
6295
6697
|
{
|
|
6296
6698
|
"data-slot": "select-item",
|
|
@@ -6300,8 +6702,8 @@ function SelectItem({
|
|
|
6300
6702
|
),
|
|
6301
6703
|
...props,
|
|
6302
6704
|
children: [
|
|
6303
|
-
/* @__PURE__ */
|
|
6304
|
-
/* @__PURE__ */
|
|
6705
|
+
/* @__PURE__ */ jsx50("span", { className: "absolute right-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ jsx50(SelectPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx50(CheckIcon5, { className: "size-4" }) }) }),
|
|
6706
|
+
/* @__PURE__ */ jsx50(SelectPrimitive.ItemText, { children })
|
|
6305
6707
|
]
|
|
6306
6708
|
}
|
|
6307
6709
|
);
|
|
@@ -6310,7 +6712,7 @@ function SelectSeparator({
|
|
|
6310
6712
|
className,
|
|
6311
6713
|
...props
|
|
6312
6714
|
}) {
|
|
6313
|
-
return /* @__PURE__ */
|
|
6715
|
+
return /* @__PURE__ */ jsx50(
|
|
6314
6716
|
SelectPrimitive.Separator,
|
|
6315
6717
|
{
|
|
6316
6718
|
"data-slot": "select-separator",
|
|
@@ -6323,7 +6725,7 @@ function SelectScrollUpButton({
|
|
|
6323
6725
|
className,
|
|
6324
6726
|
...props
|
|
6325
6727
|
}) {
|
|
6326
|
-
return /* @__PURE__ */
|
|
6728
|
+
return /* @__PURE__ */ jsx50(
|
|
6327
6729
|
SelectPrimitive.ScrollUpButton,
|
|
6328
6730
|
{
|
|
6329
6731
|
"data-slot": "select-scroll-up-button",
|
|
@@ -6332,7 +6734,7 @@ function SelectScrollUpButton({
|
|
|
6332
6734
|
className
|
|
6333
6735
|
),
|
|
6334
6736
|
...props,
|
|
6335
|
-
children: /* @__PURE__ */
|
|
6737
|
+
children: /* @__PURE__ */ jsx50(ChevronUpIcon, { className: "size-4" })
|
|
6336
6738
|
}
|
|
6337
6739
|
);
|
|
6338
6740
|
}
|
|
@@ -6340,7 +6742,7 @@ function SelectScrollDownButton({
|
|
|
6340
6742
|
className,
|
|
6341
6743
|
...props
|
|
6342
6744
|
}) {
|
|
6343
|
-
return /* @__PURE__ */
|
|
6745
|
+
return /* @__PURE__ */ jsx50(
|
|
6344
6746
|
SelectPrimitive.ScrollDownButton,
|
|
6345
6747
|
{
|
|
6346
6748
|
"data-slot": "select-scroll-down-button",
|
|
@@ -6349,7 +6751,7 @@ function SelectScrollDownButton({
|
|
|
6349
6751
|
className
|
|
6350
6752
|
),
|
|
6351
6753
|
...props,
|
|
6352
|
-
children: /* @__PURE__ */
|
|
6754
|
+
children: /* @__PURE__ */ jsx50(ChevronDownIcon4, { className: "size-4" })
|
|
6353
6755
|
}
|
|
6354
6756
|
);
|
|
6355
6757
|
}
|
|
@@ -6357,14 +6759,14 @@ function SelectScrollDownButton({
|
|
|
6357
6759
|
// src/components/ui/separator.tsx
|
|
6358
6760
|
import "react";
|
|
6359
6761
|
import * as SeparatorPrimitive from "@radix-ui/react-separator";
|
|
6360
|
-
import { jsx as
|
|
6762
|
+
import { jsx as jsx51 } from "react/jsx-runtime";
|
|
6361
6763
|
function Separator5({
|
|
6362
6764
|
className,
|
|
6363
6765
|
orientation = "horizontal",
|
|
6364
6766
|
decorative = true,
|
|
6365
6767
|
...props
|
|
6366
6768
|
}) {
|
|
6367
|
-
return /* @__PURE__ */
|
|
6769
|
+
return /* @__PURE__ */ jsx51(
|
|
6368
6770
|
SeparatorPrimitive.Root,
|
|
6369
6771
|
{
|
|
6370
6772
|
"data-slot": "separator",
|
|
@@ -6383,30 +6785,30 @@ function Separator5({
|
|
|
6383
6785
|
import * as SheetPrimitive from "@radix-ui/react-dialog";
|
|
6384
6786
|
import { XIcon as XIcon4 } from "lucide-react";
|
|
6385
6787
|
import "react";
|
|
6386
|
-
import { jsx as
|
|
6788
|
+
import { jsx as jsx52, jsxs as jsxs31 } from "react/jsx-runtime";
|
|
6387
6789
|
function Sheet({ ...props }) {
|
|
6388
|
-
return /* @__PURE__ */
|
|
6790
|
+
return /* @__PURE__ */ jsx52(SheetPrimitive.Root, { "data-slot": "sheet", ...props });
|
|
6389
6791
|
}
|
|
6390
6792
|
function SheetTrigger({
|
|
6391
6793
|
...props
|
|
6392
6794
|
}) {
|
|
6393
|
-
return /* @__PURE__ */
|
|
6795
|
+
return /* @__PURE__ */ jsx52(SheetPrimitive.Trigger, { "data-slot": "sheet-trigger", ...props });
|
|
6394
6796
|
}
|
|
6395
6797
|
function SheetClose({
|
|
6396
6798
|
...props
|
|
6397
6799
|
}) {
|
|
6398
|
-
return /* @__PURE__ */
|
|
6800
|
+
return /* @__PURE__ */ jsx52(SheetPrimitive.Close, { "data-slot": "sheet-close", ...props });
|
|
6399
6801
|
}
|
|
6400
6802
|
function SheetPortal({
|
|
6401
6803
|
...props
|
|
6402
6804
|
}) {
|
|
6403
|
-
return /* @__PURE__ */
|
|
6805
|
+
return /* @__PURE__ */ jsx52(SheetPrimitive.Portal, { "data-slot": "sheet-portal", ...props });
|
|
6404
6806
|
}
|
|
6405
6807
|
function SheetOverlay({
|
|
6406
6808
|
className,
|
|
6407
6809
|
...props
|
|
6408
6810
|
}) {
|
|
6409
|
-
return /* @__PURE__ */
|
|
6811
|
+
return /* @__PURE__ */ jsx52(
|
|
6410
6812
|
SheetPrimitive.Overlay,
|
|
6411
6813
|
{
|
|
6412
6814
|
"data-slot": "sheet-overlay",
|
|
@@ -6425,9 +6827,9 @@ function SheetContent({
|
|
|
6425
6827
|
showCloseButton = true,
|
|
6426
6828
|
...props
|
|
6427
6829
|
}) {
|
|
6428
|
-
return /* @__PURE__ */
|
|
6429
|
-
/* @__PURE__ */
|
|
6430
|
-
/* @__PURE__ */
|
|
6830
|
+
return /* @__PURE__ */ jsxs31(SheetPortal, { children: [
|
|
6831
|
+
/* @__PURE__ */ jsx52(SheetOverlay, {}),
|
|
6832
|
+
/* @__PURE__ */ jsxs31(
|
|
6431
6833
|
SheetPrimitive.Content,
|
|
6432
6834
|
{
|
|
6433
6835
|
"data-slot": "sheet-content",
|
|
@@ -6442,9 +6844,9 @@ function SheetContent({
|
|
|
6442
6844
|
...props,
|
|
6443
6845
|
children: [
|
|
6444
6846
|
children,
|
|
6445
|
-
showCloseButton && /* @__PURE__ */
|
|
6446
|
-
/* @__PURE__ */
|
|
6447
|
-
/* @__PURE__ */
|
|
6847
|
+
showCloseButton && /* @__PURE__ */ jsxs31(SheetPrimitive.Close, { className: "ring-offset-background focus:ring-ring data-[state=open]:bg-secondary absolute top-4 right-4 rounded-xs opacity-70 transition-opacity hover:opacity-100 focus:ring-2 focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none", children: [
|
|
6848
|
+
/* @__PURE__ */ jsx52(XIcon4, { className: "size-4" }),
|
|
6849
|
+
/* @__PURE__ */ jsx52("span", { className: "sr-only", children: "Close" })
|
|
6448
6850
|
] })
|
|
6449
6851
|
]
|
|
6450
6852
|
}
|
|
@@ -6452,7 +6854,7 @@ function SheetContent({
|
|
|
6452
6854
|
] });
|
|
6453
6855
|
}
|
|
6454
6856
|
function SheetHeader({ className, ...props }) {
|
|
6455
|
-
return /* @__PURE__ */
|
|
6857
|
+
return /* @__PURE__ */ jsx52(
|
|
6456
6858
|
"div",
|
|
6457
6859
|
{
|
|
6458
6860
|
"data-slot": "sheet-header",
|
|
@@ -6462,7 +6864,7 @@ function SheetHeader({ className, ...props }) {
|
|
|
6462
6864
|
);
|
|
6463
6865
|
}
|
|
6464
6866
|
function SheetFooter({ className, ...props }) {
|
|
6465
|
-
return /* @__PURE__ */
|
|
6867
|
+
return /* @__PURE__ */ jsx52(
|
|
6466
6868
|
"div",
|
|
6467
6869
|
{
|
|
6468
6870
|
"data-slot": "sheet-footer",
|
|
@@ -6475,7 +6877,7 @@ function SheetTitle({
|
|
|
6475
6877
|
className,
|
|
6476
6878
|
...props
|
|
6477
6879
|
}) {
|
|
6478
|
-
return /* @__PURE__ */
|
|
6880
|
+
return /* @__PURE__ */ jsx52(
|
|
6479
6881
|
SheetPrimitive.Title,
|
|
6480
6882
|
{
|
|
6481
6883
|
"data-slot": "sheet-title",
|
|
@@ -6488,7 +6890,7 @@ function SheetDescription({
|
|
|
6488
6890
|
className,
|
|
6489
6891
|
...props
|
|
6490
6892
|
}) {
|
|
6491
|
-
return /* @__PURE__ */
|
|
6893
|
+
return /* @__PURE__ */ jsx52(
|
|
6492
6894
|
SheetPrimitive.Description,
|
|
6493
6895
|
{
|
|
6494
6896
|
"data-slot": "sheet-description",
|
|
@@ -6499,15 +6901,15 @@ function SheetDescription({
|
|
|
6499
6901
|
}
|
|
6500
6902
|
|
|
6501
6903
|
// src/components/ui/sidebar.tsx
|
|
6502
|
-
import { Slot as
|
|
6503
|
-
import { cva as
|
|
6904
|
+
import { Slot as Slot7 } from "@radix-ui/react-slot";
|
|
6905
|
+
import { cva as cva14 } from "class-variance-authority";
|
|
6504
6906
|
import { PanelLeftIcon } from "lucide-react";
|
|
6505
|
-
import * as
|
|
6907
|
+
import * as React53 from "react";
|
|
6506
6908
|
|
|
6507
6909
|
// src/components/ui/skeleton.tsx
|
|
6508
|
-
import { jsx as
|
|
6910
|
+
import { jsx as jsx53 } from "react/jsx-runtime";
|
|
6509
6911
|
function Skeleton({ className, ...props }) {
|
|
6510
|
-
return /* @__PURE__ */
|
|
6912
|
+
return /* @__PURE__ */ jsx53(
|
|
6511
6913
|
"div",
|
|
6512
6914
|
{
|
|
6513
6915
|
"data-slot": "skeleton",
|
|
@@ -6520,13 +6922,13 @@ function Skeleton({ className, ...props }) {
|
|
|
6520
6922
|
// src/components/ui/tooltip.tsx
|
|
6521
6923
|
import * as TooltipPrimitive from "@radix-ui/react-tooltip";
|
|
6522
6924
|
import { X as X5 } from "lucide-react";
|
|
6523
|
-
import * as
|
|
6524
|
-
import { jsx as
|
|
6925
|
+
import * as React52 from "react";
|
|
6926
|
+
import { jsx as jsx54, jsxs as jsxs32 } from "react/jsx-runtime";
|
|
6525
6927
|
function TooltipProvider({
|
|
6526
6928
|
delayDuration = 0,
|
|
6527
6929
|
...props
|
|
6528
6930
|
}) {
|
|
6529
|
-
return /* @__PURE__ */
|
|
6931
|
+
return /* @__PURE__ */ jsx54(
|
|
6530
6932
|
TooltipPrimitive.Provider,
|
|
6531
6933
|
{
|
|
6532
6934
|
"data-slot": "tooltip-provider",
|
|
@@ -6535,20 +6937,20 @@ function TooltipProvider({
|
|
|
6535
6937
|
}
|
|
6536
6938
|
);
|
|
6537
6939
|
}
|
|
6538
|
-
var TooltipCloseContext =
|
|
6940
|
+
var TooltipCloseContext = React52.createContext(null);
|
|
6539
6941
|
function Tooltip2({
|
|
6540
6942
|
persistent = false,
|
|
6541
6943
|
...props
|
|
6542
6944
|
}) {
|
|
6543
|
-
const [open, setOpen] =
|
|
6945
|
+
const [open, setOpen] = React52.useState(props.defaultOpen ?? false);
|
|
6544
6946
|
if (!persistent) {
|
|
6545
|
-
return /* @__PURE__ */
|
|
6947
|
+
return /* @__PURE__ */ jsx54(TooltipProvider, { children: /* @__PURE__ */ jsx54(TooltipPrimitive.Root, { "data-slot": "tooltip", ...props }) });
|
|
6546
6948
|
}
|
|
6547
6949
|
const close = () => {
|
|
6548
6950
|
setOpen(false);
|
|
6549
6951
|
props.onOpenChange?.(false);
|
|
6550
6952
|
};
|
|
6551
|
-
return /* @__PURE__ */
|
|
6953
|
+
return /* @__PURE__ */ jsx54(TooltipProvider, { children: /* @__PURE__ */ jsx54(TooltipCloseContext.Provider, { value: close, children: /* @__PURE__ */ jsx54(
|
|
6552
6954
|
TooltipPrimitive.Root,
|
|
6553
6955
|
{
|
|
6554
6956
|
"data-slot": "tooltip",
|
|
@@ -6566,7 +6968,7 @@ function Tooltip2({
|
|
|
6566
6968
|
function TooltipTrigger({
|
|
6567
6969
|
...props
|
|
6568
6970
|
}) {
|
|
6569
|
-
return /* @__PURE__ */
|
|
6971
|
+
return /* @__PURE__ */ jsx54(TooltipPrimitive.Trigger, { "data-slot": "tooltip-trigger", ...props });
|
|
6570
6972
|
}
|
|
6571
6973
|
function TooltipContent({
|
|
6572
6974
|
className,
|
|
@@ -6576,7 +6978,7 @@ function TooltipContent({
|
|
|
6576
6978
|
children,
|
|
6577
6979
|
...props
|
|
6578
6980
|
}) {
|
|
6579
|
-
return /* @__PURE__ */
|
|
6981
|
+
return /* @__PURE__ */ jsx54(TooltipPrimitive.Portal, { children: /* @__PURE__ */ jsxs32(
|
|
6580
6982
|
TooltipPrimitive.Content,
|
|
6581
6983
|
{
|
|
6582
6984
|
"data-slot": "tooltip-content",
|
|
@@ -6588,7 +6990,7 @@ function TooltipContent({
|
|
|
6588
6990
|
...props,
|
|
6589
6991
|
children: [
|
|
6590
6992
|
children,
|
|
6591
|
-
!hideArrow && /* @__PURE__ */
|
|
6993
|
+
!hideArrow && /* @__PURE__ */ jsx54(
|
|
6592
6994
|
TooltipPrimitive.Arrow,
|
|
6593
6995
|
{
|
|
6594
6996
|
className: cn(
|
|
@@ -6629,13 +7031,13 @@ function RichTooltipContent({
|
|
|
6629
7031
|
hideArrow = false,
|
|
6630
7032
|
...props
|
|
6631
7033
|
}) {
|
|
6632
|
-
const close =
|
|
7034
|
+
const close = React52.useContext(TooltipCloseContext);
|
|
6633
7035
|
const handleDismiss = () => {
|
|
6634
7036
|
close?.();
|
|
6635
7037
|
onDismiss?.();
|
|
6636
7038
|
};
|
|
6637
7039
|
const styles = richTooltipVariants[variant] ?? richTooltipVariants.dark;
|
|
6638
|
-
return /* @__PURE__ */
|
|
7040
|
+
return /* @__PURE__ */ jsx54(TooltipPrimitive.Portal, { children: /* @__PURE__ */ jsxs32(
|
|
6639
7041
|
TooltipPrimitive.Content,
|
|
6640
7042
|
{
|
|
6641
7043
|
"data-slot": "rich-tooltip-content",
|
|
@@ -6649,7 +7051,7 @@ function RichTooltipContent({
|
|
|
6649
7051
|
},
|
|
6650
7052
|
...props,
|
|
6651
7053
|
children: [
|
|
6652
|
-
/* @__PURE__ */
|
|
7054
|
+
/* @__PURE__ */ jsxs32(
|
|
6653
7055
|
"div",
|
|
6654
7056
|
{
|
|
6655
7057
|
className: cn(
|
|
@@ -6659,12 +7061,12 @@ function RichTooltipContent({
|
|
|
6659
7061
|
surfaceClassName
|
|
6660
7062
|
),
|
|
6661
7063
|
children: [
|
|
6662
|
-
icon && /* @__PURE__ */
|
|
6663
|
-
/* @__PURE__ */
|
|
6664
|
-
heading && /* @__PURE__ */
|
|
6665
|
-
/* @__PURE__ */
|
|
7064
|
+
icon && /* @__PURE__ */ jsx54("span", { className: "flex items-center justify-center shrink-0 size-5 [&_svg]:size-5", children: icon }),
|
|
7065
|
+
/* @__PURE__ */ jsxs32("div", { className: "flex flex-1 flex-col gap-2 min-w-0", children: [
|
|
7066
|
+
heading && /* @__PURE__ */ jsx54("p", { className: "font-semibold text-sm leading-5", children: heading }),
|
|
7067
|
+
/* @__PURE__ */ jsx54("div", { className: "font-normal text-sm leading-5", children })
|
|
6666
7068
|
] }),
|
|
6667
|
-
dismissible && /* @__PURE__ */
|
|
7069
|
+
dismissible && /* @__PURE__ */ jsx54(
|
|
6668
7070
|
"button",
|
|
6669
7071
|
{
|
|
6670
7072
|
type: "button",
|
|
@@ -6674,13 +7076,13 @@ function RichTooltipContent({
|
|
|
6674
7076
|
styles.mutedText
|
|
6675
7077
|
),
|
|
6676
7078
|
"aria-label": "Dismiss",
|
|
6677
|
-
children: /* @__PURE__ */
|
|
7079
|
+
children: /* @__PURE__ */ jsx54(X5, { className: "size-3.5" })
|
|
6678
7080
|
}
|
|
6679
7081
|
)
|
|
6680
7082
|
]
|
|
6681
7083
|
}
|
|
6682
7084
|
),
|
|
6683
|
-
!hideArrow && /* @__PURE__ */
|
|
7085
|
+
!hideArrow && /* @__PURE__ */ jsx54(
|
|
6684
7086
|
TooltipPrimitive.Arrow,
|
|
6685
7087
|
{
|
|
6686
7088
|
width: 16,
|
|
@@ -6694,16 +7096,16 @@ function RichTooltipContent({
|
|
|
6694
7096
|
}
|
|
6695
7097
|
|
|
6696
7098
|
// src/components/ui/sidebar.tsx
|
|
6697
|
-
import { jsx as
|
|
7099
|
+
import { jsx as jsx55, jsxs as jsxs33 } from "react/jsx-runtime";
|
|
6698
7100
|
var SIDEBAR_COOKIE_NAME = "sidebar_state";
|
|
6699
7101
|
var SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;
|
|
6700
7102
|
var SIDEBAR_WIDTH = "18rem";
|
|
6701
7103
|
var SIDEBAR_WIDTH_MOBILE = "18rem";
|
|
6702
7104
|
var SIDEBAR_WIDTH_ICON = "3rem";
|
|
6703
7105
|
var SIDEBAR_KEYBOARD_SHORTCUT = "b";
|
|
6704
|
-
var SidebarContext =
|
|
7106
|
+
var SidebarContext = React53.createContext(null);
|
|
6705
7107
|
function useSidebar() {
|
|
6706
|
-
const context =
|
|
7108
|
+
const context = React53.useContext(SidebarContext);
|
|
6707
7109
|
if (!context) {
|
|
6708
7110
|
throw new Error("useSidebar must be used within a SidebarProvider.");
|
|
6709
7111
|
}
|
|
@@ -6719,10 +7121,10 @@ function SidebarProvider({
|
|
|
6719
7121
|
...props
|
|
6720
7122
|
}) {
|
|
6721
7123
|
const isMobile = useIsMobile();
|
|
6722
|
-
const [openMobile, setOpenMobile] =
|
|
6723
|
-
const [_open, _setOpen] =
|
|
7124
|
+
const [openMobile, setOpenMobile] = React53.useState(false);
|
|
7125
|
+
const [_open, _setOpen] = React53.useState(defaultOpen);
|
|
6724
7126
|
const open = openProp ?? _open;
|
|
6725
|
-
const setOpen =
|
|
7127
|
+
const setOpen = React53.useCallback(
|
|
6726
7128
|
(value) => {
|
|
6727
7129
|
const openState = typeof value === "function" ? value(open) : value;
|
|
6728
7130
|
if (setOpenProp) {
|
|
@@ -6734,10 +7136,10 @@ function SidebarProvider({
|
|
|
6734
7136
|
},
|
|
6735
7137
|
[setOpenProp, open]
|
|
6736
7138
|
);
|
|
6737
|
-
const toggleSidebar =
|
|
7139
|
+
const toggleSidebar = React53.useCallback(() => {
|
|
6738
7140
|
return isMobile ? setOpenMobile((open2) => !open2) : setOpen((open2) => !open2);
|
|
6739
7141
|
}, [isMobile, setOpen, setOpenMobile]);
|
|
6740
|
-
|
|
7142
|
+
React53.useEffect(() => {
|
|
6741
7143
|
const handleKeyDown = (event) => {
|
|
6742
7144
|
if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {
|
|
6743
7145
|
event.preventDefault();
|
|
@@ -6748,7 +7150,7 @@ function SidebarProvider({
|
|
|
6748
7150
|
return () => window.removeEventListener("keydown", handleKeyDown);
|
|
6749
7151
|
}, [toggleSidebar]);
|
|
6750
7152
|
const state = open ? "expanded" : "collapsed";
|
|
6751
|
-
const contextValue =
|
|
7153
|
+
const contextValue = React53.useMemo(
|
|
6752
7154
|
() => ({
|
|
6753
7155
|
state,
|
|
6754
7156
|
open,
|
|
@@ -6760,7 +7162,7 @@ function SidebarProvider({
|
|
|
6760
7162
|
}),
|
|
6761
7163
|
[state, open, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar]
|
|
6762
7164
|
);
|
|
6763
|
-
return /* @__PURE__ */
|
|
7165
|
+
return /* @__PURE__ */ jsx55(SidebarContext.Provider, { value: contextValue, children: /* @__PURE__ */ jsx55(TooltipProvider, { delayDuration: 0, children: /* @__PURE__ */ jsx55(
|
|
6764
7166
|
"div",
|
|
6765
7167
|
{
|
|
6766
7168
|
"data-slot": "sidebar-wrapper",
|
|
@@ -6788,7 +7190,7 @@ function Sidebar({
|
|
|
6788
7190
|
}) {
|
|
6789
7191
|
const { isMobile, state, openMobile, setOpenMobile } = useSidebar();
|
|
6790
7192
|
if (collapsible === "none") {
|
|
6791
|
-
return /* @__PURE__ */
|
|
7193
|
+
return /* @__PURE__ */ jsx55(
|
|
6792
7194
|
"div",
|
|
6793
7195
|
{
|
|
6794
7196
|
"data-slot": "sidebar",
|
|
@@ -6802,7 +7204,7 @@ function Sidebar({
|
|
|
6802
7204
|
);
|
|
6803
7205
|
}
|
|
6804
7206
|
if (isMobile) {
|
|
6805
|
-
return /* @__PURE__ */
|
|
7207
|
+
return /* @__PURE__ */ jsx55(Sheet, { open: openMobile, onOpenChange: setOpenMobile, ...props, children: /* @__PURE__ */ jsxs33(
|
|
6806
7208
|
SheetContent,
|
|
6807
7209
|
{
|
|
6808
7210
|
"data-sidebar": "sidebar",
|
|
@@ -6814,16 +7216,16 @@ function Sidebar({
|
|
|
6814
7216
|
},
|
|
6815
7217
|
side,
|
|
6816
7218
|
children: [
|
|
6817
|
-
/* @__PURE__ */
|
|
6818
|
-
/* @__PURE__ */
|
|
6819
|
-
/* @__PURE__ */
|
|
7219
|
+
/* @__PURE__ */ jsxs33(SheetHeader, { className: "sr-only", children: [
|
|
7220
|
+
/* @__PURE__ */ jsx55(SheetTitle, { children: "Sidebar" }),
|
|
7221
|
+
/* @__PURE__ */ jsx55(SheetDescription, { children: "Displays the mobile sidebar." })
|
|
6820
7222
|
] }),
|
|
6821
|
-
/* @__PURE__ */
|
|
7223
|
+
/* @__PURE__ */ jsx55("div", { className: "flex h-full w-full flex-col", children })
|
|
6822
7224
|
]
|
|
6823
7225
|
}
|
|
6824
7226
|
) });
|
|
6825
7227
|
}
|
|
6826
|
-
return /* @__PURE__ */
|
|
7228
|
+
return /* @__PURE__ */ jsxs33(
|
|
6827
7229
|
"div",
|
|
6828
7230
|
{
|
|
6829
7231
|
className: "group peer text-sidebar-foreground hidden md:block",
|
|
@@ -6833,7 +7235,7 @@ function Sidebar({
|
|
|
6833
7235
|
"data-side": side,
|
|
6834
7236
|
"data-slot": "sidebar",
|
|
6835
7237
|
children: [
|
|
6836
|
-
/* @__PURE__ */
|
|
7238
|
+
/* @__PURE__ */ jsx55(
|
|
6837
7239
|
"div",
|
|
6838
7240
|
{
|
|
6839
7241
|
"data-slot": "sidebar-gap",
|
|
@@ -6845,7 +7247,7 @@ function Sidebar({
|
|
|
6845
7247
|
)
|
|
6846
7248
|
}
|
|
6847
7249
|
),
|
|
6848
|
-
/* @__PURE__ */
|
|
7250
|
+
/* @__PURE__ */ jsx55(
|
|
6849
7251
|
"div",
|
|
6850
7252
|
{
|
|
6851
7253
|
"data-slot": "sidebar-container",
|
|
@@ -6857,7 +7259,7 @@ function Sidebar({
|
|
|
6857
7259
|
className
|
|
6858
7260
|
),
|
|
6859
7261
|
...props,
|
|
6860
|
-
children: /* @__PURE__ */
|
|
7262
|
+
children: /* @__PURE__ */ jsx55(
|
|
6861
7263
|
"div",
|
|
6862
7264
|
{
|
|
6863
7265
|
"data-sidebar": "sidebar",
|
|
@@ -6878,7 +7280,7 @@ function SidebarTrigger({
|
|
|
6878
7280
|
...props
|
|
6879
7281
|
}) {
|
|
6880
7282
|
const { toggleSidebar } = useSidebar();
|
|
6881
|
-
return /* @__PURE__ */
|
|
7283
|
+
return /* @__PURE__ */ jsxs33(
|
|
6882
7284
|
Button,
|
|
6883
7285
|
{
|
|
6884
7286
|
"data-sidebar": "trigger",
|
|
@@ -6892,15 +7294,15 @@ function SidebarTrigger({
|
|
|
6892
7294
|
},
|
|
6893
7295
|
...props,
|
|
6894
7296
|
children: [
|
|
6895
|
-
/* @__PURE__ */
|
|
6896
|
-
/* @__PURE__ */
|
|
7297
|
+
/* @__PURE__ */ jsx55(PanelLeftIcon, {}),
|
|
7298
|
+
/* @__PURE__ */ jsx55("span", { className: "sr-only", children: "Toggle Sidebar" })
|
|
6897
7299
|
]
|
|
6898
7300
|
}
|
|
6899
7301
|
);
|
|
6900
7302
|
}
|
|
6901
7303
|
function SidebarRail({ className, ...props }) {
|
|
6902
7304
|
const { toggleSidebar } = useSidebar();
|
|
6903
|
-
return /* @__PURE__ */
|
|
7305
|
+
return /* @__PURE__ */ jsx55(
|
|
6904
7306
|
"button",
|
|
6905
7307
|
{
|
|
6906
7308
|
"data-sidebar": "rail",
|
|
@@ -6923,7 +7325,7 @@ function SidebarRail({ className, ...props }) {
|
|
|
6923
7325
|
);
|
|
6924
7326
|
}
|
|
6925
7327
|
function SidebarInset({ className, ...props }) {
|
|
6926
|
-
return /* @__PURE__ */
|
|
7328
|
+
return /* @__PURE__ */ jsx55(
|
|
6927
7329
|
"main",
|
|
6928
7330
|
{
|
|
6929
7331
|
"data-slot": "sidebar-inset",
|
|
@@ -6940,7 +7342,7 @@ function SidebarInput({
|
|
|
6940
7342
|
className,
|
|
6941
7343
|
...props
|
|
6942
7344
|
}) {
|
|
6943
|
-
return /* @__PURE__ */
|
|
7345
|
+
return /* @__PURE__ */ jsx55(
|
|
6944
7346
|
Input,
|
|
6945
7347
|
{
|
|
6946
7348
|
"data-slot": "sidebar-input",
|
|
@@ -6951,7 +7353,7 @@ function SidebarInput({
|
|
|
6951
7353
|
);
|
|
6952
7354
|
}
|
|
6953
7355
|
function SidebarHeader({ className, ...props }) {
|
|
6954
|
-
return /* @__PURE__ */
|
|
7356
|
+
return /* @__PURE__ */ jsx55(
|
|
6955
7357
|
"div",
|
|
6956
7358
|
{
|
|
6957
7359
|
"data-slot": "sidebar-header",
|
|
@@ -6962,7 +7364,7 @@ function SidebarHeader({ className, ...props }) {
|
|
|
6962
7364
|
);
|
|
6963
7365
|
}
|
|
6964
7366
|
function SidebarFooter({ className, ...props }) {
|
|
6965
|
-
return /* @__PURE__ */
|
|
7367
|
+
return /* @__PURE__ */ jsx55(
|
|
6966
7368
|
"div",
|
|
6967
7369
|
{
|
|
6968
7370
|
"data-slot": "sidebar-footer",
|
|
@@ -6976,7 +7378,7 @@ function SidebarSeparator({
|
|
|
6976
7378
|
className,
|
|
6977
7379
|
...props
|
|
6978
7380
|
}) {
|
|
6979
|
-
return /* @__PURE__ */
|
|
7381
|
+
return /* @__PURE__ */ jsx55(
|
|
6980
7382
|
Separator5,
|
|
6981
7383
|
{
|
|
6982
7384
|
"data-slot": "sidebar-separator",
|
|
@@ -6987,7 +7389,7 @@ function SidebarSeparator({
|
|
|
6987
7389
|
);
|
|
6988
7390
|
}
|
|
6989
7391
|
function SidebarContent({ className, ...props }) {
|
|
6990
|
-
return /* @__PURE__ */
|
|
7392
|
+
return /* @__PURE__ */ jsx55(
|
|
6991
7393
|
"div",
|
|
6992
7394
|
{
|
|
6993
7395
|
"data-slot": "sidebar-content",
|
|
@@ -7001,7 +7403,7 @@ function SidebarContent({ className, ...props }) {
|
|
|
7001
7403
|
);
|
|
7002
7404
|
}
|
|
7003
7405
|
function SidebarGroup({ className, ...props }) {
|
|
7004
|
-
return /* @__PURE__ */
|
|
7406
|
+
return /* @__PURE__ */ jsx55(
|
|
7005
7407
|
"div",
|
|
7006
7408
|
{
|
|
7007
7409
|
"data-slot": "sidebar-group",
|
|
@@ -7016,8 +7418,8 @@ function SidebarGroupLabel({
|
|
|
7016
7418
|
asChild = false,
|
|
7017
7419
|
...props
|
|
7018
7420
|
}) {
|
|
7019
|
-
const Comp = asChild ?
|
|
7020
|
-
return /* @__PURE__ */
|
|
7421
|
+
const Comp = asChild ? Slot7 : "div";
|
|
7422
|
+
return /* @__PURE__ */ jsx55(
|
|
7021
7423
|
Comp,
|
|
7022
7424
|
{
|
|
7023
7425
|
"data-slot": "sidebar-group-label",
|
|
@@ -7036,8 +7438,8 @@ function SidebarGroupAction({
|
|
|
7036
7438
|
asChild = false,
|
|
7037
7439
|
...props
|
|
7038
7440
|
}) {
|
|
7039
|
-
const Comp = asChild ?
|
|
7040
|
-
return /* @__PURE__ */
|
|
7441
|
+
const Comp = asChild ? Slot7 : "button";
|
|
7442
|
+
return /* @__PURE__ */ jsx55(
|
|
7041
7443
|
Comp,
|
|
7042
7444
|
{
|
|
7043
7445
|
"data-slot": "sidebar-group-action",
|
|
@@ -7057,7 +7459,7 @@ function SidebarGroupContent({
|
|
|
7057
7459
|
className,
|
|
7058
7460
|
...props
|
|
7059
7461
|
}) {
|
|
7060
|
-
return /* @__PURE__ */
|
|
7462
|
+
return /* @__PURE__ */ jsx55(
|
|
7061
7463
|
"div",
|
|
7062
7464
|
{
|
|
7063
7465
|
"data-slot": "sidebar-group-content",
|
|
@@ -7068,7 +7470,7 @@ function SidebarGroupContent({
|
|
|
7068
7470
|
);
|
|
7069
7471
|
}
|
|
7070
7472
|
function SidebarMenu({ className, ...props }) {
|
|
7071
|
-
return /* @__PURE__ */
|
|
7473
|
+
return /* @__PURE__ */ jsx55(
|
|
7072
7474
|
"ul",
|
|
7073
7475
|
{
|
|
7074
7476
|
"data-slot": "sidebar-menu",
|
|
@@ -7079,7 +7481,7 @@ function SidebarMenu({ className, ...props }) {
|
|
|
7079
7481
|
);
|
|
7080
7482
|
}
|
|
7081
7483
|
function SidebarMenuItem({ className, ...props }) {
|
|
7082
|
-
return /* @__PURE__ */
|
|
7484
|
+
return /* @__PURE__ */ jsx55(
|
|
7083
7485
|
"li",
|
|
7084
7486
|
{
|
|
7085
7487
|
"data-slot": "sidebar-menu-item",
|
|
@@ -7089,7 +7491,7 @@ function SidebarMenuItem({ className, ...props }) {
|
|
|
7089
7491
|
}
|
|
7090
7492
|
);
|
|
7091
7493
|
}
|
|
7092
|
-
var sidebarMenuButtonVariants =
|
|
7494
|
+
var sidebarMenuButtonVariants = cva14(
|
|
7093
7495
|
"peer/menu-button flex w-full items-center gap-2 overflow-hidden rounded-md p-2 text-left text-sm outline-hidden ring-sidebar-ring transition-[width,height,padding] hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 group-has-data-[sidebar=menu-action]/menu-item:pr-8 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-[active=true]:bg-sidebar-accent data-[active=true]:font-medium data-[active=true]:text-sidebar-accent-foreground data-[state=open]:hover:bg-sidebar-accent data-[state=open]:hover:text-sidebar-accent-foreground group-data-[collapsible=icon]:size-8! group-data-[collapsible=icon]:p-2! [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0",
|
|
7094
7496
|
{
|
|
7095
7497
|
variants: {
|
|
@@ -7118,9 +7520,9 @@ function SidebarMenuButton({
|
|
|
7118
7520
|
className,
|
|
7119
7521
|
...props
|
|
7120
7522
|
}) {
|
|
7121
|
-
const Comp = asChild ?
|
|
7523
|
+
const Comp = asChild ? Slot7 : "button";
|
|
7122
7524
|
const { isMobile, state } = useSidebar();
|
|
7123
|
-
const button = /* @__PURE__ */
|
|
7525
|
+
const button = /* @__PURE__ */ jsx55(
|
|
7124
7526
|
Comp,
|
|
7125
7527
|
{
|
|
7126
7528
|
"data-slot": "sidebar-menu-button",
|
|
@@ -7139,9 +7541,9 @@ function SidebarMenuButton({
|
|
|
7139
7541
|
children: tooltip
|
|
7140
7542
|
};
|
|
7141
7543
|
}
|
|
7142
|
-
return /* @__PURE__ */
|
|
7143
|
-
/* @__PURE__ */
|
|
7144
|
-
/* @__PURE__ */
|
|
7544
|
+
return /* @__PURE__ */ jsxs33(Tooltip2, { children: [
|
|
7545
|
+
/* @__PURE__ */ jsx55(TooltipTrigger, { asChild: true, children: button }),
|
|
7546
|
+
/* @__PURE__ */ jsx55(
|
|
7145
7547
|
TooltipContent,
|
|
7146
7548
|
{
|
|
7147
7549
|
side: "right",
|
|
@@ -7158,8 +7560,8 @@ function SidebarMenuAction({
|
|
|
7158
7560
|
showOnHover = false,
|
|
7159
7561
|
...props
|
|
7160
7562
|
}) {
|
|
7161
|
-
const Comp = asChild ?
|
|
7162
|
-
return /* @__PURE__ */
|
|
7563
|
+
const Comp = asChild ? Slot7 : "button";
|
|
7564
|
+
return /* @__PURE__ */ jsx55(
|
|
7163
7565
|
Comp,
|
|
7164
7566
|
{
|
|
7165
7567
|
"data-slot": "sidebar-menu-action",
|
|
@@ -7183,7 +7585,7 @@ function SidebarMenuBadge({
|
|
|
7183
7585
|
className,
|
|
7184
7586
|
...props
|
|
7185
7587
|
}) {
|
|
7186
|
-
return /* @__PURE__ */
|
|
7588
|
+
return /* @__PURE__ */ jsx55(
|
|
7187
7589
|
"div",
|
|
7188
7590
|
{
|
|
7189
7591
|
"data-slot": "sidebar-menu-badge",
|
|
@@ -7206,10 +7608,10 @@ function SidebarMenuSkeleton({
|
|
|
7206
7608
|
showIcon = false,
|
|
7207
7609
|
...props
|
|
7208
7610
|
}) {
|
|
7209
|
-
const width =
|
|
7611
|
+
const width = React53.useMemo(() => {
|
|
7210
7612
|
return `${Math.floor(Math.random() * 40) + 50}%`;
|
|
7211
7613
|
}, []);
|
|
7212
|
-
return /* @__PURE__ */
|
|
7614
|
+
return /* @__PURE__ */ jsxs33(
|
|
7213
7615
|
"div",
|
|
7214
7616
|
{
|
|
7215
7617
|
"data-slot": "sidebar-menu-skeleton",
|
|
@@ -7217,14 +7619,14 @@ function SidebarMenuSkeleton({
|
|
|
7217
7619
|
className: cn("flex h-8 items-center gap-2 rounded-md px-2", className),
|
|
7218
7620
|
...props,
|
|
7219
7621
|
children: [
|
|
7220
|
-
showIcon && /* @__PURE__ */
|
|
7622
|
+
showIcon && /* @__PURE__ */ jsx55(
|
|
7221
7623
|
Skeleton,
|
|
7222
7624
|
{
|
|
7223
7625
|
className: "size-4 rounded-md",
|
|
7224
7626
|
"data-sidebar": "menu-skeleton-icon"
|
|
7225
7627
|
}
|
|
7226
7628
|
),
|
|
7227
|
-
/* @__PURE__ */
|
|
7629
|
+
/* @__PURE__ */ jsx55(
|
|
7228
7630
|
Skeleton,
|
|
7229
7631
|
{
|
|
7230
7632
|
className: "h-4 max-w-(--skeleton-width) flex-1",
|
|
@@ -7239,7 +7641,7 @@ function SidebarMenuSkeleton({
|
|
|
7239
7641
|
);
|
|
7240
7642
|
}
|
|
7241
7643
|
function SidebarMenuSub({ className, ...props }) {
|
|
7242
|
-
return /* @__PURE__ */
|
|
7644
|
+
return /* @__PURE__ */ jsx55(
|
|
7243
7645
|
"ul",
|
|
7244
7646
|
{
|
|
7245
7647
|
"data-slot": "sidebar-menu-sub",
|
|
@@ -7257,7 +7659,7 @@ function SidebarMenuSubItem({
|
|
|
7257
7659
|
className,
|
|
7258
7660
|
...props
|
|
7259
7661
|
}) {
|
|
7260
|
-
return /* @__PURE__ */
|
|
7662
|
+
return /* @__PURE__ */ jsx55(
|
|
7261
7663
|
"li",
|
|
7262
7664
|
{
|
|
7263
7665
|
"data-slot": "sidebar-menu-sub-item",
|
|
@@ -7274,8 +7676,8 @@ function SidebarMenuSubButton({
|
|
|
7274
7676
|
className,
|
|
7275
7677
|
...props
|
|
7276
7678
|
}) {
|
|
7277
|
-
const Comp = asChild ?
|
|
7278
|
-
return /* @__PURE__ */
|
|
7679
|
+
const Comp = asChild ? Slot7 : "a";
|
|
7680
|
+
return /* @__PURE__ */ jsx55(
|
|
7279
7681
|
Comp,
|
|
7280
7682
|
{
|
|
7281
7683
|
"data-slot": "sidebar-menu-sub-button",
|
|
@@ -7296,9 +7698,9 @@ function SidebarMenuSubButton({
|
|
|
7296
7698
|
}
|
|
7297
7699
|
|
|
7298
7700
|
// src/components/ui/slider.tsx
|
|
7299
|
-
import * as
|
|
7701
|
+
import * as React54 from "react";
|
|
7300
7702
|
import * as SliderPrimitive from "@radix-ui/react-slider";
|
|
7301
|
-
import { jsx as
|
|
7703
|
+
import { jsx as jsx56, jsxs as jsxs34 } from "react/jsx-runtime";
|
|
7302
7704
|
function Slider({
|
|
7303
7705
|
className,
|
|
7304
7706
|
defaultValue,
|
|
@@ -7307,11 +7709,11 @@ function Slider({
|
|
|
7307
7709
|
max = 100,
|
|
7308
7710
|
...props
|
|
7309
7711
|
}) {
|
|
7310
|
-
const _values =
|
|
7712
|
+
const _values = React54.useMemo(
|
|
7311
7713
|
() => Array.isArray(value) ? value : Array.isArray(defaultValue) ? defaultValue : [min, max],
|
|
7312
7714
|
[value, defaultValue, min, max]
|
|
7313
7715
|
);
|
|
7314
|
-
return /* @__PURE__ */
|
|
7716
|
+
return /* @__PURE__ */ jsxs34(
|
|
7315
7717
|
SliderPrimitive.Root,
|
|
7316
7718
|
{
|
|
7317
7719
|
"data-slot": "slider",
|
|
@@ -7325,14 +7727,14 @@ function Slider({
|
|
|
7325
7727
|
),
|
|
7326
7728
|
...props,
|
|
7327
7729
|
children: [
|
|
7328
|
-
/* @__PURE__ */
|
|
7730
|
+
/* @__PURE__ */ jsx56(
|
|
7329
7731
|
SliderPrimitive.Track,
|
|
7330
7732
|
{
|
|
7331
7733
|
"data-slot": "slider-track",
|
|
7332
7734
|
className: cn(
|
|
7333
7735
|
"bg-muted relative grow overflow-hidden rounded-full data-[orientation=horizontal]:h-1.5 data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-1.5"
|
|
7334
7736
|
),
|
|
7335
|
-
children: /* @__PURE__ */
|
|
7737
|
+
children: /* @__PURE__ */ jsx56(
|
|
7336
7738
|
SliderPrimitive.Range,
|
|
7337
7739
|
{
|
|
7338
7740
|
"data-slot": "slider-range",
|
|
@@ -7343,7 +7745,7 @@ function Slider({
|
|
|
7343
7745
|
)
|
|
7344
7746
|
}
|
|
7345
7747
|
),
|
|
7346
|
-
Array.from({ length: _values.length }, (_, index) => /* @__PURE__ */
|
|
7748
|
+
Array.from({ length: _values.length }, (_, index) => /* @__PURE__ */ jsx56(
|
|
7347
7749
|
SliderPrimitive.Thumb,
|
|
7348
7750
|
{
|
|
7349
7751
|
"data-slot": "slider-thumb",
|
|
@@ -7360,9 +7762,9 @@ function Slider({
|
|
|
7360
7762
|
import "react";
|
|
7361
7763
|
|
|
7362
7764
|
// src/components/ui/useMediaQuery.ts
|
|
7363
|
-
import * as
|
|
7765
|
+
import * as React55 from "react";
|
|
7364
7766
|
function useMediaQuery(query) {
|
|
7365
|
-
const subscribe =
|
|
7767
|
+
const subscribe = React55.useCallback(
|
|
7366
7768
|
(onStoreChange) => {
|
|
7367
7769
|
const list = window.matchMedia(query);
|
|
7368
7770
|
if (list.addEventListener) {
|
|
@@ -7374,19 +7776,19 @@ function useMediaQuery(query) {
|
|
|
7374
7776
|
},
|
|
7375
7777
|
[query]
|
|
7376
7778
|
);
|
|
7377
|
-
const getSnapshot =
|
|
7779
|
+
const getSnapshot = React55.useCallback(
|
|
7378
7780
|
() => window.matchMedia(query).matches,
|
|
7379
7781
|
[query]
|
|
7380
7782
|
);
|
|
7381
|
-
const getServerSnapshot =
|
|
7382
|
-
return
|
|
7783
|
+
const getServerSnapshot = React55.useCallback(() => false, []);
|
|
7784
|
+
return React55.useSyncExternalStore(subscribe, getSnapshot, getServerSnapshot);
|
|
7383
7785
|
}
|
|
7384
7786
|
|
|
7385
7787
|
// src/components/ui/smart-dialog-drawer.tsx
|
|
7386
|
-
import { Fragment as Fragment4, jsx as
|
|
7788
|
+
import { Fragment as Fragment4, jsx as jsx57 } from "react/jsx-runtime";
|
|
7387
7789
|
var SmartDialog = ({ children, ...props }) => {
|
|
7388
7790
|
const isMobile = useMediaQuery("(max-width: 600px)");
|
|
7389
|
-
return isMobile ? /* @__PURE__ */
|
|
7791
|
+
return isMobile ? /* @__PURE__ */ jsx57(Drawer, { ...props, children }) : /* @__PURE__ */ jsx57(Dialog, { ...props, children });
|
|
7390
7792
|
};
|
|
7391
7793
|
var SmartDialogContent = ({
|
|
7392
7794
|
children,
|
|
@@ -7396,7 +7798,7 @@ var SmartDialogContent = ({
|
|
|
7396
7798
|
...props
|
|
7397
7799
|
}) => {
|
|
7398
7800
|
const isMobile = useMediaQuery("(max-width: 600px)");
|
|
7399
|
-
return isMobile ? /* @__PURE__ */
|
|
7801
|
+
return isMobile ? /* @__PURE__ */ jsx57(
|
|
7400
7802
|
DrawerContent,
|
|
7401
7803
|
{
|
|
7402
7804
|
...props,
|
|
@@ -7405,7 +7807,7 @@ var SmartDialogContent = ({
|
|
|
7405
7807
|
showCloseButton: showCloseButton ?? true,
|
|
7406
7808
|
children
|
|
7407
7809
|
}
|
|
7408
|
-
) : /* @__PURE__ */
|
|
7810
|
+
) : /* @__PURE__ */ jsx57(
|
|
7409
7811
|
DialogContent,
|
|
7410
7812
|
{
|
|
7411
7813
|
...props,
|
|
@@ -7420,49 +7822,49 @@ var SmartDialogDescription = ({
|
|
|
7420
7822
|
...props
|
|
7421
7823
|
}) => {
|
|
7422
7824
|
const isMobile = useMediaQuery("(max-width: 600px)");
|
|
7423
|
-
return isMobile ? /* @__PURE__ */
|
|
7825
|
+
return isMobile ? /* @__PURE__ */ jsx57(DrawerDescription, { ...props, children }) : /* @__PURE__ */ jsx57(DialogDescription, { ...props, children });
|
|
7424
7826
|
};
|
|
7425
7827
|
var SmartDialogHeader = ({ children, ...props }) => {
|
|
7426
7828
|
const isMobile = useMediaQuery("(max-width: 600px)");
|
|
7427
|
-
return isMobile ? /* @__PURE__ */
|
|
7829
|
+
return isMobile ? /* @__PURE__ */ jsx57(DrawerHeader, { ...props, children }) : /* @__PURE__ */ jsx57(DialogHeader, { ...props, children });
|
|
7428
7830
|
};
|
|
7429
7831
|
var SmartDialogTitle = ({ children, ...props }) => {
|
|
7430
7832
|
const isMobile = useMediaQuery("(max-width: 600px)");
|
|
7431
|
-
return isMobile ? /* @__PURE__ */
|
|
7833
|
+
return isMobile ? /* @__PURE__ */ jsx57(DrawerTitle, { ...props, children }) : /* @__PURE__ */ jsx57(DialogTitle, { ...props, children });
|
|
7432
7834
|
};
|
|
7433
7835
|
var SmartDialogTrigger = ({
|
|
7434
7836
|
children,
|
|
7435
7837
|
...props
|
|
7436
7838
|
}) => {
|
|
7437
7839
|
const isMobile = useMediaQuery("(max-width: 600px)");
|
|
7438
|
-
return isMobile ? /* @__PURE__ */
|
|
7840
|
+
return isMobile ? /* @__PURE__ */ jsx57(DrawerTrigger, { ...props, children }) : /* @__PURE__ */ jsx57(DialogTrigger, { ...props, children });
|
|
7439
7841
|
};
|
|
7440
7842
|
var SmartDialogFooter = ({ children, ...props }) => {
|
|
7441
7843
|
const isMobile = useMediaQuery("(max-width: 600px)");
|
|
7442
|
-
return isMobile ? /* @__PURE__ */
|
|
7844
|
+
return isMobile ? /* @__PURE__ */ jsx57(DrawerFooter, { ...props, children }) : /* @__PURE__ */ jsx57(DialogFooter, { ...props, children });
|
|
7443
7845
|
};
|
|
7444
7846
|
var SmartDialogClose = ({ children, ...props }) => {
|
|
7445
7847
|
const isMobile = useMediaQuery("(max-width: 600px)");
|
|
7446
|
-
return isMobile ? /* @__PURE__ */
|
|
7848
|
+
return isMobile ? /* @__PURE__ */ jsx57(Fragment4, { children: /* @__PURE__ */ jsx57(DrawerClose, { ...props, children }) }) : /* @__PURE__ */ jsx57(DialogClose, { ...props, children });
|
|
7447
7849
|
};
|
|
7448
7850
|
|
|
7449
7851
|
// src/components/ui/sonner.tsx
|
|
7450
7852
|
import { CircleCheck, Info, TriangleAlert } from "lucide-react";
|
|
7451
7853
|
import { useTheme } from "next-themes";
|
|
7452
7854
|
import { Toaster as Sonner, toast } from "sonner";
|
|
7453
|
-
import { jsx as
|
|
7454
|
-
var iconWrapper = (icon) => /* @__PURE__ */
|
|
7855
|
+
import { jsx as jsx58 } from "react/jsx-runtime";
|
|
7856
|
+
var iconWrapper = (icon) => /* @__PURE__ */ jsx58("span", { className: "flex items-center justify-center shrink-0 size-5 [&_svg]:size-5", children: icon });
|
|
7455
7857
|
var Toaster = ({ ...props }) => {
|
|
7456
7858
|
const { theme = "system" } = useTheme();
|
|
7457
|
-
return /* @__PURE__ */
|
|
7859
|
+
return /* @__PURE__ */ jsx58(
|
|
7458
7860
|
Sonner,
|
|
7459
7861
|
{
|
|
7460
7862
|
theme,
|
|
7461
7863
|
className: "toaster group",
|
|
7462
7864
|
icons: {
|
|
7463
|
-
info: iconWrapper(/* @__PURE__ */
|
|
7464
|
-
error: iconWrapper(/* @__PURE__ */
|
|
7465
|
-
success: iconWrapper(/* @__PURE__ */
|
|
7865
|
+
info: iconWrapper(/* @__PURE__ */ jsx58(Info, {})),
|
|
7866
|
+
error: iconWrapper(/* @__PURE__ */ jsx58(TriangleAlert, {})),
|
|
7867
|
+
success: iconWrapper(/* @__PURE__ */ jsx58(CircleCheck, {}))
|
|
7466
7868
|
},
|
|
7467
7869
|
toastOptions: {
|
|
7468
7870
|
unstyled: true,
|
|
@@ -7486,12 +7888,12 @@ var Toaster = ({ ...props }) => {
|
|
|
7486
7888
|
// src/components/ui/switch.tsx
|
|
7487
7889
|
import * as SwitchPrimitive from "@radix-ui/react-switch";
|
|
7488
7890
|
import "react";
|
|
7489
|
-
import { jsx as
|
|
7891
|
+
import { jsx as jsx59 } from "react/jsx-runtime";
|
|
7490
7892
|
function Switch({
|
|
7491
7893
|
className,
|
|
7492
7894
|
...props
|
|
7493
7895
|
}) {
|
|
7494
|
-
return /* @__PURE__ */
|
|
7896
|
+
return /* @__PURE__ */ jsx59(
|
|
7495
7897
|
SwitchPrimitive.Root,
|
|
7496
7898
|
{
|
|
7497
7899
|
"data-slot": "switch",
|
|
@@ -7500,7 +7902,7 @@ function Switch({
|
|
|
7500
7902
|
className
|
|
7501
7903
|
),
|
|
7502
7904
|
...props,
|
|
7503
|
-
children: /* @__PURE__ */
|
|
7905
|
+
children: /* @__PURE__ */ jsx59(
|
|
7504
7906
|
SwitchPrimitive.Thumb,
|
|
7505
7907
|
{
|
|
7506
7908
|
"data-slot": "switch-thumb",
|
|
@@ -7515,14 +7917,14 @@ function Switch({
|
|
|
7515
7917
|
|
|
7516
7918
|
// src/components/ui/table.tsx
|
|
7517
7919
|
import "react";
|
|
7518
|
-
import { jsx as
|
|
7920
|
+
import { jsx as jsx60 } from "react/jsx-runtime";
|
|
7519
7921
|
function Table({ className, ...props }) {
|
|
7520
|
-
return /* @__PURE__ */
|
|
7922
|
+
return /* @__PURE__ */ jsx60(
|
|
7521
7923
|
"div",
|
|
7522
7924
|
{
|
|
7523
7925
|
"data-slot": "table-container",
|
|
7524
7926
|
className: "relative w-full overflow-x-auto",
|
|
7525
|
-
children: /* @__PURE__ */
|
|
7927
|
+
children: /* @__PURE__ */ jsx60(
|
|
7526
7928
|
"table",
|
|
7527
7929
|
{
|
|
7528
7930
|
"data-slot": "table",
|
|
@@ -7534,7 +7936,7 @@ function Table({ className, ...props }) {
|
|
|
7534
7936
|
);
|
|
7535
7937
|
}
|
|
7536
7938
|
function TableHeader({ className, ...props }) {
|
|
7537
|
-
return /* @__PURE__ */
|
|
7939
|
+
return /* @__PURE__ */ jsx60(
|
|
7538
7940
|
"thead",
|
|
7539
7941
|
{
|
|
7540
7942
|
"data-slot": "table-header",
|
|
@@ -7544,7 +7946,7 @@ function TableHeader({ className, ...props }) {
|
|
|
7544
7946
|
);
|
|
7545
7947
|
}
|
|
7546
7948
|
function TableBody({ className, ...props }) {
|
|
7547
|
-
return /* @__PURE__ */
|
|
7949
|
+
return /* @__PURE__ */ jsx60(
|
|
7548
7950
|
"tbody",
|
|
7549
7951
|
{
|
|
7550
7952
|
"data-slot": "table-body",
|
|
@@ -7554,7 +7956,7 @@ function TableBody({ className, ...props }) {
|
|
|
7554
7956
|
);
|
|
7555
7957
|
}
|
|
7556
7958
|
function TableFooter({ className, ...props }) {
|
|
7557
|
-
return /* @__PURE__ */
|
|
7959
|
+
return /* @__PURE__ */ jsx60(
|
|
7558
7960
|
"tfoot",
|
|
7559
7961
|
{
|
|
7560
7962
|
"data-slot": "table-footer",
|
|
@@ -7567,7 +7969,7 @@ function TableFooter({ className, ...props }) {
|
|
|
7567
7969
|
);
|
|
7568
7970
|
}
|
|
7569
7971
|
function TableRow({ className, ...props }) {
|
|
7570
|
-
return /* @__PURE__ */
|
|
7972
|
+
return /* @__PURE__ */ jsx60(
|
|
7571
7973
|
"tr",
|
|
7572
7974
|
{
|
|
7573
7975
|
"data-slot": "table-row",
|
|
@@ -7580,7 +7982,7 @@ function TableRow({ className, ...props }) {
|
|
|
7580
7982
|
);
|
|
7581
7983
|
}
|
|
7582
7984
|
function TableHead({ className, ...props }) {
|
|
7583
|
-
return /* @__PURE__ */
|
|
7985
|
+
return /* @__PURE__ */ jsx60(
|
|
7584
7986
|
"th",
|
|
7585
7987
|
{
|
|
7586
7988
|
"data-slot": "table-head",
|
|
@@ -7593,7 +7995,7 @@ function TableHead({ className, ...props }) {
|
|
|
7593
7995
|
);
|
|
7594
7996
|
}
|
|
7595
7997
|
function TableCell({ className, ...props }) {
|
|
7596
|
-
return /* @__PURE__ */
|
|
7998
|
+
return /* @__PURE__ */ jsx60(
|
|
7597
7999
|
"td",
|
|
7598
8000
|
{
|
|
7599
8001
|
"data-slot": "table-cell",
|
|
@@ -7609,7 +8011,7 @@ function TableCaption({
|
|
|
7609
8011
|
className,
|
|
7610
8012
|
...props
|
|
7611
8013
|
}) {
|
|
7612
|
-
return /* @__PURE__ */
|
|
8014
|
+
return /* @__PURE__ */ jsx60(
|
|
7613
8015
|
"caption",
|
|
7614
8016
|
{
|
|
7615
8017
|
"data-slot": "table-caption",
|
|
@@ -7621,19 +8023,19 @@ function TableCaption({
|
|
|
7621
8023
|
|
|
7622
8024
|
// src/components/ui/tabs.tsx
|
|
7623
8025
|
import * as TabsPrimitive from "@radix-ui/react-tabs";
|
|
7624
|
-
import { cva as
|
|
7625
|
-
import * as
|
|
7626
|
-
import { jsx as
|
|
7627
|
-
var TabsContext =
|
|
8026
|
+
import { cva as cva15 } from "class-variance-authority";
|
|
8027
|
+
import * as React59 from "react";
|
|
8028
|
+
import { jsx as jsx61, jsxs as jsxs35 } from "react/jsx-runtime";
|
|
8029
|
+
var TabsContext = React59.createContext({
|
|
7628
8030
|
orientation: "horizontal"
|
|
7629
8031
|
});
|
|
7630
8032
|
function useTabIndicator(listRef, orientation) {
|
|
7631
|
-
const [style, setStyle] =
|
|
8033
|
+
const [style, setStyle] = React59.useState({
|
|
7632
8034
|
position: "absolute",
|
|
7633
8035
|
opacity: 0
|
|
7634
8036
|
});
|
|
7635
|
-
const isFirstMeasurement =
|
|
7636
|
-
const measure =
|
|
8037
|
+
const isFirstMeasurement = React59.useRef(true);
|
|
8038
|
+
const measure = React59.useCallback(() => {
|
|
7637
8039
|
const list = listRef.current;
|
|
7638
8040
|
if (!list) return;
|
|
7639
8041
|
requestAnimationFrame(() => {
|
|
@@ -7674,7 +8076,7 @@ function useTabIndicator(listRef, orientation) {
|
|
|
7674
8076
|
}
|
|
7675
8077
|
});
|
|
7676
8078
|
}, [listRef, orientation]);
|
|
7677
|
-
|
|
8079
|
+
React59.useEffect(() => {
|
|
7678
8080
|
const list = listRef.current;
|
|
7679
8081
|
if (!list) return;
|
|
7680
8082
|
measure();
|
|
@@ -7703,11 +8105,11 @@ function Tabs({
|
|
|
7703
8105
|
orientation = "horizontal",
|
|
7704
8106
|
...props
|
|
7705
8107
|
}) {
|
|
7706
|
-
const ctx =
|
|
8108
|
+
const ctx = React59.useMemo(
|
|
7707
8109
|
() => ({ orientation: orientation ?? "horizontal" }),
|
|
7708
8110
|
[orientation]
|
|
7709
8111
|
);
|
|
7710
|
-
return /* @__PURE__ */
|
|
8112
|
+
return /* @__PURE__ */ jsx61(TabsContext.Provider, { value: ctx, children: /* @__PURE__ */ jsx61(
|
|
7711
8113
|
TabsPrimitive.Root,
|
|
7712
8114
|
{
|
|
7713
8115
|
"data-slot": "tabs",
|
|
@@ -7724,10 +8126,10 @@ function TabsList({
|
|
|
7724
8126
|
className,
|
|
7725
8127
|
...props
|
|
7726
8128
|
}) {
|
|
7727
|
-
const listRef =
|
|
7728
|
-
const { orientation } =
|
|
8129
|
+
const listRef = React59.useRef(null);
|
|
8130
|
+
const { orientation } = React59.useContext(TabsContext);
|
|
7729
8131
|
const { style: indicatorStyle } = useTabIndicator(listRef, orientation);
|
|
7730
|
-
return /* @__PURE__ */
|
|
8132
|
+
return /* @__PURE__ */ jsxs35(
|
|
7731
8133
|
TabsPrimitive.List,
|
|
7732
8134
|
{
|
|
7733
8135
|
ref: listRef,
|
|
@@ -7742,12 +8144,12 @@ function TabsList({
|
|
|
7742
8144
|
...props,
|
|
7743
8145
|
children: [
|
|
7744
8146
|
props.children,
|
|
7745
|
-
/* @__PURE__ */
|
|
8147
|
+
/* @__PURE__ */ jsx61("span", { "data-slot": "tabs-indicator", style: indicatorStyle })
|
|
7746
8148
|
]
|
|
7747
8149
|
}
|
|
7748
8150
|
);
|
|
7749
8151
|
}
|
|
7750
|
-
var tabsTriggerVariants =
|
|
8152
|
+
var tabsTriggerVariants = cva15(
|
|
7751
8153
|
"cursor-pointer inline-flex shrink-0 items-center justify-center font-sans font-medium whitespace-nowrap transition-[color,box-shadow] text-vibrant-text-details data-[state=active]:font-semibold data-[state=active]:text-vibrant-text-heading disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*=size-])]:size-4",
|
|
7752
8154
|
{
|
|
7753
8155
|
variants: {
|
|
@@ -7776,14 +8178,14 @@ function TabsTrigger({
|
|
|
7776
8178
|
children,
|
|
7777
8179
|
...props
|
|
7778
8180
|
}) {
|
|
7779
|
-
const { orientation } =
|
|
7780
|
-
return /* @__PURE__ */
|
|
8181
|
+
const { orientation } = React59.useContext(TabsContext);
|
|
8182
|
+
return /* @__PURE__ */ jsx61(
|
|
7781
8183
|
TabsPrimitive.Trigger,
|
|
7782
8184
|
{
|
|
7783
8185
|
"data-slot": "tabs-trigger",
|
|
7784
8186
|
className: cn(tabsTriggerVariants({ size, orientation }), className),
|
|
7785
8187
|
...props,
|
|
7786
|
-
children: /* @__PURE__ */
|
|
8188
|
+
children: /* @__PURE__ */ jsx61(
|
|
7787
8189
|
"span",
|
|
7788
8190
|
{
|
|
7789
8191
|
className: cn(
|
|
@@ -7800,7 +8202,7 @@ function TabsContent({
|
|
|
7800
8202
|
className,
|
|
7801
8203
|
...props
|
|
7802
8204
|
}) {
|
|
7803
|
-
return /* @__PURE__ */
|
|
8205
|
+
return /* @__PURE__ */ jsx61(
|
|
7804
8206
|
TabsPrimitive.Content,
|
|
7805
8207
|
{
|
|
7806
8208
|
"data-slot": "tabs-content",
|
|
@@ -7814,9 +8216,9 @@ function TabsContent({
|
|
|
7814
8216
|
import {
|
|
7815
8217
|
ThemeProvider as NextThemesProvider
|
|
7816
8218
|
} from "next-themes";
|
|
7817
|
-
import { jsx as
|
|
8219
|
+
import { jsx as jsx62 } from "react/jsx-runtime";
|
|
7818
8220
|
function ThemeProvider({ children, ...props }) {
|
|
7819
|
-
return /* @__PURE__ */
|
|
8221
|
+
return /* @__PURE__ */ jsx62(
|
|
7820
8222
|
NextThemesProvider,
|
|
7821
8223
|
{
|
|
7822
8224
|
attribute: "class",
|
|
@@ -7833,29 +8235,29 @@ function ThemeProvider({ children, ...props }) {
|
|
|
7833
8235
|
import { Monitor, Moon, Sun } from "lucide-react";
|
|
7834
8236
|
import { useTheme as useTheme2 } from "next-themes";
|
|
7835
8237
|
import "react";
|
|
7836
|
-
import { jsx as
|
|
8238
|
+
import { jsx as jsx63, jsxs as jsxs36 } from "react/jsx-runtime";
|
|
7837
8239
|
function ThemeToggle({
|
|
7838
8240
|
className,
|
|
7839
8241
|
...props
|
|
7840
8242
|
}) {
|
|
7841
8243
|
const { setTheme } = useTheme2();
|
|
7842
|
-
return /* @__PURE__ */
|
|
7843
|
-
/* @__PURE__ */
|
|
7844
|
-
/* @__PURE__ */
|
|
7845
|
-
/* @__PURE__ */
|
|
7846
|
-
/* @__PURE__ */
|
|
8244
|
+
return /* @__PURE__ */ jsxs36(DropdownMenu, { children: [
|
|
8245
|
+
/* @__PURE__ */ jsx63(DropdownMenuTrigger, { asChild: true, children: /* @__PURE__ */ jsxs36(Button, { variant: "outline", size: "icon", className, ...props, children: [
|
|
8246
|
+
/* @__PURE__ */ jsx63(Sun, { className: "size-4 rotate-0 scale-100 transition-all dark:-rotate-90 dark:scale-0" }),
|
|
8247
|
+
/* @__PURE__ */ jsx63(Moon, { className: "absolute size-4 rotate-90 scale-0 transition-all dark:rotate-0 dark:scale-100" }),
|
|
8248
|
+
/* @__PURE__ */ jsx63("span", { className: "sr-only", children: "Toggle theme" })
|
|
7847
8249
|
] }) }),
|
|
7848
|
-
/* @__PURE__ */
|
|
7849
|
-
/* @__PURE__ */
|
|
7850
|
-
/* @__PURE__ */
|
|
8250
|
+
/* @__PURE__ */ jsxs36(DropdownMenuContent, { align: "end", children: [
|
|
8251
|
+
/* @__PURE__ */ jsxs36(DropdownMenuItem, { onClick: () => setTheme("light"), children: [
|
|
8252
|
+
/* @__PURE__ */ jsx63(Sun, { className: "size-4" }),
|
|
7851
8253
|
"Light"
|
|
7852
8254
|
] }),
|
|
7853
|
-
/* @__PURE__ */
|
|
7854
|
-
/* @__PURE__ */
|
|
8255
|
+
/* @__PURE__ */ jsxs36(DropdownMenuItem, { onClick: () => setTheme("dark"), children: [
|
|
8256
|
+
/* @__PURE__ */ jsx63(Moon, { className: "size-4" }),
|
|
7855
8257
|
"Dark"
|
|
7856
8258
|
] }),
|
|
7857
|
-
/* @__PURE__ */
|
|
7858
|
-
/* @__PURE__ */
|
|
8259
|
+
/* @__PURE__ */ jsxs36(DropdownMenuItem, { onClick: () => setTheme("system"), children: [
|
|
8260
|
+
/* @__PURE__ */ jsx63(Monitor, { className: "size-4" }),
|
|
7859
8261
|
"System"
|
|
7860
8262
|
] })
|
|
7861
8263
|
] })
|
|
@@ -7865,8 +8267,8 @@ function ThemeToggle({
|
|
|
7865
8267
|
// src/components/ui/time-input.tsx
|
|
7866
8268
|
import "class-variance-authority";
|
|
7867
8269
|
import { Clock } from "lucide-react";
|
|
7868
|
-
import * as
|
|
7869
|
-
import { jsx as
|
|
8270
|
+
import * as React61 from "react";
|
|
8271
|
+
import { jsx as jsx64, jsxs as jsxs37 } from "react/jsx-runtime";
|
|
7870
8272
|
var TIME_FORMAT_PLACEHOLDER = {
|
|
7871
8273
|
"12h": "hh:mm AM/PM",
|
|
7872
8274
|
"24h": "HH:mm",
|
|
@@ -7919,16 +8321,16 @@ function TimeInput({
|
|
|
7919
8321
|
formatDisplay
|
|
7920
8322
|
}) {
|
|
7921
8323
|
const resolvedPlaceholder = placeholder ?? TIME_FORMAT_PLACEHOLDER[timeFormat];
|
|
7922
|
-
const displayValue =
|
|
8324
|
+
const displayValue = React61.useMemo(() => {
|
|
7923
8325
|
if (!time) return "";
|
|
7924
8326
|
if (formatDisplay) return formatDisplay(time);
|
|
7925
8327
|
return formatTime(time, timeFormat);
|
|
7926
8328
|
}, [time, formatDisplay, timeFormat]);
|
|
7927
|
-
const [open, setOpen] =
|
|
7928
|
-
const hoursRef =
|
|
7929
|
-
const minutesRef =
|
|
7930
|
-
const periodRef =
|
|
7931
|
-
const scrollToSelected =
|
|
8329
|
+
const [open, setOpen] = React61.useState(false);
|
|
8330
|
+
const hoursRef = React61.useRef(null);
|
|
8331
|
+
const minutesRef = React61.useRef(null);
|
|
8332
|
+
const periodRef = React61.useRef(null);
|
|
8333
|
+
const scrollToSelected = React61.useCallback(() => {
|
|
7932
8334
|
requestAnimationFrame(() => {
|
|
7933
8335
|
for (const ref of [hoursRef, minutesRef, periodRef]) {
|
|
7934
8336
|
const container = ref.current;
|
|
@@ -7940,7 +8342,7 @@ function TimeInput({
|
|
|
7940
8342
|
}
|
|
7941
8343
|
});
|
|
7942
8344
|
}, []);
|
|
7943
|
-
|
|
8345
|
+
React61.useEffect(() => {
|
|
7944
8346
|
if (open) {
|
|
7945
8347
|
scrollToSelected();
|
|
7946
8348
|
}
|
|
@@ -7976,8 +8378,8 @@ function TimeInput({
|
|
|
7976
8378
|
const selectedH12 = time ? getDisplayHour(time.hours, timeFormat) : null;
|
|
7977
8379
|
const selectedMinute = time?.minutes ?? null;
|
|
7978
8380
|
const selectedPeriod = time ? getPeriod(time.hours) : null;
|
|
7979
|
-
return /* @__PURE__ */
|
|
7980
|
-
/* @__PURE__ */
|
|
8381
|
+
return /* @__PURE__ */ jsx64("div", { className: cn("relative flex gap-2", className), children: /* @__PURE__ */ jsxs37(Popover, { open, onOpenChange: setOpen, children: [
|
|
8382
|
+
/* @__PURE__ */ jsx64(PopoverTrigger, { asChild: true, disabled: inputDisabled, children: /* @__PURE__ */ jsxs37(
|
|
7981
8383
|
Button,
|
|
7982
8384
|
{
|
|
7983
8385
|
type: "button",
|
|
@@ -7992,18 +8394,18 @@ function TimeInput({
|
|
|
7992
8394
|
disabled: inputDisabled,
|
|
7993
8395
|
children: [
|
|
7994
8396
|
displayValue || resolvedPlaceholder,
|
|
7995
|
-
icon !== void 0 ? icon : /* @__PURE__ */
|
|
8397
|
+
icon !== void 0 ? icon : /* @__PURE__ */ jsx64(Clock, { className: "h-4 w-4 text-muted-foreground shrink-0" })
|
|
7996
8398
|
]
|
|
7997
8399
|
}
|
|
7998
8400
|
) }),
|
|
7999
|
-
/* @__PURE__ */
|
|
8401
|
+
/* @__PURE__ */ jsx64(
|
|
8000
8402
|
PopoverContent,
|
|
8001
8403
|
{
|
|
8002
8404
|
className: cn("w-auto p-0", popoverContentClassName),
|
|
8003
8405
|
onOpenAutoFocus: (e) => e.preventDefault(),
|
|
8004
8406
|
...popoverContentProps,
|
|
8005
|
-
children: /* @__PURE__ */
|
|
8006
|
-
/* @__PURE__ */
|
|
8407
|
+
children: /* @__PURE__ */ jsxs37("div", { className: "flex divide-x border border-focus-ring rounded-md", children: [
|
|
8408
|
+
/* @__PURE__ */ jsx64("div", { className: "h-56 w-16 overflow-y-auto overscroll-y-contain [-webkit-overflow-scrolling:touch]", children: /* @__PURE__ */ jsx64("div", { ref: hoursRef, className: "flex flex-col p-1 ", children: hoursList.map((h) => /* @__PURE__ */ jsx64(
|
|
8007
8409
|
Button,
|
|
8008
8410
|
{
|
|
8009
8411
|
variant: "ghost",
|
|
@@ -8018,7 +8420,7 @@ function TimeInput({
|
|
|
8018
8420
|
},
|
|
8019
8421
|
h
|
|
8020
8422
|
)) }) }),
|
|
8021
|
-
/* @__PURE__ */
|
|
8423
|
+
/* @__PURE__ */ jsx64("div", { className: "h-56 w-16 overflow-y-auto overscroll-y-contain [-webkit-overflow-scrolling:touch]", children: /* @__PURE__ */ jsx64(
|
|
8022
8424
|
"div",
|
|
8023
8425
|
{
|
|
8024
8426
|
ref: minutesRef,
|
|
@@ -8026,7 +8428,7 @@ function TimeInput({
|
|
|
8026
8428
|
"flex flex-col p-1",
|
|
8027
8429
|
minutesList.length <= 12 && "h-full justify-center"
|
|
8028
8430
|
),
|
|
8029
|
-
children: minutesList.map((m) => /* @__PURE__ */
|
|
8431
|
+
children: minutesList.map((m) => /* @__PURE__ */ jsx64(
|
|
8030
8432
|
Button,
|
|
8031
8433
|
{
|
|
8032
8434
|
variant: "ghost",
|
|
@@ -8043,7 +8445,7 @@ function TimeInput({
|
|
|
8043
8445
|
))
|
|
8044
8446
|
}
|
|
8045
8447
|
) }),
|
|
8046
|
-
!is24HourFormat(timeFormat) && /* @__PURE__ */
|
|
8448
|
+
!is24HourFormat(timeFormat) && /* @__PURE__ */ jsx64("div", { className: "flex flex-col p-1 justify-center gap-1", children: ["AM", "PM"].map((p) => /* @__PURE__ */ jsx64(
|
|
8047
8449
|
Button,
|
|
8048
8450
|
{
|
|
8049
8451
|
variant: "ghost",
|
|
@@ -8067,9 +8469,9 @@ function TimeInput({
|
|
|
8067
8469
|
// src/components/ui/toggle.tsx
|
|
8068
8470
|
import "react";
|
|
8069
8471
|
import * as TogglePrimitive from "@radix-ui/react-toggle";
|
|
8070
|
-
import { cva as
|
|
8071
|
-
import { jsx as
|
|
8072
|
-
var toggleVariants =
|
|
8472
|
+
import { cva as cva16 } from "class-variance-authority";
|
|
8473
|
+
import { jsx as jsx65 } from "react/jsx-runtime";
|
|
8474
|
+
var toggleVariants = cva16(
|
|
8073
8475
|
"cursor-pointer inline-flex items-center justify-center gap-2 rounded-md text-sm font-medium hover:bg-muted hover:text-muted-foreground disabled:pointer-events-none disabled:opacity-50 data-[state=on]:bg-accent data-[state=on]:text-accent-foreground [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4 [&_svg]:shrink-0 focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] outline-none transition-[color,box-shadow] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive whitespace-nowrap",
|
|
8074
8476
|
{
|
|
8075
8477
|
variants: {
|
|
@@ -8095,7 +8497,7 @@ function Toggle({
|
|
|
8095
8497
|
size,
|
|
8096
8498
|
...props
|
|
8097
8499
|
}) {
|
|
8098
|
-
return /* @__PURE__ */
|
|
8500
|
+
return /* @__PURE__ */ jsx65(
|
|
8099
8501
|
TogglePrimitive.Root,
|
|
8100
8502
|
{
|
|
8101
8503
|
"data-slot": "toggle",
|
|
@@ -8106,11 +8508,11 @@ function Toggle({
|
|
|
8106
8508
|
}
|
|
8107
8509
|
|
|
8108
8510
|
// src/components/ui/toggle-group.tsx
|
|
8109
|
-
import * as
|
|
8511
|
+
import * as React63 from "react";
|
|
8110
8512
|
import * as ToggleGroupPrimitive from "@radix-ui/react-toggle-group";
|
|
8111
8513
|
import "class-variance-authority";
|
|
8112
|
-
import { jsx as
|
|
8113
|
-
var ToggleGroupContext =
|
|
8514
|
+
import { jsx as jsx66 } from "react/jsx-runtime";
|
|
8515
|
+
var ToggleGroupContext = React63.createContext({
|
|
8114
8516
|
size: "default",
|
|
8115
8517
|
variant: "default"
|
|
8116
8518
|
});
|
|
@@ -8121,7 +8523,7 @@ function ToggleGroup({
|
|
|
8121
8523
|
children,
|
|
8122
8524
|
...props
|
|
8123
8525
|
}) {
|
|
8124
|
-
return /* @__PURE__ */
|
|
8526
|
+
return /* @__PURE__ */ jsx66(
|
|
8125
8527
|
ToggleGroupPrimitive.Root,
|
|
8126
8528
|
{
|
|
8127
8529
|
"data-slot": "toggle-group",
|
|
@@ -8132,7 +8534,7 @@ function ToggleGroup({
|
|
|
8132
8534
|
className
|
|
8133
8535
|
),
|
|
8134
8536
|
...props,
|
|
8135
|
-
children: /* @__PURE__ */
|
|
8537
|
+
children: /* @__PURE__ */ jsx66(ToggleGroupContext.Provider, { value: { variant, size }, children })
|
|
8136
8538
|
}
|
|
8137
8539
|
);
|
|
8138
8540
|
}
|
|
@@ -8143,8 +8545,8 @@ function ToggleGroupItem({
|
|
|
8143
8545
|
size,
|
|
8144
8546
|
...props
|
|
8145
8547
|
}) {
|
|
8146
|
-
const context =
|
|
8147
|
-
return /* @__PURE__ */
|
|
8548
|
+
const context = React63.useContext(ToggleGroupContext);
|
|
8549
|
+
return /* @__PURE__ */ jsx66(
|
|
8148
8550
|
ToggleGroupPrimitive.Item,
|
|
8149
8551
|
{
|
|
8150
8552
|
"data-slot": "toggle-group-item",
|
|
@@ -8164,288 +8566,6 @@ function ToggleGroupItem({
|
|
|
8164
8566
|
);
|
|
8165
8567
|
}
|
|
8166
8568
|
|
|
8167
|
-
// src/components/ui/typography.tsx
|
|
8168
|
-
import { Slot as Slot7 } from "@radix-ui/react-slot";
|
|
8169
|
-
import { cva as cva16 } from "class-variance-authority";
|
|
8170
|
-
import "react";
|
|
8171
|
-
import { jsx as jsx65 } from "react/jsx-runtime";
|
|
8172
|
-
var displayTextVariants = cva16(
|
|
8173
|
-
"tracking-normal font-normal font-serif italic text-vibrant-text-display",
|
|
8174
|
-
{
|
|
8175
|
-
variants: {
|
|
8176
|
-
size: {
|
|
8177
|
-
lg: "text-4xl md:text-[3.25rem] leading-[44px] md:leading-[64px]",
|
|
8178
|
-
md: "text-[1.75rem] md:text-4xl leading-[36px] md:leading-[44px]",
|
|
8179
|
-
sm: "text-lg md:text-xl leading-[26px] md:leading-[28px]"
|
|
8180
|
-
}
|
|
8181
|
-
},
|
|
8182
|
-
defaultVariants: {
|
|
8183
|
-
size: "md"
|
|
8184
|
-
}
|
|
8185
|
-
}
|
|
8186
|
-
);
|
|
8187
|
-
function DisplayHeading({
|
|
8188
|
-
className,
|
|
8189
|
-
size,
|
|
8190
|
-
asChild = false,
|
|
8191
|
-
...props
|
|
8192
|
-
}) {
|
|
8193
|
-
const Comp = asChild ? Slot7 : "h1";
|
|
8194
|
-
return /* @__PURE__ */ jsx65(
|
|
8195
|
-
Comp,
|
|
8196
|
-
{
|
|
8197
|
-
"data-slot": "h1",
|
|
8198
|
-
className: cn(displayTextVariants({ size, className })),
|
|
8199
|
-
...props
|
|
8200
|
-
}
|
|
8201
|
-
);
|
|
8202
|
-
}
|
|
8203
|
-
var bodyTextVariants = cva16("font-sans text-vibrant-text-body", {
|
|
8204
|
-
variants: {
|
|
8205
|
-
size: {
|
|
8206
|
-
lg: "text-lg md:text-xl leading-[26px] md:leading-[28px]",
|
|
8207
|
-
md: "text-base leading-[24px]",
|
|
8208
|
-
sm: "text-sm leading-[20px]",
|
|
8209
|
-
xs: "text-xs leading-[16px]"
|
|
8210
|
-
}
|
|
8211
|
-
},
|
|
8212
|
-
defaultVariants: {
|
|
8213
|
-
size: "md"
|
|
8214
|
-
}
|
|
8215
|
-
});
|
|
8216
|
-
function Body({
|
|
8217
|
-
className,
|
|
8218
|
-
size,
|
|
8219
|
-
asChild = false,
|
|
8220
|
-
...props
|
|
8221
|
-
}) {
|
|
8222
|
-
const Comp = asChild ? Slot7 : "p";
|
|
8223
|
-
return /* @__PURE__ */ jsx65(
|
|
8224
|
-
Comp,
|
|
8225
|
-
{
|
|
8226
|
-
"data-slot": "p",
|
|
8227
|
-
className: cn(bodyTextVariants({ size, className })),
|
|
8228
|
-
...props
|
|
8229
|
-
}
|
|
8230
|
-
);
|
|
8231
|
-
}
|
|
8232
|
-
function HeadingXL({
|
|
8233
|
-
className,
|
|
8234
|
-
asChild = false,
|
|
8235
|
-
...props
|
|
8236
|
-
}) {
|
|
8237
|
-
const Comp = asChild ? Slot7 : "h1";
|
|
8238
|
-
return /* @__PURE__ */ jsx65(
|
|
8239
|
-
Comp,
|
|
8240
|
-
{
|
|
8241
|
-
"data-slot": "h1",
|
|
8242
|
-
className: cn(
|
|
8243
|
-
"text-2xl md:text-[2rem] leading-[32px] md:leading-[40px] font-semibold font-sans text-vibrant-text-heading",
|
|
8244
|
-
className
|
|
8245
|
-
),
|
|
8246
|
-
...props
|
|
8247
|
-
}
|
|
8248
|
-
);
|
|
8249
|
-
}
|
|
8250
|
-
function HeadingL({
|
|
8251
|
-
className,
|
|
8252
|
-
asChild = false,
|
|
8253
|
-
...props
|
|
8254
|
-
}) {
|
|
8255
|
-
const Comp = asChild ? Slot7 : "h2";
|
|
8256
|
-
return /* @__PURE__ */ jsx65(
|
|
8257
|
-
Comp,
|
|
8258
|
-
{
|
|
8259
|
-
"data-slot": "h2",
|
|
8260
|
-
className: cn(
|
|
8261
|
-
"text-[1.25rem] md:text-[1.5rem] leading-[28px] md:leading-[32px] font-semibold font-sans text-vibrant-text-heading",
|
|
8262
|
-
className
|
|
8263
|
-
),
|
|
8264
|
-
...props
|
|
8265
|
-
}
|
|
8266
|
-
);
|
|
8267
|
-
}
|
|
8268
|
-
function HeadingM({
|
|
8269
|
-
className,
|
|
8270
|
-
asChild = false,
|
|
8271
|
-
...props
|
|
8272
|
-
}) {
|
|
8273
|
-
const Comp = asChild ? Slot7 : "h3";
|
|
8274
|
-
return /* @__PURE__ */ jsx65(
|
|
8275
|
-
Comp,
|
|
8276
|
-
{
|
|
8277
|
-
"data-slot": "h3",
|
|
8278
|
-
className: cn(
|
|
8279
|
-
"text-[1.125rem] md:text-xl leading-[26px] md:leading-[28px] font-semibold font-sans text-vibrant-text-heading",
|
|
8280
|
-
className
|
|
8281
|
-
),
|
|
8282
|
-
...props
|
|
8283
|
-
}
|
|
8284
|
-
);
|
|
8285
|
-
}
|
|
8286
|
-
function HeadingS({
|
|
8287
|
-
className,
|
|
8288
|
-
asChild = false,
|
|
8289
|
-
...props
|
|
8290
|
-
}) {
|
|
8291
|
-
const Comp = asChild ? Slot7 : "h4";
|
|
8292
|
-
return /* @__PURE__ */ jsx65(
|
|
8293
|
-
Comp,
|
|
8294
|
-
{
|
|
8295
|
-
"data-slot": "h4",
|
|
8296
|
-
className: cn(
|
|
8297
|
-
"text-base leading-[24px] font-semibold font-sans text-vibrant-text-heading",
|
|
8298
|
-
className
|
|
8299
|
-
),
|
|
8300
|
-
...props
|
|
8301
|
-
}
|
|
8302
|
-
);
|
|
8303
|
-
}
|
|
8304
|
-
function HeadingXS({
|
|
8305
|
-
className,
|
|
8306
|
-
asChild = false,
|
|
8307
|
-
...props
|
|
8308
|
-
}) {
|
|
8309
|
-
const Comp = asChild ? Slot7 : "h5";
|
|
8310
|
-
return /* @__PURE__ */ jsx65(
|
|
8311
|
-
Comp,
|
|
8312
|
-
{
|
|
8313
|
-
"data-slot": "h5",
|
|
8314
|
-
className: cn(
|
|
8315
|
-
"text-sm leading-[20px] font-semibold font-sans text-vibrant-text-heading",
|
|
8316
|
-
className
|
|
8317
|
-
),
|
|
8318
|
-
...props
|
|
8319
|
-
}
|
|
8320
|
-
);
|
|
8321
|
-
}
|
|
8322
|
-
function HeadingXXS({
|
|
8323
|
-
className,
|
|
8324
|
-
asChild = false,
|
|
8325
|
-
...props
|
|
8326
|
-
}) {
|
|
8327
|
-
const Comp = asChild ? Slot7 : "h6";
|
|
8328
|
-
return /* @__PURE__ */ jsx65(
|
|
8329
|
-
Comp,
|
|
8330
|
-
{
|
|
8331
|
-
"data-slot": "h6",
|
|
8332
|
-
className: cn(
|
|
8333
|
-
"text-xs leading-[16px] font-medium font-sans text-vibrant-text-heading",
|
|
8334
|
-
className
|
|
8335
|
-
),
|
|
8336
|
-
...props
|
|
8337
|
-
}
|
|
8338
|
-
);
|
|
8339
|
-
}
|
|
8340
|
-
function HeadingXLMedium({
|
|
8341
|
-
className,
|
|
8342
|
-
asChild = false,
|
|
8343
|
-
...props
|
|
8344
|
-
}) {
|
|
8345
|
-
const Comp = asChild ? Slot7 : "h1";
|
|
8346
|
-
return /* @__PURE__ */ jsx65(
|
|
8347
|
-
Comp,
|
|
8348
|
-
{
|
|
8349
|
-
"data-slot": "h1",
|
|
8350
|
-
className: cn(
|
|
8351
|
-
"text-2xl md:text-[2rem] leading-[32px] md:leading-[40px] font-medium font-sans text-vibrant-text-heading",
|
|
8352
|
-
className
|
|
8353
|
-
),
|
|
8354
|
-
...props
|
|
8355
|
-
}
|
|
8356
|
-
);
|
|
8357
|
-
}
|
|
8358
|
-
function HeadingLMedium({
|
|
8359
|
-
className,
|
|
8360
|
-
asChild = false,
|
|
8361
|
-
...props
|
|
8362
|
-
}) {
|
|
8363
|
-
const Comp = asChild ? Slot7 : "h2";
|
|
8364
|
-
return /* @__PURE__ */ jsx65(
|
|
8365
|
-
Comp,
|
|
8366
|
-
{
|
|
8367
|
-
"data-slot": "h2",
|
|
8368
|
-
className: cn(
|
|
8369
|
-
"text-[1.25rem] md:text-[1.5rem] leading-[28px] md:leading-[32px] font-medium font-sans text-vibrant-text-heading",
|
|
8370
|
-
className
|
|
8371
|
-
),
|
|
8372
|
-
...props
|
|
8373
|
-
}
|
|
8374
|
-
);
|
|
8375
|
-
}
|
|
8376
|
-
function HeadingMMedium({
|
|
8377
|
-
className,
|
|
8378
|
-
asChild = false,
|
|
8379
|
-
...props
|
|
8380
|
-
}) {
|
|
8381
|
-
const Comp = asChild ? Slot7 : "h3";
|
|
8382
|
-
return /* @__PURE__ */ jsx65(
|
|
8383
|
-
Comp,
|
|
8384
|
-
{
|
|
8385
|
-
"data-slot": "h3",
|
|
8386
|
-
className: cn(
|
|
8387
|
-
"text-[1.125rem] md:text-xl leading-[26px] md:leading-[28px] font-medium font-sans text-vibrant-text-heading",
|
|
8388
|
-
className
|
|
8389
|
-
),
|
|
8390
|
-
...props
|
|
8391
|
-
}
|
|
8392
|
-
);
|
|
8393
|
-
}
|
|
8394
|
-
function HeadingSMedium({
|
|
8395
|
-
className,
|
|
8396
|
-
asChild = false,
|
|
8397
|
-
...props
|
|
8398
|
-
}) {
|
|
8399
|
-
const Comp = asChild ? Slot7 : "h4";
|
|
8400
|
-
return /* @__PURE__ */ jsx65(
|
|
8401
|
-
Comp,
|
|
8402
|
-
{
|
|
8403
|
-
"data-slot": "h4",
|
|
8404
|
-
className: cn(
|
|
8405
|
-
"text-base leading-[24px] font-medium font-sans text-vibrant-text-heading",
|
|
8406
|
-
className
|
|
8407
|
-
),
|
|
8408
|
-
...props
|
|
8409
|
-
}
|
|
8410
|
-
);
|
|
8411
|
-
}
|
|
8412
|
-
function HeadingXSMedium({
|
|
8413
|
-
className,
|
|
8414
|
-
asChild = false,
|
|
8415
|
-
...props
|
|
8416
|
-
}) {
|
|
8417
|
-
const Comp = asChild ? Slot7 : "h5";
|
|
8418
|
-
return /* @__PURE__ */ jsx65(
|
|
8419
|
-
Comp,
|
|
8420
|
-
{
|
|
8421
|
-
"data-slot": "h5",
|
|
8422
|
-
className: cn(
|
|
8423
|
-
"text-sm leading-[20px] font-medium font-sans text-vibrant-text-heading",
|
|
8424
|
-
className
|
|
8425
|
-
),
|
|
8426
|
-
...props
|
|
8427
|
-
}
|
|
8428
|
-
);
|
|
8429
|
-
}
|
|
8430
|
-
function HeadingXXSMedium({
|
|
8431
|
-
className,
|
|
8432
|
-
asChild = false,
|
|
8433
|
-
...props
|
|
8434
|
-
}) {
|
|
8435
|
-
const Comp = asChild ? Slot7 : "h6";
|
|
8436
|
-
return /* @__PURE__ */ jsx65(
|
|
8437
|
-
Comp,
|
|
8438
|
-
{
|
|
8439
|
-
"data-slot": "h6",
|
|
8440
|
-
className: cn(
|
|
8441
|
-
"text-xs leading-[16px] font-medium font-sans text-vibrant-text-heading",
|
|
8442
|
-
className
|
|
8443
|
-
),
|
|
8444
|
-
...props
|
|
8445
|
-
}
|
|
8446
|
-
);
|
|
8447
|
-
}
|
|
8448
|
-
|
|
8449
8569
|
// src/hooks/use-theme.ts
|
|
8450
8570
|
import { useTheme as useTheme3 } from "next-themes";
|
|
8451
8571
|
export {
|
|
@@ -8580,6 +8700,7 @@ export {
|
|
|
8580
8700
|
DropdownSelectLabel,
|
|
8581
8701
|
DropdownSelectOption,
|
|
8582
8702
|
DropdownSelectTrigger,
|
|
8703
|
+
FaqAccordion,
|
|
8583
8704
|
Form,
|
|
8584
8705
|
FormControl,
|
|
8585
8706
|
FormDescription,
|