@arkyn/components 3.0.9 → 3.0.10
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/components/calendar/_calendarProvider.d.ts.map +1 -1
- package/dist/components/datePicker/datePickerCalendarContainer/index.d.ts.map +1 -1
- package/dist/components/googleAnalytics/snippets/generateGAElements.d.ts.map +1 -1
- package/dist/components/googleTagManager/snippets/appendToDataLayer.d.ts.map +1 -1
- package/dist/components/googleTagManager/snippets/generateGTMElements.d.ts.map +1 -1
- package/dist/components/multiSelect/multiSelectOptionsContainer/index.d.ts.map +1 -1
- package/dist/components/richText/index.d.ts.map +1 -1
- package/dist/components/select/selectOptionsContainer/index.d.ts.map +1 -1
- package/dist/hooks/useFlipPosition.d.ts +38 -0
- package/dist/hooks/useFlipPosition.d.ts.map +1 -0
- package/dist/index.js +538 -511
- package/dist/index.js.map +1 -1
- package/dist/modules/components/calendar/_calendarProvider.js +47 -34
- package/dist/modules/components/calendar/_calendarProvider.js.map +1 -1
- package/dist/modules/components/datePicker/datePickerCalendarContainer/index.js +12 -19
- package/dist/modules/components/datePicker/datePickerCalendarContainer/index.js.map +1 -1
- package/dist/modules/components/googleAnalytics/snippets/generateGAElements.js +7 -6
- package/dist/modules/components/googleAnalytics/snippets/generateGAElements.js.map +1 -1
- package/dist/modules/components/googleTagManager/snippets/appendToDataLayer.js +7 -6
- package/dist/modules/components/googleTagManager/snippets/appendToDataLayer.js.map +1 -1
- package/dist/modules/components/googleTagManager/snippets/generateGTMElements.js +20 -14
- package/dist/modules/components/googleTagManager/snippets/generateGTMElements.js.map +1 -1
- package/dist/modules/components/multiSelect/multiSelectOptionsContainer/index.js +21 -28
- package/dist/modules/components/multiSelect/multiSelectOptionsContainer/index.js.map +1 -1
- package/dist/modules/components/richText/index.js +1 -1
- package/dist/modules/components/richText/index.js.map +1 -1
- package/dist/modules/components/select/selectOptionsContainer/index.js +21 -28
- package/dist/modules/components/select/selectOptionsContainer/index.js.map +1 -1
- package/dist/modules/hooks/useFlipPosition.js +26 -0
- package/dist/modules/hooks/useFlipPosition.js.map +1 -0
- package/dist/modules/utils/escapeForInlineScript.js +14 -0
- package/dist/modules/utils/escapeForInlineScript.js.map +1 -0
- package/dist/utils/escapeForInlineScript.d.ts +23 -0
- package/dist/utils/escapeForInlineScript.d.ts.map +1 -0
- package/package.json +9 -6
package/dist/index.js
CHANGED
|
@@ -662,39 +662,52 @@ var Je = class {
|
|
|
662
662
|
function Xe() {
|
|
663
663
|
return a(Ye);
|
|
664
664
|
}
|
|
665
|
-
|
|
666
|
-
|
|
667
|
-
|
|
665
|
+
var Ze = new Je();
|
|
666
|
+
function Qe(e) {
|
|
667
|
+
let { calendarType: t, children: n, defaultValue: r, defaultViewValue: a = /* @__PURE__ */ new Date(), language: o = "pt-BR", onChange: s, onChangeView: l, value: d, viewValue: f } = e, m = t === "single" ? [r || /* @__PURE__ */ new Date(), r || /* @__PURE__ */ new Date()] : r || [/* @__PURE__ */ new Date(), /* @__PURE__ */ new Date()], [h, g] = u(a), [_, v] = u(m), y = f || h, b = d ? t === "single" ? [d, d] : d : _, x = i((e) => {
|
|
668
668
|
let n = [new Date(e[0]), new Date(e[1])];
|
|
669
|
-
|
|
670
|
-
}
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
669
|
+
s && t === "range" && s(n), s && t === "single" && s(n[0]), v(n);
|
|
670
|
+
}, [t, s]), S = i((e) => {
|
|
671
|
+
l && l(e), g(e);
|
|
672
|
+
}, [l]), C = i((e, n, r) => Ze.changeDay(e, n, r, t, b, x, S), [
|
|
673
|
+
t,
|
|
674
|
+
b,
|
|
675
|
+
x,
|
|
676
|
+
S
|
|
677
|
+
]), w = i((e) => Ze.changeMonth(e, y, S), [y, S]), T = i((e) => Ze.changeYear(e, y, S), [y, S]), E = i(() => Ze.nextMonth(y, S), [y, S]), D = i(() => Ze.previousMonth(y, S), [y, S]), O = c(() => ({
|
|
678
|
+
valueDate: b,
|
|
679
|
+
viewDate: y,
|
|
680
|
+
currentDate: y.toLocaleDateString(o).slice(3),
|
|
681
|
+
currentDay: Ze.currentDay(y),
|
|
682
|
+
currentMonth: Ze.currentMonth(y),
|
|
683
|
+
currentYear: Ze.currentYear(y),
|
|
684
|
+
listWeek: Ze.listWeek(o),
|
|
685
|
+
listMonths: Ze.listMonths(y, o),
|
|
686
|
+
listYears: Ze.listYears(100),
|
|
687
|
+
listMatrix: Ze.listMatrix(y, b),
|
|
688
|
+
changeDay: C,
|
|
689
|
+
changeMonth: w,
|
|
690
|
+
changeYear: T,
|
|
691
|
+
nextMonth: E,
|
|
692
|
+
previousMonth: D
|
|
693
|
+
}), [
|
|
694
|
+
b,
|
|
695
|
+
y,
|
|
696
|
+
o,
|
|
697
|
+
C,
|
|
698
|
+
w,
|
|
699
|
+
T,
|
|
700
|
+
E,
|
|
701
|
+
D
|
|
702
|
+
]);
|
|
674
703
|
return /* @__PURE__ */ p(Ye.Provider, {
|
|
675
|
-
value:
|
|
676
|
-
valueDate: v,
|
|
677
|
-
viewDate: _,
|
|
678
|
-
currentDate: _.toLocaleDateString(a).slice(3),
|
|
679
|
-
currentDay: y.currentDay(_),
|
|
680
|
-
currentMonth: y.currentMonth(_),
|
|
681
|
-
currentYear: y.currentYear(_),
|
|
682
|
-
listWeek: y.listWeek(a),
|
|
683
|
-
listMonths: y.listMonths(_, a),
|
|
684
|
-
listYears: y.listYears(100),
|
|
685
|
-
listMatrix: y.listMatrix(_, v),
|
|
686
|
-
changeDay: (e, n, r) => y.changeDay(e, n, r, t, v, b, x),
|
|
687
|
-
changeMonth: (e) => y.changeMonth(e, _, x),
|
|
688
|
-
changeYear: (e) => y.changeYear(e, _, x),
|
|
689
|
-
nextMonth: () => y.nextMonth(_, x),
|
|
690
|
-
previousMonth: () => y.previousMonth(_, x)
|
|
691
|
-
},
|
|
704
|
+
value: O,
|
|
692
705
|
children: n
|
|
693
706
|
});
|
|
694
707
|
}
|
|
695
708
|
//#endregion
|
|
696
709
|
//#region src/components/calendar/calendarContainer/index.tsx
|
|
697
|
-
function
|
|
710
|
+
function $e({ children: e }) {
|
|
698
711
|
return /* @__PURE__ */ p("div", {
|
|
699
712
|
className: "arkynCalendarContainer",
|
|
700
713
|
children: e
|
|
@@ -702,7 +715,7 @@ function Qe({ children: e }) {
|
|
|
702
715
|
}
|
|
703
716
|
//#endregion
|
|
704
717
|
//#region src/services/fieldTemplate.tsx
|
|
705
|
-
function
|
|
718
|
+
function et(e) {
|
|
706
719
|
let { name: t, label: n, showAsterisk: r, className: i, unShowFieldTemplate: a, errorMessage: o, children: s, orientation: c } = e;
|
|
707
720
|
return a ? s : /* @__PURE__ */ m(ze, {
|
|
708
721
|
id: t,
|
|
@@ -721,7 +734,7 @@ function $e(e) {
|
|
|
721
734
|
}
|
|
722
735
|
//#endregion
|
|
723
736
|
//#region src/components/select/selectChevron/index.tsx
|
|
724
|
-
function
|
|
737
|
+
function tt(e) {
|
|
725
738
|
let { iconSize: t, isLoading: n, disabled: r, readOnly: i, isFocused: a } = e;
|
|
726
739
|
return n ? null : /* @__PURE__ */ p(C, {
|
|
727
740
|
className: `arkynSelectChevron ${r || i ? "notAnimate" : ""} ${a ? "focused" : ""}`,
|
|
@@ -736,7 +749,7 @@ function et(e) {
|
|
|
736
749
|
}
|
|
737
750
|
//#endregion
|
|
738
751
|
//#region src/components/select/selectContainer/index.tsx
|
|
739
|
-
function
|
|
752
|
+
function nt(e) {
|
|
740
753
|
let { children: t, handleContainerFocus: n, disabled: r, isError: i, isLoading: a, isFocused: o, className: s, readOnly: c, variant: l, size: u, id: d, prefixExists: f, containerRef: m, onContainerKeyDown: h, tabIndex: g, ariaControls: _, ariaActiveDescendant: v } = e;
|
|
741
754
|
return /* @__PURE__ */ p("div", {
|
|
742
755
|
ref: m,
|
|
@@ -755,7 +768,7 @@ function tt(e) {
|
|
|
755
768
|
}
|
|
756
769
|
//#endregion
|
|
757
770
|
//#region src/components/select/selectContent/index.tsx
|
|
758
|
-
function
|
|
771
|
+
function rt(e) {
|
|
759
772
|
let { children: t, size: n } = e;
|
|
760
773
|
return /* @__PURE__ */ p("div", {
|
|
761
774
|
className: `arkynSelectContent ${n}`,
|
|
@@ -764,7 +777,7 @@ function nt(e) {
|
|
|
764
777
|
}
|
|
765
778
|
//#endregion
|
|
766
779
|
//#region src/components/select/selectOption/index.tsx
|
|
767
|
-
function
|
|
780
|
+
function it(e) {
|
|
768
781
|
let { label: t, optionHasSelected: n, handleChangeValue: r, value: i, size: a, id: o, isHighlighted: s = !1 } = e, c = n(i);
|
|
769
782
|
return /* @__PURE__ */ m("button", {
|
|
770
783
|
type: "button",
|
|
@@ -781,14 +794,36 @@ function rt(e) {
|
|
|
781
794
|
});
|
|
782
795
|
}
|
|
783
796
|
//#endregion
|
|
797
|
+
//#region src/hooks/useFlipPosition.ts
|
|
798
|
+
function at(e, t, n) {
|
|
799
|
+
let [r, i] = u("bottom");
|
|
800
|
+
return o(() => {
|
|
801
|
+
if (!t) return;
|
|
802
|
+
function r() {
|
|
803
|
+
if (!e.current) return;
|
|
804
|
+
let t = e.current.parentElement;
|
|
805
|
+
if (!t) return;
|
|
806
|
+
let r = t.getBoundingClientRect();
|
|
807
|
+
window.innerHeight - r.bottom < n && r.top > n ? i("top") : i("bottom");
|
|
808
|
+
}
|
|
809
|
+
return r(), window.addEventListener("resize", r), () => {
|
|
810
|
+
window.removeEventListener("resize", r);
|
|
811
|
+
};
|
|
812
|
+
}, [
|
|
813
|
+
e,
|
|
814
|
+
t,
|
|
815
|
+
n
|
|
816
|
+
]), r;
|
|
817
|
+
}
|
|
818
|
+
//#endregion
|
|
784
819
|
//#region src/hooks/useScrollLock.ts
|
|
785
|
-
function
|
|
820
|
+
function ot() {
|
|
786
821
|
return typeof window > "u" ? 0 : window.innerWidth - document.documentElement.clientWidth;
|
|
787
822
|
}
|
|
788
|
-
function
|
|
823
|
+
function st(e) {
|
|
789
824
|
o(() => {
|
|
790
825
|
if (e) {
|
|
791
|
-
let e = document.body.style.overflow, t = document.body.style.paddingRight, n =
|
|
826
|
+
let e = document.body.style.overflow, t = document.body.style.paddingRight, n = ot();
|
|
792
827
|
if (n > 0) {
|
|
793
828
|
let e = window.getComputedStyle(document.body), t = parseInt(e.paddingRight, 10) || 0;
|
|
794
829
|
document.body.style.paddingRight = `${t + n}px`;
|
|
@@ -801,7 +836,7 @@ function at(e) {
|
|
|
801
836
|
}
|
|
802
837
|
//#endregion
|
|
803
838
|
//#region src/components/input/index.tsx
|
|
804
|
-
function
|
|
839
|
+
function ct(e) {
|
|
805
840
|
let { name: t, disabled: n, title: r, style: i, variant: a = "solid", label: o, className: c = "", prefix: d, suffix: f, isLoading: h = !1, leftIcon: g, readOnly: _, onFocus: v, onBlur: y, unShowFieldTemplate: b = !1, errorMessage: x, showAsterisk: S, rightIcon: C, type: w = "text", size: T = "md", id: E, value: D, placeholder: O, orientation: k, ...A } = e, { fieldErrors: j } = Q(), [M, N] = u(!1), P = l(null), F = s(), I = E || F, L = x || j?.[t], ee = !!L, z = n || h, B = {
|
|
806
841
|
md: 20,
|
|
807
842
|
lg: 20
|
|
@@ -821,7 +856,7 @@ function ot(e) {
|
|
|
821
856
|
type: "text",
|
|
822
857
|
ref: P,
|
|
823
858
|
...A
|
|
824
|
-
}) : /* @__PURE__ */ p(
|
|
859
|
+
}) : /* @__PURE__ */ p(et, {
|
|
825
860
|
name: t,
|
|
826
861
|
label: o,
|
|
827
862
|
showAsterisk: S,
|
|
@@ -886,38 +921,30 @@ function ot(e) {
|
|
|
886
921
|
}
|
|
887
922
|
//#endregion
|
|
888
923
|
//#region src/components/select/selectOptionsContainer/index.tsx
|
|
889
|
-
function
|
|
890
|
-
let { children: t, id: n, isFocused: r, isSearchable: i, search: a, onSearch:
|
|
891
|
-
|
|
892
|
-
|
|
893
|
-
|
|
894
|
-
let e = c.current.parentElement;
|
|
895
|
-
if (!e) return;
|
|
896
|
-
let t = e.getBoundingClientRect();
|
|
897
|
-
window.innerHeight - t.bottom < 300 && t.top > 300 ? f("top") : f("bottom");
|
|
898
|
-
})();
|
|
899
|
-
}, [r]);
|
|
900
|
-
function h(e) {
|
|
901
|
-
i && s(e.target.value);
|
|
924
|
+
function lt(e) {
|
|
925
|
+
let { children: t, id: n, isFocused: r, isSearchable: i, search: a, onSearch: o } = e, s = l(null), c = at(s, r, 300);
|
|
926
|
+
st(r);
|
|
927
|
+
function u(e) {
|
|
928
|
+
i && o(e.target.value);
|
|
902
929
|
}
|
|
903
930
|
return r ? /* @__PURE__ */ m("div", {
|
|
904
|
-
ref:
|
|
931
|
+
ref: s,
|
|
905
932
|
id: n,
|
|
906
933
|
role: "listbox",
|
|
907
|
-
className: `arkynSelectOptionsContainer ${
|
|
908
|
-
children: [i && /* @__PURE__ */ p(
|
|
934
|
+
className: `arkynSelectOptionsContainer ${c}`,
|
|
935
|
+
children: [i && /* @__PURE__ */ p(ct, {
|
|
909
936
|
type: "search",
|
|
910
937
|
name: "search-select",
|
|
911
938
|
variant: "underline",
|
|
912
939
|
leftIcon: U,
|
|
913
940
|
value: a,
|
|
914
|
-
onChange:
|
|
941
|
+
onChange: u
|
|
915
942
|
}), t]
|
|
916
943
|
}) : null;
|
|
917
944
|
}
|
|
918
945
|
//#endregion
|
|
919
946
|
//#region src/components/select/selectOverlay/index.tsx
|
|
920
|
-
function
|
|
947
|
+
function ut(e) {
|
|
921
948
|
let { isFocused: t, handleBlur: n } = e;
|
|
922
949
|
return t ? /* @__PURE__ */ p("aside", {
|
|
923
950
|
className: "arkynSelectOverlay",
|
|
@@ -926,7 +953,7 @@ function ct(e) {
|
|
|
926
953
|
}
|
|
927
954
|
//#endregion
|
|
928
955
|
//#region src/components/select/selectSpinner/index.tsx
|
|
929
|
-
function
|
|
956
|
+
function dt(e) {
|
|
930
957
|
let { iconSize: t, isLoading: n } = e;
|
|
931
958
|
return n ? /* @__PURE__ */ p(R, {
|
|
932
959
|
className: "arkynSelectSpinner",
|
|
@@ -936,7 +963,7 @@ function lt(e) {
|
|
|
936
963
|
}
|
|
937
964
|
//#endregion
|
|
938
965
|
//#region src/components/select/index.tsx
|
|
939
|
-
function
|
|
966
|
+
function ft(e) {
|
|
940
967
|
let { name: t, options: n, className: r = "", placeholder: i = "Selecione...", closeOnSelect: a = !0, defaultValue: o = "", errorMessage: c, isLoading: d = !1, readOnly: f = !1, isSearchable: h = !1, id: g, label: _, showAsterisk: v, leftIcon: y, onSearch: b, onChange: x, onBlur: S, notFoundText: C = "Sem opções disponíveis", onFocus: w, disabled: T = !1, prefix: E, size: D = "md", value: O, variant: k = "solid", orientation: A = "vertical", unShowFieldTemplate: j = !1 } = e, { fieldErrors: M } = Q(), N = l(null), P = l(null), F = s(), I = g || F, L = `${I}-listbox`, R = c || M?.[t], ee = !!R, z = T || d || f, B = {
|
|
941
968
|
md: 20,
|
|
942
969
|
lg: 20
|
|
@@ -992,7 +1019,7 @@ function ut(e) {
|
|
|
992
1019
|
}
|
|
993
1020
|
}
|
|
994
1021
|
let ce = K >= 0 && K < X.length ? ie(X[K].value) : void 0;
|
|
995
|
-
return /* @__PURE__ */ p(
|
|
1022
|
+
return /* @__PURE__ */ p(et, {
|
|
996
1023
|
name: t,
|
|
997
1024
|
label: _,
|
|
998
1025
|
showAsterisk: v,
|
|
@@ -1000,7 +1027,7 @@ function ut(e) {
|
|
|
1000
1027
|
errorMessage: R,
|
|
1001
1028
|
unShowFieldTemplate: j,
|
|
1002
1029
|
orientation: A,
|
|
1003
|
-
children: /* @__PURE__ */ m(
|
|
1030
|
+
children: /* @__PURE__ */ m(nt, {
|
|
1004
1031
|
handleContainerFocus: ae,
|
|
1005
1032
|
disabled: z,
|
|
1006
1033
|
isError: ee,
|
|
@@ -1032,20 +1059,20 @@ function ut(e) {
|
|
|
1032
1059
|
size: B,
|
|
1033
1060
|
strokeWidth: 2.5
|
|
1034
1061
|
}),
|
|
1035
|
-
/* @__PURE__ */ m(
|
|
1062
|
+
/* @__PURE__ */ m(rt, {
|
|
1036
1063
|
size: D,
|
|
1037
1064
|
children: [J !== "" && /* @__PURE__ */ p("p", {
|
|
1038
1065
|
className: "hasValue",
|
|
1039
1066
|
children: re(J)
|
|
1040
1067
|
}), J === "" && /* @__PURE__ */ p("p", { children: i })]
|
|
1041
1068
|
}),
|
|
1042
|
-
/* @__PURE__ */ m(
|
|
1069
|
+
/* @__PURE__ */ m(lt, {
|
|
1043
1070
|
id: L,
|
|
1044
1071
|
isFocused: U,
|
|
1045
1072
|
isSearchable: h,
|
|
1046
1073
|
search: V,
|
|
1047
1074
|
onSearch: Y,
|
|
1048
|
-
children: [X.map(({ label: e, value: t }, n) => /* @__PURE__ */ p(
|
|
1075
|
+
children: [X.map(({ label: e, value: t }, n) => /* @__PURE__ */ p(it, {
|
|
1049
1076
|
id: ie(t),
|
|
1050
1077
|
label: e,
|
|
1051
1078
|
value: t,
|
|
@@ -1055,18 +1082,18 @@ function ut(e) {
|
|
|
1055
1082
|
optionHasSelected: ne
|
|
1056
1083
|
}, t)), X.length <= 0 && /* @__PURE__ */ p("p", { children: C })]
|
|
1057
1084
|
}),
|
|
1058
|
-
/* @__PURE__ */ p(
|
|
1085
|
+
/* @__PURE__ */ p(tt, {
|
|
1059
1086
|
disabled: z,
|
|
1060
1087
|
isFocused: U,
|
|
1061
1088
|
readOnly: f,
|
|
1062
1089
|
iconSize: B,
|
|
1063
1090
|
isLoading: d
|
|
1064
1091
|
}),
|
|
1065
|
-
/* @__PURE__ */ p(
|
|
1092
|
+
/* @__PURE__ */ p(dt, {
|
|
1066
1093
|
iconSize: B,
|
|
1067
1094
|
isLoading: d
|
|
1068
1095
|
}),
|
|
1069
|
-
/* @__PURE__ */ p(
|
|
1096
|
+
/* @__PURE__ */ p(ut, {
|
|
1070
1097
|
handleBlur: oe,
|
|
1071
1098
|
isFocused: U
|
|
1072
1099
|
})
|
|
@@ -1076,7 +1103,7 @@ function ut(e) {
|
|
|
1076
1103
|
}
|
|
1077
1104
|
//#endregion
|
|
1078
1105
|
//#region src/components/calendar/calendarHeader/index.tsx
|
|
1079
|
-
function
|
|
1106
|
+
function pt({ basicMode: e }) {
|
|
1080
1107
|
let t = Xe();
|
|
1081
1108
|
return e ? /* @__PURE__ */ m("div", {
|
|
1082
1109
|
className: "arkynCalendarHeader",
|
|
@@ -1107,14 +1134,14 @@ function dt({ basicMode: e }) {
|
|
|
1107
1134
|
className: "arkynCalendarButton",
|
|
1108
1135
|
onClick: () => t.nextMonth(),
|
|
1109
1136
|
children: /* @__PURE__ */ p(T, {})
|
|
1110
|
-
})] }), /* @__PURE__ */ m("div", { children: [/* @__PURE__ */ p(
|
|
1137
|
+
})] }), /* @__PURE__ */ m("div", { children: [/* @__PURE__ */ p(ft, {
|
|
1111
1138
|
name: "calendarMonth",
|
|
1112
1139
|
variant: "underline",
|
|
1113
1140
|
className: "calendarMonthSelect",
|
|
1114
1141
|
value: t.currentMonth,
|
|
1115
1142
|
options: t.listMonths,
|
|
1116
1143
|
onChange: (e) => t.changeMonth(+e)
|
|
1117
|
-
}), /* @__PURE__ */ p(
|
|
1144
|
+
}), /* @__PURE__ */ p(ft, {
|
|
1118
1145
|
name: "calendarYear",
|
|
1119
1146
|
variant: "underline",
|
|
1120
1147
|
className: "calendarYearSelect",
|
|
@@ -1126,7 +1153,7 @@ function dt({ basicMode: e }) {
|
|
|
1126
1153
|
}
|
|
1127
1154
|
//#endregion
|
|
1128
1155
|
//#region src/components/calendar/calendarTableTd/index.tsx
|
|
1129
|
-
function
|
|
1156
|
+
function mt(e) {
|
|
1130
1157
|
let { day: t, month: n, year: r, dayOwner: i, dayType: a } = e, { changeDay: o } = Xe();
|
|
1131
1158
|
function s() {
|
|
1132
1159
|
let e = /* @__PURE__ */ new Date();
|
|
@@ -1148,15 +1175,15 @@ function ft(e) {
|
|
|
1148
1175
|
}
|
|
1149
1176
|
//#endregion
|
|
1150
1177
|
//#region src/components/calendar/calendarTableBody/index.tsx
|
|
1151
|
-
function
|
|
1178
|
+
function ht() {
|
|
1152
1179
|
return /* @__PURE__ */ p("tbody", {
|
|
1153
1180
|
className: "arkynCalendarTableBody",
|
|
1154
|
-
children: Xe().listMatrix.map((e, t) => /* @__PURE__ */ p("tr", { children: e.map((e, n) => /* @__PURE__ */ p(
|
|
1181
|
+
children: Xe().listMatrix.map((e, t) => /* @__PURE__ */ p("tr", { children: e.map((e, n) => /* @__PURE__ */ p(mt, { ...e }, `day-${t}-${n}`)) }, `week-${t}`))
|
|
1155
1182
|
});
|
|
1156
1183
|
}
|
|
1157
1184
|
//#endregion
|
|
1158
1185
|
//#region src/components/calendar/calendarTableContainer/index.tsx
|
|
1159
|
-
function
|
|
1186
|
+
function gt({ children: e }) {
|
|
1160
1187
|
return /* @__PURE__ */ p("table", {
|
|
1161
1188
|
className: "arkynCalendarTableContainer",
|
|
1162
1189
|
children: e
|
|
@@ -1164,7 +1191,7 @@ function mt({ children: e }) {
|
|
|
1164
1191
|
}
|
|
1165
1192
|
//#endregion
|
|
1166
1193
|
//#region src/components/calendar/calendarTableHeader/index.tsx
|
|
1167
|
-
function
|
|
1194
|
+
function _t() {
|
|
1168
1195
|
let { listWeek: e } = Xe();
|
|
1169
1196
|
return /* @__PURE__ */ p("thead", {
|
|
1170
1197
|
className: "arkynCalendarTableHeader",
|
|
@@ -1173,9 +1200,9 @@ function ht() {
|
|
|
1173
1200
|
}
|
|
1174
1201
|
//#endregion
|
|
1175
1202
|
//#region src/components/calendar/index.tsx
|
|
1176
|
-
function
|
|
1203
|
+
function vt(e) {
|
|
1177
1204
|
let t = e.variant || "complete";
|
|
1178
|
-
return e.type === "range" ? /* @__PURE__ */ p(
|
|
1205
|
+
return e.type === "range" ? /* @__PURE__ */ p(Qe, {
|
|
1179
1206
|
value: e.value,
|
|
1180
1207
|
viewValue: e.viewValue,
|
|
1181
1208
|
defaultViewValue: e.defaultViewValue,
|
|
@@ -1183,8 +1210,8 @@ function gt(e) {
|
|
|
1183
1210
|
calendarType: "range",
|
|
1184
1211
|
onChange: e.onChange,
|
|
1185
1212
|
onChangeView: e.onChangeView,
|
|
1186
|
-
children: /* @__PURE__ */ m(
|
|
1187
|
-
}) : /* @__PURE__ */ p(
|
|
1213
|
+
children: /* @__PURE__ */ m($e, { children: [/* @__PURE__ */ p(pt, { basicMode: t.includes("basic") }), /* @__PURE__ */ m(gt, { children: [/* @__PURE__ */ p(_t, {}), /* @__PURE__ */ p(ht, {})] })] })
|
|
1214
|
+
}) : /* @__PURE__ */ p(Qe, {
|
|
1188
1215
|
value: e.value,
|
|
1189
1216
|
viewValue: e.viewValue,
|
|
1190
1217
|
defaultViewValue: e.defaultViewValue,
|
|
@@ -1192,16 +1219,16 @@ function gt(e) {
|
|
|
1192
1219
|
calendarType: "single",
|
|
1193
1220
|
onChange: e.onChange,
|
|
1194
1221
|
onChangeView: e.onChangeView,
|
|
1195
|
-
children: /* @__PURE__ */ m(
|
|
1222
|
+
children: /* @__PURE__ */ m($e, { children: [/* @__PURE__ */ p(pt, { basicMode: t.includes("basic") }), /* @__PURE__ */ m(gt, { children: [/* @__PURE__ */ p(_t, {}), /* @__PURE__ */ p(ht, {})] })] })
|
|
1196
1223
|
});
|
|
1197
1224
|
}
|
|
1198
1225
|
//#endregion
|
|
1199
1226
|
//#region src/components/cardTab/cardTabContext.tsx
|
|
1200
|
-
var
|
|
1201
|
-
function
|
|
1202
|
-
return a(
|
|
1227
|
+
var yt = n({});
|
|
1228
|
+
function bt() {
|
|
1229
|
+
return a(yt);
|
|
1203
1230
|
}
|
|
1204
|
-
function
|
|
1231
|
+
function xt(e) {
|
|
1205
1232
|
let { disabled: t, currentTab: n, changeCurrentTab: r } = e, i = c(() => ({
|
|
1206
1233
|
disabled: t,
|
|
1207
1234
|
currentTab: n,
|
|
@@ -1211,15 +1238,15 @@ function yt(e) {
|
|
|
1211
1238
|
n,
|
|
1212
1239
|
r
|
|
1213
1240
|
]);
|
|
1214
|
-
return /* @__PURE__ */ p(
|
|
1241
|
+
return /* @__PURE__ */ p(yt.Provider, {
|
|
1215
1242
|
value: i,
|
|
1216
1243
|
children: e.children
|
|
1217
1244
|
});
|
|
1218
1245
|
}
|
|
1219
1246
|
//#endregion
|
|
1220
1247
|
//#region src/components/cardTab/cardTabButton/index.tsx
|
|
1221
|
-
function
|
|
1222
|
-
let { children: t, disabled: n = !1, className: r = "", onClick: i, value: a, ...o } = e, { disabled: s, currentTab: c, changeCurrentTab: l } =
|
|
1248
|
+
function St(e) {
|
|
1249
|
+
let { children: t, disabled: n = !1, className: r = "", onClick: i, value: a, ...o } = e, { disabled: s, currentTab: c, changeCurrentTab: l } = bt(), u = s || n, d = `arkynCardTabButton ${u ? "isDisabled" : ""} ${c === a && a ? "isActive" : ""} ${r}`;
|
|
1223
1250
|
function f(e) {
|
|
1224
1251
|
l(a), i?.(e);
|
|
1225
1252
|
}
|
|
@@ -1234,12 +1261,12 @@ function bt(e) {
|
|
|
1234
1261
|
}
|
|
1235
1262
|
//#endregion
|
|
1236
1263
|
//#region src/components/cardTab/cardTabContainer/index.tsx
|
|
1237
|
-
function
|
|
1264
|
+
function Ct(e) {
|
|
1238
1265
|
let { children: t, onChange: n, defaultValue: r, disabled: i = !1, className: a, ...o } = e, [s, c] = u(r || ""), l = `arkynCardTabContainer ${a || ""}`;
|
|
1239
1266
|
function d(e) {
|
|
1240
1267
|
c(e), n && n(e);
|
|
1241
1268
|
}
|
|
1242
|
-
return /* @__PURE__ */ p(
|
|
1269
|
+
return /* @__PURE__ */ p(xt, {
|
|
1243
1270
|
disabled: i,
|
|
1244
1271
|
currentTab: s,
|
|
1245
1272
|
changeCurrentTab: d,
|
|
@@ -1252,13 +1279,13 @@ function xt(e) {
|
|
|
1252
1279
|
}
|
|
1253
1280
|
//#endregion
|
|
1254
1281
|
//#region src/components/checkbox/index.tsx
|
|
1255
|
-
function
|
|
1282
|
+
function wt(e) {
|
|
1256
1283
|
let { id: t, name: n, className: r = "", size: i = "md", errorMessage: a, defaultChecked: o = !1, label: c, checked: d = null, onCheck: f, orientation: h = "horizontalReverse", showAsterisk: g, unShowFieldTemplate: _, value: v, ...y } = e, { fieldErrors: b } = Q(), S = l(null), C = s(), w = t || C, T = a || b?.[n], E = !!T, [D, O] = u(o || !1), k = typeof d == "boolean" ? d : D, A = `arkynCheckbox ${i} ${E ? "errorTrue" : "errorFalse"} ${k ? "checkedTrue" : "checkedFalse"}`;
|
|
1257
1284
|
function j() {
|
|
1258
1285
|
let e = D;
|
|
1259
1286
|
O(!e), f?.(e ? "" : v || "checked");
|
|
1260
1287
|
}
|
|
1261
|
-
return /* @__PURE__ */ p(
|
|
1288
|
+
return /* @__PURE__ */ p(et, {
|
|
1262
1289
|
name: n,
|
|
1263
1290
|
label: c,
|
|
1264
1291
|
showAsterisk: g,
|
|
@@ -1283,32 +1310,32 @@ function St(e) {
|
|
|
1283
1310
|
}
|
|
1284
1311
|
//#endregion
|
|
1285
1312
|
//#region src/hooks/useHydrated.ts
|
|
1286
|
-
function
|
|
1313
|
+
function Tt() {
|
|
1287
1314
|
return () => {};
|
|
1288
1315
|
}
|
|
1289
|
-
function
|
|
1290
|
-
return d(
|
|
1316
|
+
function Et() {
|
|
1317
|
+
return d(Tt, () => !0, () => !1);
|
|
1291
1318
|
}
|
|
1292
1319
|
//#endregion
|
|
1293
1320
|
//#region src/components/clientOnly.tsx
|
|
1294
|
-
function
|
|
1321
|
+
function Dt(e) {
|
|
1295
1322
|
let { children: t, fallback: n = null } = e;
|
|
1296
|
-
return
|
|
1323
|
+
return Et() ? t() : n;
|
|
1297
1324
|
}
|
|
1298
1325
|
//#endregion
|
|
1299
1326
|
//#region src/services/maskCurrencyValues.ts
|
|
1300
|
-
function
|
|
1327
|
+
function Ot(e) {
|
|
1301
1328
|
let t = e;
|
|
1302
1329
|
return typeof e == "string" ? (t = +ie(e), t % 1 != 0 && (t = t.toFixed(2))) : t = Number.isInteger(e) ? Number(e) * 10 ** 2 : e.toFixed(2), ie(String(t)) / 10 ** 2;
|
|
1303
1330
|
}
|
|
1304
|
-
function
|
|
1331
|
+
function kt(e, t) {
|
|
1305
1332
|
if (!e) return [0, ne(0, t)];
|
|
1306
|
-
let n =
|
|
1333
|
+
let n = Ot(e);
|
|
1307
1334
|
return [n, ne(n, t)];
|
|
1308
1335
|
}
|
|
1309
1336
|
//#endregion
|
|
1310
1337
|
//#region src/components/currencyInput/index.tsx
|
|
1311
|
-
function
|
|
1338
|
+
function At(e) {
|
|
1312
1339
|
let { name: t, disabled: n, title: r, style: i, variant: a = "solid", label: c, className: d = "", value: f, defaultValue: h, max: g = 1e9, locale: _, onChange: v, prefix: y, suffix: b, isLoading: x = !1, leftIcon: S, readOnly: C, onFocus: w, onBlur: T, errorMessage: E, unShowFieldTemplate: D, orientation: O, showAsterisk: k, rightIcon: A, size: j = "md", id: M, ...N } = e, { fieldErrors: P } = Q(), [F, I] = u(!1), [L, ee] = u("0"), z = l(null), B = s(), V = M || B, H = E || P?.[t], U = !!H, W = n || x, G = {
|
|
1313
1340
|
md: 20,
|
|
1314
1341
|
lg: 20
|
|
@@ -1323,21 +1350,21 @@ function Ot(e) {
|
|
|
1323
1350
|
I(!1), T && T(e);
|
|
1324
1351
|
}
|
|
1325
1352
|
let ie = (e) => {
|
|
1326
|
-
let [t, n] =
|
|
1327
|
-
return !g || t <= g ? (ee(n), [t, n]) :
|
|
1353
|
+
let [t, n] = kt(e, _);
|
|
1354
|
+
return !g || t <= g ? (ee(n), [t, n]) : kt(e, _);
|
|
1328
1355
|
};
|
|
1329
1356
|
return o(() => {
|
|
1330
1357
|
function e() {
|
|
1331
1358
|
if (typeof f == "number") return f;
|
|
1332
1359
|
if (typeof h == "number") return h;
|
|
1333
1360
|
}
|
|
1334
|
-
let [, t] =
|
|
1361
|
+
let [, t] = kt(e(), _);
|
|
1335
1362
|
ee(t);
|
|
1336
1363
|
}, [
|
|
1337
1364
|
_,
|
|
1338
1365
|
h,
|
|
1339
1366
|
f
|
|
1340
|
-
]), /* @__PURE__ */ p(
|
|
1367
|
+
]), /* @__PURE__ */ p(et, {
|
|
1341
1368
|
name: t,
|
|
1342
1369
|
label: c,
|
|
1343
1370
|
showAsterisk: k,
|
|
@@ -1386,7 +1413,7 @@ function Ot(e) {
|
|
|
1386
1413
|
/* @__PURE__ */ p("input", {
|
|
1387
1414
|
type: "hidden",
|
|
1388
1415
|
name: t,
|
|
1389
|
-
value:
|
|
1416
|
+
value: Ot(L),
|
|
1390
1417
|
readOnly: !0
|
|
1391
1418
|
}),
|
|
1392
1419
|
/* @__PURE__ */ p($, {
|
|
@@ -1411,17 +1438,9 @@ function Ot(e) {
|
|
|
1411
1438
|
}
|
|
1412
1439
|
//#endregion
|
|
1413
1440
|
//#region src/components/datePicker/datePickerCalendarContainer/index.tsx
|
|
1414
|
-
function
|
|
1415
|
-
let { children: t, id: n, isFocused: r } = e, i = l(null),
|
|
1416
|
-
return
|
|
1417
|
-
r && (() => {
|
|
1418
|
-
if (!i.current) return;
|
|
1419
|
-
let e = i.current.parentElement;
|
|
1420
|
-
if (!e) return;
|
|
1421
|
-
let t = e.getBoundingClientRect();
|
|
1422
|
-
window.innerHeight - t.bottom < 420 && t.top > 420 ? s("top") : s("bottom");
|
|
1423
|
-
})();
|
|
1424
|
-
}, [r]), r ? /* @__PURE__ */ p("div", {
|
|
1441
|
+
function jt(e) {
|
|
1442
|
+
let { children: t, id: n, isFocused: r } = e, i = l(null), a = at(i, r, 420);
|
|
1443
|
+
return st(r), r ? /* @__PURE__ */ p("div", {
|
|
1425
1444
|
ref: i,
|
|
1426
1445
|
id: n,
|
|
1427
1446
|
role: "dialog",
|
|
@@ -1432,7 +1451,7 @@ function kt(e) {
|
|
|
1432
1451
|
}
|
|
1433
1452
|
//#endregion
|
|
1434
1453
|
//#region src/components/datePicker/datePickerChevron/index.tsx
|
|
1435
|
-
function
|
|
1454
|
+
function Mt(e) {
|
|
1436
1455
|
let { iconSize: t, isLoading: n, disabled: r, readOnly: i, isFocused: a } = e;
|
|
1437
1456
|
return n ? null : /* @__PURE__ */ p(C, {
|
|
1438
1457
|
className: `arkynDatePickerChevron ${r || i ? "notAnimate" : ""} ${a ? "focused" : ""}`,
|
|
@@ -1447,7 +1466,7 @@ function At(e) {
|
|
|
1447
1466
|
}
|
|
1448
1467
|
//#endregion
|
|
1449
1468
|
//#region src/components/datePicker/datePickerContainer/index.tsx
|
|
1450
|
-
function
|
|
1469
|
+
function Nt(e) {
|
|
1451
1470
|
let { children: t, handleContainerFocus: n, disabled: r, isError: i, isLoading: a, isFocused: o, className: s, readOnly: c, variant: l, size: u, id: d, prefixExists: f, containerRef: m, onContainerKeyDown: h, tabIndex: g, ariaControls: _ } = e;
|
|
1452
1471
|
return /* @__PURE__ */ p("div", {
|
|
1453
1472
|
ref: m,
|
|
@@ -1465,7 +1484,7 @@ function jt(e) {
|
|
|
1465
1484
|
}
|
|
1466
1485
|
//#endregion
|
|
1467
1486
|
//#region src/components/datePicker/datePickerContent/index.tsx
|
|
1468
|
-
function
|
|
1487
|
+
function Pt(e) {
|
|
1469
1488
|
let { children: t, size: n } = e;
|
|
1470
1489
|
return /* @__PURE__ */ p("div", {
|
|
1471
1490
|
className: `arkynDatePickerContent ${n}`,
|
|
@@ -1474,7 +1493,7 @@ function Mt(e) {
|
|
|
1474
1493
|
}
|
|
1475
1494
|
//#endregion
|
|
1476
1495
|
//#region src/components/datePicker/datePickerOverlay/index.tsx
|
|
1477
|
-
function
|
|
1496
|
+
function Ft(e) {
|
|
1478
1497
|
let { isFocused: t, handleBlur: n } = e;
|
|
1479
1498
|
return t ? /* @__PURE__ */ p("aside", {
|
|
1480
1499
|
className: "arkynDatePickerOverlay",
|
|
@@ -1483,7 +1502,7 @@ function Nt(e) {
|
|
|
1483
1502
|
}
|
|
1484
1503
|
//#endregion
|
|
1485
1504
|
//#region src/components/datePicker/datePickerSpinner/index.tsx
|
|
1486
|
-
function
|
|
1505
|
+
function It(e) {
|
|
1487
1506
|
let { iconSize: t, isLoading: n } = e;
|
|
1488
1507
|
return n ? /* @__PURE__ */ p(R, {
|
|
1489
1508
|
className: "arkynDatePickerSpinner",
|
|
@@ -1493,14 +1512,14 @@ function Pt(e) {
|
|
|
1493
1512
|
}
|
|
1494
1513
|
//#endregion
|
|
1495
1514
|
//#region src/components/datePicker/index.tsx
|
|
1496
|
-
function
|
|
1515
|
+
function Lt(e) {
|
|
1497
1516
|
let t = (e) => String(e).padStart(2, "0");
|
|
1498
1517
|
return `${e.getFullYear()}-${t(e.getMonth() + 1)}-${t(e.getDate())}`;
|
|
1499
1518
|
}
|
|
1500
|
-
function
|
|
1519
|
+
function Rt(e) {
|
|
1501
1520
|
return e.toLocaleDateString("pt-BR");
|
|
1502
1521
|
}
|
|
1503
|
-
function
|
|
1522
|
+
function zt(e) {
|
|
1504
1523
|
let { name: t, className: n = "", placeholder: r = "Selecione uma data...", errorMessage: i, isLoading: a = !1, readOnly: o = !1, id: c, label: d, showAsterisk: f, leftIcon: h, onFocus: g, onBlur: _, disabled: v = !1, prefix: y, size: b = "md", value: x, variant: S = "solid", orientation: C = "vertical", unShowFieldTemplate: w = !1, calendarVariant: T = "complete" } = e, E = e.closeOnSelect ?? e.type === "single", { fieldErrors: D } = Q(), O = l(null), k = l(null), A = s(), j = c || A, M = `${j}-calendar`, N = i || D?.[t], P = !!N, F = v || a || o, I = {
|
|
1505
1524
|
md: 20,
|
|
1506
1525
|
lg: 20
|
|
@@ -1527,8 +1546,8 @@ function Lt(e) {
|
|
|
1527
1546
|
x === void 0 && V(t), e.type === "range" && e.onChange?.(t), E && U();
|
|
1528
1547
|
}
|
|
1529
1548
|
if (e.type === "range") {
|
|
1530
|
-
let i = e.rangeSeparator ?? " até ", s = x === void 0 ? B : x, c = s ? JSON.stringify([
|
|
1531
|
-
return /* @__PURE__ */ p(
|
|
1549
|
+
let i = e.rangeSeparator ?? " até ", s = x === void 0 ? B : x, c = s ? JSON.stringify([Lt(s[0]), Lt(s[1])]) : "";
|
|
1550
|
+
return /* @__PURE__ */ p(et, {
|
|
1532
1551
|
name: t,
|
|
1533
1552
|
label: d,
|
|
1534
1553
|
showAsterisk: f,
|
|
@@ -1536,7 +1555,7 @@ function Lt(e) {
|
|
|
1536
1555
|
errorMessage: N,
|
|
1537
1556
|
unShowFieldTemplate: w,
|
|
1538
1557
|
orientation: C,
|
|
1539
|
-
children: /* @__PURE__ */ m(
|
|
1558
|
+
children: /* @__PURE__ */ m(Nt, {
|
|
1540
1559
|
handleContainerFocus: H,
|
|
1541
1560
|
disabled: F,
|
|
1542
1561
|
isError: P,
|
|
@@ -1567,21 +1586,21 @@ function Lt(e) {
|
|
|
1567
1586
|
size: I,
|
|
1568
1587
|
strokeWidth: 2.5
|
|
1569
1588
|
}),
|
|
1570
|
-
/* @__PURE__ */ p(
|
|
1589
|
+
/* @__PURE__ */ p(Pt, {
|
|
1571
1590
|
size: b,
|
|
1572
1591
|
children: s ? /* @__PURE__ */ m("p", {
|
|
1573
1592
|
className: "hasValue",
|
|
1574
1593
|
children: [
|
|
1575
|
-
|
|
1594
|
+
Rt(s[0]),
|
|
1576
1595
|
i,
|
|
1577
|
-
|
|
1596
|
+
Rt(s[1])
|
|
1578
1597
|
]
|
|
1579
1598
|
}) : /* @__PURE__ */ p("p", { children: r })
|
|
1580
1599
|
}),
|
|
1581
|
-
/* @__PURE__ */ p(
|
|
1600
|
+
/* @__PURE__ */ p(jt, {
|
|
1582
1601
|
id: M,
|
|
1583
1602
|
isFocused: L,
|
|
1584
|
-
children: /* @__PURE__ */ p(
|
|
1603
|
+
children: /* @__PURE__ */ p(vt, {
|
|
1585
1604
|
type: "range",
|
|
1586
1605
|
variant: T,
|
|
1587
1606
|
value: s,
|
|
@@ -1591,18 +1610,18 @@ function Lt(e) {
|
|
|
1591
1610
|
onChangeView: e.onChangeView
|
|
1592
1611
|
})
|
|
1593
1612
|
}),
|
|
1594
|
-
/* @__PURE__ */ p(
|
|
1613
|
+
/* @__PURE__ */ p(Mt, {
|
|
1595
1614
|
disabled: F,
|
|
1596
1615
|
isFocused: L,
|
|
1597
1616
|
readOnly: o,
|
|
1598
1617
|
iconSize: I,
|
|
1599
1618
|
isLoading: a
|
|
1600
1619
|
}),
|
|
1601
|
-
/* @__PURE__ */ p(
|
|
1620
|
+
/* @__PURE__ */ p(It, {
|
|
1602
1621
|
iconSize: I,
|
|
1603
1622
|
isLoading: a
|
|
1604
1623
|
}),
|
|
1605
|
-
/* @__PURE__ */ p(
|
|
1624
|
+
/* @__PURE__ */ p(Ft, {
|
|
1606
1625
|
handleBlur: U,
|
|
1607
1626
|
isFocused: L
|
|
1608
1627
|
})
|
|
@@ -1610,8 +1629,8 @@ function Lt(e) {
|
|
|
1610
1629
|
})
|
|
1611
1630
|
});
|
|
1612
1631
|
}
|
|
1613
|
-
let K = x === void 0 ? ee : x, q = K ?
|
|
1614
|
-
return /* @__PURE__ */ p(
|
|
1632
|
+
let K = x === void 0 ? ee : x, q = K ? Lt(K) : "";
|
|
1633
|
+
return /* @__PURE__ */ p(et, {
|
|
1615
1634
|
name: t,
|
|
1616
1635
|
label: d,
|
|
1617
1636
|
showAsterisk: f,
|
|
@@ -1619,7 +1638,7 @@ function Lt(e) {
|
|
|
1619
1638
|
errorMessage: N,
|
|
1620
1639
|
unShowFieldTemplate: w,
|
|
1621
1640
|
orientation: C,
|
|
1622
|
-
children: /* @__PURE__ */ m(
|
|
1641
|
+
children: /* @__PURE__ */ m(Nt, {
|
|
1623
1642
|
handleContainerFocus: H,
|
|
1624
1643
|
disabled: F,
|
|
1625
1644
|
isError: P,
|
|
@@ -1650,17 +1669,17 @@ function Lt(e) {
|
|
|
1650
1669
|
size: I,
|
|
1651
1670
|
strokeWidth: 2.5
|
|
1652
1671
|
}),
|
|
1653
|
-
/* @__PURE__ */ p(
|
|
1672
|
+
/* @__PURE__ */ p(Pt, {
|
|
1654
1673
|
size: b,
|
|
1655
1674
|
children: K ? /* @__PURE__ */ p("p", {
|
|
1656
1675
|
className: "hasValue",
|
|
1657
|
-
children:
|
|
1676
|
+
children: Rt(K)
|
|
1658
1677
|
}) : /* @__PURE__ */ p("p", { children: r })
|
|
1659
1678
|
}),
|
|
1660
|
-
/* @__PURE__ */ p(
|
|
1679
|
+
/* @__PURE__ */ p(jt, {
|
|
1661
1680
|
id: M,
|
|
1662
1681
|
isFocused: L,
|
|
1663
|
-
children: /* @__PURE__ */ p(
|
|
1682
|
+
children: /* @__PURE__ */ p(vt, {
|
|
1664
1683
|
type: "single",
|
|
1665
1684
|
variant: T,
|
|
1666
1685
|
value: K,
|
|
@@ -1670,18 +1689,18 @@ function Lt(e) {
|
|
|
1670
1689
|
onChangeView: e.onChangeView
|
|
1671
1690
|
})
|
|
1672
1691
|
}),
|
|
1673
|
-
/* @__PURE__ */ p(
|
|
1692
|
+
/* @__PURE__ */ p(Mt, {
|
|
1674
1693
|
disabled: F,
|
|
1675
1694
|
isFocused: L,
|
|
1676
1695
|
readOnly: o,
|
|
1677
1696
|
iconSize: I,
|
|
1678
1697
|
isLoading: a
|
|
1679
1698
|
}),
|
|
1680
|
-
/* @__PURE__ */ p(
|
|
1699
|
+
/* @__PURE__ */ p(It, {
|
|
1681
1700
|
iconSize: I,
|
|
1682
1701
|
isLoading: a
|
|
1683
1702
|
}),
|
|
1684
|
-
/* @__PURE__ */ p(
|
|
1703
|
+
/* @__PURE__ */ p(Ft, {
|
|
1685
1704
|
handleBlur: U,
|
|
1686
1705
|
isFocused: L
|
|
1687
1706
|
})
|
|
@@ -1691,7 +1710,7 @@ function Lt(e) {
|
|
|
1691
1710
|
}
|
|
1692
1711
|
//#endregion
|
|
1693
1712
|
//#region src/hooks/useEscapeKey.ts
|
|
1694
|
-
function
|
|
1713
|
+
function Bt(e, t) {
|
|
1695
1714
|
let n = l(t);
|
|
1696
1715
|
n.current = t, o(() => {
|
|
1697
1716
|
if (!e) return;
|
|
@@ -1705,7 +1724,7 @@ function Rt(e, t) {
|
|
|
1705
1724
|
}
|
|
1706
1725
|
//#endregion
|
|
1707
1726
|
//#region src/hooks/useFocusTrap.ts
|
|
1708
|
-
var
|
|
1727
|
+
var Vt = [
|
|
1709
1728
|
"a[href]",
|
|
1710
1729
|
"area[href]",
|
|
1711
1730
|
"button:not([disabled])",
|
|
@@ -1715,10 +1734,10 @@ var zt = [
|
|
|
1715
1734
|
"iframe",
|
|
1716
1735
|
"[tabindex]:not([tabindex='-1'])"
|
|
1717
1736
|
].join(", ");
|
|
1718
|
-
function
|
|
1719
|
-
return Array.from(e.querySelectorAll(
|
|
1737
|
+
function Ht(e) {
|
|
1738
|
+
return Array.from(e.querySelectorAll(Vt));
|
|
1720
1739
|
}
|
|
1721
|
-
function
|
|
1740
|
+
function Ut(e, t) {
|
|
1722
1741
|
let n = l(null);
|
|
1723
1742
|
o(() => {
|
|
1724
1743
|
if (!e) return;
|
|
@@ -1726,11 +1745,11 @@ function Vt(e, t) {
|
|
|
1726
1745
|
if (!r) return;
|
|
1727
1746
|
let i = r;
|
|
1728
1747
|
n.current = document.activeElement;
|
|
1729
|
-
let [a] =
|
|
1748
|
+
let [a] = Ht(i);
|
|
1730
1749
|
(a ?? i).focus();
|
|
1731
1750
|
function o(e) {
|
|
1732
1751
|
if (e.key !== "Tab") return;
|
|
1733
|
-
let t =
|
|
1752
|
+
let t = Ht(i);
|
|
1734
1753
|
if (t.length === 0) {
|
|
1735
1754
|
e.preventDefault(), i.focus();
|
|
1736
1755
|
return;
|
|
@@ -1745,30 +1764,30 @@ function Vt(e, t) {
|
|
|
1745
1764
|
}
|
|
1746
1765
|
//#endregion
|
|
1747
1766
|
//#region src/components/drawer/drawerContext.tsx
|
|
1748
|
-
var
|
|
1749
|
-
function
|
|
1767
|
+
var Wt = n({});
|
|
1768
|
+
function Gt(e) {
|
|
1750
1769
|
let t = c(() => ({ makeInvisible: e.makeInvisible }), [e.makeInvisible]);
|
|
1751
|
-
return /* @__PURE__ */ p(
|
|
1770
|
+
return /* @__PURE__ */ p(Wt.Provider, {
|
|
1752
1771
|
value: t,
|
|
1753
1772
|
children: e.children
|
|
1754
1773
|
});
|
|
1755
1774
|
}
|
|
1756
|
-
function
|
|
1757
|
-
return a(
|
|
1775
|
+
function Kt() {
|
|
1776
|
+
return a(Wt);
|
|
1758
1777
|
}
|
|
1759
1778
|
//#endregion
|
|
1760
1779
|
//#region src/components/drawer/drawerContainer/index.tsx
|
|
1761
|
-
function
|
|
1780
|
+
function qt(e) {
|
|
1762
1781
|
let { isVisible: t, makeInvisible: n, orientation: r = "left", children: i, className: a, ...s } = e, [c, d] = u(t), [f, h] = u(!1), g = l(null);
|
|
1763
1782
|
o(() => {
|
|
1764
1783
|
t ? (d(!0), h(!1)) : c && h(!0);
|
|
1765
|
-
}, [t, c]),
|
|
1784
|
+
}, [t, c]), st(t);
|
|
1766
1785
|
let _ = c && !f;
|
|
1767
|
-
|
|
1786
|
+
Bt(_, () => h(!0)), Ut(_, g);
|
|
1768
1787
|
function v(e) {
|
|
1769
1788
|
e.target === e.currentTarget && f && (h(!1), d(!1), n());
|
|
1770
1789
|
}
|
|
1771
|
-
return c ? /* @__PURE__ */ p(
|
|
1790
|
+
return c ? /* @__PURE__ */ p(Gt, {
|
|
1772
1791
|
makeInvisible: () => h(!0),
|
|
1773
1792
|
children: /* @__PURE__ */ m("aside", {
|
|
1774
1793
|
className: [
|
|
@@ -1795,8 +1814,8 @@ function Gt(e) {
|
|
|
1795
1814
|
}
|
|
1796
1815
|
//#endregion
|
|
1797
1816
|
//#region src/components/drawer/drawerHeader/index.tsx
|
|
1798
|
-
function
|
|
1799
|
-
let { showCloseButton: t = !0, className: n, children: r, ...i } = e, { makeInvisible: a } =
|
|
1817
|
+
function Jt(e) {
|
|
1818
|
+
let { showCloseButton: t = !0, className: n, children: r, ...i } = e, { makeInvisible: a } = Kt();
|
|
1800
1819
|
return /* @__PURE__ */ m("header", {
|
|
1801
1820
|
className: `arkynDrawerHeader ${n}`.trim(),
|
|
1802
1821
|
...i,
|
|
@@ -1811,7 +1830,7 @@ function Kt(e) {
|
|
|
1811
1830
|
}
|
|
1812
1831
|
//#endregion
|
|
1813
1832
|
//#region src/components/facebookPixel/pixel.ts
|
|
1814
|
-
var
|
|
1833
|
+
var Yt = class {
|
|
1815
1834
|
pixelId;
|
|
1816
1835
|
autoConfig;
|
|
1817
1836
|
initialized;
|
|
@@ -1858,18 +1877,18 @@ var qt = class {
|
|
|
1858
1877
|
};
|
|
1859
1878
|
//#endregion
|
|
1860
1879
|
//#region src/components/facebookPixel/facebookPixel.client.tsx
|
|
1861
|
-
function
|
|
1862
|
-
let { pixelId: t, options: n, pageView: r, track: i, trackCustom: a, trackSingle: o, trackSingleCustom: s, grantConsent: c, revokeConsent: l } = e, u = new
|
|
1880
|
+
function Xt(e) {
|
|
1881
|
+
let { pixelId: t, options: n, pageView: r, track: i, trackCustom: a, trackSingle: o, trackSingleCustom: s, grantConsent: c, revokeConsent: l } = e, u = new Yt(t, n);
|
|
1863
1882
|
return u.init(), r && u.pageView(), c && u.grantConsent(), l && u.revokeConsent(), i && u.track(...i), a && u.trackCustom(...a), o && u.trackSingle(t, ...o), s && u.trackSingleCustom(t, ...s), null;
|
|
1864
1883
|
}
|
|
1865
1884
|
//#endregion
|
|
1866
1885
|
//#region src/components/facebookPixel/index.tsx
|
|
1867
|
-
function
|
|
1868
|
-
return process.env.NODE_ENV !== "production" && !e.showInDevMode ? null : /* @__PURE__ */ p(
|
|
1886
|
+
function Zt(e) {
|
|
1887
|
+
return process.env.NODE_ENV !== "production" && !e.showInDevMode ? null : /* @__PURE__ */ p(Dt, { children: () => /* @__PURE__ */ p(Xt, { ...e }) });
|
|
1869
1888
|
}
|
|
1870
1889
|
//#endregion
|
|
1871
1890
|
//#region src/components/fileUpload/hasFileContent/index.tsx
|
|
1872
|
-
function
|
|
1891
|
+
function Qt(e) {
|
|
1873
1892
|
let { disabled: t, file: n, isLoading: r, acceptFile: i, changeFileButtonText: a, handleSelectFile: o, reSendFile: s } = e;
|
|
1874
1893
|
function c() {
|
|
1875
1894
|
if (t) return;
|
|
@@ -1921,7 +1940,7 @@ function Xt(e) {
|
|
|
1921
1940
|
}
|
|
1922
1941
|
//#endregion
|
|
1923
1942
|
//#region src/components/fileUpload/noFileContent/index.tsx
|
|
1924
|
-
function
|
|
1943
|
+
function $t(e) {
|
|
1925
1944
|
let { dropFileText: t, isLoading: n, acceptFile: r, handleSelectFile: i, selectFileButtonText: a, disabled: o } = e;
|
|
1926
1945
|
function s(e) {
|
|
1927
1946
|
if (o) return;
|
|
@@ -1953,7 +1972,7 @@ function Zt(e) {
|
|
|
1953
1972
|
}
|
|
1954
1973
|
//#endregion
|
|
1955
1974
|
//#region src/components/fileUpload/index.tsx
|
|
1956
|
-
function
|
|
1975
|
+
function en(e) {
|
|
1957
1976
|
let { name: t, label: n, showAsterisk: r = !1, action: i, fileName: a = "file", method: o = "POST", acceptFile: s = "*", fileResponseName: c = "url", changeFileButtonText: l = "Alterar arquivo", selectFileButtonText: d = "Selecionar arquivo", dropFileText: f = "Ou arraste e solte o arquivo aqui", onChange: h, disabled: g = !1 } = e, { fieldErrors: _ } = Q(), v = _?.[t], [y, b] = u(""), [x, S] = u(""), [C, w] = u(null), [T, E] = u(!1);
|
|
1958
1977
|
async function D(e) {
|
|
1959
1978
|
if (g) return;
|
|
@@ -1985,7 +2004,7 @@ function Qt(e) {
|
|
|
1985
2004
|
name: t,
|
|
1986
2005
|
value: y || ""
|
|
1987
2006
|
}),
|
|
1988
|
-
!C && /* @__PURE__ */ p(
|
|
2007
|
+
!C && /* @__PURE__ */ p($t, {
|
|
1989
2008
|
disabled: g,
|
|
1990
2009
|
isLoading: T,
|
|
1991
2010
|
acceptFile: s,
|
|
@@ -1993,7 +2012,7 @@ function Qt(e) {
|
|
|
1993
2012
|
handleSelectFile: O,
|
|
1994
2013
|
selectFileButtonText: d
|
|
1995
2014
|
}),
|
|
1996
|
-
C && /* @__PURE__ */ p(
|
|
2015
|
+
C && /* @__PURE__ */ p(Qt, {
|
|
1997
2016
|
disabled: g,
|
|
1998
2017
|
isLoading: T,
|
|
1999
2018
|
acceptFile: s,
|
|
@@ -2009,7 +2028,7 @@ function Qt(e) {
|
|
|
2009
2028
|
}
|
|
2010
2029
|
//#endregion
|
|
2011
2030
|
//#region src/components/fullCalendar/_viewService.ts
|
|
2012
|
-
var
|
|
2031
|
+
var tn = class {
|
|
2013
2032
|
capitalize(e) {
|
|
2014
2033
|
return J(e);
|
|
2015
2034
|
}
|
|
@@ -2105,16 +2124,16 @@ var $t = class {
|
|
|
2105
2124
|
let n = new Date(e);
|
|
2106
2125
|
n.setDate(n.getDate() - 1), t(n);
|
|
2107
2126
|
}
|
|
2108
|
-
},
|
|
2109
|
-
function
|
|
2110
|
-
return a(
|
|
2127
|
+
}, nn = n({});
|
|
2128
|
+
function rn() {
|
|
2129
|
+
return a(nn);
|
|
2111
2130
|
}
|
|
2112
|
-
function
|
|
2113
|
-
let { blockedTimestamps: t, children: n, events: r, defaultViewValue: i = /* @__PURE__ */ new Date(), language: a = "pt-BR", onChangeView: o, onClickDate: s, viewValue: c } = e, l = new
|
|
2131
|
+
function an(e) {
|
|
2132
|
+
let { blockedTimestamps: t, children: n, events: r, defaultViewValue: i = /* @__PURE__ */ new Date(), language: a = "pt-BR", onChangeView: o, onClickDate: s, viewValue: c } = e, l = new tn(), d = l.listHours([8, 18]), [f, m] = u(i), h = c || f;
|
|
2114
2133
|
function g(e) {
|
|
2115
2134
|
o && o(e), m(e);
|
|
2116
2135
|
}
|
|
2117
|
-
return /* @__PURE__ */ p(
|
|
2136
|
+
return /* @__PURE__ */ p(nn.Provider, {
|
|
2118
2137
|
value: {
|
|
2119
2138
|
events: r,
|
|
2120
2139
|
blockedTimestamps: t,
|
|
@@ -2136,7 +2155,7 @@ function nn(e) {
|
|
|
2136
2155
|
}
|
|
2137
2156
|
//#endregion
|
|
2138
2157
|
//#region src/components/fullCalendar/dayCalendar/dayCalendarContainer/index.tsx
|
|
2139
|
-
function
|
|
2158
|
+
function on({ children: e }) {
|
|
2140
2159
|
return /* @__PURE__ */ p("div", {
|
|
2141
2160
|
className: "arkynDayCalendarContainer",
|
|
2142
2161
|
children: e
|
|
@@ -2144,15 +2163,15 @@ function rn({ children: e }) {
|
|
|
2144
2163
|
}
|
|
2145
2164
|
//#endregion
|
|
2146
2165
|
//#region src/components/fullCalendar/dayCalendar/dayCalendarEvent/index.tsx
|
|
2147
|
-
var
|
|
2148
|
-
function
|
|
2149
|
-
let { events: t, viewDate: n } =
|
|
2166
|
+
var sn = 30, cn = 205;
|
|
2167
|
+
function ln(e) {
|
|
2168
|
+
let { events: t, viewDate: n } = rn(), r = n.getDate(), i = n.getMonth(), a = n.getFullYear(), o = t.map((e, t) => ({
|
|
2150
2169
|
event: e,
|
|
2151
2170
|
sourceIndex: t
|
|
2152
2171
|
})).filter(({ event: e }) => e.initialDate.getDate() === r && e.initialDate.getMonth() === i && e.initialDate.getFullYear() === a).sort((e, t) => {
|
|
2153
2172
|
let n = e.event.initialDate.getTime(), r = t.event.initialDate.getTime();
|
|
2154
2173
|
if (n !== r) return n - r;
|
|
2155
|
-
let i = e.event.endDate?.getTime() ?? n +
|
|
2174
|
+
let i = e.event.endDate?.getTime() ?? n + sn * 6e4, a = t.event.endDate?.getTime() ?? r + sn * 6e4;
|
|
2156
2175
|
return i === a ? e.sourceIndex - t.sourceIndex : i - a;
|
|
2157
2176
|
}), s = new Map(o.map((e, t) => [e.sourceIndex, t])), c = o.filter(({ event: t }) => {
|
|
2158
2177
|
let n = Math.floor(e.timeInMinutes / 60), o = e.timeInMinutes % 60;
|
|
@@ -2173,7 +2192,7 @@ function sn(e) {
|
|
|
2173
2192
|
return n === 0 ? `${t}h` : `${t}h${n}`;
|
|
2174
2193
|
}
|
|
2175
2194
|
function d(e) {
|
|
2176
|
-
let t = e.initialDate.getHours() * 60 + e.initialDate.getMinutes(), n = e.endDate ? e.endDate.getHours() * 60 + e.endDate.getMinutes() : t +
|
|
2195
|
+
let t = e.initialDate.getHours() * 60 + e.initialDate.getMinutes(), n = e.endDate ? e.endDate.getHours() * 60 + e.endDate.getMinutes() : t + sn;
|
|
2177
2196
|
return {
|
|
2178
2197
|
startMinutes: t,
|
|
2179
2198
|
endMinutes: Math.max(n, t + 1)
|
|
@@ -2188,7 +2207,7 @@ function sn(e) {
|
|
|
2188
2207
|
}, 0);
|
|
2189
2208
|
}
|
|
2190
2209
|
function h(t, n) {
|
|
2191
|
-
let { startMinutes: r, endMinutes: i } = d(t), a = r - e.timeInMinutes, o = Math.max(i - r, 1), s = a /
|
|
2210
|
+
let { startMinutes: r, endMinutes: i } = d(t), a = r - e.timeInMinutes, o = Math.max(i - r, 1), s = a / sn * 100, c = o / sn * 100, l = f(t, n) * cn;
|
|
2192
2211
|
return {
|
|
2193
2212
|
top: `${s}%`,
|
|
2194
2213
|
height: `${c}%`,
|
|
@@ -2211,8 +2230,8 @@ function sn(e) {
|
|
|
2211
2230
|
}
|
|
2212
2231
|
//#endregion
|
|
2213
2232
|
//#region src/components/fullCalendar/dayCalendar/dayCalendarRow/index.tsx
|
|
2214
|
-
function
|
|
2215
|
-
let n = new
|
|
2233
|
+
function un({ hour: e, timeInMinutes: t }) {
|
|
2234
|
+
let n = new tn(), { blockedTimestamps: r, viewDate: i, onClickDate: a } = rn();
|
|
2216
2235
|
function o() {
|
|
2217
2236
|
return r.some((e) => i >= e.initialDate && i <= e.endDate);
|
|
2218
2237
|
}
|
|
@@ -2228,22 +2247,22 @@ function cn({ hour: e, timeInMinutes: t }) {
|
|
|
2228
2247
|
onClick: s,
|
|
2229
2248
|
children: [/* @__PURE__ */ p("p", { children: n.formatHourLabel(e) }), /* @__PURE__ */ p("div", {
|
|
2230
2249
|
className: "arkynDayCalendarRowContent",
|
|
2231
|
-
children: /* @__PURE__ */ p(
|
|
2250
|
+
children: /* @__PURE__ */ p(ln, { timeInMinutes: t })
|
|
2232
2251
|
})]
|
|
2233
2252
|
});
|
|
2234
2253
|
}
|
|
2235
2254
|
//#endregion
|
|
2236
2255
|
//#region src/components/fullCalendar/dayCalendar/index.tsx
|
|
2237
|
-
function
|
|
2238
|
-
let { listHours: e } =
|
|
2239
|
-
return /* @__PURE__ */ p(
|
|
2256
|
+
function dn() {
|
|
2257
|
+
let { listHours: e } = rn();
|
|
2258
|
+
return /* @__PURE__ */ p(on, { children: e.map((e) => /* @__PURE__ */ p(un, {
|
|
2240
2259
|
hour: e,
|
|
2241
2260
|
timeInMinutes: e
|
|
2242
2261
|
}, e)) });
|
|
2243
2262
|
}
|
|
2244
2263
|
//#endregion
|
|
2245
2264
|
//#region src/components/fullCalendar/fullCalendarContainer/index.tsx
|
|
2246
|
-
function
|
|
2265
|
+
function fn({ children: e }) {
|
|
2247
2266
|
return /* @__PURE__ */ p("div", {
|
|
2248
2267
|
className: "arkynFullCalendarContainer",
|
|
2249
2268
|
children: e
|
|
@@ -2251,8 +2270,8 @@ function un({ children: e }) {
|
|
|
2251
2270
|
}
|
|
2252
2271
|
//#endregion
|
|
2253
2272
|
//#region src/components/fullCalendar/fullCalendarHeader/index.tsx
|
|
2254
|
-
function
|
|
2255
|
-
let { setViewType: t, viewType: n } = e, r =
|
|
2273
|
+
function pn(e) {
|
|
2274
|
+
let { setViewType: t, viewType: n } = e, r = rn();
|
|
2256
2275
|
function i() {
|
|
2257
2276
|
switch (n) {
|
|
2258
2277
|
case "day": return r.previousDay();
|
|
@@ -2269,19 +2288,19 @@ function dn(e) {
|
|
|
2269
2288
|
}
|
|
2270
2289
|
return /* @__PURE__ */ m("div", {
|
|
2271
2290
|
className: "arkynFullCalendarHeader",
|
|
2272
|
-
children: [/* @__PURE__ */ m(
|
|
2291
|
+
children: [/* @__PURE__ */ m(Ct, {
|
|
2273
2292
|
defaultValue: n,
|
|
2274
2293
|
onChange: (e) => t(e),
|
|
2275
2294
|
children: [
|
|
2276
|
-
/* @__PURE__ */ p(
|
|
2295
|
+
/* @__PURE__ */ p(St, {
|
|
2277
2296
|
value: "day",
|
|
2278
2297
|
children: "Dia"
|
|
2279
2298
|
}),
|
|
2280
|
-
/* @__PURE__ */ p(
|
|
2299
|
+
/* @__PURE__ */ p(St, {
|
|
2281
2300
|
value: "week",
|
|
2282
2301
|
children: "Semana"
|
|
2283
2302
|
}),
|
|
2284
|
-
/* @__PURE__ */ p(
|
|
2303
|
+
/* @__PURE__ */ p(St, {
|
|
2285
2304
|
value: "month",
|
|
2286
2305
|
children: "Mês"
|
|
2287
2306
|
})
|
|
@@ -2312,8 +2331,8 @@ function dn(e) {
|
|
|
2312
2331
|
}
|
|
2313
2332
|
//#endregion
|
|
2314
2333
|
//#region src/components/fullCalendar/monthlyCalendar/monthlyCalendarEvent/index.tsx
|
|
2315
|
-
function
|
|
2316
|
-
let { events: t } =
|
|
2334
|
+
function mn(e) {
|
|
2335
|
+
let { events: t } = rn(), n = t.filter((t) => t.initialDate.getDate() === e.day && t.initialDate.getMonth() === e.month && t.initialDate.getFullYear() === e.year);
|
|
2317
2336
|
if (n.length === 0) return null;
|
|
2318
2337
|
function r(t) {
|
|
2319
2338
|
return `${e.day}-${e.month}-${e.year}-${t}`;
|
|
@@ -2337,8 +2356,8 @@ function fn(e) {
|
|
|
2337
2356
|
}
|
|
2338
2357
|
//#endregion
|
|
2339
2358
|
//#region src/components/fullCalendar/monthlyCalendar/monthlyCalendarTableTd/index.tsx
|
|
2340
|
-
function
|
|
2341
|
-
let { day: t, month: n, year: r, dayOwner: i } = e, { blockedTimestamps: a, onClickDate: o } =
|
|
2359
|
+
function hn(e) {
|
|
2360
|
+
let { day: t, month: n, year: r, dayOwner: i } = e, { blockedTimestamps: a, onClickDate: o } = rn();
|
|
2342
2361
|
function s() {
|
|
2343
2362
|
let e = /* @__PURE__ */ new Date();
|
|
2344
2363
|
return t === e.getDate() && n === e.getMonth() && r === e.getFullYear();
|
|
@@ -2358,7 +2377,7 @@ function pn(e) {
|
|
|
2358
2377
|
children: t
|
|
2359
2378
|
}), /* @__PURE__ */ p("div", {
|
|
2360
2379
|
className: "arkynMonthlyCalendarEventContainer",
|
|
2361
|
-
children: /* @__PURE__ */ p(
|
|
2380
|
+
children: /* @__PURE__ */ p(mn, {
|
|
2362
2381
|
day: t,
|
|
2363
2382
|
month: n,
|
|
2364
2383
|
year: r
|
|
@@ -2368,15 +2387,15 @@ function pn(e) {
|
|
|
2368
2387
|
}
|
|
2369
2388
|
//#endregion
|
|
2370
2389
|
//#region src/components/fullCalendar/monthlyCalendar/monthlyCalendarTableBody/index.tsx
|
|
2371
|
-
function
|
|
2390
|
+
function gn() {
|
|
2372
2391
|
return /* @__PURE__ */ p("tbody", {
|
|
2373
2392
|
className: "arkynMonthlyCalendarTableBody",
|
|
2374
|
-
children:
|
|
2393
|
+
children: rn().listMonthlyMatrix.map((e, t) => /* @__PURE__ */ p("tr", { children: e.map((e, t) => /* @__PURE__ */ p(hn, { ...e }, t)) }, t))
|
|
2375
2394
|
});
|
|
2376
2395
|
}
|
|
2377
2396
|
//#endregion
|
|
2378
2397
|
//#region src/components/fullCalendar/monthlyCalendar/monthlyCalendarTableContainer/index.tsx
|
|
2379
|
-
function
|
|
2398
|
+
function _n({ children: e }) {
|
|
2380
2399
|
return /* @__PURE__ */ p("div", {
|
|
2381
2400
|
className: "arkynMonthlyCalendarTableContainer",
|
|
2382
2401
|
children: /* @__PURE__ */ p("table", { children: e })
|
|
@@ -2384,8 +2403,8 @@ function hn({ children: e }) {
|
|
|
2384
2403
|
}
|
|
2385
2404
|
//#endregion
|
|
2386
2405
|
//#region src/components/fullCalendar/monthlyCalendar/monthlyCalendarTableHeader/index.tsx
|
|
2387
|
-
function
|
|
2388
|
-
let { listWeek: e } =
|
|
2406
|
+
function vn() {
|
|
2407
|
+
let { listWeek: e } = rn();
|
|
2389
2408
|
return /* @__PURE__ */ p("thead", {
|
|
2390
2409
|
className: "arkynMonthlyCalendarTableHeader",
|
|
2391
2410
|
children: /* @__PURE__ */ p("tr", { children: e.map((e) => /* @__PURE__ */ p("th", { children: J(e) }, e)) })
|
|
@@ -2393,20 +2412,20 @@ function gn() {
|
|
|
2393
2412
|
}
|
|
2394
2413
|
//#endregion
|
|
2395
2414
|
//#region src/components/fullCalendar/monthlyCalendar/index.tsx
|
|
2396
|
-
function
|
|
2397
|
-
return /* @__PURE__ */ m(
|
|
2415
|
+
function yn() {
|
|
2416
|
+
return /* @__PURE__ */ m(_n, { children: [/* @__PURE__ */ p(vn, {}), /* @__PURE__ */ p(gn, {})] });
|
|
2398
2417
|
}
|
|
2399
2418
|
//#endregion
|
|
2400
2419
|
//#region src/components/fullCalendar/weekCalendar/weekCalendarEvent/index.tsx
|
|
2401
|
-
var
|
|
2402
|
-
function
|
|
2403
|
-
let { events: t } =
|
|
2420
|
+
var bn = 30, xn = 40;
|
|
2421
|
+
function Sn(e) {
|
|
2422
|
+
let { events: t } = rn(), n = t.map((e, t) => ({
|
|
2404
2423
|
event: e,
|
|
2405
2424
|
sourceIndex: t
|
|
2406
2425
|
})).filter(({ event: t }) => t.initialDate.getDate() === e.day && t.initialDate.getMonth() === e.month && t.initialDate.getFullYear() === e.year).sort((e, t) => {
|
|
2407
2426
|
let n = e.event.initialDate.getTime(), r = t.event.initialDate.getTime();
|
|
2408
2427
|
if (n !== r) return n - r;
|
|
2409
|
-
let i = e.event.endDate?.getTime() ?? n +
|
|
2428
|
+
let i = e.event.endDate?.getTime() ?? n + bn * 6e4, a = t.event.endDate?.getTime() ?? r + bn * 6e4;
|
|
2410
2429
|
return i === a ? e.sourceIndex - t.sourceIndex : i - a;
|
|
2411
2430
|
}), r = new Map(n.map((e, t) => [e.sourceIndex, t])), i = n.filter(({ event: t }) => {
|
|
2412
2431
|
let n = Math.floor(e.timeInMinutes / 60), r = e.timeInMinutes % 60;
|
|
@@ -2427,7 +2446,7 @@ function bn(e) {
|
|
|
2427
2446
|
return n === 0 ? `${t}h` : `${t}h${n}`;
|
|
2428
2447
|
}
|
|
2429
2448
|
function s(e) {
|
|
2430
|
-
let t = e.initialDate.getHours() * 60 + e.initialDate.getMinutes(), n = e.endDate ? e.endDate.getHours() * 60 + e.endDate.getMinutes() : t +
|
|
2449
|
+
let t = e.initialDate.getHours() * 60 + e.initialDate.getMinutes(), n = e.endDate ? e.endDate.getHours() * 60 + e.endDate.getMinutes() : t + bn;
|
|
2431
2450
|
return {
|
|
2432
2451
|
startMinutes: t,
|
|
2433
2452
|
endMinutes: Math.max(n, t + 1)
|
|
@@ -2442,7 +2461,7 @@ function bn(e) {
|
|
|
2442
2461
|
}, 0);
|
|
2443
2462
|
}
|
|
2444
2463
|
function l(t, n) {
|
|
2445
|
-
let { startMinutes: r, endMinutes: i } = s(t), a = r - e.timeInMinutes, o = Math.max(i - r, 1), l = a /
|
|
2464
|
+
let { startMinutes: r, endMinutes: i } = s(t), a = r - e.timeInMinutes, o = Math.max(i - r, 1), l = a / bn * 100, u = o / bn * 100, d = c(t, n) * xn;
|
|
2446
2465
|
return {
|
|
2447
2466
|
top: `${l}%`,
|
|
2448
2467
|
height: `${u}%`,
|
|
@@ -2465,8 +2484,8 @@ function bn(e) {
|
|
|
2465
2484
|
}
|
|
2466
2485
|
//#endregion
|
|
2467
2486
|
//#region src/components/fullCalendar/weekCalendar/weekCalendarTableTd/index.tsx
|
|
2468
|
-
function
|
|
2469
|
-
let { day: t, month: n, year: r, dayOwner: i, timeInMinutes: a } = e, { blockedTimestamps: o, onClickDate: s } =
|
|
2487
|
+
function Cn(e) {
|
|
2488
|
+
let { day: t, month: n, year: r, dayOwner: i, timeInMinutes: a } = e, { blockedTimestamps: o, onClickDate: s } = rn();
|
|
2470
2489
|
function c() {
|
|
2471
2490
|
let e = new Date(r, n, t);
|
|
2472
2491
|
return o.some((t) => e >= t.initialDate && e <= t.endDate);
|
|
@@ -2484,7 +2503,7 @@ function xn(e) {
|
|
|
2484
2503
|
onClick: l,
|
|
2485
2504
|
children: /* @__PURE__ */ p("div", {
|
|
2486
2505
|
className: "arkynWeekCalendarTableTdContent",
|
|
2487
|
-
children: /* @__PURE__ */ p(
|
|
2506
|
+
children: /* @__PURE__ */ p(Sn, {
|
|
2488
2507
|
day: t,
|
|
2489
2508
|
month: n,
|
|
2490
2509
|
year: r,
|
|
@@ -2495,19 +2514,19 @@ function xn(e) {
|
|
|
2495
2514
|
}
|
|
2496
2515
|
//#endregion
|
|
2497
2516
|
//#region src/components/fullCalendar/weekCalendar/weekCalendarTableBody/index.tsx
|
|
2498
|
-
function
|
|
2499
|
-
let e =
|
|
2517
|
+
function wn() {
|
|
2518
|
+
let e = rn(), t = new tn();
|
|
2500
2519
|
return /* @__PURE__ */ p("tbody", {
|
|
2501
2520
|
className: "arkynWeekCalendarTableBody",
|
|
2502
2521
|
children: e.listWeeklyMatrix.map((e) => /* @__PURE__ */ m("tr", { children: [/* @__PURE__ */ p("td", {
|
|
2503
2522
|
className: "hourTd",
|
|
2504
2523
|
children: /* @__PURE__ */ p("p", { children: t.formatHourLabel(e[0].timeInMinutes) })
|
|
2505
|
-
}), e.map((e) => /* @__PURE__ */ p(
|
|
2524
|
+
}), e.map((e) => /* @__PURE__ */ p(Cn, { ...e }, `${e.year}-${e.month}-${e.day}-${e.timeInMinutes}`))] }, e[0].timeInMinutes))
|
|
2506
2525
|
});
|
|
2507
2526
|
}
|
|
2508
2527
|
//#endregion
|
|
2509
2528
|
//#region src/components/fullCalendar/weekCalendar/weekCalendarTableContainer/index.tsx
|
|
2510
|
-
function
|
|
2529
|
+
function Tn({ children: e }) {
|
|
2511
2530
|
return /* @__PURE__ */ p("div", {
|
|
2512
2531
|
className: "arkynWeekCalendarTableContainer",
|
|
2513
2532
|
children: /* @__PURE__ */ p("table", { children: e })
|
|
@@ -2515,8 +2534,8 @@ function Cn({ children: e }) {
|
|
|
2515
2534
|
}
|
|
2516
2535
|
//#endregion
|
|
2517
2536
|
//#region src/components/fullCalendar/weekCalendar/weekCalendarTableHeader/index.tsx
|
|
2518
|
-
function
|
|
2519
|
-
let { listWeek: e, listWeeklyMatrix: t } =
|
|
2537
|
+
function En() {
|
|
2538
|
+
let { listWeek: e, listWeeklyMatrix: t } = rn(), n = t[0] || [];
|
|
2520
2539
|
return /* @__PURE__ */ p("thead", {
|
|
2521
2540
|
className: "arkynWeekCalendarTableHeader",
|
|
2522
2541
|
children: /* @__PURE__ */ m("tr", { children: [/* @__PURE__ */ p("th", {}), e.map((e, t) => /* @__PURE__ */ p("th", { children: /* @__PURE__ */ m("div", {
|
|
@@ -2527,47 +2546,58 @@ function wn() {
|
|
|
2527
2546
|
}
|
|
2528
2547
|
//#endregion
|
|
2529
2548
|
//#region src/components/fullCalendar/weekCalendar/index.tsx
|
|
2530
|
-
function
|
|
2531
|
-
return /* @__PURE__ */ m(
|
|
2549
|
+
function Dn() {
|
|
2550
|
+
return /* @__PURE__ */ m(Tn, { children: [/* @__PURE__ */ p(En, {}), /* @__PURE__ */ p(wn, {})] });
|
|
2532
2551
|
}
|
|
2533
2552
|
//#endregion
|
|
2534
2553
|
//#region src/components/fullCalendar/index.tsx
|
|
2535
|
-
function
|
|
2554
|
+
function On(e) {
|
|
2536
2555
|
let [t, n] = u("month");
|
|
2537
|
-
return /* @__PURE__ */ p(
|
|
2556
|
+
return /* @__PURE__ */ p(an, {
|
|
2538
2557
|
events: e.events || [],
|
|
2539
2558
|
viewValue: e.viewValue,
|
|
2540
2559
|
defaultViewValue: e.defaultViewValue,
|
|
2541
2560
|
onChangeView: e.onChangeView,
|
|
2542
2561
|
blockedTimestamps: e.blockedTimestamps || [],
|
|
2543
2562
|
onClickDate: e.onClickDate,
|
|
2544
|
-
children: /* @__PURE__ */ m(
|
|
2545
|
-
/* @__PURE__ */ p(
|
|
2563
|
+
children: /* @__PURE__ */ m(fn, { children: [
|
|
2564
|
+
/* @__PURE__ */ p(pn, {
|
|
2546
2565
|
viewType: t,
|
|
2547
2566
|
setViewType: n
|
|
2548
2567
|
}),
|
|
2549
|
-
t === "day" && /* @__PURE__ */ p(
|
|
2550
|
-
t === "month" && /* @__PURE__ */ p(
|
|
2551
|
-
t === "week" && /* @__PURE__ */ p(
|
|
2568
|
+
t === "day" && /* @__PURE__ */ p(dn, {}),
|
|
2569
|
+
t === "month" && /* @__PURE__ */ p(yn, {}),
|
|
2570
|
+
t === "week" && /* @__PURE__ */ p(Dn, {})
|
|
2552
2571
|
] })
|
|
2553
2572
|
});
|
|
2554
2573
|
}
|
|
2555
2574
|
//#endregion
|
|
2575
|
+
//#region src/utils/escapeForInlineScript.ts
|
|
2576
|
+
function kn(e) {
|
|
2577
|
+
return JSON.stringify(e ?? "").replace(/</g, "\\u003C");
|
|
2578
|
+
}
|
|
2579
|
+
function An(e) {
|
|
2580
|
+
return JSON.stringify(e).replace(/</g, "\\u003C");
|
|
2581
|
+
}
|
|
2582
|
+
function jn(e) {
|
|
2583
|
+
return /^[A-Za-z_$][A-Za-z0-9_$]*$/.test(e);
|
|
2584
|
+
}
|
|
2585
|
+
//#endregion
|
|
2556
2586
|
//#region src/components/googleAnalytics/snippets/generateGAElements.ts
|
|
2557
|
-
function
|
|
2587
|
+
function Mn(e) {
|
|
2558
2588
|
let { measurementId: t } = e;
|
|
2559
2589
|
return t || console.warn("Google Analytics Measurement ID is required"), {
|
|
2560
|
-
src: `https://www.googletagmanager.com/gtag/js?id=${t}`,
|
|
2590
|
+
src: `https://www.googletagmanager.com/gtag/js?id=${encodeURIComponent(t)}`,
|
|
2561
2591
|
script: `
|
|
2562
2592
|
window.dataLayer = window.dataLayer || [];
|
|
2563
2593
|
function gtag(){dataLayer.push(arguments);}
|
|
2564
2594
|
gtag('js', new Date());
|
|
2565
|
-
gtag('config',
|
|
2595
|
+
gtag('config', ${kn(t)});`
|
|
2566
2596
|
};
|
|
2567
2597
|
}
|
|
2568
2598
|
//#endregion
|
|
2569
2599
|
//#region src/components/googleAnalytics/googleAnalytics.tsx
|
|
2570
|
-
var
|
|
2600
|
+
var Nn = class {
|
|
2571
2601
|
initializeAsyncScript(e) {
|
|
2572
2602
|
let t = document.createElement("script");
|
|
2573
2603
|
return t.async = !0, t.src = e, t;
|
|
@@ -2577,45 +2607,50 @@ var On = class {
|
|
|
2577
2607
|
return t.innerHTML = e, t;
|
|
2578
2608
|
}
|
|
2579
2609
|
initialize(e) {
|
|
2580
|
-
let { measurementId: t } = e, n =
|
|
2610
|
+
let { measurementId: t } = e, n = Mn({ measurementId: t }), r = this.initializeAsyncScript(n.src), i = this.initializeInlineScript(n.script);
|
|
2581
2611
|
document.head.appendChild(r), document.head.appendChild(i);
|
|
2582
2612
|
}
|
|
2583
2613
|
};
|
|
2584
2614
|
//#endregion
|
|
2585
2615
|
//#region src/components/googleAnalytics/googleAnalytics.client.tsx
|
|
2586
|
-
function
|
|
2587
|
-
return new
|
|
2616
|
+
function Pn(e) {
|
|
2617
|
+
return new Nn().initialize(e), null;
|
|
2588
2618
|
}
|
|
2589
2619
|
//#endregion
|
|
2590
2620
|
//#region src/components/googleAnalytics/index.tsx
|
|
2591
|
-
function
|
|
2621
|
+
function Fn(e) {
|
|
2592
2622
|
let { measurementId: t, showInDevMode: n = !1 } = e;
|
|
2593
|
-
return process.env.NODE_ENV !== "production" && !n ? null : /* @__PURE__ */ p(
|
|
2623
|
+
return process.env.NODE_ENV !== "production" && !n ? null : /* @__PURE__ */ p(Dt, { children: () => /* @__PURE__ */ p(Pn, { measurementId: t }) });
|
|
2594
2624
|
}
|
|
2595
2625
|
//#endregion
|
|
2596
2626
|
//#region src/components/googleTagManager/snippets/appendToDataLayer.ts
|
|
2597
|
-
function
|
|
2598
|
-
let { dataLayer: t, dataLayerName: n } = e;
|
|
2599
|
-
return `
|
|
2600
|
-
window.${
|
|
2601
|
-
window.${
|
|
2627
|
+
function In(e) {
|
|
2628
|
+
let { dataLayer: t, dataLayerName: n } = e, r = jn(n) ? n : "dataLayer";
|
|
2629
|
+
return r !== n && console.warn(`Invalid dataLayerName "${n}", falling back to "dataLayer"`), `
|
|
2630
|
+
window.${r} = window.${r} || [];
|
|
2631
|
+
window.${r}.push(${An(t)})`;
|
|
2602
2632
|
}
|
|
2603
2633
|
//#endregion
|
|
2604
2634
|
//#region src/components/googleTagManager/snippets/generateGTMElements.ts
|
|
2605
|
-
function
|
|
2606
|
-
|
|
2607
|
-
|
|
2608
|
-
|
|
2609
|
-
|
|
2610
|
-
|
|
2635
|
+
function Ln(e) {
|
|
2636
|
+
return encodeURIComponent(e).replace(/'/g, "%27");
|
|
2637
|
+
}
|
|
2638
|
+
function Rn(e) {
|
|
2639
|
+
let { id: t, events: n, dataLayer: r, dataLayerName: i, preview: a, auth: o } = e, s = `>m_auth=${Ln(o)}`, c = `>m_preview=${Ln(a)}`, l = Ln(t);
|
|
2640
|
+
t || console.warn("GTM Id is required");
|
|
2641
|
+
let u = `
|
|
2642
|
+
<iframe src="https://www.googletagmanager.com/ns.html?id=${l}${s}${c}>m_cookies_win=x"
|
|
2643
|
+
height="0" width="0" style="display:none;visibility:hidden" id="tag-manager"></iframe>`, d = jn(i) ? i : "dataLayer";
|
|
2644
|
+
return {
|
|
2645
|
+
iframe: u,
|
|
2611
2646
|
script: `
|
|
2612
2647
|
(function(w,d,s,l,i){w[l]=w[l]||[];
|
|
2613
|
-
w[l].push({'gtm.start': new Date().getTime(),event:'gtm.js', ${JSON.stringify(n).slice(1, -1)}});
|
|
2648
|
+
w[l].push({'gtm.start': new Date().getTime(),event:'gtm.js', ${JSON.stringify(n).slice(1, -1).replace(/</g, "\\u003C")}});
|
|
2614
2649
|
var f=d.getElementsByTagName(s)[0],j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';
|
|
2615
2650
|
j.async=true;j.src='https://www.googletagmanager.com/gtm.js?id='+i+dl+'${s}${c}>m_cookies_win=x';
|
|
2616
2651
|
f.parentNode.insertBefore(j,f);
|
|
2617
|
-
})(window,document,'script'
|
|
2618
|
-
dataLayerVar:
|
|
2652
|
+
})(window,document,'script',${kn(d)},${kn(t)});`,
|
|
2653
|
+
dataLayerVar: In({
|
|
2619
2654
|
dataLayer: r,
|
|
2620
2655
|
dataLayerName: i
|
|
2621
2656
|
})
|
|
@@ -2623,13 +2658,13 @@ function Mn(e) {
|
|
|
2623
2658
|
}
|
|
2624
2659
|
//#endregion
|
|
2625
2660
|
//#region src/components/googleTagManager/googleTagManager.tsx
|
|
2626
|
-
var
|
|
2661
|
+
var zn = class {
|
|
2627
2662
|
initializeDataScript(e) {
|
|
2628
2663
|
let t = document.createElement("script");
|
|
2629
2664
|
return t.innerHTML = e, t;
|
|
2630
2665
|
}
|
|
2631
2666
|
initializeGTMElements(e) {
|
|
2632
|
-
let t =
|
|
2667
|
+
let t = Rn(e);
|
|
2633
2668
|
return {
|
|
2634
2669
|
noScript: () => {
|
|
2635
2670
|
let e = document.createElement("noscript");
|
|
@@ -2645,7 +2680,7 @@ var Nn = class {
|
|
|
2645
2680
|
initializeDataLayer(e) {
|
|
2646
2681
|
let { dataLayer: t, dataLayerName: n } = e;
|
|
2647
2682
|
if (window[n]) return window[n].push(t);
|
|
2648
|
-
let r =
|
|
2683
|
+
let r = In({
|
|
2649
2684
|
dataLayer: t,
|
|
2650
2685
|
dataLayerName: n
|
|
2651
2686
|
}), i = this.initializeDataScript(r);
|
|
@@ -2665,14 +2700,14 @@ var Nn = class {
|
|
|
2665
2700
|
};
|
|
2666
2701
|
//#endregion
|
|
2667
2702
|
//#region src/components/googleTagManager/googleTagManager.client.tsx
|
|
2668
|
-
function
|
|
2669
|
-
return new
|
|
2703
|
+
function Bn(e) {
|
|
2704
|
+
return new zn().initialize(e), null;
|
|
2670
2705
|
}
|
|
2671
2706
|
//#endregion
|
|
2672
2707
|
//#region src/components/googleTagManager/index.tsx
|
|
2673
|
-
function
|
|
2708
|
+
function Vn(e) {
|
|
2674
2709
|
let { gtmId: t, auth: n = "", preview: r = "", dataLayerName: i = "dataLayer", events: a = {}, dataLayer: o = {}, showInDevMode: s = !1 } = e;
|
|
2675
|
-
return process.env.NODE_ENV !== "production" && !s ? null : /* @__PURE__ */ p(
|
|
2710
|
+
return process.env.NODE_ENV !== "production" && !s ? null : /* @__PURE__ */ p(Dt, { children: () => /* @__PURE__ */ p(Bn, {
|
|
2676
2711
|
auth: n,
|
|
2677
2712
|
dataLayer: o,
|
|
2678
2713
|
dataLayerName: i,
|
|
@@ -2683,7 +2718,7 @@ function Fn(e) {
|
|
|
2683
2718
|
}
|
|
2684
2719
|
//#endregion
|
|
2685
2720
|
//#region src/components/imageUpload/hasFileContent/index.tsx
|
|
2686
|
-
function
|
|
2721
|
+
function Hn(e) {
|
|
2687
2722
|
let { disabled: t, filePath: n, isLoading: r, acceptImage: i, changeImageButtonText: a, handleSelectFile: o, reSendImage: s } = e;
|
|
2688
2723
|
function c() {
|
|
2689
2724
|
if (t) return;
|
|
@@ -2723,7 +2758,7 @@ function In(e) {
|
|
|
2723
2758
|
}
|
|
2724
2759
|
//#endregion
|
|
2725
2760
|
//#region src/components/imageUpload/noFileContent/index.tsx
|
|
2726
|
-
function
|
|
2761
|
+
function Un(e) {
|
|
2727
2762
|
let { dropImageText: t, isLoading: n, acceptImage: r, handleSelectFile: i, selectImageButtonText: a, disabled: o } = e;
|
|
2728
2763
|
function s(e) {
|
|
2729
2764
|
if (o) return;
|
|
@@ -2755,7 +2790,7 @@ function Ln(e) {
|
|
|
2755
2790
|
}
|
|
2756
2791
|
//#endregion
|
|
2757
2792
|
//#region src/components/imageUpload/index.tsx
|
|
2758
|
-
function
|
|
2793
|
+
function Wn(e) {
|
|
2759
2794
|
let { name: t, defaultValue: n = "", label: r, showAsterisk: i = !1, action: a, fileName: o = "file", className: s = "", method: c = "POST", acceptImage: l = "image/*", fileResponseName: d = "url", changeImageButtonText: f = "Alterar imagem", selectImageButtonText: h = "Selecionar imagem", dropImageText: g = "Ou arraste e solte a imagem aqui", onChange: _, disabled: v = !1, unShowFieldTemplate: y = !1, orientation: b = "vertical" } = e, { fieldErrors: x } = Q(), S = x?.[t], [C, w] = u(n), [T, E] = u(""), [D, O] = u(null), [k, A] = u(n), [j, M] = u(!1);
|
|
2760
2795
|
async function N(e) {
|
|
2761
2796
|
if (v) return;
|
|
@@ -2774,7 +2809,7 @@ function Rn(e) {
|
|
|
2774
2809
|
v || (A(URL.createObjectURL(e)), N(e));
|
|
2775
2810
|
}
|
|
2776
2811
|
let F = S || T;
|
|
2777
|
-
return /* @__PURE__ */ p(
|
|
2812
|
+
return /* @__PURE__ */ p(et, {
|
|
2778
2813
|
name: t,
|
|
2779
2814
|
label: r,
|
|
2780
2815
|
showAsterisk: i,
|
|
@@ -2790,7 +2825,7 @@ function Rn(e) {
|
|
|
2790
2825
|
name: t,
|
|
2791
2826
|
value: C || ""
|
|
2792
2827
|
}),
|
|
2793
|
-
!k && /* @__PURE__ */ p(
|
|
2828
|
+
!k && /* @__PURE__ */ p(Un, {
|
|
2794
2829
|
disabled: v,
|
|
2795
2830
|
isLoading: j,
|
|
2796
2831
|
acceptImage: l,
|
|
@@ -2798,7 +2833,7 @@ function Rn(e) {
|
|
|
2798
2833
|
handleSelectFile: P,
|
|
2799
2834
|
selectImageButtonText: h
|
|
2800
2835
|
}),
|
|
2801
|
-
k && /* @__PURE__ */ p(
|
|
2836
|
+
k && /* @__PURE__ */ p(Hn, {
|
|
2802
2837
|
disabled: v,
|
|
2803
2838
|
isLoading: j,
|
|
2804
2839
|
acceptImage: l,
|
|
@@ -2813,7 +2848,7 @@ function Rn(e) {
|
|
|
2813
2848
|
}
|
|
2814
2849
|
//#endregion
|
|
2815
2850
|
//#region src/components/mapView/mapView.client.tsx
|
|
2816
|
-
function
|
|
2851
|
+
function Gn({ center: e, coordinates: t, onMarkerClick: n, accessToken: r, ...i }) {
|
|
2817
2852
|
let a = l(null), s = l(null), c = e || t[0];
|
|
2818
2853
|
return o(() => (ae.accessToken = r, a.current = new ae.Map({
|
|
2819
2854
|
container: s.current,
|
|
@@ -2863,19 +2898,19 @@ function zn({ center: e, coordinates: t, onMarkerClick: n, accessToken: r, ...i
|
|
|
2863
2898
|
}
|
|
2864
2899
|
//#endregion
|
|
2865
2900
|
//#region src/components/mapView/index.tsx
|
|
2866
|
-
function
|
|
2901
|
+
function Kn({ className: e }) {
|
|
2867
2902
|
return /* @__PURE__ */ p("div", {
|
|
2868
2903
|
className: `arkynMapViewPinnedEmpty ${e}`,
|
|
2869
2904
|
children: /* @__PURE__ */ p(ee, {})
|
|
2870
2905
|
});
|
|
2871
2906
|
}
|
|
2872
|
-
function
|
|
2907
|
+
function qn(e) {
|
|
2873
2908
|
let { coordinates: t, zoom: n = 18, accessToken: r, className: i, onMarkerClick: a, ...o } = e;
|
|
2874
|
-
if (!t) return /* @__PURE__ */ p(
|
|
2909
|
+
if (!t) return /* @__PURE__ */ p(Kn, { className: i });
|
|
2875
2910
|
let s = Array.isArray(t) ? t : [t];
|
|
2876
|
-
return s.length === 0 ? /* @__PURE__ */ p(
|
|
2877
|
-
fallback: /* @__PURE__ */ p(
|
|
2878
|
-
children: () => /* @__PURE__ */ p(
|
|
2911
|
+
return s.length === 0 ? /* @__PURE__ */ p(Kn, { className: i }) : /* @__PURE__ */ p(Dt, {
|
|
2912
|
+
fallback: /* @__PURE__ */ p(Kn, { className: i }),
|
|
2913
|
+
children: () => /* @__PURE__ */ p(Gn, {
|
|
2879
2914
|
accessToken: r,
|
|
2880
2915
|
coordinates: s,
|
|
2881
2916
|
center: s[0],
|
|
@@ -2886,11 +2921,11 @@ function Vn(e) {
|
|
|
2886
2921
|
}
|
|
2887
2922
|
//#endregion
|
|
2888
2923
|
//#region src/components/maskedInput/index.tsx
|
|
2889
|
-
var
|
|
2924
|
+
var Jn = r((e, t) => /* @__PURE__ */ p("input", {
|
|
2890
2925
|
ref: t,
|
|
2891
2926
|
...e
|
|
2892
2927
|
}));
|
|
2893
|
-
function
|
|
2928
|
+
function Yn(e) {
|
|
2894
2929
|
let { name: t, disabled: n, title: r, style: i, variant: a = "solid", separate: o, mask: c, showMask: d, replacement: f, label: h, className: g = "", prefix: _, suffix: v, isLoading: y = !1, leftIcon: b, readOnly: x, onFocus: S, onBlur: C, errorMessage: w, defaultValue: T, showAsterisk: E, rightIcon: D, size: O = "md", id: k, value: A, placeholder: j, ...M } = e, { fieldErrors: N } = Q(), [P, F] = u(!1), I = l(null), L = s(), ee = k || L, z = w || N?.[t], B = !!z, V = n || y, H = {
|
|
2895
2930
|
md: 20,
|
|
2896
2931
|
lg: 20
|
|
@@ -2936,7 +2971,7 @@ function Un(e) {
|
|
|
2936
2971
|
iconSize: H
|
|
2937
2972
|
}),
|
|
2938
2973
|
/* @__PURE__ */ p(Y, {
|
|
2939
|
-
component:
|
|
2974
|
+
component: Jn,
|
|
2940
2975
|
mask: c,
|
|
2941
2976
|
replacement: f,
|
|
2942
2977
|
separate: o,
|
|
@@ -2977,30 +3012,30 @@ function Un(e) {
|
|
|
2977
3012
|
}
|
|
2978
3013
|
//#endregion
|
|
2979
3014
|
//#region src/components/modal/modalContext.tsx
|
|
2980
|
-
var
|
|
2981
|
-
function
|
|
3015
|
+
var Xn = n({});
|
|
3016
|
+
function Zn(e) {
|
|
2982
3017
|
let t = c(() => ({ makeInvisible: e.makeInvisible }), [e.makeInvisible]);
|
|
2983
|
-
return /* @__PURE__ */ p(
|
|
3018
|
+
return /* @__PURE__ */ p(Xn.Provider, {
|
|
2984
3019
|
value: t,
|
|
2985
3020
|
children: e.children
|
|
2986
3021
|
});
|
|
2987
3022
|
}
|
|
2988
|
-
function
|
|
2989
|
-
return a(
|
|
3023
|
+
function Qn() {
|
|
3024
|
+
return a(Xn);
|
|
2990
3025
|
}
|
|
2991
3026
|
//#endregion
|
|
2992
3027
|
//#region src/components/modal/modalContainer/index.tsx
|
|
2993
|
-
function
|
|
3028
|
+
function $n(e) {
|
|
2994
3029
|
let { isVisible: t, makeInvisible: n, children: r, className: i = "", ...a } = e, [s, c] = u(t), [d, f] = u(!1), h = l(null);
|
|
2995
3030
|
o(() => {
|
|
2996
3031
|
t ? (c(!0), f(!1)) : s && f(!0);
|
|
2997
|
-
}, [t, s]),
|
|
3032
|
+
}, [t, s]), st(t);
|
|
2998
3033
|
let g = s && !d;
|
|
2999
|
-
|
|
3034
|
+
Bt(g, () => f(!0)), Ut(g, h);
|
|
3000
3035
|
function _(e) {
|
|
3001
3036
|
e.target === e.currentTarget && d && (f(!1), c(!1), n());
|
|
3002
3037
|
}
|
|
3003
|
-
return s ? /* @__PURE__ */ p(
|
|
3038
|
+
return s ? /* @__PURE__ */ p(Zn, {
|
|
3004
3039
|
makeInvisible: () => f(!0),
|
|
3005
3040
|
children: /* @__PURE__ */ m("aside", {
|
|
3006
3041
|
className: [
|
|
@@ -3026,7 +3061,7 @@ function qn(e) {
|
|
|
3026
3061
|
}
|
|
3027
3062
|
//#endregion
|
|
3028
3063
|
//#region src/components/modal/modalFooter/index.tsx
|
|
3029
|
-
function
|
|
3064
|
+
function er(e) {
|
|
3030
3065
|
let { alignment: t = "right", className: n, ...r } = e;
|
|
3031
3066
|
return /* @__PURE__ */ p("footer", {
|
|
3032
3067
|
className: `arkynModalFooter ${t} ${n}`.trim(),
|
|
@@ -3035,8 +3070,8 @@ function Jn(e) {
|
|
|
3035
3070
|
}
|
|
3036
3071
|
//#endregion
|
|
3037
3072
|
//#region src/components/modal/modalHeader/index.tsx
|
|
3038
|
-
function
|
|
3039
|
-
let { showCloseButton: t = !0, className: n, children: r, ...i } = e, { makeInvisible: a } =
|
|
3073
|
+
function tr(e) {
|
|
3074
|
+
let { showCloseButton: t = !0, className: n, children: r, ...i } = e, { makeInvisible: a } = Qn();
|
|
3040
3075
|
return /* @__PURE__ */ m("header", {
|
|
3041
3076
|
className: `arkynModalHeader ${n}`.trim(),
|
|
3042
3077
|
...i,
|
|
@@ -3051,7 +3086,7 @@ function Yn(e) {
|
|
|
3051
3086
|
}
|
|
3052
3087
|
//#endregion
|
|
3053
3088
|
//#region src/components/multiSelect/multiSelectChevron/index.tsx
|
|
3054
|
-
function
|
|
3089
|
+
function nr(e) {
|
|
3055
3090
|
let { iconSize: t, isLoading: n, disabled: r, readOnly: i, isFocused: a } = e;
|
|
3056
3091
|
return n ? null : /* @__PURE__ */ p(C, {
|
|
3057
3092
|
className: `arkynMultiSelectChevron ${r || i ? "notAnimate" : ""} ${a ? "focused" : ""}`,
|
|
@@ -3066,7 +3101,7 @@ function Xn(e) {
|
|
|
3066
3101
|
}
|
|
3067
3102
|
//#endregion
|
|
3068
3103
|
//#region src/components/multiSelect/multiSelectContainer/index.tsx
|
|
3069
|
-
function
|
|
3104
|
+
function rr(e) {
|
|
3070
3105
|
let { children: t, handleContainerFocus: n, disabled: r, isError: i, isLoading: a, isFocused: o, className: s, readOnly: c, variant: l, size: u, id: d, prefixExists: f, containerRef: m, onContainerKeyDown: h, tabIndex: g, ariaControls: _, ariaActiveDescendant: v } = e;
|
|
3071
3106
|
return /* @__PURE__ */ p("div", {
|
|
3072
3107
|
ref: m,
|
|
@@ -3085,7 +3120,7 @@ function Zn(e) {
|
|
|
3085
3120
|
}
|
|
3086
3121
|
//#endregion
|
|
3087
3122
|
//#region src/components/multiSelect/multiSelectContent/index.tsx
|
|
3088
|
-
function
|
|
3123
|
+
function ir(e) {
|
|
3089
3124
|
let { children: t, size: n } = e;
|
|
3090
3125
|
return /* @__PURE__ */ p("div", {
|
|
3091
3126
|
className: `arkynMultiSelectContent ${n}`,
|
|
@@ -3094,7 +3129,7 @@ function Qn(e) {
|
|
|
3094
3129
|
}
|
|
3095
3130
|
//#endregion
|
|
3096
3131
|
//#region src/components/multiSelect/multiSelectMark/index.tsx
|
|
3097
|
-
function
|
|
3132
|
+
function ar(e) {
|
|
3098
3133
|
let { label: t, value: n, disabled: r, handleChangeValue: i } = e;
|
|
3099
3134
|
return /* @__PURE__ */ m("div", {
|
|
3100
3135
|
className: "arkynMultiSelectMark",
|
|
@@ -3110,7 +3145,7 @@ function $n(e) {
|
|
|
3110
3145
|
}
|
|
3111
3146
|
//#endregion
|
|
3112
3147
|
//#region src/components/multiSelect/multiSelectOption/index.tsx
|
|
3113
|
-
function
|
|
3148
|
+
function or(e) {
|
|
3114
3149
|
let { label: t, optionHasSelected: n, handleChangeValue: r, value: i, size: a, id: o, isHighlighted: s = !1 } = e, c = n(i);
|
|
3115
3150
|
return /* @__PURE__ */ m("button", {
|
|
3116
3151
|
type: "button",
|
|
@@ -3128,39 +3163,31 @@ function er(e) {
|
|
|
3128
3163
|
}
|
|
3129
3164
|
//#endregion
|
|
3130
3165
|
//#region src/components/multiSelect/multiSelectOptionsContainer/index.tsx
|
|
3131
|
-
function
|
|
3132
|
-
let { children: t, id: n, isFocused: r, isSearchable: i, search: a, onSearch:
|
|
3133
|
-
|
|
3134
|
-
|
|
3135
|
-
|
|
3136
|
-
let e = c.current.parentElement;
|
|
3137
|
-
if (!e) return;
|
|
3138
|
-
let t = e.getBoundingClientRect();
|
|
3139
|
-
window.innerHeight - t.bottom < 300 && t.top > 300 ? f("top") : f("bottom");
|
|
3140
|
-
})();
|
|
3141
|
-
}, [r]);
|
|
3142
|
-
function h(e) {
|
|
3143
|
-
i && s(e.target.value);
|
|
3166
|
+
function sr(e) {
|
|
3167
|
+
let { children: t, id: n, isFocused: r, isSearchable: i, search: a, onSearch: o } = e, s = l(null), c = at(s, r, 300);
|
|
3168
|
+
st(r);
|
|
3169
|
+
function u(e) {
|
|
3170
|
+
i && o(e.target.value);
|
|
3144
3171
|
}
|
|
3145
3172
|
return r ? /* @__PURE__ */ m("div", {
|
|
3146
|
-
ref:
|
|
3173
|
+
ref: s,
|
|
3147
3174
|
id: n,
|
|
3148
3175
|
role: "listbox",
|
|
3149
3176
|
"aria-multiselectable": "true",
|
|
3150
|
-
className: `arkynMultiSelectOptionsContainer ${
|
|
3151
|
-
children: [i && /* @__PURE__ */ p(
|
|
3177
|
+
className: `arkynMultiSelectOptionsContainer ${c}`,
|
|
3178
|
+
children: [i && /* @__PURE__ */ p(ct, {
|
|
3152
3179
|
type: "search",
|
|
3153
3180
|
name: "search-select",
|
|
3154
3181
|
variant: "underline",
|
|
3155
3182
|
leftIcon: U,
|
|
3156
3183
|
value: a,
|
|
3157
|
-
onChange:
|
|
3184
|
+
onChange: u
|
|
3158
3185
|
}), t]
|
|
3159
3186
|
}) : null;
|
|
3160
3187
|
}
|
|
3161
3188
|
//#endregion
|
|
3162
3189
|
//#region src/components/multiSelect/multiSelectOverlay/index.tsx
|
|
3163
|
-
function
|
|
3190
|
+
function cr(e) {
|
|
3164
3191
|
let { isFocused: t, handleBlur: n } = e;
|
|
3165
3192
|
return t ? /* @__PURE__ */ p("aside", {
|
|
3166
3193
|
className: "arkynMultiSelectOverlay",
|
|
@@ -3169,7 +3196,7 @@ function nr(e) {
|
|
|
3169
3196
|
}
|
|
3170
3197
|
//#endregion
|
|
3171
3198
|
//#region src/components/multiSelect/multiSelectSpinner/index.tsx
|
|
3172
|
-
function
|
|
3199
|
+
function lr(e) {
|
|
3173
3200
|
let { iconSize: t, isLoading: n } = e;
|
|
3174
3201
|
return n ? /* @__PURE__ */ p(R, {
|
|
3175
3202
|
className: "arkynMultiSelectSpinner",
|
|
@@ -3179,7 +3206,7 @@ function rr(e) {
|
|
|
3179
3206
|
}
|
|
3180
3207
|
//#endregion
|
|
3181
3208
|
//#region src/components/multiSelect/index.tsx
|
|
3182
|
-
function
|
|
3209
|
+
function ur(e) {
|
|
3183
3210
|
let { name: t, options: n, className: r = "", placeholder: i = "Selecione...", closeOnSelect: a = !1, defaultValue: o = [], errorMessage: c, isLoading: d = !1, readOnly: f = !1, isSearchable: h = !1, id: g, label: _, showAsterisk: v, leftIcon: y, onSearch: b, onChange: x, onBlur: S, notFoundText: C = "Sem opções disponíveis", onFocus: w, disabled: T = !1, prefix: E, size: D = "md", value: O, variant: k = "solid", unShowFieldTemplate: A = !1, orientation: j = "vertical" } = e, { fieldErrors: M } = Q(), N = l(null), P = l(null), F = s(), I = g || F, L = `${I}-listbox`, R = c || M?.[t], ee = !!R, z = T || d || f, B = {
|
|
3184
3211
|
md: 20,
|
|
3185
3212
|
lg: 20
|
|
@@ -3235,7 +3262,7 @@ function ir(e) {
|
|
|
3235
3262
|
}
|
|
3236
3263
|
}
|
|
3237
3264
|
let ce = K >= 0 && K < X.length ? ie(X[K].value) : void 0;
|
|
3238
|
-
return /* @__PURE__ */ p(
|
|
3265
|
+
return /* @__PURE__ */ p(et, {
|
|
3239
3266
|
name: t,
|
|
3240
3267
|
label: _,
|
|
3241
3268
|
showAsterisk: v,
|
|
@@ -3243,7 +3270,7 @@ function ir(e) {
|
|
|
3243
3270
|
errorMessage: R,
|
|
3244
3271
|
unShowFieldTemplate: A,
|
|
3245
3272
|
orientation: j,
|
|
3246
|
-
children: /* @__PURE__ */ m(
|
|
3273
|
+
children: /* @__PURE__ */ m(rr, {
|
|
3247
3274
|
handleContainerFocus: ae,
|
|
3248
3275
|
disabled: z,
|
|
3249
3276
|
isError: ee,
|
|
@@ -3275,22 +3302,22 @@ function ir(e) {
|
|
|
3275
3302
|
size: B,
|
|
3276
3303
|
strokeWidth: 2.5
|
|
3277
3304
|
}),
|
|
3278
|
-
/* @__PURE__ */ m(
|
|
3305
|
+
/* @__PURE__ */ m(ir, {
|
|
3279
3306
|
size: D,
|
|
3280
|
-
children: [J.map((e) => /* @__PURE__ */ p(
|
|
3307
|
+
children: [J.map((e) => /* @__PURE__ */ p(ar, {
|
|
3281
3308
|
label: re(e),
|
|
3282
3309
|
value: e,
|
|
3283
3310
|
handleChangeValue: se,
|
|
3284
3311
|
disabled: z
|
|
3285
3312
|
}, e)), J.length <= 0 && /* @__PURE__ */ p("p", { children: i })]
|
|
3286
3313
|
}),
|
|
3287
|
-
/* @__PURE__ */ m(
|
|
3314
|
+
/* @__PURE__ */ m(sr, {
|
|
3288
3315
|
id: L,
|
|
3289
3316
|
isFocused: U,
|
|
3290
3317
|
isSearchable: h,
|
|
3291
3318
|
search: V,
|
|
3292
3319
|
onSearch: Y,
|
|
3293
|
-
children: [X.map(({ label: e, value: t }, n) => /* @__PURE__ */ p(
|
|
3320
|
+
children: [X.map(({ label: e, value: t }, n) => /* @__PURE__ */ p(or, {
|
|
3294
3321
|
id: ie(t),
|
|
3295
3322
|
label: e,
|
|
3296
3323
|
value: t,
|
|
@@ -3300,18 +3327,18 @@ function ir(e) {
|
|
|
3300
3327
|
optionHasSelected: ne
|
|
3301
3328
|
}, t)), X.length <= 0 && /* @__PURE__ */ p("p", { children: C })]
|
|
3302
3329
|
}),
|
|
3303
|
-
/* @__PURE__ */ p(
|
|
3330
|
+
/* @__PURE__ */ p(nr, {
|
|
3304
3331
|
disabled: z,
|
|
3305
3332
|
isFocused: U,
|
|
3306
3333
|
readOnly: f,
|
|
3307
3334
|
iconSize: B,
|
|
3308
3335
|
isLoading: d
|
|
3309
3336
|
}),
|
|
3310
|
-
/* @__PURE__ */ p(
|
|
3337
|
+
/* @__PURE__ */ p(lr, {
|
|
3311
3338
|
iconSize: B,
|
|
3312
3339
|
isLoading: d
|
|
3313
3340
|
}),
|
|
3314
|
-
/* @__PURE__ */ p(
|
|
3341
|
+
/* @__PURE__ */ p(cr, {
|
|
3315
3342
|
handleBlur: oe,
|
|
3316
3343
|
isFocused: U
|
|
3317
3344
|
})
|
|
@@ -3321,7 +3348,7 @@ function ir(e) {
|
|
|
3321
3348
|
}
|
|
3322
3349
|
//#endregion
|
|
3323
3350
|
//#region src/components/pagination/chevronButton/index.tsx
|
|
3324
|
-
function
|
|
3351
|
+
function dr(e) {
|
|
3325
3352
|
let { orientation: t, handlePageChange: n, disabled: r } = e;
|
|
3326
3353
|
return /* @__PURE__ */ p("button", {
|
|
3327
3354
|
type: "button",
|
|
@@ -3336,7 +3363,7 @@ function ar(e) {
|
|
|
3336
3363
|
}
|
|
3337
3364
|
//#endregion
|
|
3338
3365
|
//#region src/components/pagination/currentButton/index.tsx
|
|
3339
|
-
function
|
|
3366
|
+
function fr({ currentPage: e }) {
|
|
3340
3367
|
return /* @__PURE__ */ p("button", {
|
|
3341
3368
|
type: "button",
|
|
3342
3369
|
className: "arkynPaginationCurrentButton",
|
|
@@ -3346,7 +3373,7 @@ function or({ currentPage: e }) {
|
|
|
3346
3373
|
}
|
|
3347
3374
|
//#endregion
|
|
3348
3375
|
//#region src/components/pagination/pageButton/index.tsx
|
|
3349
|
-
function
|
|
3376
|
+
function pr(e) {
|
|
3350
3377
|
let { page: t, handlePageChange: n } = e;
|
|
3351
3378
|
return /* @__PURE__ */ p("button", {
|
|
3352
3379
|
type: "button",
|
|
@@ -3357,7 +3384,7 @@ function sr(e) {
|
|
|
3357
3384
|
}
|
|
3358
3385
|
//#endregion
|
|
3359
3386
|
//#region src/components/pagination/paginationService.ts
|
|
3360
|
-
var
|
|
3387
|
+
var mr = class {
|
|
3361
3388
|
currentPage;
|
|
3362
3389
|
totalCountRegisters;
|
|
3363
3390
|
registerPerPage;
|
|
@@ -3390,7 +3417,7 @@ var cr = class {
|
|
|
3390
3417
|
};
|
|
3391
3418
|
//#endregion
|
|
3392
3419
|
//#region src/components/pagination/spread/index.tsx
|
|
3393
|
-
function
|
|
3420
|
+
function hr() {
|
|
3394
3421
|
return /* @__PURE__ */ p("p", {
|
|
3395
3422
|
className: "arkynPaginationSpread",
|
|
3396
3423
|
children: /* @__PURE__ */ p(D, {})
|
|
@@ -3398,8 +3425,8 @@ function lr() {
|
|
|
3398
3425
|
}
|
|
3399
3426
|
//#endregion
|
|
3400
3427
|
//#region src/components/pagination/index.tsx
|
|
3401
|
-
function
|
|
3402
|
-
let { totalCountRegisters: t, siblingsCount: n, currentPage: r, registerPerPage: i, onChange: a, ...o } = e, { currentPage: s, siblingsCount: c, previousPages: l, nextPages: u, lastPage: d, handlePageChange: h, handleMinusChange: g, handlePlusChange: _ } = new
|
|
3428
|
+
function gr(e) {
|
|
3429
|
+
let { totalCountRegisters: t, siblingsCount: n, currentPage: r, registerPerPage: i, onChange: a, ...o } = e, { currentPage: s, siblingsCount: c, previousPages: l, nextPages: u, lastPage: d, handlePageChange: h, handleMinusChange: g, handlePlusChange: _ } = new mr({
|
|
3403
3430
|
totalCountRegisters: t,
|
|
3404
3431
|
currentPage: r,
|
|
3405
3432
|
registerPerPage: i,
|
|
@@ -3410,29 +3437,29 @@ function ur(e) {
|
|
|
3410
3437
|
className: "arkynPagination",
|
|
3411
3438
|
...o,
|
|
3412
3439
|
children: [
|
|
3413
|
-
/* @__PURE__ */ p(
|
|
3440
|
+
/* @__PURE__ */ p(dr, {
|
|
3414
3441
|
orientation: "left",
|
|
3415
3442
|
handlePageChange: g,
|
|
3416
3443
|
disabled: s <= 1
|
|
3417
3444
|
}),
|
|
3418
|
-
s > 1 + c && /* @__PURE__ */ m(f, { children: [/* @__PURE__ */ p(
|
|
3445
|
+
s > 1 + c && /* @__PURE__ */ m(f, { children: [/* @__PURE__ */ p(pr, {
|
|
3419
3446
|
page: 1,
|
|
3420
3447
|
handlePageChange: () => h(1)
|
|
3421
|
-
}), s > 2 + c && /* @__PURE__ */ p(
|
|
3422
|
-
l.map((e) => /* @__PURE__ */ p(
|
|
3448
|
+
}), s > 2 + c && /* @__PURE__ */ p(hr, {})] }),
|
|
3449
|
+
l.map((e) => /* @__PURE__ */ p(pr, {
|
|
3423
3450
|
page: e,
|
|
3424
3451
|
handlePageChange: g
|
|
3425
3452
|
}, e)),
|
|
3426
|
-
/* @__PURE__ */ p(
|
|
3427
|
-
u.map((e) => /* @__PURE__ */ p(
|
|
3453
|
+
/* @__PURE__ */ p(fr, { currentPage: s }),
|
|
3454
|
+
u.map((e) => /* @__PURE__ */ p(pr, {
|
|
3428
3455
|
page: e,
|
|
3429
3456
|
handlePageChange: _
|
|
3430
3457
|
}, e)),
|
|
3431
|
-
s + c < d && /* @__PURE__ */ m(f, { children: [s + 1 + c < d && /* @__PURE__ */ p(
|
|
3458
|
+
s + c < d && /* @__PURE__ */ m(f, { children: [s + 1 + c < d && /* @__PURE__ */ p(hr, {}), /* @__PURE__ */ p(pr, {
|
|
3432
3459
|
page: d,
|
|
3433
3460
|
handlePageChange: () => h(d)
|
|
3434
3461
|
})] }),
|
|
3435
|
-
/* @__PURE__ */ p(
|
|
3462
|
+
/* @__PURE__ */ p(dr, {
|
|
3436
3463
|
orientation: "right",
|
|
3437
3464
|
handlePageChange: _,
|
|
3438
3465
|
disabled: s >= d
|
|
@@ -3442,14 +3469,14 @@ function ur(e) {
|
|
|
3442
3469
|
}
|
|
3443
3470
|
//#endregion
|
|
3444
3471
|
//#region src/utils/phoneInputUtilities.ts
|
|
3445
|
-
function
|
|
3472
|
+
function _r(e) {
|
|
3446
3473
|
return e?.replace(/[^0-9]/g, "");
|
|
3447
3474
|
}
|
|
3448
|
-
var
|
|
3475
|
+
var vr = {
|
|
3449
3476
|
EIGHT: "(99) 9999-9999",
|
|
3450
3477
|
NINE: "(99) 99999-9999"
|
|
3451
3478
|
};
|
|
3452
|
-
function
|
|
3479
|
+
function yr(e, t, n = "9") {
|
|
3453
3480
|
let r = "", i = 0;
|
|
3454
3481
|
for (let a = 0; a < t.length; a++) if (t[a] === n) if (i < e.length) r += e[i], i++;
|
|
3455
3482
|
else break;
|
|
@@ -3457,13 +3484,13 @@ function pr(e, t, n = "9") {
|
|
|
3457
3484
|
else break;
|
|
3458
3485
|
return r;
|
|
3459
3486
|
}
|
|
3460
|
-
function
|
|
3487
|
+
function br(e) {
|
|
3461
3488
|
return e.length > 10 ? "NINE" : "EIGHT";
|
|
3462
3489
|
}
|
|
3463
|
-
var
|
|
3490
|
+
var xr = _r(vr.NINE).length;
|
|
3464
3491
|
//#endregion
|
|
3465
3492
|
//#region src/components/phoneInput/phoneInputContainer/index.tsx
|
|
3466
|
-
function
|
|
3493
|
+
function Sr(e) {
|
|
3467
3494
|
let { children: t, onFocus: n, disabled: r, isError: i, isLoading: a, isFocused: o, className: s = "", readOnly: c, variant: l, size: u } = e;
|
|
3468
3495
|
return /* @__PURE__ */ p("section", {
|
|
3469
3496
|
className: `arkynPhoneInputContainer ${l} ${u} ${r || c || a ? "opacity" : ""} ${i ? "errored" : ""} ${o ? "focused" : ""} ${s}`.trim(),
|
|
@@ -3473,7 +3500,7 @@ function gr(e) {
|
|
|
3473
3500
|
}
|
|
3474
3501
|
//#endregion
|
|
3475
3502
|
//#region src/components/phoneInput/phoneInputCountriesOverlay/index.tsx
|
|
3476
|
-
function
|
|
3503
|
+
function Cr(e) {
|
|
3477
3504
|
let { isOpen: t, onClick: n } = e;
|
|
3478
3505
|
return t ? /* @__PURE__ */ p("aside", {
|
|
3479
3506
|
className: "arkynPhoneInputCountriesOverlay",
|
|
@@ -3482,7 +3509,7 @@ function _r(e) {
|
|
|
3482
3509
|
}
|
|
3483
3510
|
//#endregion
|
|
3484
3511
|
//#region src/components/phoneInput/phoneInputCountryOption/index.tsx
|
|
3485
|
-
function
|
|
3512
|
+
function wr(e) {
|
|
3486
3513
|
let { country: t, isActive: n, handleChangeValue: r, size: i } = e;
|
|
3487
3514
|
return /* @__PURE__ */ m("div", {
|
|
3488
3515
|
onClick: () => r(t),
|
|
@@ -3502,12 +3529,12 @@ function vr(e) {
|
|
|
3502
3529
|
}
|
|
3503
3530
|
//#endregion
|
|
3504
3531
|
//#region src/components/phoneInput/phoneInputCountryOptionsContainer/index.tsx
|
|
3505
|
-
function
|
|
3532
|
+
function Tr(e) {
|
|
3506
3533
|
let { children: t, isOpen: n, onSearch: r, search: i, placeholder: a } = e, s = l(null), [c, d] = u("bottom");
|
|
3507
3534
|
function f(e) {
|
|
3508
3535
|
r(e.target.value);
|
|
3509
3536
|
}
|
|
3510
|
-
return
|
|
3537
|
+
return st(n), o(() => {
|
|
3511
3538
|
n && (() => {
|
|
3512
3539
|
if (!s.current) return;
|
|
3513
3540
|
let e = s.current.parentElement;
|
|
@@ -3531,7 +3558,7 @@ function yr(e) {
|
|
|
3531
3558
|
}
|
|
3532
3559
|
//#endregion
|
|
3533
3560
|
//#region src/components/phoneInput/phoneInputCountrySelector/index.tsx
|
|
3534
|
-
function
|
|
3561
|
+
function Er(e) {
|
|
3535
3562
|
let { currentCountry: t, onClick: n } = e;
|
|
3536
3563
|
return /* @__PURE__ */ m("div", {
|
|
3537
3564
|
className: "phoneInputSelectCountry",
|
|
@@ -3552,10 +3579,10 @@ function br(e) {
|
|
|
3552
3579
|
}
|
|
3553
3580
|
//#endregion
|
|
3554
3581
|
//#region src/components/phoneInput/phoneInputMask/index.tsx
|
|
3555
|
-
var
|
|
3582
|
+
var Dr = r((e, t) => /* @__PURE__ */ p("input", {
|
|
3556
3583
|
ref: t,
|
|
3557
3584
|
...e
|
|
3558
|
-
})),
|
|
3585
|
+
})), Or = r((e, t) => {
|
|
3559
3586
|
let { onFocus: n, readonly: r, onBlur: i, size: a, onChange: s, value: c, currentCountry: u, disabled: d, id: f } = e, m = l(!0), h = l(s);
|
|
3560
3587
|
h.current = s;
|
|
3561
3588
|
let g = typeof u.mask == "string" ? u.mask : u.mask[0];
|
|
@@ -3568,8 +3595,8 @@ var xr = r((e, t) => /* @__PURE__ */ p("input", {
|
|
|
3568
3595
|
}, [g]);
|
|
3569
3596
|
let _ = `phoneInputMask ${a}`;
|
|
3570
3597
|
function v(e) {
|
|
3571
|
-
let t =
|
|
3572
|
-
t.length >
|
|
3598
|
+
let t = _r(e.target.value), n = br(t);
|
|
3599
|
+
t.length > xr || (t = yr(t, vr[n]), e.target.value = t, s(t));
|
|
3573
3600
|
}
|
|
3574
3601
|
return u.code === "+55" ? /* @__PURE__ */ p("input", {
|
|
3575
3602
|
id: f,
|
|
@@ -3587,7 +3614,7 @@ var xr = r((e, t) => /* @__PURE__ */ p("input", {
|
|
|
3587
3614
|
readOnly: r,
|
|
3588
3615
|
onChange: (e) => s(e.target.value),
|
|
3589
3616
|
className: _,
|
|
3590
|
-
component:
|
|
3617
|
+
component: Dr,
|
|
3591
3618
|
onFocus: n,
|
|
3592
3619
|
onBlur: i,
|
|
3593
3620
|
disabled: d,
|
|
@@ -3599,12 +3626,12 @@ var xr = r((e, t) => /* @__PURE__ */ p("input", {
|
|
|
3599
3626
|
});
|
|
3600
3627
|
//#endregion
|
|
3601
3628
|
//#region src/components/phoneInput/index.tsx
|
|
3602
|
-
function
|
|
3629
|
+
function kr(e, t) {
|
|
3603
3630
|
let n = ie(e), r = ie(t.code), i = e.trim().startsWith("+") && n.startsWith(r) ? n.slice(r.length) : n;
|
|
3604
|
-
return t.code === "+55" ?
|
|
3631
|
+
return t.code === "+55" ? yr(i, vr[br(i)]) : yr(i, typeof t.mask == "string" ? t.mask : t.mask[0], "_");
|
|
3605
3632
|
}
|
|
3606
|
-
function
|
|
3607
|
-
let { value: t, label: n, className: r = "", disabled: i = !1, errorMessage: a, isLoading: o = !1, readOnly: c = !1, size: d = "md", defaultValue: f = "", variant: h = "solid", showAsterisk: g, name: _, onChange: v, searchCountryPlaceholder: y = "Pesquisar país", notFoundCountryText: b = "Nenhum país encontrado", id: x, unShowFieldTemplate: S = !1, orientation: C = "vertical" } = e, w = se.find((e) => e.iso === "BR"), T = f ? re(f) : "", E = f ? q(f)[1] : w, [D, O] = u(!1), [k, A] = u(""), [j, M] = u(!1), [N, P] = u(T), [F, I] = u(E), L = t === void 0 ? N :
|
|
3633
|
+
function Ar(e) {
|
|
3634
|
+
let { value: t, label: n, className: r = "", disabled: i = !1, errorMessage: a, isLoading: o = !1, readOnly: c = !1, size: d = "md", defaultValue: f = "", variant: h = "solid", showAsterisk: g, name: _, onChange: v, searchCountryPlaceholder: y = "Pesquisar país", notFoundCountryText: b = "Nenhum país encontrado", id: x, unShowFieldTemplate: S = !1, orientation: C = "vertical" } = e, w = se.find((e) => e.iso === "BR"), T = f ? re(f) : "", E = f ? q(f)[1] : w, [D, O] = u(!1), [k, A] = u(""), [j, M] = u(!1), [N, P] = u(T), [F, I] = u(E), L = t === void 0 ? N : kr(t, F), { fieldErrors: R } = Q(), ee = l(null), z = s(), B = x || z, V = a || R?.[_], H = !!V, U = i || o, W = l(null);
|
|
3608
3635
|
function G() {
|
|
3609
3636
|
U || D || j || (O(!0), W.current && W.current.focus());
|
|
3610
3637
|
}
|
|
@@ -3627,7 +3654,7 @@ function wr(e) {
|
|
|
3627
3654
|
let t = F.code;
|
|
3628
3655
|
return t += ie(e || L), t;
|
|
3629
3656
|
}
|
|
3630
|
-
return /* @__PURE__ */ p(
|
|
3657
|
+
return /* @__PURE__ */ p(et, {
|
|
3631
3658
|
name: _,
|
|
3632
3659
|
label: n,
|
|
3633
3660
|
showAsterisk: g,
|
|
@@ -3635,7 +3662,7 @@ function wr(e) {
|
|
|
3635
3662
|
errorMessage: V,
|
|
3636
3663
|
unShowFieldTemplate: S,
|
|
3637
3664
|
orientation: C,
|
|
3638
|
-
children: /* @__PURE__ */ m(
|
|
3665
|
+
children: /* @__PURE__ */ m(Sr, {
|
|
3639
3666
|
disabled: U,
|
|
3640
3667
|
isError: H,
|
|
3641
3668
|
isLoading: o,
|
|
@@ -3645,17 +3672,17 @@ function wr(e) {
|
|
|
3645
3672
|
variant: h,
|
|
3646
3673
|
onFocus: G,
|
|
3647
3674
|
children: [
|
|
3648
|
-
/* @__PURE__ */ p(
|
|
3675
|
+
/* @__PURE__ */ p(Er, {
|
|
3649
3676
|
currentCountry: F,
|
|
3650
3677
|
onClick: te,
|
|
3651
3678
|
size: d
|
|
3652
3679
|
}),
|
|
3653
|
-
/* @__PURE__ */ m(
|
|
3680
|
+
/* @__PURE__ */ m(Tr, {
|
|
3654
3681
|
isOpen: U || c ? !1 : j,
|
|
3655
3682
|
search: k,
|
|
3656
3683
|
placeholder: y,
|
|
3657
3684
|
onSearch: A,
|
|
3658
|
-
children: [se.filter((e) => ae(e)).map((e) => /* @__PURE__ */ p(
|
|
3685
|
+
children: [se.filter((e) => ae(e)).map((e) => /* @__PURE__ */ p(wr, {
|
|
3659
3686
|
country: e,
|
|
3660
3687
|
handleChangeValue: () => {
|
|
3661
3688
|
I(e), M(!1), P("");
|
|
@@ -3664,11 +3691,11 @@ function wr(e) {
|
|
|
3664
3691
|
size: d
|
|
3665
3692
|
}, e.iso)), se.filter((e) => ae(e)).length === 0 && /* @__PURE__ */ p("p", { children: b })]
|
|
3666
3693
|
}),
|
|
3667
|
-
/* @__PURE__ */ p(
|
|
3694
|
+
/* @__PURE__ */ p(Cr, {
|
|
3668
3695
|
isOpen: U || c ? !1 : j,
|
|
3669
3696
|
onClick: K
|
|
3670
3697
|
}),
|
|
3671
|
-
/* @__PURE__ */ p(
|
|
3698
|
+
/* @__PURE__ */ p(Or, {
|
|
3672
3699
|
id: B,
|
|
3673
3700
|
ref: W,
|
|
3674
3701
|
readonly: c,
|
|
@@ -3694,12 +3721,12 @@ function wr(e) {
|
|
|
3694
3721
|
}
|
|
3695
3722
|
//#endregion
|
|
3696
3723
|
//#region src/components/popover/index.tsx
|
|
3697
|
-
function
|
|
3724
|
+
function jr(e) {
|
|
3698
3725
|
let { children: t, button: n, closeOnClick: r, className: i = "", orientation: a = "bottomLeft" } = e, [o, s] = u(!1), c = l(null), d = `arkynPopover ${a} ${o ? "visibleTrue" : "visibleFalse"} ${i}`;
|
|
3699
3726
|
function f() {
|
|
3700
3727
|
o || s(!0);
|
|
3701
3728
|
}
|
|
3702
|
-
return
|
|
3729
|
+
return st(o), Bt(o, () => s(!1)), Ut(o, c), /* @__PURE__ */ m("div", {
|
|
3703
3730
|
className: d,
|
|
3704
3731
|
onClick: f,
|
|
3705
3732
|
children: [
|
|
@@ -3723,10 +3750,10 @@ function Tr(e) {
|
|
|
3723
3750
|
}
|
|
3724
3751
|
//#endregion
|
|
3725
3752
|
//#region src/components/radio/radioContext.tsx
|
|
3726
|
-
var
|
|
3727
|
-
function
|
|
3753
|
+
var Mr = n({});
|
|
3754
|
+
function Nr(e) {
|
|
3728
3755
|
let { children: t, size: n, isError: r, handleChange: i, value: a, disabled: o } = e;
|
|
3729
|
-
return /* @__PURE__ */ p(
|
|
3756
|
+
return /* @__PURE__ */ p(Mr.Provider, {
|
|
3730
3757
|
value: {
|
|
3731
3758
|
handleChange: i,
|
|
3732
3759
|
value: a,
|
|
@@ -3737,13 +3764,13 @@ function Dr(e) {
|
|
|
3737
3764
|
children: t
|
|
3738
3765
|
});
|
|
3739
3766
|
}
|
|
3740
|
-
function
|
|
3741
|
-
return a(
|
|
3767
|
+
function Pr() {
|
|
3768
|
+
return a(Mr);
|
|
3742
3769
|
}
|
|
3743
3770
|
//#endregion
|
|
3744
3771
|
//#region src/components/radio/radioBox/index.tsx
|
|
3745
|
-
function
|
|
3746
|
-
let { value: t, size: n, disabled: r, children: i, className: a = "", onClick: o, onFocus: s, ...c } = e, { handleChange: l, size: u, value: d, isError: f, disabled: h } =
|
|
3772
|
+
function Fr(e) {
|
|
3773
|
+
let { value: t, size: n, disabled: r, children: i, className: a = "", onClick: o, onFocus: s, ...c } = e, { handleChange: l, size: u, value: d, isError: f, disabled: h } = Pr(), g = d === t, _ = n || u, v = r || h, y = `arkynRadioBox ${_} ${g ? "checkedTrue" : "checkedFalse"} ${f ? "errorTrue" : "errorFalse"} ${v ? "disabledTrue" : "disabledFalse"} ${a}`;
|
|
3747
3774
|
function b(e) {
|
|
3748
3775
|
o?.(e), l(t);
|
|
3749
3776
|
}
|
|
@@ -3763,13 +3790,13 @@ function kr(e) {
|
|
|
3763
3790
|
}
|
|
3764
3791
|
//#endregion
|
|
3765
3792
|
//#region src/components/radio/radioGroup/index.tsx
|
|
3766
|
-
function
|
|
3793
|
+
function Ir(e) {
|
|
3767
3794
|
let { defaultValue: t = "", name: n, label: r, showAsterisk: i, errorMessage: a, value: o, onChange: s, size: c = "md", className: l = "", disabled: d = !1, unShowFieldTemplate: f = !1, orientation: h = "vertical", ...g } = e, [_, v] = u(t), { fieldErrors: y } = Q();
|
|
3768
3795
|
function b(e) {
|
|
3769
3796
|
v(e), s && s(e);
|
|
3770
3797
|
}
|
|
3771
3798
|
let x = a || y?.[n], S = !!x, C = `arkynRadioGroup ${c}`;
|
|
3772
|
-
return /* @__PURE__ */ p(
|
|
3799
|
+
return /* @__PURE__ */ p(et, {
|
|
3773
3800
|
name: n,
|
|
3774
3801
|
label: r,
|
|
3775
3802
|
showAsterisk: i,
|
|
@@ -3777,7 +3804,7 @@ function Ar(e) {
|
|
|
3777
3804
|
errorMessage: x,
|
|
3778
3805
|
unShowFieldTemplate: f,
|
|
3779
3806
|
orientation: h,
|
|
3780
|
-
children: /* @__PURE__ */ m(
|
|
3807
|
+
children: /* @__PURE__ */ m(Nr, {
|
|
3781
3808
|
isError: S,
|
|
3782
3809
|
size: c,
|
|
3783
3810
|
value: o || _,
|
|
@@ -3798,7 +3825,7 @@ function Ar(e) {
|
|
|
3798
3825
|
}
|
|
3799
3826
|
//#endregion
|
|
3800
3827
|
//#region src/services/clearLinkMarkAtBoundary.ts
|
|
3801
|
-
function
|
|
3828
|
+
function Lr(e) {
|
|
3802
3829
|
let { selection: t } = e;
|
|
3803
3830
|
if (!t || !ue.isCollapsed(t)) return;
|
|
3804
3831
|
let [n, r] = Z.leaf(e, t.anchor);
|
|
@@ -3806,31 +3833,31 @@ function jr(e) {
|
|
|
3806
3833
|
}
|
|
3807
3834
|
//#endregion
|
|
3808
3835
|
//#region src/services/extractTextFromNode.ts
|
|
3809
|
-
function
|
|
3836
|
+
function Rr(e) {
|
|
3810
3837
|
return e.map((e) => le.string(e)).join("");
|
|
3811
3838
|
}
|
|
3812
3839
|
//#endregion
|
|
3813
3840
|
//#region src/services/isMarkActive.ts
|
|
3814
|
-
function
|
|
3841
|
+
function zr(e, t) {
|
|
3815
3842
|
let n = Z.marks(e);
|
|
3816
3843
|
return n ? n[t] === !0 : !1;
|
|
3817
3844
|
}
|
|
3818
3845
|
//#endregion
|
|
3819
3846
|
//#region src/services/toggleMark.ts
|
|
3820
|
-
function
|
|
3821
|
-
|
|
3847
|
+
function Br(e, t) {
|
|
3848
|
+
zr(e, t) ? Z.removeMark(e, t) : Z.addMark(e, t, !0);
|
|
3822
3849
|
}
|
|
3823
3850
|
//#endregion
|
|
3824
3851
|
//#region src/templates/richTextTemplates.ts
|
|
3825
|
-
var
|
|
3852
|
+
var Vr = {
|
|
3826
3853
|
"mod+b": "bold",
|
|
3827
3854
|
"mod+i": "italic",
|
|
3828
3855
|
"mod+u": "underline",
|
|
3829
3856
|
"mod+`": "code"
|
|
3830
|
-
},
|
|
3857
|
+
}, Hr = [{
|
|
3831
3858
|
type: "paragraph",
|
|
3832
3859
|
children: [{ text: "" }]
|
|
3833
|
-
}],
|
|
3860
|
+
}], Ur = ["listItem", "numberedList"], Wr = [
|
|
3834
3861
|
"left",
|
|
3835
3862
|
"center",
|
|
3836
3863
|
"right",
|
|
@@ -3838,7 +3865,7 @@ var Fr = {
|
|
|
3838
3865
|
];
|
|
3839
3866
|
//#endregion
|
|
3840
3867
|
//#region src/services/isBlockActive.ts
|
|
3841
|
-
function
|
|
3868
|
+
function Gr(e, t, n = "type") {
|
|
3842
3869
|
let { selection: r } = e;
|
|
3843
3870
|
if (!r) return !1;
|
|
3844
3871
|
let [i] = Array.from(Z.nodes(e, {
|
|
@@ -3849,14 +3876,14 @@ function zr(e, t, n = "type") {
|
|
|
3849
3876
|
}
|
|
3850
3877
|
//#endregion
|
|
3851
3878
|
//#region src/services/toggleBlock.ts
|
|
3852
|
-
function
|
|
3853
|
-
let n =
|
|
3879
|
+
function Kr(e, t) {
|
|
3880
|
+
let n = Gr(e, t, Wr.includes(t) ? "align" : "type"), r = Ur.includes(t);
|
|
3854
3881
|
fe.unwrapNodes(e, {
|
|
3855
|
-
match: (e) => !Z.isEditor(e) && ce.isElement(e) &&
|
|
3882
|
+
match: (e) => !Z.isEditor(e) && ce.isElement(e) && Ur.includes(e.type) && !Wr.includes(t),
|
|
3856
3883
|
split: !0
|
|
3857
3884
|
});
|
|
3858
3885
|
let i;
|
|
3859
|
-
if (i =
|
|
3886
|
+
if (i = Wr.includes(t) ? { align: n ? void 0 : t } : { type: n ? "paragraph" : r ? "listItem" : t }, fe.setNodes(e, i), !n && r) {
|
|
3860
3887
|
let n = {
|
|
3861
3888
|
type: t,
|
|
3862
3889
|
children: []
|
|
@@ -3866,10 +3893,10 @@ function Br(e, t) {
|
|
|
3866
3893
|
}
|
|
3867
3894
|
//#endregion
|
|
3868
3895
|
//#region src/components/richText/blockButton/index.tsx
|
|
3869
|
-
function
|
|
3870
|
-
let n = _e(), r =
|
|
3896
|
+
function qr({ format: e, icon: t }) {
|
|
3897
|
+
let n = _e(), r = Gr(n, e, Wr.includes(e) ? "align" : "type") ? "activeTrue" : "activeFalse";
|
|
3871
3898
|
function i(t) {
|
|
3872
|
-
t.preventDefault(),
|
|
3899
|
+
t.preventDefault(), Kr(n, e);
|
|
3873
3900
|
}
|
|
3874
3901
|
return /* @__PURE__ */ p("button", {
|
|
3875
3902
|
type: "button",
|
|
@@ -3880,7 +3907,7 @@ function Vr({ format: e, icon: t }) {
|
|
|
3880
3907
|
}
|
|
3881
3908
|
//#endregion
|
|
3882
3909
|
//#region src/components/richText/element/index.tsx
|
|
3883
|
-
function
|
|
3910
|
+
function Jr({ attributes: e, children: t, element: n }) {
|
|
3884
3911
|
let r = { textAlign: n.align };
|
|
3885
3912
|
switch (n.type) {
|
|
3886
3913
|
case "blockQuote": return /* @__PURE__ */ p("blockquote", {
|
|
@@ -3950,11 +3977,11 @@ function Hr({ attributes: e, children: t, element: n }) {
|
|
|
3950
3977
|
}
|
|
3951
3978
|
//#endregion
|
|
3952
3979
|
//#region src/components/tab/tabContext.tsx
|
|
3953
|
-
var
|
|
3954
|
-
function
|
|
3955
|
-
return a(
|
|
3980
|
+
var Yr = n({});
|
|
3981
|
+
function Xr() {
|
|
3982
|
+
return a(Yr);
|
|
3956
3983
|
}
|
|
3957
|
-
function
|
|
3984
|
+
function Zr(e) {
|
|
3958
3985
|
let { disabled: t, currentTab: n, changeCurrentTab: r } = e, i = c(() => ({
|
|
3959
3986
|
disabled: t,
|
|
3960
3987
|
currentTab: n,
|
|
@@ -3964,15 +3991,15 @@ function Gr(e) {
|
|
|
3964
3991
|
n,
|
|
3965
3992
|
r
|
|
3966
3993
|
]);
|
|
3967
|
-
return /* @__PURE__ */ p(
|
|
3994
|
+
return /* @__PURE__ */ p(Yr.Provider, {
|
|
3968
3995
|
value: i,
|
|
3969
3996
|
children: e.children
|
|
3970
3997
|
});
|
|
3971
3998
|
}
|
|
3972
3999
|
//#endregion
|
|
3973
4000
|
//#region src/components/tab/tabButton/index.tsx
|
|
3974
|
-
function
|
|
3975
|
-
let { children: t, disabled: n = !1, className: r = "", onClick: i, value: a, ...o } = e, { disabled: s, currentTab: c, changeCurrentTab: l } =
|
|
4001
|
+
function Qr(e) {
|
|
4002
|
+
let { children: t, disabled: n = !1, className: r = "", onClick: i, value: a, ...o } = e, { disabled: s, currentTab: c, changeCurrentTab: l } = Xr(), u = s || n, d = `arkynTabButton ${u ? "isDisabled" : ""} ${c === a && a ? "isActive" : ""} ${r}`;
|
|
3976
4003
|
function f(e) {
|
|
3977
4004
|
l(a), i?.(e);
|
|
3978
4005
|
}
|
|
@@ -3987,12 +4014,12 @@ function Kr(e) {
|
|
|
3987
4014
|
}
|
|
3988
4015
|
//#endregion
|
|
3989
4016
|
//#region src/components/tab/tabContainer/index.tsx
|
|
3990
|
-
function
|
|
4017
|
+
function $r(e) {
|
|
3991
4018
|
let { children: t, onChange: n, defaultValue: r, disabled: i = !1, className: a, ...o } = e, [s, c] = u(r || ""), l = `arkynTabContainer ${a || ""}`;
|
|
3992
4019
|
function d(e) {
|
|
3993
4020
|
c(e), n && n(e);
|
|
3994
4021
|
}
|
|
3995
|
-
return /* @__PURE__ */ p(
|
|
4022
|
+
return /* @__PURE__ */ p(Zr, {
|
|
3996
4023
|
disabled: i,
|
|
3997
4024
|
currentTab: s,
|
|
3998
4025
|
changeCurrentTab: d,
|
|
@@ -4005,7 +4032,7 @@ function qr(e) {
|
|
|
4005
4032
|
}
|
|
4006
4033
|
//#endregion
|
|
4007
4034
|
//#region src/components/richText/insertImage/index.tsx
|
|
4008
|
-
function
|
|
4035
|
+
function ei(e) {
|
|
4009
4036
|
let { action: t, tabLabels: n = ["Adicionar URL", "Upload de arquivo"], modalCancelButton: r = "Cancelar", modalConfirmButton: i = "Confirmar", modalInputImageLabel: a = "Imagem:", modalInputUrlLabel: o = "URL da imagem:", modalTitle: s = "Inserir imagem" } = e, c = _e(), [l, d] = u(!1), [h, g] = u(""), [_, v] = u("url");
|
|
4010
4037
|
function y(e) {
|
|
4011
4038
|
e.preventDefault(), !(!h || h === "") && (c.insertNodes([
|
|
@@ -4029,26 +4056,26 @@ function Jr(e) {
|
|
|
4029
4056
|
className: "arkynRichTextInsertImage",
|
|
4030
4057
|
onMouseDown: () => d(!0),
|
|
4031
4058
|
children: /* @__PURE__ */ p(P, {})
|
|
4032
|
-
}), /* @__PURE__ */ m(
|
|
4059
|
+
}), /* @__PURE__ */ m($n, {
|
|
4033
4060
|
isVisible: l,
|
|
4034
4061
|
makeInvisible: () => d(!1),
|
|
4035
4062
|
children: [
|
|
4036
|
-
/* @__PURE__ */ p(
|
|
4063
|
+
/* @__PURE__ */ p(tr, { children: s }),
|
|
4037
4064
|
/* @__PURE__ */ m("div", {
|
|
4038
4065
|
className: "arkynRichTextInsertImageModalContent",
|
|
4039
4066
|
children: [
|
|
4040
|
-
/* @__PURE__ */ m(
|
|
4067
|
+
/* @__PURE__ */ m($r, {
|
|
4041
4068
|
defaultValue: _,
|
|
4042
4069
|
onChange: v,
|
|
4043
|
-
children: [/* @__PURE__ */ p(
|
|
4070
|
+
children: [/* @__PURE__ */ p(Qr, {
|
|
4044
4071
|
value: "url",
|
|
4045
4072
|
children: n[0]
|
|
4046
|
-
}), /* @__PURE__ */ p(
|
|
4073
|
+
}), /* @__PURE__ */ p(Qr, {
|
|
4047
4074
|
value: "file",
|
|
4048
4075
|
children: n[1]
|
|
4049
4076
|
})]
|
|
4050
4077
|
}),
|
|
4051
|
-
_ === "url" && /* @__PURE__ */ m(f, { children: [/* @__PURE__ */ p(
|
|
4078
|
+
_ === "url" && /* @__PURE__ */ m(f, { children: [/* @__PURE__ */ p(ct, {
|
|
4052
4079
|
type: "text",
|
|
4053
4080
|
name: "richTextImageURL",
|
|
4054
4081
|
label: o,
|
|
@@ -4060,7 +4087,7 @@ function Jr(e) {
|
|
|
4060
4087
|
src: h,
|
|
4061
4088
|
alt: "preview"
|
|
4062
4089
|
})] }),
|
|
4063
|
-
_ === "file" && /* @__PURE__ */ p(
|
|
4090
|
+
_ === "file" && /* @__PURE__ */ p(Wn, {
|
|
4064
4091
|
name: "richTextImageURL",
|
|
4065
4092
|
action: t,
|
|
4066
4093
|
label: a,
|
|
@@ -4070,7 +4097,7 @@ function Jr(e) {
|
|
|
4070
4097
|
})
|
|
4071
4098
|
]
|
|
4072
4099
|
}),
|
|
4073
|
-
/* @__PURE__ */ m(
|
|
4100
|
+
/* @__PURE__ */ m(er, { children: [/* @__PURE__ */ p(Be, {
|
|
4074
4101
|
type: "button",
|
|
4075
4102
|
scheme: "danger",
|
|
4076
4103
|
variant: "outline",
|
|
@@ -4086,7 +4113,7 @@ function Jr(e) {
|
|
|
4086
4113
|
}
|
|
4087
4114
|
//#endregion
|
|
4088
4115
|
//#region src/services/isValidHttpsUrl.ts
|
|
4089
|
-
function
|
|
4116
|
+
function ti(e) {
|
|
4090
4117
|
try {
|
|
4091
4118
|
return new URL(e).protocol === "https:";
|
|
4092
4119
|
} catch {
|
|
@@ -4095,8 +4122,8 @@ function Yr(e) {
|
|
|
4095
4122
|
}
|
|
4096
4123
|
//#endregion
|
|
4097
4124
|
//#region src/components/richText/insertLink/index.tsx
|
|
4098
|
-
function
|
|
4099
|
-
let { modalCancelButton: t = "Cancelar", modalConfirmButton: n = "Confirmar", modalInputUrlLabel: r = "URL do link:", modalTitle: i = "Inserir link", invalidUrlMessage: a = "URL inválida" } = e, s = _e(), [c, l] = u(!1), [d, h] = u(""), [g, _] = u(s.selection), v =
|
|
4125
|
+
function ni(e) {
|
|
4126
|
+
let { modalCancelButton: t = "Cancelar", modalConfirmButton: n = "Confirmar", modalInputUrlLabel: r = "URL do link:", modalTitle: i = "Inserir link", invalidUrlMessage: a = "URL inválida" } = e, s = _e(), [c, l] = u(!1), [d, h] = u(""), [g, _] = u(s.selection), v = ti(d), y = d && !v ? a : "";
|
|
4100
4127
|
function b(e) {
|
|
4101
4128
|
e.preventDefault(), _(s.selection), l(!0);
|
|
4102
4129
|
}
|
|
@@ -4114,14 +4141,14 @@ function Xr(e) {
|
|
|
4114
4141
|
className: "arkynRichTextInsertLink",
|
|
4115
4142
|
onMouseDown: b,
|
|
4116
4143
|
children: /* @__PURE__ */ p(L, {})
|
|
4117
|
-
}), /* @__PURE__ */ m(
|
|
4144
|
+
}), /* @__PURE__ */ m($n, {
|
|
4118
4145
|
isVisible: c,
|
|
4119
4146
|
makeInvisible: () => l(!1),
|
|
4120
4147
|
children: [
|
|
4121
|
-
/* @__PURE__ */ p(
|
|
4148
|
+
/* @__PURE__ */ p(tr, { children: i }),
|
|
4122
4149
|
/* @__PURE__ */ p("div", {
|
|
4123
4150
|
className: "arkynRichTextInsertLinkModalContent",
|
|
4124
|
-
children: /* @__PURE__ */ p(
|
|
4151
|
+
children: /* @__PURE__ */ p(ct, {
|
|
4125
4152
|
type: "text",
|
|
4126
4153
|
name: "richTextLinkURL",
|
|
4127
4154
|
label: r,
|
|
@@ -4131,7 +4158,7 @@ function Xr(e) {
|
|
|
4131
4158
|
errorMessage: y
|
|
4132
4159
|
})
|
|
4133
4160
|
}),
|
|
4134
|
-
/* @__PURE__ */ m(
|
|
4161
|
+
/* @__PURE__ */ m(er, { children: [/* @__PURE__ */ p(Be, {
|
|
4135
4162
|
type: "button",
|
|
4136
4163
|
scheme: "danger",
|
|
4137
4164
|
variant: "outline",
|
|
@@ -4148,7 +4175,7 @@ function Xr(e) {
|
|
|
4148
4175
|
}
|
|
4149
4176
|
//#endregion
|
|
4150
4177
|
//#region src/components/richText/insertVideo/index.tsx
|
|
4151
|
-
function
|
|
4178
|
+
function ri(e) {
|
|
4152
4179
|
let { modalCancelButton: t = "Cancelar", modalConfirmButton: n = "Confirmar", modalInputUrlLabel: r = "URL do vídeo:", modalTitle: i = "Inserir vídeo", invalidUrlMessage: a = "URL inválida" } = e, s = _e(), [c, l] = u(!1), [d, h] = u(""), [g, _] = u(""), [v, y] = u("");
|
|
4153
4180
|
function b(e) {
|
|
4154
4181
|
if (e.preventDefault(), !d || d === "") return;
|
|
@@ -4171,7 +4198,7 @@ function Zr(e) {
|
|
|
4171
4198
|
}
|
|
4172
4199
|
return o(() => {
|
|
4173
4200
|
if (!g || g === "") return;
|
|
4174
|
-
if (h(""), y(""), !
|
|
4201
|
+
if (h(""), y(""), !ti(g)) {
|
|
4175
4202
|
y(a);
|
|
4176
4203
|
return;
|
|
4177
4204
|
}
|
|
@@ -4184,14 +4211,14 @@ function Zr(e) {
|
|
|
4184
4211
|
className: "arkynRichTextInsertVideo",
|
|
4185
4212
|
onMouseDown: () => l(!0),
|
|
4186
4213
|
children: /* @__PURE__ */ p(G, {})
|
|
4187
|
-
}), /* @__PURE__ */ m(
|
|
4214
|
+
}), /* @__PURE__ */ m($n, {
|
|
4188
4215
|
isVisible: c,
|
|
4189
4216
|
makeInvisible: () => l(!1),
|
|
4190
4217
|
children: [
|
|
4191
|
-
/* @__PURE__ */ p(
|
|
4218
|
+
/* @__PURE__ */ p(tr, { children: i }),
|
|
4192
4219
|
/* @__PURE__ */ m("div", {
|
|
4193
4220
|
className: "arkynRichTextInsertVideoModalContent",
|
|
4194
|
-
children: [/* @__PURE__ */ p(
|
|
4221
|
+
children: [/* @__PURE__ */ p(ct, {
|
|
4195
4222
|
type: "text",
|
|
4196
4223
|
name: "richTextVideoURL",
|
|
4197
4224
|
label: r,
|
|
@@ -4209,7 +4236,7 @@ function Zr(e) {
|
|
|
4209
4236
|
allowFullScreen: !0
|
|
4210
4237
|
})]
|
|
4211
4238
|
}),
|
|
4212
|
-
/* @__PURE__ */ m(
|
|
4239
|
+
/* @__PURE__ */ m(er, { children: [/* @__PURE__ */ p(Be, {
|
|
4213
4240
|
type: "button",
|
|
4214
4241
|
scheme: "danger",
|
|
4215
4242
|
variant: "outline",
|
|
@@ -4226,7 +4253,7 @@ function Zr(e) {
|
|
|
4226
4253
|
}
|
|
4227
4254
|
//#endregion
|
|
4228
4255
|
//#region src/components/richText/leaf/index.tsx
|
|
4229
|
-
function
|
|
4256
|
+
function ii({ attributes: e, children: t, leaf: n }) {
|
|
4230
4257
|
return n.bold && (t = /* @__PURE__ */ p("strong", { children: t })), n.code && (t = /* @__PURE__ */ p("code", { children: t })), n.italic && (t = /* @__PURE__ */ p("em", { children: t })), n.underline && (t = /* @__PURE__ */ p("u", { children: t })), n.link && (t = /* @__PURE__ */ p("a", {
|
|
4231
4258
|
className: "arkynLeafLink",
|
|
4232
4259
|
href: n.href,
|
|
@@ -4238,10 +4265,10 @@ function Qr({ attributes: e, children: t, leaf: n }) {
|
|
|
4238
4265
|
}
|
|
4239
4266
|
//#endregion
|
|
4240
4267
|
//#region src/components/richText/markButton/index.tsx
|
|
4241
|
-
function
|
|
4242
|
-
let n = _e(), r =
|
|
4268
|
+
function ai({ format: e, icon: t }) {
|
|
4269
|
+
let n = _e(), r = zr(n, e) ? "activeTrue" : "activeFalse";
|
|
4243
4270
|
function i(t) {
|
|
4244
|
-
t.preventDefault(),
|
|
4271
|
+
t.preventDefault(), Br(n, e);
|
|
4245
4272
|
}
|
|
4246
4273
|
return /* @__PURE__ */ p("button", {
|
|
4247
4274
|
type: "button",
|
|
@@ -4252,7 +4279,7 @@ function $r({ format: e, icon: t }) {
|
|
|
4252
4279
|
}
|
|
4253
4280
|
//#endregion
|
|
4254
4281
|
//#region src/components/richText/toolbar/index.tsx
|
|
4255
|
-
function
|
|
4282
|
+
function oi({ children: e }) {
|
|
4256
4283
|
return /* @__PURE__ */ p("div", {
|
|
4257
4284
|
className: "arkynRichTextToolbar",
|
|
4258
4285
|
children: e
|
|
@@ -4260,24 +4287,24 @@ function ei({ children: e }) {
|
|
|
4260
4287
|
}
|
|
4261
4288
|
//#endregion
|
|
4262
4289
|
//#region src/components/richText/index.tsx
|
|
4263
|
-
function
|
|
4290
|
+
function si(e) {
|
|
4264
4291
|
let { name: t, hiddenButtons: n, imageConfig: r, videoConfig: a, linkConfig: o, className: d = "", defaultValue: f = "[]", enforceCharacterLimit: h = !1, onChangeCharactersCount: x, baseErrorMessage: S, maxLimit: C = 1e4, onChange: w, isError: T, label: D, showAsterisk: O, id: k, orientation: A = "vertical", unShowFieldTemplate: j = !1 } = e, P = c(() => me(ve(pe())), []), { fieldErrors: F } = Q(), L = c(() => {
|
|
4265
4292
|
try {
|
|
4266
4293
|
let e = JSON.parse(f);
|
|
4267
|
-
return !Array.isArray(e) || e.length === 0 ? structuredClone(
|
|
4294
|
+
return !Array.isArray(e) || e.length === 0 ? structuredClone(Hr) : e.every((e) => typeof e == "object" && !!e && "type" in e && "children" in e) ? e : structuredClone(Hr);
|
|
4268
4295
|
} catch {
|
|
4269
|
-
return structuredClone(
|
|
4296
|
+
return structuredClone(Hr);
|
|
4270
4297
|
}
|
|
4271
|
-
}, [f]), [R, ee] = u(
|
|
4298
|
+
}, [f]), [R, ee] = u(Rr(L).length), [z, B] = u(JSON.stringify(L) || "[]"), [H, U] = u(!1), G = l(null), te = s(), K = k || te, q = S || F?.[t], J = T || !!q, ne = i(ii, []), re = i(Jr, []);
|
|
4272
4299
|
function ie(e) {
|
|
4273
|
-
let t =
|
|
4300
|
+
let t = Rr(e);
|
|
4274
4301
|
ee(t.length), x?.(t.length), !(h && t.length >= C) && (B(JSON.stringify(e)), w?.(e));
|
|
4275
4302
|
}
|
|
4276
4303
|
let ae = `arkynRichText ${J || C < R ? "errorTrue" : "errorFalse"} ${H ? "focusTrue" : "focusFalse"}`, oe = C - R;
|
|
4277
4304
|
function Y(e) {
|
|
4278
4305
|
return !n?.includes(e);
|
|
4279
4306
|
}
|
|
4280
|
-
return /* @__PURE__ */ p(
|
|
4307
|
+
return /* @__PURE__ */ p(et, {
|
|
4281
4308
|
name: t,
|
|
4282
4309
|
label: D,
|
|
4283
4310
|
showAsterisk: O,
|
|
@@ -4294,54 +4321,54 @@ function ti(e) {
|
|
|
4294
4321
|
/* @__PURE__ */ m("div", {
|
|
4295
4322
|
className: ae,
|
|
4296
4323
|
children: [
|
|
4297
|
-
/* @__PURE__ */ m(
|
|
4298
|
-
Y("headingOne") && /* @__PURE__ */ p(
|
|
4324
|
+
/* @__PURE__ */ m(oi, { children: [
|
|
4325
|
+
Y("headingOne") && /* @__PURE__ */ p(qr, {
|
|
4299
4326
|
format: "headingOne",
|
|
4300
4327
|
icon: M
|
|
4301
4328
|
}),
|
|
4302
|
-
Y("headingTwo") && /* @__PURE__ */ p(
|
|
4329
|
+
Y("headingTwo") && /* @__PURE__ */ p(qr, {
|
|
4303
4330
|
format: "headingTwo",
|
|
4304
4331
|
icon: N
|
|
4305
4332
|
}),
|
|
4306
|
-
Y("blockQuote") && /* @__PURE__ */ p(
|
|
4333
|
+
Y("blockQuote") && /* @__PURE__ */ p(qr, {
|
|
4307
4334
|
format: "blockQuote",
|
|
4308
4335
|
icon: V
|
|
4309
4336
|
}),
|
|
4310
|
-
Y("bold") && /* @__PURE__ */ p(
|
|
4337
|
+
Y("bold") && /* @__PURE__ */ p(ai, {
|
|
4311
4338
|
format: "bold",
|
|
4312
4339
|
icon: b
|
|
4313
4340
|
}),
|
|
4314
|
-
Y("italic") && /* @__PURE__ */ p(
|
|
4341
|
+
Y("italic") && /* @__PURE__ */ p(ai, {
|
|
4315
4342
|
format: "italic",
|
|
4316
4343
|
icon: I
|
|
4317
4344
|
}),
|
|
4318
|
-
Y("underline") && /* @__PURE__ */ p(
|
|
4345
|
+
Y("underline") && /* @__PURE__ */ p(ai, {
|
|
4319
4346
|
format: "underline",
|
|
4320
4347
|
icon: W
|
|
4321
4348
|
}),
|
|
4322
|
-
Y("code") && /* @__PURE__ */ p(
|
|
4349
|
+
Y("code") && /* @__PURE__ */ p(ai, {
|
|
4323
4350
|
format: "code",
|
|
4324
4351
|
icon: E
|
|
4325
4352
|
}),
|
|
4326
|
-
Y("left") && /* @__PURE__ */ p(
|
|
4353
|
+
Y("left") && /* @__PURE__ */ p(qr, {
|
|
4327
4354
|
format: "left",
|
|
4328
4355
|
icon: v
|
|
4329
4356
|
}),
|
|
4330
|
-
Y("right") && /* @__PURE__ */ p(
|
|
4357
|
+
Y("right") && /* @__PURE__ */ p(qr, {
|
|
4331
4358
|
format: "right",
|
|
4332
4359
|
icon: y
|
|
4333
4360
|
}),
|
|
4334
|
-
Y("center") && /* @__PURE__ */ p(
|
|
4361
|
+
Y("center") && /* @__PURE__ */ p(qr, {
|
|
4335
4362
|
format: "center",
|
|
4336
4363
|
icon: g
|
|
4337
4364
|
}),
|
|
4338
|
-
Y("justify") && /* @__PURE__ */ p(
|
|
4365
|
+
Y("justify") && /* @__PURE__ */ p(qr, {
|
|
4339
4366
|
format: "justify",
|
|
4340
4367
|
icon: _
|
|
4341
4368
|
}),
|
|
4342
|
-
r && Y("image") && /* @__PURE__ */ p(
|
|
4343
|
-
Y("video") && /* @__PURE__ */ p(
|
|
4344
|
-
Y("link") && /* @__PURE__ */ p(
|
|
4369
|
+
r && Y("image") && /* @__PURE__ */ p(ei, { ...r }),
|
|
4370
|
+
Y("video") && /* @__PURE__ */ p(ri, { ...a }),
|
|
4371
|
+
Y("link") && /* @__PURE__ */ p(ni, { ...o })
|
|
4345
4372
|
] }),
|
|
4346
4373
|
/* @__PURE__ */ p(he, {
|
|
4347
4374
|
className: "editorContainer",
|
|
@@ -4353,11 +4380,11 @@ function ti(e) {
|
|
|
4353
4380
|
onFocus: () => U(!0),
|
|
4354
4381
|
onBlur: () => U(!1),
|
|
4355
4382
|
onKeyDown: (e) => {
|
|
4356
|
-
(e.key === " " || e.key === "Enter") &&
|
|
4357
|
-
for (let t in
|
|
4383
|
+
(e.key === " " || e.key === "Enter") && Lr(P);
|
|
4384
|
+
for (let t in Vr) if (X(t, e)) {
|
|
4358
4385
|
e.preventDefault();
|
|
4359
|
-
let n =
|
|
4360
|
-
|
|
4386
|
+
let n = Vr[t];
|
|
4387
|
+
Br(P, n);
|
|
4361
4388
|
}
|
|
4362
4389
|
}
|
|
4363
4390
|
}),
|
|
@@ -4370,7 +4397,7 @@ function ti(e) {
|
|
|
4370
4397
|
/* @__PURE__ */ p("input", {
|
|
4371
4398
|
type: "hidden",
|
|
4372
4399
|
name: t,
|
|
4373
|
-
value: z
|
|
4400
|
+
value: z
|
|
4374
4401
|
}),
|
|
4375
4402
|
/* @__PURE__ */ p("input", {
|
|
4376
4403
|
type: "hidden",
|
|
@@ -4383,7 +4410,7 @@ function ti(e) {
|
|
|
4383
4410
|
}
|
|
4384
4411
|
//#endregion
|
|
4385
4412
|
//#region src/components/searchPlaces.tsx
|
|
4386
|
-
function
|
|
4413
|
+
function ci(e) {
|
|
4387
4414
|
let { onChange: t, onPlaceChanged: n, options: r, ...i } = e, [a, o] = u(null);
|
|
4388
4415
|
return /* @__PURE__ */ p(ye, {
|
|
4389
4416
|
onLoad: (e) => o(e),
|
|
@@ -4426,7 +4453,7 @@ function ni(e) {
|
|
|
4426
4453
|
}
|
|
4427
4454
|
},
|
|
4428
4455
|
options: r,
|
|
4429
|
-
children: /* @__PURE__ */ p(
|
|
4456
|
+
children: /* @__PURE__ */ p(ct, {
|
|
4430
4457
|
type: "text",
|
|
4431
4458
|
autoComplete: "off",
|
|
4432
4459
|
onChange: (e) => t?.(e.target.value),
|
|
@@ -4436,12 +4463,12 @@ function ni(e) {
|
|
|
4436
4463
|
}
|
|
4437
4464
|
//#endregion
|
|
4438
4465
|
//#region src/components/switch/index.tsx
|
|
4439
|
-
function
|
|
4466
|
+
function li(e) {
|
|
4440
4467
|
let { label: t, size: n = "lg", defaultChecked: r = !1, checked: i = null, value: a, unCheckedValue: o = "", name: c, className: d = "", onCheck: f, id: m, orientation: h = "horizontalReverse", className: g = "", showAsterisk: _, errorMessage: v, unShowFieldTemplate: y = !1, ...b } = e, x = l(null), S = s(), C = m || S, [w, T] = u(r), E = typeof i == "boolean" ? i : w;
|
|
4441
4468
|
function D() {
|
|
4442
4469
|
T(!w), f?.(E ? o : a || "checked");
|
|
4443
4470
|
}
|
|
4444
|
-
return /* @__PURE__ */ p(
|
|
4471
|
+
return /* @__PURE__ */ p(et, {
|
|
4445
4472
|
name: c,
|
|
4446
4473
|
label: t,
|
|
4447
4474
|
showAsterisk: _,
|
|
@@ -4467,7 +4494,7 @@ function ri(e) {
|
|
|
4467
4494
|
}
|
|
4468
4495
|
//#endregion
|
|
4469
4496
|
//#region src/components/table/tableBody/index.tsx
|
|
4470
|
-
function
|
|
4497
|
+
function ui(t) {
|
|
4471
4498
|
let { emptyMessage: n = "Nenhum dado adicionado.", className: r, children: i, ...a } = t, o = `arkynTableBody ${r}`, s = e.toArray(i).filter(Boolean), c = s.length === 0;
|
|
4472
4499
|
return /* @__PURE__ */ p("tbody", {
|
|
4473
4500
|
className: o.trim(),
|
|
@@ -4483,7 +4510,7 @@ function ii(t) {
|
|
|
4483
4510
|
}
|
|
4484
4511
|
//#endregion
|
|
4485
4512
|
//#region src/components/table/tableCaption/index.tsx
|
|
4486
|
-
function
|
|
4513
|
+
function di(e) {
|
|
4487
4514
|
let { className: t, children: n, ...r } = e;
|
|
4488
4515
|
return /* @__PURE__ */ p("caption", {
|
|
4489
4516
|
className: `arkynTableCaption ${t}`.trim(),
|
|
@@ -4496,7 +4523,7 @@ function ai(e) {
|
|
|
4496
4523
|
}
|
|
4497
4524
|
//#endregion
|
|
4498
4525
|
//#region src/components/table/tableContainer/index.tsx
|
|
4499
|
-
function
|
|
4526
|
+
function fi(e) {
|
|
4500
4527
|
let { children: t, className: n, ...r } = e;
|
|
4501
4528
|
return /* @__PURE__ */ p("div", {
|
|
4502
4529
|
className: `arkynTableContainer ${n}`.trim(),
|
|
@@ -4506,7 +4533,7 @@ function oi(e) {
|
|
|
4506
4533
|
}
|
|
4507
4534
|
//#endregion
|
|
4508
4535
|
//#region src/components/table/tableFooter/index.tsx
|
|
4509
|
-
function
|
|
4536
|
+
function pi(e) {
|
|
4510
4537
|
let { className: t, children: n, ...r } = e;
|
|
4511
4538
|
return /* @__PURE__ */ m("tfoot", {
|
|
4512
4539
|
className: `arkynTableFooter ${t}`.trim(),
|
|
@@ -4522,7 +4549,7 @@ function si(e) {
|
|
|
4522
4549
|
}
|
|
4523
4550
|
//#endregion
|
|
4524
4551
|
//#region src/components/table/tableHeader/index.tsx
|
|
4525
|
-
function
|
|
4552
|
+
function mi(e) {
|
|
4526
4553
|
let { className: t, children: n, ...r } = e;
|
|
4527
4554
|
return /* @__PURE__ */ m("thead", {
|
|
4528
4555
|
className: `arkynTableHeader ${t}`.trim(),
|
|
@@ -4532,7 +4559,7 @@ function ci(e) {
|
|
|
4532
4559
|
}
|
|
4533
4560
|
//#endregion
|
|
4534
4561
|
//#region src/components/textarea/index.tsx
|
|
4535
|
-
function
|
|
4562
|
+
function hi(e) {
|
|
4536
4563
|
let { variant: t = "solid", size: n = "md", className: r, errorMessage: i, disabled: a = !1, readOnly: o = !1, label: c, showAsterisk: d, name: f, onFocus: h, onBlur: g, title: _, style: v, value: y, defaultValue: b, placeholder: x, id: S, ...C } = e, { fieldErrors: w } = Q(), [T, E] = u(!1), D = l(null), O = s(), k = S || O, A = i || w?.[f], j = `arkynTextarea ${t} ${n} ${a || o ? "opacityTrue" : "opacityFalse"} ${A ? "errorTrue" : "errorFalse"} ${T ? "focusedTrue" : "focusedFalse"}`, M = a ? void 0 : y;
|
|
4537
4564
|
function N() {
|
|
4538
4565
|
a || !D?.current || (E(!0), D.current.focus());
|
|
@@ -4576,7 +4603,7 @@ function li(e) {
|
|
|
4576
4603
|
}
|
|
4577
4604
|
//#endregion
|
|
4578
4605
|
//#region src/templates/badResponses.ts
|
|
4579
|
-
var
|
|
4606
|
+
var gi = [
|
|
4580
4607
|
"BadGateway",
|
|
4581
4608
|
"BadRequest",
|
|
4582
4609
|
"Conflict",
|
|
@@ -4586,13 +4613,13 @@ var ui = [
|
|
|
4586
4613
|
"ServerError",
|
|
4587
4614
|
"Unauthorized",
|
|
4588
4615
|
"UnprocessableEntity"
|
|
4589
|
-
],
|
|
4616
|
+
], _i = [
|
|
4590
4617
|
"Created",
|
|
4591
4618
|
"Found",
|
|
4592
4619
|
"Success",
|
|
4593
4620
|
"Updated"
|
|
4594
|
-
],
|
|
4595
|
-
function
|
|
4621
|
+
], vi = n({});
|
|
4622
|
+
function yi(e) {
|
|
4596
4623
|
let { children: t = !1 } = e, [n, r] = u([]), a = i((e) => n.some((t) => t.key === e), [n]), o = i((e) => n.find((t) => t.key === e)?.data, [n]), s = i((e, t) => {
|
|
4597
4624
|
r((n) => [...n.filter((t) => t.key !== e), {
|
|
4598
4625
|
key: e,
|
|
@@ -4615,15 +4642,15 @@ function pi(e) {
|
|
|
4615
4642
|
l,
|
|
4616
4643
|
d
|
|
4617
4644
|
]);
|
|
4618
|
-
return /* @__PURE__ */ p(
|
|
4645
|
+
return /* @__PURE__ */ p(vi.Provider, {
|
|
4619
4646
|
value: f,
|
|
4620
4647
|
children: t
|
|
4621
4648
|
});
|
|
4622
4649
|
}
|
|
4623
4650
|
//#endregion
|
|
4624
4651
|
//#region src/hooks/useModal.ts
|
|
4625
|
-
function
|
|
4626
|
-
let t = a(
|
|
4652
|
+
function bi(e) {
|
|
4653
|
+
let t = a(vi);
|
|
4627
4654
|
if (Object.entries(t).length === 0) throw Error("useModal must be used within a Provider");
|
|
4628
4655
|
if (e) {
|
|
4629
4656
|
let { modalData: n, modalIsOpen: r, openModal: i, closeModal: a } = t;
|
|
@@ -4637,8 +4664,8 @@ function mi(e) {
|
|
|
4637
4664
|
}
|
|
4638
4665
|
//#endregion
|
|
4639
4666
|
//#region src/providers/toastProvider.tsx
|
|
4640
|
-
var
|
|
4641
|
-
function
|
|
4667
|
+
var xi = n({});
|
|
4668
|
+
function Si(e) {
|
|
4642
4669
|
switch (e.type) {
|
|
4643
4670
|
case "success": return Se.success(e.message, {
|
|
4644
4671
|
style: {
|
|
@@ -4668,9 +4695,9 @@ function gi(e) {
|
|
|
4668
4695
|
});
|
|
4669
4696
|
}
|
|
4670
4697
|
}
|
|
4671
|
-
function
|
|
4672
|
-
let t = c(() => ({ showToast:
|
|
4673
|
-
return /* @__PURE__ */ m(
|
|
4698
|
+
function Ci({ children: e }) {
|
|
4699
|
+
let t = c(() => ({ showToast: Si }), []);
|
|
4700
|
+
return /* @__PURE__ */ m(xi.Provider, {
|
|
4674
4701
|
value: t,
|
|
4675
4702
|
children: [/* @__PURE__ */ p(Ce, {
|
|
4676
4703
|
position: "top-right",
|
|
@@ -4680,21 +4707,21 @@ function _i({ children: e }) {
|
|
|
4680
4707
|
}
|
|
4681
4708
|
//#endregion
|
|
4682
4709
|
//#region src/hooks/useToast.ts
|
|
4683
|
-
function
|
|
4684
|
-
let e = a(
|
|
4710
|
+
function wi() {
|
|
4711
|
+
let e = a(xi);
|
|
4685
4712
|
if (Object.entries(e).length === 0) throw Error("useToast must be used within a Provider");
|
|
4686
4713
|
return e;
|
|
4687
4714
|
}
|
|
4688
4715
|
//#endregion
|
|
4689
4716
|
//#region src/hooks/useAutomation.ts
|
|
4690
|
-
function
|
|
4691
|
-
let { closeAll: t } =
|
|
4717
|
+
function Ti(e) {
|
|
4718
|
+
let { closeAll: t } = bi(), { showToast: n } = wi(), r = e?.closeModal, a = e?.message, s = e?.name, c = e?.cause?.data?.scrollTo, l = e?.cause?.fieldErrors ? Object.values(e?.cause?.fieldErrors)[0] : null, u = i(() => {
|
|
4692
4719
|
if (!(!a && !l)) {
|
|
4693
|
-
if (
|
|
4720
|
+
if (_i.includes(s)) return n({
|
|
4694
4721
|
message: a,
|
|
4695
4722
|
type: "success"
|
|
4696
4723
|
});
|
|
4697
|
-
if (
|
|
4724
|
+
if (gi.includes(s)) {
|
|
4698
4725
|
if (l) return n({
|
|
4699
4726
|
message: l,
|
|
4700
4727
|
type: "danger"
|
|
@@ -4725,7 +4752,7 @@ function yi(e) {
|
|
|
4725
4752
|
}
|
|
4726
4753
|
//#endregion
|
|
4727
4754
|
//#region src/hooks/useCopyToClipboard.ts
|
|
4728
|
-
function
|
|
4755
|
+
function Ei(e) {
|
|
4729
4756
|
let t = document.createElement("textarea");
|
|
4730
4757
|
t.value = e, t.style.position = "fixed", t.style.opacity = "0", document.body.appendChild(t), t.select();
|
|
4731
4758
|
try {
|
|
@@ -4734,13 +4761,13 @@ function bi(e) {
|
|
|
4734
4761
|
document.body.removeChild(t);
|
|
4735
4762
|
}
|
|
4736
4763
|
}
|
|
4737
|
-
function
|
|
4764
|
+
function Di() {
|
|
4738
4765
|
async function e(e) {
|
|
4739
4766
|
try {
|
|
4740
4767
|
return await navigator.clipboard.writeText(e), !0;
|
|
4741
4768
|
} catch {
|
|
4742
4769
|
try {
|
|
4743
|
-
return
|
|
4770
|
+
return Ei(e);
|
|
4744
4771
|
} catch {
|
|
4745
4772
|
return !1;
|
|
4746
4773
|
}
|
|
@@ -4750,8 +4777,8 @@ function xi() {
|
|
|
4750
4777
|
}
|
|
4751
4778
|
//#endregion
|
|
4752
4779
|
//#region src/providers/drawerProvider.tsx
|
|
4753
|
-
var
|
|
4754
|
-
function
|
|
4780
|
+
var Oi = n({});
|
|
4781
|
+
function ki(e) {
|
|
4755
4782
|
let { children: t = !1 } = e, [n, r] = u([]);
|
|
4756
4783
|
function i(e) {
|
|
4757
4784
|
return !!n.some((t) => t.key === e);
|
|
@@ -4771,7 +4798,7 @@ function Ci(e) {
|
|
|
4771
4798
|
function s(e) {
|
|
4772
4799
|
r(n.filter((t) => t.key !== e));
|
|
4773
4800
|
}
|
|
4774
|
-
return /* @__PURE__ */ p(
|
|
4801
|
+
return /* @__PURE__ */ p(Oi.Provider, {
|
|
4775
4802
|
value: {
|
|
4776
4803
|
drawerIsOpen: i,
|
|
4777
4804
|
drawerData: a,
|
|
@@ -4783,8 +4810,8 @@ function Ci(e) {
|
|
|
4783
4810
|
}
|
|
4784
4811
|
//#endregion
|
|
4785
4812
|
//#region src/hooks/useDrawer.ts
|
|
4786
|
-
function
|
|
4787
|
-
let t = a(
|
|
4813
|
+
function Ai(e) {
|
|
4814
|
+
let t = a(Oi);
|
|
4788
4815
|
if (Object.entries(t).length === 0) throw Error("useDrawer must be used within a Provider");
|
|
4789
4816
|
if (e) {
|
|
4790
4817
|
let { drawerData: n, drawerIsOpen: r, openDrawer: i, closeDrawer: a } = t;
|
|
@@ -4798,7 +4825,7 @@ function wi(e) {
|
|
|
4798
4825
|
}
|
|
4799
4826
|
//#endregion
|
|
4800
4827
|
//#region src/hooks/useScopedParams.ts
|
|
4801
|
-
function
|
|
4828
|
+
function ji(e, t = "") {
|
|
4802
4829
|
let n = new URLSearchParams(e), r = t ? `${t}:` : "", i = (e) => {
|
|
4803
4830
|
Object.entries(e).forEach(([e, t]) => {
|
|
4804
4831
|
t === void 0 ? n.delete(`${r}${e}`) : n.set(`${r}${e}`, String(t));
|
|
@@ -4815,8 +4842,8 @@ function Ti(e, t = "") {
|
|
|
4815
4842
|
}
|
|
4816
4843
|
//#endregion
|
|
4817
4844
|
//#region src/hooks/useSearchAutomation.ts
|
|
4818
|
-
function
|
|
4819
|
-
let { closeAll: n } =
|
|
4845
|
+
function Mi(e, t = "") {
|
|
4846
|
+
let { closeAll: n } = bi(), { showToast: r } = wi(), { getParam: i } = ji(e, t), a = i("closeModal") === "true", s = i("message"), c = i("name"), l = i("type");
|
|
4820
4847
|
o(() => {
|
|
4821
4848
|
a && n(), s && (l === "success" && r({
|
|
4822
4849
|
message: s,
|
|
@@ -4824,10 +4851,10 @@ function Ei(e, t = "") {
|
|
|
4824
4851
|
}), l === "danger" && r({
|
|
4825
4852
|
message: s,
|
|
4826
4853
|
type: "danger"
|
|
4827
|
-
}), c &&
|
|
4854
|
+
}), c && gi.includes(c) && !gi.includes(s) && r({
|
|
4828
4855
|
message: s,
|
|
4829
4856
|
type: "danger"
|
|
4830
|
-
}), c &&
|
|
4857
|
+
}), c && _i.includes(c) && !_i.includes(s) && r({
|
|
4831
4858
|
message: s,
|
|
4832
4859
|
type: "success"
|
|
4833
4860
|
}));
|
|
@@ -4842,28 +4869,28 @@ function Ei(e, t = "") {
|
|
|
4842
4869
|
}
|
|
4843
4870
|
//#endregion
|
|
4844
4871
|
//#region src/providers/placesProvider.tsx
|
|
4845
|
-
var
|
|
4872
|
+
var Ni = [
|
|
4846
4873
|
"places",
|
|
4847
4874
|
"marker",
|
|
4848
4875
|
"maps"
|
|
4849
4876
|
];
|
|
4850
|
-
function
|
|
4877
|
+
function Pi(e) {
|
|
4851
4878
|
let { apiKey: t, children: n, preventFontsLoading: r = !0 } = e, { isLoaded: i } = be({
|
|
4852
4879
|
googleMapsApiKey: t,
|
|
4853
|
-
libraries:
|
|
4880
|
+
libraries: Ni,
|
|
4854
4881
|
preventGoogleFontsLoading: r
|
|
4855
4882
|
});
|
|
4856
4883
|
return /* @__PURE__ */ p(f, { children: n(i) });
|
|
4857
4884
|
}
|
|
4858
4885
|
//#endregion
|
|
4859
4886
|
//#region src/utils/richTextUtilities.ts
|
|
4860
|
-
function
|
|
4887
|
+
function Fi(e) {
|
|
4861
4888
|
if (de.isText(e)) {
|
|
4862
4889
|
let t = e?.text;
|
|
4863
4890
|
return e?.bold && (t = `<strong>${t}</strong>`), e?.code && (t = `<code>${t}</code>`), e?.italic && (t = `<em>${t}</em>`), e?.underline && (t = `<u>${t}</u>`), e?.link && (t = `<a href="${e.href}">${t}</a>`), t;
|
|
4864
4891
|
}
|
|
4865
4892
|
if (ce.isElement(e)) {
|
|
4866
|
-
let t = e.children?.map((e) =>
|
|
4893
|
+
let t = e.children?.map((e) => Fi(e)).join(""), n = e.align || "left";
|
|
4867
4894
|
switch (e.type) {
|
|
4868
4895
|
case "video": return `<iframe src="${e.src}" class="align_${n}" />`;
|
|
4869
4896
|
case "image": return `<img src="${e.src}" class="align_${n}" />`;
|
|
@@ -4879,10 +4906,10 @@ function ki(e) {
|
|
|
4879
4906
|
}
|
|
4880
4907
|
return "";
|
|
4881
4908
|
}
|
|
4882
|
-
function
|
|
4909
|
+
function Ii(e) {
|
|
4883
4910
|
if (typeof e == "string") return { text: e };
|
|
4884
4911
|
let t = e.props.children, n;
|
|
4885
|
-
n = Array.isArray(t) ? t.map((e) =>
|
|
4912
|
+
n = Array.isArray(t) ? t.map((e) => Ii(e)) : typeof t == "string" || !t ? [{ text: t || "" }] : [Ii(t)];
|
|
4886
4913
|
let r = e.props.className?.replace("align_", "");
|
|
4887
4914
|
switch (e.type) {
|
|
4888
4915
|
case "img": return {
|
|
@@ -4952,16 +4979,16 @@ function Ai(e) {
|
|
|
4952
4979
|
}
|
|
4953
4980
|
//#endregion
|
|
4954
4981
|
//#region src/services/toHtml.ts
|
|
4955
|
-
function
|
|
4956
|
-
return e.map((e) =>
|
|
4982
|
+
function Li(e) {
|
|
4983
|
+
return e.map((e) => Fi(e)).join("");
|
|
4957
4984
|
}
|
|
4958
4985
|
//#endregion
|
|
4959
4986
|
//#region src/services/toRichTextValue.ts
|
|
4960
|
-
function
|
|
4987
|
+
function Ri(e) {
|
|
4961
4988
|
let t = we(e);
|
|
4962
|
-
return Array.isArray(t) ? t.map((e) => typeof e == "string" ? { text: e } :
|
|
4989
|
+
return Array.isArray(t) ? t.map((e) => typeof e == "string" ? { text: e } : Ii(e)) : typeof t == "string" ? [{ text: t }] : [Ii(t)];
|
|
4963
4990
|
}
|
|
4964
4991
|
//#endregion
|
|
4965
|
-
export { Oe as AlertContainer, ke as AlertContent, Ae as AlertDescription, je as AlertIcon, Te as AlertTitle, Pe as AudioPlayer, Ke as AudioUpload, qe as Badge, Be as Button,
|
|
4992
|
+
export { Oe as AlertContainer, ke as AlertContent, Ae as AlertDescription, je as AlertIcon, Te as AlertTitle, Pe as AudioPlayer, Ke as AudioUpload, qe as Badge, Be as Button, vt as Calendar, St as CardTabButton, Ct as CardTabContainer, wt as Checkbox, Dt as ClientOnly, At as CurrencyInput, zt as DatePicker, Ve as Divider, qt as DrawerContainer, Jt as DrawerHeader, ki as DrawerProvider, Zt as FacebookPixel, Le as FieldError, Re as FieldLabel, ze as FieldWrapper, en as FileUpload, Ie as FormProvider, On as FullCalendar, Fn as GoogleAnalytics, Vn as GoogleTagManager, He as IconButton, Wn as ImageUpload, ct as Input, qn as MapView, Yn as MaskedInput, $n as ModalContainer, er as ModalFooter, tr as ModalHeader, yi as ModalProvider, ur as MultiSelect, gr as Pagination, Ar as PhoneInput, Pi as PlacesProvider, jr as Popover, Fr as RadioBox, Ir as RadioGroup, si as RichText, ci as SearchPlaces, ft as Select, Ne as Slider, li as Switch, Qr as TabButton, $r as TabContainer, ui as TableBody, di as TableCaption, fi as TableContainer, pi as TableFooter, mi as TableHeader, hi as Textarea, Ci as ToastProvider, Ue as Tooltip, Li as toHtml, Ri as toRichTextValue, Ti as useAutomation, Di as useCopyToClipboard, Ai as useDrawer, Q as useForm, Et as useHydrated, bi as useModal, ji as useScopedParams, st as useScrollLock, Mi as useSearchAutomation, Me as useSlider, wi as useToast };
|
|
4966
4993
|
|
|
4967
4994
|
//# sourceMappingURL=index.js.map
|