@nearform/quantum 1.4.4 → 1.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/README.md +46 -0
- package/dist/{chunk-KGI2Q7KG.mjs → chunk-RRXNHXUN.mjs} +7 -7
- package/dist/chunk-RRXNHXUN.mjs.map +1 -0
- package/dist/colors/index.js +6 -6
- package/dist/colors/index.js.map +1 -1
- package/dist/colors/index.mjs +1 -1
- package/dist/global.css +133 -66
- package/dist/global.css.map +1 -1
- package/dist/index.d.mts +104 -73
- package/dist/index.d.ts +104 -73
- package/dist/index.js +593 -223
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +601 -231
- package/dist/index.mjs.map +1 -1
- package/dist/tailwind-plugin.js +6 -6
- package/dist/tailwind-plugin.js.map +1 -1
- package/dist/tailwind-plugin.mjs +1 -1
- package/package.json +8 -2
- package/dist/chunk-KGI2Q7KG.mjs.map +0 -1
package/dist/index.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
colors_default
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-RRXNHXUN.mjs";
|
|
4
4
|
import {
|
|
5
5
|
__export,
|
|
6
6
|
__objRest,
|
|
@@ -62,6 +62,8 @@ __export(index_exports, {
|
|
|
62
62
|
SelectSeparator: () => SelectSeparator,
|
|
63
63
|
SelectTrigger: () => SelectTrigger,
|
|
64
64
|
SelectValue: () => SelectValue,
|
|
65
|
+
Step: () => Step,
|
|
66
|
+
StepsIndicator: () => StepsIndicator,
|
|
65
67
|
Switch: () => Switch,
|
|
66
68
|
Table: () => Table,
|
|
67
69
|
TableBody: () => TableBody,
|
|
@@ -178,7 +180,8 @@ var AccordionTrigger = React.forwardRef((_a, ref) => {
|
|
|
178
180
|
AccordionPrimitive.Trigger,
|
|
179
181
|
__spreadProps(__spreadValues({
|
|
180
182
|
className: cn(
|
|
181
|
-
"px-4 py-4 dark:bg-grey-900 dark:text-white group flex flex-1 cursor-
|
|
183
|
+
"px-4 py-4 dark:bg-grey-900 dark:text-white group flex flex-1 cursor-pointer items-center justify-between bg-white leading-none",
|
|
184
|
+
"focus-visible:outline-hidden focus-visible:shadow-brandGreen dark:focus-visible:shadow-brandGreen-10",
|
|
182
185
|
className
|
|
183
186
|
)
|
|
184
187
|
}, props), {
|
|
@@ -216,6 +219,7 @@ AccordionContent.displayName = AccordionPrimitive.Content.displayName;
|
|
|
216
219
|
|
|
217
220
|
// src/components/Button/index.tsx
|
|
218
221
|
import * as React2 from "react";
|
|
222
|
+
import { Slot, Slottable } from "@radix-ui/react-slot";
|
|
219
223
|
import { cva as cva2 } from "class-variance-authority";
|
|
220
224
|
import { Fragment, jsx as jsx3, jsxs as jsxs2 } from "react/jsx-runtime";
|
|
221
225
|
var buttonVariants = cva2(
|
|
@@ -348,6 +352,7 @@ var Button = React2.forwardRef(
|
|
|
348
352
|
leftSideClassName,
|
|
349
353
|
rightSideClassName,
|
|
350
354
|
disabled = false,
|
|
355
|
+
asChild = false,
|
|
351
356
|
onClick
|
|
352
357
|
} = _b, props = __objRest(_b, [
|
|
353
358
|
"className",
|
|
@@ -359,11 +364,13 @@ var Button = React2.forwardRef(
|
|
|
359
364
|
"leftSideClassName",
|
|
360
365
|
"rightSideClassName",
|
|
361
366
|
"disabled",
|
|
367
|
+
"asChild",
|
|
362
368
|
"onClick"
|
|
363
369
|
]);
|
|
364
370
|
const sideChildClassed = "inline-flex items-center justify-center text-inherit text-justify";
|
|
371
|
+
const Comp = asChild ? Slot : "button";
|
|
365
372
|
return /* @__PURE__ */ jsxs2(
|
|
366
|
-
|
|
373
|
+
Comp,
|
|
367
374
|
__spreadProps(__spreadValues({
|
|
368
375
|
className: cn(buttonVariants({ variant, size }), className),
|
|
369
376
|
ref,
|
|
@@ -374,7 +381,7 @@ var Button = React2.forwardRef(
|
|
|
374
381
|
}, props), {
|
|
375
382
|
children: [
|
|
376
383
|
leftSideChild ? /* @__PURE__ */ jsx3("div", { className: cn(sideChildClassed, "mr-3", leftSideClassName), children: leftSideChild }) : /* @__PURE__ */ jsx3(Fragment, {}),
|
|
377
|
-
/* @__PURE__ */ jsx3("div", { children }),
|
|
384
|
+
/* @__PURE__ */ jsx3(Slottable, { children: asChild ? children : /* @__PURE__ */ jsx3("div", { children }) }),
|
|
378
385
|
rightSideChild ? /* @__PURE__ */ jsx3("div", { className: cn(sideChildClassed, "ml-3", rightSideClassName), children: rightSideChild }) : /* @__PURE__ */ jsx3(Fragment, {})
|
|
379
386
|
]
|
|
380
387
|
})
|
|
@@ -398,6 +405,10 @@ var buttonGroupVariants = cva3(
|
|
|
398
405
|
"[&>*]:justify-center",
|
|
399
406
|
"[&>*]:px-3",
|
|
400
407
|
"[&>*:focus]:shadow-none",
|
|
408
|
+
"[&>*]:outline-hidden",
|
|
409
|
+
"[&>*:focus-visible]:outline-2",
|
|
410
|
+
"[&>*:focus-visible]:-outline-offset-2",
|
|
411
|
+
"[&>*:focus-visible]:outline-current",
|
|
401
412
|
"items-start",
|
|
402
413
|
"rounded-lg",
|
|
403
414
|
"overflow-hidden"
|
|
@@ -445,10 +456,11 @@ var buttonGroupVariants = cva3(
|
|
|
445
456
|
);
|
|
446
457
|
var ButtonGroup = React3.forwardRef(
|
|
447
458
|
(_a, ref) => {
|
|
448
|
-
var _b = _a, { className, orientation, variant, size } = _b, props = __objRest(_b, ["className", "orientation", "variant", "size"]);
|
|
459
|
+
var _b = _a, { className, orientation, variant, size, role = "group" } = _b, props = __objRest(_b, ["className", "orientation", "variant", "size", "role"]);
|
|
449
460
|
return /* @__PURE__ */ jsx4(
|
|
450
461
|
"div",
|
|
451
462
|
__spreadProps(__spreadValues({
|
|
463
|
+
role,
|
|
452
464
|
className: cn(
|
|
453
465
|
buttonGroupVariants({ orientation, variant, size }),
|
|
454
466
|
className
|
|
@@ -468,13 +480,38 @@ import { jsx as jsx5 } from "react/jsx-runtime";
|
|
|
468
480
|
var calendarVariants = cva4([], {
|
|
469
481
|
variants: {
|
|
470
482
|
component: {
|
|
471
|
-
months: ["flex", "flex-
|
|
472
|
-
month: ["flex", "flex-col", "gap-2"],
|
|
473
|
-
|
|
483
|
+
months: ["relative", "flex", "flex-row", "gap-4"],
|
|
484
|
+
month: ["flex", "w-full", "flex-col", "gap-2"],
|
|
485
|
+
month_caption: ["flex", "h-7", "items-center", "justify-center"],
|
|
474
486
|
caption_label: ["text-sm", "font-medium"],
|
|
475
|
-
nav
|
|
476
|
-
|
|
477
|
-
|
|
487
|
+
// v9 renders `nav` as a sibling of the months rather than inside the
|
|
488
|
+
// caption, so it is positioned over the caption row of `months` here.
|
|
489
|
+
nav: [
|
|
490
|
+
"absolute",
|
|
491
|
+
"inset-x-0",
|
|
492
|
+
"top-0",
|
|
493
|
+
"z-10",
|
|
494
|
+
"flex",
|
|
495
|
+
"h-7",
|
|
496
|
+
"items-center",
|
|
497
|
+
"justify-between",
|
|
498
|
+
"bg-transparent",
|
|
499
|
+
"dark:text-foreground-muted-dark"
|
|
500
|
+
],
|
|
501
|
+
nav_button: [
|
|
502
|
+
"flex",
|
|
503
|
+
"h-7",
|
|
504
|
+
"w-7",
|
|
505
|
+
"items-center",
|
|
506
|
+
"justify-center",
|
|
507
|
+
"rounded-lg",
|
|
508
|
+
"bg-transparent",
|
|
509
|
+
"p-0",
|
|
510
|
+
"outline-hidden",
|
|
511
|
+
"focus-visible:shadow-blue",
|
|
512
|
+
"aria-disabled:opacity-50"
|
|
513
|
+
],
|
|
514
|
+
weekday: [
|
|
478
515
|
"text-foreground-muted",
|
|
479
516
|
"dark:text-foreground-muted-dark",
|
|
480
517
|
"px-1",
|
|
@@ -484,9 +521,8 @@ var calendarVariants = cva4([], {
|
|
|
484
521
|
"text-xs",
|
|
485
522
|
"h-[34px]"
|
|
486
523
|
],
|
|
487
|
-
|
|
524
|
+
day: [
|
|
488
525
|
[
|
|
489
|
-
"overflow-none",
|
|
490
526
|
"w-9",
|
|
491
527
|
"p-0",
|
|
492
528
|
"flex",
|
|
@@ -495,41 +531,49 @@ var calendarVariants = cva4([], {
|
|
|
495
531
|
"text-center",
|
|
496
532
|
"gap-1",
|
|
497
533
|
"text-sm",
|
|
498
|
-
"relative"
|
|
534
|
+
"relative",
|
|
535
|
+
"rounded-lg"
|
|
499
536
|
],
|
|
500
|
-
[
|
|
501
|
-
"focus-within:relative",
|
|
502
|
-
"focus-within:z-20",
|
|
503
|
-
"focus-visible:shadow-blue"
|
|
504
|
-
]
|
|
537
|
+
["focus-within:relative", "focus-within:z-20"]
|
|
505
538
|
],
|
|
506
|
-
|
|
507
|
-
"aria-selected:bg-accent",
|
|
539
|
+
day_button: [
|
|
508
540
|
"rounded-lg",
|
|
509
|
-
"dark:aria-selected:bg-brandGreen-100",
|
|
510
541
|
"px-1",
|
|
511
542
|
"w-full",
|
|
512
543
|
"py-2",
|
|
513
544
|
"h-[34px]",
|
|
514
545
|
"flex",
|
|
515
546
|
"flex-col",
|
|
547
|
+
"justify-center",
|
|
516
548
|
"text-sm",
|
|
517
549
|
"font-bold",
|
|
518
|
-
"aria-selected:opacity-100",
|
|
519
550
|
"items-center",
|
|
520
551
|
"shrink-0",
|
|
521
552
|
"focus-visible:shadow-blue",
|
|
522
|
-
"outline-hidden"
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
"
|
|
527
|
-
"text-
|
|
528
|
-
"
|
|
553
|
+
"outline-hidden",
|
|
554
|
+
"disabled:cursor-not-allowed"
|
|
555
|
+
],
|
|
556
|
+
selected: [
|
|
557
|
+
"bg-accent",
|
|
558
|
+
"text-foreground-inverse",
|
|
559
|
+
"dark:bg-brandGreen-100",
|
|
560
|
+
"dark:text-foreground-inverse-dark"
|
|
561
|
+
],
|
|
562
|
+
outside: ["text-foreground-muted", "dark:text-foreground-muted-dark"],
|
|
563
|
+
disabled: [
|
|
564
|
+
"text-foreground-muted",
|
|
565
|
+
"dark:text-foreground-muted-dark",
|
|
566
|
+
"opacity-50"
|
|
529
567
|
]
|
|
530
568
|
}
|
|
531
569
|
}
|
|
532
570
|
});
|
|
571
|
+
var rangeEdge = [
|
|
572
|
+
"bg-accent!",
|
|
573
|
+
"text-foreground-inverse!",
|
|
574
|
+
"dark:bg-blue-400!",
|
|
575
|
+
"dark:text-foreground-inverse-dark!"
|
|
576
|
+
];
|
|
533
577
|
function Calendar(_a) {
|
|
534
578
|
var _b = _a, {
|
|
535
579
|
className,
|
|
@@ -545,31 +589,30 @@ function Calendar(_a) {
|
|
|
545
589
|
__spreadValues({
|
|
546
590
|
showOutsideDays,
|
|
547
591
|
className: cn(
|
|
548
|
-
"p-4 rounded-lg bg-background-alt dark:bg-background-alt-dark dark:text-foreground-inverse shadow-[0_4px_6px_0px_rgba(0,0,0,0.08)] flex
|
|
592
|
+
"p-4 rounded-lg bg-background-alt dark:bg-background-alt-dark dark:text-foreground-inverse shadow-[0_4px_6px_0px_rgba(0,0,0,0.08)] flex w-fit",
|
|
549
593
|
className
|
|
550
594
|
),
|
|
551
595
|
classNames: __spreadValues({
|
|
552
596
|
months: calendarVariants({ component: "months" }),
|
|
553
|
-
month: calendarVariants({ component: "
|
|
554
|
-
|
|
597
|
+
month: calendarVariants({ component: "month" }),
|
|
598
|
+
month_caption: calendarVariants({ component: "month_caption" }),
|
|
555
599
|
caption_label: calendarVariants({ component: "caption_label" }),
|
|
556
600
|
nav: calendarVariants({ component: "nav" }),
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
row: "flex w-full",
|
|
564
|
-
cell: calendarVariants({ component: "cell" }),
|
|
601
|
+
button_previous: calendarVariants({ component: "nav_button" }),
|
|
602
|
+
button_next: calendarVariants({ component: "nav_button" }),
|
|
603
|
+
month_grid: "w-full border-collapse",
|
|
604
|
+
weekdays: "flex",
|
|
605
|
+
weekday: calendarVariants({ component: "weekday" }),
|
|
606
|
+
week: "flex w-full",
|
|
565
607
|
day: calendarVariants({ component: "day" }),
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
608
|
+
day_button: calendarVariants({ component: "day_button" }),
|
|
609
|
+
selected: calendarVariants({ component: "selected" }),
|
|
610
|
+
range_start: cn(rangeEdge, "rounded-l-full! rounded-r-none!"),
|
|
611
|
+
range_end: cn(rangeEdge, "rounded-r-full! rounded-l-none!"),
|
|
612
|
+
range_middle: "rounded-none! bg-grey-400! text-grey-900! dark:bg-accent-alt! dark:text-foreground-inverse!",
|
|
613
|
+
outside: calendarVariants({ component: "outside" }),
|
|
614
|
+
disabled: calendarVariants({ component: "disabled" }),
|
|
615
|
+
hidden: "invisible"
|
|
573
616
|
}, classNames),
|
|
574
617
|
components: {
|
|
575
618
|
Chevron: (props2) => {
|
|
@@ -603,7 +646,11 @@ var checkboxVariants = cva5([
|
|
|
603
646
|
"rounded",
|
|
604
647
|
"border",
|
|
605
648
|
"border-border",
|
|
606
|
-
"bg-background-alt"
|
|
649
|
+
"bg-background-alt",
|
|
650
|
+
"disabled:cursor-not-allowed",
|
|
651
|
+
"focus-visible:outline-hidden",
|
|
652
|
+
"focus-visible:shadow-brandGreen",
|
|
653
|
+
"dark:focus-visible:shadow-brandGreen-10"
|
|
607
654
|
],
|
|
608
655
|
[
|
|
609
656
|
"data-[state=checked]:border-border",
|
|
@@ -704,34 +751,45 @@ var chipVariants = cva6(
|
|
|
704
751
|
);
|
|
705
752
|
var Chip = React5.forwardRef(
|
|
706
753
|
(_a, ref) => {
|
|
707
|
-
var _b = _a, { variant, size, children, disabled, onClick, active } = _b, props = __objRest(_b, ["variant", "size", "children", "disabled", "onClick", "active"]);
|
|
754
|
+
var _b = _a, { variant, size, children, disabled, onClick, active, type } = _b, props = __objRest(_b, ["variant", "size", "children", "disabled", "onClick", "active", "type"]);
|
|
708
755
|
return /* @__PURE__ */ jsxs4(
|
|
709
756
|
"button",
|
|
710
757
|
__spreadProps(__spreadValues({
|
|
758
|
+
type: type != null ? type : "button",
|
|
711
759
|
onClick,
|
|
712
|
-
"data-active": active,
|
|
760
|
+
"data-active": active || void 0,
|
|
761
|
+
"aria-pressed": active === void 0 ? void 0 : active,
|
|
713
762
|
className: cn(chipVariants({ variant, size })),
|
|
714
763
|
disabled,
|
|
715
764
|
ref
|
|
716
765
|
}, props), {
|
|
717
766
|
children: [
|
|
718
767
|
children,
|
|
719
|
-
/* @__PURE__ */ jsx7(
|
|
720
|
-
|
|
768
|
+
/* @__PURE__ */ jsx7(
|
|
769
|
+
"div",
|
|
721
770
|
{
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
771
|
+
"aria-hidden": "true",
|
|
772
|
+
className: "flex items-center justify-center w-6 h-6 p-2.5",
|
|
773
|
+
children: /* @__PURE__ */ jsx7(
|
|
774
|
+
assets_exports.BsPlus,
|
|
775
|
+
{
|
|
776
|
+
className: cn(size == "lg" ? "h-4 w-4" : "h-3 w-3", [
|
|
777
|
+
"stroke-current",
|
|
778
|
+
"shrink-0"
|
|
779
|
+
])
|
|
780
|
+
}
|
|
781
|
+
)
|
|
726
782
|
}
|
|
727
|
-
)
|
|
783
|
+
)
|
|
728
784
|
]
|
|
729
785
|
})
|
|
730
786
|
);
|
|
731
787
|
}
|
|
732
788
|
);
|
|
789
|
+
Chip.displayName = "Chip";
|
|
733
790
|
|
|
734
791
|
// src/components/ControlLabel/index.tsx
|
|
792
|
+
import * as React7 from "react";
|
|
735
793
|
import { cva as cva8 } from "class-variance-authority";
|
|
736
794
|
|
|
737
795
|
// src/components/Label/index.tsx
|
|
@@ -818,13 +876,22 @@ var ControlLabel = (_a) => {
|
|
|
818
876
|
label,
|
|
819
877
|
position = "right",
|
|
820
878
|
varticalAlign,
|
|
821
|
-
children
|
|
879
|
+
children,
|
|
880
|
+
htmlFor
|
|
822
881
|
} = _b, labelProps = __objRest(_b, [
|
|
823
882
|
"label",
|
|
824
883
|
"position",
|
|
825
884
|
"varticalAlign",
|
|
826
|
-
"children"
|
|
885
|
+
"children",
|
|
886
|
+
"htmlFor"
|
|
827
887
|
]);
|
|
888
|
+
var _a2;
|
|
889
|
+
const generatedId = React7.useId();
|
|
890
|
+
const onlyChild = React7.isValidElement(children) ? children : null;
|
|
891
|
+
const childId = onlyChild == null ? void 0 : onlyChild.props.id;
|
|
892
|
+
const controlId = (_a2 = htmlFor != null ? htmlFor : childId) != null ? _a2 : onlyChild ? generatedId : void 0;
|
|
893
|
+
const control = onlyChild && !childId && controlId ? React7.cloneElement(onlyChild, { id: controlId }) : children;
|
|
894
|
+
const labelElement = (align) => /* @__PURE__ */ jsx9(Label, __spreadProps(__spreadValues({}, labelProps), { htmlFor: controlId, align, children: label }));
|
|
828
895
|
return /* @__PURE__ */ jsxs6(
|
|
829
896
|
"div",
|
|
830
897
|
{
|
|
@@ -835,20 +902,27 @@ var ControlLabel = (_a) => {
|
|
|
835
902
|
"flex space-x-2"
|
|
836
903
|
),
|
|
837
904
|
children: [
|
|
838
|
-
position === "left" &&
|
|
839
|
-
|
|
840
|
-
position === "right" &&
|
|
905
|
+
position === "left" && labelElement("right"),
|
|
906
|
+
control,
|
|
907
|
+
position === "right" && labelElement("left")
|
|
841
908
|
]
|
|
842
909
|
}
|
|
843
910
|
);
|
|
844
911
|
};
|
|
845
912
|
|
|
846
913
|
// src/components/Input/index.tsx
|
|
847
|
-
import
|
|
914
|
+
import React8 from "react";
|
|
848
915
|
import { cva as cva9 } from "class-variance-authority";
|
|
849
916
|
import { jsx as jsx10, jsxs as jsxs7 } from "react/jsx-runtime";
|
|
850
917
|
var leftSideVariants = cva9(["flex", "items-center", "text-inherit"]);
|
|
851
|
-
var rightSideVariants = cva9([
|
|
918
|
+
var rightSideVariants = cva9([
|
|
919
|
+
"flex",
|
|
920
|
+
"self-center text-inherit",
|
|
921
|
+
"rounded-xs",
|
|
922
|
+
"focus-visible:outline-2",
|
|
923
|
+
"focus-visible:outline-offset-2",
|
|
924
|
+
"focus-visible:outline-current"
|
|
925
|
+
]);
|
|
852
926
|
var formVariants = cva9(
|
|
853
927
|
[
|
|
854
928
|
"flex",
|
|
@@ -913,58 +987,121 @@ var inputVariants = cva9(
|
|
|
913
987
|
var convertTypeToLeftComponent = (type) => {
|
|
914
988
|
var _a;
|
|
915
989
|
const mapping = {
|
|
916
|
-
search: /* @__PURE__ */ jsx10(assets_exports.BsSearch, {})
|
|
990
|
+
search: /* @__PURE__ */ jsx10(assets_exports.BsSearch, { "aria-hidden": "true" })
|
|
917
991
|
};
|
|
918
992
|
return (_a = mapping[type]) != null ? _a : null;
|
|
919
993
|
};
|
|
920
|
-
var Input =
|
|
994
|
+
var Input = React8.forwardRef(
|
|
921
995
|
(_a, ref) => {
|
|
922
996
|
var _b = _a, {
|
|
923
997
|
type,
|
|
998
|
+
id,
|
|
924
999
|
className,
|
|
925
1000
|
formClassName,
|
|
926
1001
|
leftSideClassName,
|
|
927
1002
|
variant,
|
|
928
1003
|
leftSideChild,
|
|
929
1004
|
rightSideChild,
|
|
930
|
-
|
|
1005
|
+
labelText,
|
|
1006
|
+
helpText,
|
|
1007
|
+
clearLabel = "Clear input",
|
|
1008
|
+
onClear,
|
|
1009
|
+
"aria-describedby": ariaDescribedby
|
|
931
1010
|
} = _b, props = __objRest(_b, [
|
|
932
1011
|
"type",
|
|
1012
|
+
"id",
|
|
933
1013
|
"className",
|
|
934
1014
|
"formClassName",
|
|
935
1015
|
"leftSideClassName",
|
|
936
1016
|
"variant",
|
|
937
1017
|
"leftSideChild",
|
|
938
1018
|
"rightSideChild",
|
|
939
|
-
"
|
|
1019
|
+
"labelText",
|
|
1020
|
+
"helpText",
|
|
1021
|
+
"clearLabel",
|
|
1022
|
+
"onClear",
|
|
1023
|
+
"aria-describedby"
|
|
940
1024
|
]);
|
|
1025
|
+
const generatedId = React8.useId();
|
|
1026
|
+
const inputId = id != null ? id : generatedId;
|
|
1027
|
+
const helpTextId = `${inputId}-helptext`;
|
|
1028
|
+
const describedBy = [ariaDescribedby, helpText ? helpTextId : void 0].filter(Boolean).join(" ") || void 0;
|
|
941
1029
|
const leftSideComponent = leftSideChild != null ? leftSideChild : convertTypeToLeftComponent(type);
|
|
942
|
-
const rightSideComponent = rightSideChild != null ? rightSideChild : /* @__PURE__ */ jsx10(assets_exports.BsX, { strokeWidth: 0.6 });
|
|
943
|
-
|
|
1030
|
+
const rightSideComponent = rightSideChild != null ? rightSideChild : /* @__PURE__ */ jsx10(assets_exports.BsX, { strokeWidth: 0.6, "aria-hidden": "true" });
|
|
1031
|
+
const field = /* @__PURE__ */ jsxs7("div", { className: cn(formVariants({ variant }), formClassName), children: [
|
|
944
1032
|
leftSideComponent && /* @__PURE__ */ jsx10("div", { className: cn(leftSideVariants(), leftSideClassName), children: leftSideComponent }),
|
|
945
1033
|
/* @__PURE__ */ jsx10(
|
|
946
1034
|
"input",
|
|
947
1035
|
__spreadValues({
|
|
1036
|
+
id: inputId,
|
|
948
1037
|
type,
|
|
949
1038
|
className: cn(inputVariants({ variant }), className),
|
|
950
|
-
ref
|
|
1039
|
+
ref,
|
|
1040
|
+
"aria-describedby": describedBy
|
|
951
1041
|
}, props)
|
|
952
1042
|
),
|
|
953
1043
|
/* @__PURE__ */ jsx10("div", { className: "input-right-side" }),
|
|
954
|
-
/* @__PURE__ */ jsx10(
|
|
1044
|
+
/* @__PURE__ */ jsx10(
|
|
1045
|
+
"button",
|
|
1046
|
+
{
|
|
1047
|
+
type: "button",
|
|
1048
|
+
onClick: onClear,
|
|
1049
|
+
"aria-label": clearLabel,
|
|
1050
|
+
className: rightSideVariants(),
|
|
1051
|
+
children: rightSideComponent
|
|
1052
|
+
}
|
|
1053
|
+
)
|
|
1054
|
+
] });
|
|
1055
|
+
if (!labelText && !helpText) {
|
|
1056
|
+
return field;
|
|
1057
|
+
}
|
|
1058
|
+
return /* @__PURE__ */ jsxs7("div", { className: "flex flex-col gap-3", children: [
|
|
1059
|
+
labelText && /* @__PURE__ */ jsx10(
|
|
1060
|
+
"label",
|
|
1061
|
+
{
|
|
1062
|
+
htmlFor: inputId,
|
|
1063
|
+
className: "text-m text-foreground dark:text-foreground-dark",
|
|
1064
|
+
children: labelText
|
|
1065
|
+
}
|
|
1066
|
+
),
|
|
1067
|
+
field,
|
|
1068
|
+
helpText && /* @__PURE__ */ jsx10(
|
|
1069
|
+
"span",
|
|
1070
|
+
{
|
|
1071
|
+
id: helpTextId,
|
|
1072
|
+
className: "text-sm text-foreground-muted dark:text-foreground-muted-dark",
|
|
1073
|
+
children: helpText
|
|
1074
|
+
}
|
|
1075
|
+
)
|
|
955
1076
|
] });
|
|
956
1077
|
}
|
|
957
1078
|
);
|
|
1079
|
+
Input.displayName = "Input";
|
|
958
1080
|
|
|
959
1081
|
// src/components/Link/index.tsx
|
|
960
|
-
import
|
|
1082
|
+
import React9 from "react";
|
|
961
1083
|
import { jsx as jsx11, jsxs as jsxs8 } from "react/jsx-runtime";
|
|
962
|
-
var Link =
|
|
1084
|
+
var Link = React9.forwardRef(
|
|
963
1085
|
(_a, ref) => {
|
|
964
|
-
var _b = _a, {
|
|
1086
|
+
var _b = _a, {
|
|
1087
|
+
className,
|
|
1088
|
+
onClick,
|
|
1089
|
+
selected = false,
|
|
1090
|
+
children,
|
|
1091
|
+
icon: Icon2,
|
|
1092
|
+
"aria-current": ariaCurrent
|
|
1093
|
+
} = _b, props = __objRest(_b, [
|
|
1094
|
+
"className",
|
|
1095
|
+
"onClick",
|
|
1096
|
+
"selected",
|
|
1097
|
+
"children",
|
|
1098
|
+
"icon",
|
|
1099
|
+
"aria-current"
|
|
1100
|
+
]);
|
|
965
1101
|
const selectedClasses = "cursor-default text-white dark:text-foreground-inverse-dark bg-background-inverse dark:bg-background-inverse-dark";
|
|
966
1102
|
const hoverClasses = "hover:bg-grey-100 hover:underline dark:hover:bg-grey-700";
|
|
967
|
-
const focusClasses = "focus:shadow-brandGreen focus:underline
|
|
1103
|
+
const focusClasses = "focus:shadow-brandGreen focus:underline dark:focus:shadow-brandGreen-10";
|
|
1104
|
+
const unselectedFocusClasses = "focus:bg-grey-100 dark:focus:bg-grey-700";
|
|
968
1105
|
return /* @__PURE__ */ jsxs8(
|
|
969
1106
|
"a",
|
|
970
1107
|
__spreadProps(__spreadValues({
|
|
@@ -975,10 +1112,12 @@ var Link = React8.forwardRef(
|
|
|
975
1112
|
"cursor-pointer",
|
|
976
1113
|
"outline-hidden",
|
|
977
1114
|
"dark:text-white",
|
|
978
|
-
|
|
1115
|
+
focusClasses,
|
|
1116
|
+
selected ? selectedClasses : `${hoverClasses} ${unselectedFocusClasses}`,
|
|
979
1117
|
className
|
|
980
1118
|
),
|
|
981
1119
|
ref,
|
|
1120
|
+
"aria-current": ariaCurrent != null ? ariaCurrent : selected ? "page" : void 0,
|
|
982
1121
|
onClick: (e) => {
|
|
983
1122
|
if (selected) {
|
|
984
1123
|
e.preventDefault();
|
|
@@ -988,7 +1127,7 @@ var Link = React8.forwardRef(
|
|
|
988
1127
|
}
|
|
989
1128
|
}, props), {
|
|
990
1129
|
children: [
|
|
991
|
-
Icon2 ? /* @__PURE__ */ jsx11(Icon2, { className: "mr-1" }) : null,
|
|
1130
|
+
Icon2 ? /* @__PURE__ */ jsx11(Icon2, { className: "mr-1", "aria-hidden": "true" }) : null,
|
|
992
1131
|
children
|
|
993
1132
|
]
|
|
994
1133
|
})
|
|
@@ -998,7 +1137,7 @@ var Link = React8.forwardRef(
|
|
|
998
1137
|
Link.displayName = "Link";
|
|
999
1138
|
|
|
1000
1139
|
// src/components/Modal/index.tsx
|
|
1001
|
-
import * as
|
|
1140
|
+
import * as React10 from "react";
|
|
1002
1141
|
import * as DialogPrimitive from "@radix-ui/react-dialog";
|
|
1003
1142
|
import { cva as cva10 } from "class-variance-authority";
|
|
1004
1143
|
import { jsx as jsx12, jsxs as jsxs9 } from "react/jsx-runtime";
|
|
@@ -1006,7 +1145,7 @@ var Modal = DialogPrimitive.Root;
|
|
|
1006
1145
|
var ModalTrigger = DialogPrimitive.Trigger;
|
|
1007
1146
|
var ModalPortal = DialogPrimitive.Portal;
|
|
1008
1147
|
var ModalCloseFooter = DialogPrimitive.Close;
|
|
1009
|
-
var ModalOverlay =
|
|
1148
|
+
var ModalOverlay = React10.forwardRef((_a, ref) => {
|
|
1010
1149
|
var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
|
|
1011
1150
|
return /* @__PURE__ */ jsx12(
|
|
1012
1151
|
DialogPrimitive.Overlay,
|
|
@@ -1017,7 +1156,7 @@ var ModalOverlay = React9.forwardRef((_a, ref) => {
|
|
|
1017
1156
|
);
|
|
1018
1157
|
});
|
|
1019
1158
|
ModalOverlay.displayName = DialogPrimitive.Overlay.displayName;
|
|
1020
|
-
var ModalContent =
|
|
1159
|
+
var ModalContent = React10.forwardRef((_a, ref) => {
|
|
1021
1160
|
var _b = _a, { className, children } = _b, props = __objRest(_b, ["className", "children"]);
|
|
1022
1161
|
return /* @__PURE__ */ jsxs9(ModalPortal, { children: [
|
|
1023
1162
|
/* @__PURE__ */ jsx12(ModalOverlay, {}),
|
|
@@ -1080,7 +1219,7 @@ var ModalFooter = (_a) => {
|
|
|
1080
1219
|
return /* @__PURE__ */ jsx12("div", __spreadValues({ className: cn("flex flex-col p-6 pt-0 gap-2.5", className) }, props));
|
|
1081
1220
|
};
|
|
1082
1221
|
ModalFooter.displayName = "ModalFooter";
|
|
1083
|
-
var ModalTitle =
|
|
1222
|
+
var ModalTitle = React10.forwardRef((_a, ref) => {
|
|
1084
1223
|
var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
|
|
1085
1224
|
return /* @__PURE__ */ jsx12(
|
|
1086
1225
|
DialogPrimitive.Title,
|
|
@@ -1094,7 +1233,7 @@ var ModalTitle = React9.forwardRef((_a, ref) => {
|
|
|
1094
1233
|
);
|
|
1095
1234
|
});
|
|
1096
1235
|
ModalTitle.displayName = DialogPrimitive.Title.displayName;
|
|
1097
|
-
var ModalClose =
|
|
1236
|
+
var ModalClose = React10.forwardRef((_a, ref) => {
|
|
1098
1237
|
var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
|
|
1099
1238
|
return /* @__PURE__ */ jsxs9(
|
|
1100
1239
|
DialogPrimitive.Close,
|
|
@@ -1102,16 +1241,26 @@ var ModalClose = React9.forwardRef((_a, ref) => {
|
|
|
1102
1241
|
ref,
|
|
1103
1242
|
className: cn(
|
|
1104
1243
|
"rounded-xs opacity-70 ring-offset-background transition-opacity disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-foreground-muted",
|
|
1244
|
+
"hover:opacity-100 focus-visible:opacity-100",
|
|
1245
|
+
"focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-current",
|
|
1105
1246
|
className
|
|
1106
1247
|
)
|
|
1107
1248
|
}, props), {
|
|
1108
1249
|
children: [
|
|
1109
|
-
/* @__PURE__ */ jsx12(
|
|
1250
|
+
/* @__PURE__ */ jsx12(
|
|
1251
|
+
"div",
|
|
1252
|
+
{
|
|
1253
|
+
"aria-hidden": "true",
|
|
1254
|
+
className: "text-foreground dark:text-foreground-inverse",
|
|
1255
|
+
children: /* @__PURE__ */ jsx12(assets_exports.BsXLg, { className: "w-5 h-5", strokeWidth: 0.833 })
|
|
1256
|
+
}
|
|
1257
|
+
),
|
|
1110
1258
|
/* @__PURE__ */ jsx12("span", { className: "sr-only", children: "Close" })
|
|
1111
1259
|
]
|
|
1112
1260
|
})
|
|
1113
1261
|
);
|
|
1114
1262
|
});
|
|
1263
|
+
ModalClose.displayName = "ModalClose";
|
|
1115
1264
|
var descriptionVariants = cva10(
|
|
1116
1265
|
[
|
|
1117
1266
|
"text-sm",
|
|
@@ -1131,7 +1280,7 @@ var descriptionVariants = cva10(
|
|
|
1131
1280
|
}
|
|
1132
1281
|
}
|
|
1133
1282
|
);
|
|
1134
|
-
var ModalDescription =
|
|
1283
|
+
var ModalDescription = React10.forwardRef((_a, ref) => {
|
|
1135
1284
|
var _b = _a, { className, variant } = _b, props = __objRest(_b, ["className", "variant"]);
|
|
1136
1285
|
return /* @__PURE__ */ jsx12(
|
|
1137
1286
|
DialogPrimitive.Description,
|
|
@@ -1144,7 +1293,7 @@ var ModalDescription = React9.forwardRef((_a, ref) => {
|
|
|
1144
1293
|
ModalDescription.displayName = "ModalDescription";
|
|
1145
1294
|
|
|
1146
1295
|
// src/components/Pagination/index.tsx
|
|
1147
|
-
import
|
|
1296
|
+
import React11, { useState, useEffect } from "react";
|
|
1148
1297
|
import { cva as cva11 } from "class-variance-authority";
|
|
1149
1298
|
import { jsx as jsx13, jsxs as jsxs10 } from "react/jsx-runtime";
|
|
1150
1299
|
var PaginationVariants = cva11([
|
|
@@ -1177,23 +1326,31 @@ var PageNumberActiveStyles = cva11([
|
|
|
1177
1326
|
"dark:hover:bg-primary-30",
|
|
1178
1327
|
"dark:hover:text-grey-900"
|
|
1179
1328
|
]);
|
|
1180
|
-
var Pagination =
|
|
1329
|
+
var Pagination = React11.forwardRef(
|
|
1181
1330
|
(_a, ref) => {
|
|
1182
1331
|
var _b = _a, {
|
|
1183
1332
|
className,
|
|
1184
1333
|
currentPage,
|
|
1185
1334
|
setCurrentPage,
|
|
1186
1335
|
numberOfItemsPerPage,
|
|
1187
|
-
totalNumberOfFilteredItems
|
|
1336
|
+
totalNumberOfFilteredItems,
|
|
1337
|
+
label = "Pagination",
|
|
1338
|
+
previousLabel = "Go to previous page",
|
|
1339
|
+
nextLabel = "Go to next page",
|
|
1340
|
+
pageLabel = (page) => `Go to page ${page}`
|
|
1188
1341
|
} = _b, props = __objRest(_b, [
|
|
1189
1342
|
"className",
|
|
1190
1343
|
"currentPage",
|
|
1191
1344
|
"setCurrentPage",
|
|
1192
1345
|
"numberOfItemsPerPage",
|
|
1193
|
-
"totalNumberOfFilteredItems"
|
|
1346
|
+
"totalNumberOfFilteredItems",
|
|
1347
|
+
"label",
|
|
1348
|
+
"previousLabel",
|
|
1349
|
+
"nextLabel",
|
|
1350
|
+
"pageLabel"
|
|
1194
1351
|
]);
|
|
1195
1352
|
const currentRowsLength = totalNumberOfFilteredItems != null ? totalNumberOfFilteredItems : 0;
|
|
1196
|
-
const totalPages =
|
|
1353
|
+
const totalPages = React11.useMemo(() => {
|
|
1197
1354
|
return Math.ceil(
|
|
1198
1355
|
currentRowsLength > 0 ? currentRowsLength / numberOfItemsPerPage : 0
|
|
1199
1356
|
);
|
|
@@ -1240,57 +1397,97 @@ var Pagination = React10.forwardRef(
|
|
|
1240
1397
|
const goToPrevPage = () => {
|
|
1241
1398
|
if (currentPage !== 1) setCurrentPage(currentPage - 1);
|
|
1242
1399
|
};
|
|
1243
|
-
return /* @__PURE__ */ jsx13(
|
|
1244
|
-
|
|
1245
|
-
|
|
1246
|
-
|
|
1247
|
-
|
|
1248
|
-
|
|
1249
|
-
|
|
1250
|
-
|
|
1400
|
+
return /* @__PURE__ */ jsx13(
|
|
1401
|
+
"nav",
|
|
1402
|
+
__spreadProps(__spreadValues({
|
|
1403
|
+
"aria-label": label,
|
|
1404
|
+
className: cn(PaginationVariants(), className),
|
|
1405
|
+
ref
|
|
1406
|
+
}, props), {
|
|
1407
|
+
children: /* @__PURE__ */ jsxs10("ul", { children: [
|
|
1408
|
+
/* @__PURE__ */ jsx13("li", { className: "hover:bg-background px-4 dark:hover:bg-background-dark rounded-xs", children: /* @__PURE__ */ jsx13(
|
|
1409
|
+
"button",
|
|
1251
1410
|
{
|
|
1252
|
-
|
|
1411
|
+
type: "button",
|
|
1412
|
+
"aria-label": previousLabel,
|
|
1413
|
+
onClick: goToPrevPage,
|
|
1414
|
+
disabled: currentPage === 1 || totalPages === 0,
|
|
1415
|
+
children: /* @__PURE__ */ jsx13(
|
|
1416
|
+
assets_exports.BsChevronLeft,
|
|
1417
|
+
{
|
|
1418
|
+
"aria-hidden": "true",
|
|
1419
|
+
className: "w-3 h-9 pt-3 pb-3 -mb-1 text-foreground dark:text-foreground-dark"
|
|
1420
|
+
}
|
|
1421
|
+
)
|
|
1253
1422
|
}
|
|
1254
|
-
)
|
|
1255
|
-
|
|
1256
|
-
|
|
1257
|
-
|
|
1258
|
-
|
|
1259
|
-
|
|
1260
|
-
|
|
1261
|
-
|
|
1262
|
-
|
|
1263
|
-
|
|
1264
|
-
|
|
1265
|
-
|
|
1266
|
-
|
|
1267
|
-
|
|
1268
|
-
|
|
1269
|
-
|
|
1270
|
-
|
|
1271
|
-
|
|
1272
|
-
|
|
1273
|
-
|
|
1274
|
-
|
|
1275
|
-
|
|
1276
|
-
|
|
1277
|
-
|
|
1278
|
-
|
|
1423
|
+
) }),
|
|
1424
|
+
pageNumbers.map((pgNumber) => /* @__PURE__ */ jsxs10(React11.Fragment, { children: [
|
|
1425
|
+
pgNumber === totalPages && showRightDots ? /* @__PURE__ */ jsx13(
|
|
1426
|
+
"li",
|
|
1427
|
+
{
|
|
1428
|
+
"aria-hidden": "true",
|
|
1429
|
+
className: "flex items-center px-4 min-w-40 max-w-40 text-foreground-muted",
|
|
1430
|
+
children: "..."
|
|
1431
|
+
}
|
|
1432
|
+
) : null,
|
|
1433
|
+
/* @__PURE__ */ jsx13("li", { children: /* @__PURE__ */ jsx13(
|
|
1434
|
+
"button",
|
|
1435
|
+
{
|
|
1436
|
+
type: "button",
|
|
1437
|
+
"aria-label": pageLabel(pgNumber),
|
|
1438
|
+
"aria-current": currentPage === pgNumber ? "page" : void 0,
|
|
1439
|
+
onClick: () => setCurrentPage(pgNumber),
|
|
1440
|
+
className: cn(
|
|
1441
|
+
PageNumberStyles(),
|
|
1442
|
+
currentPage === pgNumber && PageNumberActiveStyles()
|
|
1443
|
+
),
|
|
1444
|
+
children: /* @__PURE__ */ jsx13("div", { className: "text-sm", children: pgNumber })
|
|
1445
|
+
}
|
|
1446
|
+
) }),
|
|
1447
|
+
pgNumber === 1 && showLeftDots ? /* @__PURE__ */ jsx13(
|
|
1448
|
+
"li",
|
|
1449
|
+
{
|
|
1450
|
+
"aria-hidden": "true",
|
|
1451
|
+
className: "flex items-center px-4 max-w-40 min-w-40 text-foreground-muted",
|
|
1452
|
+
children: "..."
|
|
1453
|
+
}
|
|
1454
|
+
) : null
|
|
1455
|
+
] }, pgNumber)),
|
|
1456
|
+
/* @__PURE__ */ jsx13("li", { className: "hover:bg-background px-4 dark:hover:bg-background-dark rounded-xs", children: /* @__PURE__ */ jsx13(
|
|
1457
|
+
"button",
|
|
1279
1458
|
{
|
|
1280
|
-
|
|
1459
|
+
type: "button",
|
|
1460
|
+
"aria-label": nextLabel,
|
|
1461
|
+
onClick: goToNextPage,
|
|
1462
|
+
disabled: currentPage === totalPages || totalPages === 0,
|
|
1463
|
+
children: /* @__PURE__ */ jsx13(
|
|
1464
|
+
assets_exports.BsChevronRight,
|
|
1465
|
+
{
|
|
1466
|
+
"aria-hidden": "true",
|
|
1467
|
+
className: "w-3 h-9 py-3 -mb-1 text-foreground dark:text-foreground-dark"
|
|
1468
|
+
}
|
|
1469
|
+
)
|
|
1281
1470
|
}
|
|
1282
|
-
)
|
|
1283
|
-
}
|
|
1284
|
-
|
|
1285
|
-
|
|
1471
|
+
) })
|
|
1472
|
+
] })
|
|
1473
|
+
})
|
|
1474
|
+
);
|
|
1286
1475
|
}
|
|
1287
1476
|
);
|
|
1477
|
+
Pagination.displayName = "Pagination";
|
|
1288
1478
|
|
|
1289
1479
|
// src/components/Password/index.tsx
|
|
1290
|
-
import
|
|
1480
|
+
import React12, { useState as useState2 } from "react";
|
|
1291
1481
|
import { cva as cva12 } from "class-variance-authority";
|
|
1292
1482
|
import { jsx as jsx14, jsxs as jsxs11 } from "react/jsx-runtime";
|
|
1293
|
-
var toggleMaskVariants = cva12([
|
|
1483
|
+
var toggleMaskVariants = cva12([
|
|
1484
|
+
"flex",
|
|
1485
|
+
"self-center text-inherit",
|
|
1486
|
+
"rounded-xs",
|
|
1487
|
+
"focus-visible:outline-2",
|
|
1488
|
+
"focus-visible:outline-offset-2",
|
|
1489
|
+
"focus-visible:outline-current"
|
|
1490
|
+
]);
|
|
1294
1491
|
var passwordVariants = cva12(
|
|
1295
1492
|
["flex", "flex-grow", "items-center", "outline-hidden", "bg-transparent"],
|
|
1296
1493
|
{
|
|
@@ -1306,28 +1503,46 @@ var passwordVariants = cva12(
|
|
|
1306
1503
|
}
|
|
1307
1504
|
}
|
|
1308
1505
|
);
|
|
1309
|
-
var Password =
|
|
1506
|
+
var Password = React12.forwardRef(
|
|
1310
1507
|
(_a, ref) => {
|
|
1311
1508
|
var _b = _a, {
|
|
1509
|
+
id,
|
|
1312
1510
|
className,
|
|
1313
1511
|
formClassName,
|
|
1314
1512
|
variant = "primary",
|
|
1315
|
-
toggleMask = true
|
|
1513
|
+
toggleMask = true,
|
|
1514
|
+
labelText,
|
|
1515
|
+
helpText,
|
|
1516
|
+
showLabel = "Show password",
|
|
1517
|
+
hideLabel = "Hide password",
|
|
1518
|
+
"aria-describedby": ariaDescribedby
|
|
1316
1519
|
} = _b, props = __objRest(_b, [
|
|
1520
|
+
"id",
|
|
1317
1521
|
"className",
|
|
1318
1522
|
"formClassName",
|
|
1319
1523
|
"variant",
|
|
1320
|
-
"toggleMask"
|
|
1524
|
+
"toggleMask",
|
|
1525
|
+
"labelText",
|
|
1526
|
+
"helpText",
|
|
1527
|
+
"showLabel",
|
|
1528
|
+
"hideLabel",
|
|
1529
|
+
"aria-describedby"
|
|
1321
1530
|
]);
|
|
1322
1531
|
const [isMaskOn, setIsMaskOn] = useState2(true);
|
|
1532
|
+
const generatedId = React12.useId();
|
|
1533
|
+
const inputId = id != null ? id : generatedId;
|
|
1534
|
+
const helpTextId = `${inputId}-helptext`;
|
|
1535
|
+
const describedBy = [ariaDescribedby, helpText ? helpTextId : void 0].filter(Boolean).join(" ") || void 0;
|
|
1323
1536
|
const onToggleMask = () => setIsMaskOn((isMaskOn2) => !isMaskOn2);
|
|
1324
|
-
|
|
1537
|
+
const field = /* @__PURE__ */ jsxs11("div", { className: cn(formVariants({ variant }), formClassName), children: [
|
|
1325
1538
|
/* @__PURE__ */ jsx14(
|
|
1326
1539
|
"input",
|
|
1327
1540
|
__spreadValues({
|
|
1541
|
+
id: inputId,
|
|
1328
1542
|
type: isMaskOn ? "password" : "text",
|
|
1329
1543
|
className: cn(passwordVariants({ variant }), className),
|
|
1330
|
-
ref
|
|
1544
|
+
ref,
|
|
1545
|
+
"aria-describedby": describedBy
|
|
1331
1546
|
}, props)
|
|
1332
1547
|
),
|
|
1333
1548
|
/* @__PURE__ */ jsx14("div", { className: "input-right-side" }),
|
|
@@ -1336,16 +1551,42 @@ var Password = React11.forwardRef(
|
|
|
1336
1551
|
{
|
|
1337
1552
|
type: "button",
|
|
1338
1553
|
onClick: onToggleMask,
|
|
1554
|
+
"aria-label": isMaskOn ? showLabel : hideLabel,
|
|
1555
|
+
"aria-pressed": !isMaskOn,
|
|
1556
|
+
"aria-controls": inputId,
|
|
1339
1557
|
className: toggleMaskVariants(),
|
|
1340
|
-
children: isMaskOn ? /* @__PURE__ */ jsx14(assets_exports.BsEye, {}) : /* @__PURE__ */ jsx14(assets_exports.BsEyeSlash, {})
|
|
1558
|
+
children: isMaskOn ? /* @__PURE__ */ jsx14(assets_exports.BsEye, { "aria-hidden": "true" }) : /* @__PURE__ */ jsx14(assets_exports.BsEyeSlash, { "aria-hidden": "true" })
|
|
1559
|
+
}
|
|
1560
|
+
)
|
|
1561
|
+
] });
|
|
1562
|
+
if (!labelText && !helpText) {
|
|
1563
|
+
return field;
|
|
1564
|
+
}
|
|
1565
|
+
return /* @__PURE__ */ jsxs11("div", { className: "flex flex-col gap-3", children: [
|
|
1566
|
+
labelText && /* @__PURE__ */ jsx14(
|
|
1567
|
+
"label",
|
|
1568
|
+
{
|
|
1569
|
+
htmlFor: inputId,
|
|
1570
|
+
className: "text-m text-foreground dark:text-foreground-dark",
|
|
1571
|
+
children: labelText
|
|
1572
|
+
}
|
|
1573
|
+
),
|
|
1574
|
+
field,
|
|
1575
|
+
helpText && /* @__PURE__ */ jsx14(
|
|
1576
|
+
"span",
|
|
1577
|
+
{
|
|
1578
|
+
id: helpTextId,
|
|
1579
|
+
className: "text-sm text-foreground-muted dark:text-foreground-muted-dark",
|
|
1580
|
+
children: helpText
|
|
1341
1581
|
}
|
|
1342
1582
|
)
|
|
1343
1583
|
] });
|
|
1344
1584
|
}
|
|
1345
1585
|
);
|
|
1586
|
+
Password.displayName = "Password";
|
|
1346
1587
|
|
|
1347
1588
|
// src/components/Popover/index.tsx
|
|
1348
|
-
import * as
|
|
1589
|
+
import * as React13 from "react";
|
|
1349
1590
|
import * as PopoverPrimitive from "@radix-ui/react-popover";
|
|
1350
1591
|
import { cva as cva13 } from "class-variance-authority";
|
|
1351
1592
|
import * as SeparatorPrimitive from "@radix-ui/react-separator";
|
|
@@ -1365,7 +1606,7 @@ var popoverVariants = cva13([
|
|
|
1365
1606
|
var Popover = PopoverPrimitive.Root;
|
|
1366
1607
|
var PopoverTrigger = PopoverPrimitive.Trigger;
|
|
1367
1608
|
var PopoverClose = PopoverPrimitive.Close;
|
|
1368
|
-
var PopoverContent =
|
|
1609
|
+
var PopoverContent = React13.forwardRef(
|
|
1369
1610
|
(_a, ref) => {
|
|
1370
1611
|
var _b = _a, { className, align = "center", sideOffset = 4, children } = _b, props = __objRest(_b, ["className", "align", "sideOffset", "children"]);
|
|
1371
1612
|
return /* @__PURE__ */ jsx15(PopoverPrimitive.Portal, { children: /* @__PURE__ */ jsx15(
|
|
@@ -1398,7 +1639,7 @@ var PopoverScrollArea = ({
|
|
|
1398
1639
|
)
|
|
1399
1640
|
] });
|
|
1400
1641
|
};
|
|
1401
|
-
var PopoverSeparator =
|
|
1642
|
+
var PopoverSeparator = React13.forwardRef(
|
|
1402
1643
|
(_a, ref) => {
|
|
1403
1644
|
var _b = _a, { className, orientation = "horizontal", fullLength = false } = _b, props = __objRest(_b, ["className", "orientation", "fullLength"]);
|
|
1404
1645
|
return /* @__PURE__ */ jsx15("div", { className: "w-full", children: /* @__PURE__ */ jsx15(
|
|
@@ -1438,10 +1679,10 @@ var PopoverFooter = ({
|
|
|
1438
1679
|
};
|
|
1439
1680
|
|
|
1440
1681
|
// src/components/Radio/RadioGroup.tsx
|
|
1441
|
-
import * as
|
|
1682
|
+
import * as React14 from "react";
|
|
1442
1683
|
import * as RadioGroupPrimitive from "@radix-ui/react-radio-group";
|
|
1443
1684
|
import { jsx as jsx16 } from "react/jsx-runtime";
|
|
1444
|
-
var RadioGroup =
|
|
1685
|
+
var RadioGroup = React14.forwardRef((_a, ref) => {
|
|
1445
1686
|
var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
|
|
1446
1687
|
return /* @__PURE__ */ jsx16(
|
|
1447
1688
|
RadioGroupPrimitive.Root,
|
|
@@ -1455,7 +1696,7 @@ var RadioGroup = React13.forwardRef((_a, ref) => {
|
|
|
1455
1696
|
RadioGroup.displayName = RadioGroupPrimitive.Root.displayName;
|
|
1456
1697
|
|
|
1457
1698
|
// src/components/Radio/RadioGroupItem.tsx
|
|
1458
|
-
import * as
|
|
1699
|
+
import * as React15 from "react";
|
|
1459
1700
|
import * as RadioGroupPrimitive2 from "@radix-ui/react-radio-group";
|
|
1460
1701
|
import { cva as cva14 } from "class-variance-authority";
|
|
1461
1702
|
import { jsx as jsx17 } from "react/jsx-runtime";
|
|
@@ -1467,7 +1708,11 @@ var radioVariant = cva14([
|
|
|
1467
1708
|
"border-border",
|
|
1468
1709
|
"bg-background-alt",
|
|
1469
1710
|
"disabled:opacity-50",
|
|
1470
|
-
"
|
|
1711
|
+
"disabled:cursor-not-allowed",
|
|
1712
|
+
"text-foreground-inverse",
|
|
1713
|
+
"focus-visible:outline-hidden",
|
|
1714
|
+
"focus-visible:shadow-brandGreen",
|
|
1715
|
+
"dark:focus-visible:shadow-brandGreen-10"
|
|
1471
1716
|
],
|
|
1472
1717
|
["data-[state=checked]:border-border", "data-[state=checked]:bg-border"],
|
|
1473
1718
|
[
|
|
@@ -1476,7 +1721,7 @@ var radioVariant = cva14([
|
|
|
1476
1721
|
"dark:data-[state=checked]:bg-border-dark"
|
|
1477
1722
|
]
|
|
1478
1723
|
]);
|
|
1479
|
-
var RadioGroupItem =
|
|
1724
|
+
var RadioGroupItem = React15.forwardRef((_a, ref) => {
|
|
1480
1725
|
var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
|
|
1481
1726
|
return /* @__PURE__ */ jsx17(
|
|
1482
1727
|
RadioGroupPrimitive2.Item,
|
|
@@ -1497,7 +1742,7 @@ var RadioGroupItem = React14.forwardRef((_a, ref) => {
|
|
|
1497
1742
|
RadioGroupItem.displayName = RadioGroupPrimitive2.Item.displayName;
|
|
1498
1743
|
|
|
1499
1744
|
// src/components/Select/index.tsx
|
|
1500
|
-
import * as
|
|
1745
|
+
import * as React16 from "react";
|
|
1501
1746
|
import * as SelectPrimitive from "@radix-ui/react-select";
|
|
1502
1747
|
import { cva as cva15 } from "class-variance-authority";
|
|
1503
1748
|
import * as ScrollArea2 from "@radix-ui/react-scroll-area";
|
|
@@ -1568,7 +1813,7 @@ var triggerVariants = cva15(
|
|
|
1568
1813
|
}
|
|
1569
1814
|
}
|
|
1570
1815
|
);
|
|
1571
|
-
var SelectTrigger =
|
|
1816
|
+
var SelectTrigger = React16.forwardRef((_a, ref) => {
|
|
1572
1817
|
var _b = _a, { variant, size, className, children } = _b, props = __objRest(_b, ["variant", "size", "className", "children"]);
|
|
1573
1818
|
return /* @__PURE__ */ jsxs13(
|
|
1574
1819
|
SelectPrimitive.Trigger,
|
|
@@ -1602,7 +1847,7 @@ var contentVariants = cva15([
|
|
|
1602
1847
|
"dark:border-border-subtle-dark",
|
|
1603
1848
|
"dark:text-foreground-dark"
|
|
1604
1849
|
]);
|
|
1605
|
-
var SelectContent =
|
|
1850
|
+
var SelectContent = React16.forwardRef((_a, ref) => {
|
|
1606
1851
|
var _b = _a, { className, children, position = "popper" } = _b, props = __objRest(_b, ["className", "children", "position"]);
|
|
1607
1852
|
return /* @__PURE__ */ jsx18(SelectPrimitive.Portal, { children: /* @__PURE__ */ jsx18(
|
|
1608
1853
|
SelectPrimitive.Content,
|
|
@@ -1640,7 +1885,7 @@ var SelectContent = React15.forwardRef((_a, ref) => {
|
|
|
1640
1885
|
) });
|
|
1641
1886
|
});
|
|
1642
1887
|
SelectContent.displayName = SelectPrimitive.Content.displayName;
|
|
1643
|
-
var SelectLabel =
|
|
1888
|
+
var SelectLabel = React16.forwardRef((_a, ref) => {
|
|
1644
1889
|
var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
|
|
1645
1890
|
return /* @__PURE__ */ jsx18(
|
|
1646
1891
|
SelectPrimitive.Label,
|
|
@@ -1666,14 +1911,19 @@ var itemVariants = cva15([
|
|
|
1666
1911
|
"data-[disabled]:pointer-events-none",
|
|
1667
1912
|
"data-[disabled]:opacity-50",
|
|
1668
1913
|
"hover:bg-background-alt",
|
|
1914
|
+
"data-[highlighted]:bg-background-alt",
|
|
1915
|
+
"data-[highlighted]:outline-2",
|
|
1916
|
+
"data-[highlighted]:-outline-offset-2",
|
|
1917
|
+
"data-[highlighted]:outline-current",
|
|
1669
1918
|
"focus-visible:shadow-brandGreen"
|
|
1670
1919
|
],
|
|
1671
1920
|
[
|
|
1672
1921
|
"dark:focus-visible:shadow-brandGreen-10",
|
|
1673
|
-
"dark:hover:bg-background-alt-dark"
|
|
1922
|
+
"dark:hover:bg-background-alt-dark",
|
|
1923
|
+
"dark:data-[highlighted]:bg-background-alt-dark"
|
|
1674
1924
|
]
|
|
1675
1925
|
]);
|
|
1676
|
-
var SelectItem =
|
|
1926
|
+
var SelectItem = React16.forwardRef((_a, ref) => {
|
|
1677
1927
|
var _b = _a, { className, children } = _b, props = __objRest(_b, ["className", "children"]);
|
|
1678
1928
|
return /* @__PURE__ */ jsx18(
|
|
1679
1929
|
SelectPrimitive.Item,
|
|
@@ -1686,7 +1936,7 @@ var SelectItem = React15.forwardRef((_a, ref) => {
|
|
|
1686
1936
|
);
|
|
1687
1937
|
});
|
|
1688
1938
|
SelectItem.displayName = SelectPrimitive.Item.displayName;
|
|
1689
|
-
var SelectSeparator =
|
|
1939
|
+
var SelectSeparator = React16.forwardRef((_a, ref) => {
|
|
1690
1940
|
var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
|
|
1691
1941
|
return /* @__PURE__ */ jsx18(
|
|
1692
1942
|
SelectPrimitive.Separator,
|
|
@@ -1701,12 +1951,97 @@ var SelectSeparator = React15.forwardRef((_a, ref) => {
|
|
|
1701
1951
|
});
|
|
1702
1952
|
SelectSeparator.displayName = SelectPrimitive.Separator.displayName;
|
|
1703
1953
|
|
|
1704
|
-
// src/components/
|
|
1705
|
-
import * as React16 from "react";
|
|
1706
|
-
import * as SwitchPrimitives from "@radix-ui/react-switch";
|
|
1954
|
+
// src/components/StepsIndicator/Step.tsx
|
|
1707
1955
|
import { cva as cva16 } from "class-variance-authority";
|
|
1708
1956
|
import { jsx as jsx19 } from "react/jsx-runtime";
|
|
1709
|
-
var
|
|
1957
|
+
var stepVariant = cva16([
|
|
1958
|
+
"text-inherit",
|
|
1959
|
+
"fill-current",
|
|
1960
|
+
"text-accent-alt",
|
|
1961
|
+
"dark:text-accent-alt-dark",
|
|
1962
|
+
"hover:text-foreground-subtle",
|
|
1963
|
+
"dark:hover:text-foreground-subtle-dark",
|
|
1964
|
+
"active:text-foreground-muted",
|
|
1965
|
+
"dark:active:text-foreground-muted-dark",
|
|
1966
|
+
"data-[selected=true]:text-secondary-100",
|
|
1967
|
+
"dark:data-[selected=true]:text-accent-dark"
|
|
1968
|
+
]);
|
|
1969
|
+
var Step = ({ selected, className }) => {
|
|
1970
|
+
return /* @__PURE__ */ jsx19(
|
|
1971
|
+
assets_exports.BsCircleFill,
|
|
1972
|
+
{
|
|
1973
|
+
size: "8",
|
|
1974
|
+
"aria-hidden": "true",
|
|
1975
|
+
"data-selected": selected,
|
|
1976
|
+
className: cn(stepVariant(), className)
|
|
1977
|
+
}
|
|
1978
|
+
);
|
|
1979
|
+
};
|
|
1980
|
+
|
|
1981
|
+
// src/components/StepsIndicator/StepsIndicator.tsx
|
|
1982
|
+
import * as React17 from "react";
|
|
1983
|
+
import { cva as cva17 } from "class-variance-authority";
|
|
1984
|
+
import { jsx as jsx20 } from "react/jsx-runtime";
|
|
1985
|
+
var stepsVariant = cva17([
|
|
1986
|
+
"flex",
|
|
1987
|
+
"text-accent-alt",
|
|
1988
|
+
"space-x-1 ",
|
|
1989
|
+
"content-center items-center"
|
|
1990
|
+
]);
|
|
1991
|
+
var stepButtonVariant = cva17([
|
|
1992
|
+
"flex h-6 w-6 items-center justify-center m-0",
|
|
1993
|
+
"rounded-full",
|
|
1994
|
+
"outline-hidden",
|
|
1995
|
+
"focus-visible:outline-2",
|
|
1996
|
+
"focus-visible:outline-offset-1",
|
|
1997
|
+
"focus-visible:outline-current"
|
|
1998
|
+
]);
|
|
1999
|
+
var StepsIndicator = React17.forwardRef(
|
|
2000
|
+
({
|
|
2001
|
+
name = "",
|
|
2002
|
+
selectedIndex = 0,
|
|
2003
|
+
length = 1,
|
|
2004
|
+
onClick,
|
|
2005
|
+
label = "Progress",
|
|
2006
|
+
stepLabel = (step, total) => `Step ${step} of ${total}`,
|
|
2007
|
+
props
|
|
2008
|
+
}, ref) => {
|
|
2009
|
+
const Steps = Array(length).fill(null).map((_, i) => {
|
|
2010
|
+
const selected = i === selectedIndex;
|
|
2011
|
+
return /* @__PURE__ */ jsx20(
|
|
2012
|
+
"button",
|
|
2013
|
+
{
|
|
2014
|
+
type: "button",
|
|
2015
|
+
"aria-label": stepLabel(i + 1, length),
|
|
2016
|
+
"aria-current": selected ? "step" : void 0,
|
|
2017
|
+
className: stepButtonVariant(),
|
|
2018
|
+
onClick: () => onClick == null ? void 0 : onClick(i),
|
|
2019
|
+
children: /* @__PURE__ */ jsx20(Step, { selected: selected ? "true" : "false" })
|
|
2020
|
+
},
|
|
2021
|
+
`${i}-step-${name}`
|
|
2022
|
+
);
|
|
2023
|
+
});
|
|
2024
|
+
return /* @__PURE__ */ jsx20(
|
|
2025
|
+
"div",
|
|
2026
|
+
__spreadProps(__spreadValues({
|
|
2027
|
+
ref,
|
|
2028
|
+
role: "group",
|
|
2029
|
+
"aria-label": label,
|
|
2030
|
+
className: cn(stepsVariant())
|
|
2031
|
+
}, props), {
|
|
2032
|
+
children: Steps
|
|
2033
|
+
})
|
|
2034
|
+
);
|
|
2035
|
+
}
|
|
2036
|
+
);
|
|
2037
|
+
StepsIndicator.displayName = "StepsIndicator";
|
|
2038
|
+
|
|
2039
|
+
// src/components/Switch/index.tsx
|
|
2040
|
+
import * as React18 from "react";
|
|
2041
|
+
import * as SwitchPrimitives from "@radix-ui/react-switch";
|
|
2042
|
+
import { cva as cva18 } from "class-variance-authority";
|
|
2043
|
+
import { jsx as jsx21 } from "react/jsx-runtime";
|
|
2044
|
+
var switchVariants = cva18([
|
|
1710
2045
|
[
|
|
1711
2046
|
"peer",
|
|
1712
2047
|
"inline-flex",
|
|
@@ -1736,15 +2071,15 @@ var switchVariants = cva16([
|
|
|
1736
2071
|
"disabled:bg-grey-200"
|
|
1737
2072
|
]
|
|
1738
2073
|
]);
|
|
1739
|
-
var Switch =
|
|
2074
|
+
var Switch = React18.forwardRef((_a, ref) => {
|
|
1740
2075
|
var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
|
|
1741
|
-
return /* @__PURE__ */
|
|
2076
|
+
return /* @__PURE__ */ jsx21(
|
|
1742
2077
|
SwitchPrimitives.Root,
|
|
1743
2078
|
__spreadProps(__spreadValues({
|
|
1744
2079
|
className: cn(switchVariants(), className)
|
|
1745
2080
|
}, props), {
|
|
1746
2081
|
ref,
|
|
1747
|
-
children: /* @__PURE__ */
|
|
2082
|
+
children: /* @__PURE__ */ jsx21(
|
|
1748
2083
|
SwitchPrimitives.Thumb,
|
|
1749
2084
|
{
|
|
1750
2085
|
className: cn([
|
|
@@ -1770,10 +2105,10 @@ var Switch = React16.forwardRef((_a, ref) => {
|
|
|
1770
2105
|
Switch.displayName = SwitchPrimitives.Root.displayName;
|
|
1771
2106
|
|
|
1772
2107
|
// src/components/Table/index.tsx
|
|
1773
|
-
import * as
|
|
1774
|
-
import { cva as
|
|
1775
|
-
import { jsx as
|
|
1776
|
-
var tableBodyVariants =
|
|
2108
|
+
import * as React19 from "react";
|
|
2109
|
+
import { cva as cva19 } from "class-variance-authority";
|
|
2110
|
+
import { jsx as jsx22 } from "react/jsx-runtime";
|
|
2111
|
+
var tableBodyVariants = cva19("bg-background dark:bg-grey-900", {
|
|
1777
2112
|
variants: {
|
|
1778
2113
|
variant: {
|
|
1779
2114
|
zebra: [
|
|
@@ -1783,20 +2118,33 @@ var tableBodyVariants = cva17("bg-background dark:bg-grey-900", {
|
|
|
1783
2118
|
}
|
|
1784
2119
|
}
|
|
1785
2120
|
});
|
|
1786
|
-
var Table =
|
|
1787
|
-
|
|
1788
|
-
|
|
1789
|
-
|
|
1790
|
-
|
|
1791
|
-
|
|
1792
|
-
|
|
1793
|
-
|
|
1794
|
-
|
|
1795
|
-
|
|
2121
|
+
var Table = React19.forwardRef(
|
|
2122
|
+
(_a, ref) => {
|
|
2123
|
+
var _b = _a, { className, containerClassName } = _b, props = __objRest(_b, ["className", "containerClassName"]);
|
|
2124
|
+
return /* @__PURE__ */ jsx22(
|
|
2125
|
+
"div",
|
|
2126
|
+
{
|
|
2127
|
+
tabIndex: 0,
|
|
2128
|
+
className: cn(
|
|
2129
|
+
"relative w-full overflow-auto",
|
|
2130
|
+
"focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-current",
|
|
2131
|
+
containerClassName
|
|
2132
|
+
),
|
|
2133
|
+
children: /* @__PURE__ */ jsx22(
|
|
2134
|
+
"table",
|
|
2135
|
+
__spreadValues({
|
|
2136
|
+
ref,
|
|
2137
|
+
className: cn("caption-bottom text-sm dark:text-white", className)
|
|
2138
|
+
}, props)
|
|
2139
|
+
)
|
|
2140
|
+
}
|
|
2141
|
+
);
|
|
2142
|
+
}
|
|
2143
|
+
);
|
|
1796
2144
|
Table.displayName = "Table";
|
|
1797
|
-
var TableHeader =
|
|
2145
|
+
var TableHeader = React19.forwardRef((_a, ref) => {
|
|
1798
2146
|
var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
|
|
1799
|
-
return /* @__PURE__ */
|
|
2147
|
+
return /* @__PURE__ */ jsx22(
|
|
1800
2148
|
"thead",
|
|
1801
2149
|
__spreadValues({
|
|
1802
2150
|
ref,
|
|
@@ -1808,9 +2156,9 @@ var TableHeader = React17.forwardRef((_a, ref) => {
|
|
|
1808
2156
|
);
|
|
1809
2157
|
});
|
|
1810
2158
|
TableHeader.displayName = "TableHeader";
|
|
1811
|
-
var TableHead =
|
|
2159
|
+
var TableHead = React19.forwardRef((_a, ref) => {
|
|
1812
2160
|
var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
|
|
1813
|
-
return /* @__PURE__ */
|
|
2161
|
+
return /* @__PURE__ */ jsx22(
|
|
1814
2162
|
"th",
|
|
1815
2163
|
__spreadValues({
|
|
1816
2164
|
ref,
|
|
@@ -1819,10 +2167,10 @@ var TableHead = React17.forwardRef((_a, ref) => {
|
|
|
1819
2167
|
);
|
|
1820
2168
|
});
|
|
1821
2169
|
TableHead.displayName = "TableHead";
|
|
1822
|
-
var TableBody =
|
|
2170
|
+
var TableBody = React19.forwardRef(
|
|
1823
2171
|
(_a, ref) => {
|
|
1824
2172
|
var _b = _a, { className, variant } = _b, props = __objRest(_b, ["className", "variant"]);
|
|
1825
|
-
return /* @__PURE__ */
|
|
2173
|
+
return /* @__PURE__ */ jsx22(
|
|
1826
2174
|
"tbody",
|
|
1827
2175
|
__spreadValues({
|
|
1828
2176
|
ref,
|
|
@@ -1832,9 +2180,9 @@ var TableBody = React17.forwardRef(
|
|
|
1832
2180
|
}
|
|
1833
2181
|
);
|
|
1834
2182
|
TableBody.displayName = "TableBody";
|
|
1835
|
-
var TableRow =
|
|
2183
|
+
var TableRow = React19.forwardRef((_a, ref) => {
|
|
1836
2184
|
var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
|
|
1837
|
-
return /* @__PURE__ */
|
|
2185
|
+
return /* @__PURE__ */ jsx22(
|
|
1838
2186
|
"tr",
|
|
1839
2187
|
__spreadValues({
|
|
1840
2188
|
ref,
|
|
@@ -1846,19 +2194,19 @@ var TableRow = React17.forwardRef((_a, ref) => {
|
|
|
1846
2194
|
);
|
|
1847
2195
|
});
|
|
1848
2196
|
TableRow.displayName = "TableRow";
|
|
1849
|
-
var TableCell =
|
|
2197
|
+
var TableCell = React19.forwardRef((_a, ref) => {
|
|
1850
2198
|
var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
|
|
1851
|
-
return /* @__PURE__ */
|
|
2199
|
+
return /* @__PURE__ */ jsx22("td", __spreadValues({ ref, className: cn("p-4", className) }, props));
|
|
1852
2200
|
});
|
|
1853
2201
|
TableCell.displayName = "TableCell";
|
|
1854
|
-
var TableCaption =
|
|
2202
|
+
var TableCaption = React19.forwardRef((_a, ref) => {
|
|
1855
2203
|
var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
|
|
1856
|
-
return /* @__PURE__ */
|
|
2204
|
+
return /* @__PURE__ */ jsx22("caption", __spreadValues({ ref, className: cn("mt-4", className) }, props));
|
|
1857
2205
|
});
|
|
1858
2206
|
TableCaption.displayName = "TableCaption";
|
|
1859
|
-
var TableFooter =
|
|
2207
|
+
var TableFooter = React19.forwardRef((_a, ref) => {
|
|
1860
2208
|
var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
|
|
1861
|
-
return /* @__PURE__ */
|
|
2209
|
+
return /* @__PURE__ */ jsx22(
|
|
1862
2210
|
"tfoot",
|
|
1863
2211
|
__spreadValues({
|
|
1864
2212
|
ref,
|
|
@@ -1869,10 +2217,10 @@ var TableFooter = React17.forwardRef((_a, ref) => {
|
|
|
1869
2217
|
TableFooter.displayName = "TableFooter";
|
|
1870
2218
|
|
|
1871
2219
|
// src/components/Textarea/index.tsx
|
|
1872
|
-
import
|
|
1873
|
-
import { cva as
|
|
1874
|
-
import { jsx as
|
|
1875
|
-
var textareaVariants =
|
|
2220
|
+
import React20 from "react";
|
|
2221
|
+
import { cva as cva20 } from "class-variance-authority";
|
|
2222
|
+
import { jsx as jsx23, jsxs as jsxs14 } from "react/jsx-runtime";
|
|
2223
|
+
var textareaVariants = cva20(
|
|
1876
2224
|
[
|
|
1877
2225
|
"flex",
|
|
1878
2226
|
"flex-grow",
|
|
@@ -1930,33 +2278,50 @@ var textareaVariants = cva18(
|
|
|
1930
2278
|
}
|
|
1931
2279
|
}
|
|
1932
2280
|
);
|
|
1933
|
-
var Textarea =
|
|
2281
|
+
var Textarea = React20.forwardRef(
|
|
1934
2282
|
(_a, ref) => {
|
|
1935
|
-
var _b = _a, {
|
|
2283
|
+
var _b = _a, {
|
|
2284
|
+
className,
|
|
2285
|
+
variant,
|
|
2286
|
+
labelText,
|
|
2287
|
+
helpText,
|
|
2288
|
+
id,
|
|
2289
|
+
"aria-describedby": ariaDescribedby
|
|
2290
|
+
} = _b, props = __objRest(_b, [
|
|
2291
|
+
"className",
|
|
2292
|
+
"variant",
|
|
2293
|
+
"labelText",
|
|
2294
|
+
"helpText",
|
|
2295
|
+
"id",
|
|
2296
|
+
"aria-describedby"
|
|
2297
|
+
]);
|
|
2298
|
+
const generatedId = React20.useId();
|
|
2299
|
+
const textareaId = id != null ? id : generatedId;
|
|
2300
|
+
const helpTextId = `${textareaId}-helptext`;
|
|
2301
|
+
const describedBy = [ariaDescribedby, helpText ? helpTextId : void 0].filter(Boolean).join(" ") || void 0;
|
|
1936
2302
|
return /* @__PURE__ */ jsxs14("div", { className: "flex flex-col gap-3", children: [
|
|
1937
|
-
labelText && /* @__PURE__ */
|
|
2303
|
+
labelText && /* @__PURE__ */ jsx23(
|
|
1938
2304
|
"label",
|
|
1939
2305
|
{
|
|
1940
|
-
id: `${
|
|
1941
|
-
htmlFor:
|
|
2306
|
+
id: `${textareaId}-label`,
|
|
2307
|
+
htmlFor: textareaId,
|
|
1942
2308
|
className: "text-m text-foreground dark:text-foreground-dark",
|
|
1943
2309
|
children: labelText
|
|
1944
2310
|
}
|
|
1945
2311
|
),
|
|
1946
|
-
/* @__PURE__ */
|
|
2312
|
+
/* @__PURE__ */ jsx23(
|
|
1947
2313
|
"textarea",
|
|
1948
|
-
|
|
1949
|
-
id,
|
|
2314
|
+
__spreadValues({
|
|
2315
|
+
id: textareaId,
|
|
1950
2316
|
className: cn(textareaVariants({ variant }), className),
|
|
1951
|
-
ref
|
|
1952
|
-
|
|
1953
|
-
|
|
1954
|
-
})
|
|
2317
|
+
ref,
|
|
2318
|
+
"aria-describedby": describedBy
|
|
2319
|
+
}, props)
|
|
1955
2320
|
),
|
|
1956
|
-
helpText && /* @__PURE__ */
|
|
2321
|
+
helpText && /* @__PURE__ */ jsx23(
|
|
1957
2322
|
"span",
|
|
1958
2323
|
{
|
|
1959
|
-
id:
|
|
2324
|
+
id: helpTextId,
|
|
1960
2325
|
className: "text-sm text-foreground-muted dark:text-foreground-muted-dark",
|
|
1961
2326
|
children: helpText
|
|
1962
2327
|
}
|
|
@@ -1964,13 +2329,14 @@ var Textarea = React18.forwardRef(
|
|
|
1964
2329
|
] });
|
|
1965
2330
|
}
|
|
1966
2331
|
);
|
|
2332
|
+
Textarea.displayName = "Textarea";
|
|
1967
2333
|
|
|
1968
2334
|
// src/components/Tooltip/index.tsx
|
|
1969
|
-
import * as
|
|
2335
|
+
import * as React21 from "react";
|
|
1970
2336
|
import * as TooltipPrimitive from "@radix-ui/react-tooltip";
|
|
1971
|
-
import { cva as
|
|
1972
|
-
import { jsx as
|
|
1973
|
-
var tooltipVariants =
|
|
2337
|
+
import { cva as cva21 } from "class-variance-authority";
|
|
2338
|
+
import { jsx as jsx24, jsxs as jsxs15 } from "react/jsx-runtime";
|
|
2339
|
+
var tooltipVariants = cva21([
|
|
1974
2340
|
[
|
|
1975
2341
|
"fill-accent",
|
|
1976
2342
|
"bg-accent",
|
|
@@ -1989,9 +2355,9 @@ var tooltipVariants = cva19([
|
|
|
1989
2355
|
"dark:fill-accent-dark"
|
|
1990
2356
|
]
|
|
1991
2357
|
]);
|
|
1992
|
-
var Tooltip =
|
|
1993
|
-
return /* @__PURE__ */
|
|
1994
|
-
/* @__PURE__ */
|
|
2358
|
+
var Tooltip = React21.forwardRef(({ children, side, content, sideOffset }, ref) => {
|
|
2359
|
+
return /* @__PURE__ */ jsx24(TooltipPrimitive.Provider, { children: /* @__PURE__ */ jsxs15(TooltipPrimitive.Root, { delayDuration: 100, children: [
|
|
2360
|
+
/* @__PURE__ */ jsx24(TooltipPrimitive.Trigger, { asChild: React21.isValidElement(children), children }),
|
|
1995
2361
|
/* @__PURE__ */ jsxs15(
|
|
1996
2362
|
TooltipPrimitive.Content,
|
|
1997
2363
|
{
|
|
@@ -2001,18 +2367,19 @@ var Tooltip = React19.forwardRef(({ children, side, content, sideOffset }, ref)
|
|
|
2001
2367
|
ref,
|
|
2002
2368
|
children: [
|
|
2003
2369
|
content,
|
|
2004
|
-
/* @__PURE__ */
|
|
2370
|
+
/* @__PURE__ */ jsx24(TooltipPrimitive.Arrow, { className: "fill-inherit" })
|
|
2005
2371
|
]
|
|
2006
2372
|
}
|
|
2007
2373
|
)
|
|
2008
2374
|
] }) });
|
|
2009
2375
|
});
|
|
2376
|
+
Tooltip.displayName = "Tooltip";
|
|
2010
2377
|
|
|
2011
2378
|
// src/components/WebsiteFooter/index.tsx
|
|
2012
|
-
import { cva as
|
|
2013
|
-
import
|
|
2014
|
-
import { jsx as
|
|
2015
|
-
var websiteFooterVariants =
|
|
2379
|
+
import { cva as cva22 } from "class-variance-authority";
|
|
2380
|
+
import React22 from "react";
|
|
2381
|
+
import { jsx as jsx25, jsxs as jsxs16 } from "react/jsx-runtime";
|
|
2382
|
+
var websiteFooterVariants = cva22(
|
|
2016
2383
|
["flex", "flex-col", "w-full", "items-center", "px-16", "py-4"],
|
|
2017
2384
|
{
|
|
2018
2385
|
variants: {
|
|
@@ -2028,13 +2395,14 @@ var websiteFooterVariants = cva20(
|
|
|
2028
2395
|
defaultVariants: { size: "standard" }
|
|
2029
2396
|
}
|
|
2030
2397
|
);
|
|
2031
|
-
var footerStatementVariants =
|
|
2398
|
+
var footerStatementVariants = cva22(
|
|
2032
2399
|
[
|
|
2033
2400
|
"flex",
|
|
2034
2401
|
"flex-col",
|
|
2035
2402
|
"gap-1",
|
|
2036
2403
|
"items-center",
|
|
2037
|
-
"text-foreground-
|
|
2404
|
+
"text-foreground-muted",
|
|
2405
|
+
"dark:text-foreground-muted-dark",
|
|
2038
2406
|
"py-4",
|
|
2039
2407
|
"text-sm"
|
|
2040
2408
|
],
|
|
@@ -2048,7 +2416,7 @@ var footerStatementVariants = cva20(
|
|
|
2048
2416
|
defaultVariants: { size: "standard" }
|
|
2049
2417
|
}
|
|
2050
2418
|
);
|
|
2051
|
-
var linkRowVariants =
|
|
2419
|
+
var linkRowVariants = cva22([
|
|
2052
2420
|
"flex",
|
|
2053
2421
|
"w-full",
|
|
2054
2422
|
"justify-between",
|
|
@@ -2056,7 +2424,7 @@ var linkRowVariants = cva20([
|
|
|
2056
2424
|
"[&>*]:font-normal",
|
|
2057
2425
|
"[&>*]:text-sm"
|
|
2058
2426
|
]);
|
|
2059
|
-
var linkColumnVariants =
|
|
2427
|
+
var linkColumnVariants = cva22(
|
|
2060
2428
|
[
|
|
2061
2429
|
"flex",
|
|
2062
2430
|
"flex-col",
|
|
@@ -2091,11 +2459,11 @@ var linkColumnVariants = cva20(
|
|
|
2091
2459
|
}
|
|
2092
2460
|
}
|
|
2093
2461
|
);
|
|
2094
|
-
var WebsiteFooter =
|
|
2462
|
+
var WebsiteFooter = React22.forwardRef(
|
|
2095
2463
|
(_a, ref) => {
|
|
2096
2464
|
var _b = _a, { className, size } = _b, props = __objRest(_b, ["className", "size"]);
|
|
2097
|
-
return /* @__PURE__ */
|
|
2098
|
-
"
|
|
2465
|
+
return /* @__PURE__ */ jsx25(
|
|
2466
|
+
"footer",
|
|
2099
2467
|
__spreadProps(__spreadValues({
|
|
2100
2468
|
className: cn(websiteFooterVariants({ size }), className)
|
|
2101
2469
|
}, props), {
|
|
@@ -2104,10 +2472,10 @@ var WebsiteFooter = React20.forwardRef(
|
|
|
2104
2472
|
);
|
|
2105
2473
|
}
|
|
2106
2474
|
);
|
|
2107
|
-
var FooterStatement =
|
|
2475
|
+
var FooterStatement = React22.forwardRef(
|
|
2108
2476
|
(_a, ref) => {
|
|
2109
2477
|
var _b = _a, { className, size } = _b, props = __objRest(_b, ["className", "size"]);
|
|
2110
|
-
return /* @__PURE__ */
|
|
2478
|
+
return /* @__PURE__ */ jsx25("div", { children: /* @__PURE__ */ jsx25(
|
|
2111
2479
|
"div",
|
|
2112
2480
|
__spreadProps(__spreadValues({
|
|
2113
2481
|
className: cn(footerStatementVariants({ size }), className)
|
|
@@ -2117,10 +2485,10 @@ var FooterStatement = React20.forwardRef(
|
|
|
2117
2485
|
) });
|
|
2118
2486
|
}
|
|
2119
2487
|
);
|
|
2120
|
-
var LinkRow =
|
|
2488
|
+
var LinkRow = React22.forwardRef(
|
|
2121
2489
|
(_a, ref) => {
|
|
2122
2490
|
var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
|
|
2123
|
-
return /* @__PURE__ */
|
|
2491
|
+
return /* @__PURE__ */ jsx25(
|
|
2124
2492
|
"div",
|
|
2125
2493
|
__spreadProps(__spreadValues({
|
|
2126
2494
|
className: cn(linkRowVariants(), className)
|
|
@@ -2130,7 +2498,7 @@ var LinkRow = React20.forwardRef(
|
|
|
2130
2498
|
);
|
|
2131
2499
|
}
|
|
2132
2500
|
);
|
|
2133
|
-
var LinkColumn =
|
|
2501
|
+
var LinkColumn = React22.forwardRef(
|
|
2134
2502
|
(_a, ref) => {
|
|
2135
2503
|
var _b = _a, { className, size, title, children } = _b, props = __objRest(_b, ["className", "size", "title", "children"]);
|
|
2136
2504
|
return /* @__PURE__ */ jsxs16(
|
|
@@ -2140,7 +2508,7 @@ var LinkColumn = React20.forwardRef(
|
|
|
2140
2508
|
}, props), {
|
|
2141
2509
|
ref,
|
|
2142
2510
|
children: [
|
|
2143
|
-
title && /* @__PURE__ */
|
|
2511
|
+
title && /* @__PURE__ */ jsx25("div", { children: title }),
|
|
2144
2512
|
children
|
|
2145
2513
|
]
|
|
2146
2514
|
})
|
|
@@ -2201,6 +2569,8 @@ export {
|
|
|
2201
2569
|
SelectSeparator,
|
|
2202
2570
|
SelectTrigger,
|
|
2203
2571
|
SelectValue,
|
|
2572
|
+
Step,
|
|
2573
|
+
StepsIndicator,
|
|
2204
2574
|
Switch,
|
|
2205
2575
|
Table,
|
|
2206
2576
|
TableBody,
|