@2urgseui/core 0.1.5 → 0.1.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +387 -319
- package/dist/index.d.cts +5 -1
- package/dist/index.d.ts +5 -1
- package/dist/index.js +380 -312
- package/dist/styles.css +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -2160,7 +2160,7 @@ var FileDropzone = React20.forwardRef(
|
|
|
2160
2160
|
FileDropzone.displayName = "FileDropzone";
|
|
2161
2161
|
|
|
2162
2162
|
// source/components/primitive/FormField/form-field.tsx
|
|
2163
|
-
var
|
|
2163
|
+
var React32 = __toESM(require("react"), 1);
|
|
2164
2164
|
var import_react_hook_form = require("react-hook-form");
|
|
2165
2165
|
|
|
2166
2166
|
// source/components/primitive/InputOtp/input-otp.tsx
|
|
@@ -2274,10 +2274,119 @@ var Input = React22.forwardRef(
|
|
|
2274
2274
|
Input.displayName = "Input";
|
|
2275
2275
|
|
|
2276
2276
|
// source/components/primitive/Label/label.tsx
|
|
2277
|
-
var
|
|
2277
|
+
var React25 = __toESM(require("react"), 1);
|
|
2278
2278
|
var LabelPrimitive = __toESM(require("@radix-ui/react-label"), 1);
|
|
2279
2279
|
var import_class_variance_authority8 = require("class-variance-authority");
|
|
2280
|
+
var import_lucide_react8 = require("lucide-react");
|
|
2281
|
+
|
|
2282
|
+
// source/components/primitive/RichHtml/rich-html.tsx
|
|
2283
|
+
var React23 = __toESM(require("react"), 1);
|
|
2284
|
+
var import_dompurify = __toESM(require("dompurify"), 1);
|
|
2280
2285
|
var import_jsx_runtime25 = require("react/jsx-runtime");
|
|
2286
|
+
var defaultSanitizeConfig = {
|
|
2287
|
+
USE_PROFILES: { html: true }
|
|
2288
|
+
};
|
|
2289
|
+
var richHtmlChrome = cn(
|
|
2290
|
+
"max-w-none text-base leading-relaxed text-foreground",
|
|
2291
|
+
// Block flow
|
|
2292
|
+
"[&_p]:mb-3 [&_p:last-child]:mb-0 [&_blockquote]:my-4 [&_blockquote]:border-l-2 [&_blockquote]:border-muted [&_blockquote]:pl-4 [&_blockquote]:italic",
|
|
2293
|
+
// Lists
|
|
2294
|
+
"[&_ul]:my-3 [&_ul]:list-disc [&_ul]:pl-6 [&_ol]:my-3 [&_ol]:list-decimal [&_ol]:pl-6 [&_li]:my-1 [&_li]:pl-1",
|
|
2295
|
+
// Headings (common for TipTap / CMS output)
|
|
2296
|
+
"[&_h1]:mb-3 [&_h1]:mt-8 [&_h1]:text-3xl [&_h1]:font-semibold [&_h1]:first:mt-0",
|
|
2297
|
+
"[&_h2]:mb-2 [&_h2]:mt-6 [&_h2]:text-2xl [&_h2]:font-semibold [&_h2]:first:mt-0",
|
|
2298
|
+
"[&_h3]:mb-2 [&_h3]:mt-5 [&_h3]:text-xl [&_h3]:font-semibold [&_h3]:first:mt-0",
|
|
2299
|
+
"[&_h4]:mb-2 [&_h4]:mt-4 [&_h4]:text-lg [&_h4]:font-semibold [&_h4]:first:mt-0",
|
|
2300
|
+
// Links & media
|
|
2301
|
+
"[&_a]:text-primary [&_a]:underline [&_a]:underline-offset-2 [&_a]:outline-none [&_a]:focus-visible:ring-2 [&_a]:focus-visible:ring-ring [&_a]:focus-visible:ring-offset-2",
|
|
2302
|
+
"[&_img]:my-4 [&_img]:max-h-[min(480px,70vh)] [&_img]:max-w-full [&_img]:rounded-md [&_img]:object-contain",
|
|
2303
|
+
"[&_hr]:my-6 [&_hr]:border-border",
|
|
2304
|
+
// Code
|
|
2305
|
+
"[&_code]:rounded [&_code]:bg-muted [&_code]:px-1 [&_code]:py-0.5 [&_code]:text-[0.9em]",
|
|
2306
|
+
"[&_pre]:my-4 [&_pre]:overflow-x-auto [&_pre]:rounded-md [&_pre]:bg-muted [&_pre]:p-3 [&_pre]:font-mono [&_pre]:text-sm"
|
|
2307
|
+
);
|
|
2308
|
+
var RichHtml = React23.forwardRef(
|
|
2309
|
+
({
|
|
2310
|
+
html,
|
|
2311
|
+
sanitize = true,
|
|
2312
|
+
sanitizeConfig,
|
|
2313
|
+
className,
|
|
2314
|
+
suppressHydrationWarning,
|
|
2315
|
+
...props
|
|
2316
|
+
}, ref) => {
|
|
2317
|
+
const markup = React23.useMemo(() => {
|
|
2318
|
+
if (html === void 0 || html === null || html === "") {
|
|
2319
|
+
return "";
|
|
2320
|
+
}
|
|
2321
|
+
if (!sanitize) {
|
|
2322
|
+
return html;
|
|
2323
|
+
}
|
|
2324
|
+
if (typeof window === "undefined") {
|
|
2325
|
+
return "";
|
|
2326
|
+
}
|
|
2327
|
+
const config = {
|
|
2328
|
+
...defaultSanitizeConfig,
|
|
2329
|
+
...sanitizeConfig
|
|
2330
|
+
};
|
|
2331
|
+
return import_dompurify.default.sanitize(html, config);
|
|
2332
|
+
}, [html, sanitize, sanitizeConfig]);
|
|
2333
|
+
const resolvedSuppressHydration = suppressHydrationWarning ?? sanitize;
|
|
2334
|
+
if (html === void 0 || html === null || html === "") {
|
|
2335
|
+
return null;
|
|
2336
|
+
}
|
|
2337
|
+
return /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
|
|
2338
|
+
"div",
|
|
2339
|
+
{
|
|
2340
|
+
ref,
|
|
2341
|
+
suppressHydrationWarning: resolvedSuppressHydration,
|
|
2342
|
+
className: cn(richHtmlChrome, className),
|
|
2343
|
+
...props,
|
|
2344
|
+
dangerouslySetInnerHTML: { __html: markup }
|
|
2345
|
+
}
|
|
2346
|
+
);
|
|
2347
|
+
}
|
|
2348
|
+
);
|
|
2349
|
+
RichHtml.displayName = "RichHtml";
|
|
2350
|
+
|
|
2351
|
+
// source/components/primitive/ToolTip/tooltip.tsx
|
|
2352
|
+
var React24 = __toESM(require("react"), 1);
|
|
2353
|
+
var TooltipPrimitive = __toESM(require("@radix-ui/react-tooltip"), 1);
|
|
2354
|
+
var import_jsx_runtime26 = require("react/jsx-runtime");
|
|
2355
|
+
var TooltipProvider = TooltipPrimitive.Provider;
|
|
2356
|
+
var Tooltip = ({ ...props }) => {
|
|
2357
|
+
return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(TooltipPrimitive.Root, { ...props });
|
|
2358
|
+
};
|
|
2359
|
+
Tooltip.displayName = "Tooltip";
|
|
2360
|
+
var TooltipTrigger = TooltipPrimitive.Trigger;
|
|
2361
|
+
TooltipTrigger.displayName = "TooltipTrigger";
|
|
2362
|
+
var TooltipContent = React24.forwardRef(({ className, sideOffset = 4, arrow = false, children, ...props }, ref) => {
|
|
2363
|
+
return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(TooltipPrimitive.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(
|
|
2364
|
+
TooltipPrimitive.Content,
|
|
2365
|
+
{
|
|
2366
|
+
ref,
|
|
2367
|
+
sideOffset,
|
|
2368
|
+
className: cn(
|
|
2369
|
+
"z-50 overflow-hidden rounded-md border bg-popover px-3 py-1.5 text-sm text-popover-foreground shadow-md",
|
|
2370
|
+
"animate-in fade-in-0 zoom-in-95",
|
|
2371
|
+
"data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95",
|
|
2372
|
+
"data-[side=bottom]:slide-in-from-top-2",
|
|
2373
|
+
"data-[side=left]:slide-in-from-right-2",
|
|
2374
|
+
"data-[side=right]:slide-in-from-left-2",
|
|
2375
|
+
"data-[side=top]:slide-in-from-bottom-2",
|
|
2376
|
+
className
|
|
2377
|
+
),
|
|
2378
|
+
...props,
|
|
2379
|
+
children: [
|
|
2380
|
+
children,
|
|
2381
|
+
arrow && /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(TooltipPrimitive.Arrow, { className: "fill-popover" })
|
|
2382
|
+
]
|
|
2383
|
+
}
|
|
2384
|
+
) });
|
|
2385
|
+
});
|
|
2386
|
+
TooltipContent.displayName = "TooltipContent";
|
|
2387
|
+
|
|
2388
|
+
// source/components/primitive/Label/label.tsx
|
|
2389
|
+
var import_jsx_runtime27 = require("react/jsx-runtime");
|
|
2281
2390
|
var labelVariants = (0, import_class_variance_authority8.cva)(
|
|
2282
2391
|
"font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70",
|
|
2283
2392
|
{
|
|
@@ -2298,27 +2407,80 @@ var labelVariants = (0, import_class_variance_authority8.cva)(
|
|
|
2298
2407
|
}
|
|
2299
2408
|
}
|
|
2300
2409
|
);
|
|
2301
|
-
var
|
|
2302
|
-
|
|
2303
|
-
|
|
2304
|
-
|
|
2305
|
-
|
|
2306
|
-
|
|
2307
|
-
|
|
2308
|
-
|
|
2309
|
-
|
|
2310
|
-
|
|
2410
|
+
var labelTooltipHtmlClassName = cn(
|
|
2411
|
+
"max-w-xs text-sm leading-snug",
|
|
2412
|
+
"[&_p]:mb-1 [&_p:last-child]:mb-0",
|
|
2413
|
+
"[&_a]:text-inherit [&_a]:underline [&_a]:underline-offset-2"
|
|
2414
|
+
);
|
|
2415
|
+
function looksLikeHtml(value) {
|
|
2416
|
+
return /<[a-z][\s\S]*>/i.test(value);
|
|
2417
|
+
}
|
|
2418
|
+
function LabelTooltipContent({ content }) {
|
|
2419
|
+
if (typeof content === "string") {
|
|
2420
|
+
if (looksLikeHtml(content)) {
|
|
2421
|
+
return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
|
|
2422
|
+
RichHtml,
|
|
2423
|
+
{
|
|
2424
|
+
html: content,
|
|
2425
|
+
className: labelTooltipHtmlClassName
|
|
2426
|
+
}
|
|
2427
|
+
);
|
|
2428
|
+
}
|
|
2429
|
+
return content;
|
|
2311
2430
|
}
|
|
2312
|
-
|
|
2431
|
+
return content;
|
|
2432
|
+
}
|
|
2433
|
+
function LabelTooltip({ content }) {
|
|
2434
|
+
return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(TooltipProvider, { delayDuration: 200, children: /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)(Tooltip, { children: [
|
|
2435
|
+
/* @__PURE__ */ (0, import_jsx_runtime27.jsx)(TooltipTrigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
|
|
2436
|
+
"button",
|
|
2437
|
+
{
|
|
2438
|
+
type: "button",
|
|
2439
|
+
className: "inline-flex shrink-0 rounded-sm text-muted-foreground hover:text-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
|
|
2440
|
+
"aria-label": "More information",
|
|
2441
|
+
onClick: (e) => e.preventDefault(),
|
|
2442
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(import_lucide_react8.CircleHelp, { className: "h-3.5 w-3.5", "aria-hidden": true })
|
|
2443
|
+
}
|
|
2444
|
+
) }),
|
|
2445
|
+
/* @__PURE__ */ (0, import_jsx_runtime27.jsx)(TooltipContent, { side: "top", children: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(LabelTooltipContent, { content }) })
|
|
2446
|
+
] }) });
|
|
2447
|
+
}
|
|
2448
|
+
function hasLabelTooltip(tooltip) {
|
|
2449
|
+
if (tooltip == null) return false;
|
|
2450
|
+
if (typeof tooltip === "string" && tooltip.trim() === "") return false;
|
|
2451
|
+
return true;
|
|
2452
|
+
}
|
|
2453
|
+
var Label2 = React25.forwardRef(({ className, tone, size, required, tooltip, children, ...props }, ref) => {
|
|
2454
|
+
const hasTooltip = hasLabelTooltip(tooltip);
|
|
2455
|
+
return /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)(
|
|
2456
|
+
LabelPrimitive.Root,
|
|
2457
|
+
{
|
|
2458
|
+
ref,
|
|
2459
|
+
className: cn(
|
|
2460
|
+
labelVariants({ tone, size }),
|
|
2461
|
+
hasTooltip ? "flex w-full min-w-0 items-center justify-between gap-2" : "inline-flex items-center gap-1",
|
|
2462
|
+
className
|
|
2463
|
+
),
|
|
2464
|
+
...props,
|
|
2465
|
+
children: [
|
|
2466
|
+
/* @__PURE__ */ (0, import_jsx_runtime27.jsxs)("span", { className: "inline-flex min-w-0 items-center gap-1", children: [
|
|
2467
|
+
children,
|
|
2468
|
+
required && /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("span", { className: "text-destructive", children: "*" })
|
|
2469
|
+
] }),
|
|
2470
|
+
hasTooltip && /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(LabelTooltip, { content: tooltip })
|
|
2471
|
+
]
|
|
2472
|
+
}
|
|
2473
|
+
);
|
|
2474
|
+
});
|
|
2313
2475
|
Label2.displayName = LabelPrimitive.Root.displayName;
|
|
2314
2476
|
|
|
2315
2477
|
// source/components/primitive/RadioGroup/radiogroup.tsx
|
|
2316
|
-
var
|
|
2478
|
+
var React26 = __toESM(require("react"), 1);
|
|
2317
2479
|
var RadioGroupPrimitive = __toESM(require("@radix-ui/react-radio-group"), 1);
|
|
2318
|
-
var
|
|
2319
|
-
var
|
|
2320
|
-
var RadioGroup2 =
|
|
2321
|
-
return /* @__PURE__ */ (0,
|
|
2480
|
+
var import_lucide_react9 = require("lucide-react");
|
|
2481
|
+
var import_jsx_runtime28 = require("react/jsx-runtime");
|
|
2482
|
+
var RadioGroup2 = React26.forwardRef(({ className, ...props }, ref) => {
|
|
2483
|
+
return /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
|
|
2322
2484
|
RadioGroupPrimitive.Root,
|
|
2323
2485
|
{
|
|
2324
2486
|
ref,
|
|
@@ -2328,8 +2490,8 @@ var RadioGroup2 = React24.forwardRef(({ className, ...props }, ref) => {
|
|
|
2328
2490
|
);
|
|
2329
2491
|
});
|
|
2330
2492
|
RadioGroup2.displayName = "RadioGroup";
|
|
2331
|
-
var RadioGroupItem =
|
|
2332
|
-
return /* @__PURE__ */ (0,
|
|
2493
|
+
var RadioGroupItem = React26.forwardRef(({ className, ...props }, ref) => {
|
|
2494
|
+
return /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
|
|
2333
2495
|
RadioGroupPrimitive.Item,
|
|
2334
2496
|
{
|
|
2335
2497
|
ref,
|
|
@@ -2341,7 +2503,7 @@ var RadioGroupItem = React24.forwardRef(({ className, ...props }, ref) => {
|
|
|
2341
2503
|
className
|
|
2342
2504
|
),
|
|
2343
2505
|
...props,
|
|
2344
|
-
children: /* @__PURE__ */ (0,
|
|
2506
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(RadioGroupPrimitive.Indicator, { className: "flex items-center justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(import_lucide_react9.Circle, { className: "h-2.5 w-2.5 shrink-0 fill-current text-current" }) })
|
|
2345
2507
|
}
|
|
2346
2508
|
);
|
|
2347
2509
|
});
|
|
@@ -2355,20 +2517,20 @@ var import_extension_image = __toESM(require("@tiptap/extension-image"), 1);
|
|
|
2355
2517
|
var import_extension_link = __toESM(require("@tiptap/extension-link"), 1);
|
|
2356
2518
|
|
|
2357
2519
|
// source/components/primitive/RichTextArea/richtext-toolbar.tsx
|
|
2358
|
-
var
|
|
2520
|
+
var import_jsx_runtime29 = require("react/jsx-runtime");
|
|
2359
2521
|
function RichTextToolbar({ editor }) {
|
|
2360
2522
|
if (!editor) return null;
|
|
2361
|
-
return /* @__PURE__ */ (0,
|
|
2362
|
-
/* @__PURE__ */ (0,
|
|
2363
|
-
/* @__PURE__ */ (0,
|
|
2364
|
-
/* @__PURE__ */ (0,
|
|
2365
|
-
/* @__PURE__ */ (0,
|
|
2366
|
-
/* @__PURE__ */ (0,
|
|
2523
|
+
return /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)("div", { className: "flex flex-wrap gap-2 border-b p-2", children: [
|
|
2524
|
+
/* @__PURE__ */ (0, import_jsx_runtime29.jsx)("button", { onClick: () => editor.chain().focus().toggleBold().run(), children: "Bold" }),
|
|
2525
|
+
/* @__PURE__ */ (0, import_jsx_runtime29.jsx)("button", { onClick: () => editor.chain().focus().toggleItalic().run(), children: "Italic" }),
|
|
2526
|
+
/* @__PURE__ */ (0, import_jsx_runtime29.jsx)("button", { onClick: () => editor.chain().focus().toggleHeading({ level: 2 }).run(), children: "H2" }),
|
|
2527
|
+
/* @__PURE__ */ (0, import_jsx_runtime29.jsx)("button", { onClick: () => editor.chain().focus().toggleBulletList().run(), children: "List" }),
|
|
2528
|
+
/* @__PURE__ */ (0, import_jsx_runtime29.jsx)("button", { onClick: () => editor.chain().focus().toggleCodeBlock().run(), children: "Code" })
|
|
2367
2529
|
] });
|
|
2368
2530
|
}
|
|
2369
2531
|
|
|
2370
2532
|
// source/components/primitive/RichTextArea/richtext-editor.tsx
|
|
2371
|
-
var
|
|
2533
|
+
var import_jsx_runtime30 = require("react/jsx-runtime");
|
|
2372
2534
|
var RichTextEditor = ({
|
|
2373
2535
|
value,
|
|
2374
2536
|
onChange,
|
|
@@ -2392,7 +2554,7 @@ var RichTextEditor = ({
|
|
|
2392
2554
|
}
|
|
2393
2555
|
});
|
|
2394
2556
|
if (!editor) return null;
|
|
2395
|
-
return /* @__PURE__ */ (0,
|
|
2557
|
+
return /* @__PURE__ */ (0, import_jsx_runtime30.jsxs)(
|
|
2396
2558
|
"div",
|
|
2397
2559
|
{
|
|
2398
2560
|
className: cn(
|
|
@@ -2402,8 +2564,8 @@ var RichTextEditor = ({
|
|
|
2402
2564
|
className
|
|
2403
2565
|
),
|
|
2404
2566
|
children: [
|
|
2405
|
-
/* @__PURE__ */ (0,
|
|
2406
|
-
/* @__PURE__ */ (0,
|
|
2567
|
+
/* @__PURE__ */ (0, import_jsx_runtime30.jsx)(RichTextToolbar, { editor }),
|
|
2568
|
+
/* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
|
|
2407
2569
|
import_react.EditorContent,
|
|
2408
2570
|
{
|
|
2409
2571
|
editor,
|
|
@@ -2416,9 +2578,9 @@ var RichTextEditor = ({
|
|
|
2416
2578
|
};
|
|
2417
2579
|
|
|
2418
2580
|
// source/components/primitive/SearchableSelect/searchable-select.tsx
|
|
2419
|
-
var
|
|
2420
|
-
var
|
|
2421
|
-
var
|
|
2581
|
+
var React27 = __toESM(require("react"), 1);
|
|
2582
|
+
var import_lucide_react10 = require("lucide-react");
|
|
2583
|
+
var import_jsx_runtime31 = require("react/jsx-runtime");
|
|
2422
2584
|
function reactNodeToLabelString2(node) {
|
|
2423
2585
|
if (node == null || typeof node === "boolean") return "";
|
|
2424
2586
|
if (typeof node === "string" || typeof node === "number") return String(node);
|
|
@@ -2448,12 +2610,12 @@ function SearchableSelectInner({
|
|
|
2448
2610
|
"aria-invalid": ariaInvalid,
|
|
2449
2611
|
innerRef
|
|
2450
2612
|
}) {
|
|
2451
|
-
const [open, setOpen] =
|
|
2452
|
-
const [search, setSearch] =
|
|
2453
|
-
const searchInputRef =
|
|
2613
|
+
const [open, setOpen] = React27.useState(false);
|
|
2614
|
+
const [search, setSearch] = React27.useState("");
|
|
2615
|
+
const searchInputRef = React27.useRef(null);
|
|
2454
2616
|
const filteredItems = items.filter((item) => filterItem(item, search));
|
|
2455
2617
|
const selectedItem = items.find((item) => item.value === value);
|
|
2456
|
-
|
|
2618
|
+
React27.useEffect(() => {
|
|
2457
2619
|
if (open) {
|
|
2458
2620
|
setTimeout(() => searchInputRef.current?.focus(), 0);
|
|
2459
2621
|
} else {
|
|
@@ -2473,9 +2635,9 @@ function SearchableSelectInner({
|
|
|
2473
2635
|
e.stopPropagation();
|
|
2474
2636
|
onValueChange?.("");
|
|
2475
2637
|
};
|
|
2476
|
-
return /* @__PURE__ */ (0,
|
|
2477
|
-
name && /* @__PURE__ */ (0,
|
|
2478
|
-
/* @__PURE__ */ (0,
|
|
2638
|
+
return /* @__PURE__ */ (0, import_jsx_runtime31.jsx)("div", { className: "w-full min-w-0", children: /* @__PURE__ */ (0, import_jsx_runtime31.jsxs)(Popover, { open, onOpenChange: setOpen, children: [
|
|
2639
|
+
name && /* @__PURE__ */ (0, import_jsx_runtime31.jsx)("input", { type: "hidden", name, value: value ?? "" }),
|
|
2640
|
+
/* @__PURE__ */ (0, import_jsx_runtime31.jsx)(PopoverTrigger, { asChild: true, className: "w-full", children: /* @__PURE__ */ (0, import_jsx_runtime31.jsxs)(
|
|
2479
2641
|
"button",
|
|
2480
2642
|
{
|
|
2481
2643
|
ref: innerRef,
|
|
@@ -2495,7 +2657,7 @@ function SearchableSelectInner({
|
|
|
2495
2657
|
className
|
|
2496
2658
|
),
|
|
2497
2659
|
children: [
|
|
2498
|
-
/* @__PURE__ */ (0,
|
|
2660
|
+
/* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
|
|
2499
2661
|
"span",
|
|
2500
2662
|
{
|
|
2501
2663
|
className: cn(
|
|
@@ -2505,8 +2667,8 @@ function SearchableSelectInner({
|
|
|
2505
2667
|
children: selectedItem?.label ?? placeholder
|
|
2506
2668
|
}
|
|
2507
2669
|
),
|
|
2508
|
-
/* @__PURE__ */ (0,
|
|
2509
|
-
clearable && value && !disabled && /* @__PURE__ */ (0,
|
|
2670
|
+
/* @__PURE__ */ (0, import_jsx_runtime31.jsxs)("span", { className: "ml-auto flex shrink-0 items-center gap-1", children: [
|
|
2671
|
+
clearable && value && !disabled && /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
|
|
2510
2672
|
"span",
|
|
2511
2673
|
{
|
|
2512
2674
|
role: "button",
|
|
@@ -2522,21 +2684,21 @@ function SearchableSelectInner({
|
|
|
2522
2684
|
children: "\xD7"
|
|
2523
2685
|
}
|
|
2524
2686
|
),
|
|
2525
|
-
/* @__PURE__ */ (0,
|
|
2687
|
+
/* @__PURE__ */ (0, import_jsx_runtime31.jsx)(import_lucide_react10.ChevronDown, { "aria-hidden": true, className: "h-4 w-4 shrink-0 text-slate-500 dark:text-slate-400" })
|
|
2526
2688
|
] })
|
|
2527
2689
|
]
|
|
2528
2690
|
}
|
|
2529
2691
|
) }),
|
|
2530
|
-
/* @__PURE__ */ (0,
|
|
2692
|
+
/* @__PURE__ */ (0, import_jsx_runtime31.jsxs)(
|
|
2531
2693
|
PopoverContent,
|
|
2532
2694
|
{
|
|
2533
2695
|
align: "start",
|
|
2534
2696
|
className: "w-[--radix-popover-trigger-width] min-w-[var(--radix-popover-trigger-width)] max-w-[var(--radix-popover-content-available-width)] p-0",
|
|
2535
2697
|
onOpenAutoFocus: (e) => e.preventDefault(),
|
|
2536
2698
|
children: [
|
|
2537
|
-
/* @__PURE__ */ (0,
|
|
2538
|
-
/* @__PURE__ */ (0,
|
|
2539
|
-
/* @__PURE__ */ (0,
|
|
2699
|
+
/* @__PURE__ */ (0, import_jsx_runtime31.jsxs)("div", { className: "flex items-center gap-2 border-b px-3 py-2", children: [
|
|
2700
|
+
/* @__PURE__ */ (0, import_jsx_runtime31.jsx)(import_lucide_react10.Search, { className: "h-4 w-4 shrink-0 text-muted-foreground" }),
|
|
2701
|
+
/* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
|
|
2540
2702
|
"input",
|
|
2541
2703
|
{
|
|
2542
2704
|
ref: searchInputRef,
|
|
@@ -2547,9 +2709,9 @@ function SearchableSelectInner({
|
|
|
2547
2709
|
}
|
|
2548
2710
|
)
|
|
2549
2711
|
] }),
|
|
2550
|
-
/* @__PURE__ */ (0,
|
|
2712
|
+
/* @__PURE__ */ (0, import_jsx_runtime31.jsx)("div", { className: "max-h-60 overflow-y-auto p-1", children: filteredItems.length === 0 ? /* @__PURE__ */ (0, import_jsx_runtime31.jsx)("div", { className: "px-3 py-6 text-center text-sm text-muted-foreground", children: "No results found." }) : filteredItems.map((item) => {
|
|
2551
2713
|
const isSelected = item.value === value;
|
|
2552
|
-
return /* @__PURE__ */ (0,
|
|
2714
|
+
return /* @__PURE__ */ (0, import_jsx_runtime31.jsxs)(
|
|
2553
2715
|
"button",
|
|
2554
2716
|
{
|
|
2555
2717
|
type: "button",
|
|
@@ -2565,8 +2727,8 @@ function SearchableSelectInner({
|
|
|
2565
2727
|
isSelected && "bg-accent/50"
|
|
2566
2728
|
),
|
|
2567
2729
|
children: [
|
|
2568
|
-
/* @__PURE__ */ (0,
|
|
2569
|
-
/* @__PURE__ */ (0,
|
|
2730
|
+
/* @__PURE__ */ (0, import_jsx_runtime31.jsx)("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center", children: isSelected && /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(import_lucide_react10.Check, { className: "h-4 w-4" }) }),
|
|
2731
|
+
/* @__PURE__ */ (0, import_jsx_runtime31.jsx)("span", { className: "min-w-0 flex-1 whitespace-normal break-words", children: item.label })
|
|
2570
2732
|
]
|
|
2571
2733
|
},
|
|
2572
2734
|
item.value
|
|
@@ -2577,18 +2739,18 @@ function SearchableSelectInner({
|
|
|
2577
2739
|
)
|
|
2578
2740
|
] }) });
|
|
2579
2741
|
}
|
|
2580
|
-
var SearchableSelect =
|
|
2742
|
+
var SearchableSelect = React27.forwardRef((props, ref) => /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(SearchableSelectInner, { ...props, innerRef: ref }));
|
|
2581
2743
|
SearchableSelect.displayName = "SearchableSelect";
|
|
2582
2744
|
|
|
2583
2745
|
// source/components/primitive/Select/select.tsx
|
|
2584
|
-
var
|
|
2746
|
+
var React28 = __toESM(require("react"), 1);
|
|
2585
2747
|
var SelectPrimitive = __toESM(require("@radix-ui/react-select"), 1);
|
|
2586
|
-
var
|
|
2587
|
-
var
|
|
2748
|
+
var import_lucide_react11 = require("lucide-react");
|
|
2749
|
+
var import_jsx_runtime32 = require("react/jsx-runtime");
|
|
2588
2750
|
var Select = SelectPrimitive.Root;
|
|
2589
2751
|
var SelectGroup = SelectPrimitive.Group;
|
|
2590
2752
|
var SelectValue = SelectPrimitive.Value;
|
|
2591
|
-
var SelectTrigger =
|
|
2753
|
+
var SelectTrigger = React28.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)(
|
|
2592
2754
|
SelectPrimitive.Trigger,
|
|
2593
2755
|
{
|
|
2594
2756
|
ref,
|
|
@@ -2602,8 +2764,8 @@ var SelectTrigger = React26.forwardRef(({ className, children, ...props }, ref)
|
|
|
2602
2764
|
...props,
|
|
2603
2765
|
children: [
|
|
2604
2766
|
children,
|
|
2605
|
-
/* @__PURE__ */ (0,
|
|
2606
|
-
|
|
2767
|
+
/* @__PURE__ */ (0, import_jsx_runtime32.jsx)(SelectPrimitive.Icon, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
|
|
2768
|
+
import_lucide_react11.ChevronDown,
|
|
2607
2769
|
{
|
|
2608
2770
|
"aria-hidden": "true",
|
|
2609
2771
|
className: "h-4 w-4 shrink-0"
|
|
@@ -2613,7 +2775,7 @@ var SelectTrigger = React26.forwardRef(({ className, children, ...props }, ref)
|
|
|
2613
2775
|
}
|
|
2614
2776
|
));
|
|
2615
2777
|
SelectTrigger.displayName = SelectPrimitive.Trigger.displayName;
|
|
2616
|
-
var SelectScrollUpButton =
|
|
2778
|
+
var SelectScrollUpButton = React28.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
|
|
2617
2779
|
SelectPrimitive.ScrollUpButton,
|
|
2618
2780
|
{
|
|
2619
2781
|
ref,
|
|
@@ -2622,11 +2784,11 @@ var SelectScrollUpButton = React26.forwardRef(({ className, ...props }, ref) =>
|
|
|
2622
2784
|
className
|
|
2623
2785
|
),
|
|
2624
2786
|
...props,
|
|
2625
|
-
children: /* @__PURE__ */ (0,
|
|
2787
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(import_lucide_react11.ChevronUp, { className: "h-4 w-4" })
|
|
2626
2788
|
}
|
|
2627
2789
|
));
|
|
2628
2790
|
SelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;
|
|
2629
|
-
var SelectScrollDownButton =
|
|
2791
|
+
var SelectScrollDownButton = React28.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
|
|
2630
2792
|
SelectPrimitive.ScrollDownButton,
|
|
2631
2793
|
{
|
|
2632
2794
|
ref,
|
|
@@ -2635,11 +2797,11 @@ var SelectScrollDownButton = React26.forwardRef(({ className, ...props }, ref) =
|
|
|
2635
2797
|
className
|
|
2636
2798
|
),
|
|
2637
2799
|
...props,
|
|
2638
|
-
children: /* @__PURE__ */ (0,
|
|
2800
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(import_lucide_react11.ChevronDown, { className: "h-4 w-4" })
|
|
2639
2801
|
}
|
|
2640
2802
|
));
|
|
2641
2803
|
SelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;
|
|
2642
|
-
var SelectContent =
|
|
2804
|
+
var SelectContent = React28.forwardRef(({ className, children, position = "popper", ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(SelectPrimitive.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)(
|
|
2643
2805
|
SelectPrimitive.Content,
|
|
2644
2806
|
{
|
|
2645
2807
|
ref,
|
|
@@ -2651,8 +2813,8 @@ var SelectContent = React26.forwardRef(({ className, children, position = "poppe
|
|
|
2651
2813
|
position,
|
|
2652
2814
|
...props,
|
|
2653
2815
|
children: [
|
|
2654
|
-
/* @__PURE__ */ (0,
|
|
2655
|
-
/* @__PURE__ */ (0,
|
|
2816
|
+
/* @__PURE__ */ (0, import_jsx_runtime32.jsx)(SelectScrollUpButton, {}),
|
|
2817
|
+
/* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
|
|
2656
2818
|
SelectPrimitive.Viewport,
|
|
2657
2819
|
{
|
|
2658
2820
|
className: cn(
|
|
@@ -2662,12 +2824,12 @@ var SelectContent = React26.forwardRef(({ className, children, position = "poppe
|
|
|
2662
2824
|
children
|
|
2663
2825
|
}
|
|
2664
2826
|
),
|
|
2665
|
-
/* @__PURE__ */ (0,
|
|
2827
|
+
/* @__PURE__ */ (0, import_jsx_runtime32.jsx)(SelectScrollDownButton, {})
|
|
2666
2828
|
]
|
|
2667
2829
|
}
|
|
2668
2830
|
) }));
|
|
2669
2831
|
SelectContent.displayName = SelectPrimitive.Content.displayName;
|
|
2670
|
-
var SelectLabel =
|
|
2832
|
+
var SelectLabel = React28.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
|
|
2671
2833
|
SelectPrimitive.Label,
|
|
2672
2834
|
{
|
|
2673
2835
|
ref,
|
|
@@ -2676,13 +2838,13 @@ var SelectLabel = React26.forwardRef(({ className, ...props }, ref) => /* @__PUR
|
|
|
2676
2838
|
}
|
|
2677
2839
|
));
|
|
2678
2840
|
SelectLabel.displayName = SelectPrimitive.Label.displayName;
|
|
2679
|
-
var SelectItem =
|
|
2841
|
+
var SelectItem = React28.forwardRef(({ value, className, children, ...props }, ref) => {
|
|
2680
2842
|
if (value === "") {
|
|
2681
2843
|
throw new Error(
|
|
2682
2844
|
'SelectItem: `value` must not be an empty string \u2014 Radix uses "" to reset the Select and show the placeholder. Omit that option and use `<SelectValue placeholder="\u2026">`, or assign a sentinel value such as `"none"`.'
|
|
2683
2845
|
);
|
|
2684
2846
|
}
|
|
2685
|
-
return /* @__PURE__ */ (0,
|
|
2847
|
+
return /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)(
|
|
2686
2848
|
SelectPrimitive.Item,
|
|
2687
2849
|
{
|
|
2688
2850
|
ref,
|
|
@@ -2693,14 +2855,14 @@ var SelectItem = React26.forwardRef(({ value, className, children, ...props }, r
|
|
|
2693
2855
|
),
|
|
2694
2856
|
...props,
|
|
2695
2857
|
children: [
|
|
2696
|
-
/* @__PURE__ */ (0,
|
|
2697
|
-
/* @__PURE__ */ (0,
|
|
2858
|
+
/* @__PURE__ */ (0, import_jsx_runtime32.jsx)("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(SelectPrimitive.ItemIndicator, { children: /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(import_lucide_react11.Check, { className: "h-4 w-4" }) }) }),
|
|
2859
|
+
/* @__PURE__ */ (0, import_jsx_runtime32.jsx)(SelectPrimitive.ItemText, { className: "whitespace-normal break-words", children })
|
|
2698
2860
|
]
|
|
2699
2861
|
}
|
|
2700
2862
|
);
|
|
2701
2863
|
});
|
|
2702
2864
|
SelectItem.displayName = SelectPrimitive.Item.displayName;
|
|
2703
|
-
var SelectSeparator =
|
|
2865
|
+
var SelectSeparator = React28.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
|
|
2704
2866
|
SelectPrimitive.Separator,
|
|
2705
2867
|
{
|
|
2706
2868
|
ref,
|
|
@@ -2711,10 +2873,10 @@ var SelectSeparator = React26.forwardRef(({ className, ...props }, ref) => /* @_
|
|
|
2711
2873
|
SelectSeparator.displayName = SelectPrimitive.Separator.displayName;
|
|
2712
2874
|
|
|
2713
2875
|
// source/components/primitive/Switch/switch.tsx
|
|
2714
|
-
var
|
|
2876
|
+
var React29 = __toESM(require("react"), 1);
|
|
2715
2877
|
var SwitchPrimitives = __toESM(require("@radix-ui/react-switch"), 1);
|
|
2716
2878
|
var import_class_variance_authority9 = require("class-variance-authority");
|
|
2717
|
-
var
|
|
2879
|
+
var import_jsx_runtime33 = require("react/jsx-runtime");
|
|
2718
2880
|
var switchRootVariants = (0, import_class_variance_authority9.cva)(
|
|
2719
2881
|
[
|
|
2720
2882
|
"peer inline-flex shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent transition-colors",
|
|
@@ -2748,14 +2910,14 @@ var switchThumbVariants = (0, import_class_variance_authority9.cva)(
|
|
|
2748
2910
|
}
|
|
2749
2911
|
}
|
|
2750
2912
|
);
|
|
2751
|
-
var Switch =
|
|
2913
|
+
var Switch = React29.forwardRef(
|
|
2752
2914
|
({ className, label, description, error: error2, size, id: idProp, ...props }, ref) => {
|
|
2753
|
-
const generatedId =
|
|
2915
|
+
const generatedId = React29.useId();
|
|
2754
2916
|
const id = idProp ?? generatedId;
|
|
2755
2917
|
const descriptionId = description ? `${id}-description` : void 0;
|
|
2756
2918
|
const errorId = error2 ? `${id}-error` : void 0;
|
|
2757
|
-
return /* @__PURE__ */ (0,
|
|
2758
|
-
/* @__PURE__ */ (0,
|
|
2919
|
+
return /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)("div", { className: "flex items-start gap-3", children: [
|
|
2920
|
+
/* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
|
|
2759
2921
|
SwitchPrimitives.Root,
|
|
2760
2922
|
{
|
|
2761
2923
|
ref,
|
|
@@ -2768,7 +2930,7 @@ var Switch = React27.forwardRef(
|
|
|
2768
2930
|
className
|
|
2769
2931
|
),
|
|
2770
2932
|
...props,
|
|
2771
|
-
children: /* @__PURE__ */ (0,
|
|
2933
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
|
|
2772
2934
|
SwitchPrimitives.Thumb,
|
|
2773
2935
|
{
|
|
2774
2936
|
className: cn(switchThumbVariants({ size }))
|
|
@@ -2776,8 +2938,8 @@ var Switch = React27.forwardRef(
|
|
|
2776
2938
|
)
|
|
2777
2939
|
}
|
|
2778
2940
|
),
|
|
2779
|
-
(label || description || error2) && /* @__PURE__ */ (0,
|
|
2780
|
-
label && /* @__PURE__ */ (0,
|
|
2941
|
+
(label || description || error2) && /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)("div", { className: "flex flex-col leading-tight", children: [
|
|
2942
|
+
label && /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
|
|
2781
2943
|
"label",
|
|
2782
2944
|
{
|
|
2783
2945
|
htmlFor: id,
|
|
@@ -2785,7 +2947,7 @@ var Switch = React27.forwardRef(
|
|
|
2785
2947
|
children: label
|
|
2786
2948
|
}
|
|
2787
2949
|
),
|
|
2788
|
-
description && /* @__PURE__ */ (0,
|
|
2950
|
+
description && /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
|
|
2789
2951
|
"p",
|
|
2790
2952
|
{
|
|
2791
2953
|
id: descriptionId,
|
|
@@ -2793,7 +2955,7 @@ var Switch = React27.forwardRef(
|
|
|
2793
2955
|
children: description
|
|
2794
2956
|
}
|
|
2795
2957
|
),
|
|
2796
|
-
error2 && /* @__PURE__ */ (0,
|
|
2958
|
+
error2 && /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
|
|
2797
2959
|
"p",
|
|
2798
2960
|
{
|
|
2799
2961
|
id: errorId,
|
|
@@ -2808,9 +2970,9 @@ var Switch = React27.forwardRef(
|
|
|
2808
2970
|
Switch.displayName = "Switch";
|
|
2809
2971
|
|
|
2810
2972
|
// source/components/primitive/Text/text.tsx
|
|
2811
|
-
var
|
|
2973
|
+
var React30 = __toESM(require("react"), 1);
|
|
2812
2974
|
var import_class_variance_authority10 = require("class-variance-authority");
|
|
2813
|
-
var
|
|
2975
|
+
var import_jsx_runtime34 = require("react/jsx-runtime");
|
|
2814
2976
|
var textVariants = (0, import_class_variance_authority10.cva)("text-foreground", {
|
|
2815
2977
|
variants: {
|
|
2816
2978
|
element: {
|
|
@@ -2859,7 +3021,7 @@ var textVariants = (0, import_class_variance_authority10.cva)("text-foreground",
|
|
|
2859
3021
|
tone: "default"
|
|
2860
3022
|
}
|
|
2861
3023
|
});
|
|
2862
|
-
var Text =
|
|
3024
|
+
var Text = React30.forwardRef(
|
|
2863
3025
|
({
|
|
2864
3026
|
element = "p",
|
|
2865
3027
|
size,
|
|
@@ -2872,7 +3034,7 @@ var Text = React28.forwardRef(
|
|
|
2872
3034
|
}, ref) => {
|
|
2873
3035
|
const Comp = element;
|
|
2874
3036
|
const variantElement = element === "div" ? "p" : element;
|
|
2875
|
-
return /* @__PURE__ */ (0,
|
|
3037
|
+
return /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(
|
|
2876
3038
|
Comp,
|
|
2877
3039
|
{
|
|
2878
3040
|
ref,
|
|
@@ -2895,8 +3057,8 @@ var Text = React28.forwardRef(
|
|
|
2895
3057
|
Text.displayName = "Text";
|
|
2896
3058
|
|
|
2897
3059
|
// source/components/primitive/TextArea/textarea.tsx
|
|
2898
|
-
var
|
|
2899
|
-
var
|
|
3060
|
+
var React31 = __toESM(require("react"), 1);
|
|
3061
|
+
var import_jsx_runtime35 = require("react/jsx-runtime");
|
|
2900
3062
|
var resizeClasses = {
|
|
2901
3063
|
none: "resize-none",
|
|
2902
3064
|
vertical: "resize-y",
|
|
@@ -2904,9 +3066,9 @@ var resizeClasses = {
|
|
|
2904
3066
|
both: "resize"
|
|
2905
3067
|
};
|
|
2906
3068
|
var layout = "block min-h-[120px] w-full min-w-0 px-4 py-2 text-sm md:text-base";
|
|
2907
|
-
var Textarea =
|
|
3069
|
+
var Textarea = React31.forwardRef(
|
|
2908
3070
|
({ className, error: error2, resize = "vertical", ...props }, ref) => {
|
|
2909
|
-
return /* @__PURE__ */ (0,
|
|
3071
|
+
return /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(
|
|
2910
3072
|
"textarea",
|
|
2911
3073
|
{
|
|
2912
3074
|
ref,
|
|
@@ -2928,7 +3090,7 @@ var Textarea = React29.forwardRef(
|
|
|
2928
3090
|
Textarea.displayName = "Textarea";
|
|
2929
3091
|
|
|
2930
3092
|
// source/components/primitive/FormField/form-field.tsx
|
|
2931
|
-
var
|
|
3093
|
+
var import_jsx_runtime36 = require("react/jsx-runtime");
|
|
2932
3094
|
function stripThousands(s) {
|
|
2933
3095
|
return s.replace(/,/g, "");
|
|
2934
3096
|
}
|
|
@@ -3050,6 +3212,7 @@ function formFieldHasLabel(label) {
|
|
|
3050
3212
|
function FormField({
|
|
3051
3213
|
name,
|
|
3052
3214
|
label,
|
|
3215
|
+
labelTooltip,
|
|
3053
3216
|
register,
|
|
3054
3217
|
control,
|
|
3055
3218
|
rules,
|
|
@@ -3072,7 +3235,7 @@ function FormField({
|
|
|
3072
3235
|
className,
|
|
3073
3236
|
renderInput
|
|
3074
3237
|
}) {
|
|
3075
|
-
const generatedId =
|
|
3238
|
+
const generatedId = React32.useId();
|
|
3076
3239
|
const inputId = `field-${generatedId}`;
|
|
3077
3240
|
const descriptionId = description ? `${inputId}-description` : void 0;
|
|
3078
3241
|
const externalError = error2 ? String(error2) : void 0;
|
|
@@ -3115,7 +3278,7 @@ function FormField({
|
|
|
3115
3278
|
);
|
|
3116
3279
|
}
|
|
3117
3280
|
if (control) {
|
|
3118
|
-
return /* @__PURE__ */ (0,
|
|
3281
|
+
return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
3119
3282
|
import_react_hook_form.Controller,
|
|
3120
3283
|
{
|
|
3121
3284
|
name,
|
|
@@ -3142,7 +3305,7 @@ function FormField({
|
|
|
3142
3305
|
onChange: field.onChange,
|
|
3143
3306
|
onBlur: field.onBlur,
|
|
3144
3307
|
ref: field.ref
|
|
3145
|
-
}) : /* @__PURE__ */ (0,
|
|
3308
|
+
}) : /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
3146
3309
|
FormFieldVariantControl,
|
|
3147
3310
|
{
|
|
3148
3311
|
variant,
|
|
@@ -3167,18 +3330,19 @@ function FormField({
|
|
|
3167
3330
|
maskInput: renderInput ? void 0 : maskInput
|
|
3168
3331
|
}
|
|
3169
3332
|
);
|
|
3170
|
-
const labelBlock = isCheckboxInline || !hasFieldLabel2 ? null : /* @__PURE__ */ (0,
|
|
3333
|
+
const labelBlock = isCheckboxInline || !hasFieldLabel2 ? null : /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
3171
3334
|
Label2,
|
|
3172
3335
|
{
|
|
3173
3336
|
id: variant === "radio" || variant === "richtext" ? legendId : void 0,
|
|
3174
3337
|
htmlFor: variant === "radio" || variant === "richtext" ? void 0 : inputId,
|
|
3175
3338
|
size: "sm",
|
|
3176
3339
|
required,
|
|
3340
|
+
tooltip: labelTooltip,
|
|
3177
3341
|
children: label
|
|
3178
3342
|
}
|
|
3179
3343
|
);
|
|
3180
|
-
const checkboxInline = isCheckboxInline ? hasFieldLabel2 ? /* @__PURE__ */ (0,
|
|
3181
|
-
/* @__PURE__ */ (0,
|
|
3344
|
+
const checkboxInline = isCheckboxInline ? hasFieldLabel2 ? /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)("div", { className: "flex w-full min-w-0 items-start gap-2", children: [
|
|
3345
|
+
/* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
3182
3346
|
Checkbox,
|
|
3183
3347
|
{
|
|
3184
3348
|
...checkboxProps,
|
|
@@ -3193,17 +3357,18 @@ function FormField({
|
|
|
3193
3357
|
"aria-invalid": hasError || void 0
|
|
3194
3358
|
}
|
|
3195
3359
|
),
|
|
3196
|
-
/* @__PURE__ */ (0,
|
|
3360
|
+
/* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
3197
3361
|
Label2,
|
|
3198
3362
|
{
|
|
3199
3363
|
htmlFor: inputId,
|
|
3200
3364
|
required,
|
|
3201
3365
|
size: "sm",
|
|
3202
|
-
|
|
3366
|
+
tooltip: labelTooltip,
|
|
3367
|
+
className: "min-w-0 flex-1 font-normal leading-snug",
|
|
3203
3368
|
children: label
|
|
3204
3369
|
}
|
|
3205
3370
|
)
|
|
3206
|
-
] }) : /* @__PURE__ */ (0,
|
|
3371
|
+
] }) : /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
3207
3372
|
Checkbox,
|
|
3208
3373
|
{
|
|
3209
3374
|
...checkboxProps,
|
|
@@ -3218,7 +3383,7 @@ function FormField({
|
|
|
3218
3383
|
"aria-invalid": hasError || void 0
|
|
3219
3384
|
}
|
|
3220
3385
|
) : null;
|
|
3221
|
-
return /* @__PURE__ */ (0,
|
|
3386
|
+
return /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)(
|
|
3222
3387
|
"div",
|
|
3223
3388
|
{
|
|
3224
3389
|
className: cn(
|
|
@@ -3226,12 +3391,12 @@ function FormField({
|
|
|
3226
3391
|
className
|
|
3227
3392
|
),
|
|
3228
3393
|
children: [
|
|
3229
|
-
isCheckboxInline ? checkboxInline : /* @__PURE__ */ (0,
|
|
3394
|
+
isCheckboxInline ? checkboxInline : /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)("div", { className: "flex w-full min-w-0 flex-col gap-1.5", children: [
|
|
3230
3395
|
labelBlock,
|
|
3231
3396
|
controlNode
|
|
3232
3397
|
] }),
|
|
3233
|
-
description && /* @__PURE__ */ (0,
|
|
3234
|
-
message && /* @__PURE__ */ (0,
|
|
3398
|
+
description && /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(Text, { id: descriptionId, size: "sm", tone: "muted", children: description }),
|
|
3399
|
+
message && /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(Text, { id: errorId, size: "sm", tone: "destructive", children: message })
|
|
3235
3400
|
]
|
|
3236
3401
|
}
|
|
3237
3402
|
);
|
|
@@ -3256,7 +3421,7 @@ function FormField({
|
|
|
3256
3421
|
"aria-describedby": describedBy,
|
|
3257
3422
|
error: Boolean(externalError),
|
|
3258
3423
|
...registered
|
|
3259
|
-
}) : variant === "textarea" ? /* @__PURE__ */ (0,
|
|
3424
|
+
}) : variant === "textarea" ? /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
3260
3425
|
Textarea,
|
|
3261
3426
|
{
|
|
3262
3427
|
id: inputId,
|
|
@@ -3265,7 +3430,7 @@ function FormField({
|
|
|
3265
3430
|
...textareaProps,
|
|
3266
3431
|
...registered
|
|
3267
3432
|
}
|
|
3268
|
-
) : /* @__PURE__ */ (0,
|
|
3433
|
+
) : /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
3269
3434
|
Input,
|
|
3270
3435
|
{
|
|
3271
3436
|
id: inputId,
|
|
@@ -3275,13 +3440,22 @@ function FormField({
|
|
|
3275
3440
|
...registered
|
|
3276
3441
|
}
|
|
3277
3442
|
);
|
|
3278
|
-
return /* @__PURE__ */ (0,
|
|
3279
|
-
hasFieldLabel ? /* @__PURE__ */ (0,
|
|
3280
|
-
/* @__PURE__ */ (0,
|
|
3443
|
+
return /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)("div", { className: cn("mt-4 flex w-full min-w-0 flex-col gap-2", className), children: [
|
|
3444
|
+
hasFieldLabel ? /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)("div", { className: "flex w-full min-w-0 flex-col gap-1.5", children: [
|
|
3445
|
+
/* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
3446
|
+
Label2,
|
|
3447
|
+
{
|
|
3448
|
+
htmlFor: inputId,
|
|
3449
|
+
required,
|
|
3450
|
+
size: "sm",
|
|
3451
|
+
tooltip: labelTooltip,
|
|
3452
|
+
children: label
|
|
3453
|
+
}
|
|
3454
|
+
),
|
|
3281
3455
|
registeredControl
|
|
3282
|
-
] }) : /* @__PURE__ */ (0,
|
|
3283
|
-
description && /* @__PURE__ */ (0,
|
|
3284
|
-
externalError && /* @__PURE__ */ (0,
|
|
3456
|
+
] }) : /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("div", { className: "w-full min-w-0", children: registeredControl }),
|
|
3457
|
+
description && /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(Text, { id: descriptionId, size: "sm", tone: "muted", children: description }),
|
|
3458
|
+
externalError && /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(Text, { id: `${inputId}-error`, size: "sm", tone: "destructive", children: externalError })
|
|
3285
3459
|
] });
|
|
3286
3460
|
}
|
|
3287
3461
|
function formValueToAsyncSelectOption(v) {
|
|
@@ -3319,7 +3493,7 @@ function FormFieldVariantControl({
|
|
|
3319
3493
|
}) {
|
|
3320
3494
|
switch (variant) {
|
|
3321
3495
|
case "textarea":
|
|
3322
|
-
return /* @__PURE__ */ (0,
|
|
3496
|
+
return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("div", { className: "w-full min-w-0", children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
3323
3497
|
Textarea,
|
|
3324
3498
|
{
|
|
3325
3499
|
...textareaProps,
|
|
@@ -3337,7 +3511,7 @@ function FormFieldVariantControl({
|
|
|
3337
3511
|
case "checkbox":
|
|
3338
3512
|
return null;
|
|
3339
3513
|
case "switch":
|
|
3340
|
-
return /* @__PURE__ */ (0,
|
|
3514
|
+
return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("div", { className: "w-full min-w-0", children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
3341
3515
|
Switch,
|
|
3342
3516
|
{
|
|
3343
3517
|
...switchProps,
|
|
@@ -3375,7 +3549,7 @@ function FormFieldVariantControl({
|
|
|
3375
3549
|
}
|
|
3376
3550
|
const value = field.value == null || field.value === "" ? void 0 : String(field.value);
|
|
3377
3551
|
if (searchable) {
|
|
3378
|
-
return /* @__PURE__ */ (0,
|
|
3552
|
+
return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("div", { className: "w-full min-w-0", children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
3379
3553
|
SearchableSelect,
|
|
3380
3554
|
{
|
|
3381
3555
|
items,
|
|
@@ -3400,7 +3574,7 @@ function FormFieldVariantControl({
|
|
|
3400
3574
|
}
|
|
3401
3575
|
) });
|
|
3402
3576
|
}
|
|
3403
|
-
return /* @__PURE__ */ (0,
|
|
3577
|
+
return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("div", { className: "w-full min-w-0", children: /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)(
|
|
3404
3578
|
Select,
|
|
3405
3579
|
{
|
|
3406
3580
|
...selectRootRest,
|
|
@@ -3409,7 +3583,7 @@ function FormFieldVariantControl({
|
|
|
3409
3583
|
disabled: field.disabled,
|
|
3410
3584
|
name: field.name,
|
|
3411
3585
|
children: [
|
|
3412
|
-
/* @__PURE__ */ (0,
|
|
3586
|
+
/* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
3413
3587
|
SelectTrigger,
|
|
3414
3588
|
{
|
|
3415
3589
|
id: inputId,
|
|
@@ -3421,10 +3595,10 @@ function FormFieldVariantControl({
|
|
|
3421
3595
|
triggerClassName
|
|
3422
3596
|
),
|
|
3423
3597
|
onBlur: field.onBlur,
|
|
3424
|
-
children: /* @__PURE__ */ (0,
|
|
3598
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(SelectValue, { placeholder })
|
|
3425
3599
|
}
|
|
3426
3600
|
),
|
|
3427
|
-
/* @__PURE__ */ (0,
|
|
3601
|
+
/* @__PURE__ */ (0, import_jsx_runtime36.jsx)(SelectContent, { className: contentClassName, children: items.map((item) => /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
3428
3602
|
SelectItem,
|
|
3429
3603
|
{
|
|
3430
3604
|
value: item.value,
|
|
@@ -3447,7 +3621,7 @@ function FormFieldVariantControl({
|
|
|
3447
3621
|
if (!asyncSelectProps?.labelKey) {
|
|
3448
3622
|
throw new Error('FormField variant "async-select" requires asyncSelectProps.labelKey.');
|
|
3449
3623
|
}
|
|
3450
|
-
return /* @__PURE__ */ (0,
|
|
3624
|
+
return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("div", { className: "w-full min-w-0", children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
3451
3625
|
AsyncSelect,
|
|
3452
3626
|
{
|
|
3453
3627
|
...asyncSelectProps,
|
|
@@ -3471,7 +3645,7 @@ function FormFieldVariantControl({
|
|
|
3471
3645
|
className: radioClassName,
|
|
3472
3646
|
...radioGroupRest
|
|
3473
3647
|
} = radioProps;
|
|
3474
|
-
return /* @__PURE__ */ (0,
|
|
3648
|
+
return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
3475
3649
|
RadioGroup2,
|
|
3476
3650
|
{
|
|
3477
3651
|
...radioGroupRest,
|
|
@@ -3486,8 +3660,8 @@ function FormFieldVariantControl({
|
|
|
3486
3660
|
"aria-describedby": describedBy,
|
|
3487
3661
|
"aria-invalid": hasError || void 0,
|
|
3488
3662
|
ref: field.ref,
|
|
3489
|
-
children: options.map((opt) => /* @__PURE__ */ (0,
|
|
3490
|
-
/* @__PURE__ */ (0,
|
|
3663
|
+
children: options.map((opt) => /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)("div", { className: "flex items-center gap-2", children: [
|
|
3664
|
+
/* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
3491
3665
|
RadioGroupItem,
|
|
3492
3666
|
{
|
|
3493
3667
|
value: opt.value,
|
|
@@ -3495,7 +3669,7 @@ function FormFieldVariantControl({
|
|
|
3495
3669
|
disabled: opt.disabled
|
|
3496
3670
|
}
|
|
3497
3671
|
),
|
|
3498
|
-
/* @__PURE__ */ (0,
|
|
3672
|
+
/* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
3499
3673
|
Label2,
|
|
3500
3674
|
{
|
|
3501
3675
|
htmlFor: opt.id ?? `${inputId}-${opt.value}`,
|
|
@@ -3514,7 +3688,7 @@ function FormFieldVariantControl({
|
|
|
3514
3688
|
}
|
|
3515
3689
|
const { maxLength, groups, containerClassName, ...otpRest } = otpProps;
|
|
3516
3690
|
const slotGroups = groups?.length ? groups : defaultOtpGroups(maxLength);
|
|
3517
|
-
return /* @__PURE__ */ (0,
|
|
3691
|
+
return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("div", { className: "w-full min-w-0", children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
3518
3692
|
InputOTP,
|
|
3519
3693
|
{
|
|
3520
3694
|
...otpRest,
|
|
@@ -3533,15 +3707,15 @@ function FormFieldVariantControl({
|
|
|
3533
3707
|
hasError && inputOtpContainerInvalid,
|
|
3534
3708
|
containerClassName
|
|
3535
3709
|
),
|
|
3536
|
-
children: slotGroups.map((indices, gi) => /* @__PURE__ */ (0,
|
|
3537
|
-
gi > 0 ? /* @__PURE__ */ (0,
|
|
3538
|
-
/* @__PURE__ */ (0,
|
|
3710
|
+
children: slotGroups.map((indices, gi) => /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)(React32.Fragment, { children: [
|
|
3711
|
+
gi > 0 ? /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(InputOTPSeparator, {}) : null,
|
|
3712
|
+
/* @__PURE__ */ (0, import_jsx_runtime36.jsx)(InputOTPGroup, { children: indices.map((index) => /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(InputOTPSlot, { index }, index)) })
|
|
3539
3713
|
] }, gi))
|
|
3540
3714
|
}
|
|
3541
3715
|
) });
|
|
3542
3716
|
}
|
|
3543
3717
|
case "richtext":
|
|
3544
|
-
return /* @__PURE__ */ (0,
|
|
3718
|
+
return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
3545
3719
|
"div",
|
|
3546
3720
|
{
|
|
3547
3721
|
className: "w-full min-w-0",
|
|
@@ -3551,7 +3725,7 @@ function FormFieldVariantControl({
|
|
|
3551
3725
|
"aria-describedby": describedBy,
|
|
3552
3726
|
"aria-invalid": hasError || void 0,
|
|
3553
3727
|
onBlur: field.onBlur,
|
|
3554
|
-
children: /* @__PURE__ */ (0,
|
|
3728
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
3555
3729
|
RichTextEditor,
|
|
3556
3730
|
{
|
|
3557
3731
|
value: field.value ?? "",
|
|
@@ -3563,7 +3737,7 @@ function FormFieldVariantControl({
|
|
|
3563
3737
|
}
|
|
3564
3738
|
);
|
|
3565
3739
|
case "dropzone":
|
|
3566
|
-
return /* @__PURE__ */ (0,
|
|
3740
|
+
return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("div", { className: "w-full min-w-0", children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
3567
3741
|
FileDropzone,
|
|
3568
3742
|
{
|
|
3569
3743
|
...dropzoneProps,
|
|
@@ -3597,7 +3771,7 @@ function FormFieldVariantControl({
|
|
|
3597
3771
|
const pattern = maskInput.pattern;
|
|
3598
3772
|
const rawStored = field.value == null || field.value === "" ? "" : String(field.value);
|
|
3599
3773
|
const displayValue = formFieldMaskFormatDisplay(pattern, rawStored);
|
|
3600
|
-
return /* @__PURE__ */ (0,
|
|
3774
|
+
return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("div", { className: "w-full min-w-0", children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
3601
3775
|
Input,
|
|
3602
3776
|
{
|
|
3603
3777
|
...restInputProps,
|
|
@@ -3634,7 +3808,7 @@ function FormFieldVariantControl({
|
|
|
3634
3808
|
useGrouping
|
|
3635
3809
|
);
|
|
3636
3810
|
const defaultInputMode = allowDecimal ? "decimal" : "numeric";
|
|
3637
|
-
return /* @__PURE__ */ (0,
|
|
3811
|
+
return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("div", { className: "w-full min-w-0", children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
3638
3812
|
Input,
|
|
3639
3813
|
{
|
|
3640
3814
|
...restInputProps,
|
|
@@ -3658,7 +3832,7 @@ function FormFieldVariantControl({
|
|
|
3658
3832
|
}
|
|
3659
3833
|
) });
|
|
3660
3834
|
}
|
|
3661
|
-
return /* @__PURE__ */ (0,
|
|
3835
|
+
return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("div", { className: "w-full min-w-0", children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
3662
3836
|
Input,
|
|
3663
3837
|
{
|
|
3664
3838
|
...restInputProps,
|
|
@@ -3683,9 +3857,9 @@ function FormFieldVariantControl({
|
|
|
3683
3857
|
}
|
|
3684
3858
|
|
|
3685
3859
|
// source/components/primitive/Heading/heading.tsx
|
|
3686
|
-
var
|
|
3860
|
+
var React33 = __toESM(require("react"), 1);
|
|
3687
3861
|
var import_class_variance_authority11 = require("class-variance-authority");
|
|
3688
|
-
var
|
|
3862
|
+
var import_jsx_runtime37 = require("react/jsx-runtime");
|
|
3689
3863
|
var headingVariants = (0, import_class_variance_authority11.cva)(
|
|
3690
3864
|
"text-foreground tracking-tight",
|
|
3691
3865
|
{
|
|
@@ -3751,7 +3925,7 @@ var headingVariants = (0, import_class_variance_authority11.cva)(
|
|
|
3751
3925
|
}
|
|
3752
3926
|
}
|
|
3753
3927
|
);
|
|
3754
|
-
var Heading =
|
|
3928
|
+
var Heading = React33.forwardRef(
|
|
3755
3929
|
({
|
|
3756
3930
|
level = 1,
|
|
3757
3931
|
size,
|
|
@@ -3764,7 +3938,7 @@ var Heading = React31.forwardRef(
|
|
|
3764
3938
|
...props
|
|
3765
3939
|
}, ref) => {
|
|
3766
3940
|
const Tag = `h${level}`;
|
|
3767
|
-
return /* @__PURE__ */ (0,
|
|
3941
|
+
return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
|
|
3768
3942
|
Tag,
|
|
3769
3943
|
{
|
|
3770
3944
|
ref,
|
|
@@ -3780,10 +3954,10 @@ var Heading = React31.forwardRef(
|
|
|
3780
3954
|
Heading.displayName = "Heading";
|
|
3781
3955
|
|
|
3782
3956
|
// source/components/primitive/InputGroup/input-group.tsx
|
|
3783
|
-
var
|
|
3784
|
-
var
|
|
3785
|
-
var InputGroup =
|
|
3786
|
-
({ className, error: error2, children, ...props }, ref) => /* @__PURE__ */ (0,
|
|
3957
|
+
var React34 = __toESM(require("react"), 1);
|
|
3958
|
+
var import_jsx_runtime38 = require("react/jsx-runtime");
|
|
3959
|
+
var InputGroup = React34.forwardRef(
|
|
3960
|
+
({ className, error: error2, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(
|
|
3787
3961
|
"div",
|
|
3788
3962
|
{
|
|
3789
3963
|
ref,
|
|
@@ -3801,7 +3975,7 @@ var InputGroup = React32.forwardRef(
|
|
|
3801
3975
|
)
|
|
3802
3976
|
);
|
|
3803
3977
|
InputGroup.displayName = "InputGroup";
|
|
3804
|
-
var InputGroupIcon =
|
|
3978
|
+
var InputGroupIcon = React34.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(
|
|
3805
3979
|
"span",
|
|
3806
3980
|
{
|
|
3807
3981
|
ref,
|
|
@@ -3814,8 +3988,8 @@ var InputGroupIcon = React32.forwardRef(({ className, ...props }, ref) => /* @__
|
|
|
3814
3988
|
}
|
|
3815
3989
|
));
|
|
3816
3990
|
InputGroupIcon.displayName = "InputGroupIcon";
|
|
3817
|
-
var InputGroupInput =
|
|
3818
|
-
({ className, type, ...props }, ref) => /* @__PURE__ */ (0,
|
|
3991
|
+
var InputGroupInput = React34.forwardRef(
|
|
3992
|
+
({ className, type, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(
|
|
3819
3993
|
"input",
|
|
3820
3994
|
{
|
|
3821
3995
|
ref,
|
|
@@ -3834,10 +4008,10 @@ InputGroupInput.displayName = "InputGroupInput";
|
|
|
3834
4008
|
var inputGroupSelectTriggerTextAlignClass = "pl-12";
|
|
3835
4009
|
|
|
3836
4010
|
// source/components/primitive/Pagination/pagination.tsx
|
|
3837
|
-
var
|
|
3838
|
-
var
|
|
3839
|
-
var
|
|
3840
|
-
var Pagination = ({ className, ...props }) => /* @__PURE__ */ (0,
|
|
4011
|
+
var React35 = __toESM(require("react"), 1);
|
|
4012
|
+
var import_lucide_react12 = require("lucide-react");
|
|
4013
|
+
var import_jsx_runtime39 = require("react/jsx-runtime");
|
|
4014
|
+
var Pagination = ({ className, ...props }) => /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
3841
4015
|
"nav",
|
|
3842
4016
|
{
|
|
3843
4017
|
role: "navigation",
|
|
@@ -3847,7 +4021,7 @@ var Pagination = ({ className, ...props }) => /* @__PURE__ */ (0, import_jsx_run
|
|
|
3847
4021
|
}
|
|
3848
4022
|
);
|
|
3849
4023
|
Pagination.displayName = "Pagination";
|
|
3850
|
-
var PaginationContent =
|
|
4024
|
+
var PaginationContent = React35.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
3851
4025
|
"ul",
|
|
3852
4026
|
{
|
|
3853
4027
|
ref,
|
|
@@ -3856,14 +4030,14 @@ var PaginationContent = React33.forwardRef(({ className, ...props }, ref) => /*
|
|
|
3856
4030
|
}
|
|
3857
4031
|
));
|
|
3858
4032
|
PaginationContent.displayName = "PaginationContent";
|
|
3859
|
-
var PaginationItem =
|
|
4033
|
+
var PaginationItem = React35.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("li", { ref, className: cn("", className), ...props }));
|
|
3860
4034
|
PaginationItem.displayName = "PaginationItem";
|
|
3861
4035
|
var PaginationLink = ({
|
|
3862
4036
|
className,
|
|
3863
4037
|
isActive,
|
|
3864
4038
|
size = "icon",
|
|
3865
4039
|
...props
|
|
3866
|
-
}) => /* @__PURE__ */ (0,
|
|
4040
|
+
}) => /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
3867
4041
|
"a",
|
|
3868
4042
|
{
|
|
3869
4043
|
"aria-current": isActive ? "page" : void 0,
|
|
@@ -3881,7 +4055,7 @@ PaginationLink.displayName = "PaginationLink";
|
|
|
3881
4055
|
var PaginationPrevious = ({
|
|
3882
4056
|
className,
|
|
3883
4057
|
...props
|
|
3884
|
-
}) => /* @__PURE__ */ (0,
|
|
4058
|
+
}) => /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(
|
|
3885
4059
|
PaginationLink,
|
|
3886
4060
|
{
|
|
3887
4061
|
"aria-label": "Go to previous page",
|
|
@@ -3889,8 +4063,8 @@ var PaginationPrevious = ({
|
|
|
3889
4063
|
size: "default",
|
|
3890
4064
|
...props,
|
|
3891
4065
|
children: [
|
|
3892
|
-
/* @__PURE__ */ (0,
|
|
3893
|
-
/* @__PURE__ */ (0,
|
|
4066
|
+
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)(import_lucide_react12.ChevronLeft, { className: "h-4 w-4" }),
|
|
4067
|
+
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)("span", { children: "Previous" })
|
|
3894
4068
|
]
|
|
3895
4069
|
}
|
|
3896
4070
|
);
|
|
@@ -3898,7 +4072,7 @@ PaginationPrevious.displayName = "PaginationPrevious";
|
|
|
3898
4072
|
var PaginationNext = ({
|
|
3899
4073
|
className,
|
|
3900
4074
|
...props
|
|
3901
|
-
}) => /* @__PURE__ */ (0,
|
|
4075
|
+
}) => /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(
|
|
3902
4076
|
PaginationLink,
|
|
3903
4077
|
{
|
|
3904
4078
|
"aria-label": "Go to next page",
|
|
@@ -3906,8 +4080,8 @@ var PaginationNext = ({
|
|
|
3906
4080
|
size: "default",
|
|
3907
4081
|
...props,
|
|
3908
4082
|
children: [
|
|
3909
|
-
/* @__PURE__ */ (0,
|
|
3910
|
-
/* @__PURE__ */ (0,
|
|
4083
|
+
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)("span", { children: "Next" }),
|
|
4084
|
+
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)(import_lucide_react12.ChevronRight, { className: "h-4 w-4" })
|
|
3911
4085
|
]
|
|
3912
4086
|
}
|
|
3913
4087
|
);
|
|
@@ -3915,31 +4089,31 @@ PaginationNext.displayName = "PaginationNext";
|
|
|
3915
4089
|
var PaginationEllipsis = ({
|
|
3916
4090
|
className,
|
|
3917
4091
|
...props
|
|
3918
|
-
}) => /* @__PURE__ */ (0,
|
|
4092
|
+
}) => /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(
|
|
3919
4093
|
"span",
|
|
3920
4094
|
{
|
|
3921
4095
|
"aria-hidden": true,
|
|
3922
4096
|
className: cn("flex h-9 w-9 items-center justify-center", className),
|
|
3923
4097
|
...props,
|
|
3924
4098
|
children: [
|
|
3925
|
-
/* @__PURE__ */ (0,
|
|
3926
|
-
/* @__PURE__ */ (0,
|
|
4099
|
+
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)(import_lucide_react12.MoreHorizontal, { className: "h-4 w-4" }),
|
|
4100
|
+
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)("span", { className: "sr-only", children: "More pages" })
|
|
3927
4101
|
]
|
|
3928
4102
|
}
|
|
3929
4103
|
);
|
|
3930
4104
|
PaginationEllipsis.displayName = "PaginationEllipsis";
|
|
3931
4105
|
|
|
3932
4106
|
// source/components/primitive/Progress/progress.tsx
|
|
3933
|
-
var
|
|
4107
|
+
var React36 = __toESM(require("react"), 1);
|
|
3934
4108
|
var ProgressPrimitive = __toESM(require("@radix-ui/react-progress"), 1);
|
|
3935
|
-
var
|
|
4109
|
+
var import_jsx_runtime40 = require("react/jsx-runtime");
|
|
3936
4110
|
var variantStyles = {
|
|
3937
4111
|
default: "bg-primary",
|
|
3938
4112
|
success: "bg-green-500",
|
|
3939
4113
|
warning: "bg-yellow-500",
|
|
3940
4114
|
error: "bg-red-500"
|
|
3941
4115
|
};
|
|
3942
|
-
var Progress =
|
|
4116
|
+
var Progress = React36.forwardRef(
|
|
3943
4117
|
({
|
|
3944
4118
|
className,
|
|
3945
4119
|
value = 0,
|
|
@@ -3953,15 +4127,15 @@ var Progress = React34.forwardRef(
|
|
|
3953
4127
|
const safeMax = max > 0 ? max : 100;
|
|
3954
4128
|
const safeValue = Math.min(Math.max(value, 0), safeMax);
|
|
3955
4129
|
const percentage = Math.min(safeValue / safeMax * 100, 100);
|
|
3956
|
-
return /* @__PURE__ */ (0,
|
|
3957
|
-
(label || showValue) && /* @__PURE__ */ (0,
|
|
3958
|
-
label && /* @__PURE__ */ (0,
|
|
3959
|
-
showValue && !indeterminate && /* @__PURE__ */ (0,
|
|
4130
|
+
return /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)("div", { className: "flex flex-col gap-1", children: [
|
|
4131
|
+
(label || showValue) && /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)("div", { className: "flex items-center justify-between", children: [
|
|
4132
|
+
label && /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("span", { className: "text-sm font-medium", children: label }),
|
|
4133
|
+
showValue && !indeterminate && /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)("span", { className: "text-xs text-muted-foreground", children: [
|
|
3960
4134
|
Math.round(percentage),
|
|
3961
4135
|
"%"
|
|
3962
4136
|
] })
|
|
3963
4137
|
] }),
|
|
3964
|
-
/* @__PURE__ */ (0,
|
|
4138
|
+
/* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
|
|
3965
4139
|
ProgressPrimitive.Root,
|
|
3966
4140
|
{
|
|
3967
4141
|
ref,
|
|
@@ -3974,7 +4148,7 @@ var Progress = React34.forwardRef(
|
|
|
3974
4148
|
"aria-valuemax": safeMax,
|
|
3975
4149
|
"aria-valuenow": indeterminate ? void 0 : safeValue,
|
|
3976
4150
|
...props,
|
|
3977
|
-
children: /* @__PURE__ */ (0,
|
|
4151
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
|
|
3978
4152
|
ProgressPrimitive.Indicator,
|
|
3979
4153
|
{
|
|
3980
4154
|
className: cn(
|
|
@@ -3994,94 +4168,25 @@ var Progress = React34.forwardRef(
|
|
|
3994
4168
|
);
|
|
3995
4169
|
Progress.displayName = "Progress";
|
|
3996
4170
|
|
|
3997
|
-
// source/components/primitive/RichHtml/rich-html.tsx
|
|
3998
|
-
var React35 = __toESM(require("react"), 1);
|
|
3999
|
-
var import_dompurify = __toESM(require("dompurify"), 1);
|
|
4000
|
-
var import_jsx_runtime39 = require("react/jsx-runtime");
|
|
4001
|
-
var defaultSanitizeConfig = {
|
|
4002
|
-
USE_PROFILES: { html: true }
|
|
4003
|
-
};
|
|
4004
|
-
var richHtmlChrome = cn(
|
|
4005
|
-
"max-w-none text-base leading-relaxed text-foreground",
|
|
4006
|
-
// Block flow
|
|
4007
|
-
"[&_p]:mb-3 [&_p:last-child]:mb-0 [&_blockquote]:my-4 [&_blockquote]:border-l-2 [&_blockquote]:border-muted [&_blockquote]:pl-4 [&_blockquote]:italic",
|
|
4008
|
-
// Lists
|
|
4009
|
-
"[&_ul]:my-3 [&_ul]:list-disc [&_ul]:pl-6 [&_ol]:my-3 [&_ol]:list-decimal [&_ol]:pl-6 [&_li]:my-1 [&_li]:pl-1",
|
|
4010
|
-
// Headings (common for TipTap / CMS output)
|
|
4011
|
-
"[&_h1]:mb-3 [&_h1]:mt-8 [&_h1]:text-3xl [&_h1]:font-semibold [&_h1]:first:mt-0",
|
|
4012
|
-
"[&_h2]:mb-2 [&_h2]:mt-6 [&_h2]:text-2xl [&_h2]:font-semibold [&_h2]:first:mt-0",
|
|
4013
|
-
"[&_h3]:mb-2 [&_h3]:mt-5 [&_h3]:text-xl [&_h3]:font-semibold [&_h3]:first:mt-0",
|
|
4014
|
-
"[&_h4]:mb-2 [&_h4]:mt-4 [&_h4]:text-lg [&_h4]:font-semibold [&_h4]:first:mt-0",
|
|
4015
|
-
// Links & media
|
|
4016
|
-
"[&_a]:text-primary [&_a]:underline [&_a]:underline-offset-2 [&_a]:outline-none [&_a]:focus-visible:ring-2 [&_a]:focus-visible:ring-ring [&_a]:focus-visible:ring-offset-2",
|
|
4017
|
-
"[&_img]:my-4 [&_img]:max-h-[min(480px,70vh)] [&_img]:max-w-full [&_img]:rounded-md [&_img]:object-contain",
|
|
4018
|
-
"[&_hr]:my-6 [&_hr]:border-border",
|
|
4019
|
-
// Code
|
|
4020
|
-
"[&_code]:rounded [&_code]:bg-muted [&_code]:px-1 [&_code]:py-0.5 [&_code]:text-[0.9em]",
|
|
4021
|
-
"[&_pre]:my-4 [&_pre]:overflow-x-auto [&_pre]:rounded-md [&_pre]:bg-muted [&_pre]:p-3 [&_pre]:font-mono [&_pre]:text-sm"
|
|
4022
|
-
);
|
|
4023
|
-
var RichHtml = React35.forwardRef(
|
|
4024
|
-
({
|
|
4025
|
-
html,
|
|
4026
|
-
sanitize = true,
|
|
4027
|
-
sanitizeConfig,
|
|
4028
|
-
className,
|
|
4029
|
-
suppressHydrationWarning,
|
|
4030
|
-
...props
|
|
4031
|
-
}, ref) => {
|
|
4032
|
-
const markup = React35.useMemo(() => {
|
|
4033
|
-
if (html === void 0 || html === null || html === "") {
|
|
4034
|
-
return "";
|
|
4035
|
-
}
|
|
4036
|
-
if (!sanitize) {
|
|
4037
|
-
return html;
|
|
4038
|
-
}
|
|
4039
|
-
if (typeof window === "undefined") {
|
|
4040
|
-
return "";
|
|
4041
|
-
}
|
|
4042
|
-
const config = {
|
|
4043
|
-
...defaultSanitizeConfig,
|
|
4044
|
-
...sanitizeConfig
|
|
4045
|
-
};
|
|
4046
|
-
return import_dompurify.default.sanitize(html, config);
|
|
4047
|
-
}, [html, sanitize, sanitizeConfig]);
|
|
4048
|
-
const resolvedSuppressHydration = suppressHydrationWarning ?? sanitize;
|
|
4049
|
-
if (html === void 0 || html === null || html === "") {
|
|
4050
|
-
return null;
|
|
4051
|
-
}
|
|
4052
|
-
return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
4053
|
-
"div",
|
|
4054
|
-
{
|
|
4055
|
-
ref,
|
|
4056
|
-
suppressHydrationWarning: resolvedSuppressHydration,
|
|
4057
|
-
className: cn(richHtmlChrome, className),
|
|
4058
|
-
...props,
|
|
4059
|
-
dangerouslySetInnerHTML: { __html: markup }
|
|
4060
|
-
}
|
|
4061
|
-
);
|
|
4062
|
-
}
|
|
4063
|
-
);
|
|
4064
|
-
RichHtml.displayName = "RichHtml";
|
|
4065
|
-
|
|
4066
4171
|
// source/components/primitive/ScrollArea/scroll-area.tsx
|
|
4067
|
-
var
|
|
4172
|
+
var React37 = __toESM(require("react"), 1);
|
|
4068
4173
|
var ScrollAreaPrimitive = __toESM(require("@radix-ui/react-scroll-area"), 1);
|
|
4069
|
-
var
|
|
4070
|
-
var ScrollArea =
|
|
4174
|
+
var import_jsx_runtime41 = require("react/jsx-runtime");
|
|
4175
|
+
var ScrollArea = React37.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime41.jsxs)(
|
|
4071
4176
|
ScrollAreaPrimitive.Root,
|
|
4072
4177
|
{
|
|
4073
4178
|
ref,
|
|
4074
4179
|
className: cn("relative overflow-hidden", className),
|
|
4075
4180
|
...props,
|
|
4076
4181
|
children: [
|
|
4077
|
-
/* @__PURE__ */ (0,
|
|
4078
|
-
/* @__PURE__ */ (0,
|
|
4079
|
-
/* @__PURE__ */ (0,
|
|
4182
|
+
/* @__PURE__ */ (0, import_jsx_runtime41.jsx)(ScrollAreaPrimitive.Viewport, { className: "h-full w-full rounded-[inherit]", children }),
|
|
4183
|
+
/* @__PURE__ */ (0, import_jsx_runtime41.jsx)(ScrollBar, {}),
|
|
4184
|
+
/* @__PURE__ */ (0, import_jsx_runtime41.jsx)(ScrollAreaPrimitive.Corner, {})
|
|
4080
4185
|
]
|
|
4081
4186
|
}
|
|
4082
4187
|
));
|
|
4083
4188
|
ScrollArea.displayName = ScrollAreaPrimitive.Root.displayName;
|
|
4084
|
-
var ScrollBar =
|
|
4189
|
+
var ScrollBar = React37.forwardRef(({ className, orientation = "vertical", ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
|
|
4085
4190
|
ScrollAreaPrimitive.ScrollAreaScrollbar,
|
|
4086
4191
|
{
|
|
4087
4192
|
ref,
|
|
@@ -4093,16 +4198,16 @@ var ScrollBar = React36.forwardRef(({ className, orientation = "vertical", ...pr
|
|
|
4093
4198
|
className
|
|
4094
4199
|
),
|
|
4095
4200
|
...props,
|
|
4096
|
-
children: /* @__PURE__ */ (0,
|
|
4201
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(ScrollAreaPrimitive.ScrollAreaThumb, { className: "relative flex-1 rounded-full bg-border" })
|
|
4097
4202
|
}
|
|
4098
4203
|
));
|
|
4099
4204
|
ScrollBar.displayName = ScrollAreaPrimitive.ScrollAreaScrollbar.displayName;
|
|
4100
4205
|
|
|
4101
4206
|
// source/components/primitive/Separator/separator.tsx
|
|
4102
|
-
var
|
|
4207
|
+
var React38 = __toESM(require("react"), 1);
|
|
4103
4208
|
var SeparatorPrimitive = __toESM(require("@radix-ui/react-separator"), 1);
|
|
4104
4209
|
var import_class_variance_authority12 = require("class-variance-authority");
|
|
4105
|
-
var
|
|
4210
|
+
var import_jsx_runtime42 = require("react/jsx-runtime");
|
|
4106
4211
|
var separatorVariants = (0, import_class_variance_authority12.cva)("shrink-0", {
|
|
4107
4212
|
variants: {
|
|
4108
4213
|
orientation: {
|
|
@@ -4120,7 +4225,7 @@ var separatorVariants = (0, import_class_variance_authority12.cva)("shrink-0", {
|
|
|
4120
4225
|
line: "solid"
|
|
4121
4226
|
}
|
|
4122
4227
|
});
|
|
4123
|
-
var Separator3 =
|
|
4228
|
+
var Separator3 = React38.forwardRef(
|
|
4124
4229
|
({
|
|
4125
4230
|
className,
|
|
4126
4231
|
orientation = "horizontal",
|
|
@@ -4132,13 +4237,13 @@ var Separator3 = React37.forwardRef(
|
|
|
4132
4237
|
}, ref) => {
|
|
4133
4238
|
const line = lineProp ?? variant ?? "solid";
|
|
4134
4239
|
if (label && orientation === "horizontal") {
|
|
4135
|
-
return /* @__PURE__ */ (0,
|
|
4240
|
+
return /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)(
|
|
4136
4241
|
"div",
|
|
4137
4242
|
{
|
|
4138
4243
|
role: "separator",
|
|
4139
4244
|
className: "flex items-center gap-3",
|
|
4140
4245
|
children: [
|
|
4141
|
-
/* @__PURE__ */ (0,
|
|
4246
|
+
/* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
|
|
4142
4247
|
"div",
|
|
4143
4248
|
{
|
|
4144
4249
|
className: cn(
|
|
@@ -4147,8 +4252,8 @@ var Separator3 = React37.forwardRef(
|
|
|
4147
4252
|
)
|
|
4148
4253
|
}
|
|
4149
4254
|
),
|
|
4150
|
-
/* @__PURE__ */ (0,
|
|
4151
|
-
/* @__PURE__ */ (0,
|
|
4255
|
+
/* @__PURE__ */ (0, import_jsx_runtime42.jsx)("span", { className: "text-xs text-muted-foreground whitespace-nowrap", children: label }),
|
|
4256
|
+
/* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
|
|
4152
4257
|
"div",
|
|
4153
4258
|
{
|
|
4154
4259
|
className: cn(
|
|
@@ -4161,7 +4266,7 @@ var Separator3 = React37.forwardRef(
|
|
|
4161
4266
|
}
|
|
4162
4267
|
);
|
|
4163
4268
|
}
|
|
4164
|
-
return /* @__PURE__ */ (0,
|
|
4269
|
+
return /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
|
|
4165
4270
|
SeparatorPrimitive.Root,
|
|
4166
4271
|
{
|
|
4167
4272
|
ref,
|
|
@@ -4179,16 +4284,16 @@ var Separator3 = React37.forwardRef(
|
|
|
4179
4284
|
Separator3.displayName = "Separator";
|
|
4180
4285
|
|
|
4181
4286
|
// source/components/primitive/Sheet/sheet.tsx
|
|
4182
|
-
var
|
|
4287
|
+
var React39 = __toESM(require("react"), 1);
|
|
4183
4288
|
var SheetPrimitive = __toESM(require("@radix-ui/react-dialog"), 1);
|
|
4184
4289
|
var import_class_variance_authority13 = require("class-variance-authority");
|
|
4185
|
-
var
|
|
4186
|
-
var
|
|
4290
|
+
var import_lucide_react13 = require("lucide-react");
|
|
4291
|
+
var import_jsx_runtime43 = require("react/jsx-runtime");
|
|
4187
4292
|
var Sheet = SheetPrimitive.Root;
|
|
4188
4293
|
var SheetTrigger = SheetPrimitive.Trigger;
|
|
4189
4294
|
var SheetClose = SheetPrimitive.Close;
|
|
4190
4295
|
var SheetPortal = SheetPrimitive.Portal;
|
|
4191
|
-
var SheetOverlay =
|
|
4296
|
+
var SheetOverlay = React39.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
|
|
4192
4297
|
SheetPrimitive.Overlay,
|
|
4193
4298
|
{
|
|
4194
4299
|
className: cn(
|
|
@@ -4216,9 +4321,9 @@ var sheetVariants = (0, import_class_variance_authority13.cva)(
|
|
|
4216
4321
|
}
|
|
4217
4322
|
}
|
|
4218
4323
|
);
|
|
4219
|
-
var SheetContent =
|
|
4220
|
-
/* @__PURE__ */ (0,
|
|
4221
|
-
/* @__PURE__ */ (0,
|
|
4324
|
+
var SheetContent = React39.forwardRef(({ side = "right", className, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)(SheetPortal, { children: [
|
|
4325
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)(SheetOverlay, {}),
|
|
4326
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsxs)(
|
|
4222
4327
|
SheetPrimitive.Content,
|
|
4223
4328
|
{
|
|
4224
4329
|
ref,
|
|
@@ -4226,9 +4331,9 @@ var SheetContent = React38.forwardRef(({ side = "right", className, children, ..
|
|
|
4226
4331
|
...props,
|
|
4227
4332
|
children: [
|
|
4228
4333
|
children,
|
|
4229
|
-
/* @__PURE__ */ (0,
|
|
4230
|
-
/* @__PURE__ */ (0,
|
|
4231
|
-
/* @__PURE__ */ (0,
|
|
4334
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsxs)(SheetPrimitive.Close, { className: "absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-secondary", children: [
|
|
4335
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)(import_lucide_react13.X, { className: "h-4 w-4" }),
|
|
4336
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)("span", { className: "sr-only", children: "Close" })
|
|
4232
4337
|
] })
|
|
4233
4338
|
]
|
|
4234
4339
|
}
|
|
@@ -4238,7 +4343,7 @@ SheetContent.displayName = SheetPrimitive.Content.displayName;
|
|
|
4238
4343
|
var SheetHeader = ({
|
|
4239
4344
|
className,
|
|
4240
4345
|
...props
|
|
4241
|
-
}) => /* @__PURE__ */ (0,
|
|
4346
|
+
}) => /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
|
|
4242
4347
|
"div",
|
|
4243
4348
|
{
|
|
4244
4349
|
className: cn(
|
|
@@ -4252,7 +4357,7 @@ SheetHeader.displayName = "SheetHeader";
|
|
|
4252
4357
|
var SheetFooter = ({
|
|
4253
4358
|
className,
|
|
4254
4359
|
...props
|
|
4255
|
-
}) => /* @__PURE__ */ (0,
|
|
4360
|
+
}) => /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
|
|
4256
4361
|
"div",
|
|
4257
4362
|
{
|
|
4258
4363
|
className: cn(
|
|
@@ -4263,7 +4368,7 @@ var SheetFooter = ({
|
|
|
4263
4368
|
}
|
|
4264
4369
|
);
|
|
4265
4370
|
SheetFooter.displayName = "SheetFooter";
|
|
4266
|
-
var SheetTitle =
|
|
4371
|
+
var SheetTitle = React39.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
|
|
4267
4372
|
SheetPrimitive.Title,
|
|
4268
4373
|
{
|
|
4269
4374
|
ref,
|
|
@@ -4272,7 +4377,7 @@ var SheetTitle = React38.forwardRef(({ className, ...props }, ref) => /* @__PURE
|
|
|
4272
4377
|
}
|
|
4273
4378
|
));
|
|
4274
4379
|
SheetTitle.displayName = SheetPrimitive.Title.displayName;
|
|
4275
|
-
var SheetDescription =
|
|
4380
|
+
var SheetDescription = React39.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
|
|
4276
4381
|
SheetPrimitive.Description,
|
|
4277
4382
|
{
|
|
4278
4383
|
ref,
|
|
@@ -4286,16 +4391,16 @@ SheetDescription.displayName = SheetPrimitive.Description.displayName;
|
|
|
4286
4391
|
var React42 = __toESM(require("react"), 1);
|
|
4287
4392
|
var import_react_slot3 = require("@radix-ui/react-slot");
|
|
4288
4393
|
var import_class_variance_authority15 = require("class-variance-authority");
|
|
4289
|
-
var
|
|
4394
|
+
var import_lucide_react14 = require("lucide-react");
|
|
4290
4395
|
|
|
4291
4396
|
// source/hooks/use-mobile.ts
|
|
4292
|
-
var
|
|
4397
|
+
var React40 = __toESM(require("react"), 1);
|
|
4293
4398
|
var MOBILE_MAX = 768;
|
|
4294
4399
|
function useIsMobile(breakpoint = MOBILE_MAX) {
|
|
4295
|
-
const [isMobile, setIsMobile] =
|
|
4400
|
+
const [isMobile, setIsMobile] = React40.useState(
|
|
4296
4401
|
() => typeof window !== "undefined" ? window.innerWidth < breakpoint : false
|
|
4297
4402
|
);
|
|
4298
|
-
|
|
4403
|
+
React40.useEffect(() => {
|
|
4299
4404
|
const mq = window.matchMedia(`(max-width: ${breakpoint - 1}px)`);
|
|
4300
4405
|
const onChange = () => setIsMobile(mq.matches);
|
|
4301
4406
|
onChange();
|
|
@@ -4306,9 +4411,9 @@ function useIsMobile(breakpoint = MOBILE_MAX) {
|
|
|
4306
4411
|
}
|
|
4307
4412
|
|
|
4308
4413
|
// source/components/primitive/Skeleton/skeleton.tsx
|
|
4309
|
-
var
|
|
4414
|
+
var React41 = __toESM(require("react"), 1);
|
|
4310
4415
|
var import_class_variance_authority14 = require("class-variance-authority");
|
|
4311
|
-
var
|
|
4416
|
+
var import_jsx_runtime44 = require("react/jsx-runtime");
|
|
4312
4417
|
var skeletonVariants = (0, import_class_variance_authority14.cva)(
|
|
4313
4418
|
"animate-pulse bg-muted",
|
|
4314
4419
|
{
|
|
@@ -4325,9 +4430,9 @@ var skeletonVariants = (0, import_class_variance_authority14.cva)(
|
|
|
4325
4430
|
}
|
|
4326
4431
|
}
|
|
4327
4432
|
);
|
|
4328
|
-
var Skeleton =
|
|
4433
|
+
var Skeleton = React41.forwardRef(
|
|
4329
4434
|
({ className, rounded, ...props }, ref) => {
|
|
4330
|
-
return /* @__PURE__ */ (0,
|
|
4435
|
+
return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
4331
4436
|
"div",
|
|
4332
4437
|
{
|
|
4333
4438
|
ref,
|
|
@@ -4341,43 +4446,6 @@ var Skeleton = React40.forwardRef(
|
|
|
4341
4446
|
);
|
|
4342
4447
|
Skeleton.displayName = "Skeleton";
|
|
4343
4448
|
|
|
4344
|
-
// source/components/primitive/ToolTip/tooltip.tsx
|
|
4345
|
-
var React41 = __toESM(require("react"), 1);
|
|
4346
|
-
var TooltipPrimitive = __toESM(require("@radix-ui/react-tooltip"), 1);
|
|
4347
|
-
var import_jsx_runtime44 = require("react/jsx-runtime");
|
|
4348
|
-
var TooltipProvider = TooltipPrimitive.Provider;
|
|
4349
|
-
var Tooltip = ({ ...props }) => {
|
|
4350
|
-
return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(TooltipPrimitive.Root, { ...props });
|
|
4351
|
-
};
|
|
4352
|
-
Tooltip.displayName = "Tooltip";
|
|
4353
|
-
var TooltipTrigger = TooltipPrimitive.Trigger;
|
|
4354
|
-
TooltipTrigger.displayName = "TooltipTrigger";
|
|
4355
|
-
var TooltipContent = React41.forwardRef(({ className, sideOffset = 4, arrow = false, children, ...props }, ref) => {
|
|
4356
|
-
return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(TooltipPrimitive.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(
|
|
4357
|
-
TooltipPrimitive.Content,
|
|
4358
|
-
{
|
|
4359
|
-
ref,
|
|
4360
|
-
sideOffset,
|
|
4361
|
-
className: cn(
|
|
4362
|
-
"z-50 overflow-hidden rounded-md border bg-popover px-3 py-1.5 text-sm text-popover-foreground shadow-md",
|
|
4363
|
-
"animate-in fade-in-0 zoom-in-95",
|
|
4364
|
-
"data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95",
|
|
4365
|
-
"data-[side=bottom]:slide-in-from-top-2",
|
|
4366
|
-
"data-[side=left]:slide-in-from-right-2",
|
|
4367
|
-
"data-[side=right]:slide-in-from-left-2",
|
|
4368
|
-
"data-[side=top]:slide-in-from-bottom-2",
|
|
4369
|
-
className
|
|
4370
|
-
),
|
|
4371
|
-
...props,
|
|
4372
|
-
children: [
|
|
4373
|
-
children,
|
|
4374
|
-
arrow && /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(TooltipPrimitive.Arrow, { className: "fill-popover" })
|
|
4375
|
-
]
|
|
4376
|
-
}
|
|
4377
|
-
) });
|
|
4378
|
-
});
|
|
4379
|
-
TooltipContent.displayName = "TooltipContent";
|
|
4380
|
-
|
|
4381
4449
|
// source/components/primitive/Sidebar/sidebar.tsx
|
|
4382
4450
|
var import_jsx_runtime45 = require("react/jsx-runtime");
|
|
4383
4451
|
var SIDEBAR_COOKIE_NAME = "sidebar:state";
|
|
@@ -4598,7 +4666,7 @@ var SidebarTrigger = React42.forwardRef(({ className, onClick, ...props }, ref)
|
|
|
4598
4666
|
},
|
|
4599
4667
|
...props,
|
|
4600
4668
|
children: [
|
|
4601
|
-
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
|
|
4669
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)(import_lucide_react14.PanelLeft, {}),
|
|
4602
4670
|
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)("span", { className: "sr-only", children: "Toggle Sidebar" })
|
|
4603
4671
|
]
|
|
4604
4672
|
}
|