@bergetai/ui 0.4.0 → 0.5.0
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 +1273 -969
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +45 -71
- package/dist/index.d.ts +45 -71
- package/dist/index.js +1272 -968
- package/dist/index.js.map +1 -1
- package/package.json +3 -2
package/dist/index.cjs
CHANGED
|
@@ -124,8 +124,8 @@ __export(index_exports, {
|
|
|
124
124
|
NavigationMenuItem: () => NavigationMenuItem,
|
|
125
125
|
NavigationMenuLink: () => NavigationMenuLink,
|
|
126
126
|
NavigationMenuList: () => NavigationMenuList,
|
|
127
|
+
NavigationMenuPositioner: () => NavigationMenuPositioner,
|
|
127
128
|
NavigationMenuTrigger: () => NavigationMenuTrigger,
|
|
128
|
-
NavigationMenuViewport: () => NavigationMenuViewport,
|
|
129
129
|
Select: () => Select2,
|
|
130
130
|
Switch: () => Switch,
|
|
131
131
|
Table: () => Table2,
|
|
@@ -153,7 +153,7 @@ __export(index_exports, {
|
|
|
153
153
|
gridVariants: () => gridVariants,
|
|
154
154
|
isEUCountry: () => isEUCountry,
|
|
155
155
|
linkVariants: () => linkVariants,
|
|
156
|
-
navigationMenuTriggerStyle: () =>
|
|
156
|
+
navigationMenuTriggerStyle: () => navigationMenuTriggerStyle2,
|
|
157
157
|
selectVariants: () => selectVariants,
|
|
158
158
|
switchRootVariants: () => switchRootVariants,
|
|
159
159
|
switchThumbVariants: () => switchThumbVariants,
|
|
@@ -363,31 +363,31 @@ var ThemeToggle = React3.forwardRef(
|
|
|
363
363
|
ThemeToggle.displayName = "ThemeToggle";
|
|
364
364
|
|
|
365
365
|
// src/primitives/button.tsx
|
|
366
|
-
var React4 = __toESM(require("react"), 1);
|
|
367
|
-
var import_class_variance_authority = require("class-variance-authority");
|
|
368
366
|
var import_button = require("@base-ui/react/button");
|
|
367
|
+
var import_class_variance_authority = require("class-variance-authority");
|
|
368
|
+
var import_cn = require("cn");
|
|
369
369
|
var import_jsx_runtime3 = require("react/jsx-runtime");
|
|
370
370
|
var buttonVariants = (0, import_class_variance_authority.cva)(
|
|
371
|
-
"inline-flex shrink-0
|
|
371
|
+
"group/button inline-flex shrink-0 items-center justify-center rounded-lg border border-transparent bg-clip-padding text-sm font-medium whitespace-nowrap transition-all outline-none select-none focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 active:not-aria-[haspopup]:translate-y-px disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
|
|
372
372
|
{
|
|
373
373
|
variants: {
|
|
374
374
|
variant: {
|
|
375
|
-
default: "bg-primary text-primary-foreground hover:bg-primary/
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
375
|
+
default: "bg-primary text-primary-foreground hover:bg-primary/80",
|
|
376
|
+
outline: "border-border bg-background hover:bg-muted hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground dark:border-input dark:bg-input/30 dark:hover:bg-input/50",
|
|
377
|
+
secondary: "bg-secondary text-secondary-foreground hover:bg-[color-mix(in_oklch,var(--secondary),var(--foreground)_5%)] aria-expanded:bg-secondary aria-expanded:text-secondary-foreground",
|
|
378
|
+
ghost: "hover:bg-muted hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground dark:hover:bg-muted/50",
|
|
379
|
+
destructive: "bg-destructive/10 text-destructive hover:bg-destructive/20 focus-visible:border-destructive/40 focus-visible:ring-destructive/20 dark:bg-destructive/20 dark:hover:bg-destructive/30 dark:focus-visible:ring-destructive/40",
|
|
380
380
|
link: "text-primary underline-offset-4 hover:underline"
|
|
381
381
|
},
|
|
382
382
|
size: {
|
|
383
|
-
default: "h-
|
|
384
|
-
xs: "h-6 gap-1 rounded-md px-2 text-xs has-[
|
|
385
|
-
sm: "h-
|
|
386
|
-
lg: "h-
|
|
387
|
-
icon: "size-
|
|
388
|
-
"icon-xs": "size-6 rounded-md [&_svg:not([class*='size-'])]:size-3",
|
|
389
|
-
"icon-sm": "size-
|
|
390
|
-
"icon-lg": "size-
|
|
383
|
+
default: "h-8 gap-1.5 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2",
|
|
384
|
+
xs: "h-6 gap-1 rounded-[min(var(--radius-md),10px)] px-2 text-xs in-data-[slot=button-group]:rounded-lg has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3",
|
|
385
|
+
sm: "h-7 gap-1 rounded-[min(var(--radius-md),12px)] px-2.5 text-[0.8rem] in-data-[slot=button-group]:rounded-lg has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3.5",
|
|
386
|
+
lg: "h-9 gap-1.5 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2",
|
|
387
|
+
icon: "size-8",
|
|
388
|
+
"icon-xs": "size-6 rounded-[min(var(--radius-md),10px)] in-data-[slot=button-group]:rounded-lg [&_svg:not([class*='size-'])]:size-3",
|
|
389
|
+
"icon-sm": "size-7 rounded-[min(var(--radius-md),12px)] in-data-[slot=button-group]:rounded-lg",
|
|
390
|
+
"icon-lg": "size-9"
|
|
391
391
|
}
|
|
392
392
|
},
|
|
393
393
|
defaultVariants: {
|
|
@@ -396,22 +396,21 @@ var buttonVariants = (0, import_class_variance_authority.cva)(
|
|
|
396
396
|
}
|
|
397
397
|
}
|
|
398
398
|
);
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
Button.displayName = "Button";
|
|
399
|
+
function Button({
|
|
400
|
+
className,
|
|
401
|
+
variant = "default",
|
|
402
|
+
size = "default",
|
|
403
|
+
...props
|
|
404
|
+
}) {
|
|
405
|
+
return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
406
|
+
import_button.Button,
|
|
407
|
+
{
|
|
408
|
+
"data-slot": "button",
|
|
409
|
+
className: (0, import_cn.cn)(buttonVariants({ variant, size, className })),
|
|
410
|
+
...props
|
|
411
|
+
}
|
|
412
|
+
);
|
|
413
|
+
}
|
|
415
414
|
|
|
416
415
|
// src/components/button/Button.tsx
|
|
417
416
|
var import_jsx_runtime4 = require("react/jsx-runtime");
|
|
@@ -464,11 +463,21 @@ function Button2({
|
|
|
464
463
|
className
|
|
465
464
|
);
|
|
466
465
|
const content = /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("span", { className: cn("inline-flex items-center", !isIcon && "gap-2"), children });
|
|
467
|
-
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
466
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
467
|
+
Button,
|
|
468
|
+
{
|
|
469
|
+
className: baseClass,
|
|
470
|
+
ref,
|
|
471
|
+
render: asChildRender(asChild, children),
|
|
472
|
+
type,
|
|
473
|
+
...props,
|
|
474
|
+
children: asChild ? void 0 : content
|
|
475
|
+
}
|
|
476
|
+
);
|
|
468
477
|
}
|
|
469
478
|
|
|
470
479
|
// src/components/typography/Typography.tsx
|
|
471
|
-
var
|
|
480
|
+
var React4 = __toESM(require("react"), 1);
|
|
472
481
|
var import_class_variance_authority2 = require("class-variance-authority");
|
|
473
482
|
var import_jsx_runtime5 = require("react/jsx-runtime");
|
|
474
483
|
var typographyVariants = (0, import_class_variance_authority2.cva)("", {
|
|
@@ -515,7 +524,7 @@ var defaultElementMap = {
|
|
|
515
524
|
mono: "p",
|
|
516
525
|
code: "span"
|
|
517
526
|
};
|
|
518
|
-
var Typography =
|
|
527
|
+
var Typography = React4.forwardRef(
|
|
519
528
|
({ className, variant = "body", color = "default", as, children, ...props }, ref) => {
|
|
520
529
|
const Component = as ?? defaultElementMap[variant ?? "body"] ?? "p";
|
|
521
530
|
return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
@@ -532,43 +541,89 @@ var Typography = React5.forwardRef(
|
|
|
532
541
|
Typography.displayName = "Typography";
|
|
533
542
|
|
|
534
543
|
// src/components/card/Card.tsx
|
|
535
|
-
var
|
|
544
|
+
var React5 = __toESM(require("react"), 1);
|
|
536
545
|
var import_class_variance_authority3 = require("class-variance-authority");
|
|
537
546
|
|
|
538
547
|
// src/primitives/card.tsx
|
|
539
|
-
var
|
|
548
|
+
var import_cn2 = require("cn");
|
|
540
549
|
var import_jsx_runtime6 = require("react/jsx-runtime");
|
|
541
|
-
|
|
542
|
-
|
|
550
|
+
function Card({
|
|
551
|
+
className,
|
|
552
|
+
size = "default",
|
|
553
|
+
...props
|
|
554
|
+
}) {
|
|
555
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
543
556
|
"div",
|
|
544
557
|
{
|
|
545
|
-
|
|
546
|
-
|
|
558
|
+
"data-slot": "card",
|
|
559
|
+
"data-size": size,
|
|
560
|
+
className: (0, import_cn2.cn)(
|
|
561
|
+
"group/card flex flex-col gap-(--card-spacing) overflow-hidden rounded-xl bg-card py-(--card-spacing) text-sm text-card-foreground ring-1 ring-foreground/10 [--card-spacing:--spacing(4)] has-data-[slot=card-footer]:pb-0 has-[>img:first-child]:pt-0 data-[size=sm]:[--card-spacing:--spacing(3)] data-[size=sm]:has-data-[slot=card-footer]:pb-0 *:[img:first-child]:rounded-t-xl *:[img:last-child]:rounded-b-xl",
|
|
562
|
+
className
|
|
563
|
+
),
|
|
547
564
|
...props
|
|
548
565
|
}
|
|
549
|
-
)
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
);
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
566
|
+
);
|
|
567
|
+
}
|
|
568
|
+
function CardHeader({ className, ...props }) {
|
|
569
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
570
|
+
"div",
|
|
571
|
+
{
|
|
572
|
+
"data-slot": "card-header",
|
|
573
|
+
className: (0, import_cn2.cn)(
|
|
574
|
+
"group/card-header @container/card-header grid auto-rows-min items-start gap-1 rounded-t-xl px-(--card-spacing) has-data-[slot=card-action]:grid-cols-[1fr_auto] has-data-[slot=card-description]:grid-rows-[auto_auto] [.border-b]:pb-(--card-spacing)",
|
|
575
|
+
className
|
|
576
|
+
),
|
|
577
|
+
...props
|
|
578
|
+
}
|
|
579
|
+
);
|
|
580
|
+
}
|
|
581
|
+
function CardTitle({ className, ...props }) {
|
|
582
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
583
|
+
"div",
|
|
584
|
+
{
|
|
585
|
+
"data-slot": "card-title",
|
|
586
|
+
className: (0, import_cn2.cn)(
|
|
587
|
+
"text-base leading-snug font-medium group-data-[size=sm]/card:text-sm",
|
|
588
|
+
className
|
|
589
|
+
),
|
|
590
|
+
...props
|
|
591
|
+
}
|
|
592
|
+
);
|
|
593
|
+
}
|
|
594
|
+
function CardDescription({ className, ...props }) {
|
|
595
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
596
|
+
"div",
|
|
597
|
+
{
|
|
598
|
+
"data-slot": "card-description",
|
|
599
|
+
className: (0, import_cn2.cn)("text-sm text-muted-foreground", className),
|
|
600
|
+
...props
|
|
601
|
+
}
|
|
602
|
+
);
|
|
603
|
+
}
|
|
604
|
+
function CardContent({ className, ...props }) {
|
|
605
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
606
|
+
"div",
|
|
607
|
+
{
|
|
608
|
+
"data-slot": "card-content",
|
|
609
|
+
className: (0, import_cn2.cn)("px-(--card-spacing)", className),
|
|
610
|
+
...props
|
|
611
|
+
}
|
|
612
|
+
);
|
|
613
|
+
}
|
|
614
|
+
function CardFooter({ className, ...props }) {
|
|
615
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
616
|
+
"div",
|
|
617
|
+
{
|
|
618
|
+
"data-slot": "card-footer",
|
|
619
|
+
className: (0, import_cn2.cn)(
|
|
620
|
+
"flex items-center rounded-b-xl border-t bg-muted/50 p-(--card-spacing)",
|
|
621
|
+
className
|
|
622
|
+
),
|
|
623
|
+
...props
|
|
624
|
+
}
|
|
625
|
+
);
|
|
626
|
+
}
|
|
572
627
|
|
|
573
628
|
// src/components/card/Card.tsx
|
|
574
629
|
var import_jsx_runtime7 = require("react/jsx-runtime");
|
|
@@ -590,7 +645,7 @@ var cardVariants = (0, import_class_variance_authority3.cva)("rounded-berget-sm"
|
|
|
590
645
|
padding: "md"
|
|
591
646
|
}
|
|
592
647
|
});
|
|
593
|
-
var Card2 =
|
|
648
|
+
var Card2 = React5.forwardRef(
|
|
594
649
|
({ className, variant, padding, children, ...props }, ref) => {
|
|
595
650
|
return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
|
|
596
651
|
Card,
|
|
@@ -606,7 +661,7 @@ var Card2 = React7.forwardRef(
|
|
|
606
661
|
Card2.displayName = "Card";
|
|
607
662
|
|
|
608
663
|
// src/components/badge/Badge.tsx
|
|
609
|
-
var
|
|
664
|
+
var React6 = __toESM(require("react"), 1);
|
|
610
665
|
var import_class_variance_authority4 = require("class-variance-authority");
|
|
611
666
|
var import_jsx_runtime8 = require("react/jsx-runtime");
|
|
612
667
|
var badgeVariants = (0, import_class_variance_authority4.cva)(
|
|
@@ -641,7 +696,7 @@ var badgeVariants = (0, import_class_variance_authority4.cva)(
|
|
|
641
696
|
}
|
|
642
697
|
}
|
|
643
698
|
);
|
|
644
|
-
var Badge =
|
|
699
|
+
var Badge = React6.forwardRef(
|
|
645
700
|
({ className, variant, status, size, icon, iconGap = 2, children, ...props }, ref) => {
|
|
646
701
|
return /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)("div", { className: cn(badgeVariants({ variant, status, size }), className), ref, ...props, children: [
|
|
647
702
|
icon && /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("div", { style: { marginRight: children ? `${iconGap * 0.25}rem` : "0" }, children: icon }),
|
|
@@ -652,20 +707,20 @@ var Badge = React8.forwardRef(
|
|
|
652
707
|
Badge.displayName = "Badge";
|
|
653
708
|
|
|
654
709
|
// src/components/alert/Alert.tsx
|
|
655
|
-
var
|
|
710
|
+
var React7 = __toESM(require("react"), 1);
|
|
656
711
|
var import_class_variance_authority6 = require("class-variance-authority");
|
|
657
712
|
|
|
658
713
|
// src/primitives/alert.tsx
|
|
659
|
-
var React9 = __toESM(require("react"), 1);
|
|
660
714
|
var import_class_variance_authority5 = require("class-variance-authority");
|
|
715
|
+
var import_cn3 = require("cn");
|
|
661
716
|
var import_jsx_runtime9 = require("react/jsx-runtime");
|
|
662
717
|
var alertVariants = (0, import_class_variance_authority5.cva)(
|
|
663
|
-
"relative w-full rounded-lg
|
|
718
|
+
"group/alert relative grid w-full gap-0.5 rounded-lg border px-2.5 py-2 text-left text-sm has-data-[slot=alert-action]:relative has-data-[slot=alert-action]:pr-18 has-[>svg]:grid-cols-[auto_1fr] has-[>svg]:gap-x-2 *:[svg]:row-span-2 *:[svg]:translate-y-0.5 *:[svg]:text-current *:[svg:not([class*='size-'])]:size-4",
|
|
664
719
|
{
|
|
665
720
|
variants: {
|
|
666
721
|
variant: {
|
|
667
|
-
default: "",
|
|
668
|
-
destructive: ""
|
|
722
|
+
default: "bg-card text-card-foreground",
|
|
723
|
+
destructive: "bg-card text-destructive *:data-[slot=alert-description]:text-destructive/90 *:[svg]:text-current"
|
|
669
724
|
}
|
|
670
725
|
},
|
|
671
726
|
defaultVariants: {
|
|
@@ -673,14 +728,50 @@ var alertVariants = (0, import_class_variance_authority5.cva)(
|
|
|
673
728
|
}
|
|
674
729
|
}
|
|
675
730
|
);
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
|
|
680
|
-
)
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
|
|
731
|
+
function Alert({
|
|
732
|
+
className,
|
|
733
|
+
variant,
|
|
734
|
+
...props
|
|
735
|
+
}) {
|
|
736
|
+
return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
|
|
737
|
+
"div",
|
|
738
|
+
{
|
|
739
|
+
"data-slot": "alert",
|
|
740
|
+
role: "alert",
|
|
741
|
+
className: (0, import_cn3.cn)(alertVariants({ variant }), className),
|
|
742
|
+
...props
|
|
743
|
+
}
|
|
744
|
+
);
|
|
745
|
+
}
|
|
746
|
+
function AlertTitle({ className, ...props }) {
|
|
747
|
+
return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
|
|
748
|
+
"div",
|
|
749
|
+
{
|
|
750
|
+
"data-slot": "alert-title",
|
|
751
|
+
className: (0, import_cn3.cn)(
|
|
752
|
+
"font-medium group-has-[>svg]/alert:col-start-2 [&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground",
|
|
753
|
+
className
|
|
754
|
+
),
|
|
755
|
+
...props
|
|
756
|
+
}
|
|
757
|
+
);
|
|
758
|
+
}
|
|
759
|
+
function AlertDescription({
|
|
760
|
+
className,
|
|
761
|
+
...props
|
|
762
|
+
}) {
|
|
763
|
+
return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
|
|
764
|
+
"div",
|
|
765
|
+
{
|
|
766
|
+
"data-slot": "alert-description",
|
|
767
|
+
className: (0, import_cn3.cn)(
|
|
768
|
+
"text-sm text-balance text-muted-foreground md:text-pretty [&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground [&_p:not(:last-child)]:mb-4",
|
|
769
|
+
className
|
|
770
|
+
),
|
|
771
|
+
...props
|
|
772
|
+
}
|
|
773
|
+
);
|
|
774
|
+
}
|
|
684
775
|
|
|
685
776
|
// src/components/alert/Alert.tsx
|
|
686
777
|
var import_jsx_runtime10 = require("react/jsx-runtime");
|
|
@@ -698,24 +789,24 @@ var alertVariants2 = (0, import_class_variance_authority6.cva)("", {
|
|
|
698
789
|
variant: "default"
|
|
699
790
|
}
|
|
700
791
|
});
|
|
701
|
-
var Alert2 =
|
|
792
|
+
var Alert2 = React7.forwardRef(
|
|
702
793
|
({ className, variant, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(Alert, { ref, className: cn(alertVariants2({ variant }), className), ...props })
|
|
703
794
|
);
|
|
704
795
|
Alert2.displayName = "Alert";
|
|
705
796
|
|
|
706
797
|
// src/components/dialog/Dialog.tsx
|
|
707
|
-
var
|
|
798
|
+
var React8 = __toESM(require("react"), 1);
|
|
708
799
|
var import_dialog = require("@base-ui/react/dialog");
|
|
709
800
|
var import_lucide_react = require("lucide-react");
|
|
710
801
|
var import_jsx_runtime11 = require("react/jsx-runtime");
|
|
711
802
|
var Dialog = import_dialog.Dialog.Root;
|
|
712
|
-
var DialogTrigger =
|
|
803
|
+
var DialogTrigger = React8.forwardRef(
|
|
713
804
|
({ asChild, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_dialog.Dialog.Trigger, { ref, render: asChildRender(asChild, children), ...props, children: asChild ? void 0 : children })
|
|
714
805
|
);
|
|
715
806
|
DialogTrigger.displayName = "DialogTrigger";
|
|
716
807
|
var DialogPortal = import_dialog.Dialog.Portal;
|
|
717
808
|
var DialogClose = import_dialog.Dialog.Close;
|
|
718
|
-
var DialogOverlay =
|
|
809
|
+
var DialogOverlay = React8.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
|
|
719
810
|
import_dialog.Dialog.Backdrop,
|
|
720
811
|
{
|
|
721
812
|
ref,
|
|
@@ -727,7 +818,7 @@ var DialogOverlay = React11.forwardRef(({ className, ...props }, ref) => /* @__P
|
|
|
727
818
|
}
|
|
728
819
|
));
|
|
729
820
|
DialogOverlay.displayName = "DialogOverlay";
|
|
730
|
-
var DialogContent =
|
|
821
|
+
var DialogContent = React8.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(DialogPortal, { children: [
|
|
731
822
|
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)(DialogOverlay, {}),
|
|
732
823
|
/* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(
|
|
733
824
|
import_dialog.Dialog.Popup,
|
|
@@ -759,7 +850,7 @@ var DialogFooter = ({ className, ...props }) => /* @__PURE__ */ (0, import_jsx_r
|
|
|
759
850
|
}
|
|
760
851
|
);
|
|
761
852
|
DialogFooter.displayName = "DialogFooter";
|
|
762
|
-
var DialogTitle =
|
|
853
|
+
var DialogTitle = React8.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
|
|
763
854
|
import_dialog.Dialog.Title,
|
|
764
855
|
{
|
|
765
856
|
ref,
|
|
@@ -769,7 +860,7 @@ var DialogTitle = React11.forwardRef(({ className, children, ...props }, ref) =>
|
|
|
769
860
|
}
|
|
770
861
|
));
|
|
771
862
|
DialogTitle.displayName = "DialogTitle";
|
|
772
|
-
var DialogDescription =
|
|
863
|
+
var DialogDescription = React8.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
|
|
773
864
|
import_dialog.Dialog.Description,
|
|
774
865
|
{
|
|
775
866
|
ref,
|
|
@@ -781,16 +872,16 @@ var DialogDescription = React11.forwardRef(({ className, children, ...props }, r
|
|
|
781
872
|
DialogDescription.displayName = "DialogDescription";
|
|
782
873
|
|
|
783
874
|
// src/components/alert-dialog/AlertDialog.tsx
|
|
784
|
-
var
|
|
875
|
+
var React9 = __toESM(require("react"), 1);
|
|
785
876
|
var import_alert_dialog = require("@base-ui/react/alert-dialog");
|
|
786
877
|
var import_jsx_runtime12 = require("react/jsx-runtime");
|
|
787
878
|
var AlertDialog = import_alert_dialog.AlertDialog.Root;
|
|
788
|
-
var AlertDialogTrigger =
|
|
879
|
+
var AlertDialogTrigger = React9.forwardRef(
|
|
789
880
|
({ asChild, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_alert_dialog.AlertDialog.Trigger, { ref, render: asChildRender(asChild, children), ...props, children: asChild ? void 0 : children })
|
|
790
881
|
);
|
|
791
882
|
AlertDialogTrigger.displayName = "AlertDialogTrigger";
|
|
792
883
|
var AlertDialogPortal = import_alert_dialog.AlertDialog.Portal;
|
|
793
|
-
var AlertDialogOverlay =
|
|
884
|
+
var AlertDialogOverlay = React9.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
|
|
794
885
|
import_alert_dialog.AlertDialog.Backdrop,
|
|
795
886
|
{
|
|
796
887
|
ref,
|
|
@@ -802,7 +893,7 @@ var AlertDialogOverlay = React12.forwardRef(({ className, ...props }, ref) => /*
|
|
|
802
893
|
}
|
|
803
894
|
));
|
|
804
895
|
AlertDialogOverlay.displayName = "AlertDialogOverlay";
|
|
805
|
-
var AlertDialogContent =
|
|
896
|
+
var AlertDialogContent = React9.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(AlertDialogPortal, { children: [
|
|
806
897
|
/* @__PURE__ */ (0, import_jsx_runtime12.jsx)(AlertDialogOverlay, {}),
|
|
807
898
|
/* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
|
|
808
899
|
import_alert_dialog.AlertDialog.Popup,
|
|
@@ -827,7 +918,7 @@ var AlertDialogFooter = ({ className, ...props }) => /* @__PURE__ */ (0, import_
|
|
|
827
918
|
}
|
|
828
919
|
);
|
|
829
920
|
AlertDialogFooter.displayName = "AlertDialogFooter";
|
|
830
|
-
var AlertDialogTitle =
|
|
921
|
+
var AlertDialogTitle = React9.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
|
|
831
922
|
import_alert_dialog.AlertDialog.Title,
|
|
832
923
|
{
|
|
833
924
|
ref,
|
|
@@ -837,7 +928,7 @@ var AlertDialogTitle = React12.forwardRef(({ className, children, ...props }, re
|
|
|
837
928
|
}
|
|
838
929
|
));
|
|
839
930
|
AlertDialogTitle.displayName = "AlertDialogTitle";
|
|
840
|
-
var AlertDialogDescription =
|
|
931
|
+
var AlertDialogDescription = React9.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
|
|
841
932
|
import_alert_dialog.AlertDialog.Description,
|
|
842
933
|
{
|
|
843
934
|
ref,
|
|
@@ -847,7 +938,7 @@ var AlertDialogDescription = React12.forwardRef(({ className, children, ...props
|
|
|
847
938
|
}
|
|
848
939
|
));
|
|
849
940
|
AlertDialogDescription.displayName = "AlertDialogDescription";
|
|
850
|
-
var AlertDialogAction =
|
|
941
|
+
var AlertDialogAction = React9.forwardRef(({ className, asChild, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
|
|
851
942
|
import_alert_dialog.AlertDialog.Close,
|
|
852
943
|
{
|
|
853
944
|
ref,
|
|
@@ -858,7 +949,7 @@ var AlertDialogAction = React12.forwardRef(({ className, asChild, children, ...p
|
|
|
858
949
|
}
|
|
859
950
|
));
|
|
860
951
|
AlertDialogAction.displayName = "AlertDialogAction";
|
|
861
|
-
var AlertDialogCancel =
|
|
952
|
+
var AlertDialogCancel = React9.forwardRef(({ className, asChild, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
|
|
862
953
|
import_alert_dialog.AlertDialog.Close,
|
|
863
954
|
{
|
|
864
955
|
ref,
|
|
@@ -871,12 +962,12 @@ var AlertDialogCancel = React12.forwardRef(({ className, asChild, children, ...p
|
|
|
871
962
|
AlertDialogCancel.displayName = "AlertDialogCancel";
|
|
872
963
|
|
|
873
964
|
// src/components/dropdown-menu/DropdownMenu.tsx
|
|
874
|
-
var
|
|
965
|
+
var React10 = __toESM(require("react"), 1);
|
|
875
966
|
var import_menu = require("@base-ui/react/menu");
|
|
876
967
|
var import_lucide_react2 = require("lucide-react");
|
|
877
968
|
var import_jsx_runtime13 = require("react/jsx-runtime");
|
|
878
969
|
var DropdownMenu = import_menu.Menu.Root;
|
|
879
|
-
var DropdownMenuTrigger =
|
|
970
|
+
var DropdownMenuTrigger = React10.forwardRef(
|
|
880
971
|
({ asChild, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(import_menu.Menu.Trigger, { ref, render: asChildRender(asChild, children), ...props, children: asChild ? void 0 : children })
|
|
881
972
|
);
|
|
882
973
|
DropdownMenuTrigger.displayName = "DropdownMenuTrigger";
|
|
@@ -884,7 +975,7 @@ var DropdownMenuGroup = import_menu.Menu.Group;
|
|
|
884
975
|
var DropdownMenuPortal = import_menu.Menu.Portal;
|
|
885
976
|
var DropdownMenuSub = import_menu.Menu.SubmenuRoot;
|
|
886
977
|
var DropdownMenuRadioGroup = import_menu.Menu.RadioGroup;
|
|
887
|
-
var DropdownMenuSubTrigger =
|
|
978
|
+
var DropdownMenuSubTrigger = React10.forwardRef(({ className, inset, asChild, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
|
|
888
979
|
import_menu.Menu.SubmenuTrigger,
|
|
889
980
|
{
|
|
890
981
|
ref,
|
|
@@ -902,7 +993,7 @@ var DropdownMenuSubTrigger = React13.forwardRef(({ className, inset, asChild, ch
|
|
|
902
993
|
}
|
|
903
994
|
));
|
|
904
995
|
DropdownMenuSubTrigger.displayName = "DropdownMenuSubTrigger";
|
|
905
|
-
var DropdownMenuSubContent =
|
|
996
|
+
var DropdownMenuSubContent = React10.forwardRef(
|
|
906
997
|
({ className, side = "right", align = "start", alignOffset = -3, sideOffset = 0, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(import_menu.Menu.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
|
|
907
998
|
import_menu.Menu.Positioner,
|
|
908
999
|
{
|
|
@@ -926,7 +1017,7 @@ var DropdownMenuSubContent = React13.forwardRef(
|
|
|
926
1017
|
) })
|
|
927
1018
|
);
|
|
928
1019
|
DropdownMenuSubContent.displayName = "DropdownMenuSubContent";
|
|
929
|
-
var DropdownMenuContent =
|
|
1020
|
+
var DropdownMenuContent = React10.forwardRef(({ className, sideOffset = 4, align = "center", side, alignOffset, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(import_menu.Menu.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
|
|
930
1021
|
import_menu.Menu.Positioner,
|
|
931
1022
|
{
|
|
932
1023
|
side,
|
|
@@ -948,7 +1039,7 @@ var DropdownMenuContent = React13.forwardRef(({ className, sideOffset = 4, align
|
|
|
948
1039
|
}
|
|
949
1040
|
) }));
|
|
950
1041
|
DropdownMenuContent.displayName = "DropdownMenuContent";
|
|
951
|
-
var DropdownMenuItem =
|
|
1042
|
+
var DropdownMenuItem = React10.forwardRef(({ className, inset, asChild, children, textValue, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
|
|
952
1043
|
import_menu.Menu.Item,
|
|
953
1044
|
{
|
|
954
1045
|
ref,
|
|
@@ -964,7 +1055,7 @@ var DropdownMenuItem = React13.forwardRef(({ className, inset, asChild, children
|
|
|
964
1055
|
}
|
|
965
1056
|
));
|
|
966
1057
|
DropdownMenuItem.displayName = "DropdownMenuItem";
|
|
967
|
-
var DropdownMenuCheckboxItem =
|
|
1058
|
+
var DropdownMenuCheckboxItem = React10.forwardRef(({ className, children, asChild, textValue, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)(
|
|
968
1059
|
import_menu.Menu.CheckboxItem,
|
|
969
1060
|
{
|
|
970
1061
|
ref,
|
|
@@ -982,7 +1073,7 @@ var DropdownMenuCheckboxItem = React13.forwardRef(({ className, children, asChil
|
|
|
982
1073
|
}
|
|
983
1074
|
));
|
|
984
1075
|
DropdownMenuCheckboxItem.displayName = "DropdownMenuCheckboxItem";
|
|
985
|
-
var DropdownMenuRadioItem =
|
|
1076
|
+
var DropdownMenuRadioItem = React10.forwardRef(({ className, children, asChild, textValue, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)(
|
|
986
1077
|
import_menu.Menu.RadioItem,
|
|
987
1078
|
{
|
|
988
1079
|
ref,
|
|
@@ -1000,7 +1091,7 @@ var DropdownMenuRadioItem = React13.forwardRef(({ className, children, asChild,
|
|
|
1000
1091
|
}
|
|
1001
1092
|
));
|
|
1002
1093
|
DropdownMenuRadioItem.displayName = "DropdownMenuRadioItem";
|
|
1003
|
-
var DropdownMenuLabel =
|
|
1094
|
+
var DropdownMenuLabel = React10.forwardRef(({ className, inset, asChild, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
|
|
1004
1095
|
import_menu.Menu.GroupLabel,
|
|
1005
1096
|
{
|
|
1006
1097
|
ref,
|
|
@@ -1015,7 +1106,7 @@ var DropdownMenuLabel = React13.forwardRef(({ className, inset, asChild, childre
|
|
|
1015
1106
|
}
|
|
1016
1107
|
));
|
|
1017
1108
|
DropdownMenuLabel.displayName = "DropdownMenuLabel";
|
|
1018
|
-
var DropdownMenuSeparator =
|
|
1109
|
+
var DropdownMenuSeparator = React10.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
|
|
1019
1110
|
import_menu.Menu.Separator,
|
|
1020
1111
|
{
|
|
1021
1112
|
ref,
|
|
@@ -1036,180 +1127,288 @@ var DropdownMenuShortcut = ({ className, ...props }) => {
|
|
|
1036
1127
|
DropdownMenuShortcut.displayName = "DropdownMenuShortcut";
|
|
1037
1128
|
|
|
1038
1129
|
// src/components/navigation-menu/NavigationMenu.tsx
|
|
1039
|
-
var
|
|
1130
|
+
var import_navigation_menu2 = require("@base-ui/react/navigation-menu");
|
|
1131
|
+
var import_class_variance_authority8 = require("class-variance-authority");
|
|
1132
|
+
var import_lucide_react4 = require("lucide-react");
|
|
1133
|
+
|
|
1134
|
+
// src/primitives/navigation-menu.tsx
|
|
1040
1135
|
var import_navigation_menu = require("@base-ui/react/navigation-menu");
|
|
1041
1136
|
var import_class_variance_authority7 = require("class-variance-authority");
|
|
1137
|
+
var import_cn4 = require("cn");
|
|
1042
1138
|
var import_lucide_react3 = require("lucide-react");
|
|
1043
1139
|
var import_jsx_runtime14 = require("react/jsx-runtime");
|
|
1044
|
-
|
|
1045
|
-
|
|
1046
|
-
|
|
1047
|
-
|
|
1048
|
-
|
|
1049
|
-
|
|
1050
|
-
|
|
1051
|
-
|
|
1052
|
-
|
|
1053
|
-
|
|
1054
|
-
|
|
1055
|
-
)
|
|
1056
|
-
|
|
1057
|
-
|
|
1058
|
-
|
|
1059
|
-
|
|
1060
|
-
|
|
1061
|
-
|
|
1062
|
-
|
|
1063
|
-
|
|
1064
|
-
)
|
|
1065
|
-
|
|
1066
|
-
|
|
1140
|
+
function NavigationMenuList({
|
|
1141
|
+
className,
|
|
1142
|
+
...props
|
|
1143
|
+
}) {
|
|
1144
|
+
return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
|
|
1145
|
+
import_navigation_menu.NavigationMenu.List,
|
|
1146
|
+
{
|
|
1147
|
+
"data-slot": "navigation-menu-list",
|
|
1148
|
+
className: (0, import_cn4.cn)(
|
|
1149
|
+
"group flex flex-1 list-none items-center justify-center gap-0",
|
|
1150
|
+
className
|
|
1151
|
+
),
|
|
1152
|
+
...props
|
|
1153
|
+
}
|
|
1154
|
+
);
|
|
1155
|
+
}
|
|
1156
|
+
function NavigationMenuItem({
|
|
1157
|
+
className,
|
|
1158
|
+
...props
|
|
1159
|
+
}) {
|
|
1160
|
+
return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
|
|
1161
|
+
import_navigation_menu.NavigationMenu.Item,
|
|
1162
|
+
{
|
|
1163
|
+
"data-slot": "navigation-menu-item",
|
|
1164
|
+
className: (0, import_cn4.cn)("relative", className),
|
|
1165
|
+
...props
|
|
1166
|
+
}
|
|
1167
|
+
);
|
|
1168
|
+
}
|
|
1067
1169
|
var navigationMenuTriggerStyle = (0, import_class_variance_authority7.cva)(
|
|
1068
|
-
"group inline-flex h-
|
|
1170
|
+
"group/navigation-menu-trigger inline-flex h-9 w-max items-center justify-center rounded-lg px-2.5 py-1.5 text-sm font-medium transition-all outline-none hover:bg-muted focus:bg-muted focus-visible:ring-3 focus-visible:ring-ring/50 focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 data-popup-open:bg-muted/50 data-popup-open:hover:bg-muted data-open:bg-muted/50 data-open:hover:bg-muted data-open:focus:bg-muted"
|
|
1069
1171
|
);
|
|
1070
|
-
|
|
1071
|
-
|
|
1072
|
-
|
|
1073
|
-
|
|
1074
|
-
|
|
1075
|
-
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
|
|
1079
|
-
|
|
1080
|
-
|
|
1081
|
-
|
|
1082
|
-
|
|
1083
|
-
|
|
1084
|
-
|
|
1085
|
-
|
|
1086
|
-
|
|
1087
|
-
|
|
1088
|
-
|
|
1089
|
-
)
|
|
1090
|
-
|
|
1091
|
-
|
|
1092
|
-
|
|
1093
|
-
|
|
1094
|
-
|
|
1095
|
-
|
|
1096
|
-
|
|
1097
|
-
|
|
1098
|
-
|
|
1099
|
-
|
|
1100
|
-
|
|
1101
|
-
)
|
|
1102
|
-
|
|
1103
|
-
var NavigationMenuLink = React14.forwardRef(({ className, asChild, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
|
|
1104
|
-
import_navigation_menu.NavigationMenu.Link,
|
|
1105
|
-
{
|
|
1106
|
-
ref,
|
|
1107
|
-
className,
|
|
1108
|
-
render: asChildRender(asChild, children),
|
|
1109
|
-
...props,
|
|
1110
|
-
children: asChild ? void 0 : children
|
|
1111
|
-
}
|
|
1112
|
-
));
|
|
1113
|
-
NavigationMenuLink.displayName = "NavigationMenuLink";
|
|
1114
|
-
var NavigationMenuViewport = React14.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(import_navigation_menu.NavigationMenu.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(import_navigation_menu.NavigationMenu.Positioner, { className: "isolate z-50 outline-none", children: /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
|
|
1115
|
-
import_navigation_menu.NavigationMenu.Popup,
|
|
1116
|
-
{
|
|
1117
|
-
ref,
|
|
1118
|
-
className: cn(
|
|
1119
|
-
"origin-top-center relative mt-1.5 h-[var(--popup-height)] w-full overflow-hidden rounded-berget-xs border border-berget-border bg-berget-popover text-berget-popover-foreground shadow-berget-lg transition-[opacity,transform] data-starting-style:opacity-0 data-starting-style:scale-90 data-ending-style:opacity-0 data-ending-style:scale-90 md:w-[var(--popup-width)]",
|
|
1120
|
-
className
|
|
1121
|
-
),
|
|
1122
|
-
...props,
|
|
1123
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(import_navigation_menu.NavigationMenu.Viewport, {})
|
|
1124
|
-
}
|
|
1125
|
-
) }) }));
|
|
1126
|
-
NavigationMenuViewport.displayName = "NavigationMenuViewport";
|
|
1127
|
-
var NavigationMenuIndicator = React14.forwardRef(({ className, asChild, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)(
|
|
1128
|
-
import_navigation_menu.NavigationMenu.Icon,
|
|
1129
|
-
{
|
|
1130
|
-
ref,
|
|
1131
|
-
className: cn(
|
|
1132
|
-
"top-full z-[1] flex h-1.5 items-end justify-center overflow-hidden transition-[opacity] data-starting-style:opacity-0 data-ending-style:opacity-0",
|
|
1133
|
-
className
|
|
1134
|
-
),
|
|
1135
|
-
render: asChildRender(asChild, children),
|
|
1136
|
-
...props,
|
|
1137
|
-
children: [
|
|
1138
|
-
asChild ? void 0 : children,
|
|
1139
|
-
/* @__PURE__ */ (0, import_jsx_runtime14.jsx)("div", { className: "relative top-[60%] size-2 rotate-45 rounded-tl-sm bg-berget-border shadow-md" })
|
|
1140
|
-
]
|
|
1141
|
-
}
|
|
1142
|
-
));
|
|
1143
|
-
NavigationMenuIndicator.displayName = "NavigationMenuIndicator";
|
|
1144
|
-
|
|
1145
|
-
// src/components/table/Table.tsx
|
|
1146
|
-
var React16 = __toESM(require("react"), 1);
|
|
1172
|
+
function NavigationMenuContent({
|
|
1173
|
+
className,
|
|
1174
|
+
...props
|
|
1175
|
+
}) {
|
|
1176
|
+
return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
|
|
1177
|
+
import_navigation_menu.NavigationMenu.Content,
|
|
1178
|
+
{
|
|
1179
|
+
"data-slot": "navigation-menu-content",
|
|
1180
|
+
className: (0, import_cn4.cn)(
|
|
1181
|
+
"data-ending-style:data-activation-direction=left:translate-x-[50%] data-ending-style:data-activation-direction=right:translate-x-[-50%] data-starting-style:data-activation-direction=left:translate-x-[-50%] data-starting-style:data-activation-direction=right:translate-x-[50%] h-full w-auto p-1 transition-[opacity,transform,translate] duration-[0.35s] ease-[cubic-bezier(0.22,1,0.36,1)] group-data-[viewport=false]/navigation-menu:rounded-lg group-data-[viewport=false]/navigation-menu:bg-popover group-data-[viewport=false]/navigation-menu:text-popover-foreground group-data-[viewport=false]/navigation-menu:shadow group-data-[viewport=false]/navigation-menu:ring-1 group-data-[viewport=false]/navigation-menu:ring-foreground/10 group-data-[viewport=false]/navigation-menu:duration-300 data-ending-style:opacity-0 data-starting-style:opacity-0 data-[motion=from-end]:slide-in-from-right-52 data-[motion=from-start]:slide-in-from-left-52 data-[motion=to-end]:slide-out-to-right-52 data-[motion=to-start]:slide-out-to-left-52 data-[motion^=from-]:animate-in data-[motion^=from-]:fade-in data-[motion^=to-]:animate-out data-[motion^=to-]:fade-out **:data-[slot=navigation-menu-link]:focus:ring-0 **:data-[slot=navigation-menu-link]:focus:outline-none group-data-[viewport=false]/navigation-menu:data-open:animate-in group-data-[viewport=false]/navigation-menu:data-open:fade-in-0 group-data-[viewport=false]/navigation-menu:data-open:zoom-in-95 group-data-[viewport=false]/navigation-menu:data-closed:animate-out group-data-[viewport=false]/navigation-menu:data-closed:fade-out-0 group-data-[viewport=false]/navigation-menu:data-closed:zoom-out-95",
|
|
1182
|
+
className
|
|
1183
|
+
),
|
|
1184
|
+
...props
|
|
1185
|
+
}
|
|
1186
|
+
);
|
|
1187
|
+
}
|
|
1188
|
+
function NavigationMenuIndicator({
|
|
1189
|
+
className,
|
|
1190
|
+
...props
|
|
1191
|
+
}) {
|
|
1192
|
+
return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
|
|
1193
|
+
import_navigation_menu.NavigationMenu.Icon,
|
|
1194
|
+
{
|
|
1195
|
+
"data-slot": "navigation-menu-indicator",
|
|
1196
|
+
className: (0, import_cn4.cn)(
|
|
1197
|
+
"top-full z-1 flex h-1.5 items-end justify-center overflow-hidden data-[state=hidden]:animate-out data-[state=hidden]:fade-out data-[state=visible]:animate-in data-[state=visible]:fade-in",
|
|
1198
|
+
className
|
|
1199
|
+
),
|
|
1200
|
+
...props,
|
|
1201
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("div", { className: "relative top-[60%] h-2 w-2 rotate-45 rounded-tl-sm bg-border shadow-md" })
|
|
1202
|
+
}
|
|
1203
|
+
);
|
|
1204
|
+
}
|
|
1147
1205
|
|
|
1148
|
-
// src/
|
|
1149
|
-
var React15 = __toESM(require("react"), 1);
|
|
1206
|
+
// src/components/navigation-menu/NavigationMenu.tsx
|
|
1150
1207
|
var import_jsx_runtime15 = require("react/jsx-runtime");
|
|
1151
|
-
|
|
1152
|
-
|
|
1153
|
-
|
|
1154
|
-
|
|
1155
|
-
|
|
1156
|
-
|
|
1157
|
-
|
|
1158
|
-
|
|
1159
|
-
var TableFooter = React15.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
|
|
1160
|
-
"tfoot",
|
|
1161
|
-
{
|
|
1162
|
-
ref,
|
|
1163
|
-
className: cn("border-t bg-muted/50 font-medium [&>tr]:last:border-b-0", className),
|
|
1164
|
-
...props
|
|
1165
|
-
}
|
|
1166
|
-
));
|
|
1167
|
-
TableFooter.displayName = "TableFooter";
|
|
1168
|
-
var TableRow = React15.forwardRef(
|
|
1169
|
-
({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
|
|
1170
|
-
"tr",
|
|
1208
|
+
function NavigationMenu({
|
|
1209
|
+
align = "start",
|
|
1210
|
+
className,
|
|
1211
|
+
children,
|
|
1212
|
+
...props
|
|
1213
|
+
}) {
|
|
1214
|
+
return /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)(
|
|
1215
|
+
import_navigation_menu2.NavigationMenu.Root,
|
|
1171
1216
|
{
|
|
1172
|
-
|
|
1217
|
+
"data-slot": "navigation-menu",
|
|
1173
1218
|
className: cn(
|
|
1174
|
-
"
|
|
1219
|
+
"group/navigation-menu relative flex max-w-max flex-1 items-center justify-center",
|
|
1175
1220
|
className
|
|
1176
1221
|
),
|
|
1177
|
-
...props
|
|
1222
|
+
...props,
|
|
1223
|
+
children: [
|
|
1224
|
+
children,
|
|
1225
|
+
/* @__PURE__ */ (0, import_jsx_runtime15.jsx)(NavigationMenuPositioner, { align })
|
|
1226
|
+
]
|
|
1178
1227
|
}
|
|
1179
|
-
)
|
|
1228
|
+
);
|
|
1229
|
+
}
|
|
1230
|
+
var navigationMenuTriggerStyle2 = (0, import_class_variance_authority8.cva)(
|
|
1231
|
+
"group/navigation-menu-trigger inline-flex h-9 w-max items-center justify-center rounded-berget-xs px-2.5 py-1.5 text-sm font-medium transition-all outline-none hover:bg-berget-surface-02 focus:bg-berget-surface-02 focus-visible:ring-3 focus-visible:ring-berget-ring/50 focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 data-popup-open:bg-berget-surface-02/50 data-popup-open:hover:bg-berget-surface-02 data-open:bg-berget-surface-02/50 data-open:hover:bg-berget-surface-02 data-open:focus:bg-berget-surface-02"
|
|
1180
1232
|
);
|
|
1181
|
-
|
|
1182
|
-
|
|
1183
|
-
|
|
1184
|
-
|
|
1185
|
-
|
|
1186
|
-
|
|
1187
|
-
|
|
1188
|
-
|
|
1189
|
-
|
|
1190
|
-
|
|
1191
|
-
|
|
1192
|
-
|
|
1193
|
-
|
|
1194
|
-
|
|
1195
|
-
|
|
1196
|
-
|
|
1197
|
-
|
|
1198
|
-
|
|
1199
|
-
|
|
1200
|
-
|
|
1201
|
-
)
|
|
1202
|
-
|
|
1203
|
-
|
|
1204
|
-
|
|
1233
|
+
function NavigationMenuTrigger({
|
|
1234
|
+
className,
|
|
1235
|
+
children,
|
|
1236
|
+
...props
|
|
1237
|
+
}) {
|
|
1238
|
+
return /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)(
|
|
1239
|
+
import_navigation_menu2.NavigationMenu.Trigger,
|
|
1240
|
+
{
|
|
1241
|
+
"data-slot": "navigation-menu-trigger",
|
|
1242
|
+
className: cn(navigationMenuTriggerStyle2(), "group", className),
|
|
1243
|
+
...props,
|
|
1244
|
+
children: [
|
|
1245
|
+
children,
|
|
1246
|
+
" ",
|
|
1247
|
+
/* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
|
|
1248
|
+
import_lucide_react4.ChevronDown,
|
|
1249
|
+
{
|
|
1250
|
+
className: "relative top-px ml-1 size-3 transition duration-300 group-data-popup-open/navigation-menu-trigger:rotate-180 group-data-open/navigation-menu-trigger:rotate-180",
|
|
1251
|
+
"aria-hidden": "true"
|
|
1252
|
+
}
|
|
1253
|
+
)
|
|
1254
|
+
]
|
|
1255
|
+
}
|
|
1256
|
+
);
|
|
1257
|
+
}
|
|
1258
|
+
function NavigationMenuLink({ className, ...props }) {
|
|
1259
|
+
return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
|
|
1260
|
+
import_navigation_menu2.NavigationMenu.Link,
|
|
1261
|
+
{
|
|
1262
|
+
"data-slot": "navigation-menu-link",
|
|
1263
|
+
className: cn(
|
|
1264
|
+
"flex items-center gap-2 rounded-berget-xs p-2 text-sm transition-all outline-none hover:bg-berget-surface-02 focus:bg-berget-surface-02 focus-visible:ring-3 focus-visible:ring-berget-ring/50 focus-visible:outline-1 in-data-[slot=navigation-menu-content]:rounded-berget-xs data-active:bg-berget-surface-02/50 data-active:hover:bg-berget-surface-02 data-active:focus:bg-berget-surface-02 [&_svg:not([class*='size-'])]:size-4",
|
|
1265
|
+
className
|
|
1266
|
+
),
|
|
1267
|
+
...props
|
|
1268
|
+
}
|
|
1269
|
+
);
|
|
1270
|
+
}
|
|
1271
|
+
function NavigationMenuPositioner({
|
|
1272
|
+
className,
|
|
1273
|
+
side = "bottom",
|
|
1274
|
+
sideOffset = 8,
|
|
1275
|
+
align = "start",
|
|
1276
|
+
alignOffset = 0,
|
|
1277
|
+
...props
|
|
1278
|
+
}) {
|
|
1279
|
+
return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(import_navigation_menu2.NavigationMenu.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
|
|
1280
|
+
import_navigation_menu2.NavigationMenu.Positioner,
|
|
1281
|
+
{
|
|
1282
|
+
side,
|
|
1283
|
+
sideOffset,
|
|
1284
|
+
align,
|
|
1285
|
+
alignOffset,
|
|
1286
|
+
className: cn(
|
|
1287
|
+
"isolate z-50 h-(--positioner-height) w-(--positioner-width) max-w-(--available-width) transition-[top,left,right,bottom] duration-[0.35s] ease-[cubic-bezier(0.22,1,0.36,1)] data-instant:transition-none data-[side=bottom]:before:top-[-10px] data-[side=bottom]:before:right-0 data-[side=bottom]:before:left-0",
|
|
1288
|
+
className
|
|
1289
|
+
),
|
|
1290
|
+
...props,
|
|
1291
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(import_navigation_menu2.NavigationMenu.Popup, { className: "data-[ending-style]:easing-[ease] xs:w-(--popup-width) relative h-(--popup-height) w-(--popup-width) origin-(--transform-origin) rounded-berget-xs bg-berget-popover text-berget-popover-foreground shadow-berget-lg ring-1 ring-berget-border transition-[opacity,transform,width,height,scale,translate] duration-[0.35s] ease-[cubic-bezier(0.22,1,0.36,1)] outline-none data-ending-style:scale-90 data-ending-style:opacity-0 data-ending-style:duration-150 data-starting-style:scale-90 data-starting-style:opacity-0", children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(import_navigation_menu2.NavigationMenu.Viewport, { className: "relative size-full overflow-hidden" }) })
|
|
1292
|
+
}
|
|
1293
|
+
) });
|
|
1294
|
+
}
|
|
1205
1295
|
|
|
1206
1296
|
// src/components/table/Table.tsx
|
|
1297
|
+
var React11 = __toESM(require("react"), 1);
|
|
1298
|
+
|
|
1299
|
+
// src/primitives/table.tsx
|
|
1300
|
+
var import_cn5 = require("cn");
|
|
1207
1301
|
var import_jsx_runtime16 = require("react/jsx-runtime");
|
|
1208
|
-
|
|
1209
|
-
|
|
1302
|
+
function Table({ className, ...props }) {
|
|
1303
|
+
return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
|
|
1304
|
+
"div",
|
|
1305
|
+
{
|
|
1306
|
+
"data-slot": "table-container",
|
|
1307
|
+
className: "relative w-full overflow-x-auto",
|
|
1308
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
|
|
1309
|
+
"table",
|
|
1310
|
+
{
|
|
1311
|
+
"data-slot": "table",
|
|
1312
|
+
className: (0, import_cn5.cn)("w-full caption-bottom text-sm", className),
|
|
1313
|
+
...props
|
|
1314
|
+
}
|
|
1315
|
+
)
|
|
1316
|
+
}
|
|
1317
|
+
);
|
|
1318
|
+
}
|
|
1319
|
+
function TableHeader({ className, ...props }) {
|
|
1320
|
+
return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
|
|
1321
|
+
"thead",
|
|
1322
|
+
{
|
|
1323
|
+
"data-slot": "table-header",
|
|
1324
|
+
className: (0, import_cn5.cn)("[&_tr]:border-b", className),
|
|
1325
|
+
...props
|
|
1326
|
+
}
|
|
1327
|
+
);
|
|
1328
|
+
}
|
|
1329
|
+
function TableBody({ className, ...props }) {
|
|
1330
|
+
return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
|
|
1331
|
+
"tbody",
|
|
1332
|
+
{
|
|
1333
|
+
"data-slot": "table-body",
|
|
1334
|
+
className: (0, import_cn5.cn)("[&_tr:last-child]:border-0", className),
|
|
1335
|
+
...props
|
|
1336
|
+
}
|
|
1337
|
+
);
|
|
1338
|
+
}
|
|
1339
|
+
function TableFooter({ className, ...props }) {
|
|
1340
|
+
return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
|
|
1341
|
+
"tfoot",
|
|
1342
|
+
{
|
|
1343
|
+
"data-slot": "table-footer",
|
|
1344
|
+
className: (0, import_cn5.cn)(
|
|
1345
|
+
"border-t bg-muted/50 font-medium [&>tr]:last:border-b-0",
|
|
1346
|
+
className
|
|
1347
|
+
),
|
|
1348
|
+
...props
|
|
1349
|
+
}
|
|
1350
|
+
);
|
|
1351
|
+
}
|
|
1352
|
+
function TableRow({ className, ...props }) {
|
|
1353
|
+
return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
|
|
1354
|
+
"tr",
|
|
1355
|
+
{
|
|
1356
|
+
"data-slot": "table-row",
|
|
1357
|
+
className: (0, import_cn5.cn)(
|
|
1358
|
+
"border-b transition-colors hover:bg-muted/50 has-aria-expanded:bg-muted/50 data-[state=selected]:bg-muted",
|
|
1359
|
+
className
|
|
1360
|
+
),
|
|
1361
|
+
...props
|
|
1362
|
+
}
|
|
1363
|
+
);
|
|
1364
|
+
}
|
|
1365
|
+
function TableHead({ className, ...props }) {
|
|
1366
|
+
return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
|
|
1367
|
+
"th",
|
|
1368
|
+
{
|
|
1369
|
+
"data-slot": "table-head",
|
|
1370
|
+
className: (0, import_cn5.cn)(
|
|
1371
|
+
"h-10 px-2 text-left align-middle font-medium whitespace-nowrap text-foreground [&:has([role=checkbox])]:pr-0",
|
|
1372
|
+
className
|
|
1373
|
+
),
|
|
1374
|
+
...props
|
|
1375
|
+
}
|
|
1376
|
+
);
|
|
1377
|
+
}
|
|
1378
|
+
function TableCell({ className, ...props }) {
|
|
1379
|
+
return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
|
|
1380
|
+
"td",
|
|
1381
|
+
{
|
|
1382
|
+
"data-slot": "table-cell",
|
|
1383
|
+
className: (0, import_cn5.cn)(
|
|
1384
|
+
"p-2 align-middle whitespace-nowrap [&:has([role=checkbox])]:pr-0",
|
|
1385
|
+
className
|
|
1386
|
+
),
|
|
1387
|
+
...props
|
|
1388
|
+
}
|
|
1389
|
+
);
|
|
1390
|
+
}
|
|
1391
|
+
function TableCaption({
|
|
1392
|
+
className,
|
|
1393
|
+
...props
|
|
1394
|
+
}) {
|
|
1395
|
+
return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
|
|
1396
|
+
"caption",
|
|
1397
|
+
{
|
|
1398
|
+
"data-slot": "table-caption",
|
|
1399
|
+
className: (0, import_cn5.cn)("mt-4 text-sm text-muted-foreground", className),
|
|
1400
|
+
...props
|
|
1401
|
+
}
|
|
1402
|
+
);
|
|
1403
|
+
}
|
|
1404
|
+
|
|
1405
|
+
// src/components/table/Table.tsx
|
|
1406
|
+
var import_jsx_runtime17 = require("react/jsx-runtime");
|
|
1407
|
+
var Table2 = React11.forwardRef(
|
|
1408
|
+
({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(Table, { ref, className, ...props })
|
|
1210
1409
|
);
|
|
1211
1410
|
Table2.displayName = "Table";
|
|
1212
|
-
var TableHeader2 =
|
|
1411
|
+
var TableHeader2 = React11.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
|
|
1213
1412
|
TableHeader,
|
|
1214
1413
|
{
|
|
1215
1414
|
ref,
|
|
@@ -1218,7 +1417,7 @@ var TableHeader2 = React16.forwardRef(({ className, ...props }, ref) => /* @__PU
|
|
|
1218
1417
|
}
|
|
1219
1418
|
));
|
|
1220
1419
|
TableHeader2.displayName = "TableHeader";
|
|
1221
|
-
var TableBody2 =
|
|
1420
|
+
var TableBody2 = React11.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
|
|
1222
1421
|
TableBody,
|
|
1223
1422
|
{
|
|
1224
1423
|
ref,
|
|
@@ -1227,7 +1426,7 @@ var TableBody2 = React16.forwardRef(({ className, ...props }, ref) => /* @__PURE
|
|
|
1227
1426
|
}
|
|
1228
1427
|
));
|
|
1229
1428
|
TableBody2.displayName = "TableBody";
|
|
1230
|
-
var TableFooter2 =
|
|
1429
|
+
var TableFooter2 = React11.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
|
|
1231
1430
|
TableFooter,
|
|
1232
1431
|
{
|
|
1233
1432
|
ref,
|
|
@@ -1239,8 +1438,8 @@ var TableFooter2 = React16.forwardRef(({ className, ...props }, ref) => /* @__PU
|
|
|
1239
1438
|
}
|
|
1240
1439
|
));
|
|
1241
1440
|
TableFooter2.displayName = "TableFooter";
|
|
1242
|
-
var TableRow2 =
|
|
1243
|
-
({ className, ...props }, ref) => /* @__PURE__ */ (0,
|
|
1441
|
+
var TableRow2 = React11.forwardRef(
|
|
1442
|
+
({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
|
|
1244
1443
|
TableRow,
|
|
1245
1444
|
{
|
|
1246
1445
|
ref,
|
|
@@ -1253,7 +1452,7 @@ var TableRow2 = React16.forwardRef(
|
|
|
1253
1452
|
)
|
|
1254
1453
|
);
|
|
1255
1454
|
TableRow2.displayName = "TableRow";
|
|
1256
|
-
var TableHead2 =
|
|
1455
|
+
var TableHead2 = React11.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
|
|
1257
1456
|
TableHead,
|
|
1258
1457
|
{
|
|
1259
1458
|
ref,
|
|
@@ -1265,7 +1464,7 @@ var TableHead2 = React16.forwardRef(({ className, ...props }, ref) => /* @__PURE
|
|
|
1265
1464
|
}
|
|
1266
1465
|
));
|
|
1267
1466
|
TableHead2.displayName = "TableHead";
|
|
1268
|
-
var TableCell2 =
|
|
1467
|
+
var TableCell2 = React11.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
|
|
1269
1468
|
TableCell,
|
|
1270
1469
|
{
|
|
1271
1470
|
ref,
|
|
@@ -1274,7 +1473,7 @@ var TableCell2 = React16.forwardRef(({ className, ...props }, ref) => /* @__PURE
|
|
|
1274
1473
|
}
|
|
1275
1474
|
));
|
|
1276
1475
|
TableCell2.displayName = "TableCell";
|
|
1277
|
-
var TableCaption2 =
|
|
1476
|
+
var TableCaption2 = React11.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
|
|
1278
1477
|
TableCaption,
|
|
1279
1478
|
{
|
|
1280
1479
|
ref,
|
|
@@ -1285,68 +1484,80 @@ var TableCaption2 = React16.forwardRef(({ className, ...props }, ref) => /* @__P
|
|
|
1285
1484
|
TableCaption2.displayName = "TableCaption";
|
|
1286
1485
|
|
|
1287
1486
|
// src/components/item/Item.tsx
|
|
1288
|
-
var
|
|
1487
|
+
var React12 = __toESM(require("react"), 1);
|
|
1289
1488
|
|
|
1290
1489
|
// src/primitives/item.tsx
|
|
1291
|
-
var import_class_variance_authority8 = require("class-variance-authority");
|
|
1292
1490
|
var import_merge_props = require("@base-ui/react/merge-props");
|
|
1293
1491
|
var import_use_render = require("@base-ui/react/use-render");
|
|
1492
|
+
var import_class_variance_authority9 = require("class-variance-authority");
|
|
1493
|
+
var import_cn7 = require("cn");
|
|
1294
1494
|
|
|
1295
1495
|
// src/primitives/separator.tsx
|
|
1296
|
-
var React17 = __toESM(require("react"), 1);
|
|
1297
1496
|
var import_separator = require("@base-ui/react/separator");
|
|
1298
|
-
var
|
|
1299
|
-
var
|
|
1300
|
-
|
|
1301
|
-
|
|
1302
|
-
|
|
1303
|
-
|
|
1304
|
-
|
|
1305
|
-
|
|
1306
|
-
|
|
1307
|
-
|
|
1308
|
-
|
|
1309
|
-
|
|
1310
|
-
|
|
1311
|
-
|
|
1312
|
-
|
|
1497
|
+
var import_cn6 = require("cn");
|
|
1498
|
+
var import_jsx_runtime18 = require("react/jsx-runtime");
|
|
1499
|
+
function Separator({
|
|
1500
|
+
className,
|
|
1501
|
+
orientation = "horizontal",
|
|
1502
|
+
...props
|
|
1503
|
+
}) {
|
|
1504
|
+
return /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
|
|
1505
|
+
import_separator.Separator,
|
|
1506
|
+
{
|
|
1507
|
+
"data-slot": "separator",
|
|
1508
|
+
orientation,
|
|
1509
|
+
className: (0, import_cn6.cn)(
|
|
1510
|
+
"shrink-0 bg-border data-horizontal:h-px data-horizontal:w-full data-vertical:w-px data-vertical:self-stretch",
|
|
1511
|
+
className
|
|
1512
|
+
),
|
|
1513
|
+
...props
|
|
1514
|
+
}
|
|
1515
|
+
);
|
|
1516
|
+
}
|
|
1313
1517
|
|
|
1314
1518
|
// src/primitives/item.tsx
|
|
1315
|
-
var
|
|
1519
|
+
var import_jsx_runtime19 = require("react/jsx-runtime");
|
|
1316
1520
|
function ItemGroup({ className, ...props }) {
|
|
1317
|
-
return /* @__PURE__ */ (0,
|
|
1521
|
+
return /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(
|
|
1318
1522
|
"div",
|
|
1319
1523
|
{
|
|
1320
1524
|
role: "list",
|
|
1321
1525
|
"data-slot": "item-group",
|
|
1322
|
-
className:
|
|
1526
|
+
className: (0, import_cn7.cn)(
|
|
1527
|
+
"group/item-group flex w-full flex-col gap-4 has-data-[size=sm]:gap-2.5 has-data-[size=xs]:gap-2",
|
|
1528
|
+
className
|
|
1529
|
+
),
|
|
1323
1530
|
...props
|
|
1324
1531
|
}
|
|
1325
1532
|
);
|
|
1326
1533
|
}
|
|
1327
|
-
function ItemSeparator({
|
|
1328
|
-
|
|
1534
|
+
function ItemSeparator({
|
|
1535
|
+
className,
|
|
1536
|
+
...props
|
|
1537
|
+
}) {
|
|
1538
|
+
return /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(
|
|
1329
1539
|
Separator,
|
|
1330
1540
|
{
|
|
1331
1541
|
"data-slot": "item-separator",
|
|
1332
1542
|
orientation: "horizontal",
|
|
1333
|
-
className: cn("my-
|
|
1543
|
+
className: (0, import_cn7.cn)("my-2", className),
|
|
1334
1544
|
...props
|
|
1335
1545
|
}
|
|
1336
1546
|
);
|
|
1337
1547
|
}
|
|
1338
|
-
var itemVariants = (0,
|
|
1339
|
-
"group/item
|
|
1548
|
+
var itemVariants = (0, import_class_variance_authority9.cva)(
|
|
1549
|
+
"group/item flex w-full flex-wrap items-center rounded-lg border text-sm transition-colors duration-100 outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 [a]:transition-colors [a]:hover:bg-muted",
|
|
1340
1550
|
{
|
|
1341
1551
|
variants: {
|
|
1342
1552
|
variant: {
|
|
1343
|
-
default: "
|
|
1553
|
+
default: "border-transparent",
|
|
1344
1554
|
outline: "border-border",
|
|
1345
|
-
muted: "bg-muted/50"
|
|
1555
|
+
muted: "border-transparent bg-muted/50"
|
|
1346
1556
|
},
|
|
1347
1557
|
size: {
|
|
1348
|
-
default: "gap-
|
|
1349
|
-
sm: "gap-2.5 px-
|
|
1558
|
+
default: "gap-2.5 px-3 py-2.5",
|
|
1559
|
+
sm: "gap-2.5 px-3 py-2.5",
|
|
1560
|
+
xs: "gap-2 px-2.5 py-2 in-data-[slot=dropdown-menu-content]:p-0"
|
|
1350
1561
|
}
|
|
1351
1562
|
},
|
|
1352
1563
|
defaultVariants: {
|
|
@@ -1364,26 +1575,28 @@ function Item({
|
|
|
1364
1575
|
}) {
|
|
1365
1576
|
return (0, import_use_render.useRender)({
|
|
1366
1577
|
defaultTagName: "div",
|
|
1367
|
-
render,
|
|
1368
1578
|
props: (0, import_merge_props.mergeProps)(
|
|
1369
1579
|
{
|
|
1370
|
-
|
|
1371
|
-
"data-variant": variant,
|
|
1372
|
-
"data-size": size,
|
|
1373
|
-
className: cn(itemVariants({ variant, size, className }))
|
|
1580
|
+
className: (0, import_cn7.cn)(itemVariants({ variant, size, className }))
|
|
1374
1581
|
},
|
|
1375
1582
|
props
|
|
1376
|
-
)
|
|
1583
|
+
),
|
|
1584
|
+
render,
|
|
1585
|
+
state: {
|
|
1586
|
+
slot: "item",
|
|
1587
|
+
variant,
|
|
1588
|
+
size
|
|
1589
|
+
}
|
|
1377
1590
|
});
|
|
1378
1591
|
}
|
|
1379
|
-
var itemMediaVariants = (0,
|
|
1380
|
-
"flex shrink-0 items-center justify-center gap-2 group-has-
|
|
1592
|
+
var itemMediaVariants = (0, import_class_variance_authority9.cva)(
|
|
1593
|
+
"flex shrink-0 items-center justify-center gap-2 group-has-data-[slot=item-description]/item:translate-y-0.5 group-has-data-[slot=item-description]/item:self-start [&_svg]:pointer-events-none",
|
|
1381
1594
|
{
|
|
1382
1595
|
variants: {
|
|
1383
1596
|
variant: {
|
|
1384
1597
|
default: "bg-transparent",
|
|
1385
|
-
icon: "
|
|
1386
|
-
image: "size-10 overflow-hidden rounded-sm [&_img]:size-full [&_img]:object-cover"
|
|
1598
|
+
icon: "[&_svg:not([class*='size-'])]:size-4",
|
|
1599
|
+
image: "size-10 overflow-hidden rounded-sm group-data-[size=sm]/item:size-8 group-data-[size=xs]/item:size-6 [&_img]:size-full [&_img]:object-cover"
|
|
1387
1600
|
}
|
|
1388
1601
|
},
|
|
1389
1602
|
defaultVariants: {
|
|
@@ -1396,44 +1609,49 @@ function ItemMedia({
|
|
|
1396
1609
|
variant = "default",
|
|
1397
1610
|
...props
|
|
1398
1611
|
}) {
|
|
1399
|
-
return /* @__PURE__ */ (0,
|
|
1612
|
+
return /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(
|
|
1400
1613
|
"div",
|
|
1401
1614
|
{
|
|
1402
1615
|
"data-slot": "item-media",
|
|
1403
1616
|
"data-variant": variant,
|
|
1404
|
-
className: cn(itemMediaVariants({ variant, className })),
|
|
1617
|
+
className: (0, import_cn7.cn)(itemMediaVariants({ variant, className })),
|
|
1405
1618
|
...props
|
|
1406
1619
|
}
|
|
1407
1620
|
);
|
|
1408
1621
|
}
|
|
1409
1622
|
function ItemContent({ className, ...props }) {
|
|
1410
|
-
return /* @__PURE__ */ (0,
|
|
1623
|
+
return /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(
|
|
1411
1624
|
"div",
|
|
1412
1625
|
{
|
|
1413
1626
|
"data-slot": "item-content",
|
|
1414
|
-
className:
|
|
1627
|
+
className: (0, import_cn7.cn)(
|
|
1628
|
+
"flex flex-1 flex-col gap-1 group-data-[size=xs]/item:gap-0 [&+[data-slot=item-content]]:flex-none",
|
|
1629
|
+
className
|
|
1630
|
+
),
|
|
1415
1631
|
...props
|
|
1416
1632
|
}
|
|
1417
1633
|
);
|
|
1418
1634
|
}
|
|
1419
1635
|
function ItemTitle({ className, ...props }) {
|
|
1420
|
-
return /* @__PURE__ */ (0,
|
|
1636
|
+
return /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(
|
|
1421
1637
|
"div",
|
|
1422
1638
|
{
|
|
1423
1639
|
"data-slot": "item-title",
|
|
1424
|
-
className:
|
|
1640
|
+
className: (0, import_cn7.cn)(
|
|
1641
|
+
"line-clamp-1 flex w-fit items-center gap-2 text-sm leading-snug font-medium underline-offset-4",
|
|
1642
|
+
className
|
|
1643
|
+
),
|
|
1425
1644
|
...props
|
|
1426
1645
|
}
|
|
1427
1646
|
);
|
|
1428
1647
|
}
|
|
1429
1648
|
function ItemDescription({ className, ...props }) {
|
|
1430
|
-
return /* @__PURE__ */ (0,
|
|
1649
|
+
return /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(
|
|
1431
1650
|
"p",
|
|
1432
1651
|
{
|
|
1433
1652
|
"data-slot": "item-description",
|
|
1434
|
-
className: cn(
|
|
1435
|
-
"
|
|
1436
|
-
"[&>a:hover]:text-primary [&>a]:underline [&>a]:underline-offset-4",
|
|
1653
|
+
className: (0, import_cn7.cn)(
|
|
1654
|
+
"line-clamp-2 text-left text-sm leading-normal font-normal text-muted-foreground group-data-[size=xs]/item:text-xs [&>a]:underline [&>a]:underline-offset-4 [&>a:hover]:text-primary",
|
|
1437
1655
|
className
|
|
1438
1656
|
),
|
|
1439
1657
|
...props
|
|
@@ -1441,33 +1659,46 @@ function ItemDescription({ className, ...props }) {
|
|
|
1441
1659
|
);
|
|
1442
1660
|
}
|
|
1443
1661
|
function ItemActions({ className, ...props }) {
|
|
1444
|
-
return /* @__PURE__ */ (0,
|
|
1662
|
+
return /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(
|
|
1663
|
+
"div",
|
|
1664
|
+
{
|
|
1665
|
+
"data-slot": "item-actions",
|
|
1666
|
+
className: (0, import_cn7.cn)("flex items-center gap-2", className),
|
|
1667
|
+
...props
|
|
1668
|
+
}
|
|
1669
|
+
);
|
|
1445
1670
|
}
|
|
1446
1671
|
function ItemHeader({ className, ...props }) {
|
|
1447
|
-
return /* @__PURE__ */ (0,
|
|
1672
|
+
return /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(
|
|
1448
1673
|
"div",
|
|
1449
1674
|
{
|
|
1450
1675
|
"data-slot": "item-header",
|
|
1451
|
-
className:
|
|
1676
|
+
className: (0, import_cn7.cn)(
|
|
1677
|
+
"flex basis-full items-center justify-between gap-2",
|
|
1678
|
+
className
|
|
1679
|
+
),
|
|
1452
1680
|
...props
|
|
1453
1681
|
}
|
|
1454
1682
|
);
|
|
1455
1683
|
}
|
|
1456
1684
|
function ItemFooter({ className, ...props }) {
|
|
1457
|
-
return /* @__PURE__ */ (0,
|
|
1685
|
+
return /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(
|
|
1458
1686
|
"div",
|
|
1459
1687
|
{
|
|
1460
1688
|
"data-slot": "item-footer",
|
|
1461
|
-
className:
|
|
1689
|
+
className: (0, import_cn7.cn)(
|
|
1690
|
+
"flex basis-full items-center justify-between gap-2",
|
|
1691
|
+
className
|
|
1692
|
+
),
|
|
1462
1693
|
...props
|
|
1463
1694
|
}
|
|
1464
1695
|
);
|
|
1465
1696
|
}
|
|
1466
1697
|
|
|
1467
1698
|
// src/components/item/Item.tsx
|
|
1468
|
-
var
|
|
1699
|
+
var import_jsx_runtime20 = require("react/jsx-runtime");
|
|
1469
1700
|
function Item2({ className, asChild, children, ...props }) {
|
|
1470
|
-
return /* @__PURE__ */ (0,
|
|
1701
|
+
return /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
|
|
1471
1702
|
Item,
|
|
1472
1703
|
{
|
|
1473
1704
|
render: asChild ? children : void 0,
|
|
@@ -1486,8 +1717,8 @@ function Item2({ className, asChild, children, ...props }) {
|
|
|
1486
1717
|
}
|
|
1487
1718
|
);
|
|
1488
1719
|
}
|
|
1489
|
-
var ItemMedia2 =
|
|
1490
|
-
return /* @__PURE__ */ (0,
|
|
1720
|
+
var ItemMedia2 = React12.forwardRef(({ className, ...props }, ref) => {
|
|
1721
|
+
return /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
|
|
1491
1722
|
ItemMedia,
|
|
1492
1723
|
{
|
|
1493
1724
|
ref,
|
|
@@ -1497,8 +1728,8 @@ var ItemMedia2 = React18.forwardRef(({ className, ...props }, ref) => {
|
|
|
1497
1728
|
);
|
|
1498
1729
|
});
|
|
1499
1730
|
ItemMedia2.displayName = "ItemMedia";
|
|
1500
|
-
var ItemTitle2 =
|
|
1501
|
-
return /* @__PURE__ */ (0,
|
|
1731
|
+
var ItemTitle2 = React12.forwardRef(({ className, ...props }, ref) => {
|
|
1732
|
+
return /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
|
|
1502
1733
|
ItemTitle,
|
|
1503
1734
|
{
|
|
1504
1735
|
ref,
|
|
@@ -1508,8 +1739,8 @@ var ItemTitle2 = React18.forwardRef(({ className, ...props }, ref) => {
|
|
|
1508
1739
|
);
|
|
1509
1740
|
});
|
|
1510
1741
|
ItemTitle2.displayName = "ItemTitle";
|
|
1511
|
-
var ItemDescription2 =
|
|
1512
|
-
return /* @__PURE__ */ (0,
|
|
1742
|
+
var ItemDescription2 = React12.forwardRef(({ className, ...props }, ref) => {
|
|
1743
|
+
return /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
|
|
1513
1744
|
ItemDescription,
|
|
1514
1745
|
{
|
|
1515
1746
|
ref,
|
|
@@ -1519,8 +1750,8 @@ var ItemDescription2 = React18.forwardRef(({ className, ...props }, ref) => {
|
|
|
1519
1750
|
);
|
|
1520
1751
|
});
|
|
1521
1752
|
ItemDescription2.displayName = "ItemDescription";
|
|
1522
|
-
var ItemSeparator2 =
|
|
1523
|
-
return /* @__PURE__ */ (0,
|
|
1753
|
+
var ItemSeparator2 = React12.forwardRef(({ className, ...props }, ref) => {
|
|
1754
|
+
return /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
|
|
1524
1755
|
ItemSeparator,
|
|
1525
1756
|
{
|
|
1526
1757
|
ref,
|
|
@@ -1532,38 +1763,36 @@ var ItemSeparator2 = React18.forwardRef(({ className, ...props }, ref) => {
|
|
|
1532
1763
|
ItemSeparator2.displayName = "ItemSeparator";
|
|
1533
1764
|
|
|
1534
1765
|
// src/components/input/Input.tsx
|
|
1535
|
-
var
|
|
1766
|
+
var React13 = __toESM(require("react"), 1);
|
|
1536
1767
|
|
|
1537
1768
|
// src/primitives/input.tsx
|
|
1538
|
-
var
|
|
1539
|
-
var
|
|
1540
|
-
var
|
|
1541
|
-
|
|
1542
|
-
|
|
1543
|
-
|
|
1544
|
-
|
|
1545
|
-
|
|
1546
|
-
|
|
1547
|
-
|
|
1548
|
-
|
|
1549
|
-
|
|
1550
|
-
|
|
1551
|
-
|
|
1552
|
-
|
|
1553
|
-
|
|
1554
|
-
|
|
1555
|
-
);
|
|
1556
|
-
Input.displayName = "Input";
|
|
1769
|
+
var import_input = require("@base-ui/react/input");
|
|
1770
|
+
var import_cn8 = require("cn");
|
|
1771
|
+
var import_jsx_runtime21 = require("react/jsx-runtime");
|
|
1772
|
+
function Input({ className, type, ...props }) {
|
|
1773
|
+
return /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
|
|
1774
|
+
import_input.Input,
|
|
1775
|
+
{
|
|
1776
|
+
type,
|
|
1777
|
+
"data-slot": "input",
|
|
1778
|
+
className: (0, import_cn8.cn)(
|
|
1779
|
+
"h-8 w-full min-w-0 rounded-lg border border-input bg-transparent px-2.5 py-1 text-base transition-colors outline-none file:inline-flex file:h-6 file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:pointer-events-none disabled:cursor-not-allowed disabled:bg-input/50 disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 md:text-sm dark:bg-input/30 dark:disabled:bg-input/80 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40",
|
|
1780
|
+
className
|
|
1781
|
+
),
|
|
1782
|
+
...props
|
|
1783
|
+
}
|
|
1784
|
+
);
|
|
1785
|
+
}
|
|
1557
1786
|
|
|
1558
1787
|
// src/components/input/Input.tsx
|
|
1559
|
-
var
|
|
1560
|
-
var Input2 =
|
|
1788
|
+
var import_jsx_runtime22 = require("react/jsx-runtime");
|
|
1789
|
+
var Input2 = React13.forwardRef(
|
|
1561
1790
|
({ className, icon, actionButton, label, description, error, id, disabled, ...props }, ref) => {
|
|
1562
|
-
const generatedId =
|
|
1791
|
+
const generatedId = React13.useId();
|
|
1563
1792
|
const inputId = id || generatedId;
|
|
1564
1793
|
const errorId = `${inputId}-error`;
|
|
1565
1794
|
const descriptionId = `${inputId}-description`;
|
|
1566
|
-
const inputElement = /* @__PURE__ */ (0,
|
|
1795
|
+
const inputElement = /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
|
|
1567
1796
|
Input,
|
|
1568
1797
|
{
|
|
1569
1798
|
ref,
|
|
@@ -1583,8 +1812,8 @@ var Input2 = React20.forwardRef(
|
|
|
1583
1812
|
}
|
|
1584
1813
|
);
|
|
1585
1814
|
if (!icon && !actionButton) {
|
|
1586
|
-
return /* @__PURE__ */ (0,
|
|
1587
|
-
label && /* @__PURE__ */ (0,
|
|
1815
|
+
return /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)("div", { className: "flex flex-col gap-2", children: [
|
|
1816
|
+
label && /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
|
|
1588
1817
|
"label",
|
|
1589
1818
|
{
|
|
1590
1819
|
htmlFor: inputId,
|
|
@@ -1597,9 +1826,9 @@ var Input2 = React20.forwardRef(
|
|
|
1597
1826
|
}
|
|
1598
1827
|
),
|
|
1599
1828
|
inputElement,
|
|
1600
|
-
(description || error) && /* @__PURE__ */ (0,
|
|
1601
|
-
description && /* @__PURE__ */ (0,
|
|
1602
|
-
error && /* @__PURE__ */ (0,
|
|
1829
|
+
(description || error) && /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)("div", { className: "flex flex-col gap-1", children: [
|
|
1830
|
+
description && /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(Typography, { variant: "xs", color: "muted", id: descriptionId, children: description }),
|
|
1831
|
+
error && /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
|
|
1603
1832
|
Typography,
|
|
1604
1833
|
{
|
|
1605
1834
|
variant: "xs",
|
|
@@ -1611,8 +1840,8 @@ var Input2 = React20.forwardRef(
|
|
|
1611
1840
|
] })
|
|
1612
1841
|
] });
|
|
1613
1842
|
}
|
|
1614
|
-
return /* @__PURE__ */ (0,
|
|
1615
|
-
label && /* @__PURE__ */ (0,
|
|
1843
|
+
return /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)("div", { className: "flex flex-col gap-2", children: [
|
|
1844
|
+
label && /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
|
|
1616
1845
|
"label",
|
|
1617
1846
|
{
|
|
1618
1847
|
htmlFor: inputId,
|
|
@@ -1624,14 +1853,14 @@ var Input2 = React20.forwardRef(
|
|
|
1624
1853
|
children: label
|
|
1625
1854
|
}
|
|
1626
1855
|
),
|
|
1627
|
-
/* @__PURE__ */ (0,
|
|
1628
|
-
icon && /* @__PURE__ */ (0,
|
|
1856
|
+
/* @__PURE__ */ (0, import_jsx_runtime22.jsxs)("div", { className: "relative w-full", children: [
|
|
1857
|
+
icon && /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("div", { className: "absolute left-3 top-1/2 -translate-y-1/2", children: icon }),
|
|
1629
1858
|
inputElement,
|
|
1630
|
-
actionButton && /* @__PURE__ */ (0,
|
|
1859
|
+
actionButton && /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("div", { className: "absolute right-2 top-1/2 -translate-y-1/2", children: actionButton })
|
|
1631
1860
|
] }),
|
|
1632
|
-
(description || error) && /* @__PURE__ */ (0,
|
|
1633
|
-
description && /* @__PURE__ */ (0,
|
|
1634
|
-
error && /* @__PURE__ */ (0,
|
|
1861
|
+
(description || error) && /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)("div", { className: "flex flex-col gap-1", children: [
|
|
1862
|
+
description && /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(Typography, { variant: "xs", color: "muted", id: descriptionId, children: description }),
|
|
1863
|
+
error && /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(Typography, { variant: "xs", id: errorId, className: "text-berget-destructive-foreground", children: error })
|
|
1635
1864
|
] })
|
|
1636
1865
|
] });
|
|
1637
1866
|
}
|
|
@@ -1639,43 +1868,44 @@ var Input2 = React20.forwardRef(
|
|
|
1639
1868
|
Input2.displayName = "Input";
|
|
1640
1869
|
|
|
1641
1870
|
// src/components/checkbox/Checkbox.tsx
|
|
1642
|
-
var
|
|
1871
|
+
var React14 = __toESM(require("react"), 1);
|
|
1643
1872
|
var import_checkbox2 = require("@base-ui/react/checkbox");
|
|
1644
|
-
var
|
|
1645
|
-
var
|
|
1873
|
+
var import_lucide_react6 = require("lucide-react");
|
|
1874
|
+
var import_class_variance_authority10 = require("class-variance-authority");
|
|
1646
1875
|
|
|
1647
1876
|
// src/primitives/checkbox.tsx
|
|
1648
|
-
var React21 = __toESM(require("react"), 1);
|
|
1649
1877
|
var import_checkbox = require("@base-ui/react/checkbox");
|
|
1650
|
-
var
|
|
1651
|
-
var
|
|
1652
|
-
var
|
|
1653
|
-
|
|
1654
|
-
|
|
1655
|
-
|
|
1656
|
-
|
|
1657
|
-
"
|
|
1658
|
-
className
|
|
1659
|
-
|
|
1660
|
-
|
|
1661
|
-
|
|
1662
|
-
|
|
1663
|
-
)
|
|
1664
|
-
Checkbox.
|
|
1665
|
-
|
|
1666
|
-
|
|
1667
|
-
|
|
1668
|
-
|
|
1669
|
-
|
|
1670
|
-
|
|
1671
|
-
|
|
1672
|
-
|
|
1673
|
-
)
|
|
1674
|
-
|
|
1878
|
+
var import_cn9 = require("cn");
|
|
1879
|
+
var import_lucide_react5 = require("lucide-react");
|
|
1880
|
+
var import_jsx_runtime23 = require("react/jsx-runtime");
|
|
1881
|
+
function Checkbox({ className, ...props }) {
|
|
1882
|
+
return /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
|
|
1883
|
+
import_checkbox.Checkbox.Root,
|
|
1884
|
+
{
|
|
1885
|
+
"data-slot": "checkbox",
|
|
1886
|
+
className: (0, import_cn9.cn)(
|
|
1887
|
+
"peer relative flex size-4 shrink-0 items-center justify-center rounded-[4px] border border-input transition-colors outline-none group-has-disabled/field:opacity-50 group-has-[:focus-visible]/field-label:ring-0 group-has-[:focus-visible]/field-label:not-data-checked:border-input after:absolute after:-inset-x-3 after:-inset-y-2 focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 aria-invalid:aria-checked:border-primary dark:bg-input/30 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 data-checked:border-primary data-checked:bg-primary data-checked:text-primary-foreground group-has-[:focus-visible]/field-label:data-checked:border-primary dark:data-checked:bg-primary",
|
|
1888
|
+
className
|
|
1889
|
+
),
|
|
1890
|
+
...props,
|
|
1891
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
|
|
1892
|
+
import_checkbox.Checkbox.Indicator,
|
|
1893
|
+
{
|
|
1894
|
+
"data-slot": "checkbox-indicator",
|
|
1895
|
+
className: "grid place-content-center text-current transition-none [&>svg]:size-3.5",
|
|
1896
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
|
|
1897
|
+
import_lucide_react5.CheckIcon,
|
|
1898
|
+
{}
|
|
1899
|
+
)
|
|
1900
|
+
}
|
|
1901
|
+
)
|
|
1902
|
+
}
|
|
1903
|
+
);
|
|
1904
|
+
}
|
|
1675
1905
|
|
|
1676
1906
|
// src/components/checkbox/Checkbox.tsx
|
|
1677
|
-
var
|
|
1678
|
-
var checkboxVariants = (0,
|
|
1907
|
+
var import_jsx_runtime24 = require("react/jsx-runtime");
|
|
1908
|
+
var checkboxVariants = (0, import_class_variance_authority10.cva)(
|
|
1679
1909
|
"inline-flex items-center justify-center rounded-md transition-all duration-200 focus-visible:outline-none disabled:cursor-not-allowed disabled:opacity-50",
|
|
1680
1910
|
{
|
|
1681
1911
|
variants: {
|
|
@@ -1696,7 +1926,7 @@ var checkboxVariants = (0, import_class_variance_authority9.cva)(
|
|
|
1696
1926
|
}
|
|
1697
1927
|
}
|
|
1698
1928
|
);
|
|
1699
|
-
var Checkbox2 =
|
|
1929
|
+
var Checkbox2 = React14.forwardRef(
|
|
1700
1930
|
({
|
|
1701
1931
|
"aria-label": ariaLabel,
|
|
1702
1932
|
className,
|
|
@@ -1709,11 +1939,11 @@ var Checkbox2 = React22.forwardRef(
|
|
|
1709
1939
|
disabled,
|
|
1710
1940
|
...props
|
|
1711
1941
|
}, ref) => {
|
|
1712
|
-
const generatedId =
|
|
1942
|
+
const generatedId = React14.useId();
|
|
1713
1943
|
const checkboxId = id || generatedId;
|
|
1714
1944
|
const errorId = `${checkboxId}-error`;
|
|
1715
|
-
return /* @__PURE__ */ (0,
|
|
1716
|
-
/* @__PURE__ */ (0,
|
|
1945
|
+
return /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)("div", { className: "flex items-start gap-3", children: [
|
|
1946
|
+
/* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { className: "relative flex items-start pt-0.5", children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
|
|
1717
1947
|
Checkbox,
|
|
1718
1948
|
{
|
|
1719
1949
|
ref,
|
|
@@ -1730,8 +1960,8 @@ var Checkbox2 = React22.forwardRef(
|
|
|
1730
1960
|
className
|
|
1731
1961
|
),
|
|
1732
1962
|
...props,
|
|
1733
|
-
children: /* @__PURE__ */ (0,
|
|
1734
|
-
|
|
1963
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(import_checkbox2.Checkbox.Indicator, { children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
|
|
1964
|
+
import_lucide_react6.Check,
|
|
1735
1965
|
{
|
|
1736
1966
|
className: "h-4 w-4 text-current stroke-current",
|
|
1737
1967
|
style: { color: "currentColor", stroke: "currentColor" }
|
|
@@ -1739,8 +1969,8 @@ var Checkbox2 = React22.forwardRef(
|
|
|
1739
1969
|
) })
|
|
1740
1970
|
}
|
|
1741
1971
|
) }),
|
|
1742
|
-
(label || description || error) && /* @__PURE__ */ (0,
|
|
1743
|
-
label && /* @__PURE__ */ (0,
|
|
1972
|
+
(label || description || error) && /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)("div", { className: "flex flex-col gap-1", children: [
|
|
1973
|
+
label && /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
|
|
1744
1974
|
"label",
|
|
1745
1975
|
{
|
|
1746
1976
|
htmlFor: checkboxId,
|
|
@@ -1752,8 +1982,8 @@ var Checkbox2 = React22.forwardRef(
|
|
|
1752
1982
|
children: label
|
|
1753
1983
|
}
|
|
1754
1984
|
),
|
|
1755
|
-
description && /* @__PURE__ */ (0,
|
|
1756
|
-
error && /* @__PURE__ */ (0,
|
|
1985
|
+
description && /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(Typography, { variant: "xs", color: "muted", children: description }),
|
|
1986
|
+
error && /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(Typography, { variant: "xs", id: errorId, className: "text-berget-destructive-foreground", children: error })
|
|
1757
1987
|
] })
|
|
1758
1988
|
] });
|
|
1759
1989
|
}
|
|
@@ -1761,11 +1991,11 @@ var Checkbox2 = React22.forwardRef(
|
|
|
1761
1991
|
Checkbox2.displayName = "Checkbox";
|
|
1762
1992
|
|
|
1763
1993
|
// src/components/switch/Switch.tsx
|
|
1764
|
-
var
|
|
1994
|
+
var React15 = __toESM(require("react"), 1);
|
|
1765
1995
|
var import_switch = require("@base-ui/react/switch");
|
|
1766
|
-
var
|
|
1767
|
-
var
|
|
1768
|
-
var switchRootVariants = (0,
|
|
1996
|
+
var import_class_variance_authority11 = require("class-variance-authority");
|
|
1997
|
+
var import_jsx_runtime25 = require("react/jsx-runtime");
|
|
1998
|
+
var switchRootVariants = (0, import_class_variance_authority11.cva)(
|
|
1769
1999
|
"peer inline-flex shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-berget-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background disabled:cursor-not-allowed disabled:opacity-50",
|
|
1770
2000
|
{
|
|
1771
2001
|
variants: {
|
|
@@ -1786,7 +2016,7 @@ var switchRootVariants = (0, import_class_variance_authority10.cva)(
|
|
|
1786
2016
|
}
|
|
1787
2017
|
}
|
|
1788
2018
|
);
|
|
1789
|
-
var switchThumbVariants = (0,
|
|
2019
|
+
var switchThumbVariants = (0, import_class_variance_authority11.cva)(
|
|
1790
2020
|
"pointer-events-none block rounded-full ring-0 transition-transform shadow-berget-sm bg-berget-foreground",
|
|
1791
2021
|
{
|
|
1792
2022
|
variants: {
|
|
@@ -1801,7 +2031,7 @@ var switchThumbVariants = (0, import_class_variance_authority10.cva)(
|
|
|
1801
2031
|
}
|
|
1802
2032
|
}
|
|
1803
2033
|
);
|
|
1804
|
-
var Switch =
|
|
2034
|
+
var Switch = React15.forwardRef(
|
|
1805
2035
|
({
|
|
1806
2036
|
"aria-label": ariaLabel,
|
|
1807
2037
|
className,
|
|
@@ -1814,11 +2044,11 @@ var Switch = React23.forwardRef(
|
|
|
1814
2044
|
disabled,
|
|
1815
2045
|
...props
|
|
1816
2046
|
}, ref) => {
|
|
1817
|
-
const generatedId =
|
|
2047
|
+
const generatedId = React15.useId();
|
|
1818
2048
|
const switchId = id || generatedId;
|
|
1819
2049
|
const errorId = `${switchId}-error`;
|
|
1820
|
-
return /* @__PURE__ */ (0,
|
|
1821
|
-
/* @__PURE__ */ (0,
|
|
2050
|
+
return /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)("div", { className: "flex items-center gap-3", children: [
|
|
2051
|
+
/* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
|
|
1822
2052
|
import_switch.Switch.Root,
|
|
1823
2053
|
{
|
|
1824
2054
|
ref,
|
|
@@ -1834,11 +2064,11 @@ var Switch = React23.forwardRef(
|
|
|
1834
2064
|
className
|
|
1835
2065
|
),
|
|
1836
2066
|
...props,
|
|
1837
|
-
children: /* @__PURE__ */ (0,
|
|
2067
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(import_switch.Switch.Thumb, { className: cn(switchThumbVariants({ size })) })
|
|
1838
2068
|
}
|
|
1839
2069
|
),
|
|
1840
|
-
(label || description || error) && /* @__PURE__ */ (0,
|
|
1841
|
-
label && /* @__PURE__ */ (0,
|
|
2070
|
+
(label || description || error) && /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)("div", { className: "flex flex-col gap-1", children: [
|
|
2071
|
+
label && /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
|
|
1842
2072
|
"label",
|
|
1843
2073
|
{
|
|
1844
2074
|
htmlFor: switchId,
|
|
@@ -1849,8 +2079,8 @@ var Switch = React23.forwardRef(
|
|
|
1849
2079
|
children: label
|
|
1850
2080
|
}
|
|
1851
2081
|
),
|
|
1852
|
-
description && /* @__PURE__ */ (0,
|
|
1853
|
-
error && /* @__PURE__ */ (0,
|
|
2082
|
+
description && /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(Typography, { variant: "xs", color: "muted", children: description }),
|
|
2083
|
+
error && /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(Typography, { variant: "xs", id: errorId, className: "text-berget-destructive-foreground", children: error })
|
|
1854
2084
|
] })
|
|
1855
2085
|
] });
|
|
1856
2086
|
}
|
|
@@ -1858,135 +2088,160 @@ var Switch = React23.forwardRef(
|
|
|
1858
2088
|
Switch.displayName = "Switch";
|
|
1859
2089
|
|
|
1860
2090
|
// src/components/select/Select.tsx
|
|
1861
|
-
var
|
|
1862
|
-
var
|
|
2091
|
+
var React16 = __toESM(require("react"), 1);
|
|
2092
|
+
var import_class_variance_authority12 = require("class-variance-authority");
|
|
1863
2093
|
|
|
1864
2094
|
// src/primitives/select.tsx
|
|
1865
|
-
var React24 = __toESM(require("react"), 1);
|
|
1866
2095
|
var import_select = require("@base-ui/react/select");
|
|
1867
|
-
var
|
|
1868
|
-
var
|
|
2096
|
+
var import_cn10 = require("cn");
|
|
2097
|
+
var import_lucide_react7 = require("lucide-react");
|
|
2098
|
+
var import_jsx_runtime26 = require("react/jsx-runtime");
|
|
1869
2099
|
var Select = import_select.Select.Root;
|
|
1870
|
-
|
|
1871
|
-
|
|
1872
|
-
|
|
1873
|
-
|
|
1874
|
-
|
|
1875
|
-
|
|
1876
|
-
|
|
1877
|
-
|
|
1878
|
-
|
|
1879
|
-
|
|
1880
|
-
|
|
1881
|
-
|
|
1882
|
-
|
|
1883
|
-
|
|
1884
|
-
|
|
1885
|
-
|
|
1886
|
-
|
|
1887
|
-
|
|
1888
|
-
|
|
1889
|
-
|
|
1890
|
-
|
|
1891
|
-
|
|
1892
|
-
|
|
1893
|
-
|
|
1894
|
-
|
|
1895
|
-
|
|
1896
|
-
|
|
1897
|
-
|
|
1898
|
-
|
|
1899
|
-
|
|
1900
|
-
|
|
1901
|
-
|
|
1902
|
-
|
|
1903
|
-
|
|
1904
|
-
|
|
1905
|
-
|
|
1906
|
-
|
|
1907
|
-
|
|
1908
|
-
|
|
1909
|
-
|
|
1910
|
-
|
|
1911
|
-
|
|
1912
|
-
|
|
1913
|
-
|
|
1914
|
-
|
|
1915
|
-
|
|
1916
|
-
|
|
1917
|
-
|
|
1918
|
-
|
|
1919
|
-
}, ref) => /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(import_select.Select.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
|
|
2100
|
+
function SelectValue({ className, ...props }) {
|
|
2101
|
+
return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
|
|
2102
|
+
import_select.Select.Value,
|
|
2103
|
+
{
|
|
2104
|
+
"data-slot": "select-value",
|
|
2105
|
+
className: (0, import_cn10.cn)("flex flex-1 text-left", className),
|
|
2106
|
+
...props
|
|
2107
|
+
}
|
|
2108
|
+
);
|
|
2109
|
+
}
|
|
2110
|
+
function SelectTrigger({
|
|
2111
|
+
className,
|
|
2112
|
+
size = "default",
|
|
2113
|
+
children,
|
|
2114
|
+
...props
|
|
2115
|
+
}) {
|
|
2116
|
+
return /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(
|
|
2117
|
+
import_select.Select.Trigger,
|
|
2118
|
+
{
|
|
2119
|
+
"data-slot": "select-trigger",
|
|
2120
|
+
"data-size": size,
|
|
2121
|
+
className: (0, import_cn10.cn)(
|
|
2122
|
+
"flex w-fit items-center justify-between gap-1.5 rounded-lg border border-input bg-transparent py-2 pr-2 pl-2.5 text-sm whitespace-nowrap transition-colors outline-none select-none focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 data-placeholder:text-muted-foreground data-[size=default]:h-8 data-[size=sm]:h-7 data-[size=sm]:rounded-[min(var(--radius-md),10px)] *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-1.5 dark:bg-input/30 dark:hover:bg-input/50 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
|
|
2123
|
+
className
|
|
2124
|
+
),
|
|
2125
|
+
...props,
|
|
2126
|
+
children: [
|
|
2127
|
+
children,
|
|
2128
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
|
|
2129
|
+
import_select.Select.Icon,
|
|
2130
|
+
{
|
|
2131
|
+
render: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(import_lucide_react7.ChevronDownIcon, { className: "pointer-events-none size-4 text-muted-foreground" })
|
|
2132
|
+
}
|
|
2133
|
+
)
|
|
2134
|
+
]
|
|
2135
|
+
}
|
|
2136
|
+
);
|
|
2137
|
+
}
|
|
2138
|
+
function SelectContent({
|
|
2139
|
+
className,
|
|
2140
|
+
children,
|
|
2141
|
+
side = "bottom",
|
|
2142
|
+
sideOffset = 4,
|
|
2143
|
+
align = "center",
|
|
2144
|
+
alignOffset = 0,
|
|
2145
|
+
alignItemWithTrigger = true,
|
|
2146
|
+
...props
|
|
2147
|
+
}) {
|
|
2148
|
+
return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(import_select.Select.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
|
|
1920
2149
|
import_select.Select.Positioner,
|
|
1921
2150
|
{
|
|
1922
|
-
alignItemWithTrigger,
|
|
1923
2151
|
side,
|
|
2152
|
+
sideOffset,
|
|
1924
2153
|
align,
|
|
1925
2154
|
alignOffset,
|
|
1926
|
-
|
|
2155
|
+
alignItemWithTrigger,
|
|
1927
2156
|
className: "isolate z-50",
|
|
1928
|
-
children: /* @__PURE__ */ (0,
|
|
2157
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(
|
|
1929
2158
|
import_select.Select.Popup,
|
|
1930
2159
|
{
|
|
1931
|
-
|
|
1932
|
-
|
|
1933
|
-
|
|
1934
|
-
className
|
|
1935
|
-
),
|
|
2160
|
+
"data-slot": "select-content",
|
|
2161
|
+
"data-align-trigger": alignItemWithTrigger,
|
|
2162
|
+
className: (0, import_cn10.cn)("relative isolate z-50 max-h-(--available-height) w-(--anchor-width) min-w-36 origin-(--transform-origin) overflow-x-hidden overflow-y-auto rounded-lg bg-popover text-popover-foreground shadow-md ring-1 ring-foreground/10 duration-100 data-[align-trigger=true]:animate-none data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-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 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95", className),
|
|
1936
2163
|
...props,
|
|
1937
2164
|
children: [
|
|
1938
|
-
/* @__PURE__ */ (0,
|
|
1939
|
-
/* @__PURE__ */ (0,
|
|
1940
|
-
/* @__PURE__ */ (0,
|
|
2165
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)(SelectScrollUpButton, {}),
|
|
2166
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)(import_select.Select.List, { children }),
|
|
2167
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)(SelectScrollDownButton, {})
|
|
1941
2168
|
]
|
|
1942
2169
|
}
|
|
1943
2170
|
)
|
|
1944
2171
|
}
|
|
1945
|
-
) })
|
|
1946
|
-
|
|
1947
|
-
|
|
1948
|
-
|
|
1949
|
-
|
|
1950
|
-
|
|
1951
|
-
|
|
1952
|
-
|
|
1953
|
-
|
|
1954
|
-
|
|
1955
|
-
|
|
1956
|
-
|
|
1957
|
-
)
|
|
1958
|
-
|
|
1959
|
-
|
|
1960
|
-
|
|
1961
|
-
|
|
1962
|
-
|
|
1963
|
-
|
|
1964
|
-
|
|
1965
|
-
|
|
1966
|
-
|
|
1967
|
-
|
|
1968
|
-
|
|
1969
|
-
|
|
1970
|
-
|
|
1971
|
-
|
|
1972
|
-
|
|
1973
|
-
|
|
1974
|
-
|
|
1975
|
-
|
|
1976
|
-
|
|
1977
|
-
|
|
1978
|
-
|
|
1979
|
-
|
|
1980
|
-
|
|
1981
|
-
|
|
1982
|
-
|
|
1983
|
-
|
|
1984
|
-
|
|
1985
|
-
|
|
2172
|
+
) });
|
|
2173
|
+
}
|
|
2174
|
+
function SelectItem({
|
|
2175
|
+
className,
|
|
2176
|
+
children,
|
|
2177
|
+
...props
|
|
2178
|
+
}) {
|
|
2179
|
+
return /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(
|
|
2180
|
+
import_select.Select.Item,
|
|
2181
|
+
{
|
|
2182
|
+
"data-slot": "select-item",
|
|
2183
|
+
className: (0, import_cn10.cn)(
|
|
2184
|
+
"relative flex w-full cursor-default items-center gap-1.5 rounded-md py-1 pr-8 pl-1.5 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground not-data-[variant=destructive]:focus:**:text-accent-foreground data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2",
|
|
2185
|
+
className
|
|
2186
|
+
),
|
|
2187
|
+
...props,
|
|
2188
|
+
children: [
|
|
2189
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)(import_select.Select.ItemText, { className: "flex flex-1 shrink-0 gap-2 whitespace-nowrap", children }),
|
|
2190
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
|
|
2191
|
+
import_select.Select.ItemIndicator,
|
|
2192
|
+
{
|
|
2193
|
+
render: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("span", { className: "pointer-events-none absolute right-2 flex size-4 items-center justify-center" }),
|
|
2194
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(import_lucide_react7.CheckIcon, { className: "pointer-events-none" })
|
|
2195
|
+
}
|
|
2196
|
+
)
|
|
2197
|
+
]
|
|
2198
|
+
}
|
|
2199
|
+
);
|
|
2200
|
+
}
|
|
2201
|
+
function SelectScrollUpButton({
|
|
2202
|
+
className,
|
|
2203
|
+
...props
|
|
2204
|
+
}) {
|
|
2205
|
+
return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
|
|
2206
|
+
import_select.Select.ScrollUpArrow,
|
|
2207
|
+
{
|
|
2208
|
+
"data-slot": "select-scroll-up-button",
|
|
2209
|
+
className: (0, import_cn10.cn)(
|
|
2210
|
+
"top-0 z-10 flex w-full cursor-default items-center justify-center bg-popover py-1 [&_svg:not([class*='size-'])]:size-4",
|
|
2211
|
+
className
|
|
2212
|
+
),
|
|
2213
|
+
...props,
|
|
2214
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
|
|
2215
|
+
import_lucide_react7.ChevronUpIcon,
|
|
2216
|
+
{}
|
|
2217
|
+
)
|
|
2218
|
+
}
|
|
2219
|
+
);
|
|
2220
|
+
}
|
|
2221
|
+
function SelectScrollDownButton({
|
|
2222
|
+
className,
|
|
2223
|
+
...props
|
|
2224
|
+
}) {
|
|
2225
|
+
return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
|
|
2226
|
+
import_select.Select.ScrollDownArrow,
|
|
2227
|
+
{
|
|
2228
|
+
"data-slot": "select-scroll-down-button",
|
|
2229
|
+
className: (0, import_cn10.cn)(
|
|
2230
|
+
"bottom-0 z-10 flex w-full cursor-default items-center justify-center bg-popover py-1 [&_svg:not([class*='size-'])]:size-4",
|
|
2231
|
+
className
|
|
2232
|
+
),
|
|
2233
|
+
...props,
|
|
2234
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
|
|
2235
|
+
import_lucide_react7.ChevronDownIcon,
|
|
2236
|
+
{}
|
|
2237
|
+
)
|
|
2238
|
+
}
|
|
2239
|
+
);
|
|
2240
|
+
}
|
|
1986
2241
|
|
|
1987
2242
|
// src/components/select/Select.tsx
|
|
1988
|
-
var
|
|
1989
|
-
var selectVariants = (0,
|
|
2243
|
+
var import_jsx_runtime27 = require("react/jsx-runtime");
|
|
2244
|
+
var selectVariants = (0, import_class_variance_authority12.cva)(
|
|
1990
2245
|
"flex w-full items-center justify-between rounded-berget-xs border bg-card px-4 py-3 text-sm transition-colors duration-200 focus-visible:outline-none focus-visible:ring-0 focus-visible:ring-offset-0 focus-visible:border-berget-form-focus-border disabled:cursor-not-allowed disabled:opacity-50",
|
|
1991
2246
|
{
|
|
1992
2247
|
variants: {
|
|
@@ -2008,7 +2263,7 @@ var selectVariants = (0, import_class_variance_authority11.cva)(
|
|
|
2008
2263
|
}
|
|
2009
2264
|
}
|
|
2010
2265
|
);
|
|
2011
|
-
var Select2 =
|
|
2266
|
+
var Select2 = React16.forwardRef(
|
|
2012
2267
|
({
|
|
2013
2268
|
className,
|
|
2014
2269
|
variant,
|
|
@@ -2026,12 +2281,12 @@ var Select2 = React25.forwardRef(
|
|
|
2026
2281
|
name,
|
|
2027
2282
|
required
|
|
2028
2283
|
}, ref) => {
|
|
2029
|
-
const generatedId =
|
|
2284
|
+
const generatedId = React16.useId();
|
|
2030
2285
|
const selectId = id || generatedId;
|
|
2031
2286
|
const errorId = `${selectId}-error`;
|
|
2032
2287
|
const descriptionId = `${selectId}-description`;
|
|
2033
|
-
return /* @__PURE__ */ (0,
|
|
2034
|
-
label && /* @__PURE__ */ (0,
|
|
2288
|
+
return /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)("div", { className: "flex flex-col gap-2", children: [
|
|
2289
|
+
label && /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
|
|
2035
2290
|
"label",
|
|
2036
2291
|
{
|
|
2037
2292
|
htmlFor: selectId,
|
|
@@ -2043,7 +2298,7 @@ var Select2 = React25.forwardRef(
|
|
|
2043
2298
|
children: label
|
|
2044
2299
|
}
|
|
2045
2300
|
),
|
|
2046
|
-
/* @__PURE__ */ (0,
|
|
2301
|
+
/* @__PURE__ */ (0, import_jsx_runtime27.jsxs)(
|
|
2047
2302
|
Select,
|
|
2048
2303
|
{
|
|
2049
2304
|
value,
|
|
@@ -2054,7 +2309,7 @@ var Select2 = React25.forwardRef(
|
|
|
2054
2309
|
required,
|
|
2055
2310
|
items: options,
|
|
2056
2311
|
children: [
|
|
2057
|
-
/* @__PURE__ */ (0,
|
|
2312
|
+
/* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
|
|
2058
2313
|
SelectTrigger,
|
|
2059
2314
|
{
|
|
2060
2315
|
ref,
|
|
@@ -2066,33 +2321,33 @@ var Select2 = React25.forwardRef(
|
|
|
2066
2321
|
error && "border-berget-destructive-foreground/50 bg-berget-destructive",
|
|
2067
2322
|
className
|
|
2068
2323
|
),
|
|
2069
|
-
children: /* @__PURE__ */ (0,
|
|
2324
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(SelectValue, { placeholder })
|
|
2070
2325
|
}
|
|
2071
2326
|
),
|
|
2072
|
-
/* @__PURE__ */ (0,
|
|
2327
|
+
/* @__PURE__ */ (0, import_jsx_runtime27.jsx)(SelectContent, { children: options.map((option) => /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(SelectItem, { value: option.value, disabled: option.disabled, children: option.label }, option.value)) })
|
|
2073
2328
|
]
|
|
2074
2329
|
}
|
|
2075
2330
|
),
|
|
2076
|
-
description && /* @__PURE__ */ (0,
|
|
2077
|
-
error && /* @__PURE__ */ (0,
|
|
2331
|
+
description && /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(Typography, { variant: "xs", color: "muted", id: descriptionId, children: description }),
|
|
2332
|
+
error && /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(Typography, { variant: "xs", id: errorId, className: "text-berget-destructive-foreground", children: error })
|
|
2078
2333
|
] });
|
|
2079
2334
|
}
|
|
2080
2335
|
);
|
|
2081
2336
|
Select2.displayName = "Select";
|
|
2082
2337
|
|
|
2083
2338
|
// src/components/country-select/CountrySelect.tsx
|
|
2084
|
-
var
|
|
2085
|
-
var
|
|
2339
|
+
var React18 = __toESM(require("react"), 1);
|
|
2340
|
+
var import_lucide_react10 = require("lucide-react");
|
|
2086
2341
|
|
|
2087
2342
|
// src/components/icon/Icon.tsx
|
|
2088
|
-
var
|
|
2089
|
-
var
|
|
2343
|
+
var React17 = __toESM(require("react"), 1);
|
|
2344
|
+
var import_jsx_runtime28 = require("react/jsx-runtime");
|
|
2090
2345
|
var iconStrokeMap = {
|
|
2091
2346
|
16: 1.4,
|
|
2092
2347
|
24: 1.6,
|
|
2093
2348
|
32: 1.8
|
|
2094
2349
|
};
|
|
2095
|
-
var Icon =
|
|
2350
|
+
var Icon = React17.forwardRef(
|
|
2096
2351
|
({
|
|
2097
2352
|
icon: IconComponent,
|
|
2098
2353
|
size,
|
|
@@ -2104,7 +2359,7 @@ var Icon = React26.forwardRef(
|
|
|
2104
2359
|
const strokeWidth = iconStrokeMap[size];
|
|
2105
2360
|
const sizeClass = size === 16 ? "w-4 h-4" : size === 24 ? "w-6 h-6" : "w-8 h-8";
|
|
2106
2361
|
const ariaAttributes = ariaLabel ? { "aria-label": ariaLabel } : { "aria-hidden": ariaHidden };
|
|
2107
|
-
return /* @__PURE__ */ (0,
|
|
2362
|
+
return /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
|
|
2108
2363
|
IconComponent,
|
|
2109
2364
|
{
|
|
2110
2365
|
ref,
|
|
@@ -2119,193 +2374,252 @@ var Icon = React26.forwardRef(
|
|
|
2119
2374
|
Icon.displayName = "Icon";
|
|
2120
2375
|
|
|
2121
2376
|
// src/primitives/popover.tsx
|
|
2122
|
-
var React27 = __toESM(require("react"), 1);
|
|
2123
2377
|
var import_popover = require("@base-ui/react/popover");
|
|
2124
|
-
var
|
|
2125
|
-
var
|
|
2126
|
-
|
|
2127
|
-
|
|
2128
|
-
|
|
2129
|
-
PopoverTrigger
|
|
2130
|
-
|
|
2131
|
-
|
|
2132
|
-
|
|
2133
|
-
|
|
2134
|
-
|
|
2135
|
-
|
|
2136
|
-
|
|
2137
|
-
|
|
2138
|
-
|
|
2139
|
-
|
|
2140
|
-
|
|
2141
|
-
|
|
2378
|
+
var import_cn11 = require("cn");
|
|
2379
|
+
var import_jsx_runtime29 = require("react/jsx-runtime");
|
|
2380
|
+
function Popover({ ...props }) {
|
|
2381
|
+
return /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(import_popover.Popover.Root, { "data-slot": "popover", ...props });
|
|
2382
|
+
}
|
|
2383
|
+
function PopoverTrigger({ ...props }) {
|
|
2384
|
+
return /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(import_popover.Popover.Trigger, { "data-slot": "popover-trigger", ...props });
|
|
2385
|
+
}
|
|
2386
|
+
function PopoverContent({
|
|
2387
|
+
className,
|
|
2388
|
+
align = "center",
|
|
2389
|
+
alignOffset = 0,
|
|
2390
|
+
side = "bottom",
|
|
2391
|
+
sideOffset = 4,
|
|
2392
|
+
...props
|
|
2393
|
+
}) {
|
|
2394
|
+
return /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(import_popover.Popover.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
|
|
2395
|
+
import_popover.Popover.Positioner,
|
|
2396
|
+
{
|
|
2397
|
+
align,
|
|
2398
|
+
alignOffset,
|
|
2399
|
+
side,
|
|
2400
|
+
sideOffset,
|
|
2401
|
+
className: "isolate z-50",
|
|
2402
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
|
|
2403
|
+
import_popover.Popover.Popup,
|
|
2404
|
+
{
|
|
2405
|
+
"data-slot": "popover-content",
|
|
2406
|
+
className: (0, import_cn11.cn)(
|
|
2407
|
+
"z-50 flex w-72 origin-(--transform-origin) flex-col gap-2.5 rounded-lg bg-popover p-2.5 text-sm text-popover-foreground shadow-md ring-1 ring-foreground/10 outline-hidden duration-100 data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-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 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",
|
|
2408
|
+
className
|
|
2409
|
+
),
|
|
2410
|
+
...props
|
|
2411
|
+
}
|
|
2412
|
+
)
|
|
2413
|
+
}
|
|
2414
|
+
) });
|
|
2415
|
+
}
|
|
2142
2416
|
|
|
2143
2417
|
// src/primitives/command.tsx
|
|
2144
|
-
var React29 = __toESM(require("react"), 1);
|
|
2145
2418
|
var import_cmdk = require("cmdk");
|
|
2146
|
-
var
|
|
2419
|
+
var import_cn15 = require("cn");
|
|
2147
2420
|
|
|
2148
2421
|
// src/primitives/dialog.tsx
|
|
2149
|
-
var React28 = __toESM(require("react"), 1);
|
|
2150
2422
|
var import_dialog2 = require("@base-ui/react/dialog");
|
|
2151
|
-
var
|
|
2152
|
-
var
|
|
2153
|
-
var
|
|
2154
|
-
|
|
2155
|
-
|
|
2156
|
-
);
|
|
2157
|
-
|
|
2158
|
-
|
|
2159
|
-
|
|
2160
|
-
|
|
2161
|
-
);
|
|
2162
|
-
|
|
2163
|
-
|
|
2164
|
-
|
|
2165
|
-
|
|
2166
|
-
|
|
2167
|
-
|
|
2168
|
-
|
|
2169
|
-
|
|
2170
|
-
|
|
2171
|
-
|
|
2172
|
-
|
|
2173
|
-
)
|
|
2174
|
-
|
|
2175
|
-
|
|
2176
|
-
|
|
2177
|
-
|
|
2178
|
-
|
|
2423
|
+
var import_cn12 = require("cn");
|
|
2424
|
+
var import_lucide_react8 = require("lucide-react");
|
|
2425
|
+
var import_jsx_runtime30 = require("react/jsx-runtime");
|
|
2426
|
+
|
|
2427
|
+
// src/primitives/input-group.tsx
|
|
2428
|
+
var import_class_variance_authority13 = require("class-variance-authority");
|
|
2429
|
+
var import_cn14 = require("cn");
|
|
2430
|
+
|
|
2431
|
+
// src/primitives/textarea.tsx
|
|
2432
|
+
var import_cn13 = require("cn");
|
|
2433
|
+
var import_jsx_runtime31 = require("react/jsx-runtime");
|
|
2434
|
+
function Textarea({ className, ...props }) {
|
|
2435
|
+
return /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
|
|
2436
|
+
"textarea",
|
|
2437
|
+
{
|
|
2438
|
+
"data-slot": "textarea",
|
|
2439
|
+
className: (0, import_cn13.cn)(
|
|
2440
|
+
"flex field-sizing-content min-h-16 w-full rounded-lg border border-input bg-transparent px-2.5 py-2 text-base transition-colors outline-none placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:bg-input/50 disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 md:text-sm dark:bg-input/30 dark:disabled:bg-input/80 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40",
|
|
2441
|
+
className
|
|
2442
|
+
),
|
|
2443
|
+
...props
|
|
2444
|
+
}
|
|
2445
|
+
);
|
|
2446
|
+
}
|
|
2447
|
+
|
|
2448
|
+
// src/primitives/input-group.tsx
|
|
2449
|
+
var import_jsx_runtime32 = require("react/jsx-runtime");
|
|
2450
|
+
function InputGroup({ className, ...props }) {
|
|
2451
|
+
return /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
|
|
2452
|
+
"div",
|
|
2179
2453
|
{
|
|
2180
|
-
|
|
2181
|
-
|
|
2182
|
-
|
|
2454
|
+
"data-slot": "input-group",
|
|
2455
|
+
role: "group",
|
|
2456
|
+
className: (0, import_cn14.cn)(
|
|
2457
|
+
"group/input-group relative flex h-8 w-full min-w-0 items-center rounded-lg border border-input transition-colors outline-none in-data-[slot=combobox-content]:focus-within:border-inherit in-data-[slot=combobox-content]:focus-within:ring-0 has-disabled:bg-input/50 has-disabled:opacity-50 has-[[data-slot=input-group-control]:focus-visible]:border-ring has-[[data-slot=input-group-control]:focus-visible]:ring-3 has-[[data-slot=input-group-control]:focus-visible]:ring-ring/50 has-[[data-slot][aria-invalid=true]]:border-destructive has-[[data-slot][aria-invalid=true]]:ring-3 has-[[data-slot][aria-invalid=true]]:ring-destructive/20 has-[>[data-align=block-end]]:h-auto has-[>[data-align=block-end]]:flex-col has-[>[data-align=block-start]]:h-auto has-[>[data-align=block-start]]:flex-col has-[>textarea]:h-auto dark:bg-input/30 dark:has-disabled:bg-input/80 dark:has-[[data-slot][aria-invalid=true]]:ring-destructive/40 has-[>[data-align=block-end]]:[&>input]:pt-3 has-[>[data-align=block-start]]:[&>input]:pb-3 has-[>[data-align=inline-end]]:[&>input]:pr-1.5 has-[>[data-align=inline-start]]:[&>input]:pl-1.5",
|
|
2183
2458
|
className
|
|
2184
2459
|
),
|
|
2185
|
-
...props
|
|
2186
|
-
children: [
|
|
2187
|
-
children,
|
|
2188
|
-
/* @__PURE__ */ (0, import_jsx_runtime29.jsxs)(import_dialog2.Dialog.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-open:bg-accent data-open:text-muted-foreground", children: [
|
|
2189
|
-
/* @__PURE__ */ (0, import_jsx_runtime29.jsx)(import_lucide_react7.X, { className: "h-4 w-4" }),
|
|
2190
|
-
/* @__PURE__ */ (0, import_jsx_runtime29.jsx)("span", { className: "sr-only", children: "Close" })
|
|
2191
|
-
] })
|
|
2192
|
-
]
|
|
2460
|
+
...props
|
|
2193
2461
|
}
|
|
2194
|
-
)
|
|
2195
|
-
|
|
2196
|
-
|
|
2197
|
-
|
|
2198
|
-
DialogHeader2.displayName = "DialogHeader";
|
|
2199
|
-
var DialogFooter2 = ({ className, ...props }) => /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
|
|
2200
|
-
"div",
|
|
2462
|
+
);
|
|
2463
|
+
}
|
|
2464
|
+
var inputGroupAddonVariants = (0, import_class_variance_authority13.cva)(
|
|
2465
|
+
"flex h-auto cursor-text items-center justify-center gap-2 py-1.5 text-sm font-medium text-muted-foreground select-none group-data-[disabled=true]/input-group:opacity-50 [&>kbd]:rounded-[calc(var(--radius)-5px)] [&>svg:not([class*='size-'])]:size-4",
|
|
2201
2466
|
{
|
|
2202
|
-
|
|
2203
|
-
|
|
2467
|
+
variants: {
|
|
2468
|
+
align: {
|
|
2469
|
+
"inline-start": "order-first pl-2 has-[>button]:ml-[-0.3rem] has-[>kbd]:ml-[-0.15rem]",
|
|
2470
|
+
"inline-end": "order-last pr-2 has-[>button]:mr-[-0.3rem] has-[>kbd]:mr-[-0.15rem]",
|
|
2471
|
+
"block-start": "order-first w-full justify-start px-2.5 pt-2 group-has-[>input]/input-group:pt-2 [.border-b]:pb-2",
|
|
2472
|
+
"block-end": "order-last w-full justify-start px-2.5 pb-2 group-has-[>input]/input-group:pb-2 [.border-t]:pt-2"
|
|
2473
|
+
}
|
|
2474
|
+
},
|
|
2475
|
+
defaultVariants: {
|
|
2476
|
+
align: "inline-start"
|
|
2477
|
+
}
|
|
2204
2478
|
}
|
|
2205
2479
|
);
|
|
2206
|
-
|
|
2207
|
-
|
|
2208
|
-
|
|
2209
|
-
|
|
2210
|
-
|
|
2211
|
-
|
|
2212
|
-
|
|
2213
|
-
|
|
2214
|
-
|
|
2215
|
-
|
|
2216
|
-
|
|
2217
|
-
|
|
2480
|
+
function InputGroupAddon({
|
|
2481
|
+
className,
|
|
2482
|
+
align = "inline-start",
|
|
2483
|
+
...props
|
|
2484
|
+
}) {
|
|
2485
|
+
return /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
|
|
2486
|
+
"div",
|
|
2487
|
+
{
|
|
2488
|
+
role: "group",
|
|
2489
|
+
"data-slot": "input-group-addon",
|
|
2490
|
+
"data-align": align,
|
|
2491
|
+
className: (0, import_cn14.cn)(inputGroupAddonVariants({ align }), className),
|
|
2492
|
+
onClick: (e) => {
|
|
2493
|
+
if (e.target.closest("button")) {
|
|
2494
|
+
return;
|
|
2495
|
+
}
|
|
2496
|
+
e.currentTarget.parentElement?.querySelector("input")?.focus();
|
|
2497
|
+
},
|
|
2498
|
+
...props
|
|
2499
|
+
}
|
|
2500
|
+
);
|
|
2501
|
+
}
|
|
2502
|
+
var inputGroupButtonVariants = (0, import_class_variance_authority13.cva)(
|
|
2503
|
+
"flex items-center gap-2 text-sm shadow-none",
|
|
2218
2504
|
{
|
|
2219
|
-
|
|
2220
|
-
|
|
2221
|
-
|
|
2505
|
+
variants: {
|
|
2506
|
+
size: {
|
|
2507
|
+
xs: "h-6 gap-1 rounded-[calc(var(--radius)-3px)] px-1.5 [&>svg:not([class*='size-'])]:size-3.5",
|
|
2508
|
+
sm: "",
|
|
2509
|
+
"icon-xs": "size-6 rounded-[calc(var(--radius)-3px)] p-0 has-[>svg]:p-0",
|
|
2510
|
+
"icon-sm": "size-8 p-0 has-[>svg]:p-0"
|
|
2511
|
+
}
|
|
2512
|
+
},
|
|
2513
|
+
defaultVariants: {
|
|
2514
|
+
size: "xs"
|
|
2515
|
+
}
|
|
2222
2516
|
}
|
|
2223
|
-
)
|
|
2224
|
-
DialogDescription2.displayName = "DialogDescription";
|
|
2517
|
+
);
|
|
2225
2518
|
|
|
2226
2519
|
// src/primitives/command.tsx
|
|
2227
|
-
var
|
|
2228
|
-
var
|
|
2229
|
-
|
|
2230
|
-
|
|
2231
|
-
|
|
2232
|
-
|
|
2233
|
-
|
|
2234
|
-
|
|
2235
|
-
),
|
|
2236
|
-
...props
|
|
2237
|
-
}
|
|
2238
|
-
));
|
|
2239
|
-
Command.displayName = import_cmdk.Command.displayName;
|
|
2240
|
-
var CommandInput = React29.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime30.jsxs)("div", { className: "flex items-center border-b px-3", "cmdk-input-wrapper": "", children: [
|
|
2241
|
-
/* @__PURE__ */ (0, import_jsx_runtime30.jsx)(import_lucide_react8.Search, { className: "mr-2 h-4 w-4 shrink-0 opacity-50" }),
|
|
2242
|
-
/* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
|
|
2243
|
-
import_cmdk.Command.Input,
|
|
2520
|
+
var import_lucide_react9 = require("lucide-react");
|
|
2521
|
+
var import_jsx_runtime33 = require("react/jsx-runtime");
|
|
2522
|
+
function Command({
|
|
2523
|
+
className,
|
|
2524
|
+
...props
|
|
2525
|
+
}) {
|
|
2526
|
+
return /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
|
|
2527
|
+
import_cmdk.Command,
|
|
2244
2528
|
{
|
|
2245
|
-
|
|
2246
|
-
className: cn(
|
|
2247
|
-
"flex
|
|
2529
|
+
"data-slot": "command",
|
|
2530
|
+
className: (0, import_cn15.cn)(
|
|
2531
|
+
"flex size-full flex-col overflow-hidden rounded-xl! bg-popover p-1 text-popover-foreground",
|
|
2248
2532
|
className
|
|
2249
2533
|
),
|
|
2250
2534
|
...props
|
|
2251
2535
|
}
|
|
2252
|
-
)
|
|
2253
|
-
|
|
2254
|
-
CommandInput
|
|
2255
|
-
|
|
2256
|
-
|
|
2257
|
-
|
|
2258
|
-
|
|
2259
|
-
|
|
2260
|
-
|
|
2261
|
-
|
|
2262
|
-
|
|
2263
|
-
|
|
2264
|
-
|
|
2265
|
-
|
|
2266
|
-
|
|
2267
|
-
|
|
2268
|
-
|
|
2269
|
-
ref,
|
|
2270
|
-
className: cn(
|
|
2271
|
-
"overflow-hidden p-1 text-foreground [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground",
|
|
2272
|
-
className
|
|
2273
|
-
),
|
|
2274
|
-
...props
|
|
2275
|
-
}
|
|
2276
|
-
));
|
|
2277
|
-
CommandGroup.displayName = import_cmdk.Command.Group.displayName;
|
|
2278
|
-
var CommandSeparator = React29.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
|
|
2279
|
-
import_cmdk.Command.Separator,
|
|
2280
|
-
{
|
|
2281
|
-
ref,
|
|
2282
|
-
className: cn("-mx-1 h-px bg-border", className),
|
|
2283
|
-
...props
|
|
2284
|
-
}
|
|
2285
|
-
));
|
|
2286
|
-
CommandSeparator.displayName = import_cmdk.Command.Separator.displayName;
|
|
2287
|
-
var CommandItem = React29.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
|
|
2288
|
-
import_cmdk.Command.Item,
|
|
2289
|
-
{
|
|
2290
|
-
ref,
|
|
2291
|
-
className: cn(
|
|
2292
|
-
"relative flex cursor-default gap-2 select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none data-[disabled=true]:pointer-events-none data-[selected='true']:bg-accent data-[selected=true]:text-accent-foreground data-[disabled=true]:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",
|
|
2293
|
-
className
|
|
2536
|
+
);
|
|
2537
|
+
}
|
|
2538
|
+
function CommandInput({
|
|
2539
|
+
className,
|
|
2540
|
+
...props
|
|
2541
|
+
}) {
|
|
2542
|
+
return /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("div", { "data-slot": "command-input-wrapper", className: "p-1 pb-0", children: /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)(InputGroup, { className: "h-8! rounded-lg! border-input/30 bg-input/30 shadow-none! *:data-[slot=input-group-addon]:pl-2!", children: [
|
|
2543
|
+
/* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
|
|
2544
|
+
import_cmdk.Command.Input,
|
|
2545
|
+
{
|
|
2546
|
+
"data-slot": "command-input",
|
|
2547
|
+
className: (0, import_cn15.cn)(
|
|
2548
|
+
"w-full text-sm outline-hidden disabled:cursor-not-allowed disabled:opacity-50",
|
|
2549
|
+
className
|
|
2550
|
+
),
|
|
2551
|
+
...props
|
|
2552
|
+
}
|
|
2294
2553
|
),
|
|
2295
|
-
|
|
2296
|
-
}
|
|
2297
|
-
|
|
2298
|
-
|
|
2299
|
-
|
|
2300
|
-
|
|
2301
|
-
|
|
2554
|
+
/* @__PURE__ */ (0, import_jsx_runtime33.jsx)(InputGroupAddon, { children: /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(import_lucide_react9.SearchIcon, { className: "size-4 shrink-0 opacity-50" }) })
|
|
2555
|
+
] }) });
|
|
2556
|
+
}
|
|
2557
|
+
function CommandList({
|
|
2558
|
+
className,
|
|
2559
|
+
...props
|
|
2560
|
+
}) {
|
|
2561
|
+
return /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
|
|
2562
|
+
import_cmdk.Command.List,
|
|
2563
|
+
{
|
|
2564
|
+
"data-slot": "command-list",
|
|
2565
|
+
className: (0, import_cn15.cn)(
|
|
2566
|
+
"no-scrollbar max-h-72 scroll-py-1 overflow-x-hidden overflow-y-auto outline-none",
|
|
2567
|
+
className
|
|
2568
|
+
),
|
|
2569
|
+
...props
|
|
2570
|
+
}
|
|
2571
|
+
);
|
|
2572
|
+
}
|
|
2573
|
+
function CommandEmpty({
|
|
2574
|
+
className,
|
|
2575
|
+
...props
|
|
2576
|
+
}) {
|
|
2577
|
+
return /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
|
|
2578
|
+
import_cmdk.Command.Empty,
|
|
2302
2579
|
{
|
|
2303
|
-
|
|
2580
|
+
"data-slot": "command-empty",
|
|
2581
|
+
className: (0, import_cn15.cn)("py-6 text-center text-sm", className),
|
|
2304
2582
|
...props
|
|
2305
2583
|
}
|
|
2306
2584
|
);
|
|
2307
|
-
}
|
|
2308
|
-
|
|
2585
|
+
}
|
|
2586
|
+
function CommandGroup({
|
|
2587
|
+
className,
|
|
2588
|
+
...props
|
|
2589
|
+
}) {
|
|
2590
|
+
return /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
|
|
2591
|
+
import_cmdk.Command.Group,
|
|
2592
|
+
{
|
|
2593
|
+
"data-slot": "command-group",
|
|
2594
|
+
className: (0, import_cn15.cn)(
|
|
2595
|
+
"overflow-hidden p-1 text-foreground **:[[cmdk-group-heading]]:px-2 **:[[cmdk-group-heading]]:py-1.5 **:[[cmdk-group-heading]]:text-xs **:[[cmdk-group-heading]]:font-medium **:[[cmdk-group-heading]]:text-muted-foreground",
|
|
2596
|
+
className
|
|
2597
|
+
),
|
|
2598
|
+
...props
|
|
2599
|
+
}
|
|
2600
|
+
);
|
|
2601
|
+
}
|
|
2602
|
+
function CommandItem({
|
|
2603
|
+
className,
|
|
2604
|
+
children,
|
|
2605
|
+
...props
|
|
2606
|
+
}) {
|
|
2607
|
+
return /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)(
|
|
2608
|
+
import_cmdk.Command.Item,
|
|
2609
|
+
{
|
|
2610
|
+
"data-slot": "command-item",
|
|
2611
|
+
className: (0, import_cn15.cn)(
|
|
2612
|
+
"group/command-item relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none in-data-[slot=dialog-content]:rounded-lg! data-[disabled=true]:pointer-events-none data-[disabled=true]:opacity-50 data-selected:bg-muted data-selected:text-foreground [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 data-selected:*:[svg]:text-foreground",
|
|
2613
|
+
className
|
|
2614
|
+
),
|
|
2615
|
+
...props,
|
|
2616
|
+
children: [
|
|
2617
|
+
children,
|
|
2618
|
+
/* @__PURE__ */ (0, import_jsx_runtime33.jsx)(import_lucide_react9.CheckIcon, { className: "ml-auto opacity-0 group-has-data-[slot=command-shortcut]/command-item:hidden group-data-[checked=true]/command-item:opacity-100" })
|
|
2619
|
+
]
|
|
2620
|
+
}
|
|
2621
|
+
);
|
|
2622
|
+
}
|
|
2309
2623
|
|
|
2310
2624
|
// src/components/country-select/countries.ts
|
|
2311
2625
|
var COUNTRIES = [
|
|
@@ -2449,8 +2763,8 @@ var isEUCountry = (countryCode) => {
|
|
|
2449
2763
|
};
|
|
2450
2764
|
|
|
2451
2765
|
// src/components/country-select/CountrySelect.tsx
|
|
2452
|
-
var
|
|
2453
|
-
var CountrySelect =
|
|
2766
|
+
var import_jsx_runtime34 = require("react/jsx-runtime");
|
|
2767
|
+
var CountrySelect = React18.forwardRef(
|
|
2454
2768
|
({
|
|
2455
2769
|
value,
|
|
2456
2770
|
onValueChange,
|
|
@@ -2460,53 +2774,58 @@ var CountrySelect = React30.forwardRef(
|
|
|
2460
2774
|
align = "center",
|
|
2461
2775
|
sideOffset = 4
|
|
2462
2776
|
}, ref) => {
|
|
2463
|
-
const [open, setOpen] =
|
|
2464
|
-
const selectedCountry =
|
|
2465
|
-
return /* @__PURE__ */ (0,
|
|
2466
|
-
/* @__PURE__ */ (0,
|
|
2467
|
-
|
|
2777
|
+
const [open, setOpen] = React18.useState(false);
|
|
2778
|
+
const selectedCountry = React18.useMemo(() => COUNTRIES.find((c) => c.code === value), [value]);
|
|
2779
|
+
return /* @__PURE__ */ (0, import_jsx_runtime34.jsxs)(Popover, { open, onOpenChange: setOpen, children: [
|
|
2780
|
+
/* @__PURE__ */ (0, import_jsx_runtime34.jsxs)(
|
|
2781
|
+
PopoverTrigger,
|
|
2468
2782
|
{
|
|
2469
2783
|
ref,
|
|
2470
|
-
|
|
2471
|
-
|
|
2472
|
-
|
|
2473
|
-
|
|
2474
|
-
|
|
2475
|
-
|
|
2476
|
-
|
|
2477
|
-
|
|
2478
|
-
|
|
2479
|
-
|
|
2480
|
-
|
|
2481
|
-
|
|
2482
|
-
|
|
2483
|
-
|
|
2484
|
-
|
|
2784
|
+
render: /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(
|
|
2785
|
+
"button",
|
|
2786
|
+
{
|
|
2787
|
+
type: "button",
|
|
2788
|
+
disabled,
|
|
2789
|
+
"aria-expanded": open,
|
|
2790
|
+
className: cn(
|
|
2791
|
+
// Base layout — consistent with Select trigger
|
|
2792
|
+
"flex w-full items-center justify-between",
|
|
2793
|
+
"rounded-berget-xs border bg-card",
|
|
2794
|
+
"px-4 py-3 text-sm",
|
|
2795
|
+
"transition-colors duration-200",
|
|
2796
|
+
"focus-visible:outline-none focus-visible:ring-0",
|
|
2797
|
+
"focus-visible:ring-offset-0 focus-visible:border-berget-form-focus-border",
|
|
2798
|
+
"disabled:cursor-not-allowed disabled:opacity-50",
|
|
2799
|
+
// Default border & hover matching Select variant "default"
|
|
2800
|
+
"border-berget-border-interactive hover:bg-berget-surface-hover",
|
|
2801
|
+
className
|
|
2802
|
+
)
|
|
2803
|
+
}
|
|
2485
2804
|
),
|
|
2486
2805
|
children: [
|
|
2487
|
-
/* @__PURE__ */ (0,
|
|
2488
|
-
/* @__PURE__ */ (0,
|
|
2489
|
-
/* @__PURE__ */ (0,
|
|
2490
|
-
/* @__PURE__ */ (0,
|
|
2806
|
+
/* @__PURE__ */ (0, import_jsx_runtime34.jsx)("div", { className: "flex items-center gap-2 min-w-0 flex-1", children: selectedCountry ? /* @__PURE__ */ (0, import_jsx_runtime34.jsxs)(import_jsx_runtime34.Fragment, { children: [
|
|
2807
|
+
/* @__PURE__ */ (0, import_jsx_runtime34.jsx)("span", { className: "text-xl flex-shrink-0", children: selectedCountry.flag }),
|
|
2808
|
+
/* @__PURE__ */ (0, import_jsx_runtime34.jsx)("span", { className: "truncate", children: selectedCountry.name }),
|
|
2809
|
+
/* @__PURE__ */ (0, import_jsx_runtime34.jsxs)("span", { className: "text-berget-muted-foreground text-xs flex-shrink-0", children: [
|
|
2491
2810
|
"(",
|
|
2492
2811
|
selectedCountry.code,
|
|
2493
2812
|
")"
|
|
2494
2813
|
] })
|
|
2495
|
-
] }) : /* @__PURE__ */ (0,
|
|
2496
|
-
/* @__PURE__ */ (0,
|
|
2814
|
+
] }) : /* @__PURE__ */ (0, import_jsx_runtime34.jsxs)(import_jsx_runtime34.Fragment, { children: [
|
|
2815
|
+
/* @__PURE__ */ (0, import_jsx_runtime34.jsx)(
|
|
2497
2816
|
Icon,
|
|
2498
2817
|
{
|
|
2499
|
-
icon:
|
|
2818
|
+
icon: import_lucide_react10.Globe,
|
|
2500
2819
|
size: 16,
|
|
2501
2820
|
className: "flex-shrink-0 text-berget-muted-foreground"
|
|
2502
2821
|
}
|
|
2503
2822
|
),
|
|
2504
|
-
/* @__PURE__ */ (0,
|
|
2823
|
+
/* @__PURE__ */ (0, import_jsx_runtime34.jsx)("span", { className: "text-berget-muted-foreground truncate", children: placeholder })
|
|
2505
2824
|
] }) }),
|
|
2506
|
-
/* @__PURE__ */ (0,
|
|
2825
|
+
/* @__PURE__ */ (0, import_jsx_runtime34.jsx)(
|
|
2507
2826
|
Icon,
|
|
2508
2827
|
{
|
|
2509
|
-
icon:
|
|
2828
|
+
icon: import_lucide_react10.ChevronDown,
|
|
2510
2829
|
size: 16,
|
|
2511
2830
|
className: cn(
|
|
2512
2831
|
"flex-shrink-0 text-berget-muted-foreground",
|
|
@@ -2517,18 +2836,18 @@ var CountrySelect = React30.forwardRef(
|
|
|
2517
2836
|
)
|
|
2518
2837
|
]
|
|
2519
2838
|
}
|
|
2520
|
-
)
|
|
2521
|
-
/* @__PURE__ */ (0,
|
|
2839
|
+
),
|
|
2840
|
+
/* @__PURE__ */ (0, import_jsx_runtime34.jsx)(
|
|
2522
2841
|
PopoverContent,
|
|
2523
2842
|
{
|
|
2524
2843
|
align,
|
|
2525
2844
|
sideOffset,
|
|
2526
2845
|
className: "w-[var(--radix-popover-trigger-width)] p-0",
|
|
2527
|
-
children: /* @__PURE__ */ (0,
|
|
2528
|
-
/* @__PURE__ */ (0,
|
|
2529
|
-
/* @__PURE__ */ (0,
|
|
2530
|
-
/* @__PURE__ */ (0,
|
|
2531
|
-
/* @__PURE__ */ (0,
|
|
2846
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime34.jsxs)(Command, { children: [
|
|
2847
|
+
/* @__PURE__ */ (0, import_jsx_runtime34.jsx)(CommandInput, { placeholder: "Search country..." }),
|
|
2848
|
+
/* @__PURE__ */ (0, import_jsx_runtime34.jsxs)(CommandList, { children: [
|
|
2849
|
+
/* @__PURE__ */ (0, import_jsx_runtime34.jsx)(CommandEmpty, { children: "No countries found." }),
|
|
2850
|
+
/* @__PURE__ */ (0, import_jsx_runtime34.jsx)(CommandGroup, { children: COUNTRIES.map((country) => /* @__PURE__ */ (0, import_jsx_runtime34.jsxs)(
|
|
2532
2851
|
CommandItem,
|
|
2533
2852
|
{
|
|
2534
2853
|
value: `${country.name} ${country.code}`,
|
|
@@ -2542,12 +2861,12 @@ var CountrySelect = React30.forwardRef(
|
|
|
2542
2861
|
value === country.code && "bg-berget-brand-granite-800/40"
|
|
2543
2862
|
),
|
|
2544
2863
|
children: [
|
|
2545
|
-
/* @__PURE__ */ (0,
|
|
2546
|
-
/* @__PURE__ */ (0,
|
|
2547
|
-
/* @__PURE__ */ (0,
|
|
2548
|
-
/* @__PURE__ */ (0,
|
|
2864
|
+
/* @__PURE__ */ (0, import_jsx_runtime34.jsx)("span", { className: "text-xl flex-shrink-0", children: country.flag }),
|
|
2865
|
+
/* @__PURE__ */ (0, import_jsx_runtime34.jsxs)("div", { className: "flex-1 min-w-0", children: [
|
|
2866
|
+
/* @__PURE__ */ (0, import_jsx_runtime34.jsx)("div", { className: "text-sm truncate", children: country.name }),
|
|
2867
|
+
/* @__PURE__ */ (0, import_jsx_runtime34.jsx)("div", { className: "text-xs text-berget-muted-foreground", children: country.code })
|
|
2549
2868
|
] }),
|
|
2550
|
-
value === country.code && /* @__PURE__ */ (0,
|
|
2869
|
+
value === country.code && /* @__PURE__ */ (0, import_jsx_runtime34.jsx)("div", { className: "w-2 h-2 rounded-full bg-berget-brand-granite-400 flex-shrink-0" })
|
|
2551
2870
|
]
|
|
2552
2871
|
},
|
|
2553
2872
|
country.code
|
|
@@ -2562,32 +2881,10 @@ var CountrySelect = React30.forwardRef(
|
|
|
2562
2881
|
CountrySelect.displayName = "CountrySelect";
|
|
2563
2882
|
|
|
2564
2883
|
// src/components/text-area/TextArea.tsx
|
|
2565
|
-
var
|
|
2566
|
-
var
|
|
2567
|
-
|
|
2568
|
-
|
|
2569
|
-
var React31 = __toESM(require("react"), 1);
|
|
2570
|
-
var import_jsx_runtime32 = require("react/jsx-runtime");
|
|
2571
|
-
var Textarea = React31.forwardRef(
|
|
2572
|
-
({ className, ...props }, ref) => {
|
|
2573
|
-
return /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
|
|
2574
|
-
"textarea",
|
|
2575
|
-
{
|
|
2576
|
-
className: cn(
|
|
2577
|
-
"flex min-h-[80px] w-full rounded-md border border-input bg-background px-3 py-2 text-base ring-offset-background placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",
|
|
2578
|
-
className
|
|
2579
|
-
),
|
|
2580
|
-
ref,
|
|
2581
|
-
...props
|
|
2582
|
-
}
|
|
2583
|
-
);
|
|
2584
|
-
}
|
|
2585
|
-
);
|
|
2586
|
-
Textarea.displayName = "Textarea";
|
|
2587
|
-
|
|
2588
|
-
// src/components/text-area/TextArea.tsx
|
|
2589
|
-
var import_jsx_runtime33 = require("react/jsx-runtime");
|
|
2590
|
-
var textAreaVariants = (0, import_class_variance_authority12.cva)(
|
|
2884
|
+
var React19 = __toESM(require("react"), 1);
|
|
2885
|
+
var import_class_variance_authority14 = require("class-variance-authority");
|
|
2886
|
+
var import_jsx_runtime35 = require("react/jsx-runtime");
|
|
2887
|
+
var textAreaVariants = (0, import_class_variance_authority14.cva)(
|
|
2591
2888
|
"rounded-berget-xs bg-card px-4 py-3 transition-colors duration-200 focus-visible:border-berget-form-focus-border focus-visible:ring-0 focus-visible:ring-offset-0 resize-y",
|
|
2592
2889
|
{
|
|
2593
2890
|
variants: {
|
|
@@ -2609,7 +2906,7 @@ var textAreaVariants = (0, import_class_variance_authority12.cva)(
|
|
|
2609
2906
|
}
|
|
2610
2907
|
}
|
|
2611
2908
|
);
|
|
2612
|
-
var TextArea =
|
|
2909
|
+
var TextArea = React19.forwardRef(
|
|
2613
2910
|
({
|
|
2614
2911
|
className,
|
|
2615
2912
|
variant,
|
|
@@ -2629,13 +2926,13 @@ var TextArea = React32.forwardRef(
|
|
|
2629
2926
|
actionButton,
|
|
2630
2927
|
...props
|
|
2631
2928
|
}, ref) => {
|
|
2632
|
-
const generatedId =
|
|
2929
|
+
const generatedId = React19.useId();
|
|
2633
2930
|
const textareaId = id || generatedId;
|
|
2634
2931
|
const errorId = `${textareaId}-error`;
|
|
2635
2932
|
const descriptionId = `${textareaId}-description`;
|
|
2636
2933
|
const characterCount = typeof value === "string" ? value.length : 0;
|
|
2637
|
-
return /* @__PURE__ */ (0,
|
|
2638
|
-
label && /* @__PURE__ */ (0,
|
|
2934
|
+
return /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)("div", { className: "flex flex-col gap-2", children: [
|
|
2935
|
+
label && /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(
|
|
2639
2936
|
"label",
|
|
2640
2937
|
{
|
|
2641
2938
|
htmlFor: textareaId,
|
|
@@ -2647,9 +2944,9 @@ var TextArea = React32.forwardRef(
|
|
|
2647
2944
|
children: label
|
|
2648
2945
|
}
|
|
2649
2946
|
),
|
|
2650
|
-
/* @__PURE__ */ (0,
|
|
2651
|
-
icon && /* @__PURE__ */ (0,
|
|
2652
|
-
/* @__PURE__ */ (0,
|
|
2947
|
+
/* @__PURE__ */ (0, import_jsx_runtime35.jsxs)("div", { className: "relative", children: [
|
|
2948
|
+
icon && /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("div", { className: "absolute left-2 top-1/2 -translate-y-1/2", children: icon }),
|
|
2949
|
+
/* @__PURE__ */ (0, import_jsx_runtime35.jsx)(
|
|
2653
2950
|
Textarea,
|
|
2654
2951
|
{
|
|
2655
2952
|
ref,
|
|
@@ -2674,13 +2971,13 @@ var TextArea = React32.forwardRef(
|
|
|
2674
2971
|
...props
|
|
2675
2972
|
}
|
|
2676
2973
|
),
|
|
2677
|
-
secondaryIcon && /* @__PURE__ */ (0,
|
|
2678
|
-
actionButton && /* @__PURE__ */ (0,
|
|
2974
|
+
secondaryIcon && /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("div", { className: "absolute right-12 top-1/2 -translate-y-1/2", children: secondaryIcon }),
|
|
2975
|
+
actionButton && /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("div", { className: "absolute right-2 top-1/2 -translate-y-1/2", children: actionButton })
|
|
2679
2976
|
] }),
|
|
2680
|
-
(description || error || showCount && maxLength) && /* @__PURE__ */ (0,
|
|
2681
|
-
description && /* @__PURE__ */ (0,
|
|
2682
|
-
(error || showCount && maxLength) && /* @__PURE__ */ (0,
|
|
2683
|
-
showCount && maxLength && /* @__PURE__ */ (0,
|
|
2977
|
+
(description || error || showCount && maxLength) && /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)("div", { className: "flex items-center justify-between gap-2", children: [
|
|
2978
|
+
description && /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(Typography, { variant: "xs", color: "muted", id: descriptionId, children: description }),
|
|
2979
|
+
(error || showCount && maxLength) && /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)("div", { className: "flex items-center gap-2 ml-auto", children: [
|
|
2980
|
+
showCount && maxLength && /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)(
|
|
2684
2981
|
Typography,
|
|
2685
2982
|
{
|
|
2686
2983
|
variant: "xs",
|
|
@@ -2694,7 +2991,7 @@ var TextArea = React32.forwardRef(
|
|
|
2694
2991
|
]
|
|
2695
2992
|
}
|
|
2696
2993
|
),
|
|
2697
|
-
error && /* @__PURE__ */ (0,
|
|
2994
|
+
error && /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(
|
|
2698
2995
|
Typography,
|
|
2699
2996
|
{
|
|
2700
2997
|
variant: "xs",
|
|
@@ -2711,27 +3008,34 @@ var TextArea = React32.forwardRef(
|
|
|
2711
3008
|
TextArea.displayName = "TextArea";
|
|
2712
3009
|
|
|
2713
3010
|
// src/primitives/label.tsx
|
|
2714
|
-
var
|
|
2715
|
-
var
|
|
2716
|
-
|
|
2717
|
-
|
|
2718
|
-
|
|
2719
|
-
|
|
2720
|
-
|
|
2721
|
-
|
|
3011
|
+
var import_cn16 = require("cn");
|
|
3012
|
+
var import_jsx_runtime36 = require("react/jsx-runtime");
|
|
3013
|
+
function Label({ className, ...props }) {
|
|
3014
|
+
return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
3015
|
+
"label",
|
|
3016
|
+
{
|
|
3017
|
+
"data-slot": "label",
|
|
3018
|
+
className: (0, import_cn16.cn)(
|
|
3019
|
+
"flex items-center gap-2 text-sm leading-none font-medium select-none group-data-[disabled=true]:pointer-events-none group-data-[disabled=true]:opacity-50 peer-disabled:cursor-not-allowed peer-disabled:opacity-50",
|
|
3020
|
+
className
|
|
3021
|
+
),
|
|
3022
|
+
...props
|
|
3023
|
+
}
|
|
3024
|
+
);
|
|
3025
|
+
}
|
|
2722
3026
|
|
|
2723
3027
|
// src/primitives/field.tsx
|
|
2724
3028
|
var import_react = require("react");
|
|
2725
|
-
var
|
|
2726
|
-
var
|
|
3029
|
+
var import_class_variance_authority15 = require("class-variance-authority");
|
|
3030
|
+
var import_cn17 = require("cn");
|
|
3031
|
+
var import_jsx_runtime37 = require("react/jsx-runtime");
|
|
2727
3032
|
function FieldSet({ className, ...props }) {
|
|
2728
|
-
return /* @__PURE__ */ (0,
|
|
3033
|
+
return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
|
|
2729
3034
|
"fieldset",
|
|
2730
3035
|
{
|
|
2731
3036
|
"data-slot": "field-set",
|
|
2732
|
-
className: cn(
|
|
2733
|
-
"flex flex-col gap-
|
|
2734
|
-
"has-[>[data-slot=checkbox-group]]:gap-3 has-[>[data-slot=radio-group]]:gap-3",
|
|
3037
|
+
className: (0, import_cn17.cn)(
|
|
3038
|
+
"flex flex-col gap-4 has-[>[data-slot=checkbox-group]]:gap-3 has-[>[data-slot=radio-group]]:gap-3",
|
|
2735
3039
|
className
|
|
2736
3040
|
),
|
|
2737
3041
|
...props
|
|
@@ -2743,15 +3047,13 @@ function FieldLegend({
|
|
|
2743
3047
|
variant = "legend",
|
|
2744
3048
|
...props
|
|
2745
3049
|
}) {
|
|
2746
|
-
return /* @__PURE__ */ (0,
|
|
3050
|
+
return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
|
|
2747
3051
|
"legend",
|
|
2748
3052
|
{
|
|
2749
3053
|
"data-slot": "field-legend",
|
|
2750
3054
|
"data-variant": variant,
|
|
2751
|
-
className: cn(
|
|
2752
|
-
"mb-
|
|
2753
|
-
"data-[variant=legend]:text-base",
|
|
2754
|
-
"data-[variant=label]:text-sm",
|
|
3055
|
+
className: (0, import_cn17.cn)(
|
|
3056
|
+
"mb-1.5 font-medium data-[variant=label]:text-sm data-[variant=legend]:text-base",
|
|
2755
3057
|
className
|
|
2756
3058
|
),
|
|
2757
3059
|
...props
|
|
@@ -2759,34 +3061,26 @@ function FieldLegend({
|
|
|
2759
3061
|
);
|
|
2760
3062
|
}
|
|
2761
3063
|
function FieldGroup({ className, ...props }) {
|
|
2762
|
-
return /* @__PURE__ */ (0,
|
|
3064
|
+
return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
|
|
2763
3065
|
"div",
|
|
2764
3066
|
{
|
|
2765
3067
|
"data-slot": "field-group",
|
|
2766
|
-
className: cn(
|
|
2767
|
-
"group/field-group @container/field-group flex w-full flex-col gap-
|
|
3068
|
+
className: (0, import_cn17.cn)(
|
|
3069
|
+
"group/field-group @container/field-group flex w-full flex-col gap-5 data-[slot=checkbox-group]:gap-3 *:data-[slot=field-group]:gap-4",
|
|
2768
3070
|
className
|
|
2769
3071
|
),
|
|
2770
3072
|
...props
|
|
2771
3073
|
}
|
|
2772
3074
|
);
|
|
2773
3075
|
}
|
|
2774
|
-
var fieldVariants = (0,
|
|
2775
|
-
"group/field data-[invalid=true]:text-
|
|
3076
|
+
var fieldVariants = (0, import_class_variance_authority15.cva)(
|
|
3077
|
+
"group/field flex w-full gap-2 data-[invalid=true]:text-destructive",
|
|
2776
3078
|
{
|
|
2777
3079
|
variants: {
|
|
2778
3080
|
orientation: {
|
|
2779
|
-
vertical:
|
|
2780
|
-
horizontal: [
|
|
2781
|
-
|
|
2782
|
-
"[&>[data-slot=field-label]]:flex-auto",
|
|
2783
|
-
"has-[>[data-slot=field-content]]:[&>[role=checkbox],[role=radio]]:mt-px has-[>[data-slot=field-content]]:items-start"
|
|
2784
|
-
],
|
|
2785
|
-
responsive: [
|
|
2786
|
-
"@md/field-group:flex-row @md/field-group:items-center @md/field-group:[&>*]:w-auto flex-col [&>*]:w-full [&>.sr-only]:w-auto",
|
|
2787
|
-
"@md/field-group:[&>[data-slot=field-label]]:flex-auto",
|
|
2788
|
-
"@md/field-group:has-[>[data-slot=field-content]]:items-start @md/field-group:has-[>[data-slot=field-content]]:[&>[role=checkbox],[role=radio]]:mt-px"
|
|
2789
|
-
]
|
|
3081
|
+
vertical: "flex-col *:w-full [&>.sr-only]:w-auto",
|
|
3082
|
+
horizontal: "flex-row items-center has-[>[data-slot=field-content]]:items-start *:data-[slot=field-label]:flex-auto has-[>[data-slot=field-content]]:[&>[role=checkbox],[role=radio]]:mt-px",
|
|
3083
|
+
responsive: "flex-col *:w-full @md/field-group:flex-row @md/field-group:items-center @md/field-group:*:w-auto @md/field-group:has-[>[data-slot=field-content]]:items-start @md/field-group:*:data-[slot=field-label]:flex-auto [&>.sr-only]:w-auto @md/field-group:has-[>[data-slot=field-content]]:[&>[role=checkbox],[role=radio]]:mt-px"
|
|
2790
3084
|
}
|
|
2791
3085
|
},
|
|
2792
3086
|
defaultVariants: {
|
|
@@ -2799,36 +3093,41 @@ function Field({
|
|
|
2799
3093
|
orientation = "vertical",
|
|
2800
3094
|
...props
|
|
2801
3095
|
}) {
|
|
2802
|
-
return /* @__PURE__ */ (0,
|
|
3096
|
+
return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
|
|
2803
3097
|
"div",
|
|
2804
3098
|
{
|
|
2805
3099
|
role: "group",
|
|
2806
3100
|
"data-slot": "field",
|
|
2807
3101
|
"data-orientation": orientation,
|
|
2808
|
-
className: cn(fieldVariants({ orientation }), className),
|
|
3102
|
+
className: (0, import_cn17.cn)(fieldVariants({ orientation }), className),
|
|
2809
3103
|
...props
|
|
2810
3104
|
}
|
|
2811
3105
|
);
|
|
2812
3106
|
}
|
|
2813
3107
|
function FieldContent({ className, ...props }) {
|
|
2814
|
-
return /* @__PURE__ */ (0,
|
|
3108
|
+
return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
|
|
2815
3109
|
"div",
|
|
2816
3110
|
{
|
|
2817
3111
|
"data-slot": "field-content",
|
|
2818
|
-
className:
|
|
3112
|
+
className: (0, import_cn17.cn)(
|
|
3113
|
+
"group/field-content flex flex-1 flex-col gap-0.5 leading-snug",
|
|
3114
|
+
className
|
|
3115
|
+
),
|
|
2819
3116
|
...props
|
|
2820
3117
|
}
|
|
2821
3118
|
);
|
|
2822
3119
|
}
|
|
2823
|
-
function FieldLabel({
|
|
2824
|
-
|
|
3120
|
+
function FieldLabel({
|
|
3121
|
+
className,
|
|
3122
|
+
...props
|
|
3123
|
+
}) {
|
|
3124
|
+
return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
|
|
2825
3125
|
Label,
|
|
2826
3126
|
{
|
|
2827
3127
|
"data-slot": "field-label",
|
|
2828
|
-
className: cn(
|
|
2829
|
-
"group/field-label peer/field-label flex w-fit gap-2 leading-snug
|
|
2830
|
-
"has-[>[data-slot=field]]:w-full has-[>[data-slot=field]]:flex-col
|
|
2831
|
-
"has-data-[state=checked]:bg-primary/5 has-data-[state=checked]:border-primary dark:has-data-[state=checked]:bg-primary/10",
|
|
3128
|
+
className: (0, import_cn17.cn)(
|
|
3129
|
+
"group/field-label peer/field-label flex w-fit gap-2 leading-snug group-data-[disabled=true]/field:opacity-50 has-data-checked:border-primary/30 has-data-checked:bg-primary/5 has-[>[data-slot=field]]:rounded-lg has-[>[data-slot=field]]:border has-[>[data-slot=field]]:not-has-[:disabled,[data-disabled]]:hover:bg-muted/50 has-[>[data-slot=field]]:has-[:focus-visible]:border-ring has-[>[data-slot=field]]:has-[:focus-visible]:ring-3 has-[>[data-slot=field]]:has-[:focus-visible]:ring-ring/50 *:data-[slot=field]:p-2.5 dark:has-data-checked:border-primary/20 dark:has-data-checked:bg-primary/10",
|
|
3130
|
+
"has-[>[data-slot=field]]:w-full has-[>[data-slot=field]]:flex-col",
|
|
2832
3131
|
className
|
|
2833
3132
|
),
|
|
2834
3133
|
...props
|
|
@@ -2836,12 +3135,12 @@ function FieldLabel({ className, ...props }) {
|
|
|
2836
3135
|
);
|
|
2837
3136
|
}
|
|
2838
3137
|
function FieldTitle({ className, ...props }) {
|
|
2839
|
-
return /* @__PURE__ */ (0,
|
|
3138
|
+
return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
|
|
2840
3139
|
"div",
|
|
2841
3140
|
{
|
|
2842
3141
|
"data-slot": "field-label",
|
|
2843
|
-
className: cn(
|
|
2844
|
-
"flex w-fit items-center gap-2 text-sm font-medium
|
|
3142
|
+
className: (0, import_cn17.cn)(
|
|
3143
|
+
"flex w-fit items-center gap-2 text-sm font-medium group-data-[disabled=true]/field:opacity-50",
|
|
2845
3144
|
className
|
|
2846
3145
|
),
|
|
2847
3146
|
...props
|
|
@@ -2849,14 +3148,14 @@ function FieldTitle({ className, ...props }) {
|
|
|
2849
3148
|
);
|
|
2850
3149
|
}
|
|
2851
3150
|
function FieldDescription({ className, ...props }) {
|
|
2852
|
-
return /* @__PURE__ */ (0,
|
|
3151
|
+
return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
|
|
2853
3152
|
"p",
|
|
2854
3153
|
{
|
|
2855
3154
|
"data-slot": "field-description",
|
|
2856
|
-
className: cn(
|
|
2857
|
-
"text-
|
|
2858
|
-
"
|
|
2859
|
-
"[&>a
|
|
3155
|
+
className: (0, import_cn17.cn)(
|
|
3156
|
+
"text-left text-sm leading-normal font-normal text-muted-foreground group-has-data-horizontal/field:text-balance [[data-variant=legend]+&]:-mt-1.5",
|
|
3157
|
+
"last:mt-0 nth-last-2:-mt-1",
|
|
3158
|
+
"[&>a]:underline [&>a]:underline-offset-4 [&>a:hover]:text-primary",
|
|
2860
3159
|
className
|
|
2861
3160
|
),
|
|
2862
3161
|
...props
|
|
@@ -2868,22 +3167,22 @@ function FieldSeparator({
|
|
|
2868
3167
|
className,
|
|
2869
3168
|
...props
|
|
2870
3169
|
}) {
|
|
2871
|
-
return /* @__PURE__ */ (0,
|
|
3170
|
+
return /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(
|
|
2872
3171
|
"div",
|
|
2873
3172
|
{
|
|
2874
3173
|
"data-slot": "field-separator",
|
|
2875
3174
|
"data-content": !!children,
|
|
2876
|
-
className: cn(
|
|
3175
|
+
className: (0, import_cn17.cn)(
|
|
2877
3176
|
"relative -my-2 h-5 text-sm group-data-[variant=outline]/field-group:-mb-2",
|
|
2878
3177
|
className
|
|
2879
3178
|
),
|
|
2880
3179
|
...props,
|
|
2881
3180
|
children: [
|
|
2882
|
-
/* @__PURE__ */ (0,
|
|
2883
|
-
children && /* @__PURE__ */ (0,
|
|
3181
|
+
/* @__PURE__ */ (0, import_jsx_runtime37.jsx)(Separator, { className: "absolute inset-0 top-1/2" }),
|
|
3182
|
+
children && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
|
|
2884
3183
|
"span",
|
|
2885
3184
|
{
|
|
2886
|
-
className: "
|
|
3185
|
+
className: "relative mx-auto block w-fit bg-background px-2 text-muted-foreground",
|
|
2887
3186
|
"data-slot": "field-separator-content",
|
|
2888
3187
|
children
|
|
2889
3188
|
}
|
|
@@ -2902,23 +3201,28 @@ function FieldError({
|
|
|
2902
3201
|
if (children) {
|
|
2903
3202
|
return children;
|
|
2904
3203
|
}
|
|
2905
|
-
if (!errors) {
|
|
3204
|
+
if (!errors?.length) {
|
|
2906
3205
|
return null;
|
|
2907
3206
|
}
|
|
2908
|
-
|
|
2909
|
-
|
|
3207
|
+
const uniqueErrors = [
|
|
3208
|
+
...new Map(errors.map((error) => [error?.message, error])).values()
|
|
3209
|
+
];
|
|
3210
|
+
if (uniqueErrors?.length == 1) {
|
|
3211
|
+
return uniqueErrors[0]?.message;
|
|
2910
3212
|
}
|
|
2911
|
-
return /* @__PURE__ */ (0,
|
|
3213
|
+
return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("ul", { className: "ml-4 flex list-disc flex-col gap-1", children: uniqueErrors.map(
|
|
3214
|
+
(error, index) => error?.message && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("li", { children: error.message }, index)
|
|
3215
|
+
) });
|
|
2912
3216
|
}, [children, errors]);
|
|
2913
3217
|
if (!content) {
|
|
2914
3218
|
return null;
|
|
2915
3219
|
}
|
|
2916
|
-
return /* @__PURE__ */ (0,
|
|
3220
|
+
return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
|
|
2917
3221
|
"div",
|
|
2918
3222
|
{
|
|
2919
3223
|
role: "alert",
|
|
2920
3224
|
"data-slot": "field-error",
|
|
2921
|
-
className: cn("text-
|
|
3225
|
+
className: (0, import_cn17.cn)("text-sm font-normal text-destructive", className),
|
|
2922
3226
|
...props,
|
|
2923
3227
|
children: content
|
|
2924
3228
|
}
|
|
@@ -2926,11 +3230,11 @@ function FieldError({
|
|
|
2926
3230
|
}
|
|
2927
3231
|
|
|
2928
3232
|
// src/components/link/Link.tsx
|
|
2929
|
-
var
|
|
2930
|
-
var
|
|
2931
|
-
var
|
|
2932
|
-
var
|
|
2933
|
-
var linkVariants = (0,
|
|
3233
|
+
var React20 = __toESM(require("react"), 1);
|
|
3234
|
+
var import_class_variance_authority16 = require("class-variance-authority");
|
|
3235
|
+
var import_lucide_react11 = require("lucide-react");
|
|
3236
|
+
var import_jsx_runtime38 = require("react/jsx-runtime");
|
|
3237
|
+
var linkVariants = (0, import_class_variance_authority16.cva)(
|
|
2934
3238
|
"inline-flex cursor-pointer items-center gap-2 transition-all duration-200 focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background disabled:pointer-events-none disabled:opacity-50",
|
|
2935
3239
|
{
|
|
2936
3240
|
variants: {
|
|
@@ -2954,7 +3258,7 @@ var linkVariants = (0, import_class_variance_authority15.cva)(
|
|
|
2954
3258
|
}
|
|
2955
3259
|
}
|
|
2956
3260
|
);
|
|
2957
|
-
var Link =
|
|
3261
|
+
var Link = React20.forwardRef(
|
|
2958
3262
|
({
|
|
2959
3263
|
className,
|
|
2960
3264
|
variant,
|
|
@@ -2967,7 +3271,7 @@ var Link = React34.forwardRef(
|
|
|
2967
3271
|
...props
|
|
2968
3272
|
}, ref) => {
|
|
2969
3273
|
const isExternal = external || typeof props.href === "string" && (props.href.startsWith("http://") || props.href.startsWith("https://") || props.href.startsWith("mailto:") || props.href.startsWith("tel:"));
|
|
2970
|
-
return /* @__PURE__ */ (0,
|
|
3274
|
+
return /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)(
|
|
2971
3275
|
"a",
|
|
2972
3276
|
{
|
|
2973
3277
|
ref,
|
|
@@ -2983,8 +3287,8 @@ var Link = React34.forwardRef(
|
|
|
2983
3287
|
},
|
|
2984
3288
|
children: [
|
|
2985
3289
|
children,
|
|
2986
|
-
icon && /* @__PURE__ */ (0,
|
|
2987
|
-
showExternalIcon && isExternal && !disabled && /* @__PURE__ */ (0,
|
|
3290
|
+
icon && /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("span", { className: "inline-flex items-center", children: icon }),
|
|
3291
|
+
showExternalIcon && isExternal && !disabled && /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("span", { className: "inline-flex items-center ml-1 opacity-60", "aria-hidden": "true", children: /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(Icon, { icon: import_lucide_react11.ExternalLink, size: 16 }) })
|
|
2988
3292
|
]
|
|
2989
3293
|
}
|
|
2990
3294
|
);
|
|
@@ -2993,11 +3297,11 @@ var Link = React34.forwardRef(
|
|
|
2993
3297
|
Link.displayName = "Link";
|
|
2994
3298
|
|
|
2995
3299
|
// src/components/container/Container.tsx
|
|
2996
|
-
var
|
|
3300
|
+
var React21 = __toESM(require("react"), 1);
|
|
2997
3301
|
var import_merge_props2 = require("@base-ui/react/merge-props");
|
|
2998
3302
|
var import_use_render2 = require("@base-ui/react/use-render");
|
|
2999
|
-
var
|
|
3000
|
-
var containerVariants = (0,
|
|
3303
|
+
var import_class_variance_authority17 = require("class-variance-authority");
|
|
3304
|
+
var containerVariants = (0, import_class_variance_authority17.cva)("w-full mx-auto", {
|
|
3001
3305
|
variants: {
|
|
3002
3306
|
size: {
|
|
3003
3307
|
sm: "max-w-3xl",
|
|
@@ -3018,7 +3322,7 @@ var containerVariants = (0, import_class_variance_authority16.cva)("w-full mx-au
|
|
|
3018
3322
|
padding: "md"
|
|
3019
3323
|
}
|
|
3020
3324
|
});
|
|
3021
|
-
var Container =
|
|
3325
|
+
var Container = React21.forwardRef(
|
|
3022
3326
|
({ className, size, padding, asChild = false, children, ...props }, ref) => {
|
|
3023
3327
|
return (0, import_use_render2.useRender)({
|
|
3024
3328
|
ref,
|
|
@@ -3037,11 +3341,11 @@ var Container = React35.forwardRef(
|
|
|
3037
3341
|
Container.displayName = "Container";
|
|
3038
3342
|
|
|
3039
3343
|
// src/components/grid/Grid.tsx
|
|
3040
|
-
var
|
|
3041
|
-
var
|
|
3344
|
+
var React22 = __toESM(require("react"), 1);
|
|
3345
|
+
var import_class_variance_authority18 = require("class-variance-authority");
|
|
3042
3346
|
var import_merge_props3 = require("@base-ui/react/merge-props");
|
|
3043
3347
|
var import_use_render3 = require("@base-ui/react/use-render");
|
|
3044
|
-
var gridVariants = (0,
|
|
3348
|
+
var gridVariants = (0, import_class_variance_authority18.cva)("grid", {
|
|
3045
3349
|
variants: {
|
|
3046
3350
|
align: {
|
|
3047
3351
|
start: "items-start",
|
|
@@ -3063,7 +3367,7 @@ var gridVariants = (0, import_class_variance_authority17.cva)("grid", {
|
|
|
3063
3367
|
justify: "start"
|
|
3064
3368
|
}
|
|
3065
3369
|
});
|
|
3066
|
-
var Grid =
|
|
3370
|
+
var Grid = React22.forwardRef(
|
|
3067
3371
|
({ className, align, justify, cols, rows, gap, gapX, gapY, asChild = false, children, ...props }, ref) => {
|
|
3068
3372
|
return (0, import_use_render3.useRender)({
|
|
3069
3373
|
ref,
|
|
@@ -3090,11 +3394,11 @@ var Grid = React36.forwardRef(
|
|
|
3090
3394
|
Grid.displayName = "Grid";
|
|
3091
3395
|
|
|
3092
3396
|
// src/components/box/Box.tsx
|
|
3093
|
-
var
|
|
3094
|
-
var
|
|
3397
|
+
var React23 = __toESM(require("react"), 1);
|
|
3398
|
+
var import_class_variance_authority19 = require("class-variance-authority");
|
|
3095
3399
|
var import_merge_props4 = require("@base-ui/react/merge-props");
|
|
3096
3400
|
var import_use_render4 = require("@base-ui/react/use-render");
|
|
3097
|
-
var boxVariants = (0,
|
|
3401
|
+
var boxVariants = (0, import_class_variance_authority19.cva)("flex", {
|
|
3098
3402
|
variants: {
|
|
3099
3403
|
direction: {
|
|
3100
3404
|
row: "flex-row",
|
|
@@ -3130,7 +3434,7 @@ var boxVariants = (0, import_class_variance_authority18.cva)("flex", {
|
|
|
3130
3434
|
wrap: "nowrap"
|
|
3131
3435
|
}
|
|
3132
3436
|
});
|
|
3133
|
-
var Box =
|
|
3437
|
+
var Box = React23.forwardRef(
|
|
3134
3438
|
({ className, direction, align, justify, wrap, gap, asChild = false, children, ...props }, ref) => {
|
|
3135
3439
|
return (0, import_use_render4.useRender)({
|
|
3136
3440
|
ref,
|
|
@@ -3153,16 +3457,16 @@ var Box = React37.forwardRef(
|
|
|
3153
3457
|
Box.displayName = "Box";
|
|
3154
3458
|
|
|
3155
3459
|
// src/components/berget-logo/BergetLogo.tsx
|
|
3156
|
-
var
|
|
3157
|
-
var
|
|
3158
|
-
var BergetLogo =
|
|
3460
|
+
var React24 = __toESM(require("react"), 1);
|
|
3461
|
+
var import_jsx_runtime39 = require("react/jsx-runtime");
|
|
3462
|
+
var BergetLogo = React24.forwardRef(
|
|
3159
3463
|
({ variant = "logotype", color = "auto", size = 48, className, ...props }, ref) => {
|
|
3160
3464
|
const fillColor = color === "auto" ? "var(--berget-logo-light)" : color === "white" ? "var(--berget-logo-light)" : "var(--berget-logo-dark)";
|
|
3161
3465
|
if (variant === "symbol") {
|
|
3162
3466
|
const aspectRatio2 = 463 / 419;
|
|
3163
3467
|
const width2 = size * aspectRatio2;
|
|
3164
3468
|
const height2 = size;
|
|
3165
|
-
return /* @__PURE__ */ (0,
|
|
3469
|
+
return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
3166
3470
|
"svg",
|
|
3167
3471
|
{
|
|
3168
3472
|
ref,
|
|
@@ -3175,7 +3479,7 @@ var BergetLogo = React38.forwardRef(
|
|
|
3175
3479
|
"aria-label": "Berget symbol",
|
|
3176
3480
|
className: cn("inline-block", className),
|
|
3177
3481
|
...props,
|
|
3178
|
-
children: /* @__PURE__ */ (0,
|
|
3482
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
3179
3483
|
"path",
|
|
3180
3484
|
{
|
|
3181
3485
|
d: "M208.739 17L255.261 17L446 403L398 403L313.5 255L261.5 176L233.163 96.1677L237.815 98.6522H226.185L230.837 96.1677L113 331L64.5 403L18 403L208.739 17Z",
|
|
@@ -3188,7 +3492,7 @@ var BergetLogo = React38.forwardRef(
|
|
|
3188
3492
|
const aspectRatio = 793.63 / 204.37;
|
|
3189
3493
|
const width = size * aspectRatio;
|
|
3190
3494
|
const height = size;
|
|
3191
|
-
return /* @__PURE__ */ (0,
|
|
3495
|
+
return /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(
|
|
3192
3496
|
"svg",
|
|
3193
3497
|
{
|
|
3194
3498
|
ref,
|
|
@@ -3202,59 +3506,59 @@ var BergetLogo = React38.forwardRef(
|
|
|
3202
3506
|
className: cn("inline-block", className),
|
|
3203
3507
|
...props,
|
|
3204
3508
|
children: [
|
|
3205
|
-
/* @__PURE__ */ (0,
|
|
3206
|
-
/* @__PURE__ */ (0,
|
|
3509
|
+
/* @__PURE__ */ (0, import_jsx_runtime39.jsxs)("g", { style: { fill: fillColor }, children: [
|
|
3510
|
+
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
3207
3511
|
"path",
|
|
3208
3512
|
{
|
|
3209
3513
|
className: "berget-logotype-fill",
|
|
3210
3514
|
d: "M268.78,172.54v-96.04h37.74c10.39,0,18.26,2.33,23.6,7,5.33,4.67,8.01,10.52,8.01,17.56,0,6.13-1.72,11-5.15,14.61-3.43,3.61-7.58,6.06-12.44,7.34,3.81.73,7.22,2.2,10.22,4.39,3.01,2.2,5.36,4.94,7.08,8.23,1.72,3.29,2.58,6.86,2.58,10.7,0,4.94-1.27,9.4-3.79,13.38-2.53,3.98-6.22,7.11-11.08,9.4-4.86,2.29-10.82,3.43-17.87,3.43h-38.89ZM283.93,117.66h20.74c5.81,0,10.24-1.3,13.29-3.91,3.05-2.61,4.58-6.19,4.58-10.77s-1.51-8.05-4.51-10.7c-3-2.65-7.55-3.98-13.65-3.98h-20.45v29.36ZM283.93,160.61h21.74c6.1,0,10.84-1.37,14.22-4.11,3.38-2.75,5.08-6.59,5.08-11.53s-1.76-8.85-5.29-11.73-8.29-4.32-14.3-4.32h-21.45v31.69Z"
|
|
3211
3515
|
}
|
|
3212
3516
|
),
|
|
3213
|
-
/* @__PURE__ */ (0,
|
|
3517
|
+
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
3214
3518
|
"path",
|
|
3215
3519
|
{
|
|
3216
3520
|
className: "berget-logotype-fill",
|
|
3217
3521
|
d: "M382.45,174.19c-6.96,0-13.13-1.49-18.52-4.46-5.39-2.97-9.6-7.11-12.65-12.42-3.05-5.3-4.57-11.48-4.57-18.52s1.5-13.4,4.5-18.79,7.19-9.61,12.58-12.62c5.39-3.02,11.65-4.53,18.81-4.53s13,1.48,18.15,4.46c5.15,2.97,9.16,6.93,12.01,11.87,2.86,4.94,4.29,10.38,4.29,16.33,0,.92-.02,1.9-.07,2.95-.05,1.05-.12,2.22-.22,3.5h-55.19c.48,6.59,2.75,11.59,6.79,15.02,4.05,3.43,8.75,5.14,14.09,5.14,4.29,0,7.89-.93,10.79-2.81,2.91-1.88,5.08-4.41,6.51-7.61h15.16c-1.91,6.4-5.7,11.75-11.37,16.05-5.68,4.3-12.71,6.45-21.09,6.45ZM382.45,114.78c-5.05,0-9.54,1.44-13.44,4.32-3.91,2.88-6.29,7.2-7.15,12.97h40.04c-.29-5.3-2.24-9.51-5.87-12.62-3.62-3.11-8.15-4.67-13.58-4.67Z"
|
|
3218
3522
|
}
|
|
3219
3523
|
),
|
|
3220
|
-
/* @__PURE__ */ (0,
|
|
3524
|
+
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
3221
3525
|
"path",
|
|
3222
3526
|
{
|
|
3223
3527
|
className: "berget-logotype-fill",
|
|
3224
3528
|
d: "M425.62,172.54v-68.05h13.59l1.29,12.9c2.47-4.48,5.93-8.03,10.37-10.63,4.43-2.61,9.79-3.91,16.08-3.91v15.23h-4.15c-4.19,0-7.93.67-11.22,1.99-3.29,1.33-5.91,3.57-7.86,6.72-1.96,3.16-2.93,7.53-2.93,13.1v32.65h-15.16Z"
|
|
3225
3529
|
}
|
|
3226
3530
|
),
|
|
3227
|
-
/* @__PURE__ */ (0,
|
|
3531
|
+
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
3228
3532
|
"path",
|
|
3229
3533
|
{
|
|
3230
3534
|
className: "berget-logotype-fill",
|
|
3231
3535
|
d: "M500.25,151.69c-3.72,0-7.14-.41-10.29-1.24l-6.15,5.76c1.05.64,2.34,1.19,3.86,1.65,1.52.46,3.66.87,6.43,1.23,2.76.37,6.53.73,11.29,1.1,9.43.82,16.25,3,20.44,6.52,4.2,3.52,6.29,8.21,6.29,14.06,0,4.02-1.12,7.84-3.35,11.45-2.24,3.61-5.72,6.54-10.44,8.78s-10.74,3.36-18.09,3.36c-9.91,0-17.94-1.8-24.09-5.42-6.15-3.62-9.22-9.08-9.22-16.4,0-2.84.78-5.65,2.35-8.44,1.57-2.79,4.08-5.42,7.51-7.89-2-.83-3.74-1.72-5.22-2.68-1.48-.96-2.79-1.94-3.94-2.95v-3.29l12.3-12.07c-5.53-4.57-8.29-10.56-8.29-17.97,0-4.48,1.12-8.58,3.36-12.28,2.24-3.7,5.5-6.65,9.79-8.85,4.29-2.2,9.43-3.29,15.44-3.29,4.01,0,7.72.55,11.15,1.64h26.45v9.6l-12.58.69c2.28,3.75,3.43,7.91,3.43,12.49s-1.13,8.69-3.36,12.35c-2.24,3.66-5.48,6.59-9.72,8.78-4.25,2.2-9.37,3.29-15.37,3.29ZM481.24,181.19c0,3.93,1.81,6.88,5.44,8.85,3.62,1.97,8.15,2.95,13.58,2.95s9.48-1.07,12.72-3.22c3.24-2.15,4.86-5,4.86-8.57,0-2.65-1.09-4.92-3.29-6.79-2.19-1.87-6.34-3.04-12.44-3.5-4.57-.27-8.63-.68-12.15-1.23-3.34,1.74-5.63,3.61-6.86,5.63-1.25,2.01-1.86,3.98-1.86,5.9ZM500.25,140.3c4.38,0,7.93-1.12,10.66-3.36,2.71-2.24,4.07-5.42,4.07-9.53s-1.36-7.41-4.07-9.6c-2.72-2.2-6.27-3.29-10.66-3.29s-8.08,1.1-10.79,3.29c-2.71,2.2-4.08,5.4-4.08,9.6s1.36,7.3,4.08,9.53c2.71,2.24,6.31,3.36,10.79,3.36Z"
|
|
3232
3536
|
}
|
|
3233
3537
|
),
|
|
3234
|
-
/* @__PURE__ */ (0,
|
|
3538
|
+
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
3235
3539
|
"path",
|
|
3236
3540
|
{
|
|
3237
3541
|
className: "berget-logotype-fill",
|
|
3238
3542
|
d: "M574.61,174.19c-6.96,0-13.13-1.49-18.52-4.46-5.39-2.97-9.6-7.11-12.65-12.42-3.05-5.3-4.57-11.48-4.57-18.52s1.5-13.4,4.5-18.79c3-5.4,7.19-9.61,12.58-12.62c5.39-3.02,11.65-4.53,18.81-4.53s13,1.48,18.15,4.46c5.15,2.97,9.16,6.93,12.01,11.87,2.86,4.94,4.29,10.38,4.29,16.33,0,.92-.02,1.9-.07,2.95-.05,1.05-.12,2.22-.22,3.5h-55.19c.48,6.59,2.75,11.59,6.79,15.02,4.05,3.43,8.75,5.14,14.09,5.14,4.29,0,7.89-.93,10.79-2.81s5.08-4.41,6.51-7.61h15.16c-1.91,6.4-5.7,11.75-11.37,16.05-5.68,4.3-12.71,6.45-21.09,6.45ZM574.61,114.78c-5.05,0-9.54,1.44-13.44,4.32-3.91,2.88-6.29,7.2-7.15,12.97h40.04c-.29-5.3-2.24-9.51-5.87-12.62-3.62-3.11-8.15-4.67-13.58-4.67Z"
|
|
3239
3543
|
}
|
|
3240
3544
|
),
|
|
3241
|
-
/* @__PURE__ */ (0,
|
|
3545
|
+
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
3242
3546
|
"path",
|
|
3243
3547
|
{
|
|
3244
3548
|
className: "berget-logotype-fill",
|
|
3245
3549
|
d: "M646.23,172.54c-6.96,0-12.49-1.62-16.59-4.87-4.1-3.25-6.15-9.03-6.15-17.36v-33.61h-12.16v-12.21h12.16l1.86-17.29h13.29v17.29h20.02v12.21h-20.02v33.61c0,3.75.84,6.33,2.51,7.75,1.67,1.42,4.55,2.13,8.65,2.13h8.14v12.35h-11.72Z"
|
|
3246
3550
|
}
|
|
3247
3551
|
),
|
|
3248
|
-
/* @__PURE__ */ (0,
|
|
3552
|
+
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
3249
3553
|
"path",
|
|
3250
3554
|
{
|
|
3251
3555
|
className: "berget-logotype-fill",
|
|
3252
3556
|
d: "M684.4,172.54l36.89-96.04h16.59l36.6,96.04h-16.01l-8.58-23.46h-40.88l-8.58,23.46h-16.01ZM713.28,137.56h32.31l-16.16-43.77-16.16,43.77Z"
|
|
3253
3557
|
}
|
|
3254
3558
|
),
|
|
3255
|
-
/* @__PURE__ */ (0,
|
|
3559
|
+
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)("path", { className: "berget-logotype-fill", d: "M778.48,172.54v-96.04h15.15v96.04h-15.15Z" })
|
|
3256
3560
|
] }),
|
|
3257
|
-
/* @__PURE__ */ (0,
|
|
3561
|
+
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
3258
3562
|
"path",
|
|
3259
3563
|
{
|
|
3260
3564
|
style: { fill: fillColor },
|
|
@@ -3269,19 +3573,19 @@ var BergetLogo = React38.forwardRef(
|
|
|
3269
3573
|
BergetLogo.displayName = "BergetLogo";
|
|
3270
3574
|
|
|
3271
3575
|
// src/components/language-select/LanguageSelect.tsx
|
|
3272
|
-
var
|
|
3576
|
+
var React25 = __toESM(require("react"), 1);
|
|
3273
3577
|
var import_select3 = require("@base-ui/react/select");
|
|
3274
|
-
var
|
|
3275
|
-
var
|
|
3276
|
-
var LanguageSelect =
|
|
3578
|
+
var import_lucide_react12 = require("lucide-react");
|
|
3579
|
+
var import_jsx_runtime40 = require("react/jsx-runtime");
|
|
3580
|
+
var LanguageSelect = React25.forwardRef(
|
|
3277
3581
|
({ className, options, value, onValueChange }, ref) => {
|
|
3278
|
-
return /* @__PURE__ */ (0,
|
|
3582
|
+
return /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)(
|
|
3279
3583
|
import_select3.Select.Root,
|
|
3280
3584
|
{
|
|
3281
3585
|
value,
|
|
3282
3586
|
onValueChange: onValueChange ? (v) => onValueChange(v ?? "") : void 0,
|
|
3283
3587
|
children: [
|
|
3284
|
-
/* @__PURE__ */ (0,
|
|
3588
|
+
/* @__PURE__ */ (0, import_jsx_runtime40.jsxs)(
|
|
3285
3589
|
import_select3.Select.Trigger,
|
|
3286
3590
|
{
|
|
3287
3591
|
ref,
|
|
@@ -3304,12 +3608,12 @@ var LanguageSelect = React39.forwardRef(
|
|
|
3304
3608
|
className
|
|
3305
3609
|
),
|
|
3306
3610
|
children: [
|
|
3307
|
-
/* @__PURE__ */ (0,
|
|
3308
|
-
/* @__PURE__ */ (0,
|
|
3611
|
+
/* @__PURE__ */ (0, import_jsx_runtime40.jsx)("span", { className: "sr-only", children: "Select language" }),
|
|
3612
|
+
/* @__PURE__ */ (0, import_jsx_runtime40.jsx)(Icon, { icon: import_lucide_react12.Globe, size: 16, "aria-hidden": true })
|
|
3309
3613
|
]
|
|
3310
3614
|
}
|
|
3311
3615
|
),
|
|
3312
|
-
/* @__PURE__ */ (0,
|
|
3616
|
+
/* @__PURE__ */ (0, import_jsx_runtime40.jsx)(import_select3.Select.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(import_select3.Select.Positioner, { alignItemWithTrigger: false, className: "isolate z-50", children: /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
|
|
3313
3617
|
import_select3.Select.Popup,
|
|
3314
3618
|
{
|
|
3315
3619
|
className: cn(
|
|
@@ -3335,7 +3639,7 @@ var LanguageSelect = React39.forwardRef(
|
|
|
3335
3639
|
// Origin for transforms
|
|
3336
3640
|
"origin-[--transform-origin]"
|
|
3337
3641
|
),
|
|
3338
|
-
children: /* @__PURE__ */ (0,
|
|
3642
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(import_select3.Select.List, { className: "p-1", children: options.map((option) => /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
|
|
3339
3643
|
import_select3.Select.Item,
|
|
3340
3644
|
{
|
|
3341
3645
|
value: option.value,
|
|
@@ -3352,7 +3656,7 @@ var LanguageSelect = React39.forwardRef(
|
|
|
3352
3656
|
// Disabled state
|
|
3353
3657
|
"data-disabled:pointer-events-none data-disabled:opacity-50"
|
|
3354
3658
|
),
|
|
3355
|
-
children: /* @__PURE__ */ (0,
|
|
3659
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(import_select3.Select.ItemText, { children: option.label })
|
|
3356
3660
|
},
|
|
3357
3661
|
option.value
|
|
3358
3662
|
)) })
|
|
@@ -3366,13 +3670,13 @@ var LanguageSelect = React39.forwardRef(
|
|
|
3366
3670
|
LanguageSelect.displayName = "LanguageSelect";
|
|
3367
3671
|
|
|
3368
3672
|
// src/components/list/List.tsx
|
|
3369
|
-
var
|
|
3673
|
+
var React27 = __toESM(require("react"), 1);
|
|
3370
3674
|
|
|
3371
3675
|
// src/components/divider/Divider.tsx
|
|
3372
|
-
var
|
|
3373
|
-
var
|
|
3374
|
-
var
|
|
3375
|
-
var dividerVariants = (0,
|
|
3676
|
+
var React26 = __toESM(require("react"), 1);
|
|
3677
|
+
var import_class_variance_authority20 = require("class-variance-authority");
|
|
3678
|
+
var import_jsx_runtime41 = require("react/jsx-runtime");
|
|
3679
|
+
var dividerVariants = (0, import_class_variance_authority20.cva)("", {
|
|
3376
3680
|
variants: {
|
|
3377
3681
|
variant: {
|
|
3378
3682
|
default: "bg-berget-separator",
|
|
@@ -3392,7 +3696,7 @@ var dividerVariants = (0, import_class_variance_authority19.cva)("", {
|
|
|
3392
3696
|
size: "thin"
|
|
3393
3697
|
}
|
|
3394
3698
|
});
|
|
3395
|
-
var Divider =
|
|
3699
|
+
var Divider = React26.forwardRef(
|
|
3396
3700
|
({
|
|
3397
3701
|
className,
|
|
3398
3702
|
orientation = "horizontal",
|
|
@@ -3403,16 +3707,16 @@ var Divider = React40.forwardRef(
|
|
|
3403
3707
|
...props
|
|
3404
3708
|
}, ref) => {
|
|
3405
3709
|
if (label) {
|
|
3406
|
-
return /* @__PURE__ */ (0,
|
|
3407
|
-
labelPosition !== "right" && /* @__PURE__ */ (0,
|
|
3710
|
+
return /* @__PURE__ */ (0, import_jsx_runtime41.jsxs)("div", { ref, className: cn("flex items-center w-full", className), ...props, children: [
|
|
3711
|
+
labelPosition !== "right" && /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
|
|
3408
3712
|
Separator,
|
|
3409
3713
|
{
|
|
3410
3714
|
orientation: "horizontal",
|
|
3411
3715
|
className: cn(dividerVariants({ variant, size }), "flex-1")
|
|
3412
3716
|
}
|
|
3413
3717
|
),
|
|
3414
|
-
/* @__PURE__ */ (0,
|
|
3415
|
-
labelPosition !== "left" && /* @__PURE__ */ (0,
|
|
3718
|
+
/* @__PURE__ */ (0, import_jsx_runtime41.jsx)(Typography, { variant: "small", color: "muted", className: "px-4 whitespace-nowrap", children: label }),
|
|
3719
|
+
labelPosition !== "left" && /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
|
|
3416
3720
|
Separator,
|
|
3417
3721
|
{
|
|
3418
3722
|
orientation: "horizontal",
|
|
@@ -3421,7 +3725,7 @@ var Divider = React40.forwardRef(
|
|
|
3421
3725
|
)
|
|
3422
3726
|
] });
|
|
3423
3727
|
}
|
|
3424
|
-
return /* @__PURE__ */ (0,
|
|
3728
|
+
return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
|
|
3425
3729
|
Separator,
|
|
3426
3730
|
{
|
|
3427
3731
|
ref,
|
|
@@ -3438,20 +3742,20 @@ var Divider = React40.forwardRef(
|
|
|
3438
3742
|
Divider.displayName = "Divider";
|
|
3439
3743
|
|
|
3440
3744
|
// src/components/list/List.tsx
|
|
3441
|
-
var
|
|
3442
|
-
var
|
|
3443
|
-
var List =
|
|
3745
|
+
var import_lucide_react13 = require("lucide-react");
|
|
3746
|
+
var import_jsx_runtime42 = require("react/jsx-runtime");
|
|
3747
|
+
var List = React27.forwardRef(
|
|
3444
3748
|
({ className, children, ...props }, ref) => {
|
|
3445
|
-
const childrenArray =
|
|
3446
|
-
return /* @__PURE__ */ (0,
|
|
3749
|
+
const childrenArray = React27.Children.toArray(children);
|
|
3750
|
+
return /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("div", { ref, className: cn("flex flex-col", className), ...props, children: childrenArray.map((child, index) => /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)(React27.Fragment, { children: [
|
|
3447
3751
|
child,
|
|
3448
|
-
index < childrenArray.length - 1 && /* @__PURE__ */ (0,
|
|
3752
|
+
index < childrenArray.length - 1 && /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(Divider, { variant: "subtle" })
|
|
3449
3753
|
] }, index)) });
|
|
3450
3754
|
}
|
|
3451
3755
|
);
|
|
3452
3756
|
List.displayName = "List";
|
|
3453
|
-
var ListItem =
|
|
3454
|
-
({ className, icon, children, interactive = true, ...props }, ref) => /* @__PURE__ */ (0,
|
|
3757
|
+
var ListItem = React27.forwardRef(
|
|
3758
|
+
({ className, icon, children, interactive = true, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)(
|
|
3455
3759
|
"div",
|
|
3456
3760
|
{
|
|
3457
3761
|
ref,
|
|
@@ -3462,15 +3766,15 @@ var ListItem = React41.forwardRef(
|
|
|
3462
3766
|
),
|
|
3463
3767
|
...props,
|
|
3464
3768
|
children: [
|
|
3465
|
-
icon && /* @__PURE__ */ (0,
|
|
3466
|
-
/* @__PURE__ */ (0,
|
|
3769
|
+
icon && /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("div", { className: "flex-shrink-0 flex items-center justify-center", children: icon }),
|
|
3770
|
+
/* @__PURE__ */ (0, import_jsx_runtime42.jsx)("div", { className: "flex-1 min-w-0", children })
|
|
3467
3771
|
]
|
|
3468
3772
|
}
|
|
3469
3773
|
)
|
|
3470
3774
|
);
|
|
3471
3775
|
ListItem.displayName = "ListItem";
|
|
3472
|
-
var ListHeader =
|
|
3473
|
-
({ className, children, ...props }, ref) => /* @__PURE__ */ (0,
|
|
3776
|
+
var ListHeader = React27.forwardRef(
|
|
3777
|
+
({ className, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
|
|
3474
3778
|
"div",
|
|
3475
3779
|
{
|
|
3476
3780
|
ref,
|
|
@@ -3481,21 +3785,21 @@ var ListHeader = React41.forwardRef(
|
|
|
3481
3785
|
)
|
|
3482
3786
|
);
|
|
3483
3787
|
ListHeader.displayName = "ListHeader";
|
|
3484
|
-
var FeatureList =
|
|
3788
|
+
var FeatureList = React27.forwardRef(
|
|
3485
3789
|
({ items, variant = "bullet", className, ...props }, ref) => {
|
|
3486
|
-
return /* @__PURE__ */ (0,
|
|
3487
|
-
variant === "bullet" ? /* @__PURE__ */ (0,
|
|
3488
|
-
/* @__PURE__ */ (0,
|
|
3790
|
+
return /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("ul", { ref, className: cn("flex flex-col gap-fluid-md", className), ...props, children: items.map((item, index) => /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)("li", { className: "flex items-start gap-fluid-md", children: [
|
|
3791
|
+
variant === "bullet" ? /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("span", { className: "w-1.5 h-1.5 rounded-full bg-berget-icon-muted flex-shrink-0 mt-2" }) : /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("div", { className: "flex-shrink-0 mt-0.5", children: /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(Icon, { icon: import_lucide_react13.Check, size: 24, className: "text-berget-logo-light" }) }),
|
|
3792
|
+
/* @__PURE__ */ (0, import_jsx_runtime42.jsx)(Typography, { variant: "body", color: "muted", children: item })
|
|
3489
3793
|
] }, index)) });
|
|
3490
3794
|
}
|
|
3491
3795
|
);
|
|
3492
3796
|
FeatureList.displayName = "FeatureList";
|
|
3493
3797
|
|
|
3494
3798
|
// src/components/hero-block/HeroBlock.tsx
|
|
3495
|
-
var
|
|
3496
|
-
var
|
|
3497
|
-
var
|
|
3498
|
-
var heroBlockVariants = (0,
|
|
3799
|
+
var React28 = __toESM(require("react"), 1);
|
|
3800
|
+
var import_class_variance_authority21 = require("class-variance-authority");
|
|
3801
|
+
var import_jsx_runtime43 = require("react/jsx-runtime");
|
|
3802
|
+
var heroBlockVariants = (0, import_class_variance_authority21.cva)(
|
|
3499
3803
|
"relative overflow-hidden min-h-[40dvh] flex items-center py-fluid-2xl",
|
|
3500
3804
|
{
|
|
3501
3805
|
variants: {
|
|
@@ -3515,7 +3819,7 @@ var heroBlockVariants = (0, import_class_variance_authority20.cva)(
|
|
|
3515
3819
|
}
|
|
3516
3820
|
}
|
|
3517
3821
|
);
|
|
3518
|
-
var HeroBlock =
|
|
3822
|
+
var HeroBlock = React28.forwardRef(
|
|
3519
3823
|
({
|
|
3520
3824
|
className,
|
|
3521
3825
|
variant,
|
|
@@ -3527,26 +3831,26 @@ var HeroBlock = React42.forwardRef(
|
|
|
3527
3831
|
actions,
|
|
3528
3832
|
...props
|
|
3529
3833
|
}, ref) => {
|
|
3530
|
-
return /* @__PURE__ */ (0,
|
|
3834
|
+
return /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
|
|
3531
3835
|
"div",
|
|
3532
3836
|
{
|
|
3533
3837
|
ref,
|
|
3534
3838
|
className: cn(heroBlockVariants({ variant, withPattern }), className),
|
|
3535
3839
|
...props,
|
|
3536
|
-
children: /* @__PURE__ */ (0,
|
|
3537
|
-
tagline && /* @__PURE__ */ (0,
|
|
3840
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("div", { className: "mx-auto px-4 sm:px-6 lg:px-8", children: /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)("div", { className: "mx-auto text-center max-w-4xl", children: [
|
|
3841
|
+
tagline && /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
|
|
3538
3842
|
Badge,
|
|
3539
3843
|
{
|
|
3540
3844
|
variant: "default",
|
|
3541
|
-
icon: TaglineIcon ? /* @__PURE__ */ (0,
|
|
3845
|
+
icon: TaglineIcon ? /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(Icon, { icon: TaglineIcon, size: 16 }) : void 0,
|
|
3542
3846
|
iconGap: 2,
|
|
3543
3847
|
className: "mb-fluid-md",
|
|
3544
3848
|
children: tagline
|
|
3545
3849
|
}
|
|
3546
3850
|
),
|
|
3547
|
-
/* @__PURE__ */ (0,
|
|
3548
|
-
/* @__PURE__ */ (0,
|
|
3549
|
-
actions && /* @__PURE__ */ (0,
|
|
3851
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)(Typography, { variant: "h1", className: "mb-fluid-md", children: title }),
|
|
3852
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)(Typography, { variant: "h3", color: "muted", className: "mb-fluid-lg", children: description }),
|
|
3853
|
+
actions && /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("div", { className: "flex flex-wrap gap-fluid-md justify-center", children: actions })
|
|
3550
3854
|
] }) })
|
|
3551
3855
|
}
|
|
3552
3856
|
);
|
|
@@ -3556,7 +3860,7 @@ HeroBlock.displayName = "HeroBlock";
|
|
|
3556
3860
|
|
|
3557
3861
|
// src/components/code-block/CodeBlock.tsx
|
|
3558
3862
|
var import_react2 = require("react");
|
|
3559
|
-
var
|
|
3863
|
+
var import_lucide_react14 = require("lucide-react");
|
|
3560
3864
|
|
|
3561
3865
|
// src/lib/shiki.ts
|
|
3562
3866
|
var import_core2 = require("shiki/core");
|
|
@@ -3597,7 +3901,7 @@ function getHighlighter() {
|
|
|
3597
3901
|
}
|
|
3598
3902
|
|
|
3599
3903
|
// src/components/code-block/CodeBlock.tsx
|
|
3600
|
-
var
|
|
3904
|
+
var import_jsx_runtime44 = require("react/jsx-runtime");
|
|
3601
3905
|
function CodeBlock({ code, language = "text", title, className }) {
|
|
3602
3906
|
const [html, setHtml] = (0, import_react2.useState)(null);
|
|
3603
3907
|
const [copied, setCopied] = (0, import_react2.useState)(false);
|
|
@@ -3613,16 +3917,16 @@ function CodeBlock({ code, language = "text", title, className }) {
|
|
|
3613
3917
|
setCopied(true);
|
|
3614
3918
|
setTimeout(() => setCopied(false), 2e3);
|
|
3615
3919
|
}, [code]);
|
|
3616
|
-
const copyButton = /* @__PURE__ */ (0,
|
|
3920
|
+
const copyButton = /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
3617
3921
|
"button",
|
|
3618
3922
|
{
|
|
3619
3923
|
onClick: handleCopy,
|
|
3620
3924
|
className: "flex items-center justify-center w-6 h-6 text-berget-muted-foreground hover:text-berget-foreground transition-colors",
|
|
3621
3925
|
"aria-label": "Copy code",
|
|
3622
|
-
children: copied ? /* @__PURE__ */ (0,
|
|
3926
|
+
children: copied ? /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(import_lucide_react14.Check, { className: "w-3.5 h-3.5" }) : /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(import_lucide_react14.Copy, { className: "w-3.5 h-3.5" })
|
|
3623
3927
|
}
|
|
3624
3928
|
);
|
|
3625
|
-
return /* @__PURE__ */ (0,
|
|
3929
|
+
return /* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(
|
|
3626
3930
|
"div",
|
|
3627
3931
|
{
|
|
3628
3932
|
className: cn(
|
|
@@ -3630,25 +3934,25 @@ function CodeBlock({ code, language = "text", title, className }) {
|
|
|
3630
3934
|
className
|
|
3631
3935
|
),
|
|
3632
3936
|
children: [
|
|
3633
|
-
title && /* @__PURE__ */ (0,
|
|
3634
|
-
/* @__PURE__ */ (0,
|
|
3635
|
-
html ? /* @__PURE__ */ (0,
|
|
3937
|
+
title && /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("div", { className: "!h-10 flex items-center !px-4 !text-xs !leading-normal border-b border-berget-border bg-berget-codeblock-header-bg", children: /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("span", { className: "text-berget-muted-foreground", children: title }) }),
|
|
3938
|
+
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)("div", { className: "absolute right-2 top-2 z-10", children: copyButton }),
|
|
3939
|
+
html ? /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
3636
3940
|
"div",
|
|
3637
3941
|
{
|
|
3638
3942
|
className: "[&_.shiki]:!p-4 [&_.shiki]:!m-0 [&_.shiki]:overflow-x-auto [&_.shiki]:!text-sm [&_.shiki]:!leading-relaxed [&_.shiki]:bg-transparent",
|
|
3639
3943
|
dangerouslySetInnerHTML: { __html: html }
|
|
3640
3944
|
}
|
|
3641
|
-
) : /* @__PURE__ */ (0,
|
|
3945
|
+
) : /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("pre", { className: "!p-4 !m-0 overflow-x-auto !text-sm !leading-relaxed text-berget-muted-foreground", children: /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("code", { children: code }) })
|
|
3642
3946
|
]
|
|
3643
3947
|
}
|
|
3644
3948
|
);
|
|
3645
3949
|
}
|
|
3646
3950
|
|
|
3647
3951
|
// src/components/window-frame/WindowFrame.tsx
|
|
3648
|
-
var
|
|
3952
|
+
var React29 = __toESM(require("react"), 1);
|
|
3649
3953
|
var import_react3 = require("react");
|
|
3650
|
-
var
|
|
3651
|
-
var WindowFrame =
|
|
3954
|
+
var import_jsx_runtime45 = require("react/jsx-runtime");
|
|
3955
|
+
var WindowFrame = React29.forwardRef(
|
|
3652
3956
|
({ title = "window", tabs, activeTab, onTabChange, children, className, ...props }, ref) => {
|
|
3653
3957
|
const [internalActive, setInternalActive] = (0, import_react3.useState)(tabs?.[0]?.id ?? "");
|
|
3654
3958
|
const currentTab = activeTab ?? internalActive;
|
|
@@ -3659,7 +3963,7 @@ var WindowFrame = React43.forwardRef(
|
|
|
3659
3963
|
setInternalActive(id);
|
|
3660
3964
|
}
|
|
3661
3965
|
};
|
|
3662
|
-
return /* @__PURE__ */ (0,
|
|
3966
|
+
return /* @__PURE__ */ (0, import_jsx_runtime45.jsxs)(
|
|
3663
3967
|
"div",
|
|
3664
3968
|
{
|
|
3665
3969
|
ref,
|
|
@@ -3669,13 +3973,13 @@ var WindowFrame = React43.forwardRef(
|
|
|
3669
3973
|
),
|
|
3670
3974
|
...props,
|
|
3671
3975
|
children: [
|
|
3672
|
-
/* @__PURE__ */ (0,
|
|
3673
|
-
/* @__PURE__ */ (0,
|
|
3674
|
-
/* @__PURE__ */ (0,
|
|
3675
|
-
/* @__PURE__ */ (0,
|
|
3676
|
-
/* @__PURE__ */ (0,
|
|
3976
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsxs)("div", { className: "flex items-center gap-2 px-4 py-3 border-b border-berget-brand-granite-700 bg-berget-brand-granite-900", children: [
|
|
3977
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsxs)("div", { className: "flex items-center gap-2 flex-shrink-0", children: [
|
|
3978
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)("div", { className: "w-3 h-3 rounded-full bg-[#FF5F56]" }),
|
|
3979
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)("div", { className: "w-3 h-3 rounded-full bg-[#FFBD2E]" }),
|
|
3980
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)("div", { className: "w-3 h-3 rounded-full bg-[#27C93F]" })
|
|
3677
3981
|
] }),
|
|
3678
|
-
tabs && tabs.length > 0 ? /* @__PURE__ */ (0,
|
|
3982
|
+
tabs && tabs.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime45.jsx)("div", { className: "ml-4 flex items-center gap-1", children: tabs.map((tab) => /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
|
|
3679
3983
|
"button",
|
|
3680
3984
|
{
|
|
3681
3985
|
type: "button",
|
|
@@ -3687,9 +3991,9 @@ var WindowFrame = React43.forwardRef(
|
|
|
3687
3991
|
children: tab.label
|
|
3688
3992
|
},
|
|
3689
3993
|
tab.id
|
|
3690
|
-
)) }) : /* @__PURE__ */ (0,
|
|
3994
|
+
)) }) : /* @__PURE__ */ (0, import_jsx_runtime45.jsx)("span", { className: "ml-4 text-sm font-mono text-berget-brand-moss-400", children: title })
|
|
3691
3995
|
] }),
|
|
3692
|
-
/* @__PURE__ */ (0,
|
|
3996
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)("div", { children })
|
|
3693
3997
|
]
|
|
3694
3998
|
}
|
|
3695
3999
|
);
|
|
@@ -3699,7 +4003,7 @@ WindowFrame.displayName = "WindowFrame";
|
|
|
3699
4003
|
|
|
3700
4004
|
// src/components/fog-illustration/FogIllustration.tsx
|
|
3701
4005
|
var import_react4 = require("react");
|
|
3702
|
-
var
|
|
4006
|
+
var import_jsx_runtime46 = require("react/jsx-runtime");
|
|
3703
4007
|
var FOG_BRAND_PALETTE = {
|
|
3704
4008
|
ink: "#171a1a",
|
|
3705
4009
|
milk: "#f7f5ed",
|
|
@@ -4012,7 +4316,7 @@ var FogIllustration = ({ palette, speed = 1, className }) => {
|
|
|
4012
4316
|
gl.deleteFramebuffer(fbo);
|
|
4013
4317
|
};
|
|
4014
4318
|
}, []);
|
|
4015
|
-
return /* @__PURE__ */ (0,
|
|
4319
|
+
return /* @__PURE__ */ (0, import_jsx_runtime46.jsx)("canvas", { ref, "aria-hidden": "true", className: cn("size-full", className) });
|
|
4016
4320
|
};
|
|
4017
4321
|
// Annotate the CommonJS export names for ESM import in node:
|
|
4018
4322
|
0 && (module.exports = {
|
|
@@ -4110,8 +4414,8 @@ var FogIllustration = ({ palette, speed = 1, className }) => {
|
|
|
4110
4414
|
NavigationMenuItem,
|
|
4111
4415
|
NavigationMenuLink,
|
|
4112
4416
|
NavigationMenuList,
|
|
4417
|
+
NavigationMenuPositioner,
|
|
4113
4418
|
NavigationMenuTrigger,
|
|
4114
|
-
NavigationMenuViewport,
|
|
4115
4419
|
Select,
|
|
4116
4420
|
Switch,
|
|
4117
4421
|
Table,
|