@algorithm-shift/design-system 1.2.31 → 1.2.33
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.css +30 -0
- package/dist/index.css.map +1 -1
- package/dist/index.d.mts +41 -14
- package/dist/index.d.ts +41 -14
- package/dist/index.js +468 -558
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +465 -555
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -298,35 +298,17 @@ function Input({ className, type, ...props }) {
|
|
|
298
298
|
var import_jsx_runtime10 = require("react/jsx-runtime");
|
|
299
299
|
var TextInput = ({ className, style, ...props }) => {
|
|
300
300
|
const placeholder = props.placeholder || "Placeholder text";
|
|
301
|
-
const regexPattern = props.regexPattern ?? "";
|
|
302
|
-
const errorMessage = props.errorMessage ?? "Required";
|
|
303
|
-
const noOfCharacters = props.noOfCharacters ?? 100;
|
|
304
|
-
const isRequired = props.isRequired ?? false;
|
|
305
301
|
const isEditable = props.isEditable ?? true;
|
|
306
302
|
const isDisabled = props.isDisabled ?? false;
|
|
307
303
|
const isReadonly = props.isReadonly ?? false;
|
|
308
304
|
const isAutocomplete = props.isAutocomplete ?? false;
|
|
309
|
-
const [value, setValue] = React2.useState("");
|
|
310
305
|
const [error, setError] = React2.useState(null);
|
|
311
306
|
React2.useEffect(() => {
|
|
312
307
|
if (!props.validateOnMount) return;
|
|
313
308
|
setError(props.errorMessage || null);
|
|
314
309
|
}, [props.errorMessage, props.validateOnMount]);
|
|
315
310
|
const handleChange = (e) => {
|
|
316
|
-
|
|
317
|
-
props.onChange?.(e);
|
|
318
|
-
return;
|
|
319
|
-
}
|
|
320
|
-
const val = e.target.value;
|
|
321
|
-
if (val.length > noOfCharacters) return;
|
|
322
|
-
setValue(val);
|
|
323
|
-
if (isRequired && val.trim() === "") {
|
|
324
|
-
setError(errorMessage);
|
|
325
|
-
} else if (regexPattern && !new RegExp(regexPattern).test(val)) {
|
|
326
|
-
setError(errorMessage);
|
|
327
|
-
} else {
|
|
328
|
-
setError(null);
|
|
329
|
-
}
|
|
311
|
+
props.onChange?.(e);
|
|
330
312
|
};
|
|
331
313
|
return /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(import_jsx_runtime10.Fragment, { children: [
|
|
332
314
|
/* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
|
|
@@ -339,15 +321,12 @@ var TextInput = ({ className, style, ...props }) => {
|
|
|
339
321
|
...style,
|
|
340
322
|
borderColor: error ? "#f87171" : style?.borderColor
|
|
341
323
|
},
|
|
342
|
-
value: props.value
|
|
324
|
+
value: props.value,
|
|
343
325
|
autoComplete: isAutocomplete ? "on" : "off",
|
|
344
326
|
placeholder,
|
|
345
327
|
onChange: handleChange,
|
|
346
328
|
disabled: isDisabled || !isEditable,
|
|
347
|
-
readOnly: isReadonly
|
|
348
|
-
required: isRequired,
|
|
349
|
-
maxLength: noOfCharacters,
|
|
350
|
-
pattern: regexPattern || void 0
|
|
329
|
+
readOnly: isReadonly
|
|
351
330
|
}
|
|
352
331
|
),
|
|
353
332
|
error && /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("p", { className: "mt-1 text-xs text-red-500", children: error })
|
|
@@ -560,35 +539,17 @@ var import_react4 = require("react");
|
|
|
560
539
|
var import_jsx_runtime11 = require("react/jsx-runtime");
|
|
561
540
|
var NumberInput = ({ className, style, ...props }) => {
|
|
562
541
|
const placeholder = props.placeholder ?? "Placeholder text";
|
|
563
|
-
const regexPattern = props.regexPattern ?? "";
|
|
564
|
-
const errorMessage = props.errorMessage ?? "Required";
|
|
565
|
-
const noOfCharacters = props.noOfCharacters ?? 100;
|
|
566
|
-
const isRequired = props.isRequired ?? false;
|
|
567
542
|
const isEditable = props.isEditable ?? true;
|
|
568
543
|
const isDisabled = props.isDisabled ?? false;
|
|
569
544
|
const isReadonly = props.isReadonly ?? false;
|
|
570
545
|
const isAutocomplete = props.isAutocomplete ?? false;
|
|
571
|
-
const [value, setValue] = React3.useState("");
|
|
572
546
|
const [error, setError] = React3.useState(null);
|
|
573
547
|
(0, import_react4.useEffect)(() => {
|
|
574
548
|
if (!props.validateOnMount) return;
|
|
575
549
|
setError(props.errorMessage || null);
|
|
576
550
|
}, [props.errorMessage, props.validateOnMount]);
|
|
577
551
|
const handleChange = (e) => {
|
|
578
|
-
|
|
579
|
-
props.onChange?.(e);
|
|
580
|
-
return;
|
|
581
|
-
}
|
|
582
|
-
const val = e.target.value;
|
|
583
|
-
if (val.length > noOfCharacters) return;
|
|
584
|
-
setValue(val);
|
|
585
|
-
if (isRequired && val.trim() === "") {
|
|
586
|
-
setError(errorMessage);
|
|
587
|
-
} else if (regexPattern && !new RegExp(regexPattern).test(val)) {
|
|
588
|
-
setError(errorMessage);
|
|
589
|
-
} else {
|
|
590
|
-
setError(null);
|
|
591
|
-
}
|
|
552
|
+
props.onChange?.(e);
|
|
592
553
|
};
|
|
593
554
|
return /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(import_jsx_runtime11.Fragment, { children: [
|
|
594
555
|
/* @__PURE__ */ (0, import_jsx_runtime11.jsxs)("div", { className: "flex justify-start items-center relative", children: [
|
|
@@ -597,9 +558,9 @@ var NumberInput = ({ className, style, ...props }) => {
|
|
|
597
558
|
Input,
|
|
598
559
|
{
|
|
599
560
|
type: "number",
|
|
600
|
-
id: "number-field",
|
|
561
|
+
id: props.name || "number-field",
|
|
601
562
|
name: props.name,
|
|
602
|
-
value: props.value
|
|
563
|
+
value: props.value,
|
|
603
564
|
className: cn(className, error ? "border-red-500" : ""),
|
|
604
565
|
style: {
|
|
605
566
|
...style,
|
|
@@ -609,10 +570,7 @@ var NumberInput = ({ className, style, ...props }) => {
|
|
|
609
570
|
placeholder,
|
|
610
571
|
onChange: handleChange,
|
|
611
572
|
disabled: isDisabled || !isEditable,
|
|
612
|
-
readOnly: isReadonly
|
|
613
|
-
required: isRequired,
|
|
614
|
-
maxLength: noOfCharacters,
|
|
615
|
-
pattern: regexPattern || void 0
|
|
573
|
+
readOnly: isReadonly
|
|
616
574
|
}
|
|
617
575
|
)
|
|
618
576
|
] }),
|
|
@@ -626,35 +584,17 @@ var React4 = __toESM(require("react"));
|
|
|
626
584
|
var import_jsx_runtime12 = require("react/jsx-runtime");
|
|
627
585
|
var EmailInput = ({ className, style, ...props }) => {
|
|
628
586
|
const placeholder = props.placeholder ?? "Placeholder text";
|
|
629
|
-
const regexPattern = props.regexPattern ?? "";
|
|
630
|
-
const errorMessage = props.errorMessage ?? "Required";
|
|
631
|
-
const noOfCharacters = props.noOfCharacters ?? 100;
|
|
632
|
-
const isRequired = props.isRequired ?? false;
|
|
633
587
|
const isEditable = props.isEditable ?? true;
|
|
634
588
|
const isDisabled = props.isDisabled ?? false;
|
|
635
589
|
const isReadonly = props.isReadonly ?? false;
|
|
636
590
|
const isAutocomplete = props.isAutocomplete ?? false;
|
|
637
|
-
const [value, setValue] = React4.useState("");
|
|
638
591
|
const [error, setError] = React4.useState(null);
|
|
639
592
|
React4.useEffect(() => {
|
|
640
593
|
if (!props.validateOnMount) return;
|
|
641
594
|
setError(props.errorMessage || null);
|
|
642
595
|
}, [props.errorMessage, props.validateOnMount]);
|
|
643
596
|
const handleChange = (e) => {
|
|
644
|
-
|
|
645
|
-
props.onChange?.(e);
|
|
646
|
-
return;
|
|
647
|
-
}
|
|
648
|
-
const val = e.target.value;
|
|
649
|
-
if (val.length > noOfCharacters) return;
|
|
650
|
-
setValue(val);
|
|
651
|
-
if (isRequired && val.trim() === "") {
|
|
652
|
-
setError(errorMessage);
|
|
653
|
-
} else if (regexPattern && !new RegExp(regexPattern).test(val)) {
|
|
654
|
-
setError(errorMessage);
|
|
655
|
-
} else {
|
|
656
|
-
setError(null);
|
|
657
|
-
}
|
|
597
|
+
props.onChange?.(e);
|
|
658
598
|
};
|
|
659
599
|
return /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(import_jsx_runtime12.Fragment, { children: [
|
|
660
600
|
/* @__PURE__ */ (0, import_jsx_runtime12.jsxs)("div", { className: "flex justify-start items-center relative", children: [
|
|
@@ -664,7 +604,7 @@ var EmailInput = ({ className, style, ...props }) => {
|
|
|
664
604
|
{
|
|
665
605
|
type: "email",
|
|
666
606
|
name: props.name,
|
|
667
|
-
value: props.value
|
|
607
|
+
value: props.value,
|
|
668
608
|
className: cn(className, error ? "border-red-500" : ""),
|
|
669
609
|
style: {
|
|
670
610
|
...style,
|
|
@@ -674,10 +614,7 @@ var EmailInput = ({ className, style, ...props }) => {
|
|
|
674
614
|
placeholder,
|
|
675
615
|
onChange: handleChange,
|
|
676
616
|
disabled: isDisabled || !isEditable,
|
|
677
|
-
readOnly: isReadonly
|
|
678
|
-
required: isRequired,
|
|
679
|
-
maxLength: noOfCharacters,
|
|
680
|
-
pattern: regexPattern || void 0
|
|
617
|
+
readOnly: isReadonly
|
|
681
618
|
}
|
|
682
619
|
)
|
|
683
620
|
] }),
|
|
@@ -691,35 +628,17 @@ var React5 = __toESM(require("react"));
|
|
|
691
628
|
var import_jsx_runtime13 = require("react/jsx-runtime");
|
|
692
629
|
var PasswordInput = ({ className, style, ...props }) => {
|
|
693
630
|
const placeholder = props.placeholder ?? "Placeholder text";
|
|
694
|
-
const regexPattern = props.regexPattern ?? "";
|
|
695
|
-
const errorMessage = props.errorMessage ?? "Required";
|
|
696
|
-
const noOfCharacters = props.noOfCharacters ?? 100;
|
|
697
|
-
const isRequired = props.isRequired ?? false;
|
|
698
631
|
const isEditable = props.isEditable ?? true;
|
|
699
632
|
const isDisabled = props.isDisabled ?? false;
|
|
700
633
|
const isReadonly = props.isReadonly ?? false;
|
|
701
634
|
const isAutocomplete = props.isAutocomplete ?? false;
|
|
702
|
-
const [value, setValue] = React5.useState("");
|
|
703
635
|
const [error, setError] = React5.useState(null);
|
|
704
636
|
React5.useEffect(() => {
|
|
705
637
|
if (!props.validateOnMount) return;
|
|
706
638
|
setError(props.errorMessage || null);
|
|
707
639
|
}, [props.errorMessage, props.validateOnMount]);
|
|
708
640
|
const handleChange = (e) => {
|
|
709
|
-
|
|
710
|
-
props.onChange?.(e);
|
|
711
|
-
return;
|
|
712
|
-
}
|
|
713
|
-
const val = e.target.value;
|
|
714
|
-
if (val.length > noOfCharacters) return;
|
|
715
|
-
setValue(val);
|
|
716
|
-
if (isRequired && val.trim() === "") {
|
|
717
|
-
setError(errorMessage);
|
|
718
|
-
} else if (regexPattern && !new RegExp(regexPattern).test(val)) {
|
|
719
|
-
setError(errorMessage);
|
|
720
|
-
} else {
|
|
721
|
-
setError(null);
|
|
722
|
-
}
|
|
641
|
+
props.onChange?.(e);
|
|
723
642
|
};
|
|
724
643
|
return /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)(import_jsx_runtime13.Fragment, { children: [
|
|
725
644
|
/* @__PURE__ */ (0, import_jsx_runtime13.jsxs)("div", { className: "flex justify-start items-center relative", children: [
|
|
@@ -728,9 +647,9 @@ var PasswordInput = ({ className, style, ...props }) => {
|
|
|
728
647
|
Input,
|
|
729
648
|
{
|
|
730
649
|
type: "password",
|
|
731
|
-
id: "password-field",
|
|
650
|
+
id: props.name || "password-field",
|
|
732
651
|
name: props.name,
|
|
733
|
-
value: props.value
|
|
652
|
+
value: props.value,
|
|
734
653
|
className: cn(className, error ? "border-red-500" : ""),
|
|
735
654
|
style: {
|
|
736
655
|
...style,
|
|
@@ -740,10 +659,7 @@ var PasswordInput = ({ className, style, ...props }) => {
|
|
|
740
659
|
placeholder,
|
|
741
660
|
onChange: handleChange,
|
|
742
661
|
disabled: isDisabled || !isEditable,
|
|
743
|
-
readOnly: isReadonly
|
|
744
|
-
required: isRequired,
|
|
745
|
-
maxLength: noOfCharacters,
|
|
746
|
-
pattern: regexPattern || void 0
|
|
662
|
+
readOnly: isReadonly
|
|
747
663
|
}
|
|
748
664
|
)
|
|
749
665
|
] }),
|
|
@@ -775,35 +691,17 @@ function Textarea({ className, ...props }) {
|
|
|
775
691
|
var import_jsx_runtime15 = require("react/jsx-runtime");
|
|
776
692
|
var Textarea2 = ({ className, style, ...props }) => {
|
|
777
693
|
const placeholder = props.placeholder ?? "Placeholder text";
|
|
778
|
-
const regexPattern = props.regexPattern ?? "";
|
|
779
|
-
const errorMessage = props.errorMessage ?? "Required";
|
|
780
|
-
const noOfCharacters = props.noOfCharacters ?? 100;
|
|
781
|
-
const isRequired = props.isRequired ?? false;
|
|
782
694
|
const isEditable = props.isEditable ?? true;
|
|
783
695
|
const isDisabled = props.isDisabled ?? false;
|
|
784
696
|
const isReadonly = props.isReadonly ?? false;
|
|
785
697
|
const isAutocomplete = props.isAutocomplete ?? false;
|
|
786
|
-
const [value, setValue] = React6.useState("");
|
|
787
698
|
const [error, setError] = React6.useState(null);
|
|
788
699
|
React6.useEffect(() => {
|
|
789
700
|
if (!props.validateOnMount) return;
|
|
790
701
|
setError(props.errorMessage || null);
|
|
791
702
|
}, [props.errorMessage, props.validateOnMount]);
|
|
792
703
|
const handleChange = (e) => {
|
|
793
|
-
|
|
794
|
-
props.onChange?.(e);
|
|
795
|
-
return;
|
|
796
|
-
}
|
|
797
|
-
const val = e.target.value;
|
|
798
|
-
if (val.length > noOfCharacters) return;
|
|
799
|
-
setValue(val);
|
|
800
|
-
if (isRequired && val.trim() === "") {
|
|
801
|
-
setError(errorMessage);
|
|
802
|
-
} else if (regexPattern && !new RegExp(regexPattern).test(val)) {
|
|
803
|
-
setError(errorMessage);
|
|
804
|
-
} else {
|
|
805
|
-
setError(null);
|
|
806
|
-
}
|
|
704
|
+
props.onChange?.(e);
|
|
807
705
|
};
|
|
808
706
|
return /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)(import_jsx_runtime15.Fragment, { children: [
|
|
809
707
|
/* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
|
|
@@ -811,7 +709,7 @@ var Textarea2 = ({ className, style, ...props }) => {
|
|
|
811
709
|
{
|
|
812
710
|
id: "textarea-field",
|
|
813
711
|
name: props.name,
|
|
814
|
-
value: props.value
|
|
712
|
+
value: props.value,
|
|
815
713
|
className: cn(className, error ? "border-red-500" : ""),
|
|
816
714
|
style: {
|
|
817
715
|
...style,
|
|
@@ -821,9 +719,7 @@ var Textarea2 = ({ className, style, ...props }) => {
|
|
|
821
719
|
placeholder,
|
|
822
720
|
onChange: handleChange,
|
|
823
721
|
disabled: isDisabled || !isEditable,
|
|
824
|
-
readOnly: isReadonly
|
|
825
|
-
required: isRequired,
|
|
826
|
-
maxLength: noOfCharacters
|
|
722
|
+
readOnly: isReadonly
|
|
827
723
|
}
|
|
828
724
|
),
|
|
829
725
|
error && /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("p", { className: "mt-1 text-xs text-red-500", children: error })
|
|
@@ -836,35 +732,17 @@ var React7 = __toESM(require("react"));
|
|
|
836
732
|
var import_jsx_runtime16 = require("react/jsx-runtime");
|
|
837
733
|
var UrlInput = ({ className, style, ...props }) => {
|
|
838
734
|
const placeholder = props.placeholder ?? "Placeholder text";
|
|
839
|
-
const regexPattern = props.regexPattern ?? "";
|
|
840
|
-
const errorMessage = props.errorMessage ?? "Required";
|
|
841
|
-
const noOfCharacters = props.noOfCharacters ?? 100;
|
|
842
|
-
const isRequired = props.isRequired ?? false;
|
|
843
735
|
const isEditable = props.isEditable ?? true;
|
|
844
736
|
const isDisabled = props.isDisabled ?? false;
|
|
845
737
|
const isReadonly = props.isReadonly ?? false;
|
|
846
738
|
const isAutocomplete = props.isAutocomplete ?? false;
|
|
847
|
-
const [value, setValue] = React7.useState("");
|
|
848
739
|
const [error, setError] = React7.useState(null);
|
|
849
740
|
React7.useEffect(() => {
|
|
850
741
|
if (!props.validateOnMount) return;
|
|
851
742
|
setError(props.errorMessage || null);
|
|
852
743
|
}, [props.errorMessage, props.validateOnMount]);
|
|
853
744
|
const handleChange = (e) => {
|
|
854
|
-
|
|
855
|
-
props.onChange?.(e);
|
|
856
|
-
return;
|
|
857
|
-
}
|
|
858
|
-
const val = e.target.value;
|
|
859
|
-
if (val.length > noOfCharacters) return;
|
|
860
|
-
setValue(val);
|
|
861
|
-
if (isRequired && val.trim() === "") {
|
|
862
|
-
setError(errorMessage);
|
|
863
|
-
} else if (regexPattern && !new RegExp(regexPattern).test(val)) {
|
|
864
|
-
setError(errorMessage);
|
|
865
|
-
} else {
|
|
866
|
-
setError(null);
|
|
867
|
-
}
|
|
745
|
+
props.onChange?.(e);
|
|
868
746
|
};
|
|
869
747
|
return /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)(import_jsx_runtime16.Fragment, { children: [
|
|
870
748
|
/* @__PURE__ */ (0, import_jsx_runtime16.jsxs)("div", { className: "flex justify-start items-center relative", children: [
|
|
@@ -875,7 +753,7 @@ var UrlInput = ({ className, style, ...props }) => {
|
|
|
875
753
|
id: "url-field",
|
|
876
754
|
type: "url",
|
|
877
755
|
name: props.name,
|
|
878
|
-
value: props.value
|
|
756
|
+
value: props.value,
|
|
879
757
|
className: cn(className, error ? "border-red-500" : ""),
|
|
880
758
|
style: {
|
|
881
759
|
...style,
|
|
@@ -885,10 +763,7 @@ var UrlInput = ({ className, style, ...props }) => {
|
|
|
885
763
|
placeholder,
|
|
886
764
|
onChange: handleChange,
|
|
887
765
|
disabled: isDisabled || !isEditable,
|
|
888
|
-
readOnly: isReadonly
|
|
889
|
-
required: isRequired,
|
|
890
|
-
maxLength: noOfCharacters,
|
|
891
|
-
pattern: regexPattern || void 0
|
|
766
|
+
readOnly: isReadonly
|
|
892
767
|
}
|
|
893
768
|
)
|
|
894
769
|
] }),
|
|
@@ -897,6 +772,9 @@ var UrlInput = ({ className, style, ...props }) => {
|
|
|
897
772
|
};
|
|
898
773
|
var UrlInput_default = UrlInput;
|
|
899
774
|
|
|
775
|
+
// src/components/Inputs/Checkbox/Checkbox.tsx
|
|
776
|
+
var import_react5 = require("react");
|
|
777
|
+
|
|
900
778
|
// src/components/ui/checkbox.tsx
|
|
901
779
|
var CheckboxPrimitive = __toESM(require("@radix-ui/react-checkbox"));
|
|
902
780
|
var import_jsx_runtime17 = require("react/jsx-runtime");
|
|
@@ -948,14 +826,38 @@ function Label({
|
|
|
948
826
|
// src/components/Inputs/Checkbox/Checkbox.tsx
|
|
949
827
|
var import_jsx_runtime19 = require("react/jsx-runtime");
|
|
950
828
|
var CheckboxInput = ({ className, style, ...props }) => {
|
|
829
|
+
const isEditable = props.isEditable ?? true;
|
|
830
|
+
const isDisabled = props.isDisabled ?? false;
|
|
951
831
|
const text = props.text ? props.text : "Subscribe";
|
|
952
|
-
|
|
953
|
-
|
|
954
|
-
|
|
955
|
-
|
|
832
|
+
const [error, setError] = (0, import_react5.useState)(null);
|
|
833
|
+
(0, import_react5.useEffect)(() => {
|
|
834
|
+
if (!props.validateOnMount) return;
|
|
835
|
+
setError(props.errorMessage || null);
|
|
836
|
+
}, [props.errorMessage, props.validateOnMount]);
|
|
837
|
+
const handleChange = (value) => {
|
|
838
|
+
props.onChange?.(value);
|
|
839
|
+
};
|
|
840
|
+
return /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)(import_jsx_runtime19.Fragment, { children: [
|
|
841
|
+
/* @__PURE__ */ (0, import_jsx_runtime19.jsx)("div", { className, style, children: /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)("div", { className: "flex items-center space-x-2", children: [
|
|
842
|
+
/* @__PURE__ */ (0, import_jsx_runtime19.jsx)(
|
|
843
|
+
Checkbox,
|
|
844
|
+
{
|
|
845
|
+
id: props.name || "checkbox",
|
|
846
|
+
checked: !!props.value,
|
|
847
|
+
onCheckedChange: handleChange,
|
|
848
|
+
disabled: !isEditable || isDisabled
|
|
849
|
+
}
|
|
850
|
+
),
|
|
851
|
+
/* @__PURE__ */ (0, import_jsx_runtime19.jsx)(Label, { htmlFor: props.name || "checkbox", children: text })
|
|
852
|
+
] }) }),
|
|
853
|
+
error && /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("p", { className: "mt-1 text-xs text-red-500", children: error })
|
|
854
|
+
] });
|
|
956
855
|
};
|
|
957
856
|
var Checkbox_default = CheckboxInput;
|
|
958
857
|
|
|
858
|
+
// src/components/Inputs/RadioInput/RadioInput.tsx
|
|
859
|
+
var import_react6 = require("react");
|
|
860
|
+
|
|
959
861
|
// src/components/ui/radio-group.tsx
|
|
960
862
|
var RadioGroupPrimitive = __toESM(require("@radix-ui/react-radio-group"));
|
|
961
863
|
var import_jsx_runtime20 = require("react/jsx-runtime");
|
|
@@ -999,39 +901,108 @@ function RadioGroupItem({
|
|
|
999
901
|
|
|
1000
902
|
// src/components/Inputs/RadioInput/RadioInput.tsx
|
|
1001
903
|
var import_jsx_runtime21 = require("react/jsx-runtime");
|
|
1002
|
-
var RadioInput = ({
|
|
1003
|
-
|
|
1004
|
-
|
|
1005
|
-
|
|
1006
|
-
|
|
904
|
+
var RadioInput = ({
|
|
905
|
+
className,
|
|
906
|
+
style,
|
|
907
|
+
defaultValue,
|
|
908
|
+
onChange,
|
|
909
|
+
data = [],
|
|
910
|
+
dataKey,
|
|
911
|
+
dataLabel,
|
|
912
|
+
...props
|
|
913
|
+
}) => {
|
|
914
|
+
const [error, setError] = (0, import_react6.useState)(null);
|
|
915
|
+
(0, import_react6.useEffect)(() => {
|
|
916
|
+
if (!props.validateOnMount) return;
|
|
917
|
+
setError(props.errorMessage || null);
|
|
918
|
+
}, [props.errorMessage, props.validateOnMount]);
|
|
919
|
+
const options = (data || []).map((item) => ({
|
|
920
|
+
value: item[dataKey || "value"],
|
|
921
|
+
label: item[dataLabel || "label"]
|
|
1007
922
|
}));
|
|
1008
|
-
|
|
1009
|
-
|
|
1010
|
-
|
|
1011
|
-
|
|
923
|
+
const handleChange = (value) => {
|
|
924
|
+
onChange?.(value);
|
|
925
|
+
};
|
|
926
|
+
const resolvedDefaultValue = (typeof defaultValue === "string" ? defaultValue : void 0) ?? options[0]?.value;
|
|
927
|
+
return /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)(import_jsx_runtime21.Fragment, { children: [
|
|
928
|
+
/* @__PURE__ */ (0, import_jsx_runtime21.jsx)("div", { className, style, children: /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)(
|
|
929
|
+
RadioGroup,
|
|
930
|
+
{
|
|
931
|
+
defaultValue: resolvedDefaultValue,
|
|
932
|
+
onValueChange: handleChange,
|
|
933
|
+
children: [
|
|
934
|
+
options.length === 0 && /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("div", { className: "text-sm text-gray-500", children: "No options available" }),
|
|
935
|
+
options.map((item) => /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)("div", { className: "flex items-center space-x-2", children: [
|
|
936
|
+
/* @__PURE__ */ (0, import_jsx_runtime21.jsx)(RadioGroupItem, { value: item.value, id: `radio-${item.value}` }),
|
|
937
|
+
/* @__PURE__ */ (0, import_jsx_runtime21.jsx)(Label, { htmlFor: `radio-${item.value}`, children: item.label })
|
|
938
|
+
] }, item.value))
|
|
939
|
+
]
|
|
940
|
+
}
|
|
941
|
+
) }),
|
|
942
|
+
error && /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("p", { className: "mt-1 text-xs text-red-500", children: error })
|
|
943
|
+
] });
|
|
1012
944
|
};
|
|
1013
945
|
var RadioInput_default = RadioInput;
|
|
1014
946
|
|
|
1015
947
|
// src/components/Inputs/MultiCheckbox/MultiCheckbox.tsx
|
|
948
|
+
var import_react7 = require("react");
|
|
1016
949
|
var import_jsx_runtime22 = require("react/jsx-runtime");
|
|
1017
|
-
var MultiCheckbox = ({
|
|
1018
|
-
|
|
1019
|
-
|
|
1020
|
-
|
|
1021
|
-
|
|
950
|
+
var MultiCheckbox = ({
|
|
951
|
+
className,
|
|
952
|
+
style,
|
|
953
|
+
data = [],
|
|
954
|
+
dataKey = "value",
|
|
955
|
+
dataLabel = "label",
|
|
956
|
+
value: propValue = {},
|
|
957
|
+
onChange,
|
|
958
|
+
isEditable = true,
|
|
959
|
+
isDisabled = false
|
|
960
|
+
}) => {
|
|
961
|
+
const [value, setValue] = (0, import_react7.useState)(propValue);
|
|
962
|
+
const options = (data || []).map((item) => ({
|
|
963
|
+
value: item[dataKey || "value"],
|
|
964
|
+
label: item[dataLabel || "label"]
|
|
1022
965
|
}));
|
|
1023
|
-
|
|
1024
|
-
|
|
1025
|
-
|
|
1026
|
-
|
|
966
|
+
const handleChange = (0, import_react7.useCallback)(
|
|
967
|
+
(key, checked) => {
|
|
968
|
+
setValue((prev) => {
|
|
969
|
+
const newValue = { ...prev, [key]: checked };
|
|
970
|
+
onChange?.(newValue);
|
|
971
|
+
return newValue;
|
|
972
|
+
});
|
|
973
|
+
},
|
|
974
|
+
[onChange]
|
|
975
|
+
);
|
|
976
|
+
return /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)(
|
|
977
|
+
"div",
|
|
978
|
+
{
|
|
979
|
+
className: cn("flex flex-col gap-3", className),
|
|
980
|
+
style,
|
|
981
|
+
children: [
|
|
982
|
+
options.length === 0 && /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("p", { className: "text-sm text-gray-500", children: "No options available." }),
|
|
983
|
+
options.map((opt) => /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)("div", { className: "flex items-center space-x-2", children: [
|
|
984
|
+
/* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
|
|
985
|
+
Checkbox,
|
|
986
|
+
{
|
|
987
|
+
id: opt.value,
|
|
988
|
+
checked: !!value[opt.value],
|
|
989
|
+
onCheckedChange: (checked) => handleChange(opt.value, checked === true),
|
|
990
|
+
disabled: !isEditable || isDisabled
|
|
991
|
+
}
|
|
992
|
+
),
|
|
993
|
+
/* @__PURE__ */ (0, import_jsx_runtime22.jsx)(Label, { htmlFor: opt.value, children: opt.label })
|
|
994
|
+
] }, opt.value))
|
|
995
|
+
]
|
|
996
|
+
}
|
|
997
|
+
);
|
|
1027
998
|
};
|
|
1028
999
|
var MultiCheckbox_default = MultiCheckbox;
|
|
1029
1000
|
|
|
1030
1001
|
// src/components/Inputs/RichText/RichText.tsx
|
|
1031
|
-
var
|
|
1002
|
+
var import_react9 = require("react");
|
|
1032
1003
|
|
|
1033
1004
|
// src/components/Global/TinyMceEditor.tsx
|
|
1034
|
-
var
|
|
1005
|
+
var import_react8 = require("react");
|
|
1035
1006
|
var import_tinymce_react = require("@tinymce/tinymce-react");
|
|
1036
1007
|
var import_jsx_runtime23 = require("react/jsx-runtime");
|
|
1037
1008
|
function MyEditor({
|
|
@@ -1039,7 +1010,7 @@ function MyEditor({
|
|
|
1039
1010
|
onChange,
|
|
1040
1011
|
isDefault
|
|
1041
1012
|
}) {
|
|
1042
|
-
const editorRef = (0,
|
|
1013
|
+
const editorRef = (0, import_react8.useRef)(null);
|
|
1043
1014
|
function stripOuterP(html) {
|
|
1044
1015
|
const trimmedHtml = html.trim();
|
|
1045
1016
|
if (!trimmedHtml) return "";
|
|
@@ -1051,7 +1022,7 @@ function MyEditor({
|
|
|
1051
1022
|
}
|
|
1052
1023
|
return trimmedHtml;
|
|
1053
1024
|
}
|
|
1054
|
-
const isDefaultToolbar = (0,
|
|
1025
|
+
const isDefaultToolbar = (0, import_react8.useMemo)(() => {
|
|
1055
1026
|
let toolbar = "undo redo | formatselect | bold italic forecolor";
|
|
1056
1027
|
if (isDefault) {
|
|
1057
1028
|
toolbar = "undo redo | blocks | bold italic forecolor | alignleft aligncenter alignright alignjustify | bullist numlist outdent indent | removeformat | help";
|
|
@@ -1104,8 +1075,8 @@ function MyEditor({
|
|
|
1104
1075
|
// src/components/Inputs/RichText/RichText.tsx
|
|
1105
1076
|
var import_jsx_runtime24 = require("react/jsx-runtime");
|
|
1106
1077
|
function RichText({ className, style, ...props }) {
|
|
1107
|
-
const [error, setError] = (0,
|
|
1108
|
-
(0,
|
|
1078
|
+
const [error, setError] = (0, import_react9.useState)(null);
|
|
1079
|
+
(0, import_react9.useEffect)(() => {
|
|
1109
1080
|
if (!props.validateOnMount) return;
|
|
1110
1081
|
setError(props.errorMessage || null);
|
|
1111
1082
|
}, [props.errorMessage, props.validateOnMount]);
|
|
@@ -1254,106 +1225,61 @@ function SelectScrollDownButton({
|
|
|
1254
1225
|
);
|
|
1255
1226
|
}
|
|
1256
1227
|
|
|
1257
|
-
// src/components/Global/SelectDropdown.tsx
|
|
1258
|
-
var import_jsx_runtime26 = require("react/jsx-runtime");
|
|
1259
|
-
function SelectDropdown({
|
|
1260
|
-
options,
|
|
1261
|
-
placeholder = "Select an option",
|
|
1262
|
-
value,
|
|
1263
|
-
onChange,
|
|
1264
|
-
className,
|
|
1265
|
-
id,
|
|
1266
|
-
disabled,
|
|
1267
|
-
readOnly,
|
|
1268
|
-
style,
|
|
1269
|
-
name
|
|
1270
|
-
}) {
|
|
1271
|
-
return /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(Select, { name, value, onValueChange: onChange, disabled, children: [
|
|
1272
|
-
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
|
|
1273
|
-
SelectTrigger,
|
|
1274
|
-
{
|
|
1275
|
-
id,
|
|
1276
|
-
className,
|
|
1277
|
-
style: style ?? {},
|
|
1278
|
-
"aria-readonly": readOnly,
|
|
1279
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(SelectValue, { placeholder })
|
|
1280
|
-
}
|
|
1281
|
-
),
|
|
1282
|
-
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)(SelectContent, { children: options.map((opt) => /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(SelectItem, { value: opt.value, children: opt.label }, opt.value)) })
|
|
1283
|
-
] });
|
|
1284
|
-
}
|
|
1285
|
-
|
|
1286
1228
|
// src/components/Inputs/Dropdown/Dropdown.tsx
|
|
1287
|
-
var
|
|
1229
|
+
var import_jsx_runtime26 = require("react/jsx-runtime");
|
|
1288
1230
|
var Dropdown = ({ className, style, ...props }) => {
|
|
1289
|
-
const
|
|
1231
|
+
const list = props.data || [];
|
|
1290
1232
|
const placeholder = props.placeholder ? props.placeholder : "Placeholder text";
|
|
1291
|
-
const formatList = text.filter((i) => i.value && i.label).map((item) => ({
|
|
1292
|
-
label: item.label,
|
|
1293
|
-
value: item.value
|
|
1294
|
-
}));
|
|
1295
|
-
const regexPattern = props.regexPattern ?? "";
|
|
1296
|
-
const errorMessage = props.errorMessage ?? "Required";
|
|
1297
|
-
const isRequired = props.isRequired ?? false;
|
|
1298
1233
|
const isEditable = props.isEditable ?? true;
|
|
1299
1234
|
const isDisabled = props.isDisabled ?? false;
|
|
1300
1235
|
const isReadonly = props.isReadonly ?? false;
|
|
1301
|
-
const isAutocomplete = props.isAutocomplete ?? false;
|
|
1302
|
-
const [value, setValue] = React8.useState("");
|
|
1303
1236
|
const [error, setError] = React8.useState(null);
|
|
1304
1237
|
React8.useEffect(() => {
|
|
1305
1238
|
if (!props.validateOnMount) return;
|
|
1306
1239
|
setError(props.errorMessage || null);
|
|
1307
1240
|
}, [props.errorMessage, props.validateOnMount]);
|
|
1308
|
-
const handleChange = (
|
|
1309
|
-
|
|
1310
|
-
props.onChange?.(val);
|
|
1311
|
-
return;
|
|
1312
|
-
}
|
|
1313
|
-
setValue(val);
|
|
1314
|
-
if (isRequired && val.trim() === "") {
|
|
1315
|
-
setError(errorMessage);
|
|
1316
|
-
} else if (regexPattern && !new RegExp(regexPattern).test(val)) {
|
|
1317
|
-
setError(errorMessage);
|
|
1318
|
-
} else {
|
|
1319
|
-
setError(null);
|
|
1320
|
-
}
|
|
1241
|
+
const handleChange = (value) => {
|
|
1242
|
+
props.onChange?.(value);
|
|
1321
1243
|
};
|
|
1322
|
-
|
|
1323
|
-
|
|
1324
|
-
|
|
1325
|
-
|
|
1326
|
-
|
|
1327
|
-
|
|
1328
|
-
|
|
1329
|
-
|
|
1330
|
-
|
|
1331
|
-
|
|
1332
|
-
|
|
1333
|
-
|
|
1334
|
-
|
|
1335
|
-
|
|
1336
|
-
|
|
1337
|
-
|
|
1338
|
-
|
|
1339
|
-
|
|
1340
|
-
|
|
1341
|
-
|
|
1342
|
-
|
|
1343
|
-
|
|
1344
|
-
|
|
1244
|
+
const dataKey = props.dataKey || "value";
|
|
1245
|
+
const dataLabel = props.dataLabel || "label";
|
|
1246
|
+
const options = list.map((item) => ({
|
|
1247
|
+
value: item[dataKey],
|
|
1248
|
+
label: item[dataLabel]
|
|
1249
|
+
}));
|
|
1250
|
+
return /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(import_jsx_runtime26.Fragment, { children: [
|
|
1251
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(Select, { name: props.name, value: props.value, onValueChange: handleChange, disabled: isDisabled || !isEditable, children: [
|
|
1252
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
|
|
1253
|
+
SelectTrigger,
|
|
1254
|
+
{
|
|
1255
|
+
id: props.name || "select-field",
|
|
1256
|
+
className: cn(className, error ? "border-red-500" : ""),
|
|
1257
|
+
style: {
|
|
1258
|
+
...style,
|
|
1259
|
+
borderColor: error ? "#f87171" : style?.borderColor
|
|
1260
|
+
},
|
|
1261
|
+
"aria-readonly": isReadonly,
|
|
1262
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(SelectValue, { placeholder })
|
|
1263
|
+
}
|
|
1264
|
+
),
|
|
1265
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)(SelectContent, { children: options.map((opt) => /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(SelectItem, { value: opt.value, children: opt.label }, opt.value)) })
|
|
1266
|
+
] }),
|
|
1267
|
+
error && /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("p", { className: "mt-1 text-xs text-red-500", children: error })
|
|
1345
1268
|
] });
|
|
1346
1269
|
};
|
|
1347
1270
|
var Dropdown_default = Dropdown;
|
|
1348
1271
|
|
|
1272
|
+
// src/components/Inputs/SwitchToggle/SwitchToggle.tsx
|
|
1273
|
+
var import_react10 = require("react");
|
|
1274
|
+
|
|
1349
1275
|
// src/components/ui/switch.tsx
|
|
1350
1276
|
var SwitchPrimitive = __toESM(require("@radix-ui/react-switch"));
|
|
1351
|
-
var
|
|
1277
|
+
var import_jsx_runtime27 = require("react/jsx-runtime");
|
|
1352
1278
|
function Switch({
|
|
1353
1279
|
className,
|
|
1354
1280
|
...props
|
|
1355
1281
|
}) {
|
|
1356
|
-
return /* @__PURE__ */ (0,
|
|
1282
|
+
return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
|
|
1357
1283
|
SwitchPrimitive.Root,
|
|
1358
1284
|
{
|
|
1359
1285
|
"data-slot": "switch",
|
|
@@ -1362,7 +1288,7 @@ function Switch({
|
|
|
1362
1288
|
className
|
|
1363
1289
|
),
|
|
1364
1290
|
...props,
|
|
1365
|
-
children: /* @__PURE__ */ (0,
|
|
1291
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
|
|
1366
1292
|
SwitchPrimitive.Thumb,
|
|
1367
1293
|
{
|
|
1368
1294
|
"data-slot": "switch-thumb",
|
|
@@ -1376,13 +1302,33 @@ function Switch({
|
|
|
1376
1302
|
}
|
|
1377
1303
|
|
|
1378
1304
|
// src/components/Inputs/SwitchToggle/SwitchToggle.tsx
|
|
1379
|
-
var
|
|
1305
|
+
var import_jsx_runtime28 = require("react/jsx-runtime");
|
|
1380
1306
|
var SwitchToggle = ({ className, style, ...props }) => {
|
|
1381
|
-
const
|
|
1382
|
-
|
|
1383
|
-
|
|
1384
|
-
|
|
1385
|
-
|
|
1307
|
+
const isEditable = props.isEditable ?? true;
|
|
1308
|
+
const isDisabled = props.isDisabled ?? false;
|
|
1309
|
+
const [error, setError] = (0, import_react10.useState)(null);
|
|
1310
|
+
(0, import_react10.useEffect)(() => {
|
|
1311
|
+
if (!props.validateOnMount) return;
|
|
1312
|
+
setError(props.errorMessage || null);
|
|
1313
|
+
}, [props.errorMessage, props.validateOnMount]);
|
|
1314
|
+
const handleChange = (value) => {
|
|
1315
|
+
props.onChange?.(value);
|
|
1316
|
+
};
|
|
1317
|
+
return /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)(import_jsx_runtime28.Fragment, { children: [
|
|
1318
|
+
/* @__PURE__ */ (0, import_jsx_runtime28.jsx)("div", { className, style, children: /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)("div", { className: "flex items-center space-x-2 mb-2", children: [
|
|
1319
|
+
/* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
|
|
1320
|
+
Switch,
|
|
1321
|
+
{
|
|
1322
|
+
id: props.name || "switch",
|
|
1323
|
+
checked: !!props.value,
|
|
1324
|
+
onCheckedChange: handleChange,
|
|
1325
|
+
disabled: isDisabled || !isEditable
|
|
1326
|
+
}
|
|
1327
|
+
),
|
|
1328
|
+
/* @__PURE__ */ (0, import_jsx_runtime28.jsx)(Label, { htmlFor: props.name || "switch", children: props.text })
|
|
1329
|
+
] }) }),
|
|
1330
|
+
error && /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("p", { className: "mt-1 text-xs text-red-500", children: error })
|
|
1331
|
+
] });
|
|
1386
1332
|
};
|
|
1387
1333
|
var SwitchToggle_default = SwitchToggle;
|
|
1388
1334
|
|
|
@@ -1390,14 +1336,9 @@ var SwitchToggle_default = SwitchToggle;
|
|
|
1390
1336
|
var React9 = __toESM(require("react"));
|
|
1391
1337
|
var import_react_international_phone = require("react-international-phone");
|
|
1392
1338
|
var import_style = require("react-international-phone/style.css");
|
|
1393
|
-
var
|
|
1339
|
+
var import_jsx_runtime29 = require("react/jsx-runtime");
|
|
1394
1340
|
var PhoneInput = ({ className, style, ...props }) => {
|
|
1395
1341
|
const placeholder = props.placeholder ?? "Enter phone number";
|
|
1396
|
-
const [value, setValue] = React9.useState("");
|
|
1397
|
-
const regexPattern = props.regexPattern ?? "";
|
|
1398
|
-
const errorMessage = props.errorMessage ?? "Required";
|
|
1399
|
-
const noOfCharacters = props.noOfCharacters ?? 100;
|
|
1400
|
-
const isRequired = props.isRequired ?? false;
|
|
1401
1342
|
const isEditable = props.isEditable ?? true;
|
|
1402
1343
|
const isDisabled = props.isDisabled ?? false;
|
|
1403
1344
|
const [error, setError] = React9.useState(null);
|
|
@@ -1406,27 +1347,15 @@ var PhoneInput = ({ className, style, ...props }) => {
|
|
|
1406
1347
|
setError(props.errorMessage || null);
|
|
1407
1348
|
}, [props.errorMessage, props.validateOnMount]);
|
|
1408
1349
|
const handleChange = (val) => {
|
|
1409
|
-
|
|
1410
|
-
props.onChange?.(val);
|
|
1411
|
-
return;
|
|
1412
|
-
}
|
|
1413
|
-
if (val.length > noOfCharacters) return;
|
|
1414
|
-
setValue(val);
|
|
1415
|
-
if (isRequired && val.trim() === "") {
|
|
1416
|
-
setError(errorMessage);
|
|
1417
|
-
} else if (regexPattern && !new RegExp(regexPattern).test(val)) {
|
|
1418
|
-
setError(errorMessage);
|
|
1419
|
-
} else {
|
|
1420
|
-
setError(null);
|
|
1421
|
-
}
|
|
1350
|
+
props.onChange?.(val);
|
|
1422
1351
|
};
|
|
1423
|
-
return /* @__PURE__ */ (0,
|
|
1424
|
-
/* @__PURE__ */ (0,
|
|
1352
|
+
return /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)(import_jsx_runtime29.Fragment, { children: [
|
|
1353
|
+
/* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
|
|
1425
1354
|
import_react_international_phone.PhoneInput,
|
|
1426
1355
|
{
|
|
1427
1356
|
defaultCountry: "in",
|
|
1428
1357
|
name: props.name,
|
|
1429
|
-
value: props.value
|
|
1358
|
+
value: props.value,
|
|
1430
1359
|
className: cn(className, error ? "border-red-500" : ""),
|
|
1431
1360
|
style: {
|
|
1432
1361
|
...style,
|
|
@@ -1434,64 +1363,44 @@ var PhoneInput = ({ className, style, ...props }) => {
|
|
|
1434
1363
|
},
|
|
1435
1364
|
onChange: (phone) => handleChange(phone),
|
|
1436
1365
|
inputProps: {
|
|
1437
|
-
id: "phone-field"
|
|
1438
|
-
required: isRequired
|
|
1366
|
+
id: "phone-field"
|
|
1439
1367
|
},
|
|
1440
1368
|
placeholder,
|
|
1441
|
-
disabled: isDisabled || !isEditable
|
|
1442
|
-
required: isRequired
|
|
1369
|
+
disabled: isDisabled || !isEditable
|
|
1443
1370
|
}
|
|
1444
1371
|
),
|
|
1445
|
-
error && /* @__PURE__ */ (0,
|
|
1372
|
+
error && /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("p", { className: "mt-1 text-xs text-red-500", children: error })
|
|
1446
1373
|
] });
|
|
1447
1374
|
};
|
|
1448
1375
|
var PhoneInput_default = PhoneInput;
|
|
1449
1376
|
|
|
1450
1377
|
// src/components/Inputs/SearchInput/SearchInput.tsx
|
|
1451
1378
|
var React10 = __toESM(require("react"));
|
|
1452
|
-
var
|
|
1379
|
+
var import_jsx_runtime30 = require("react/jsx-runtime");
|
|
1453
1380
|
var SearchInput = ({ className, style, ...props }) => {
|
|
1454
1381
|
const placeholder = props.placeholder ?? "Placeholder text";
|
|
1455
|
-
const regexPattern = props.regexPattern ?? "";
|
|
1456
|
-
const errorMessage = props.errorMessage ?? "Required";
|
|
1457
|
-
const noOfCharacters = props.noOfCharacters ?? 100;
|
|
1458
|
-
const isRequired = props.isRequired ?? false;
|
|
1459
1382
|
const isEditable = props.isEditable ?? true;
|
|
1460
1383
|
const isDisabled = props.isDisabled ?? false;
|
|
1461
1384
|
const isReadonly = props.isReadonly ?? false;
|
|
1462
1385
|
const isAutocomplete = props.isAutocomplete ?? false;
|
|
1463
|
-
const [value, setValue] = React10.useState("");
|
|
1464
1386
|
const [error, setError] = React10.useState(null);
|
|
1465
1387
|
React10.useEffect(() => {
|
|
1466
1388
|
if (!props.validateOnMount) return;
|
|
1467
1389
|
setError(props.errorMessage || null);
|
|
1468
1390
|
}, [props.errorMessage, props.validateOnMount]);
|
|
1469
1391
|
const handleChange = (e) => {
|
|
1470
|
-
|
|
1471
|
-
props.onChange?.(e);
|
|
1472
|
-
return;
|
|
1473
|
-
}
|
|
1474
|
-
const val = e.target.value;
|
|
1475
|
-
if (val.length > noOfCharacters) return;
|
|
1476
|
-
setValue(val);
|
|
1477
|
-
if (isRequired && val.trim() === "") {
|
|
1478
|
-
setError(errorMessage);
|
|
1479
|
-
} else if (regexPattern && !new RegExp(regexPattern).test(val)) {
|
|
1480
|
-
setError(errorMessage);
|
|
1481
|
-
} else {
|
|
1482
|
-
setError(null);
|
|
1483
|
-
}
|
|
1392
|
+
props.onChange?.(e);
|
|
1484
1393
|
};
|
|
1485
|
-
return /* @__PURE__ */ (0,
|
|
1486
|
-
/* @__PURE__ */ (0,
|
|
1487
|
-
/* @__PURE__ */ (0,
|
|
1488
|
-
/* @__PURE__ */ (0,
|
|
1394
|
+
return /* @__PURE__ */ (0, import_jsx_runtime30.jsxs)(import_jsx_runtime30.Fragment, { children: [
|
|
1395
|
+
/* @__PURE__ */ (0, import_jsx_runtime30.jsxs)("div", { className: "flex justify-start items-center relative", children: [
|
|
1396
|
+
/* @__PURE__ */ (0, import_jsx_runtime30.jsx)(Search, { className: "left-3 top-1/2 h-4 w-4 -translate-y-1/2 text-[#BDBDBD]" }),
|
|
1397
|
+
/* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
|
|
1489
1398
|
Input,
|
|
1490
1399
|
{
|
|
1491
1400
|
type: "text",
|
|
1492
|
-
id: "text-field",
|
|
1401
|
+
id: props.name || "text-field",
|
|
1493
1402
|
name: props.name,
|
|
1494
|
-
value: props.value
|
|
1403
|
+
value: props.value,
|
|
1495
1404
|
className: cn(className, error ? "border-red-500" : ""),
|
|
1496
1405
|
style: {
|
|
1497
1406
|
...style,
|
|
@@ -1501,30 +1410,27 @@ var SearchInput = ({ className, style, ...props }) => {
|
|
|
1501
1410
|
placeholder,
|
|
1502
1411
|
onChange: handleChange,
|
|
1503
1412
|
disabled: isDisabled || !isEditable,
|
|
1504
|
-
readOnly: isReadonly
|
|
1505
|
-
required: isRequired,
|
|
1506
|
-
maxLength: noOfCharacters,
|
|
1507
|
-
pattern: regexPattern || void 0
|
|
1413
|
+
readOnly: isReadonly
|
|
1508
1414
|
}
|
|
1509
1415
|
)
|
|
1510
1416
|
] }),
|
|
1511
|
-
error && /* @__PURE__ */ (0,
|
|
1417
|
+
error && /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("p", { className: "mt-1 text-xs text-red-500", children: error })
|
|
1512
1418
|
] });
|
|
1513
1419
|
};
|
|
1514
1420
|
var SearchInput_default = SearchInput;
|
|
1515
1421
|
|
|
1516
1422
|
// src/components/Inputs/FileInput/FileInput.tsx
|
|
1517
|
-
var
|
|
1518
|
-
var
|
|
1423
|
+
var import_react11 = require("react");
|
|
1424
|
+
var import_jsx_runtime31 = require("react/jsx-runtime");
|
|
1519
1425
|
var FileInput = ({ className, style, ...props }) => {
|
|
1520
1426
|
const placeholder = props.placeholder ?? "Placeholder text";
|
|
1521
|
-
const [error, setError] = (0,
|
|
1522
|
-
(0,
|
|
1427
|
+
const [error, setError] = (0, import_react11.useState)(null);
|
|
1428
|
+
(0, import_react11.useEffect)(() => {
|
|
1523
1429
|
if (!props.validateOnMount) return;
|
|
1524
1430
|
setError(props.errorMessage || null);
|
|
1525
1431
|
}, [props.errorMessage, props.validateOnMount]);
|
|
1526
|
-
return /* @__PURE__ */ (0,
|
|
1527
|
-
/* @__PURE__ */ (0,
|
|
1432
|
+
return /* @__PURE__ */ (0, import_jsx_runtime31.jsxs)("div", { className: "d-flex items-center relative align-middle", children: [
|
|
1433
|
+
/* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
|
|
1528
1434
|
Input,
|
|
1529
1435
|
{
|
|
1530
1436
|
type: "file",
|
|
@@ -1539,35 +1445,29 @@ var FileInput = ({ className, style, ...props }) => {
|
|
|
1539
1445
|
autoComplete: "off",
|
|
1540
1446
|
placeholder,
|
|
1541
1447
|
onChange: (e) => {
|
|
1542
|
-
|
|
1543
|
-
props.onChange?.(e);
|
|
1544
|
-
return;
|
|
1545
|
-
}
|
|
1448
|
+
props.onChange?.(e);
|
|
1546
1449
|
}
|
|
1547
1450
|
}
|
|
1548
1451
|
),
|
|
1549
|
-
error && /* @__PURE__ */ (0,
|
|
1452
|
+
error && /* @__PURE__ */ (0, import_jsx_runtime31.jsx)("p", { className: "mt-1 text-xs text-red-500", children: error })
|
|
1550
1453
|
] });
|
|
1551
1454
|
};
|
|
1552
1455
|
var FileInput_default = FileInput;
|
|
1553
1456
|
|
|
1554
1457
|
// src/components/Inputs/DatePicker/DatePicker.tsx
|
|
1555
|
-
var
|
|
1556
|
-
var
|
|
1458
|
+
var import_react12 = __toESM(require("react"));
|
|
1459
|
+
var import_jsx_runtime32 = require("react/jsx-runtime");
|
|
1557
1460
|
function DatePicker({ className, style, ...props }) {
|
|
1558
1461
|
const placeholder = props.placeholder ?? "Placeholder text";
|
|
1559
1462
|
const minimumDate = props.minimumDate ?? "none";
|
|
1560
1463
|
const customMinimumDate = props.customMinimumDate ?? "";
|
|
1561
1464
|
const maximumDate = props.maximumDate ?? "none";
|
|
1562
1465
|
const customMaximumDate = props.customMaximumDate ?? "";
|
|
1563
|
-
const errorMessage = props.errorMessage ?? "Required";
|
|
1564
|
-
const isRequired = props.isRequired ?? false;
|
|
1565
1466
|
const isEditable = props.isEditable ?? true;
|
|
1566
1467
|
const isDisabled = props.isDisabled ?? false;
|
|
1567
1468
|
const isReadonly = props.isReadonly ?? false;
|
|
1568
1469
|
const isAutocomplete = props.isAutocomplete ?? false;
|
|
1569
|
-
const [
|
|
1570
|
-
const [error, setError] = import_react8.default.useState(null);
|
|
1470
|
+
const [error, setError] = import_react12.default.useState(null);
|
|
1571
1471
|
const resolveDate = (option, customOption) => {
|
|
1572
1472
|
if (!option) return void 0;
|
|
1573
1473
|
switch (option) {
|
|
@@ -1582,27 +1482,17 @@ function DatePicker({ className, style, ...props }) {
|
|
|
1582
1482
|
};
|
|
1583
1483
|
const minDate = resolveDate(minimumDate, customMinimumDate);
|
|
1584
1484
|
const maxDate = resolveDate(maximumDate, customMaximumDate);
|
|
1585
|
-
(0,
|
|
1485
|
+
(0, import_react12.useEffect)(() => {
|
|
1586
1486
|
if (!props.validateOnMount) return;
|
|
1587
1487
|
setError(props.errorMessage || null);
|
|
1588
1488
|
}, [props.errorMessage, props.validateOnMount]);
|
|
1589
1489
|
const handleChange = (e) => {
|
|
1590
|
-
|
|
1591
|
-
props.onChange?.(e);
|
|
1592
|
-
return;
|
|
1593
|
-
}
|
|
1594
|
-
const val = e.target.value;
|
|
1595
|
-
setValue(val);
|
|
1596
|
-
if (isRequired && val.trim() === "") {
|
|
1597
|
-
setError(errorMessage);
|
|
1598
|
-
} else {
|
|
1599
|
-
setError(null);
|
|
1600
|
-
}
|
|
1490
|
+
props.onChange?.(e);
|
|
1601
1491
|
};
|
|
1602
|
-
return /* @__PURE__ */ (0,
|
|
1603
|
-
/* @__PURE__ */ (0,
|
|
1604
|
-
/* @__PURE__ */ (0,
|
|
1605
|
-
/* @__PURE__ */ (0,
|
|
1492
|
+
return /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)(import_jsx_runtime32.Fragment, { children: [
|
|
1493
|
+
/* @__PURE__ */ (0, import_jsx_runtime32.jsxs)("div", { className: "flex justify-start items-center relative", children: [
|
|
1494
|
+
/* @__PURE__ */ (0, import_jsx_runtime32.jsx)(Calendar, { className: "absolute left-3 top-1/2 h-4 w-4 -translate-y-1/2 text-[#BDBDBD]" }),
|
|
1495
|
+
/* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
|
|
1606
1496
|
Input,
|
|
1607
1497
|
{
|
|
1608
1498
|
type: "date",
|
|
@@ -1611,21 +1501,24 @@ function DatePicker({ className, style, ...props }) {
|
|
|
1611
1501
|
onChange: handleChange,
|
|
1612
1502
|
disabled: isDisabled || !isEditable,
|
|
1613
1503
|
name: props.name,
|
|
1614
|
-
value: props.value
|
|
1615
|
-
className: cn(
|
|
1504
|
+
value: props.value,
|
|
1505
|
+
className: cn(
|
|
1506
|
+
className,
|
|
1507
|
+
error ? "border-red-500" : "",
|
|
1508
|
+
"appearance-auto"
|
|
1509
|
+
),
|
|
1616
1510
|
style: {
|
|
1617
1511
|
...style,
|
|
1618
1512
|
borderColor: error ? "#f87171" : style?.borderColor
|
|
1619
1513
|
},
|
|
1620
1514
|
readOnly: isReadonly,
|
|
1621
|
-
required: isRequired,
|
|
1622
1515
|
placeholder,
|
|
1623
1516
|
min: minDate,
|
|
1624
1517
|
max: maxDate
|
|
1625
1518
|
}
|
|
1626
1519
|
)
|
|
1627
1520
|
] }),
|
|
1628
|
-
error && /* @__PURE__ */ (0,
|
|
1521
|
+
error && /* @__PURE__ */ (0, import_jsx_runtime32.jsx)("p", { className: "mt-1 text-xs text-red-500", children: error })
|
|
1629
1522
|
] });
|
|
1630
1523
|
}
|
|
1631
1524
|
|
|
@@ -1636,7 +1529,7 @@ var import_date_fns = require("date-fns");
|
|
|
1636
1529
|
// src/components/ui/calendar.tsx
|
|
1637
1530
|
var React12 = __toESM(require("react"));
|
|
1638
1531
|
var import_react_day_picker = require("react-day-picker");
|
|
1639
|
-
var
|
|
1532
|
+
var import_jsx_runtime33 = require("react/jsx-runtime");
|
|
1640
1533
|
function Calendar2({
|
|
1641
1534
|
className,
|
|
1642
1535
|
classNames,
|
|
@@ -1648,7 +1541,7 @@ function Calendar2({
|
|
|
1648
1541
|
...props
|
|
1649
1542
|
}) {
|
|
1650
1543
|
const defaultClassNames = (0, import_react_day_picker.getDefaultClassNames)();
|
|
1651
|
-
return /* @__PURE__ */ (0,
|
|
1544
|
+
return /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
|
|
1652
1545
|
import_react_day_picker.DayPicker,
|
|
1653
1546
|
{
|
|
1654
1547
|
showOutsideDays,
|
|
@@ -1747,7 +1640,7 @@ function Calendar2({
|
|
|
1747
1640
|
},
|
|
1748
1641
|
components: {
|
|
1749
1642
|
Root: ({ className: className2, rootRef, ...props2 }) => {
|
|
1750
|
-
return /* @__PURE__ */ (0,
|
|
1643
|
+
return /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
|
|
1751
1644
|
"div",
|
|
1752
1645
|
{
|
|
1753
1646
|
"data-slot": "calendar",
|
|
@@ -1759,10 +1652,10 @@ function Calendar2({
|
|
|
1759
1652
|
},
|
|
1760
1653
|
Chevron: ({ className: className2, orientation, ...props2 }) => {
|
|
1761
1654
|
if (orientation === "left") {
|
|
1762
|
-
return /* @__PURE__ */ (0,
|
|
1655
|
+
return /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(ChevronLeft, { className: cn("size-4", className2), ...props2 });
|
|
1763
1656
|
}
|
|
1764
1657
|
if (orientation === "right") {
|
|
1765
|
-
return /* @__PURE__ */ (0,
|
|
1658
|
+
return /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
|
|
1766
1659
|
ChevronRight,
|
|
1767
1660
|
{
|
|
1768
1661
|
className: cn("size-4", className2),
|
|
@@ -1770,11 +1663,11 @@ function Calendar2({
|
|
|
1770
1663
|
}
|
|
1771
1664
|
);
|
|
1772
1665
|
}
|
|
1773
|
-
return /* @__PURE__ */ (0,
|
|
1666
|
+
return /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(ChevronDown, { className: cn("size-4", className2), ...props2 });
|
|
1774
1667
|
},
|
|
1775
1668
|
DayButton: CalendarDayButton,
|
|
1776
1669
|
WeekNumber: ({ children, ...props2 }) => {
|
|
1777
|
-
return /* @__PURE__ */ (0,
|
|
1670
|
+
return /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("td", { ...props2, children: /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("div", { className: "flex size-(--cell-size) items-center justify-center text-center", children }) });
|
|
1778
1671
|
},
|
|
1779
1672
|
...components
|
|
1780
1673
|
},
|
|
@@ -1793,7 +1686,7 @@ function CalendarDayButton({
|
|
|
1793
1686
|
React12.useEffect(() => {
|
|
1794
1687
|
if (modifiers.focused) ref.current?.focus();
|
|
1795
1688
|
}, [modifiers.focused]);
|
|
1796
|
-
return /* @__PURE__ */ (0,
|
|
1689
|
+
return /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
|
|
1797
1690
|
Button,
|
|
1798
1691
|
{
|
|
1799
1692
|
ref,
|
|
@@ -1816,16 +1709,16 @@ function CalendarDayButton({
|
|
|
1816
1709
|
|
|
1817
1710
|
// src/components/ui/popover.tsx
|
|
1818
1711
|
var PopoverPrimitive = __toESM(require("@radix-ui/react-popover"));
|
|
1819
|
-
var
|
|
1712
|
+
var import_jsx_runtime34 = require("react/jsx-runtime");
|
|
1820
1713
|
function Popover({
|
|
1821
1714
|
...props
|
|
1822
1715
|
}) {
|
|
1823
|
-
return /* @__PURE__ */ (0,
|
|
1716
|
+
return /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(PopoverPrimitive.Root, { "data-slot": "popover", ...props });
|
|
1824
1717
|
}
|
|
1825
1718
|
function PopoverTrigger({
|
|
1826
1719
|
...props
|
|
1827
1720
|
}) {
|
|
1828
|
-
return /* @__PURE__ */ (0,
|
|
1721
|
+
return /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(PopoverPrimitive.Trigger, { "data-slot": "popover-trigger", ...props });
|
|
1829
1722
|
}
|
|
1830
1723
|
function PopoverContent({
|
|
1831
1724
|
className,
|
|
@@ -1833,7 +1726,7 @@ function PopoverContent({
|
|
|
1833
1726
|
sideOffset = 4,
|
|
1834
1727
|
...props
|
|
1835
1728
|
}) {
|
|
1836
|
-
return /* @__PURE__ */ (0,
|
|
1729
|
+
return /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(PopoverPrimitive.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(
|
|
1837
1730
|
PopoverPrimitive.Content,
|
|
1838
1731
|
{
|
|
1839
1732
|
"data-slot": "popover-content",
|
|
@@ -1849,41 +1742,58 @@ function PopoverContent({
|
|
|
1849
1742
|
}
|
|
1850
1743
|
|
|
1851
1744
|
// src/components/Inputs/DateRange/DateRange.tsx
|
|
1852
|
-
var
|
|
1853
|
-
var DateRange = ({ className, style }) => {
|
|
1854
|
-
const [
|
|
1855
|
-
|
|
1856
|
-
|
|
1857
|
-
|
|
1858
|
-
|
|
1859
|
-
|
|
1860
|
-
|
|
1861
|
-
|
|
1862
|
-
|
|
1863
|
-
|
|
1864
|
-
|
|
1865
|
-
|
|
1866
|
-
|
|
1867
|
-
|
|
1868
|
-
|
|
1869
|
-
|
|
1870
|
-
|
|
1871
|
-
|
|
1872
|
-
|
|
1873
|
-
|
|
1874
|
-
|
|
1875
|
-
|
|
1876
|
-
|
|
1877
|
-
|
|
1878
|
-
|
|
1879
|
-
|
|
1880
|
-
|
|
1881
|
-
|
|
1882
|
-
|
|
1883
|
-
|
|
1884
|
-
|
|
1885
|
-
|
|
1886
|
-
|
|
1745
|
+
var import_jsx_runtime35 = require("react/jsx-runtime");
|
|
1746
|
+
var DateRange = ({ className, style, ...props }) => {
|
|
1747
|
+
const [error, setError] = React13.useState(null);
|
|
1748
|
+
const isDateRange = (val) => !!val && val.from instanceof Date;
|
|
1749
|
+
const [date, setDate] = React13.useState(
|
|
1750
|
+
isDateRange(props.value) ? props.value : {
|
|
1751
|
+
from: /* @__PURE__ */ new Date(),
|
|
1752
|
+
to: (0, import_date_fns.addDays)(/* @__PURE__ */ new Date(), 7)
|
|
1753
|
+
}
|
|
1754
|
+
);
|
|
1755
|
+
React13.useEffect(() => {
|
|
1756
|
+
if (!props.validateOnMount) return;
|
|
1757
|
+
setError(props.errorMessage || null);
|
|
1758
|
+
}, [props.errorMessage, props.validateOnMount]);
|
|
1759
|
+
const handleChange = (value) => {
|
|
1760
|
+
setDate(value);
|
|
1761
|
+
if (value) {
|
|
1762
|
+
props.onChange?.(value);
|
|
1763
|
+
}
|
|
1764
|
+
};
|
|
1765
|
+
return /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)(import_jsx_runtime35.Fragment, { children: [
|
|
1766
|
+
/* @__PURE__ */ (0, import_jsx_runtime35.jsx)("div", { className, style, children: /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)(Popover, { children: [
|
|
1767
|
+
/* @__PURE__ */ (0, import_jsx_runtime35.jsx)(PopoverTrigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(
|
|
1768
|
+
Button,
|
|
1769
|
+
{
|
|
1770
|
+
id: "date",
|
|
1771
|
+
variant: "outline",
|
|
1772
|
+
className: cn(
|
|
1773
|
+
"w-[300px] justify-start text-left font-normal text-[11px]",
|
|
1774
|
+
!date && "text-muted-foreground"
|
|
1775
|
+
),
|
|
1776
|
+
children: date?.from ? date.to ? /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)(import_jsx_runtime35.Fragment, { children: [
|
|
1777
|
+
(0, import_date_fns.format)(date.from, "LLL dd, y"),
|
|
1778
|
+
" -",
|
|
1779
|
+
" ",
|
|
1780
|
+
(0, import_date_fns.format)(date.to, "LLL dd, y")
|
|
1781
|
+
] }) : (0, import_date_fns.format)(date.from, "LLL dd, y") : /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("span", { children: "Pick a date range" })
|
|
1782
|
+
}
|
|
1783
|
+
) }),
|
|
1784
|
+
/* @__PURE__ */ (0, import_jsx_runtime35.jsx)(PopoverContent, { className: "w-auto p-0", align: "start", children: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(
|
|
1785
|
+
Calendar2,
|
|
1786
|
+
{
|
|
1787
|
+
mode: "range",
|
|
1788
|
+
defaultMonth: date?.from,
|
|
1789
|
+
selected: date,
|
|
1790
|
+
onSelect: handleChange,
|
|
1791
|
+
numberOfMonths: 2
|
|
1792
|
+
}
|
|
1793
|
+
) })
|
|
1794
|
+
] }) }),
|
|
1795
|
+
error && /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("p", { className: "mt-1 text-xs text-red-500", children: error })
|
|
1796
|
+
] });
|
|
1887
1797
|
};
|
|
1888
1798
|
var DateRange_default = DateRange;
|
|
1889
1799
|
|
|
@@ -1891,14 +1801,14 @@ var DateRange_default = DateRange;
|
|
|
1891
1801
|
var import_react_table = require("@tanstack/react-table");
|
|
1892
1802
|
|
|
1893
1803
|
// src/components/ui/table.tsx
|
|
1894
|
-
var
|
|
1804
|
+
var import_jsx_runtime36 = require("react/jsx-runtime");
|
|
1895
1805
|
function Table({ className, ...props }) {
|
|
1896
|
-
return /* @__PURE__ */ (0,
|
|
1806
|
+
return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
1897
1807
|
"div",
|
|
1898
1808
|
{
|
|
1899
1809
|
"data-slot": "table-container",
|
|
1900
1810
|
className: "relative w-full overflow-x-auto rounded-md border border-gray-200 bg-white",
|
|
1901
|
-
children: /* @__PURE__ */ (0,
|
|
1811
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
1902
1812
|
"table",
|
|
1903
1813
|
{
|
|
1904
1814
|
"data-slot": "table",
|
|
@@ -1910,7 +1820,7 @@ function Table({ className, ...props }) {
|
|
|
1910
1820
|
);
|
|
1911
1821
|
}
|
|
1912
1822
|
function TableHeader({ className, ...props }) {
|
|
1913
|
-
return /* @__PURE__ */ (0,
|
|
1823
|
+
return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
1914
1824
|
"thead",
|
|
1915
1825
|
{
|
|
1916
1826
|
"data-slot": "table-header",
|
|
@@ -1923,7 +1833,7 @@ function TableHeader({ className, ...props }) {
|
|
|
1923
1833
|
);
|
|
1924
1834
|
}
|
|
1925
1835
|
function TableBody({ className, ...props }) {
|
|
1926
|
-
return /* @__PURE__ */ (0,
|
|
1836
|
+
return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
1927
1837
|
"tbody",
|
|
1928
1838
|
{
|
|
1929
1839
|
"data-slot": "table-body",
|
|
@@ -1936,7 +1846,7 @@ function TableBody({ className, ...props }) {
|
|
|
1936
1846
|
);
|
|
1937
1847
|
}
|
|
1938
1848
|
function TableRow({ className, ...props }) {
|
|
1939
|
-
return /* @__PURE__ */ (0,
|
|
1849
|
+
return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
1940
1850
|
"tr",
|
|
1941
1851
|
{
|
|
1942
1852
|
"data-slot": "table-row",
|
|
@@ -1949,7 +1859,7 @@ function TableRow({ className, ...props }) {
|
|
|
1949
1859
|
);
|
|
1950
1860
|
}
|
|
1951
1861
|
function TableHead({ className, ...props }) {
|
|
1952
|
-
return /* @__PURE__ */ (0,
|
|
1862
|
+
return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
1953
1863
|
"th",
|
|
1954
1864
|
{
|
|
1955
1865
|
"data-slot": "table-head",
|
|
@@ -1962,7 +1872,7 @@ function TableHead({ className, ...props }) {
|
|
|
1962
1872
|
);
|
|
1963
1873
|
}
|
|
1964
1874
|
function TableCell({ className, ...props }) {
|
|
1965
|
-
return /* @__PURE__ */ (0,
|
|
1875
|
+
return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
1966
1876
|
"td",
|
|
1967
1877
|
{
|
|
1968
1878
|
"data-slot": "table-cell",
|
|
@@ -1976,7 +1886,7 @@ function TableCell({ className, ...props }) {
|
|
|
1976
1886
|
}
|
|
1977
1887
|
|
|
1978
1888
|
// src/components/ui/data-table.tsx
|
|
1979
|
-
var
|
|
1889
|
+
var import_jsx_runtime37 = require("react/jsx-runtime");
|
|
1980
1890
|
function DataTable({
|
|
1981
1891
|
columns,
|
|
1982
1892
|
rowActions,
|
|
@@ -2001,14 +1911,14 @@ function DataTable({
|
|
|
2001
1911
|
onCellClick(rowData, columnId);
|
|
2002
1912
|
}
|
|
2003
1913
|
};
|
|
2004
|
-
return /* @__PURE__ */ (0,
|
|
2005
|
-
/* @__PURE__ */ (0,
|
|
2006
|
-
return /* @__PURE__ */ (0,
|
|
1914
|
+
return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("div", { className: "overflow-hidden rounded-md border w-full", children: /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(Table, { children: [
|
|
1915
|
+
/* @__PURE__ */ (0, import_jsx_runtime37.jsx)(TableHeader, { children: table.getHeaderGroups().map((headerGroup) => /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(TableRow, { children: headerGroup.headers.map((header) => {
|
|
1916
|
+
return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(TableHead, { children: header.isPlaceholder ? null : (0, import_react_table.flexRender)(
|
|
2007
1917
|
header.column.columnDef.header,
|
|
2008
1918
|
header.getContext()
|
|
2009
1919
|
) }, header.id);
|
|
2010
1920
|
}) }, headerGroup.id)) }),
|
|
2011
|
-
/* @__PURE__ */ (0,
|
|
1921
|
+
/* @__PURE__ */ (0, import_jsx_runtime37.jsx)(TableBody, { children: loading ? /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(TableRow, { children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(TableCell, { colSpan: columns.length, className: "h-24 text-center", children: "Loading..." }) }) : /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_jsx_runtime37.Fragment, { children: table.getRowModel().rows?.length ? table.getRowModel().rows.map((row) => /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(
|
|
2012
1922
|
TableRow,
|
|
2013
1923
|
{
|
|
2014
1924
|
"data-state": row.getIsSelected() && "selected",
|
|
@@ -2018,7 +1928,7 @@ function DataTable({
|
|
|
2018
1928
|
const isCellClickable = cellClickEnabled(row.original, cell.column.id);
|
|
2019
1929
|
const dynamicClass = cell.column.columnDef.meta?.cellClass || "";
|
|
2020
1930
|
const dynamicStyle = cell.column.columnDef.meta?.cellStyle || {};
|
|
2021
|
-
return /* @__PURE__ */ (0,
|
|
1931
|
+
return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
|
|
2022
1932
|
TableCell,
|
|
2023
1933
|
{
|
|
2024
1934
|
className: `${dynamicClass} ${isCellClickable ? "underline cursor-pointer" : ""}`,
|
|
@@ -2033,18 +1943,18 @@ function DataTable({
|
|
|
2033
1943
|
cell.id
|
|
2034
1944
|
);
|
|
2035
1945
|
}),
|
|
2036
|
-
rowActions.length > 0 && /* @__PURE__ */ (0,
|
|
1946
|
+
rowActions.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("div", { className: "absolute top-0 right-0 bg-white py-3 min-w-[100px] z-50 shadow-md flex items-center justify-center gap-3 p-2 opacity-0 group-hover:opacity-100 duration-300 h-full", children: rowActions.map((action, index) => /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("p", { className: "text-[#383838] text-[12px] cursor-pointer font-[400]", children: action.header }, index)) })
|
|
2037
1947
|
]
|
|
2038
1948
|
},
|
|
2039
1949
|
row.id
|
|
2040
|
-
)) : /* @__PURE__ */ (0,
|
|
1950
|
+
)) : /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(TableRow, { children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(TableCell, { colSpan: columns.length, className: "h-24 text-center", children: "No results." }) }) }) })
|
|
2041
1951
|
] }) });
|
|
2042
1952
|
}
|
|
2043
1953
|
|
|
2044
1954
|
// src/components/ui/pagination.tsx
|
|
2045
|
-
var
|
|
1955
|
+
var import_jsx_runtime38 = require("react/jsx-runtime");
|
|
2046
1956
|
function Pagination({ className, ...props }) {
|
|
2047
|
-
return /* @__PURE__ */ (0,
|
|
1957
|
+
return /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(
|
|
2048
1958
|
"nav",
|
|
2049
1959
|
{
|
|
2050
1960
|
role: "navigation",
|
|
@@ -2059,7 +1969,7 @@ function PaginationContent({
|
|
|
2059
1969
|
className,
|
|
2060
1970
|
...props
|
|
2061
1971
|
}) {
|
|
2062
|
-
return /* @__PURE__ */ (0,
|
|
1972
|
+
return /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(
|
|
2063
1973
|
"ul",
|
|
2064
1974
|
{
|
|
2065
1975
|
"data-slot": "pagination-content",
|
|
@@ -2069,7 +1979,7 @@ function PaginationContent({
|
|
|
2069
1979
|
);
|
|
2070
1980
|
}
|
|
2071
1981
|
function PaginationItem({ ...props }) {
|
|
2072
|
-
return /* @__PURE__ */ (0,
|
|
1982
|
+
return /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("li", { "data-slot": "pagination-item", ...props });
|
|
2073
1983
|
}
|
|
2074
1984
|
function PaginationLink({
|
|
2075
1985
|
className,
|
|
@@ -2077,7 +1987,7 @@ function PaginationLink({
|
|
|
2077
1987
|
size = "icon",
|
|
2078
1988
|
...props
|
|
2079
1989
|
}) {
|
|
2080
|
-
return /* @__PURE__ */ (0,
|
|
1990
|
+
return /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(
|
|
2081
1991
|
"a",
|
|
2082
1992
|
{
|
|
2083
1993
|
"aria-current": isActive ? "page" : void 0,
|
|
@@ -2098,7 +2008,7 @@ function PaginationPrevious({
|
|
|
2098
2008
|
className,
|
|
2099
2009
|
...props
|
|
2100
2010
|
}) {
|
|
2101
|
-
return /* @__PURE__ */ (0,
|
|
2011
|
+
return /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)(
|
|
2102
2012
|
PaginationLink,
|
|
2103
2013
|
{
|
|
2104
2014
|
"aria-label": "Go to previous page",
|
|
@@ -2106,8 +2016,8 @@ function PaginationPrevious({
|
|
|
2106
2016
|
className: cn("gap-1 px-2.5 sm:pl-2.5", className),
|
|
2107
2017
|
...props,
|
|
2108
2018
|
children: [
|
|
2109
|
-
/* @__PURE__ */ (0,
|
|
2110
|
-
/* @__PURE__ */ (0,
|
|
2019
|
+
/* @__PURE__ */ (0, import_jsx_runtime38.jsx)(ChevronLeft, {}),
|
|
2020
|
+
/* @__PURE__ */ (0, import_jsx_runtime38.jsx)("span", { className: "hidden sm:block", children: "Previous" })
|
|
2111
2021
|
]
|
|
2112
2022
|
}
|
|
2113
2023
|
);
|
|
@@ -2116,7 +2026,7 @@ function PaginationNext({
|
|
|
2116
2026
|
className,
|
|
2117
2027
|
...props
|
|
2118
2028
|
}) {
|
|
2119
|
-
return /* @__PURE__ */ (0,
|
|
2029
|
+
return /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)(
|
|
2120
2030
|
PaginationLink,
|
|
2121
2031
|
{
|
|
2122
2032
|
"aria-label": "Go to next page",
|
|
@@ -2124,8 +2034,8 @@ function PaginationNext({
|
|
|
2124
2034
|
className: cn("gap-1 px-2.5 sm:pr-2.5", className),
|
|
2125
2035
|
...props,
|
|
2126
2036
|
children: [
|
|
2127
|
-
/* @__PURE__ */ (0,
|
|
2128
|
-
/* @__PURE__ */ (0,
|
|
2037
|
+
/* @__PURE__ */ (0, import_jsx_runtime38.jsx)("span", { className: "hidden sm:block", children: "Next" }),
|
|
2038
|
+
/* @__PURE__ */ (0, import_jsx_runtime38.jsx)(ChevronRight, {})
|
|
2129
2039
|
]
|
|
2130
2040
|
}
|
|
2131
2041
|
);
|
|
@@ -2134,7 +2044,7 @@ function PaginationEllipsis({
|
|
|
2134
2044
|
className,
|
|
2135
2045
|
...props
|
|
2136
2046
|
}) {
|
|
2137
|
-
return /* @__PURE__ */ (0,
|
|
2047
|
+
return /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)(
|
|
2138
2048
|
"span",
|
|
2139
2049
|
{
|
|
2140
2050
|
"aria-hidden": true,
|
|
@@ -2142,15 +2052,15 @@ function PaginationEllipsis({
|
|
|
2142
2052
|
className: cn("flex size-9 items-center justify-center", className),
|
|
2143
2053
|
...props,
|
|
2144
2054
|
children: [
|
|
2145
|
-
/* @__PURE__ */ (0,
|
|
2146
|
-
/* @__PURE__ */ (0,
|
|
2055
|
+
/* @__PURE__ */ (0, import_jsx_runtime38.jsx)(Ellipsis, { className: "size-4" }),
|
|
2056
|
+
/* @__PURE__ */ (0, import_jsx_runtime38.jsx)("span", { className: "sr-only", children: "More pages" })
|
|
2147
2057
|
]
|
|
2148
2058
|
}
|
|
2149
2059
|
);
|
|
2150
2060
|
}
|
|
2151
2061
|
|
|
2152
2062
|
// src/components/DataDisplay/Pagination/Pagination.tsx
|
|
2153
|
-
var
|
|
2063
|
+
var import_jsx_runtime39 = require("react/jsx-runtime");
|
|
2154
2064
|
var CustomPagination = ({
|
|
2155
2065
|
totalPages,
|
|
2156
2066
|
currentPage,
|
|
@@ -2192,15 +2102,15 @@ var CustomPagination = ({
|
|
|
2192
2102
|
}
|
|
2193
2103
|
};
|
|
2194
2104
|
const pageNumbers = getPageNumbers();
|
|
2195
|
-
return /* @__PURE__ */ (0,
|
|
2196
|
-
/* @__PURE__ */ (0,
|
|
2105
|
+
return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(Pagination, { children: /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(PaginationContent, { children: [
|
|
2106
|
+
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)(PaginationItem, { children: /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
2197
2107
|
PaginationPrevious,
|
|
2198
2108
|
{
|
|
2199
2109
|
onClick: () => handlePageChange(currentPage - 1),
|
|
2200
2110
|
className: currentPage === 1 ? "pointer-events-none opacity-50" : "cursor-pointer"
|
|
2201
2111
|
}
|
|
2202
2112
|
) }),
|
|
2203
|
-
pageNumbers.map((pageNumber, index) => /* @__PURE__ */ (0,
|
|
2113
|
+
pageNumbers.map((pageNumber, index) => /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(PaginationItem, { children: pageNumber === "..." ? /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(PaginationEllipsis, {}) : /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
2204
2114
|
PaginationLink,
|
|
2205
2115
|
{
|
|
2206
2116
|
onClick: () => handlePageChange(pageNumber),
|
|
@@ -2209,7 +2119,7 @@ var CustomPagination = ({
|
|
|
2209
2119
|
children: pageNumber
|
|
2210
2120
|
}
|
|
2211
2121
|
) }, index)),
|
|
2212
|
-
/* @__PURE__ */ (0,
|
|
2122
|
+
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)(PaginationItem, { children: /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
2213
2123
|
PaginationNext,
|
|
2214
2124
|
{
|
|
2215
2125
|
onClick: () => handlePageChange(currentPage + 1),
|
|
@@ -2221,22 +2131,22 @@ var CustomPagination = ({
|
|
|
2221
2131
|
var Pagination_default = CustomPagination;
|
|
2222
2132
|
|
|
2223
2133
|
// src/components/DataDisplay/Table/Table.tsx
|
|
2224
|
-
var
|
|
2225
|
-
var
|
|
2134
|
+
var import_react13 = require("react");
|
|
2135
|
+
var import_jsx_runtime40 = require("react/jsx-runtime");
|
|
2226
2136
|
var Table2 = ({ columns, data, rowActions, className, style, pagination = false, itemsPerPage = 10, onPageChange, loading = false }) => {
|
|
2227
2137
|
const rawColumns = Array.isArray(columns) ? columns : [];
|
|
2228
2138
|
const rawData = Array.isArray(data) ? data : [];
|
|
2229
2139
|
const rawRowActions = Array.isArray(rowActions) ? rowActions : [];
|
|
2230
|
-
const [currentPage, setCurrentPage] = (0,
|
|
2140
|
+
const [currentPage, setCurrentPage] = (0, import_react13.useState)(1);
|
|
2231
2141
|
const enablePagination = pagination && rawData.length > itemsPerPage;
|
|
2232
2142
|
const handlePageChange = (page) => {
|
|
2233
2143
|
setCurrentPage(page);
|
|
2234
2144
|
onPageChange?.(page);
|
|
2235
2145
|
};
|
|
2236
2146
|
const paginatedData = enablePagination ? rawData.slice((currentPage - 1) * itemsPerPage, currentPage * itemsPerPage) : rawData;
|
|
2237
|
-
return /* @__PURE__ */ (0,
|
|
2238
|
-
/* @__PURE__ */ (0,
|
|
2239
|
-
enablePagination && /* @__PURE__ */ (0,
|
|
2147
|
+
return /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)("div", { className: `${className} space-y-3`, style, children: [
|
|
2148
|
+
/* @__PURE__ */ (0, import_jsx_runtime40.jsx)(DataTable, { columns: rawColumns, data: paginatedData, rowActions: rawRowActions, loading }),
|
|
2149
|
+
enablePagination && /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
|
|
2240
2150
|
Pagination_default,
|
|
2241
2151
|
{
|
|
2242
2152
|
totalPages: Math.ceil(rawData.length / itemsPerPage),
|
|
@@ -2250,16 +2160,16 @@ var Table_default = Table2;
|
|
|
2250
2160
|
|
|
2251
2161
|
// src/components/ui/dropdown-menu.tsx
|
|
2252
2162
|
var DropdownMenuPrimitive = __toESM(require("@radix-ui/react-dropdown-menu"));
|
|
2253
|
-
var
|
|
2163
|
+
var import_jsx_runtime41 = require("react/jsx-runtime");
|
|
2254
2164
|
function DropdownMenu({
|
|
2255
2165
|
...props
|
|
2256
2166
|
}) {
|
|
2257
|
-
return /* @__PURE__ */ (0,
|
|
2167
|
+
return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(DropdownMenuPrimitive.Root, { "data-slot": "dropdown-menu", ...props });
|
|
2258
2168
|
}
|
|
2259
2169
|
function DropdownMenuTrigger({
|
|
2260
2170
|
...props
|
|
2261
2171
|
}) {
|
|
2262
|
-
return /* @__PURE__ */ (0,
|
|
2172
|
+
return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
|
|
2263
2173
|
DropdownMenuPrimitive.Trigger,
|
|
2264
2174
|
{
|
|
2265
2175
|
"data-slot": "dropdown-menu-trigger",
|
|
@@ -2272,7 +2182,7 @@ function DropdownMenuContent({
|
|
|
2272
2182
|
sideOffset = 4,
|
|
2273
2183
|
...props
|
|
2274
2184
|
}) {
|
|
2275
|
-
return /* @__PURE__ */ (0,
|
|
2185
|
+
return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(DropdownMenuPrimitive.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
|
|
2276
2186
|
DropdownMenuPrimitive.Content,
|
|
2277
2187
|
{
|
|
2278
2188
|
"data-slot": "dropdown-menu-content",
|
|
@@ -2291,7 +2201,7 @@ function DropdownMenuItem({
|
|
|
2291
2201
|
variant = "default",
|
|
2292
2202
|
...props
|
|
2293
2203
|
}) {
|
|
2294
|
-
return /* @__PURE__ */ (0,
|
|
2204
|
+
return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
|
|
2295
2205
|
DropdownMenuPrimitive.Item,
|
|
2296
2206
|
{
|
|
2297
2207
|
"data-slot": "dropdown-menu-item",
|
|
@@ -2310,7 +2220,7 @@ function DropdownMenuLabel({
|
|
|
2310
2220
|
inset,
|
|
2311
2221
|
...props
|
|
2312
2222
|
}) {
|
|
2313
|
-
return /* @__PURE__ */ (0,
|
|
2223
|
+
return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
|
|
2314
2224
|
DropdownMenuPrimitive.Label,
|
|
2315
2225
|
{
|
|
2316
2226
|
"data-slot": "dropdown-menu-label",
|
|
@@ -2327,7 +2237,7 @@ function DropdownMenuSeparator({
|
|
|
2327
2237
|
className,
|
|
2328
2238
|
...props
|
|
2329
2239
|
}) {
|
|
2330
|
-
return /* @__PURE__ */ (0,
|
|
2240
|
+
return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
|
|
2331
2241
|
DropdownMenuPrimitive.Separator,
|
|
2332
2242
|
{
|
|
2333
2243
|
"data-slot": "dropdown-menu-separator",
|
|
@@ -2338,7 +2248,7 @@ function DropdownMenuSeparator({
|
|
|
2338
2248
|
}
|
|
2339
2249
|
|
|
2340
2250
|
// src/components/Navigation/Tabs/Tabs.tsx
|
|
2341
|
-
var
|
|
2251
|
+
var import_jsx_runtime42 = require("react/jsx-runtime");
|
|
2342
2252
|
var Tabs = ({ tabs, className, style, pathname, LinkComponent }) => {
|
|
2343
2253
|
const rawTabs = Array.isArray(tabs) ? tabs : [];
|
|
2344
2254
|
const baseClasses = "text-[12px] text-[#E9E9E9] p-2 text-center rounded-md transition-colors border-none outline-none focus:outline-none focus:ring-0 focus:ring-offset-0 cursor-pointer select-none ";
|
|
@@ -2348,7 +2258,7 @@ var Tabs = ({ tabs, className, style, pathname, LinkComponent }) => {
|
|
|
2348
2258
|
if (!path) return false;
|
|
2349
2259
|
return pathname === path || path !== "/" && pathname?.startsWith(path);
|
|
2350
2260
|
};
|
|
2351
|
-
return /* @__PURE__ */ (0,
|
|
2261
|
+
return /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("div", { className, style, children: rawTabs.map((tab, index) => {
|
|
2352
2262
|
const finalClasses = [
|
|
2353
2263
|
baseClasses,
|
|
2354
2264
|
isActive(tab.href) ? activeClasses : hoverClasses,
|
|
@@ -2356,29 +2266,29 @@ var Tabs = ({ tabs, className, style, pathname, LinkComponent }) => {
|
|
|
2356
2266
|
].join(" ");
|
|
2357
2267
|
const hasDropdown = Array.isArray(tab.children) && tab.children.length > 0 && tab.isDropDown;
|
|
2358
2268
|
if (hasDropdown) {
|
|
2359
|
-
return /* @__PURE__ */ (0,
|
|
2360
|
-
/* @__PURE__ */ (0,
|
|
2269
|
+
return /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)(DropdownMenu, { children: [
|
|
2270
|
+
/* @__PURE__ */ (0, import_jsx_runtime42.jsxs)(
|
|
2361
2271
|
DropdownMenuTrigger,
|
|
2362
2272
|
{
|
|
2363
2273
|
className: `${finalClasses} inline-flex items-center gap-1`,
|
|
2364
2274
|
children: [
|
|
2365
2275
|
tab.header,
|
|
2366
|
-
/* @__PURE__ */ (0,
|
|
2276
|
+
/* @__PURE__ */ (0, import_jsx_runtime42.jsx)(ChevronDown, { className: "h-4 w-4 opacity-80" })
|
|
2367
2277
|
]
|
|
2368
2278
|
}
|
|
2369
2279
|
),
|
|
2370
|
-
/* @__PURE__ */ (0,
|
|
2280
|
+
/* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
|
|
2371
2281
|
DropdownMenuContent,
|
|
2372
2282
|
{
|
|
2373
2283
|
align: "start",
|
|
2374
2284
|
sideOffset: 6,
|
|
2375
2285
|
className: "z-50 min-w-[160px] rounded-md border border-gray-200 bg-white p-1 shadow-lg",
|
|
2376
|
-
children: tab.children.map((item) => /* @__PURE__ */ (0,
|
|
2286
|
+
children: tab.children.map((item) => /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
|
|
2377
2287
|
DropdownMenuItem,
|
|
2378
2288
|
{
|
|
2379
2289
|
asChild: true,
|
|
2380
2290
|
className: "cursor-pointer rounded-sm px-3 py-2 text-[12px] text-gray-800 hover:bg-gray-100 focus:bg-gray-100",
|
|
2381
|
-
children: LinkComponent ? /* @__PURE__ */ (0,
|
|
2291
|
+
children: LinkComponent ? /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(LinkComponent, { href: item.href || "#", children: item.header }) : item.header
|
|
2382
2292
|
},
|
|
2383
2293
|
item.id
|
|
2384
2294
|
))
|
|
@@ -2386,19 +2296,19 @@ var Tabs = ({ tabs, className, style, pathname, LinkComponent }) => {
|
|
|
2386
2296
|
)
|
|
2387
2297
|
] }, index);
|
|
2388
2298
|
}
|
|
2389
|
-
return tab.url && LinkComponent ? /* @__PURE__ */ (0,
|
|
2299
|
+
return tab.url && LinkComponent ? /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(LinkComponent, { href: tab.url, className: finalClasses, style: tab.style, children: tab.header }, index) : /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("div", { className: finalClasses, style: tab.style, role: "button", tabIndex: 0, children: tab.header }, index);
|
|
2390
2300
|
}) });
|
|
2391
2301
|
};
|
|
2392
2302
|
var Tabs_default = Tabs;
|
|
2393
2303
|
|
|
2394
2304
|
// src/components/Navigation/Stages/Stages.tsx
|
|
2395
|
-
var
|
|
2396
|
-
var
|
|
2305
|
+
var import_react14 = __toESM(require("react"));
|
|
2306
|
+
var import_jsx_runtime43 = require("react/jsx-runtime");
|
|
2397
2307
|
var StagesComponent = ({ stages, isShowBtn, buttonText, className, style }) => {
|
|
2398
|
-
return /* @__PURE__ */ (0,
|
|
2399
|
-
/* @__PURE__ */ (0,
|
|
2400
|
-
/* @__PURE__ */ (0,
|
|
2401
|
-
/* @__PURE__ */ (0,
|
|
2308
|
+
return /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("div", { className, style, children: /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)("div", { className: "flex items-center justify-between bg-gray-50 p-2 rounded-lg border border-gray-200 w-full", children: [
|
|
2309
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)("div", { className: "flex items-center", children: /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("button", { className: "p-2 hover:bg-gray-100 rounded", children: /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("svg", { className: "w-4 h-4 text-gray-600", fill: "none", stroke: "currentColor", viewBox: "0 0 24 24", children: /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("path", { strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: 2, d: "M19 9l-7 7-7-7" }) }) }) }),
|
|
2310
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)("div", { className: "flex items-center flex-1 px-2", children: stages?.length > 0 && stages?.map((stage, index) => /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)(import_react14.default.Fragment, { children: [
|
|
2311
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
|
|
2402
2312
|
"button",
|
|
2403
2313
|
{
|
|
2404
2314
|
className: `
|
|
@@ -2406,26 +2316,26 @@ var StagesComponent = ({ stages, isShowBtn, buttonText, className, style }) => {
|
|
|
2406
2316
|
children: stage.header
|
|
2407
2317
|
}
|
|
2408
2318
|
),
|
|
2409
|
-
index < stages.length - 1 && /* @__PURE__ */ (0,
|
|
2319
|
+
index < stages.length - 1 && /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("div", { className: "flex-shrink-0 w-3 h-px bg-gray-300" })
|
|
2410
2320
|
] }, stage.id)) }),
|
|
2411
|
-
isShowBtn && /* @__PURE__ */ (0,
|
|
2321
|
+
isShowBtn && /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("div", { className: "flex items-center", children: /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("button", { className: "bg-[#034486] text-white px-6 py-2 rounded-lg text-sm font-medium transition-colors duration-200 shadow-sm", children: buttonText }) })
|
|
2412
2322
|
] }) });
|
|
2413
2323
|
};
|
|
2414
2324
|
var Stages_default = StagesComponent;
|
|
2415
2325
|
|
|
2416
2326
|
// src/components/Navigation/Spacer/Spacer.tsx
|
|
2417
|
-
var
|
|
2327
|
+
var import_jsx_runtime44 = require("react/jsx-runtime");
|
|
2418
2328
|
var Spacer = ({ className, style }) => {
|
|
2419
|
-
return /* @__PURE__ */ (0,
|
|
2329
|
+
return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("div", { className: `${className}`, style });
|
|
2420
2330
|
};
|
|
2421
2331
|
var Spacer_default = Spacer;
|
|
2422
2332
|
|
|
2423
2333
|
// src/components/Navigation/Profile/Profile.tsx
|
|
2424
|
-
var
|
|
2334
|
+
var import_jsx_runtime45 = require("react/jsx-runtime");
|
|
2425
2335
|
var Profile = ({ profileType, showName, userName, className, style }) => {
|
|
2426
|
-
return /* @__PURE__ */ (0,
|
|
2427
|
-
showName && /* @__PURE__ */ (0,
|
|
2428
|
-
profileType === "avatar" ? /* @__PURE__ */ (0,
|
|
2336
|
+
return /* @__PURE__ */ (0, import_jsx_runtime45.jsx)("div", { className, style, children: /* @__PURE__ */ (0, import_jsx_runtime45.jsxs)("div", { className: "flex gap-2 items-center justify-between w-30 cursor-pointer", children: [
|
|
2337
|
+
showName && /* @__PURE__ */ (0, import_jsx_runtime45.jsx)("h4", { className: "text-[#000000] dark:text-[#fff] text-[13px] font-[500] mb-0", children: userName }),
|
|
2338
|
+
profileType === "avatar" ? /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
|
|
2429
2339
|
"img",
|
|
2430
2340
|
{
|
|
2431
2341
|
src: "https://builder.development.algorithmshift.ai/images/toolset/profile.svg",
|
|
@@ -2433,16 +2343,16 @@ var Profile = ({ profileType, showName, userName, className, style }) => {
|
|
|
2433
2343
|
width: 24,
|
|
2434
2344
|
height: 24
|
|
2435
2345
|
}
|
|
2436
|
-
) : /* @__PURE__ */ (0,
|
|
2346
|
+
) : /* @__PURE__ */ (0, import_jsx_runtime45.jsx)("div", { className: "w-6 h-6 bg-[#12715b] rounded-full text-[#fff] text-center text-[11px] flex items-center justify-center", children: "A" })
|
|
2437
2347
|
] }) });
|
|
2438
2348
|
};
|
|
2439
2349
|
var Profile_default = Profile;
|
|
2440
2350
|
|
|
2441
2351
|
// src/components/Navigation/Notification/Notification.tsx
|
|
2442
|
-
var
|
|
2352
|
+
var import_jsx_runtime46 = require("react/jsx-runtime");
|
|
2443
2353
|
var Notification = ({ className, style, badgeType, badgeCount = 0, hideBadgeWhenZero }) => {
|
|
2444
|
-
return /* @__PURE__ */ (0,
|
|
2445
|
-
/* @__PURE__ */ (0,
|
|
2354
|
+
return /* @__PURE__ */ (0, import_jsx_runtime46.jsx)("div", { className, style, children: /* @__PURE__ */ (0, import_jsx_runtime46.jsxs)("div", { className: "w-[34px] h-[34px] bg-[#E9E9E9] rounded-md text-center flex items-center justify-center relative", children: [
|
|
2355
|
+
/* @__PURE__ */ (0, import_jsx_runtime46.jsx)(
|
|
2446
2356
|
"img",
|
|
2447
2357
|
{
|
|
2448
2358
|
src: "https://builder.development.algorithmshift.ai/images/toolset/notification.svg",
|
|
@@ -2451,7 +2361,7 @@ var Notification = ({ className, style, badgeType, badgeCount = 0, hideBadgeWhen
|
|
|
2451
2361
|
height: 18
|
|
2452
2362
|
}
|
|
2453
2363
|
),
|
|
2454
|
-
badgeType === "number" && !(hideBadgeWhenZero && badgeCount === 0) && badgeCount > 0 ? /* @__PURE__ */ (0,
|
|
2364
|
+
badgeType === "number" && !(hideBadgeWhenZero && badgeCount === 0) && badgeCount > 0 ? /* @__PURE__ */ (0, import_jsx_runtime46.jsx)("span", { className: "text-[10px] text-[#fff] bg-[#FF4A4A] w-[20px] h-[20px] rounded-full absolute top-0 right-0 transform translate-x-1/2 -translate-y-1/2 leading-[20px]", children: badgeCount }) : /* @__PURE__ */ (0, import_jsx_runtime46.jsx)("span", { className: "bg-[#FF4A4A] w-[10px] h-[10px] rounded-full absolute top-0 right-0 transform translate-x-1/2 -translate-y-1/2 leading-[20px]" })
|
|
2455
2365
|
] }) });
|
|
2456
2366
|
};
|
|
2457
2367
|
var Notification_default = Notification;
|
|
@@ -2460,7 +2370,7 @@ var Notification_default = Notification;
|
|
|
2460
2370
|
var logo_placeholder_default = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAABDgAAAGPCAYAAAC552DlAAAACXBIWXMAAA7EAAAOxAGVKw4bAAAgAElEQVR4nO3d6X+V5Z0/8G8WEhIgSBKWkLCECFIJAoILdRRU3NsBtXVrq+PymmkfzuN5MP0L5pmvdtpqX3aqti5V61jrVm2p24AKggqKRHYQCEsgQNbfA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++e1AcBH9VY2Nj3HfffTFq1KhCt3JS9fX1gyrcMK8AzuAABlBTU1PcfPPNA3IdcH8NHTo0lixZEvX19fH8888PyKm1xcXFccstt8Q555yT97FyUVpaGt///vfjiSeeiIMHDxa6nROyts4cI0aMiP/8z/8sdBvJqqioiFtuuSUmT55c6FaOq7q6Ou6666546KGHYs+ePYVu55jKy8vj+9///pe3ki408wpw1OCInIHT3syZM+P2229P4gD0qy644IK47bbbBuRD7JIlSwZNuPGF0tLSuPHGGwfdt4FfZW1BbkaMGBH33HPPoD4I/sLIkSPjRz/60aDbtPML119/fYwcObLQbUSEeQX4KgEHkHdz5syJG2+8MW93Acm3adOmxR133JHX/hcuXBgzZ87MW/3+KC8vj+uvv77QbRyTtQW5qaqqinvvvXdQh5XfNGrUqPje9743YHdAytWkSZPivPPOK3QbEWFeAb5JwAHk1bnnnhvf+c53kv8g09jYGDfffHNeXkdjY2NcdtllmdfN0mDc08LagtxUVFTEnXfeOWjOOOiLxsbGuOKKKwrdxpdKSkriuuuuK3QbEWFeAY5FwAHkTV1dXSxevHjQbMDWX9/61rfiqquuyrRmZWVlLFmyxMFtH1lbkJvi4uK49dZbo6amptCtnLJvf/vbUVdXV+g2IuLo2Qdjx44tdBvmFeA4To9PhsCgU15eHt/73veirKys0K1kav78+XHuuedmVu/qq6+OqqqqzOqdCawtyN1VV10VkyZNKnQb/VJcXBzf/e53BcFfYV4Bjs3OZkBeXHvttVFdXV3oNvLihhtuiM8++yza29v7VaehoWHQXMedEmsLcjNp0qS46KKLMq3Z29sbGzZsiE8//TS2bdsWu3btis7OzoiIGD58eIwfPz6amppi2rRpmYaQdXV1MWfOnHj33Xczq5kq8wpwfAIOIHONjY0xe/bsQreRN5WVlXHdddfFk08+2a8611xzjW+u+sjagtyUlJRk/u346tWr49VXX43W1tZj/ry9vT0+//zzWLFiRVRWVsaCBQti3rx5mV1K9k//9E/x3nvvndG3VjavACfmEhUgU0VFRXHDDTcUuo28a25ujqamplN+fmNjYzQ0NG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gAAACB5Ag4AAAAgeQIOAAAAIHkCDgAAACB5Ag4AAAAgeQIOAAAAIHkCDgAAACB5Ag4AAAAgeQIOAAAAIHkCDgAAACB5Ag4AAAAgeQIOAAAAIHkCDgAAACB5Ag4AAAAgeQIOAAAAIHkCDgAAACB5Ag4AAAAgeQIOAAAAIHkCDgAAACB5Ag4AAAAgeQIOAAAAIHkCDgAAACB5Ag4AAAAgeQIOAAAAIHkCDgAAACB5Ag4AAAAgeQIOAAAAIHkCDgAAACB5Ag4AAAAgeQIOAAAAIHkCDgAAACB5Ag4AAAAgeQIOAAAAIHkCDgAAACB5Ag4AAAAgeQIOAAAAIHkCDgAAACB5Ag4AAAAgeQIOAAAAIHkCDgAAACB5Ag4AAAAgeQIOAAAAIHkCDgAAACB5/w8RG1j/1Z36RAAAAABJRU5ErkJggg==";
|
|
2461
2371
|
|
|
2462
2372
|
// src/components/Navigation/Logo/Logo.tsx
|
|
2463
|
-
var
|
|
2373
|
+
var import_jsx_runtime47 = require("react/jsx-runtime");
|
|
2464
2374
|
var Logo = ({
|
|
2465
2375
|
className,
|
|
2466
2376
|
style,
|
|
@@ -2468,7 +2378,7 @@ var Logo = ({
|
|
|
2468
2378
|
altText = "Preview"
|
|
2469
2379
|
}) => {
|
|
2470
2380
|
if (!imageUrl) {
|
|
2471
|
-
return /* @__PURE__ */ (0,
|
|
2381
|
+
return /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
|
|
2472
2382
|
"div",
|
|
2473
2383
|
{
|
|
2474
2384
|
className: cn(
|
|
@@ -2476,19 +2386,19 @@ var Logo = ({
|
|
|
2476
2386
|
"p-0"
|
|
2477
2387
|
),
|
|
2478
2388
|
style,
|
|
2479
|
-
children: /* @__PURE__ */ (0,
|
|
2389
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime47.jsx)("img", { src: logo_placeholder_default, alt: altText, className: "opacity-50", width: 150, height: 80 })
|
|
2480
2390
|
}
|
|
2481
2391
|
);
|
|
2482
2392
|
}
|
|
2483
|
-
return /* @__PURE__ */ (0,
|
|
2393
|
+
return /* @__PURE__ */ (0, import_jsx_runtime47.jsx)("img", { src: imageUrl, alt: altText, className, style });
|
|
2484
2394
|
};
|
|
2485
2395
|
var Logo_default = Logo;
|
|
2486
2396
|
|
|
2487
2397
|
// src/components/ui/avatar.tsx
|
|
2488
2398
|
var React15 = __toESM(require("react"));
|
|
2489
2399
|
var AvatarPrimitive = __toESM(require("@radix-ui/react-avatar"));
|
|
2490
|
-
var
|
|
2491
|
-
var Avatar = React15.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0,
|
|
2400
|
+
var import_jsx_runtime48 = require("react/jsx-runtime");
|
|
2401
|
+
var Avatar = React15.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(
|
|
2492
2402
|
AvatarPrimitive.Root,
|
|
2493
2403
|
{
|
|
2494
2404
|
ref,
|
|
@@ -2500,7 +2410,7 @@ var Avatar = React15.forwardRef(({ className, ...props }, ref) => /* @__PURE__ *
|
|
|
2500
2410
|
}
|
|
2501
2411
|
));
|
|
2502
2412
|
Avatar.displayName = AvatarPrimitive.Root.displayName;
|
|
2503
|
-
var AvatarImage = React15.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0,
|
|
2413
|
+
var AvatarImage = React15.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(
|
|
2504
2414
|
AvatarPrimitive.Image,
|
|
2505
2415
|
{
|
|
2506
2416
|
ref,
|
|
@@ -2509,7 +2419,7 @@ var AvatarImage = React15.forwardRef(({ className, ...props }, ref) => /* @__PUR
|
|
|
2509
2419
|
}
|
|
2510
2420
|
));
|
|
2511
2421
|
AvatarImage.displayName = AvatarPrimitive.Image.displayName;
|
|
2512
|
-
var AvatarFallback = React15.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0,
|
|
2422
|
+
var AvatarFallback = React15.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(
|
|
2513
2423
|
AvatarPrimitive.Fallback,
|
|
2514
2424
|
{
|
|
2515
2425
|
ref,
|
|
@@ -2523,7 +2433,7 @@ var AvatarFallback = React15.forwardRef(({ className, ...props }, ref) => /* @__
|
|
|
2523
2433
|
AvatarFallback.displayName = AvatarPrimitive.Fallback.displayName;
|
|
2524
2434
|
|
|
2525
2435
|
// src/components/Navigation/Navbar/Navbar.tsx
|
|
2526
|
-
var
|
|
2436
|
+
var import_jsx_runtime49 = require("react/jsx-runtime");
|
|
2527
2437
|
function Navbar({
|
|
2528
2438
|
style,
|
|
2529
2439
|
badgeType,
|
|
@@ -2538,61 +2448,61 @@ function Navbar({
|
|
|
2538
2448
|
ImageComponent
|
|
2539
2449
|
}) {
|
|
2540
2450
|
const isMobileView = canvasMode === "mobile" || canvasMode === "tablet";
|
|
2541
|
-
return /* @__PURE__ */ (0,
|
|
2542
|
-
LinkComponent && ImageComponent ? /* @__PURE__ */ (0,
|
|
2543
|
-
/* @__PURE__ */ (0,
|
|
2544
|
-
!isMobileView ? /* @__PURE__ */ (0,
|
|
2545
|
-
/* @__PURE__ */ (0,
|
|
2546
|
-
/* @__PURE__ */ (0,
|
|
2547
|
-
] }) }) : /* @__PURE__ */ (0,
|
|
2451
|
+
return /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("nav", { className: "w-full border-b bg-white shadow-sm", style, children: /* @__PURE__ */ (0, import_jsx_runtime49.jsxs)("div", { className: "mx-auto flex max-w-7xl items-center justify-between px-4 py-2", children: [
|
|
2452
|
+
LinkComponent && ImageComponent ? /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(LinkComponent, { href: "/", className: "flex items-center space-x-2", children: imageUrl ? /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(ImageComponent, { src: imageUrl, alt: altText, width: 200, height: 200 }) : /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("span", { className: "font-semibold text-blue-700", children: "Logo" }) }) : /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("span", { className: "font-semibold text-blue-700", children: "Logo" }),
|
|
2453
|
+
/* @__PURE__ */ (0, import_jsx_runtime49.jsxs)("div", { className: "flex items-center space-x-3", children: [
|
|
2454
|
+
!isMobileView ? /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("div", { className: "flex-1 px-6", children: /* @__PURE__ */ (0, import_jsx_runtime49.jsxs)("div", { className: "relative w-full max-w-md border border-gray-300 rounded-md", children: [
|
|
2455
|
+
/* @__PURE__ */ (0, import_jsx_runtime49.jsx)(Search, { className: "absolute left-3 top-1/2 -translate-y-1/2 h-4 w-4 text-gray-400" }),
|
|
2456
|
+
/* @__PURE__ */ (0, import_jsx_runtime49.jsx)(Input, { placeholder: "Search", className: "pl-9 text-gray-400" })
|
|
2457
|
+
] }) }) : /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(
|
|
2548
2458
|
Button,
|
|
2549
2459
|
{
|
|
2550
2460
|
variant: "ghost",
|
|
2551
2461
|
size: "icon",
|
|
2552
2462
|
className: "border border-gray-400",
|
|
2553
|
-
children: /* @__PURE__ */ (0,
|
|
2463
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(Search, { className: "h-5 w-5 text-gray-400" })
|
|
2554
2464
|
}
|
|
2555
2465
|
),
|
|
2556
|
-
/* @__PURE__ */ (0,
|
|
2557
|
-
/* @__PURE__ */ (0,
|
|
2558
|
-
badgeType === "number" && !(hideBadgeWhenZero && badgeCount === 0) && badgeCount > 0 ? /* @__PURE__ */ (0,
|
|
2466
|
+
/* @__PURE__ */ (0, import_jsx_runtime49.jsxs)("div", { className: "relative bg-[#E9E9E9] rounded-md", children: [
|
|
2467
|
+
/* @__PURE__ */ (0, import_jsx_runtime49.jsx)(Button, { variant: "ghost", size: "icon", children: /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(Bell, { className: "h-5 w-5 text-[#1C1B1F]" }) }),
|
|
2468
|
+
badgeType === "number" && !(hideBadgeWhenZero && badgeCount === 0) && badgeCount > 0 ? /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("span", { className: "absolute -top-1 -right-1 flex h-4 w-4 items-center justify-center rounded-full bg-red-500 text-[10px] text-white leading-8", children: badgeCount }) : /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("span", { className: "absolute -top-1 -right-1 flex h-2 w-2 items-center justify-center rounded-full bg-red-500" })
|
|
2559
2469
|
] }),
|
|
2560
|
-
/* @__PURE__ */ (0,
|
|
2561
|
-
/* @__PURE__ */ (0,
|
|
2562
|
-
!isMobileView && showName && /* @__PURE__ */ (0,
|
|
2563
|
-
!isMobileView ? /* @__PURE__ */ (0,
|
|
2564
|
-
/* @__PURE__ */ (0,
|
|
2470
|
+
/* @__PURE__ */ (0, import_jsx_runtime49.jsxs)(DropdownMenu, { children: [
|
|
2471
|
+
/* @__PURE__ */ (0, import_jsx_runtime49.jsx)(DropdownMenuTrigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime49.jsxs)("div", { className: "flex items-center space-x-2", children: [
|
|
2472
|
+
!isMobileView && showName && /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("h4", { className: "text-[#000000] text-[13px] font-[500] mb-0", children: "Akbar Sheriff" }),
|
|
2473
|
+
!isMobileView ? /* @__PURE__ */ (0, import_jsx_runtime49.jsxs)(import_jsx_runtime49.Fragment, { children: [
|
|
2474
|
+
/* @__PURE__ */ (0, import_jsx_runtime49.jsx)(Avatar, { className: "cursor-pointer h-8 w-8 text-gray-900", children: profileType === "avatar" ? /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(
|
|
2565
2475
|
AvatarImage,
|
|
2566
2476
|
{
|
|
2567
2477
|
src: "/images/appbuilder/toolset/profile.svg",
|
|
2568
2478
|
alt: "Akbar Sheriff"
|
|
2569
2479
|
}
|
|
2570
|
-
) : /* @__PURE__ */ (0,
|
|
2571
|
-
/* @__PURE__ */ (0,
|
|
2480
|
+
) : /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("div", { className: "w-8 h-8 bg-[#12715b] rounded-full text-[#fff] text-center text-[11px] flex items-center justify-center", children: "AS" }) }),
|
|
2481
|
+
/* @__PURE__ */ (0, import_jsx_runtime49.jsx)(
|
|
2572
2482
|
Button,
|
|
2573
2483
|
{
|
|
2574
2484
|
variant: "ghost",
|
|
2575
2485
|
size: "icon",
|
|
2576
2486
|
className: "text-gray-900 md:hidden",
|
|
2577
|
-
children: /* @__PURE__ */ (0,
|
|
2487
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(Menu, { className: "h-6 w-6" })
|
|
2578
2488
|
}
|
|
2579
2489
|
)
|
|
2580
|
-
] }) : /* @__PURE__ */ (0,
|
|
2490
|
+
] }) : /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(
|
|
2581
2491
|
Button,
|
|
2582
2492
|
{
|
|
2583
2493
|
variant: "ghost",
|
|
2584
2494
|
size: "icon",
|
|
2585
2495
|
className: "text-gray-900",
|
|
2586
|
-
children: /* @__PURE__ */ (0,
|
|
2496
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(Menu, { className: "h-6 w-6" })
|
|
2587
2497
|
}
|
|
2588
2498
|
)
|
|
2589
2499
|
] }) }),
|
|
2590
|
-
/* @__PURE__ */ (0,
|
|
2591
|
-
/* @__PURE__ */ (0,
|
|
2592
|
-
/* @__PURE__ */ (0,
|
|
2593
|
-
/* @__PURE__ */ (0,
|
|
2594
|
-
/* @__PURE__ */ (0,
|
|
2595
|
-
/* @__PURE__ */ (0,
|
|
2500
|
+
/* @__PURE__ */ (0, import_jsx_runtime49.jsxs)(DropdownMenuContent, { align: "end", className: "bg-white", children: [
|
|
2501
|
+
/* @__PURE__ */ (0, import_jsx_runtime49.jsx)(DropdownMenuLabel, { className: "text-black", children: "My Account" }),
|
|
2502
|
+
/* @__PURE__ */ (0, import_jsx_runtime49.jsx)(DropdownMenuSeparator, {}),
|
|
2503
|
+
/* @__PURE__ */ (0, import_jsx_runtime49.jsx)(DropdownMenuItem, { className: "text-black", children: "Profile" }),
|
|
2504
|
+
/* @__PURE__ */ (0, import_jsx_runtime49.jsx)(DropdownMenuItem, { className: "text-black", children: "Settings" }),
|
|
2505
|
+
/* @__PURE__ */ (0, import_jsx_runtime49.jsx)(DropdownMenuItem, { className: "text-black", children: "Logout" })
|
|
2596
2506
|
] })
|
|
2597
2507
|
] })
|
|
2598
2508
|
] })
|
|
@@ -2601,28 +2511,28 @@ function Navbar({
|
|
|
2601
2511
|
|
|
2602
2512
|
// src/components/Chart/BarChart.tsx
|
|
2603
2513
|
var import_recharts = require("recharts");
|
|
2604
|
-
var
|
|
2514
|
+
var import_jsx_runtime50 = require("react/jsx-runtime");
|
|
2605
2515
|
var ChartComponent = ({ className, style, ...props }) => {
|
|
2606
2516
|
const data = Array.isArray(props?.data) ? props.data : [];
|
|
2607
2517
|
const chartType = props.chartType || "bar";
|
|
2608
2518
|
const legendsPosition = props.legendsPosition === "middle" || props.legendsPosition === "bottom" ? props.legendsPosition : "top";
|
|
2609
|
-
return /* @__PURE__ */ (0,
|
|
2610
|
-
/* @__PURE__ */ (0,
|
|
2611
|
-
/* @__PURE__ */ (0,
|
|
2612
|
-
/* @__PURE__ */ (0,
|
|
2613
|
-
/* @__PURE__ */ (0,
|
|
2614
|
-
/* @__PURE__ */ (0,
|
|
2615
|
-
/* @__PURE__ */ (0,
|
|
2616
|
-
] }) : /* @__PURE__ */ (0,
|
|
2617
|
-
/* @__PURE__ */ (0,
|
|
2618
|
-
/* @__PURE__ */ (0,
|
|
2619
|
-
/* @__PURE__ */ (0,
|
|
2519
|
+
return /* @__PURE__ */ (0, import_jsx_runtime50.jsx)("div", { className: `${className} h-[400px]`, style, children: data.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(import_recharts.ResponsiveContainer, { width: "100%", height: "100%", children: chartType === "bar" ? /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)(import_recharts.BarChart, { data, children: [
|
|
2520
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)(import_recharts.CartesianGrid, { strokeDasharray: "3 3" }),
|
|
2521
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)(import_recharts.XAxis, { dataKey: "name" }),
|
|
2522
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)(import_recharts.YAxis, {}),
|
|
2523
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)(import_recharts.Tooltip, {}),
|
|
2524
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)(import_recharts.Legend, { verticalAlign: legendsPosition, align: "center" }),
|
|
2525
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)(import_recharts.Bar, { dataKey: "value", fill: "#00695C" })
|
|
2526
|
+
] }) : /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)(import_recharts.AreaChart, { data, children: [
|
|
2527
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)("defs", { children: /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)("linearGradient", { id: "colorCount", x1: "0", y1: "0", x2: "0", y2: "1", children: [
|
|
2528
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)("stop", { offset: "5%", stopColor: "#00695C", stopOpacity: 0.8 }),
|
|
2529
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)("stop", { offset: "95%", stopColor: "#00695C", stopOpacity: 0 })
|
|
2620
2530
|
] }) }),
|
|
2621
|
-
/* @__PURE__ */ (0,
|
|
2622
|
-
/* @__PURE__ */ (0,
|
|
2623
|
-
/* @__PURE__ */ (0,
|
|
2624
|
-
/* @__PURE__ */ (0,
|
|
2625
|
-
/* @__PURE__ */ (0,
|
|
2531
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)(import_recharts.CartesianGrid, { strokeDasharray: "3 3" }),
|
|
2532
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)(import_recharts.XAxis, { dataKey: "name" }),
|
|
2533
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)(import_recharts.YAxis, {}),
|
|
2534
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)(import_recharts.Tooltip, {}),
|
|
2535
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
|
|
2626
2536
|
import_recharts.Area,
|
|
2627
2537
|
{
|
|
2628
2538
|
type: "monotone",
|
|
@@ -2638,7 +2548,7 @@ var BarChart_default = ChartComponent;
|
|
|
2638
2548
|
|
|
2639
2549
|
// src/components/Chart/PieChart.tsx
|
|
2640
2550
|
var import_recharts2 = require("recharts");
|
|
2641
|
-
var
|
|
2551
|
+
var import_jsx_runtime51 = require("react/jsx-runtime");
|
|
2642
2552
|
var DonutChart = ({ className, style, ...props }) => {
|
|
2643
2553
|
const data = Array.isArray(props?.data) ? props.data : [];
|
|
2644
2554
|
const total = data.reduce((sum, d) => sum + d.value, 0);
|
|
@@ -2649,7 +2559,7 @@ var DonutChart = ({ className, style, ...props }) => {
|
|
|
2649
2559
|
const renderLabel = ({ value, x, y }) => {
|
|
2650
2560
|
if (value == null) return null;
|
|
2651
2561
|
const percentage = (Number(value) / total * 100).toFixed(0);
|
|
2652
|
-
return /* @__PURE__ */ (0,
|
|
2562
|
+
return /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)(
|
|
2653
2563
|
"text",
|
|
2654
2564
|
{
|
|
2655
2565
|
x,
|
|
@@ -2671,33 +2581,33 @@ var DonutChart = ({ className, style, ...props }) => {
|
|
|
2671
2581
|
const wrapperClass = canvasMode ? forceDesktop ? "flex-row" : "flex-col" : "flex-col md:flex-row";
|
|
2672
2582
|
const renderLegends = () => {
|
|
2673
2583
|
if (!showLegends) return null;
|
|
2674
|
-
return /* @__PURE__ */ (0,
|
|
2584
|
+
return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(import_jsx_runtime51.Fragment, { children: data.map((d) => /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)(
|
|
2675
2585
|
"div",
|
|
2676
2586
|
{
|
|
2677
2587
|
className: "flex items-center space-x-2 rounded-md border border-gray-200 px-3 py-2 w-[48%] md:w-auto",
|
|
2678
2588
|
children: [
|
|
2679
|
-
/* @__PURE__ */ (0,
|
|
2589
|
+
/* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
|
|
2680
2590
|
"span",
|
|
2681
2591
|
{
|
|
2682
2592
|
className: "inline-block w-[16px] h-[16px] rounded",
|
|
2683
2593
|
style: { backgroundColor: d.color }
|
|
2684
2594
|
}
|
|
2685
2595
|
),
|
|
2686
|
-
/* @__PURE__ */ (0,
|
|
2596
|
+
/* @__PURE__ */ (0, import_jsx_runtime51.jsx)("span", { className: "text-[#000000] text-[12px] md:text-[13px] font-[500]", children: d.name })
|
|
2687
2597
|
]
|
|
2688
2598
|
},
|
|
2689
2599
|
d.name
|
|
2690
2600
|
)) });
|
|
2691
2601
|
};
|
|
2692
|
-
return /* @__PURE__ */ (0,
|
|
2602
|
+
return /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)(
|
|
2693
2603
|
"div",
|
|
2694
2604
|
{
|
|
2695
2605
|
className: `relative flex items-center ${wrapperClass} ${className}`,
|
|
2696
2606
|
style,
|
|
2697
2607
|
children: [
|
|
2698
|
-
/* @__PURE__ */ (0,
|
|
2699
|
-
data.length > 0 && /* @__PURE__ */ (0,
|
|
2700
|
-
/* @__PURE__ */ (0,
|
|
2608
|
+
/* @__PURE__ */ (0, import_jsx_runtime51.jsxs)("div", { className: "relative w-full md:w-[70%] h-[300px] md:h-[400px] flex items-center justify-center", children: [
|
|
2609
|
+
data.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(import_recharts2.ResponsiveContainer, { width: "100%", height: "100%", children: /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)(import_recharts2.PieChart, { children: [
|
|
2610
|
+
/* @__PURE__ */ (0, import_jsx_runtime51.jsxs)(
|
|
2701
2611
|
import_recharts2.Pie,
|
|
2702
2612
|
{
|
|
2703
2613
|
data,
|
|
@@ -2709,8 +2619,8 @@ var DonutChart = ({ className, style, ...props }) => {
|
|
|
2709
2619
|
labelLine: false,
|
|
2710
2620
|
isAnimationActive: false,
|
|
2711
2621
|
children: [
|
|
2712
|
-
data.map((entry, index) => /* @__PURE__ */ (0,
|
|
2713
|
-
/* @__PURE__ */ (0,
|
|
2622
|
+
data.map((entry, index) => /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(import_recharts2.Cell, { fill: entry.color }, `cell-${index}`)),
|
|
2623
|
+
/* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
|
|
2714
2624
|
import_recharts2.LabelList,
|
|
2715
2625
|
{
|
|
2716
2626
|
dataKey: "value",
|
|
@@ -2721,14 +2631,14 @@ var DonutChart = ({ className, style, ...props }) => {
|
|
|
2721
2631
|
]
|
|
2722
2632
|
}
|
|
2723
2633
|
),
|
|
2724
|
-
/* @__PURE__ */ (0,
|
|
2634
|
+
/* @__PURE__ */ (0, import_jsx_runtime51.jsx)(import_recharts2.Tooltip, { formatter: (value, name) => [`${value}k`, name] })
|
|
2725
2635
|
] }) }),
|
|
2726
|
-
/* @__PURE__ */ (0,
|
|
2636
|
+
/* @__PURE__ */ (0, import_jsx_runtime51.jsxs)("div", { className: "absolute left-1/2 top-1/2 -translate-x-1/2 -translate-y-1/2 text-2xl md:text-4xl font-bold text-[#000]", children: [
|
|
2727
2637
|
total,
|
|
2728
2638
|
"k"
|
|
2729
2639
|
] })
|
|
2730
2640
|
] }),
|
|
2731
|
-
/* @__PURE__ */ (0,
|
|
2641
|
+
/* @__PURE__ */ (0, import_jsx_runtime51.jsx)("div", { className: `flex ${forceDesktop ? "flex-col ml-auto space-y-3" : "flex-wrap justify-center gap-2 mt-4"}
|
|
2732
2642
|
w-full md:w-auto`, children: renderLegends() })
|
|
2733
2643
|
]
|
|
2734
2644
|
}
|
|
@@ -2737,10 +2647,10 @@ var DonutChart = ({ className, style, ...props }) => {
|
|
|
2737
2647
|
var PieChart_default = DonutChart;
|
|
2738
2648
|
|
|
2739
2649
|
// src/components/Blocks/EmailComposer.tsx
|
|
2740
|
-
var
|
|
2650
|
+
var import_jsx_runtime52 = require("react/jsx-runtime");
|
|
2741
2651
|
function EmailComposer({ className, style, to, setTo, showCc, setShowCc, showBcc, setShowBcc, cc, setCc, bcc, setBcc, subject, setSubject, body, setBody }) {
|
|
2742
|
-
return /* @__PURE__ */ (0,
|
|
2743
|
-
/* @__PURE__ */ (0,
|
|
2652
|
+
return /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("div", { className, style, children: /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)("div", { className: "border rounded-md shadow bg-[#fff] p-4 mx-auto z-[50] relative", children: [
|
|
2653
|
+
/* @__PURE__ */ (0, import_jsx_runtime52.jsx)("div", { className: "mb-3", children: /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
|
|
2744
2654
|
"input",
|
|
2745
2655
|
{
|
|
2746
2656
|
type: "email",
|
|
@@ -2749,8 +2659,8 @@ function EmailComposer({ className, style, to, setTo, showCc, setShowCc, showBcc
|
|
|
2749
2659
|
required: true
|
|
2750
2660
|
}
|
|
2751
2661
|
) }),
|
|
2752
|
-
/* @__PURE__ */ (0,
|
|
2753
|
-
/* @__PURE__ */ (0,
|
|
2662
|
+
/* @__PURE__ */ (0, import_jsx_runtime52.jsx)("div", { className: "mb-3", children: /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)("div", { className: "flex items-center gap-2", children: [
|
|
2663
|
+
/* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
|
|
2754
2664
|
"input",
|
|
2755
2665
|
{
|
|
2756
2666
|
type: "email",
|
|
@@ -2761,7 +2671,7 @@ function EmailComposer({ className, style, to, setTo, showCc, setShowCc, showBcc
|
|
|
2761
2671
|
required: true
|
|
2762
2672
|
}
|
|
2763
2673
|
),
|
|
2764
|
-
!showCc && /* @__PURE__ */ (0,
|
|
2674
|
+
!showCc && /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
|
|
2765
2675
|
"button",
|
|
2766
2676
|
{
|
|
2767
2677
|
onClick: () => setShowCc?.(true),
|
|
@@ -2769,7 +2679,7 @@ function EmailComposer({ className, style, to, setTo, showCc, setShowCc, showBcc
|
|
|
2769
2679
|
children: "Cc"
|
|
2770
2680
|
}
|
|
2771
2681
|
),
|
|
2772
|
-
!showBcc && /* @__PURE__ */ (0,
|
|
2682
|
+
!showBcc && /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
|
|
2773
2683
|
"button",
|
|
2774
2684
|
{
|
|
2775
2685
|
onClick: () => setShowBcc?.(true),
|
|
@@ -2778,7 +2688,7 @@ function EmailComposer({ className, style, to, setTo, showCc, setShowCc, showBcc
|
|
|
2778
2688
|
}
|
|
2779
2689
|
)
|
|
2780
2690
|
] }) }),
|
|
2781
|
-
showCc && /* @__PURE__ */ (0,
|
|
2691
|
+
showCc && /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("div", { className: "mb-3", children: /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
|
|
2782
2692
|
"input",
|
|
2783
2693
|
{
|
|
2784
2694
|
type: "text",
|
|
@@ -2788,7 +2698,7 @@ function EmailComposer({ className, style, to, setTo, showCc, setShowCc, showBcc
|
|
|
2788
2698
|
className: "w-full flex-1 border-2 rounded-md h-[40px] px-3 focus:outline-none border-[#E9E9E9] text-[#383838]"
|
|
2789
2699
|
}
|
|
2790
2700
|
) }),
|
|
2791
|
-
showBcc && /* @__PURE__ */ (0,
|
|
2701
|
+
showBcc && /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("div", { className: "mb-3", children: /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
|
|
2792
2702
|
"input",
|
|
2793
2703
|
{
|
|
2794
2704
|
type: "text",
|
|
@@ -2798,7 +2708,7 @@ function EmailComposer({ className, style, to, setTo, showCc, setShowCc, showBcc
|
|
|
2798
2708
|
className: "w-full flex-1 border-2 rounded-md h-[40px] px-3 focus:outline-none border-[#E9E9E9] text-[#383838]"
|
|
2799
2709
|
}
|
|
2800
2710
|
) }),
|
|
2801
|
-
/* @__PURE__ */ (0,
|
|
2711
|
+
/* @__PURE__ */ (0, import_jsx_runtime52.jsx)("div", { className: "mb-3", children: /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
|
|
2802
2712
|
"input",
|
|
2803
2713
|
{
|
|
2804
2714
|
type: "text",
|
|
@@ -2808,11 +2718,11 @@ function EmailComposer({ className, style, to, setTo, showCc, setShowCc, showBcc
|
|
|
2808
2718
|
className: "w-full flex-1 border-2 rounded-md h-[40px] px-3 focus:outline-none border-[#E9E9E9] text-[#383838]"
|
|
2809
2719
|
}
|
|
2810
2720
|
) }),
|
|
2811
|
-
/* @__PURE__ */ (0,
|
|
2812
|
-
/* @__PURE__ */ (0,
|
|
2813
|
-
/* @__PURE__ */ (0,
|
|
2814
|
-
/* @__PURE__ */ (0,
|
|
2815
|
-
/* @__PURE__ */ (0,
|
|
2721
|
+
/* @__PURE__ */ (0, import_jsx_runtime52.jsx)("div", { className: "mb-4", children: /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(MyEditor, { value: body, onChange: setBody }) }),
|
|
2722
|
+
/* @__PURE__ */ (0, import_jsx_runtime52.jsxs)("div", { className: "flex justify-end gap-2", children: [
|
|
2723
|
+
/* @__PURE__ */ (0, import_jsx_runtime52.jsx)("button", { className: "px-4 py-2 rounded-md text-gray-600 hover:bg-gray-100", children: "Discard" }),
|
|
2724
|
+
/* @__PURE__ */ (0, import_jsx_runtime52.jsx)("button", { className: "px-4 py-2 rounded-md border text-[#12715B] border-[#12715B]", children: "Reset" }),
|
|
2725
|
+
/* @__PURE__ */ (0, import_jsx_runtime52.jsx)("button", { className: "px-4 py-2 rounded-md bg-[#12715B] text-white", children: "Send" })
|
|
2816
2726
|
] })
|
|
2817
2727
|
] }) });
|
|
2818
2728
|
}
|