@arkyn/components 3.0.1-beta.145 → 3.0.1-beta.147
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/bundle.css +1 -1
- package/dist/bundle.js +885 -341
- package/dist/components/fullCalendar/_fullCalendarProvider.d.ts +43 -0
- package/dist/components/fullCalendar/_fullCalendarProvider.d.ts.map +1 -0
- package/dist/components/fullCalendar/_fullCalendarProvider.js +35 -0
- package/dist/components/fullCalendar/_viewService.d.ts +28 -0
- package/dist/components/fullCalendar/_viewService.d.ts.map +1 -0
- package/dist/components/fullCalendar/_viewService.js +144 -0
- package/dist/components/fullCalendar/dayCalendar/dayCalendarContainer/index.d.ts +8 -0
- package/dist/components/fullCalendar/dayCalendar/dayCalendarContainer/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/dayCalendar/dayCalendarContainer/index.js +6 -0
- package/dist/components/fullCalendar/dayCalendar/dayCalendarEvent/index.d.ts +7 -0
- package/dist/components/fullCalendar/dayCalendar/dayCalendarEvent/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/dayCalendar/dayCalendarEvent/index.js +105 -0
- package/dist/components/fullCalendar/dayCalendar/dayCalendarRow/index.d.ts +8 -0
- package/dist/components/fullCalendar/dayCalendar/dayCalendarRow/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/dayCalendar/dayCalendarRow/index.js +24 -0
- package/dist/components/fullCalendar/dayCalendar/index.d.ts +3 -0
- package/dist/components/fullCalendar/dayCalendar/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/dayCalendar/index.js +9 -0
- package/dist/components/fullCalendar/fullCalendarContainer/index.d.ts +8 -0
- package/dist/components/fullCalendar/fullCalendarContainer/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/fullCalendarContainer/index.js +6 -0
- package/dist/components/fullCalendar/fullCalendarHeader/index.d.ts +8 -0
- package/dist/components/fullCalendar/fullCalendarHeader/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/fullCalendarHeader/index.js +37 -0
- package/dist/components/fullCalendar/index.d.ts +92 -0
- package/dist/components/fullCalendar/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/index.js +52 -0
- package/dist/components/fullCalendar/monthlyCalendar/index.d.ts +3 -0
- package/dist/components/fullCalendar/monthlyCalendar/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/monthlyCalendar/index.js +8 -0
- package/dist/components/fullCalendar/monthlyCalendar/monthlyCalendarEvent/index.d.ts +9 -0
- package/dist/components/fullCalendar/monthlyCalendar/monthlyCalendarEvent/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/monthlyCalendar/monthlyCalendarEvent/index.js +29 -0
- package/dist/components/fullCalendar/monthlyCalendar/monthlyCalendarTableBody/index.d.ts +4 -0
- package/dist/components/fullCalendar/monthlyCalendar/monthlyCalendarTableBody/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/monthlyCalendar/monthlyCalendarTableBody/index.js +9 -0
- package/dist/components/fullCalendar/monthlyCalendar/monthlyCalendarTableContainer/index.d.ts +8 -0
- package/dist/components/fullCalendar/monthlyCalendar/monthlyCalendarTableContainer/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/monthlyCalendar/monthlyCalendarTableContainer/index.js +6 -0
- package/dist/components/fullCalendar/monthlyCalendar/monthlyCalendarTableHeader/index.d.ts +4 -0
- package/dist/components/fullCalendar/monthlyCalendar/monthlyCalendarTableHeader/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/monthlyCalendar/monthlyCalendarTableHeader/index.js +9 -0
- package/dist/components/fullCalendar/monthlyCalendar/monthlyCalendarTableTd/index.d.ts +10 -0
- package/dist/components/fullCalendar/monthlyCalendar/monthlyCalendarTableTd/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/monthlyCalendar/monthlyCalendarTableTd/index.js +30 -0
- package/dist/components/fullCalendar/weekCalendar/index.d.ts +3 -0
- package/dist/components/fullCalendar/weekCalendar/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/weekCalendar/index.js +8 -0
- package/dist/components/fullCalendar/weekCalendar/weekCalendarEvent/index.d.ts +10 -0
- package/dist/components/fullCalendar/weekCalendar/weekCalendarEvent/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/weekCalendar/weekCalendarEvent/index.js +102 -0
- package/dist/components/fullCalendar/weekCalendar/weekCalendarTableBody/index.d.ts +4 -0
- package/dist/components/fullCalendar/weekCalendar/weekCalendarTableBody/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/weekCalendar/weekCalendarTableBody/index.js +11 -0
- package/dist/components/fullCalendar/weekCalendar/weekCalendarTableContainer/index.d.ts +8 -0
- package/dist/components/fullCalendar/weekCalendar/weekCalendarTableContainer/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/weekCalendar/weekCalendarTableContainer/index.js +6 -0
- package/dist/components/fullCalendar/weekCalendar/weekCalendarTableHeader/index.d.ts +4 -0
- package/dist/components/fullCalendar/weekCalendar/weekCalendarTableHeader/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/weekCalendar/weekCalendarTableHeader/index.js +10 -0
- package/dist/components/fullCalendar/weekCalendar/weekCalendarTableTd/index.d.ts +11 -0
- package/dist/components/fullCalendar/weekCalendar/weekCalendarTableTd/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/weekCalendar/weekCalendarTableTd/index.js +25 -0
- package/dist/components/imageUpload/index.js +1 -1
- package/dist/components/input/index.d.ts.map +1 -1
- package/dist/components/multiSelect/index.js +1 -1
- package/dist/components/radio/radioGroup/index.js +1 -1
- package/dist/components/richText/index.js +1 -1
- package/dist/components/select/index.js +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -0
- package/package.json +7 -7
package/dist/bundle.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Children as e, cloneElement as t, createContext as n, forwardRef as r, useCallback as i, useContext as a, useEffect as o, useId as s, useMemo as c, useRef as l, useState as u, useSyncExternalStore as d } from "react";
|
|
2
2
|
import { Fragment as f, jsx as p, jsxs as m } from "react/jsx-runtime";
|
|
3
3
|
import { AlertTriangle as h, AlignCenter as g, AlignJustify as _, AlignLeft as v, AlignRight as y, Bold as b, Check as x, CheckCircle2 as S, ChevronDown as C, ChevronLeft as w, ChevronRight as T, Code as E, Ellipsis as D, File as O, FileArchive as k, FileAudio as A, FileImage as j, Heading1 as M, Heading2 as N, Image as P, Info as F, Italic as I, Loader2 as L, MapPinned as R, Pause as z, Play as B, Quote as V, RefreshCw as H, Search as U, Underline as W, Video as G, X as K, XCircle as q } from "lucide-react";
|
|
4
|
-
import { findCountryMask as ee, formatToCapitalizeFirstWordLetter as
|
|
4
|
+
import { findCountryMask as ee, formatToCapitalizeFirstWordLetter as J, formatToCurrency as te, formatToPhone as ne, removeNonNumeric as re } from "@arkyn/shared";
|
|
5
5
|
import { AnimatePresence as ie, motion as Y } from "framer-motion";
|
|
6
6
|
import ae from "mapbox-gl";
|
|
7
7
|
import { createRoot as oe } from "react-dom/client";
|
|
@@ -533,7 +533,7 @@ var Ye = class {
|
|
|
533
533
|
return String(e.getFullYear());
|
|
534
534
|
}
|
|
535
535
|
capitalize(e) {
|
|
536
|
-
return
|
|
536
|
+
return J(e);
|
|
537
537
|
}
|
|
538
538
|
parseDayType(e, t, n, r) {
|
|
539
539
|
let i = r[0].getDate(), a = r[0].getMonth(), o = r[0].getFullYear(), s = r[1].getDate(), c = r[1].getMonth(), l = r[1].getFullYear(), u = new Date(o, a, i), d = new Date(l, c, s), f = new Date(n, t, e);
|
|
@@ -694,7 +694,7 @@ function $e({ children: e }) {
|
|
|
694
694
|
}
|
|
695
695
|
//#endregion
|
|
696
696
|
//#region src/services/fieldTemplate.tsx
|
|
697
|
-
function
|
|
697
|
+
function et(e) {
|
|
698
698
|
let { name: t, label: n, showAsterisk: r, className: i, unShowFieldTemplate: a, errorMessage: o, children: s, orientation: c } = e;
|
|
699
699
|
return a ? s : /* @__PURE__ */ m(Ve, {
|
|
700
700
|
id: t,
|
|
@@ -712,7 +712,7 @@ function $(e) {
|
|
|
712
712
|
}
|
|
713
713
|
//#endregion
|
|
714
714
|
//#region src/components/select/selectChevron/index.tsx
|
|
715
|
-
function
|
|
715
|
+
function tt(e) {
|
|
716
716
|
let { iconSize: t, isLoading: n, disabled: r, readOnly: i, isFocused: a } = e;
|
|
717
717
|
return n ? /* @__PURE__ */ p(f, {}) : /* @__PURE__ */ p(C, {
|
|
718
718
|
className: `arkynSelectChevron ${r || i ? "notAnimate" : ""} ${a ? "focused" : ""}`,
|
|
@@ -727,7 +727,7 @@ function et(e) {
|
|
|
727
727
|
}
|
|
728
728
|
//#endregion
|
|
729
729
|
//#region src/components/select/selectContainer/index.tsx
|
|
730
|
-
function
|
|
730
|
+
function nt(e) {
|
|
731
731
|
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 } = e;
|
|
732
732
|
return /* @__PURE__ */ p("section", {
|
|
733
733
|
id: d,
|
|
@@ -738,7 +738,7 @@ function tt(e) {
|
|
|
738
738
|
}
|
|
739
739
|
//#endregion
|
|
740
740
|
//#region src/components/select/selectContent/index.tsx
|
|
741
|
-
function
|
|
741
|
+
function rt(e) {
|
|
742
742
|
let { children: t, size: n } = e;
|
|
743
743
|
return /* @__PURE__ */ p("div", {
|
|
744
744
|
className: `arkynSelectContent ${n}`,
|
|
@@ -747,7 +747,7 @@ function nt(e) {
|
|
|
747
747
|
}
|
|
748
748
|
//#endregion
|
|
749
749
|
//#region src/components/select/selectOption/index.tsx
|
|
750
|
-
function
|
|
750
|
+
function it(e) {
|
|
751
751
|
let { label: t, optionHasSelected: n, handleChangeValue: r, value: i, size: a } = e;
|
|
752
752
|
return /* @__PURE__ */ m("div", {
|
|
753
753
|
onClick: () => r(i),
|
|
@@ -761,13 +761,13 @@ function rt(e) {
|
|
|
761
761
|
}
|
|
762
762
|
//#endregion
|
|
763
763
|
//#region src/hooks/useScrollLock.ts
|
|
764
|
-
function
|
|
764
|
+
function at() {
|
|
765
765
|
return typeof window > "u" ? 0 : window.innerWidth - document.documentElement.clientWidth;
|
|
766
766
|
}
|
|
767
|
-
function
|
|
767
|
+
function ot(e) {
|
|
768
768
|
o(() => {
|
|
769
769
|
if (e) {
|
|
770
|
-
let e = document.body.style.overflow, t = document.body.style.paddingRight, n =
|
|
770
|
+
let e = document.body.style.overflow, t = document.body.style.paddingRight, n = at();
|
|
771
771
|
if (n > 0) {
|
|
772
772
|
let e = window.getComputedStyle(document.body), t = parseInt(e.paddingRight) || 0;
|
|
773
773
|
document.body.style.paddingRight = `${t + n}px`;
|
|
@@ -780,7 +780,7 @@ function at(e) {
|
|
|
780
780
|
}
|
|
781
781
|
//#endregion
|
|
782
782
|
//#region src/components/input/index.tsx
|
|
783
|
-
function
|
|
783
|
+
function st(e) {
|
|
784
784
|
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 } = X(), [M, N] = u(!1), P = l(null), F = E || s(), I = x || j?.[t], R = !!I, z = n || h, B = {
|
|
785
785
|
md: 20,
|
|
786
786
|
lg: 20
|
|
@@ -800,7 +800,7 @@ function ot(e) {
|
|
|
800
800
|
type: "text",
|
|
801
801
|
ref: P,
|
|
802
802
|
...A
|
|
803
|
-
}) : /* @__PURE__ */ p(
|
|
803
|
+
}) : /* @__PURE__ */ p(et, {
|
|
804
804
|
name: t,
|
|
805
805
|
label: o,
|
|
806
806
|
showAsterisk: S,
|
|
@@ -865,9 +865,9 @@ function ot(e) {
|
|
|
865
865
|
}
|
|
866
866
|
//#endregion
|
|
867
867
|
//#region src/components/select/selectOptionsContainer/index.tsx
|
|
868
|
-
function
|
|
868
|
+
function ct(e) {
|
|
869
869
|
let { children: t, isFocused: n, isSearchable: r, search: i, onSearch: a } = e, s = l(null), [c, d] = u("bottom");
|
|
870
|
-
|
|
870
|
+
ot(n), o(() => {
|
|
871
871
|
n && (() => {
|
|
872
872
|
if (!s.current) return;
|
|
873
873
|
let e = s.current.parentElement;
|
|
@@ -882,7 +882,7 @@ function st(e) {
|
|
|
882
882
|
return n ? /* @__PURE__ */ m("div", {
|
|
883
883
|
ref: s,
|
|
884
884
|
className: `arkynSelectOptionsContainer ${c}`,
|
|
885
|
-
children: [r && /* @__PURE__ */ p(
|
|
885
|
+
children: [r && /* @__PURE__ */ p(st, {
|
|
886
886
|
type: "search",
|
|
887
887
|
name: "search-select",
|
|
888
888
|
variant: "underline",
|
|
@@ -894,7 +894,7 @@ function st(e) {
|
|
|
894
894
|
}
|
|
895
895
|
//#endregion
|
|
896
896
|
//#region src/components/select/selectOverlay/index.tsx
|
|
897
|
-
function
|
|
897
|
+
function lt(e) {
|
|
898
898
|
let { isFocused: t, handleBlur: n } = e;
|
|
899
899
|
return t ? /* @__PURE__ */ p("aside", {
|
|
900
900
|
className: "arkynSelectOverlay",
|
|
@@ -903,7 +903,7 @@ function ct(e) {
|
|
|
903
903
|
}
|
|
904
904
|
//#endregion
|
|
905
905
|
//#region src/components/select/selectSpinner/index.tsx
|
|
906
|
-
function
|
|
906
|
+
function ut(e) {
|
|
907
907
|
let { iconSize: t, isLoading: n } = e;
|
|
908
908
|
return n ? /* @__PURE__ */ p(L, {
|
|
909
909
|
className: "arkynSelectSpinner",
|
|
@@ -913,8 +913,8 @@ function lt(e) {
|
|
|
913
913
|
}
|
|
914
914
|
//#endregion
|
|
915
915
|
//#region src/components/select/index.tsx
|
|
916
|
-
function
|
|
917
|
-
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: _, optionMaxHeight: v, showAsterisk: y, leftIcon: b, onSearch: x, onChange: S, onBlur: C, notFoundText: w = "Sem opções disponíveis", onFocus: T, disabled: E = !1, prefix: D, size: O = "md", value: k, variant: A = "solid", orientation: j = "
|
|
916
|
+
function dt(e) {
|
|
917
|
+
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: _, optionMaxHeight: v, showAsterisk: y, leftIcon: b, onSearch: x, onChange: S, onBlur: C, notFoundText: w = "Sem opções disponíveis", onFocus: T, disabled: E = !1, prefix: D, size: O = "md", value: k, variant: A = "solid", orientation: j = "vertical", unShowFieldTemplate: M = !1 } = e, { fieldErrors: N } = X(), P = l(null), F = g || s(), I = c || N?.[t], L = !!I, R = E || d || f, z = {
|
|
918
918
|
md: 20,
|
|
919
919
|
lg: 20
|
|
920
920
|
}[O], [B, V] = u(""), [H, U] = u(!1), [W, G] = u(o), K = k || W;
|
|
@@ -924,20 +924,20 @@ function ut(e) {
|
|
|
924
924
|
function ee(e) {
|
|
925
925
|
return n.find((t) => t.value === e)?.label || "";
|
|
926
926
|
}
|
|
927
|
-
function
|
|
927
|
+
function J() {
|
|
928
928
|
R || !P?.current || H || (U(!0), P.current.focus(), T && T());
|
|
929
929
|
}
|
|
930
|
-
function
|
|
930
|
+
function te() {
|
|
931
931
|
U(!1), C && P.current && P.current.blur();
|
|
932
932
|
}
|
|
933
933
|
function ne(e) {
|
|
934
934
|
V(e), x && x(e);
|
|
935
935
|
}
|
|
936
936
|
function re(e) {
|
|
937
|
-
q(e) ? (G(""), S && S("")) : (G(e), S && S(e)), a &&
|
|
937
|
+
q(e) ? (G(""), S && S("")) : (G(e), S && S(e)), a && te();
|
|
938
938
|
}
|
|
939
939
|
let ie = n.filter((t) => !!(e.onSearch || !e.isSearchable || t.label.toLowerCase().includes(B.toLowerCase())));
|
|
940
|
-
return /* @__PURE__ */ p(
|
|
940
|
+
return /* @__PURE__ */ p(et, {
|
|
941
941
|
name: t,
|
|
942
942
|
label: _,
|
|
943
943
|
showAsterisk: y,
|
|
@@ -945,8 +945,8 @@ function ut(e) {
|
|
|
945
945
|
errorMessage: I,
|
|
946
946
|
unShowFieldTemplate: M,
|
|
947
947
|
orientation: j,
|
|
948
|
-
children: /* @__PURE__ */ m(
|
|
949
|
-
handleContainerFocus:
|
|
948
|
+
children: /* @__PURE__ */ m(nt, {
|
|
949
|
+
handleContainerFocus: J,
|
|
950
950
|
disabled: R,
|
|
951
951
|
isError: L,
|
|
952
952
|
isFocused: H,
|
|
@@ -972,19 +972,19 @@ function ut(e) {
|
|
|
972
972
|
size: z,
|
|
973
973
|
strokeWidth: 2.5
|
|
974
974
|
}),
|
|
975
|
-
/* @__PURE__ */ m(
|
|
975
|
+
/* @__PURE__ */ m(rt, {
|
|
976
976
|
size: O,
|
|
977
977
|
children: [K !== "" && /* @__PURE__ */ p("p", {
|
|
978
978
|
className: "hasValue",
|
|
979
979
|
children: ee(K)
|
|
980
980
|
}), K === "" && /* @__PURE__ */ p("p", { children: i })]
|
|
981
981
|
}),
|
|
982
|
-
/* @__PURE__ */ m(
|
|
982
|
+
/* @__PURE__ */ m(ct, {
|
|
983
983
|
isFocused: H,
|
|
984
984
|
isSearchable: h,
|
|
985
985
|
search: B,
|
|
986
986
|
onSearch: ne,
|
|
987
|
-
children: [ie.map(({ label: e, value: t }) => /* @__PURE__ */ p(
|
|
987
|
+
children: [ie.map(({ label: e, value: t }) => /* @__PURE__ */ p(it, {
|
|
988
988
|
label: e,
|
|
989
989
|
value: t,
|
|
990
990
|
size: O,
|
|
@@ -992,19 +992,19 @@ function ut(e) {
|
|
|
992
992
|
optionHasSelected: q
|
|
993
993
|
}, t)), ie.length <= 0 && /* @__PURE__ */ p("p", { children: w })]
|
|
994
994
|
}),
|
|
995
|
-
/* @__PURE__ */ p(
|
|
995
|
+
/* @__PURE__ */ p(tt, {
|
|
996
996
|
disabled: R,
|
|
997
997
|
isFocused: H,
|
|
998
998
|
readOnly: f,
|
|
999
999
|
iconSize: z,
|
|
1000
1000
|
isLoading: d
|
|
1001
1001
|
}),
|
|
1002
|
-
/* @__PURE__ */ p(
|
|
1002
|
+
/* @__PURE__ */ p(ut, {
|
|
1003
1003
|
iconSize: z,
|
|
1004
1004
|
isLoading: d
|
|
1005
1005
|
}),
|
|
1006
|
-
/* @__PURE__ */ p(
|
|
1007
|
-
handleBlur:
|
|
1006
|
+
/* @__PURE__ */ p(lt, {
|
|
1007
|
+
handleBlur: te,
|
|
1008
1008
|
isFocused: H
|
|
1009
1009
|
})
|
|
1010
1010
|
]
|
|
@@ -1013,7 +1013,7 @@ function ut(e) {
|
|
|
1013
1013
|
}
|
|
1014
1014
|
//#endregion
|
|
1015
1015
|
//#region src/components/calendar/calendarHeader/index.tsx
|
|
1016
|
-
function
|
|
1016
|
+
function ft({ basicMode: e }) {
|
|
1017
1017
|
let t = Ze();
|
|
1018
1018
|
return e ? /* @__PURE__ */ m("div", {
|
|
1019
1019
|
className: "arkynCalendarHeader",
|
|
@@ -1040,14 +1040,14 @@ function dt({ basicMode: e }) {
|
|
|
1040
1040
|
className: "arkynCalendarButton",
|
|
1041
1041
|
onClick: () => t.nextMonth(),
|
|
1042
1042
|
children: /* @__PURE__ */ p(T, {})
|
|
1043
|
-
})] }), /* @__PURE__ */ m("div", { children: [/* @__PURE__ */ p(
|
|
1043
|
+
})] }), /* @__PURE__ */ m("div", { children: [/* @__PURE__ */ p(dt, {
|
|
1044
1044
|
name: "calendarMonth",
|
|
1045
1045
|
variant: "underline",
|
|
1046
1046
|
className: "calendarMonthSelect",
|
|
1047
1047
|
value: t.currentMonth,
|
|
1048
1048
|
options: t.listMonths,
|
|
1049
1049
|
onChange: (e) => t.changeMonth(+e)
|
|
1050
|
-
}), /* @__PURE__ */ p(
|
|
1050
|
+
}), /* @__PURE__ */ p(dt, {
|
|
1051
1051
|
name: "calendarYear",
|
|
1052
1052
|
variant: "underline",
|
|
1053
1053
|
className: "calendarYearSelect",
|
|
@@ -1059,7 +1059,7 @@ function dt({ basicMode: e }) {
|
|
|
1059
1059
|
}
|
|
1060
1060
|
//#endregion
|
|
1061
1061
|
//#region src/components/calendar/calendarTableTd/index.tsx
|
|
1062
|
-
function
|
|
1062
|
+
function pt(e) {
|
|
1063
1063
|
let { day: t, month: n, year: r, dayOwner: i, dayType: a } = e, { changeDay: o } = Ze();
|
|
1064
1064
|
function s() {
|
|
1065
1065
|
let e = /* @__PURE__ */ new Date();
|
|
@@ -1076,15 +1076,15 @@ function ft(e) {
|
|
|
1076
1076
|
}
|
|
1077
1077
|
//#endregion
|
|
1078
1078
|
//#region src/components/calendar/calendarTableBody/index.tsx
|
|
1079
|
-
function
|
|
1079
|
+
function mt() {
|
|
1080
1080
|
return /* @__PURE__ */ p("tbody", {
|
|
1081
1081
|
className: "arkynCalendarTableBody",
|
|
1082
|
-
children: Ze().listMatrix.map((e, t) => /* @__PURE__ */ p("tr", { children: e.map((e, t) => /* @__PURE__ */ p(
|
|
1082
|
+
children: Ze().listMatrix.map((e, t) => /* @__PURE__ */ p("tr", { children: e.map((e, t) => /* @__PURE__ */ p(pt, { ...e }, t)) }, t))
|
|
1083
1083
|
});
|
|
1084
1084
|
}
|
|
1085
1085
|
//#endregion
|
|
1086
1086
|
//#region src/components/calendar/calendarTableContainer/index.tsx
|
|
1087
|
-
function
|
|
1087
|
+
function ht({ children: e }) {
|
|
1088
1088
|
return /* @__PURE__ */ p("table", {
|
|
1089
1089
|
className: "arkynCalendarTableContainer",
|
|
1090
1090
|
children: e
|
|
@@ -1092,47 +1092,47 @@ function mt({ children: e }) {
|
|
|
1092
1092
|
}
|
|
1093
1093
|
//#endregion
|
|
1094
1094
|
//#region src/components/calendar/calendarTableHeader/index.tsx
|
|
1095
|
-
function
|
|
1095
|
+
function gt() {
|
|
1096
1096
|
let { listWeek: e } = Ze();
|
|
1097
1097
|
return /* @__PURE__ */ p("thead", {
|
|
1098
1098
|
className: "arkynCalendarTableHeader",
|
|
1099
|
-
children: /* @__PURE__ */ p("tr", { children: e.map((e, t) => /* @__PURE__ */ p("th", { children:
|
|
1099
|
+
children: /* @__PURE__ */ p("tr", { children: e.map((e, t) => /* @__PURE__ */ p("th", { children: J(e) }, t)) })
|
|
1100
1100
|
});
|
|
1101
1101
|
}
|
|
1102
1102
|
//#endregion
|
|
1103
1103
|
//#region src/components/calendar/index.tsx
|
|
1104
|
-
function
|
|
1104
|
+
function _t(e) {
|
|
1105
1105
|
let t = e.variant || "complete";
|
|
1106
1106
|
return e.type === "range" ? /* @__PURE__ */ p(Qe, {
|
|
1107
1107
|
defaultValue: e.defaultValue,
|
|
1108
1108
|
calendarType: "range",
|
|
1109
1109
|
onChange: e.onChange,
|
|
1110
1110
|
onChangeView: e.onChangeView,
|
|
1111
|
-
children: /* @__PURE__ */ m($e, { children: [/* @__PURE__ */ p(
|
|
1111
|
+
children: /* @__PURE__ */ m($e, { children: [/* @__PURE__ */ p(ft, { basicMode: t.includes("basic") }), /* @__PURE__ */ m(ht, { children: [/* @__PURE__ */ p(gt, {}), /* @__PURE__ */ p(mt, {})] })] })
|
|
1112
1112
|
}) : /* @__PURE__ */ p(Qe, {
|
|
1113
1113
|
defaultValue: e.defaultValue,
|
|
1114
1114
|
calendarType: "single",
|
|
1115
1115
|
onChange: e.onChange,
|
|
1116
1116
|
onChangeView: e.onChangeView,
|
|
1117
|
-
children: /* @__PURE__ */ m($e, { children: [/* @__PURE__ */ p(
|
|
1117
|
+
children: /* @__PURE__ */ m($e, { children: [/* @__PURE__ */ p(ft, { basicMode: t.includes("basic") }), /* @__PURE__ */ m(ht, { children: [/* @__PURE__ */ p(gt, {}), /* @__PURE__ */ p(mt, {})] })] })
|
|
1118
1118
|
});
|
|
1119
1119
|
}
|
|
1120
1120
|
//#endregion
|
|
1121
1121
|
//#region src/components/cardTab/cardTabContext.tsx
|
|
1122
|
-
var
|
|
1123
|
-
function
|
|
1124
|
-
return a(
|
|
1122
|
+
var vt = n({});
|
|
1123
|
+
function yt() {
|
|
1124
|
+
return a(vt);
|
|
1125
1125
|
}
|
|
1126
|
-
function
|
|
1127
|
-
return /* @__PURE__ */ p(
|
|
1126
|
+
function bt(e) {
|
|
1127
|
+
return /* @__PURE__ */ p(vt.Provider, {
|
|
1128
1128
|
value: e,
|
|
1129
1129
|
children: e.children
|
|
1130
1130
|
});
|
|
1131
1131
|
}
|
|
1132
1132
|
//#endregion
|
|
1133
1133
|
//#region src/components/cardTab/cardTabButton/index.tsx
|
|
1134
|
-
function
|
|
1135
|
-
let { children: t, disabled: n = !1, className: r = "", onClick: i, value: a, ...o } = e, { disabled: s, currentTab: c, changeCurrentTab: l } =
|
|
1134
|
+
function xt(e) {
|
|
1135
|
+
let { children: t, disabled: n = !1, className: r = "", onClick: i, value: a, ...o } = e, { disabled: s, currentTab: c, changeCurrentTab: l } = yt(), u = s || n, d = `arkynCardTabButton ${u ? "isDisabled" : ""} ${c === a && a ? "isActive" : ""} ${r}`;
|
|
1136
1136
|
function f(e) {
|
|
1137
1137
|
l(a), i && i(e);
|
|
1138
1138
|
}
|
|
@@ -1147,12 +1147,12 @@ function bt(e) {
|
|
|
1147
1147
|
}
|
|
1148
1148
|
//#endregion
|
|
1149
1149
|
//#region src/components/cardTab/cardTabContainer/index.tsx
|
|
1150
|
-
function
|
|
1150
|
+
function St(e) {
|
|
1151
1151
|
let { children: t, onChange: n, defaultValue: r, disabled: i = !1, className: a, ...o } = e, [s, c] = u(r || ""), l = `arkynCardTabContainer ${a || ""}`;
|
|
1152
1152
|
function d(e) {
|
|
1153
1153
|
c(e), n && n(e);
|
|
1154
1154
|
}
|
|
1155
|
-
return /* @__PURE__ */ p(
|
|
1155
|
+
return /* @__PURE__ */ p(bt, {
|
|
1156
1156
|
disabled: i,
|
|
1157
1157
|
currentTab: s,
|
|
1158
1158
|
changeCurrentTab: d,
|
|
@@ -1165,13 +1165,13 @@ function xt(e) {
|
|
|
1165
1165
|
}
|
|
1166
1166
|
//#endregion
|
|
1167
1167
|
//#region src/components/checkbox/index.tsx
|
|
1168
|
-
function
|
|
1168
|
+
function Ct(e) {
|
|
1169
1169
|
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 } = X(), S = l(null), C = t || s(), w = a || b?.[n], T = !!w, [E, D] = u(o || !1), O = typeof d == "boolean" ? d : E, k = `arkynCheckbox ${i} ${T ? "errorTrue" : "errorFalse"} ${O ? "checkedTrue" : "checkedFalse"}`;
|
|
1170
1170
|
function A() {
|
|
1171
1171
|
let e = E;
|
|
1172
1172
|
D(!e), f && f(e ? "" : v || "checked");
|
|
1173
1173
|
}
|
|
1174
|
-
return /* @__PURE__ */ p(
|
|
1174
|
+
return /* @__PURE__ */ p(et, {
|
|
1175
1175
|
name: n,
|
|
1176
1176
|
label: c,
|
|
1177
1177
|
showAsterisk: g,
|
|
@@ -1196,61 +1196,61 @@ function St(e) {
|
|
|
1196
1196
|
}
|
|
1197
1197
|
//#endregion
|
|
1198
1198
|
//#region src/hooks/useHydrated.ts
|
|
1199
|
-
function
|
|
1199
|
+
function wt() {
|
|
1200
1200
|
return () => {};
|
|
1201
1201
|
}
|
|
1202
|
-
function
|
|
1203
|
-
return d(
|
|
1202
|
+
function Tt() {
|
|
1203
|
+
return d(wt, () => !0, () => !1);
|
|
1204
1204
|
}
|
|
1205
1205
|
//#endregion
|
|
1206
1206
|
//#region src/components/clientOnly.tsx
|
|
1207
|
-
function
|
|
1207
|
+
function Et(e) {
|
|
1208
1208
|
let { children: t, fallback: n = null } = e;
|
|
1209
|
-
return
|
|
1209
|
+
return Tt() ? /* @__PURE__ */ p(f, { children: t() }) : /* @__PURE__ */ p(f, { children: n });
|
|
1210
1210
|
}
|
|
1211
1211
|
//#endregion
|
|
1212
1212
|
//#region src/services/maskCurrencyValues.ts
|
|
1213
|
-
function
|
|
1213
|
+
function Dt(e) {
|
|
1214
1214
|
let t = e;
|
|
1215
1215
|
return typeof e == "string" ? (t = +re(e), t % 1 != 0 && (t = t.toFixed(2))) : t = Number.isInteger(e) ? Number(e) * 10 ** 2 : e.toFixed(2), re(String(t)) / 10 ** 2;
|
|
1216
1216
|
}
|
|
1217
|
-
function
|
|
1218
|
-
if (!e) return [0,
|
|
1219
|
-
let n =
|
|
1220
|
-
return [n,
|
|
1217
|
+
function Ot(e, t) {
|
|
1218
|
+
if (!e) return [0, te(0, t)];
|
|
1219
|
+
let n = Dt(e);
|
|
1220
|
+
return [n, te(n, t)];
|
|
1221
1221
|
}
|
|
1222
1222
|
//#endregion
|
|
1223
1223
|
//#region src/components/currencyInput/index.tsx
|
|
1224
|
-
function
|
|
1224
|
+
function kt(e) {
|
|
1225
1225
|
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 } = X(), [F, I] = u(!1), [R, z] = u("0"), B = l(null), V = M || s(), H = E || P?.[t], U = !!H, W = n || x, G = {
|
|
1226
1226
|
md: 20,
|
|
1227
1227
|
lg: 20
|
|
1228
1228
|
}[j], K = A ? "right" : "left", q = K === "left" && x, ee = K === "right" && x;
|
|
1229
|
-
function
|
|
1229
|
+
function J() {
|
|
1230
1230
|
W || !B?.current || (I(!0), B.current.focus());
|
|
1231
1231
|
}
|
|
1232
|
-
function
|
|
1232
|
+
function te(e) {
|
|
1233
1233
|
I(!0), w && w(e);
|
|
1234
1234
|
}
|
|
1235
1235
|
function ne(e) {
|
|
1236
1236
|
I(!1), T && T(e);
|
|
1237
1237
|
}
|
|
1238
1238
|
let re = (e) => {
|
|
1239
|
-
let [t, n] =
|
|
1240
|
-
return !g || t <= g ? (z(n), [t, n]) :
|
|
1239
|
+
let [t, n] = Ot(e, _);
|
|
1240
|
+
return !g || t <= g ? (z(n), [t, n]) : Ot(e, _);
|
|
1241
1241
|
};
|
|
1242
1242
|
return o(() => {
|
|
1243
1243
|
function e() {
|
|
1244
1244
|
if (typeof f == "number") return f;
|
|
1245
1245
|
if (typeof h == "number") return h;
|
|
1246
1246
|
}
|
|
1247
|
-
let [, t] =
|
|
1247
|
+
let [, t] = Ot(e(), _);
|
|
1248
1248
|
z(t);
|
|
1249
1249
|
}, [
|
|
1250
1250
|
_,
|
|
1251
1251
|
h,
|
|
1252
1252
|
f
|
|
1253
|
-
]), /* @__PURE__ */ p(
|
|
1253
|
+
]), /* @__PURE__ */ p(et, {
|
|
1254
1254
|
name: t,
|
|
1255
1255
|
label: c,
|
|
1256
1256
|
showAsterisk: k,
|
|
@@ -1262,7 +1262,7 @@ function Ot(e) {
|
|
|
1262
1262
|
title: r,
|
|
1263
1263
|
style: i,
|
|
1264
1264
|
className: `arkynCurrencyInput ${y ? "hasPrefix" : ""} ${b ? "hasSuffix" : ""} ${a} ${j} ${W || C || x ? "opacity" : ""} ${U ? "errored" : ""} ${F ? "focused" : ""}`,
|
|
1265
|
-
onClick:
|
|
1265
|
+
onClick: J,
|
|
1266
1266
|
children: [
|
|
1267
1267
|
/* @__PURE__ */ p(Z, {
|
|
1268
1268
|
iconSize: G,
|
|
@@ -1284,7 +1284,7 @@ function Ot(e) {
|
|
|
1284
1284
|
disabled: W,
|
|
1285
1285
|
readOnly: C,
|
|
1286
1286
|
ref: B,
|
|
1287
|
-
onFocus:
|
|
1287
|
+
onFocus: te,
|
|
1288
1288
|
onBlur: ne,
|
|
1289
1289
|
onChange: (e) => {
|
|
1290
1290
|
e.preventDefault();
|
|
@@ -1299,7 +1299,7 @@ function Ot(e) {
|
|
|
1299
1299
|
/* @__PURE__ */ p("input", {
|
|
1300
1300
|
type: "hidden",
|
|
1301
1301
|
name: t,
|
|
1302
|
-
value:
|
|
1302
|
+
value: Dt(R),
|
|
1303
1303
|
readOnly: !0
|
|
1304
1304
|
}),
|
|
1305
1305
|
/* @__PURE__ */ p(Z, {
|
|
@@ -1324,23 +1324,23 @@ function Ot(e) {
|
|
|
1324
1324
|
}
|
|
1325
1325
|
//#endregion
|
|
1326
1326
|
//#region src/components/drawer/drawerContext.tsx
|
|
1327
|
-
var
|
|
1328
|
-
function
|
|
1329
|
-
return /* @__PURE__ */ p(
|
|
1327
|
+
var At = n({});
|
|
1328
|
+
function jt(e) {
|
|
1329
|
+
return /* @__PURE__ */ p(At.Provider, {
|
|
1330
1330
|
value: { makeInvisible: e.makeInvisible },
|
|
1331
1331
|
children: e.children
|
|
1332
1332
|
});
|
|
1333
1333
|
}
|
|
1334
|
-
function
|
|
1335
|
-
return a(
|
|
1334
|
+
function Mt() {
|
|
1335
|
+
return a(At);
|
|
1336
1336
|
}
|
|
1337
1337
|
//#endregion
|
|
1338
1338
|
//#region src/components/drawer/drawerContainer/index.tsx
|
|
1339
|
-
function
|
|
1339
|
+
function Nt(e) {
|
|
1340
1340
|
let { isVisible: t, makeInvisible: n, orientation: r = "left", children: i, className: a, ...o } = e;
|
|
1341
|
-
|
|
1341
|
+
ot(t);
|
|
1342
1342
|
let s = r === "left" ? "-100%" : "100%", c = `arkynDrawerContainer ${r} ${t ? "visibleTrue" : "visibleFalse"} ${a}`;
|
|
1343
|
-
return /* @__PURE__ */ p(
|
|
1343
|
+
return /* @__PURE__ */ p(jt, {
|
|
1344
1344
|
makeInvisible: n,
|
|
1345
1345
|
children: /* @__PURE__ */ p(ie, { children: t && /* @__PURE__ */ m("aside", {
|
|
1346
1346
|
className: c.trim(),
|
|
@@ -1371,8 +1371,8 @@ function Mt(e) {
|
|
|
1371
1371
|
}
|
|
1372
1372
|
//#endregion
|
|
1373
1373
|
//#region src/components/drawer/drawerHeader/index.tsx
|
|
1374
|
-
function
|
|
1375
|
-
let { showCloseButton: t = !0, className: n, children: r, ...i } = e, { makeInvisible: a } =
|
|
1374
|
+
function Pt(e) {
|
|
1375
|
+
let { showCloseButton: t = !0, className: n, children: r, ...i } = e, { makeInvisible: a } = Mt();
|
|
1376
1376
|
return /* @__PURE__ */ m("header", {
|
|
1377
1377
|
className: `arkynDrawerHeader ${n}`.trim(),
|
|
1378
1378
|
...i,
|
|
@@ -1387,7 +1387,7 @@ function Nt(e) {
|
|
|
1387
1387
|
}
|
|
1388
1388
|
//#endregion
|
|
1389
1389
|
//#region src/components/facebookPixel/pixel.ts
|
|
1390
|
-
var
|
|
1390
|
+
var Ft = class {
|
|
1391
1391
|
pixelId;
|
|
1392
1392
|
autoConfig;
|
|
1393
1393
|
initialized;
|
|
@@ -1434,18 +1434,18 @@ var Pt = class {
|
|
|
1434
1434
|
};
|
|
1435
1435
|
//#endregion
|
|
1436
1436
|
//#region src/components/facebookPixel/facebookPixel.client.tsx
|
|
1437
|
-
function
|
|
1438
|
-
let { pixelId: t, options: n, pageView: r, track: i, trackCustom: a, trackSingle: o, trackSingleCustom: s, grantConsent: c, revokeConsent: l } = e, u = new
|
|
1437
|
+
function It(e) {
|
|
1438
|
+
let { pixelId: t, options: n, pageView: r, track: i, trackCustom: a, trackSingle: o, trackSingleCustom: s, grantConsent: c, revokeConsent: l } = e, u = new Ft(t, n);
|
|
1439
1439
|
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), /* @__PURE__ */ p(f, {});
|
|
1440
1440
|
}
|
|
1441
1441
|
//#endregion
|
|
1442
1442
|
//#region src/components/facebookPixel/index.tsx
|
|
1443
|
-
function
|
|
1444
|
-
return process.env.NODE_ENV !== "production" && !e.showInDevMode ? /* @__PURE__ */ p(f, {}) : /* @__PURE__ */ p(
|
|
1443
|
+
function Lt(e) {
|
|
1444
|
+
return process.env.NODE_ENV !== "production" && !e.showInDevMode ? /* @__PURE__ */ p(f, {}) : /* @__PURE__ */ p(Et, { children: () => /* @__PURE__ */ p(It, { ...e }) });
|
|
1445
1445
|
}
|
|
1446
1446
|
//#endregion
|
|
1447
1447
|
//#region src/components/fileUpload/hasFileContent/index.tsx
|
|
1448
|
-
function
|
|
1448
|
+
function Rt(e) {
|
|
1449
1449
|
let { disabled: t, file: n, isLoading: r, acceptFile: i, changeFileButtonText: a, handleSelectFile: o, reSendFile: s } = e;
|
|
1450
1450
|
function c() {
|
|
1451
1451
|
if (t) return;
|
|
@@ -1497,7 +1497,7 @@ function Lt(e) {
|
|
|
1497
1497
|
}
|
|
1498
1498
|
//#endregion
|
|
1499
1499
|
//#region src/components/fileUpload/noFileContent/index.tsx
|
|
1500
|
-
function
|
|
1500
|
+
function zt(e) {
|
|
1501
1501
|
let { dropFileText: t, isLoading: n, acceptFile: r, handleSelectFile: i, selectFileButtonText: a, disabled: o } = e;
|
|
1502
1502
|
function s(e) {
|
|
1503
1503
|
if (o) return;
|
|
@@ -1529,7 +1529,7 @@ function Rt(e) {
|
|
|
1529
1529
|
}
|
|
1530
1530
|
//#endregion
|
|
1531
1531
|
//#region src/components/fileUpload/index.tsx
|
|
1532
|
-
function
|
|
1532
|
+
function Bt(e) {
|
|
1533
1533
|
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: _ } = X(), v = _?.[t], [y, b] = u(""), [x, S] = u(""), [C, w] = u(null), [T, E] = u(!1);
|
|
1534
1534
|
async function D(e) {
|
|
1535
1535
|
if (g) return;
|
|
@@ -1561,7 +1561,7 @@ function zt(e) {
|
|
|
1561
1561
|
name: t,
|
|
1562
1562
|
value: y || ""
|
|
1563
1563
|
}),
|
|
1564
|
-
!C && /* @__PURE__ */ p(
|
|
1564
|
+
!C && /* @__PURE__ */ p(zt, {
|
|
1565
1565
|
disabled: g,
|
|
1566
1566
|
isLoading: T,
|
|
1567
1567
|
acceptFile: s,
|
|
@@ -1569,7 +1569,7 @@ function zt(e) {
|
|
|
1569
1569
|
handleSelectFile: O,
|
|
1570
1570
|
selectFileButtonText: d
|
|
1571
1571
|
}),
|
|
1572
|
-
C && /* @__PURE__ */ p(
|
|
1572
|
+
C && /* @__PURE__ */ p(Rt, {
|
|
1573
1573
|
disabled: g,
|
|
1574
1574
|
isLoading: T,
|
|
1575
1575
|
acceptFile: s,
|
|
@@ -1584,8 +1584,552 @@ function zt(e) {
|
|
|
1584
1584
|
] });
|
|
1585
1585
|
}
|
|
1586
1586
|
//#endregion
|
|
1587
|
+
//#region src/components/fullCalendar/_viewService.ts
|
|
1588
|
+
var Vt = class {
|
|
1589
|
+
capitalize(e) {
|
|
1590
|
+
return J(e);
|
|
1591
|
+
}
|
|
1592
|
+
listHours(e) {
|
|
1593
|
+
let [t, n] = e, r = [];
|
|
1594
|
+
for (let e = t * 60; e <= n * 60; e += 30) r.push(e);
|
|
1595
|
+
return r;
|
|
1596
|
+
}
|
|
1597
|
+
formatHourLabel(e) {
|
|
1598
|
+
let t = Math.floor(e / 60), n = e % 60;
|
|
1599
|
+
return `${String(t).padStart(2, "0")}:${String(n).padStart(2, "0")}`;
|
|
1600
|
+
}
|
|
1601
|
+
getStartOfWeek(e) {
|
|
1602
|
+
let t = new Date(e);
|
|
1603
|
+
return t.setHours(0, 0, 0, 0), t.setDate(t.getDate() - t.getDay()), t;
|
|
1604
|
+
}
|
|
1605
|
+
listWeek(e, t) {
|
|
1606
|
+
let n = [], r = this.getStartOfWeek(e);
|
|
1607
|
+
for (let e = 0; e < 7; e++) {
|
|
1608
|
+
let i = new Date(r);
|
|
1609
|
+
i.setDate(r.getDate() + e);
|
|
1610
|
+
let a = i.toLocaleDateString(t, { weekday: "short" });
|
|
1611
|
+
n.push(a);
|
|
1612
|
+
}
|
|
1613
|
+
return n;
|
|
1614
|
+
}
|
|
1615
|
+
listWeeklyMatrix(e, t) {
|
|
1616
|
+
let n = this.getStartOfWeek(e), r = e.getMonth();
|
|
1617
|
+
return t.map((t) => Array.from({ length: 7 }, (i, a) => {
|
|
1618
|
+
let o = new Date(n);
|
|
1619
|
+
o.setDate(n.getDate() + a);
|
|
1620
|
+
let s = "current";
|
|
1621
|
+
return (o.getMonth() < r || o.getFullYear() < e.getFullYear()) && (s = "previous"), (o.getMonth() > r || o.getFullYear() > e.getFullYear()) && (s = "next"), {
|
|
1622
|
+
day: o.getDate(),
|
|
1623
|
+
month: o.getMonth(),
|
|
1624
|
+
year: o.getFullYear(),
|
|
1625
|
+
dayOwner: s,
|
|
1626
|
+
timeInMinutes: t
|
|
1627
|
+
};
|
|
1628
|
+
}));
|
|
1629
|
+
}
|
|
1630
|
+
listMonthlyMatrix(e) {
|
|
1631
|
+
let t = e.getFullYear(), n = e.getMonth(), r = new Date(t, n, 1).getDay(), i = new Date(t, n + 1, 0).getDate(), a = new Date(t, n, 0).getDate(), o = Math.ceil((r + i) / 7) * 7, s = [], c = 1, l = 1;
|
|
1632
|
+
for (let e = 0; e < o; e++) {
|
|
1633
|
+
let o = Math.floor(e / 7);
|
|
1634
|
+
if (s[o] || (s[o] = []), e < r) {
|
|
1635
|
+
let i = a - (r - e - 1), c = n === 0 ? 11 : n - 1, l = n === 0 ? t - 1 : t;
|
|
1636
|
+
s[o].push({
|
|
1637
|
+
day: i,
|
|
1638
|
+
month: c,
|
|
1639
|
+
year: l,
|
|
1640
|
+
dayOwner: "previous"
|
|
1641
|
+
});
|
|
1642
|
+
} else if (c <= i) s[o].push({
|
|
1643
|
+
day: c,
|
|
1644
|
+
month: n,
|
|
1645
|
+
year: t,
|
|
1646
|
+
dayOwner: "current"
|
|
1647
|
+
}), c++;
|
|
1648
|
+
else {
|
|
1649
|
+
let e = n === 11 ? 0 : n + 1, r = n === 11 ? t + 1 : t;
|
|
1650
|
+
s[o].push({
|
|
1651
|
+
day: l,
|
|
1652
|
+
month: e,
|
|
1653
|
+
year: r,
|
|
1654
|
+
dayOwner: "next"
|
|
1655
|
+
}), l++;
|
|
1656
|
+
}
|
|
1657
|
+
}
|
|
1658
|
+
return s;
|
|
1659
|
+
}
|
|
1660
|
+
nextMonth(e, t) {
|
|
1661
|
+
let n = new Date(e);
|
|
1662
|
+
n.setMonth(n.getMonth() + 1), t(n);
|
|
1663
|
+
}
|
|
1664
|
+
nextWeek(e, t) {
|
|
1665
|
+
let n = new Date(e);
|
|
1666
|
+
n.setDate(n.getDate() + 7), t(n);
|
|
1667
|
+
}
|
|
1668
|
+
nextDay(e, t) {
|
|
1669
|
+
let n = new Date(e);
|
|
1670
|
+
n.setDate(n.getDate() + 1), t(n);
|
|
1671
|
+
}
|
|
1672
|
+
previousMonth(e, t) {
|
|
1673
|
+
let n = new Date(e);
|
|
1674
|
+
n.setMonth(n.getMonth() - 1), t(n);
|
|
1675
|
+
}
|
|
1676
|
+
previousWeek(e, t) {
|
|
1677
|
+
let n = new Date(e);
|
|
1678
|
+
n.setDate(n.getDate() - 7), t(n);
|
|
1679
|
+
}
|
|
1680
|
+
previousDay(e, t) {
|
|
1681
|
+
let n = new Date(e);
|
|
1682
|
+
n.setDate(n.getDate() - 1), t(n);
|
|
1683
|
+
}
|
|
1684
|
+
}, Ht = n({});
|
|
1685
|
+
function $() {
|
|
1686
|
+
return a(Ht);
|
|
1687
|
+
}
|
|
1688
|
+
function Ut(e) {
|
|
1689
|
+
let t = e.language || "pt-BR", n = new Vt(), r = n.listHours([8, 18]), [i, a] = u(e.defaultValue || /* @__PURE__ */ new Date());
|
|
1690
|
+
function o(t) {
|
|
1691
|
+
e.onChangeView && e.onChangeView(t), a(t);
|
|
1692
|
+
}
|
|
1693
|
+
return /* @__PURE__ */ p(Ht.Provider, {
|
|
1694
|
+
value: {
|
|
1695
|
+
events: e.events,
|
|
1696
|
+
blockedTimestamps: e.blockedTimestamps,
|
|
1697
|
+
viewDate: i,
|
|
1698
|
+
listHours: r,
|
|
1699
|
+
listWeek: n.listWeek(i, t),
|
|
1700
|
+
listMonthlyMatrix: n.listMonthlyMatrix(i),
|
|
1701
|
+
listWeeklyMatrix: n.listWeeklyMatrix(i, r),
|
|
1702
|
+
nextMonth: () => n.nextMonth(i, o),
|
|
1703
|
+
nextWeek: () => n.nextWeek(i, o),
|
|
1704
|
+
nextDay: () => n.nextDay(i, o),
|
|
1705
|
+
previousMonth: () => n.previousMonth(i, o),
|
|
1706
|
+
previousWeek: () => n.previousWeek(i, o),
|
|
1707
|
+
previousDay: () => n.previousDay(i, o),
|
|
1708
|
+
onClickDate: e.onClickDate
|
|
1709
|
+
},
|
|
1710
|
+
children: e.children
|
|
1711
|
+
});
|
|
1712
|
+
}
|
|
1713
|
+
//#endregion
|
|
1714
|
+
//#region src/components/fullCalendar/dayCalendar/dayCalendarContainer/index.tsx
|
|
1715
|
+
function Wt({ children: e }) {
|
|
1716
|
+
return /* @__PURE__ */ p("div", {
|
|
1717
|
+
className: "arkynDayCalendarContainer",
|
|
1718
|
+
children: e
|
|
1719
|
+
});
|
|
1720
|
+
}
|
|
1721
|
+
//#endregion
|
|
1722
|
+
//#region src/components/fullCalendar/dayCalendar/dayCalendarEvent/index.tsx
|
|
1723
|
+
var Gt = 30, Kt = 205;
|
|
1724
|
+
function qt(e) {
|
|
1725
|
+
let { events: t, viewDate: n } = $(), r = n.getDate(), i = n.getMonth(), a = n.getFullYear(), o = t.map((e, t) => ({
|
|
1726
|
+
event: e,
|
|
1727
|
+
sourceIndex: t
|
|
1728
|
+
})).filter(({ event: e }) => e.initialDate.getDate() === r && e.initialDate.getMonth() === i && e.initialDate.getFullYear() === a).sort((e, t) => {
|
|
1729
|
+
let n = e.event.initialDate.getTime(), r = t.event.initialDate.getTime();
|
|
1730
|
+
if (n !== r) return n - r;
|
|
1731
|
+
let i = e.event.endDate?.getTime() ?? n + Gt * 6e4, a = t.event.endDate?.getTime() ?? r + Gt * 6e4;
|
|
1732
|
+
return i === a ? e.sourceIndex - t.sourceIndex : i - a;
|
|
1733
|
+
}), s = new Map(o.map((e, t) => [e.sourceIndex, t])), c = o.filter(({ event: t }) => {
|
|
1734
|
+
let n = Math.floor(e.timeInMinutes / 60), o = e.timeInMinutes % 60;
|
|
1735
|
+
function s() {
|
|
1736
|
+
let e = t.initialDate.getHours(), r = t.initialDate.getMinutes();
|
|
1737
|
+
if (e !== n) return !1;
|
|
1738
|
+
if (o === 0) return r < 30 && r >= 0;
|
|
1739
|
+
if (o === 30) return r >= 30 && r < 60;
|
|
1740
|
+
}
|
|
1741
|
+
return s() && t.initialDate.getDate() === r && t.initialDate.getMonth() === i && t.initialDate.getFullYear() === a;
|
|
1742
|
+
});
|
|
1743
|
+
if (c.length === 0) return /* @__PURE__ */ p(f, {});
|
|
1744
|
+
function l(e, t) {
|
|
1745
|
+
return `${r}-${i}-${a}-${t}-${e}`;
|
|
1746
|
+
}
|
|
1747
|
+
function u(e) {
|
|
1748
|
+
let t = e.getHours(), n = e.getMinutes();
|
|
1749
|
+
return n === 0 ? `${t}h` : `${t}h${n}`;
|
|
1750
|
+
}
|
|
1751
|
+
function d(e) {
|
|
1752
|
+
let t = e.initialDate.getHours() * 60 + e.initialDate.getMinutes(), n = e.endDate ? e.endDate.getHours() * 60 + e.endDate.getMinutes() : t + Gt;
|
|
1753
|
+
return {
|
|
1754
|
+
startMinutes: t,
|
|
1755
|
+
endMinutes: Math.max(n, t + 1)
|
|
1756
|
+
};
|
|
1757
|
+
}
|
|
1758
|
+
function h(e, t) {
|
|
1759
|
+
let n = d(e), r = s.get(t);
|
|
1760
|
+
return r == null ? 0 : o.reduce((e, t, i) => {
|
|
1761
|
+
if (i >= r) return e;
|
|
1762
|
+
let a = d(t.event);
|
|
1763
|
+
return a.startMinutes < n.endMinutes && a.endMinutes > n.startMinutes ? e + 1 : e;
|
|
1764
|
+
}, 0);
|
|
1765
|
+
}
|
|
1766
|
+
function g(t, n) {
|
|
1767
|
+
let { startMinutes: r, endMinutes: i } = d(t), a = r - e.timeInMinutes, o = Math.max(i - r, 1), s = a / Gt * 100, c = o / Gt * 100, l = h(t, n) * Kt;
|
|
1768
|
+
return {
|
|
1769
|
+
top: `${s}%`,
|
|
1770
|
+
height: `${c}%`,
|
|
1771
|
+
left: `${l}px`
|
|
1772
|
+
};
|
|
1773
|
+
}
|
|
1774
|
+
function _(e, t) {
|
|
1775
|
+
e.stopPropagation(), t.onClick?.(t.data);
|
|
1776
|
+
}
|
|
1777
|
+
return c.map(({ event: e, sourceIndex: t }, n) => /* @__PURE__ */ m("div", {
|
|
1778
|
+
className: `arkynDayCalendarEvent ${e?.scheme || "primary"}`,
|
|
1779
|
+
style: g(e, t),
|
|
1780
|
+
onClick: (t) => _(t, e),
|
|
1781
|
+
children: [/* @__PURE__ */ m("strong", { children: [
|
|
1782
|
+
u(e.initialDate),
|
|
1783
|
+
" ",
|
|
1784
|
+
e?.endDate && `- ${u(e.endDate)}`
|
|
1785
|
+
] }), /* @__PURE__ */ p("p", { children: e.title })]
|
|
1786
|
+
}, l(n, t)));
|
|
1787
|
+
}
|
|
1788
|
+
//#endregion
|
|
1789
|
+
//#region src/components/fullCalendar/dayCalendar/dayCalendarRow/index.tsx
|
|
1790
|
+
function Jt({ hour: e, timeInMinutes: t }) {
|
|
1791
|
+
let n = new Vt(), { blockedTimestamps: r, viewDate: i, onClickDate: a } = $();
|
|
1792
|
+
function o() {
|
|
1793
|
+
return r.some((e) => i >= e.initialDate && i <= e.endDate);
|
|
1794
|
+
}
|
|
1795
|
+
function s(e) {
|
|
1796
|
+
if (e.stopPropagation(), !o() && a) {
|
|
1797
|
+
let e = new Date(i);
|
|
1798
|
+
e.setHours(0, t, 0, 0), a(e);
|
|
1799
|
+
}
|
|
1800
|
+
}
|
|
1801
|
+
return /* @__PURE__ */ m("div", {
|
|
1802
|
+
className: `arkynDayCalendarRow ${o() ? "blocked" : ""}`,
|
|
1803
|
+
"data-time": t,
|
|
1804
|
+
onClick: s,
|
|
1805
|
+
children: [/* @__PURE__ */ p("p", { children: n.formatHourLabel(e) }), /* @__PURE__ */ p("div", {
|
|
1806
|
+
className: "arkynDayCalendarRowContent",
|
|
1807
|
+
children: /* @__PURE__ */ p(qt, { timeInMinutes: t })
|
|
1808
|
+
})]
|
|
1809
|
+
});
|
|
1810
|
+
}
|
|
1811
|
+
//#endregion
|
|
1812
|
+
//#region src/components/fullCalendar/dayCalendar/index.tsx
|
|
1813
|
+
function Yt() {
|
|
1814
|
+
let { listHours: e } = $();
|
|
1815
|
+
return /* @__PURE__ */ p(Wt, { children: e.map((e) => /* @__PURE__ */ p(Jt, {
|
|
1816
|
+
hour: e,
|
|
1817
|
+
timeInMinutes: e
|
|
1818
|
+
})) });
|
|
1819
|
+
}
|
|
1820
|
+
//#endregion
|
|
1821
|
+
//#region src/components/fullCalendar/fullCalendarContainer/index.tsx
|
|
1822
|
+
function Xt({ children: e }) {
|
|
1823
|
+
return /* @__PURE__ */ p("div", {
|
|
1824
|
+
className: "arkynFullCalendarContainer",
|
|
1825
|
+
children: e
|
|
1826
|
+
});
|
|
1827
|
+
}
|
|
1828
|
+
//#endregion
|
|
1829
|
+
//#region src/components/fullCalendar/fullCalendarHeader/index.tsx
|
|
1830
|
+
function Zt(e) {
|
|
1831
|
+
let { setViewType: t, viewType: n } = e, r = $();
|
|
1832
|
+
function i() {
|
|
1833
|
+
switch (n) {
|
|
1834
|
+
case "day": return r.previousDay();
|
|
1835
|
+
case "week": return r.previousWeek();
|
|
1836
|
+
case "month": return r.previousMonth();
|
|
1837
|
+
}
|
|
1838
|
+
}
|
|
1839
|
+
function a() {
|
|
1840
|
+
switch (n) {
|
|
1841
|
+
case "day": return r.nextDay();
|
|
1842
|
+
case "week": return r.nextWeek();
|
|
1843
|
+
case "month": return r.nextMonth();
|
|
1844
|
+
}
|
|
1845
|
+
}
|
|
1846
|
+
return /* @__PURE__ */ m("div", {
|
|
1847
|
+
className: "arkynFullCalendarHeader",
|
|
1848
|
+
children: [/* @__PURE__ */ m(St, {
|
|
1849
|
+
defaultValue: n,
|
|
1850
|
+
onChange: (e) => t(e),
|
|
1851
|
+
children: [
|
|
1852
|
+
/* @__PURE__ */ p(xt, {
|
|
1853
|
+
value: "day",
|
|
1854
|
+
children: "Dia"
|
|
1855
|
+
}),
|
|
1856
|
+
/* @__PURE__ */ p(xt, {
|
|
1857
|
+
value: "week",
|
|
1858
|
+
children: "Semana"
|
|
1859
|
+
}),
|
|
1860
|
+
/* @__PURE__ */ p(xt, {
|
|
1861
|
+
value: "month",
|
|
1862
|
+
children: "Mês"
|
|
1863
|
+
})
|
|
1864
|
+
]
|
|
1865
|
+
}), /* @__PURE__ */ m("div", {
|
|
1866
|
+
className: "arkynFullCalendarHeaderActions",
|
|
1867
|
+
children: [
|
|
1868
|
+
/* @__PURE__ */ p(Ue, {
|
|
1869
|
+
variant: "outline",
|
|
1870
|
+
icon: w,
|
|
1871
|
+
"aria-label": "Handle previous",
|
|
1872
|
+
onClick: () => i()
|
|
1873
|
+
}),
|
|
1874
|
+
/* @__PURE__ */ p("p", { children: r.viewDate.toLocaleDateString("pt-BR", {
|
|
1875
|
+
day: "2-digit",
|
|
1876
|
+
month: "long",
|
|
1877
|
+
year: "numeric"
|
|
1878
|
+
}) }),
|
|
1879
|
+
/* @__PURE__ */ p(Ue, {
|
|
1880
|
+
variant: "outline",
|
|
1881
|
+
icon: T,
|
|
1882
|
+
"aria-label": "Handle next",
|
|
1883
|
+
onClick: () => a()
|
|
1884
|
+
})
|
|
1885
|
+
]
|
|
1886
|
+
})]
|
|
1887
|
+
});
|
|
1888
|
+
}
|
|
1889
|
+
//#endregion
|
|
1890
|
+
//#region src/components/fullCalendar/monthlyCalendar/monthlyCalendarEvent/index.tsx
|
|
1891
|
+
function Qt(e) {
|
|
1892
|
+
let { events: t } = $(), n = t.filter((t) => t.initialDate.getDate() === e.day && t.initialDate.getMonth() === e.month && t.initialDate.getFullYear() === e.year);
|
|
1893
|
+
if (n.length === 0) return /* @__PURE__ */ p(f, {});
|
|
1894
|
+
function r(t) {
|
|
1895
|
+
return `${e.day}-${e.month}-${e.year}-${t}`;
|
|
1896
|
+
}
|
|
1897
|
+
function i(e) {
|
|
1898
|
+
let t = e.getHours(), n = e.getMinutes();
|
|
1899
|
+
return n === 0 ? `${t}h` : `${t}h${n}`;
|
|
1900
|
+
}
|
|
1901
|
+
function a(e, t) {
|
|
1902
|
+
e.stopPropagation(), t.onClick?.(t.data);
|
|
1903
|
+
}
|
|
1904
|
+
return n.map((e, t) => /* @__PURE__ */ m("div", {
|
|
1905
|
+
className: `arkynMonthlyCalendarEvent ${e?.scheme || "primary"}`,
|
|
1906
|
+
onClick: (t) => a(t, e),
|
|
1907
|
+
children: [/* @__PURE__ */ m("strong", { children: [
|
|
1908
|
+
i(e.initialDate),
|
|
1909
|
+
" ",
|
|
1910
|
+
e?.endDate && `- ${i(e.endDate)}`
|
|
1911
|
+
] }), /* @__PURE__ */ p("p", { children: e.title })]
|
|
1912
|
+
}, r(t)));
|
|
1913
|
+
}
|
|
1914
|
+
//#endregion
|
|
1915
|
+
//#region src/components/fullCalendar/monthlyCalendar/monthlyCalendarTableTd/index.tsx
|
|
1916
|
+
function $t(e) {
|
|
1917
|
+
let { day: t, month: n, year: r, dayOwner: i } = e, { blockedTimestamps: a, onClickDate: o } = $();
|
|
1918
|
+
function s() {
|
|
1919
|
+
let e = /* @__PURE__ */ new Date();
|
|
1920
|
+
return t === e.getDate() && n === e.getMonth() && r === e.getFullYear();
|
|
1921
|
+
}
|
|
1922
|
+
function c() {
|
|
1923
|
+
let e = new Date(r, n, t);
|
|
1924
|
+
return a.some((t) => e >= t.initialDate && e <= t.endDate);
|
|
1925
|
+
}
|
|
1926
|
+
function l(e) {
|
|
1927
|
+
e.stopPropagation(), !c() && o && o(new Date(r, n, t));
|
|
1928
|
+
}
|
|
1929
|
+
return /* @__PURE__ */ m("td", {
|
|
1930
|
+
className: `arkynMonthlyCalendarTableTd ${i} ${c() ? "blocked" : ""}`,
|
|
1931
|
+
onClick: l,
|
|
1932
|
+
children: [/* @__PURE__ */ p("p", {
|
|
1933
|
+
className: s() ? "today" : "",
|
|
1934
|
+
children: t
|
|
1935
|
+
}), /* @__PURE__ */ p("div", {
|
|
1936
|
+
className: "arkynMonthlyCalendarEventContainer",
|
|
1937
|
+
children: /* @__PURE__ */ p(Qt, {
|
|
1938
|
+
day: t,
|
|
1939
|
+
month: n,
|
|
1940
|
+
year: r
|
|
1941
|
+
})
|
|
1942
|
+
})]
|
|
1943
|
+
});
|
|
1944
|
+
}
|
|
1945
|
+
//#endregion
|
|
1946
|
+
//#region src/components/fullCalendar/monthlyCalendar/monthlyCalendarTableBody/index.tsx
|
|
1947
|
+
function en() {
|
|
1948
|
+
return /* @__PURE__ */ p("tbody", {
|
|
1949
|
+
className: "arkynMonthlyCalendarTableBody",
|
|
1950
|
+
children: $().listMonthlyMatrix.map((e, t) => /* @__PURE__ */ p("tr", { children: e.map((e, t) => /* @__PURE__ */ p($t, { ...e }, t)) }, t))
|
|
1951
|
+
});
|
|
1952
|
+
}
|
|
1953
|
+
//#endregion
|
|
1954
|
+
//#region src/components/fullCalendar/monthlyCalendar/monthlyCalendarTableContainer/index.tsx
|
|
1955
|
+
function tn({ children: e }) {
|
|
1956
|
+
return /* @__PURE__ */ p("div", {
|
|
1957
|
+
className: "arkynMonthlyCalendarTableContainer",
|
|
1958
|
+
children: /* @__PURE__ */ p("table", { children: e })
|
|
1959
|
+
});
|
|
1960
|
+
}
|
|
1961
|
+
//#endregion
|
|
1962
|
+
//#region src/components/fullCalendar/monthlyCalendar/monthlyCalendarTableHeader/index.tsx
|
|
1963
|
+
function nn() {
|
|
1964
|
+
let { listWeek: e } = $();
|
|
1965
|
+
return /* @__PURE__ */ p("thead", {
|
|
1966
|
+
className: "arkynMonthlyCalendarTableHeader",
|
|
1967
|
+
children: /* @__PURE__ */ p("tr", { children: e.map((e, t) => /* @__PURE__ */ p("th", { children: J(e) }, t)) })
|
|
1968
|
+
});
|
|
1969
|
+
}
|
|
1970
|
+
//#endregion
|
|
1971
|
+
//#region src/components/fullCalendar/monthlyCalendar/index.tsx
|
|
1972
|
+
function rn() {
|
|
1973
|
+
return /* @__PURE__ */ m(tn, { children: [/* @__PURE__ */ p(nn, {}), /* @__PURE__ */ p(en, {})] });
|
|
1974
|
+
}
|
|
1975
|
+
//#endregion
|
|
1976
|
+
//#region src/components/fullCalendar/weekCalendar/weekCalendarEvent/index.tsx
|
|
1977
|
+
var an = 30, on = 40;
|
|
1978
|
+
function sn(e) {
|
|
1979
|
+
let { events: t } = $(), n = t.map((e, t) => ({
|
|
1980
|
+
event: e,
|
|
1981
|
+
sourceIndex: t
|
|
1982
|
+
})).filter(({ event: t }) => t.initialDate.getDate() === e.day && t.initialDate.getMonth() === e.month && t.initialDate.getFullYear() === e.year).sort((e, t) => {
|
|
1983
|
+
let n = e.event.initialDate.getTime(), r = t.event.initialDate.getTime();
|
|
1984
|
+
if (n !== r) return n - r;
|
|
1985
|
+
let i = e.event.endDate?.getTime() ?? n + an * 6e4, a = t.event.endDate?.getTime() ?? r + an * 6e4;
|
|
1986
|
+
return i === a ? e.sourceIndex - t.sourceIndex : i - a;
|
|
1987
|
+
}), r = new Map(n.map((e, t) => [e.sourceIndex, t])), i = n.filter(({ event: t }) => {
|
|
1988
|
+
let n = Math.floor(e.timeInMinutes / 60), r = e.timeInMinutes % 60;
|
|
1989
|
+
function i() {
|
|
1990
|
+
let e = t.initialDate.getHours(), i = t.initialDate.getMinutes();
|
|
1991
|
+
if (e !== n) return !1;
|
|
1992
|
+
if (r === 0) return i < 30 && i >= 0;
|
|
1993
|
+
if (r === 30) return i >= 30 && i < 60;
|
|
1994
|
+
}
|
|
1995
|
+
return i() && t.initialDate.getDate() === e.day && t.initialDate.getMonth() === e.month && t.initialDate.getFullYear() === e.year;
|
|
1996
|
+
});
|
|
1997
|
+
if (i.length === 0) return /* @__PURE__ */ p(f, {});
|
|
1998
|
+
function a(t, n) {
|
|
1999
|
+
return `${e.day}-${e.month}-${e.year}-${n}-${t}`;
|
|
2000
|
+
}
|
|
2001
|
+
function o(e) {
|
|
2002
|
+
let t = e.getHours(), n = e.getMinutes();
|
|
2003
|
+
return n === 0 ? `${t}h` : `${t}h${n}`;
|
|
2004
|
+
}
|
|
2005
|
+
function s(e) {
|
|
2006
|
+
let t = e.initialDate.getHours() * 60 + e.initialDate.getMinutes(), n = e.endDate ? e.endDate.getHours() * 60 + e.endDate.getMinutes() : t + an;
|
|
2007
|
+
return {
|
|
2008
|
+
startMinutes: t,
|
|
2009
|
+
endMinutes: Math.max(n, t + 1)
|
|
2010
|
+
};
|
|
2011
|
+
}
|
|
2012
|
+
function c(e, t) {
|
|
2013
|
+
let i = s(e), a = r.get(t);
|
|
2014
|
+
return a == null ? 0 : n.reduce((e, t, n) => {
|
|
2015
|
+
if (n >= a) return e;
|
|
2016
|
+
let r = s(t.event);
|
|
2017
|
+
return r.startMinutes < i.endMinutes && r.endMinutes > i.startMinutes ? e + 1 : e;
|
|
2018
|
+
}, 0);
|
|
2019
|
+
}
|
|
2020
|
+
function l(t, n) {
|
|
2021
|
+
let { startMinutes: r, endMinutes: i } = s(t), a = r - e.timeInMinutes, o = Math.max(i - r, 1), l = a / an * 100, u = o / an * 100, d = c(t, n) * on;
|
|
2022
|
+
return {
|
|
2023
|
+
top: `${l}%`,
|
|
2024
|
+
height: `${u}%`,
|
|
2025
|
+
left: `${d}px`
|
|
2026
|
+
};
|
|
2027
|
+
}
|
|
2028
|
+
function u(e, t) {
|
|
2029
|
+
e.stopPropagation(), t.onClick?.(t.data);
|
|
2030
|
+
}
|
|
2031
|
+
return i.map(({ event: e, sourceIndex: t }, n) => /* @__PURE__ */ m("div", {
|
|
2032
|
+
className: `arkynWeekCalendarEvent ${e?.scheme || "primary"}`,
|
|
2033
|
+
style: l(e, t),
|
|
2034
|
+
onClick: (t) => u(t, e),
|
|
2035
|
+
children: [/* @__PURE__ */ m("strong", { children: [
|
|
2036
|
+
o(e.initialDate),
|
|
2037
|
+
" ",
|
|
2038
|
+
e?.endDate && `- ${o(e.endDate)}`
|
|
2039
|
+
] }), /* @__PURE__ */ p("p", { children: e.title })]
|
|
2040
|
+
}, a(n, t)));
|
|
2041
|
+
}
|
|
2042
|
+
//#endregion
|
|
2043
|
+
//#region src/components/fullCalendar/weekCalendar/weekCalendarTableTd/index.tsx
|
|
2044
|
+
function cn(e) {
|
|
2045
|
+
let { day: t, month: n, year: r, dayOwner: i, timeInMinutes: a } = e, { blockedTimestamps: o, onClickDate: s } = $();
|
|
2046
|
+
function c() {
|
|
2047
|
+
let e = new Date(r, n, t);
|
|
2048
|
+
return o.some((t) => e >= t.initialDate && e <= t.endDate);
|
|
2049
|
+
}
|
|
2050
|
+
function l(e) {
|
|
2051
|
+
if (e.stopPropagation(), !c() && s) {
|
|
2052
|
+
let e = new Date(r, n, t);
|
|
2053
|
+
e.setHours(0, a, 0, 0), s(e);
|
|
2054
|
+
}
|
|
2055
|
+
}
|
|
2056
|
+
return /* @__PURE__ */ p("td", {
|
|
2057
|
+
className: `arkynWeekCalendarTableTd ${i} ${c() ? "blocked" : ""}`,
|
|
2058
|
+
"data-day": t,
|
|
2059
|
+
"data-time": a,
|
|
2060
|
+
onClick: l,
|
|
2061
|
+
children: /* @__PURE__ */ p("div", {
|
|
2062
|
+
className: "arkynWeekCalendarTableTdContent",
|
|
2063
|
+
children: /* @__PURE__ */ p(sn, {
|
|
2064
|
+
day: t,
|
|
2065
|
+
month: n,
|
|
2066
|
+
year: r,
|
|
2067
|
+
timeInMinutes: a
|
|
2068
|
+
})
|
|
2069
|
+
})
|
|
2070
|
+
});
|
|
2071
|
+
}
|
|
2072
|
+
//#endregion
|
|
2073
|
+
//#region src/components/fullCalendar/weekCalendar/weekCalendarTableBody/index.tsx
|
|
2074
|
+
function ln() {
|
|
2075
|
+
let e = $(), t = new Vt();
|
|
2076
|
+
return /* @__PURE__ */ p("tbody", {
|
|
2077
|
+
className: "arkynWeekCalendarTableBody",
|
|
2078
|
+
children: e.listWeeklyMatrix.map((e) => /* @__PURE__ */ m("tr", { children: [/* @__PURE__ */ p("td", {
|
|
2079
|
+
className: "hourTd",
|
|
2080
|
+
children: /* @__PURE__ */ p("p", { children: t.formatHourLabel(e[0].timeInMinutes) })
|
|
2081
|
+
}), e.map((e, t) => /* @__PURE__ */ p(cn, { ...e }, `${e.year}-${e.month}-${e.day}-${e.timeInMinutes}-${t}`))] }, e[0].timeInMinutes))
|
|
2082
|
+
});
|
|
2083
|
+
}
|
|
2084
|
+
//#endregion
|
|
2085
|
+
//#region src/components/fullCalendar/weekCalendar/weekCalendarTableContainer/index.tsx
|
|
2086
|
+
function un({ children: e }) {
|
|
2087
|
+
return /* @__PURE__ */ p("div", {
|
|
2088
|
+
className: "arkynWeekCalendarTableContainer",
|
|
2089
|
+
children: /* @__PURE__ */ p("table", { children: e })
|
|
2090
|
+
});
|
|
2091
|
+
}
|
|
2092
|
+
//#endregion
|
|
2093
|
+
//#region src/components/fullCalendar/weekCalendar/weekCalendarTableHeader/index.tsx
|
|
2094
|
+
function dn() {
|
|
2095
|
+
let { listWeek: e, listWeeklyMatrix: t } = $(), n = t[0] || [];
|
|
2096
|
+
return /* @__PURE__ */ p("thead", {
|
|
2097
|
+
className: "arkynWeekCalendarTableHeader",
|
|
2098
|
+
children: /* @__PURE__ */ m("tr", { children: [/* @__PURE__ */ p("th", {}), e.map((e, t) => /* @__PURE__ */ p("th", { children: /* @__PURE__ */ m("div", {
|
|
2099
|
+
className: "arkynWeekCalendarTableHeaderContent",
|
|
2100
|
+
children: [/* @__PURE__ */ p("span", { children: J(e) }), /* @__PURE__ */ p("strong", { children: n[t]?.day })]
|
|
2101
|
+
}) }, t))] })
|
|
2102
|
+
});
|
|
2103
|
+
}
|
|
2104
|
+
//#endregion
|
|
2105
|
+
//#region src/components/fullCalendar/weekCalendar/index.tsx
|
|
2106
|
+
function fn() {
|
|
2107
|
+
return /* @__PURE__ */ m(un, { children: [/* @__PURE__ */ p(dn, {}), /* @__PURE__ */ p(ln, {})] });
|
|
2108
|
+
}
|
|
2109
|
+
//#endregion
|
|
2110
|
+
//#region src/components/fullCalendar/index.tsx
|
|
2111
|
+
function pn(e) {
|
|
2112
|
+
let [t, n] = u("month");
|
|
2113
|
+
return /* @__PURE__ */ p(Ut, {
|
|
2114
|
+
events: e.events || [],
|
|
2115
|
+
defaultValue: e.defaultValue,
|
|
2116
|
+
onChangeView: e.onChangeView,
|
|
2117
|
+
blockedTimestamps: e.blockedTimestamps || [],
|
|
2118
|
+
onClickDate: e.onClickDate,
|
|
2119
|
+
children: /* @__PURE__ */ m(Xt, { children: [
|
|
2120
|
+
/* @__PURE__ */ p(Zt, {
|
|
2121
|
+
viewType: t,
|
|
2122
|
+
setViewType: n
|
|
2123
|
+
}),
|
|
2124
|
+
t === "day" && /* @__PURE__ */ p(Yt, {}),
|
|
2125
|
+
t === "month" && /* @__PURE__ */ p(rn, {}),
|
|
2126
|
+
t === "week" && /* @__PURE__ */ p(fn, {})
|
|
2127
|
+
] })
|
|
2128
|
+
});
|
|
2129
|
+
}
|
|
2130
|
+
//#endregion
|
|
1587
2131
|
//#region src/components/googleAnalytics/snippets/generateGAElements.ts
|
|
1588
|
-
function
|
|
2132
|
+
function mn(e) {
|
|
1589
2133
|
let { measurementId: t } = e;
|
|
1590
2134
|
return t || console.warn("Google Analytics Measurement ID is required"), {
|
|
1591
2135
|
src: `https://www.googletagmanager.com/gtag/js?id=${t}`,
|
|
@@ -1598,7 +2142,7 @@ function Bt(e) {
|
|
|
1598
2142
|
}
|
|
1599
2143
|
//#endregion
|
|
1600
2144
|
//#region src/components/googleAnalytics/googleAnalytics.tsx
|
|
1601
|
-
var
|
|
2145
|
+
var hn = class {
|
|
1602
2146
|
initializeAsyncScript(e) {
|
|
1603
2147
|
let t = document.createElement("script");
|
|
1604
2148
|
return t.async = !0, t.src = e, t;
|
|
@@ -1608,24 +2152,24 @@ var Vt = class {
|
|
|
1608
2152
|
return t.innerHTML = e, t;
|
|
1609
2153
|
}
|
|
1610
2154
|
initialize(e) {
|
|
1611
|
-
let { measurementId: t } = e, n =
|
|
2155
|
+
let { measurementId: t } = e, n = mn({ measurementId: t }), r = this.initializeAsyncScript(n.src), i = this.initializeInlineScript(n.script);
|
|
1612
2156
|
document.head.appendChild(r), document.head.appendChild(i);
|
|
1613
2157
|
}
|
|
1614
2158
|
};
|
|
1615
2159
|
//#endregion
|
|
1616
2160
|
//#region src/components/googleAnalytics/googleAnalytics.client.tsx
|
|
1617
|
-
function
|
|
1618
|
-
return new
|
|
2161
|
+
function gn(e) {
|
|
2162
|
+
return new hn().initialize(e), /* @__PURE__ */ p(f, {});
|
|
1619
2163
|
}
|
|
1620
2164
|
//#endregion
|
|
1621
2165
|
//#region src/components/googleAnalytics/index.tsx
|
|
1622
|
-
function
|
|
2166
|
+
function _n(e) {
|
|
1623
2167
|
let { measurementId: t, showInDevMode: n = !1 } = e;
|
|
1624
|
-
return process.env.NODE_ENV !== "production" && !n ? /* @__PURE__ */ p(f, {}) : /* @__PURE__ */ p(
|
|
2168
|
+
return process.env.NODE_ENV !== "production" && !n ? /* @__PURE__ */ p(f, {}) : /* @__PURE__ */ p(Et, { children: () => /* @__PURE__ */ p(gn, { measurementId: t }) });
|
|
1625
2169
|
}
|
|
1626
2170
|
//#endregion
|
|
1627
2171
|
//#region src/components/googleTagManager/snippets/appendToDataLayer.ts
|
|
1628
|
-
function
|
|
2172
|
+
function vn(e) {
|
|
1629
2173
|
let { dataLayer: t, dataLayerName: n } = e;
|
|
1630
2174
|
return `
|
|
1631
2175
|
window.${n} = window.${n} || [];
|
|
@@ -1633,7 +2177,7 @@ function Wt(e) {
|
|
|
1633
2177
|
}
|
|
1634
2178
|
//#endregion
|
|
1635
2179
|
//#region src/components/googleTagManager/snippets/generateGTMElements.ts
|
|
1636
|
-
function
|
|
2180
|
+
function yn(e) {
|
|
1637
2181
|
let { id: t, events: n, dataLayer: r, dataLayerName: i, preview: a, auth: o } = e, s = `>m_auth=${o}`, c = `>m_preview=${a}`;
|
|
1638
2182
|
return t || console.warn("GTM Id is required"), {
|
|
1639
2183
|
iframe: `
|
|
@@ -1646,7 +2190,7 @@ function Gt(e) {
|
|
|
1646
2190
|
j.async=true;j.src='https://www.googletagmanager.com/gtm.js?id='+i+dl+'${s}${c}>m_cookies_win=x';
|
|
1647
2191
|
f.parentNode.insertBefore(j,f);
|
|
1648
2192
|
})(window,document,'script','${i}','${t}');`,
|
|
1649
|
-
dataLayerVar:
|
|
2193
|
+
dataLayerVar: vn({
|
|
1650
2194
|
dataLayer: r,
|
|
1651
2195
|
dataLayerName: i
|
|
1652
2196
|
})
|
|
@@ -1654,13 +2198,13 @@ function Gt(e) {
|
|
|
1654
2198
|
}
|
|
1655
2199
|
//#endregion
|
|
1656
2200
|
//#region src/components/googleTagManager/googleTagManager.tsx
|
|
1657
|
-
var
|
|
2201
|
+
var bn = class {
|
|
1658
2202
|
initializeDataScript(e) {
|
|
1659
2203
|
let t = document.createElement("script");
|
|
1660
2204
|
return t.innerHTML = e, t;
|
|
1661
2205
|
}
|
|
1662
2206
|
initializeGTMElements(e) {
|
|
1663
|
-
let t =
|
|
2207
|
+
let t = yn(e);
|
|
1664
2208
|
return {
|
|
1665
2209
|
noScript: () => {
|
|
1666
2210
|
let e = document.createElement("noscript");
|
|
@@ -1676,7 +2220,7 @@ var Kt = class {
|
|
|
1676
2220
|
initializeDataLayer(e) {
|
|
1677
2221
|
let { dataLayer: t, dataLayerName: n } = e;
|
|
1678
2222
|
if (window[n]) return window[n].push(t);
|
|
1679
|
-
let r =
|
|
2223
|
+
let r = vn({
|
|
1680
2224
|
dataLayer: t,
|
|
1681
2225
|
dataLayerName: n
|
|
1682
2226
|
}), i = this.initializeDataScript(r);
|
|
@@ -1696,14 +2240,14 @@ var Kt = class {
|
|
|
1696
2240
|
};
|
|
1697
2241
|
//#endregion
|
|
1698
2242
|
//#region src/components/googleTagManager/googleTagManager.client.tsx
|
|
1699
|
-
function
|
|
1700
|
-
return new
|
|
2243
|
+
function xn(e) {
|
|
2244
|
+
return new bn().initialize(e), /* @__PURE__ */ p(f, {});
|
|
1701
2245
|
}
|
|
1702
2246
|
//#endregion
|
|
1703
2247
|
//#region src/components/googleTagManager/index.tsx
|
|
1704
|
-
function
|
|
2248
|
+
function Sn(e) {
|
|
1705
2249
|
let { gtmId: t, auth: n = "", preview: r = "", dataLayerName: i = "dataLayer", events: a = {}, dataLayer: o = {}, showInDevMode: s = !1 } = e;
|
|
1706
|
-
return process.env.NODE_ENV !== "production" && !s ? /* @__PURE__ */ p(f, {}) : /* @__PURE__ */ p(
|
|
2250
|
+
return process.env.NODE_ENV !== "production" && !s ? /* @__PURE__ */ p(f, {}) : /* @__PURE__ */ p(Et, { children: () => /* @__PURE__ */ p(xn, {
|
|
1707
2251
|
auth: n,
|
|
1708
2252
|
dataLayer: o,
|
|
1709
2253
|
dataLayerName: i,
|
|
@@ -1714,7 +2258,7 @@ function Jt(e) {
|
|
|
1714
2258
|
}
|
|
1715
2259
|
//#endregion
|
|
1716
2260
|
//#region src/components/imageUpload/hasFileContent/index.tsx
|
|
1717
|
-
function
|
|
2261
|
+
function Cn(e) {
|
|
1718
2262
|
let { disabled: t, filePath: n, isLoading: r, acceptImage: i, changeImageButtonText: a, handleSelectFile: o, reSendImage: s } = e;
|
|
1719
2263
|
function c() {
|
|
1720
2264
|
if (t) return;
|
|
@@ -1754,7 +2298,7 @@ function Yt(e) {
|
|
|
1754
2298
|
}
|
|
1755
2299
|
//#endregion
|
|
1756
2300
|
//#region src/components/imageUpload/noFileContent/index.tsx
|
|
1757
|
-
function
|
|
2301
|
+
function wn(e) {
|
|
1758
2302
|
let { dropImageText: t, isLoading: n, acceptImage: r, handleSelectFile: i, selectImageButtonText: a, disabled: o } = e;
|
|
1759
2303
|
function s(e) {
|
|
1760
2304
|
if (o) return;
|
|
@@ -1786,8 +2330,8 @@ function Xt(e) {
|
|
|
1786
2330
|
}
|
|
1787
2331
|
//#endregion
|
|
1788
2332
|
//#region src/components/imageUpload/index.tsx
|
|
1789
|
-
function
|
|
1790
|
-
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 = "
|
|
2333
|
+
function Tn(e) {
|
|
2334
|
+
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 } = X(), S = x?.[t], [C, w] = u(n), [T, E] = u(""), [D, O] = u(null), [k, A] = u(n), [j, M] = u(!1);
|
|
1791
2335
|
async function N(e) {
|
|
1792
2336
|
if (v) return;
|
|
1793
2337
|
M(!0), O(e), E("");
|
|
@@ -1805,7 +2349,7 @@ function Zt(e) {
|
|
|
1805
2349
|
v || (A(URL.createObjectURL(e)), N(e));
|
|
1806
2350
|
}
|
|
1807
2351
|
let F = S || T;
|
|
1808
|
-
return /* @__PURE__ */ p(
|
|
2352
|
+
return /* @__PURE__ */ p(et, {
|
|
1809
2353
|
name: t,
|
|
1810
2354
|
label: r,
|
|
1811
2355
|
showAsterisk: i,
|
|
@@ -1821,7 +2365,7 @@ function Zt(e) {
|
|
|
1821
2365
|
name: t,
|
|
1822
2366
|
value: C || ""
|
|
1823
2367
|
}),
|
|
1824
|
-
!k && /* @__PURE__ */ p(
|
|
2368
|
+
!k && /* @__PURE__ */ p(wn, {
|
|
1825
2369
|
disabled: v,
|
|
1826
2370
|
isLoading: j,
|
|
1827
2371
|
acceptImage: l,
|
|
@@ -1829,7 +2373,7 @@ function Zt(e) {
|
|
|
1829
2373
|
handleSelectFile: P,
|
|
1830
2374
|
selectImageButtonText: h
|
|
1831
2375
|
}),
|
|
1832
|
-
k && /* @__PURE__ */ p(
|
|
2376
|
+
k && /* @__PURE__ */ p(Cn, {
|
|
1833
2377
|
disabled: v,
|
|
1834
2378
|
isLoading: j,
|
|
1835
2379
|
acceptImage: l,
|
|
@@ -1844,7 +2388,7 @@ function Zt(e) {
|
|
|
1844
2388
|
}
|
|
1845
2389
|
//#endregion
|
|
1846
2390
|
//#region src/components/mapView/mapView.client.tsx
|
|
1847
|
-
function
|
|
2391
|
+
function En({ center: e, coordinates: t, onMarkerClick: n, accessToken: r, ...i }) {
|
|
1848
2392
|
let a = l(null), s = l(null), c = e || t[0];
|
|
1849
2393
|
return o(() => (ae.accessToken = r, a.current = new ae.Map({
|
|
1850
2394
|
container: s.current,
|
|
@@ -1888,19 +2432,19 @@ function Qt({ center: e, coordinates: t, onMarkerClick: n, accessToken: r, ...i
|
|
|
1888
2432
|
}
|
|
1889
2433
|
//#endregion
|
|
1890
2434
|
//#region src/components/mapView/index.tsx
|
|
1891
|
-
function
|
|
2435
|
+
function Dn({ className: e }) {
|
|
1892
2436
|
return /* @__PURE__ */ p("div", {
|
|
1893
2437
|
className: "arkynMapViewPinnedEmpty " + e,
|
|
1894
2438
|
children: /* @__PURE__ */ p(R, {})
|
|
1895
2439
|
});
|
|
1896
2440
|
}
|
|
1897
|
-
function
|
|
2441
|
+
function On(e) {
|
|
1898
2442
|
let { coordinates: t, zoom: n = 18, accessToken: r, className: i, onMarkerClick: a, ...o } = e;
|
|
1899
|
-
if (!t) return /* @__PURE__ */ p(
|
|
2443
|
+
if (!t) return /* @__PURE__ */ p(Dn, { className: i });
|
|
1900
2444
|
let s = Array.isArray(t) ? t : [t];
|
|
1901
|
-
return s.length === 0 ? /* @__PURE__ */ p(
|
|
1902
|
-
fallback: /* @__PURE__ */ p(
|
|
1903
|
-
children: () => /* @__PURE__ */ p(
|
|
2445
|
+
return s.length === 0 ? /* @__PURE__ */ p(Dn, { className: i }) : /* @__PURE__ */ p(Et, {
|
|
2446
|
+
fallback: /* @__PURE__ */ p(Dn, { className: i }),
|
|
2447
|
+
children: () => /* @__PURE__ */ p(En, {
|
|
1904
2448
|
accessToken: r,
|
|
1905
2449
|
coordinates: s,
|
|
1906
2450
|
center: s[0],
|
|
@@ -1911,11 +2455,11 @@ function en(e) {
|
|
|
1911
2455
|
}
|
|
1912
2456
|
//#endregion
|
|
1913
2457
|
//#region src/components/maskedInput/index.tsx
|
|
1914
|
-
var
|
|
2458
|
+
var kn = r((e, t) => /* @__PURE__ */ p("input", {
|
|
1915
2459
|
ref: t,
|
|
1916
2460
|
...e
|
|
1917
2461
|
}));
|
|
1918
|
-
function
|
|
2462
|
+
function An(e) {
|
|
1919
2463
|
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 } = X(), [P, F] = u(!1), I = l(null), R = k || s(), z = w || N?.[t], B = !!z, V = n || y, H = {
|
|
1920
2464
|
md: 20,
|
|
1921
2465
|
lg: 20
|
|
@@ -1929,7 +2473,7 @@ function nn(e) {
|
|
|
1929
2473
|
function ee(e) {
|
|
1930
2474
|
F(!1), C && C(e);
|
|
1931
2475
|
}
|
|
1932
|
-
let
|
|
2476
|
+
let J = `arkynMaskedInput ${_ ? "hasPrefix" : ""} ${v ? "hasSuffix" : ""} ${a} ${O} ${V || x || y ? "opacity" : ""} ${B ? "errored" : ""} ${P ? "focused" : ""}`;
|
|
1933
2477
|
return /* @__PURE__ */ m(Ve, {
|
|
1934
2478
|
className: g,
|
|
1935
2479
|
children: [
|
|
@@ -1942,7 +2486,7 @@ function nn(e) {
|
|
|
1942
2486
|
title: r,
|
|
1943
2487
|
style: i,
|
|
1944
2488
|
onClick: K,
|
|
1945
|
-
className:
|
|
2489
|
+
className: J,
|
|
1946
2490
|
children: [
|
|
1947
2491
|
/* @__PURE__ */ p(Z, {
|
|
1948
2492
|
iconSize: H,
|
|
@@ -1961,7 +2505,7 @@ function nn(e) {
|
|
|
1961
2505
|
iconSize: H
|
|
1962
2506
|
}),
|
|
1963
2507
|
/* @__PURE__ */ p(se, {
|
|
1964
|
-
component:
|
|
2508
|
+
component: kn,
|
|
1965
2509
|
mask: c,
|
|
1966
2510
|
replacement: f,
|
|
1967
2511
|
separate: o,
|
|
@@ -2002,23 +2546,23 @@ function nn(e) {
|
|
|
2002
2546
|
}
|
|
2003
2547
|
//#endregion
|
|
2004
2548
|
//#region src/components/modal/modalContext.tsx
|
|
2005
|
-
var
|
|
2006
|
-
function
|
|
2007
|
-
return /* @__PURE__ */ p(
|
|
2549
|
+
var jn = n({});
|
|
2550
|
+
function Mn(e) {
|
|
2551
|
+
return /* @__PURE__ */ p(jn.Provider, {
|
|
2008
2552
|
value: { makeInvisible: e.makeInvisible },
|
|
2009
2553
|
children: e.children
|
|
2010
2554
|
});
|
|
2011
2555
|
}
|
|
2012
|
-
function
|
|
2013
|
-
return a(
|
|
2556
|
+
function Nn() {
|
|
2557
|
+
return a(jn);
|
|
2014
2558
|
}
|
|
2015
2559
|
//#endregion
|
|
2016
2560
|
//#region src/components/modal/modalContainer/index.tsx
|
|
2017
|
-
function
|
|
2561
|
+
function Pn(e) {
|
|
2018
2562
|
let { isVisible: t, makeInvisible: n, children: r, className: i = "", ...a } = e;
|
|
2019
|
-
|
|
2563
|
+
ot(t);
|
|
2020
2564
|
let o = `arkynModalContainer ${t ? "visibleTrue" : "visibleFalse"} ${i}`;
|
|
2021
|
-
return /* @__PURE__ */ p(
|
|
2565
|
+
return /* @__PURE__ */ p(Mn, {
|
|
2022
2566
|
makeInvisible: n,
|
|
2023
2567
|
children: /* @__PURE__ */ p(ie, { children: t && /* @__PURE__ */ m("aside", {
|
|
2024
2568
|
className: o.trim(),
|
|
@@ -2058,7 +2602,7 @@ function sn(e) {
|
|
|
2058
2602
|
}
|
|
2059
2603
|
//#endregion
|
|
2060
2604
|
//#region src/components/modal/modalFooter/index.tsx
|
|
2061
|
-
function
|
|
2605
|
+
function Fn(e) {
|
|
2062
2606
|
let { alignment: t = "right", className: n, ...r } = e;
|
|
2063
2607
|
return /* @__PURE__ */ p("footer", {
|
|
2064
2608
|
className: `arkynModalFooter ${t} ${n}`.trim(),
|
|
@@ -2067,8 +2611,8 @@ function cn(e) {
|
|
|
2067
2611
|
}
|
|
2068
2612
|
//#endregion
|
|
2069
2613
|
//#region src/components/modal/modalHeader/index.tsx
|
|
2070
|
-
function
|
|
2071
|
-
let { showCloseButton: t = !0, className: n, children: r, ...i } = e, { makeInvisible: a } =
|
|
2614
|
+
function In(e) {
|
|
2615
|
+
let { showCloseButton: t = !0, className: n, children: r, ...i } = e, { makeInvisible: a } = Nn();
|
|
2072
2616
|
return /* @__PURE__ */ m("header", {
|
|
2073
2617
|
className: `arkynModalHeader ${n}`.trim(),
|
|
2074
2618
|
...i,
|
|
@@ -2083,7 +2627,7 @@ function ln(e) {
|
|
|
2083
2627
|
}
|
|
2084
2628
|
//#endregion
|
|
2085
2629
|
//#region src/components/multiSelect/multiSelectChevron/index.tsx
|
|
2086
|
-
function
|
|
2630
|
+
function Ln(e) {
|
|
2087
2631
|
let { iconSize: t, isLoading: n, disabled: r, readOnly: i, isFocused: a } = e;
|
|
2088
2632
|
return n ? /* @__PURE__ */ p(f, {}) : /* @__PURE__ */ p(C, {
|
|
2089
2633
|
className: `arkynMultiSelectChevron ${r || i ? "notAnimate" : ""} ${a ? "focused" : ""}`,
|
|
@@ -2098,7 +2642,7 @@ function un(e) {
|
|
|
2098
2642
|
}
|
|
2099
2643
|
//#endregion
|
|
2100
2644
|
//#region src/components/multiSelect/multiSelectContainer/index.tsx
|
|
2101
|
-
function
|
|
2645
|
+
function Rn(e) {
|
|
2102
2646
|
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 } = e;
|
|
2103
2647
|
return /* @__PURE__ */ p("section", {
|
|
2104
2648
|
id: d,
|
|
@@ -2109,7 +2653,7 @@ function dn(e) {
|
|
|
2109
2653
|
}
|
|
2110
2654
|
//#endregion
|
|
2111
2655
|
//#region src/components/multiSelect/multiSelectContent/index.tsx
|
|
2112
|
-
function
|
|
2656
|
+
function zn(e) {
|
|
2113
2657
|
let { children: t, size: n } = e;
|
|
2114
2658
|
return /* @__PURE__ */ p("div", {
|
|
2115
2659
|
className: `arkynMultiSelectContent ${n}`,
|
|
@@ -2118,7 +2662,7 @@ function fn(e) {
|
|
|
2118
2662
|
}
|
|
2119
2663
|
//#endregion
|
|
2120
2664
|
//#region src/components/multiSelect/multiSelectMark/index.tsx
|
|
2121
|
-
function
|
|
2665
|
+
function Bn(e) {
|
|
2122
2666
|
let { label: t, value: n, disabled: r, handleChangeValue: i } = e;
|
|
2123
2667
|
return /* @__PURE__ */ m("div", {
|
|
2124
2668
|
className: "arkynMultiSelectMark",
|
|
@@ -2134,7 +2678,7 @@ function pn(e) {
|
|
|
2134
2678
|
}
|
|
2135
2679
|
//#endregion
|
|
2136
2680
|
//#region src/components/multiSelect/multiSelectOption/index.tsx
|
|
2137
|
-
function
|
|
2681
|
+
function Vn(e) {
|
|
2138
2682
|
let { label: t, optionHasSelected: n, handleChangeValue: r, value: i, size: a } = e;
|
|
2139
2683
|
return /* @__PURE__ */ m("div", {
|
|
2140
2684
|
onClick: () => r(i),
|
|
@@ -2148,9 +2692,9 @@ function mn(e) {
|
|
|
2148
2692
|
}
|
|
2149
2693
|
//#endregion
|
|
2150
2694
|
//#region src/components/multiSelect/multiSelectOptionsContainer/index.tsx
|
|
2151
|
-
function
|
|
2695
|
+
function Hn(e) {
|
|
2152
2696
|
let { children: t, isFocused: n, isSearchable: r, search: i, onSearch: a } = e, s = l(null), [c, d] = u("bottom");
|
|
2153
|
-
|
|
2697
|
+
ot(n), o(() => {
|
|
2154
2698
|
n && (() => {
|
|
2155
2699
|
if (!s.current) return;
|
|
2156
2700
|
let e = s.current.parentElement;
|
|
@@ -2165,7 +2709,7 @@ function hn(e) {
|
|
|
2165
2709
|
return n ? /* @__PURE__ */ m("div", {
|
|
2166
2710
|
ref: s,
|
|
2167
2711
|
className: `arkynMultiSelectOptionsContainer ${c}`,
|
|
2168
|
-
children: [r && /* @__PURE__ */ p(
|
|
2712
|
+
children: [r && /* @__PURE__ */ p(st, {
|
|
2169
2713
|
type: "search",
|
|
2170
2714
|
name: "search-select",
|
|
2171
2715
|
variant: "underline",
|
|
@@ -2177,7 +2721,7 @@ function hn(e) {
|
|
|
2177
2721
|
}
|
|
2178
2722
|
//#endregion
|
|
2179
2723
|
//#region src/components/multiSelect/multiSelectOverlay/index.tsx
|
|
2180
|
-
function
|
|
2724
|
+
function Un(e) {
|
|
2181
2725
|
let { isFocused: t, handleBlur: n } = e;
|
|
2182
2726
|
return t ? /* @__PURE__ */ p("aside", {
|
|
2183
2727
|
className: "arkynMultiSelectOverlay",
|
|
@@ -2186,7 +2730,7 @@ function gn(e) {
|
|
|
2186
2730
|
}
|
|
2187
2731
|
//#endregion
|
|
2188
2732
|
//#region src/components/multiSelect/multiSelectSpinner/index.tsx
|
|
2189
|
-
function
|
|
2733
|
+
function Wn(e) {
|
|
2190
2734
|
let { iconSize: t, isLoading: n } = e;
|
|
2191
2735
|
return n ? /* @__PURE__ */ p(L, {
|
|
2192
2736
|
className: "arkynMultiSelectSpinner",
|
|
@@ -2196,8 +2740,8 @@ function _n(e) {
|
|
|
2196
2740
|
}
|
|
2197
2741
|
//#endregion
|
|
2198
2742
|
//#region src/components/multiSelect/index.tsx
|
|
2199
|
-
function
|
|
2200
|
-
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: _, optionMaxHeight: v, showAsterisk: y, leftIcon: b, onSearch: x, onChange: S, onBlur: C, notFoundText: w = "Sem opções disponíveis", onFocus: T, disabled: E = !1, prefix: D, size: O = "md", value: k, variant: A = "solid", unShowFieldTemplate: j = !1, orientation: M = "
|
|
2743
|
+
function Gn(e) {
|
|
2744
|
+
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: _, optionMaxHeight: v, showAsterisk: y, leftIcon: b, onSearch: x, onChange: S, onBlur: C, notFoundText: w = "Sem opções disponíveis", onFocus: T, disabled: E = !1, prefix: D, size: O = "md", value: k, variant: A = "solid", unShowFieldTemplate: j = !1, orientation: M = "vertical" } = e, { fieldErrors: N } = X(), P = l(null), F = g || s(), I = c || N?.[t], L = !!I, R = E || d || f, z = {
|
|
2201
2745
|
md: 20,
|
|
2202
2746
|
lg: 20
|
|
2203
2747
|
}[O], [B, V] = u(""), [H, U] = u(!1), [W, G] = u(o), K = k || W;
|
|
@@ -2207,20 +2751,20 @@ function vn(e) {
|
|
|
2207
2751
|
function ee(e) {
|
|
2208
2752
|
return n.find((t) => t.value === e)?.label || "";
|
|
2209
2753
|
}
|
|
2210
|
-
function
|
|
2754
|
+
function J() {
|
|
2211
2755
|
R || !P?.current || H || (U(!0), P.current.focus(), T && T());
|
|
2212
2756
|
}
|
|
2213
|
-
function
|
|
2757
|
+
function te() {
|
|
2214
2758
|
U(!1), C && P.current && P.current.blur();
|
|
2215
2759
|
}
|
|
2216
2760
|
function ne(e) {
|
|
2217
2761
|
V(e), x && x(e);
|
|
2218
2762
|
}
|
|
2219
2763
|
function re(e) {
|
|
2220
|
-
q(e) ? (G(W.filter((t) => t !== e)), S && S(W.filter((t) => t !== e))) : (G([...W, e]), S && S([...W, e])), a &&
|
|
2764
|
+
q(e) ? (G(W.filter((t) => t !== e)), S && S(W.filter((t) => t !== e))) : (G([...W, e]), S && S([...W, e])), a && te();
|
|
2221
2765
|
}
|
|
2222
2766
|
let ie = n.filter((t) => !!(e.onSearch || !e.isSearchable || t.label.toLowerCase().includes(B.toLowerCase())));
|
|
2223
|
-
return /* @__PURE__ */ p(
|
|
2767
|
+
return /* @__PURE__ */ p(et, {
|
|
2224
2768
|
name: t,
|
|
2225
2769
|
label: _,
|
|
2226
2770
|
showAsterisk: y,
|
|
@@ -2228,8 +2772,8 @@ function vn(e) {
|
|
|
2228
2772
|
errorMessage: I,
|
|
2229
2773
|
unShowFieldTemplate: j,
|
|
2230
2774
|
orientation: M,
|
|
2231
|
-
children: /* @__PURE__ */ m(
|
|
2232
|
-
handleContainerFocus:
|
|
2775
|
+
children: /* @__PURE__ */ m(Rn, {
|
|
2776
|
+
handleContainerFocus: J,
|
|
2233
2777
|
disabled: R,
|
|
2234
2778
|
isError: L,
|
|
2235
2779
|
isFocused: H,
|
|
@@ -2255,21 +2799,21 @@ function vn(e) {
|
|
|
2255
2799
|
size: z,
|
|
2256
2800
|
strokeWidth: 2.5
|
|
2257
2801
|
}),
|
|
2258
|
-
/* @__PURE__ */ m(
|
|
2802
|
+
/* @__PURE__ */ m(zn, {
|
|
2259
2803
|
size: O,
|
|
2260
|
-
children: [K.map((e) => /* @__PURE__ */ p(
|
|
2804
|
+
children: [K.map((e) => /* @__PURE__ */ p(Bn, {
|
|
2261
2805
|
label: ee(e),
|
|
2262
2806
|
value: e,
|
|
2263
2807
|
handleChangeValue: re,
|
|
2264
2808
|
disabled: R
|
|
2265
2809
|
}, e)), K.length <= 0 && /* @__PURE__ */ p("p", { children: i })]
|
|
2266
2810
|
}),
|
|
2267
|
-
/* @__PURE__ */ m(
|
|
2811
|
+
/* @__PURE__ */ m(Hn, {
|
|
2268
2812
|
isFocused: H,
|
|
2269
2813
|
isSearchable: h,
|
|
2270
2814
|
search: B,
|
|
2271
2815
|
onSearch: ne,
|
|
2272
|
-
children: [ie.map(({ label: e, value: t }) => /* @__PURE__ */ p(
|
|
2816
|
+
children: [ie.map(({ label: e, value: t }) => /* @__PURE__ */ p(Vn, {
|
|
2273
2817
|
label: e,
|
|
2274
2818
|
value: t,
|
|
2275
2819
|
size: O,
|
|
@@ -2277,19 +2821,19 @@ function vn(e) {
|
|
|
2277
2821
|
optionHasSelected: q
|
|
2278
2822
|
}, t)), ie.length <= 0 && /* @__PURE__ */ p("p", { children: w })]
|
|
2279
2823
|
}),
|
|
2280
|
-
/* @__PURE__ */ p(
|
|
2824
|
+
/* @__PURE__ */ p(Ln, {
|
|
2281
2825
|
disabled: R,
|
|
2282
2826
|
isFocused: H,
|
|
2283
2827
|
readOnly: f,
|
|
2284
2828
|
iconSize: z,
|
|
2285
2829
|
isLoading: d
|
|
2286
2830
|
}),
|
|
2287
|
-
/* @__PURE__ */ p(
|
|
2831
|
+
/* @__PURE__ */ p(Wn, {
|
|
2288
2832
|
iconSize: z,
|
|
2289
2833
|
isLoading: d
|
|
2290
2834
|
}),
|
|
2291
|
-
/* @__PURE__ */ p(
|
|
2292
|
-
handleBlur:
|
|
2835
|
+
/* @__PURE__ */ p(Un, {
|
|
2836
|
+
handleBlur: te,
|
|
2293
2837
|
isFocused: H
|
|
2294
2838
|
})
|
|
2295
2839
|
]
|
|
@@ -2298,7 +2842,7 @@ function vn(e) {
|
|
|
2298
2842
|
}
|
|
2299
2843
|
//#endregion
|
|
2300
2844
|
//#region src/components/pagination/chevronButton/index.tsx
|
|
2301
|
-
function
|
|
2845
|
+
function Kn(e) {
|
|
2302
2846
|
let { orientation: t, handlePageChange: n, disabled: r } = e;
|
|
2303
2847
|
return /* @__PURE__ */ p("button", {
|
|
2304
2848
|
className: "arkynChevronPageButton",
|
|
@@ -2312,7 +2856,7 @@ function yn(e) {
|
|
|
2312
2856
|
}
|
|
2313
2857
|
//#endregion
|
|
2314
2858
|
//#region src/components/pagination/currentButton/index.tsx
|
|
2315
|
-
function
|
|
2859
|
+
function qn({ currentPage: e }) {
|
|
2316
2860
|
return /* @__PURE__ */ p("button", {
|
|
2317
2861
|
className: "arkynPaginationCurrentButton",
|
|
2318
2862
|
disabled: !0,
|
|
@@ -2321,7 +2865,7 @@ function bn({ currentPage: e }) {
|
|
|
2321
2865
|
}
|
|
2322
2866
|
//#endregion
|
|
2323
2867
|
//#region src/components/pagination/pageButton/index.tsx
|
|
2324
|
-
function
|
|
2868
|
+
function Jn(e) {
|
|
2325
2869
|
let { page: t, handlePageChange: n } = e;
|
|
2326
2870
|
return /* @__PURE__ */ p("button", {
|
|
2327
2871
|
className: "arkynPaginationPageButton",
|
|
@@ -2331,7 +2875,7 @@ function xn(e) {
|
|
|
2331
2875
|
}
|
|
2332
2876
|
//#endregion
|
|
2333
2877
|
//#region src/components/pagination/paginationService.ts
|
|
2334
|
-
var
|
|
2878
|
+
var Yn = class {
|
|
2335
2879
|
currentPage;
|
|
2336
2880
|
totalCountRegisters;
|
|
2337
2881
|
registerPerPage;
|
|
@@ -2364,7 +2908,7 @@ var Sn = class {
|
|
|
2364
2908
|
};
|
|
2365
2909
|
//#endregion
|
|
2366
2910
|
//#region src/components/pagination/spread/index.tsx
|
|
2367
|
-
function
|
|
2911
|
+
function Xn() {
|
|
2368
2912
|
return /* @__PURE__ */ p("p", {
|
|
2369
2913
|
className: "arkynPaginationSpread",
|
|
2370
2914
|
children: /* @__PURE__ */ p(D, {})
|
|
@@ -2372,8 +2916,8 @@ function Cn() {
|
|
|
2372
2916
|
}
|
|
2373
2917
|
//#endregion
|
|
2374
2918
|
//#region src/components/pagination/index.tsx
|
|
2375
|
-
function
|
|
2376
|
-
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
|
|
2919
|
+
function Zn(e) {
|
|
2920
|
+
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 Yn({
|
|
2377
2921
|
totalCountRegisters: t,
|
|
2378
2922
|
currentPage: r,
|
|
2379
2923
|
registerPerPage: i,
|
|
@@ -2384,29 +2928,29 @@ function wn(e) {
|
|
|
2384
2928
|
className: "arkynPagination",
|
|
2385
2929
|
...o,
|
|
2386
2930
|
children: [
|
|
2387
|
-
/* @__PURE__ */ p(
|
|
2931
|
+
/* @__PURE__ */ p(Kn, {
|
|
2388
2932
|
orientation: "left",
|
|
2389
2933
|
handlePageChange: g,
|
|
2390
2934
|
disabled: s <= 1
|
|
2391
2935
|
}),
|
|
2392
|
-
s > 1 + c && /* @__PURE__ */ m(f, { children: [/* @__PURE__ */ p(
|
|
2936
|
+
s > 1 + c && /* @__PURE__ */ m(f, { children: [/* @__PURE__ */ p(Jn, {
|
|
2393
2937
|
page: 1,
|
|
2394
2938
|
handlePageChange: () => h(1)
|
|
2395
|
-
}), s > 2 + c && /* @__PURE__ */ p(
|
|
2396
|
-
l.map((e, t) => /* @__PURE__ */ p(
|
|
2939
|
+
}), s > 2 + c && /* @__PURE__ */ p(Xn, {})] }),
|
|
2940
|
+
l.map((e, t) => /* @__PURE__ */ p(Jn, {
|
|
2397
2941
|
page: e,
|
|
2398
2942
|
handlePageChange: g
|
|
2399
2943
|
}, t)),
|
|
2400
|
-
/* @__PURE__ */ p(
|
|
2401
|
-
u.map((e, t) => /* @__PURE__ */ p(
|
|
2944
|
+
/* @__PURE__ */ p(qn, { currentPage: s }),
|
|
2945
|
+
u.map((e, t) => /* @__PURE__ */ p(Jn, {
|
|
2402
2946
|
page: e,
|
|
2403
2947
|
handlePageChange: _
|
|
2404
2948
|
}, t)),
|
|
2405
|
-
s + c < d && /* @__PURE__ */ m(f, { children: [s + 1 + c < d && /* @__PURE__ */ p(
|
|
2949
|
+
s + c < d && /* @__PURE__ */ m(f, { children: [s + 1 + c < d && /* @__PURE__ */ p(Xn, {}), /* @__PURE__ */ p(Jn, {
|
|
2406
2950
|
page: d,
|
|
2407
2951
|
handlePageChange: () => h(d)
|
|
2408
2952
|
})] }),
|
|
2409
|
-
/* @__PURE__ */ p(
|
|
2953
|
+
/* @__PURE__ */ p(Kn, {
|
|
2410
2954
|
orientation: "right",
|
|
2411
2955
|
handlePageChange: _,
|
|
2412
2956
|
disabled: s >= d
|
|
@@ -2416,7 +2960,7 @@ function wn(e) {
|
|
|
2416
2960
|
}
|
|
2417
2961
|
//#endregion
|
|
2418
2962
|
//#region src/components/phoneInput/phoneInputContainer/index.tsx
|
|
2419
|
-
function
|
|
2963
|
+
function Qn(e) {
|
|
2420
2964
|
let { children: t, onFocus: n, disabled: r, isError: i, isLoading: a, isFocused: o, className: s = "", readOnly: c, variant: l, size: u } = e;
|
|
2421
2965
|
return /* @__PURE__ */ p("section", {
|
|
2422
2966
|
className: `arkynPhoneInputContainer ${l} ${u} ${r || c || a ? "opacity" : ""} ${i ? "errored" : ""} ${o ? "focused" : ""} ${s}`.trim(),
|
|
@@ -2426,7 +2970,7 @@ function Tn(e) {
|
|
|
2426
2970
|
}
|
|
2427
2971
|
//#endregion
|
|
2428
2972
|
//#region src/components/phoneInput/phoneInputCountriesOverlay/index.tsx
|
|
2429
|
-
function
|
|
2973
|
+
function $n(e) {
|
|
2430
2974
|
let { isOpen: t, onClick: n } = e;
|
|
2431
2975
|
return t ? /* @__PURE__ */ p("aside", {
|
|
2432
2976
|
className: "arkynPhoneInputCountriesOverlay",
|
|
@@ -2435,7 +2979,7 @@ function En(e) {
|
|
|
2435
2979
|
}
|
|
2436
2980
|
//#endregion
|
|
2437
2981
|
//#region src/components/phoneInput/phoneInputCountryOption/index.tsx
|
|
2438
|
-
function
|
|
2982
|
+
function er(e) {
|
|
2439
2983
|
let { country: t, isActive: n, handleChangeValue: r, size: i } = e;
|
|
2440
2984
|
return /* @__PURE__ */ m("div", {
|
|
2441
2985
|
onClick: () => r(t),
|
|
@@ -2455,12 +2999,12 @@ function Dn(e) {
|
|
|
2455
2999
|
}
|
|
2456
3000
|
//#endregion
|
|
2457
3001
|
//#region src/components/phoneInput/phoneInputCountryOptionsContainer/index.tsx
|
|
2458
|
-
function
|
|
3002
|
+
function tr(e) {
|
|
2459
3003
|
let { children: t, isOpen: n, onSearch: r, search: i, placeholder: a } = e, s = l(null), [c, d] = u("bottom");
|
|
2460
3004
|
function h(e) {
|
|
2461
3005
|
r(e.target.value);
|
|
2462
3006
|
}
|
|
2463
|
-
return
|
|
3007
|
+
return ot(n), o(() => {
|
|
2464
3008
|
n && (() => {
|
|
2465
3009
|
if (!s.current) return;
|
|
2466
3010
|
let e = s.current.parentElement;
|
|
@@ -2484,7 +3028,7 @@ function On(e) {
|
|
|
2484
3028
|
}
|
|
2485
3029
|
//#endregion
|
|
2486
3030
|
//#region src/components/phoneInput/phoneInputCountrySelector/index.tsx
|
|
2487
|
-
function
|
|
3031
|
+
function nr(e) {
|
|
2488
3032
|
let { currentCountry: t, onClick: n } = e;
|
|
2489
3033
|
return /* @__PURE__ */ m("div", {
|
|
2490
3034
|
className: "phoneInputSelectCountry",
|
|
@@ -2505,14 +3049,14 @@ function kn(e) {
|
|
|
2505
3049
|
}
|
|
2506
3050
|
//#endregion
|
|
2507
3051
|
//#region src/utils/phoneInputUtilities.ts
|
|
2508
|
-
function
|
|
3052
|
+
function rr(e) {
|
|
2509
3053
|
return e && e.replace(/[^0-9]/g, "");
|
|
2510
3054
|
}
|
|
2511
|
-
var
|
|
3055
|
+
var ir = {
|
|
2512
3056
|
EIGHT: "(99) 9999-9999",
|
|
2513
3057
|
NINE: "(99) 99999-9999"
|
|
2514
3058
|
};
|
|
2515
|
-
function
|
|
3059
|
+
function ar(e, t) {
|
|
2516
3060
|
let n = "", r = 0;
|
|
2517
3061
|
for (let i = 0; i < t.length; i++) if (t[i] === "9") if (r < e.length) n += e[r], r++;
|
|
2518
3062
|
else break;
|
|
@@ -2520,21 +3064,21 @@ function Mn(e, t) {
|
|
|
2520
3064
|
else break;
|
|
2521
3065
|
return n;
|
|
2522
3066
|
}
|
|
2523
|
-
function
|
|
3067
|
+
function or(e) {
|
|
2524
3068
|
return e.length > 10 ? "NINE" : "EIGHT";
|
|
2525
3069
|
}
|
|
2526
|
-
var
|
|
3070
|
+
var sr = rr(ir.NINE).length, cr = r((e, t) => /* @__PURE__ */ p("input", {
|
|
2527
3071
|
ref: t,
|
|
2528
3072
|
...e
|
|
2529
|
-
})),
|
|
3073
|
+
})), lr = r((e, t) => {
|
|
2530
3074
|
let { onFocus: n, readonly: r, onBlur: i, size: a, onChange: s, value: c, currentCountry: l, disabled: d, id: f } = e, [m, h] = u(!1), g = typeof l.mask == "string" ? l.mask : l.mask[0];
|
|
2531
3075
|
o(() => {
|
|
2532
3076
|
m ? s(g) : h(!0);
|
|
2533
3077
|
}, [l]);
|
|
2534
3078
|
let _ = `phoneInputMask ${a}`;
|
|
2535
3079
|
function v(e) {
|
|
2536
|
-
let t =
|
|
2537
|
-
t.length >
|
|
3080
|
+
let t = rr(e.target.value), n = or(t);
|
|
3081
|
+
t.length > sr || (t = ar(t, ir[n]), e.target.value = t, s(t));
|
|
2538
3082
|
}
|
|
2539
3083
|
return l.code === "+55" ? /* @__PURE__ */ p("input", {
|
|
2540
3084
|
id: f,
|
|
@@ -2551,7 +3095,7 @@ var Pn = An(jn.NINE).length, Fn = r((e, t) => /* @__PURE__ */ p("input", {
|
|
|
2551
3095
|
readOnly: r,
|
|
2552
3096
|
onChange: (e) => s(e.target.value),
|
|
2553
3097
|
className: _,
|
|
2554
|
-
component:
|
|
3098
|
+
component: cr,
|
|
2555
3099
|
onFocus: n,
|
|
2556
3100
|
onBlur: i,
|
|
2557
3101
|
disabled: d,
|
|
@@ -2563,7 +3107,7 @@ var Pn = An(jn.NINE).length, Fn = r((e, t) => /* @__PURE__ */ p("input", {
|
|
|
2563
3107
|
});
|
|
2564
3108
|
//#endregion
|
|
2565
3109
|
//#region src/components/phoneInput/index.tsx
|
|
2566
|
-
function
|
|
3110
|
+
function ur(e) {
|
|
2567
3111
|
let { defaultCountryIso: t, value: n, label: r, className: i = "", disabled: a = !1, errorMessage: o, isLoading: c = !1, readOnly: d = !1, size: f = "md", defaultValue: h = "", variant: g = "solid", showAsterisk: _, name: v, onChange: y, searchCountryPlaceholder: b = "Pesquisar país", notFoundCountryText: x = "Nenhum país encontrado", id: S, unShowFieldTemplate: C = !1, orientation: w = "vertical" } = e, T = ce.find((e) => e.iso === "BR"), E = h ? ne(h) : "", D = h ? ee(h)[1] : T, [O, k] = u(!1), [A, j] = u(""), [M, N] = u(!1), [P, F] = u(E), I = n === void 0 ? P : n, [L, R] = u(D), { fieldErrors: z } = X(), B = l(null), V = S || s(), H = o || z?.[v], U = !!H, W = a || c, G = l(null);
|
|
2568
3112
|
function K() {
|
|
2569
3113
|
W || O || M || (k(!0), G.current && G.current.focus());
|
|
@@ -2571,10 +3115,10 @@ function Ln(e) {
|
|
|
2571
3115
|
function q() {
|
|
2572
3116
|
N(!0), k(!0);
|
|
2573
3117
|
}
|
|
2574
|
-
function
|
|
3118
|
+
function J() {
|
|
2575
3119
|
N(!1), k(!1);
|
|
2576
3120
|
}
|
|
2577
|
-
function
|
|
3121
|
+
function te() {
|
|
2578
3122
|
k(!0);
|
|
2579
3123
|
}
|
|
2580
3124
|
function ie() {
|
|
@@ -2587,7 +3131,7 @@ function Ln(e) {
|
|
|
2587
3131
|
let t = L.code;
|
|
2588
3132
|
return t += re(e || I), t;
|
|
2589
3133
|
}
|
|
2590
|
-
return /* @__PURE__ */ p(
|
|
3134
|
+
return /* @__PURE__ */ p(et, {
|
|
2591
3135
|
name: v,
|
|
2592
3136
|
label: r,
|
|
2593
3137
|
showAsterisk: _,
|
|
@@ -2595,7 +3139,7 @@ function Ln(e) {
|
|
|
2595
3139
|
errorMessage: H,
|
|
2596
3140
|
unShowFieldTemplate: C,
|
|
2597
3141
|
orientation: w,
|
|
2598
|
-
children: /* @__PURE__ */ m(
|
|
3142
|
+
children: /* @__PURE__ */ m(Qn, {
|
|
2599
3143
|
disabled: W,
|
|
2600
3144
|
isError: U,
|
|
2601
3145
|
isLoading: c,
|
|
@@ -2605,17 +3149,17 @@ function Ln(e) {
|
|
|
2605
3149
|
variant: g,
|
|
2606
3150
|
onFocus: K,
|
|
2607
3151
|
children: [
|
|
2608
|
-
/* @__PURE__ */ p(
|
|
3152
|
+
/* @__PURE__ */ p(nr, {
|
|
2609
3153
|
currentCountry: L,
|
|
2610
3154
|
onClick: q,
|
|
2611
3155
|
size: f
|
|
2612
3156
|
}),
|
|
2613
|
-
/* @__PURE__ */ m(
|
|
3157
|
+
/* @__PURE__ */ m(tr, {
|
|
2614
3158
|
isOpen: W || d ? !1 : M,
|
|
2615
3159
|
search: A,
|
|
2616
3160
|
placeholder: b,
|
|
2617
3161
|
onSearch: j,
|
|
2618
|
-
children: [ce.filter((e) => Y(e)).map((e) => /* @__PURE__ */ p(
|
|
3162
|
+
children: [ce.filter((e) => Y(e)).map((e) => /* @__PURE__ */ p(er, {
|
|
2619
3163
|
country: e,
|
|
2620
3164
|
handleChangeValue: () => {
|
|
2621
3165
|
R(e), N(!1), F("");
|
|
@@ -2624,11 +3168,11 @@ function Ln(e) {
|
|
|
2624
3168
|
size: f
|
|
2625
3169
|
}, e.iso)), ce.filter((e) => Y(e)).length === 0 && /* @__PURE__ */ p("p", { children: x })]
|
|
2626
3170
|
}),
|
|
2627
|
-
/* @__PURE__ */ p(
|
|
3171
|
+
/* @__PURE__ */ p($n, {
|
|
2628
3172
|
isOpen: W || d ? !1 : M,
|
|
2629
|
-
onClick:
|
|
3173
|
+
onClick: J
|
|
2630
3174
|
}),
|
|
2631
|
-
/* @__PURE__ */ p(
|
|
3175
|
+
/* @__PURE__ */ p(lr, {
|
|
2632
3176
|
id: V,
|
|
2633
3177
|
ref: G,
|
|
2634
3178
|
readonly: d,
|
|
@@ -2636,7 +3180,7 @@ function Ln(e) {
|
|
|
2636
3180
|
value: I,
|
|
2637
3181
|
disabled: W,
|
|
2638
3182
|
onBlur: ie,
|
|
2639
|
-
onFocus:
|
|
3183
|
+
onFocus: te,
|
|
2640
3184
|
size: f,
|
|
2641
3185
|
onChange: (e) => {
|
|
2642
3186
|
F(e), y && y(ae(e));
|
|
@@ -2654,12 +3198,12 @@ function Ln(e) {
|
|
|
2654
3198
|
}
|
|
2655
3199
|
//#endregion
|
|
2656
3200
|
//#region src/components/popover/index.tsx
|
|
2657
|
-
function
|
|
3201
|
+
function dr(e) {
|
|
2658
3202
|
let { children: t, button: n, closeOnClick: r, className: i = "", orientation: a = "bottomLeft" } = e, [o, s] = u(!1), c = `arkynPopover ${a} ${o ? "visibleTrue" : "visibleFalse"} ${i}`;
|
|
2659
3203
|
function l() {
|
|
2660
3204
|
o || s(!0);
|
|
2661
3205
|
}
|
|
2662
|
-
return
|
|
3206
|
+
return ot(o), /* @__PURE__ */ m("div", {
|
|
2663
3207
|
className: c,
|
|
2664
3208
|
onClick: l,
|
|
2665
3209
|
children: [
|
|
@@ -2686,10 +3230,10 @@ function Rn(e) {
|
|
|
2686
3230
|
}
|
|
2687
3231
|
//#endregion
|
|
2688
3232
|
//#region src/components/radio/radioContext.tsx
|
|
2689
|
-
var
|
|
2690
|
-
function
|
|
3233
|
+
var fr = n({});
|
|
3234
|
+
function pr(e) {
|
|
2691
3235
|
let { children: t, size: n, isError: r, handleChange: i, value: a, disabled: o } = e;
|
|
2692
|
-
return /* @__PURE__ */ p(
|
|
3236
|
+
return /* @__PURE__ */ p(fr.Provider, {
|
|
2693
3237
|
value: {
|
|
2694
3238
|
handleChange: i,
|
|
2695
3239
|
value: a,
|
|
@@ -2700,13 +3244,13 @@ function Bn(e) {
|
|
|
2700
3244
|
children: t
|
|
2701
3245
|
});
|
|
2702
3246
|
}
|
|
2703
|
-
function
|
|
2704
|
-
return a(
|
|
3247
|
+
function mr() {
|
|
3248
|
+
return a(fr);
|
|
2705
3249
|
}
|
|
2706
3250
|
//#endregion
|
|
2707
3251
|
//#region src/components/radio/radioBox/index.tsx
|
|
2708
|
-
function
|
|
2709
|
-
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 } =
|
|
3252
|
+
function hr(e) {
|
|
3253
|
+
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 } = mr(), g = d === t, _ = n || u, v = r || h, y = `arkynRadioBox ${_} ${g ? "checkedTrue" : "checkedFalse"} ${f ? "errorTrue" : "errorFalse"} ${v ? "disabledTrue" : "disabledFalse"} ${a}`;
|
|
2710
3254
|
function b(e) {
|
|
2711
3255
|
o && o(e), l(t);
|
|
2712
3256
|
}
|
|
@@ -2726,13 +3270,13 @@ function Hn(e) {
|
|
|
2726
3270
|
}
|
|
2727
3271
|
//#endregion
|
|
2728
3272
|
//#region src/components/radio/radioGroup/index.tsx
|
|
2729
|
-
function
|
|
2730
|
-
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 = "
|
|
3273
|
+
function gr(e) {
|
|
3274
|
+
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 } = X();
|
|
2731
3275
|
function b(e) {
|
|
2732
3276
|
v(e), s && s(e);
|
|
2733
3277
|
}
|
|
2734
3278
|
let x = a || y?.[n], S = !!x, C = `arkynRadioGroup ${c}`;
|
|
2735
|
-
return /* @__PURE__ */ p(
|
|
3279
|
+
return /* @__PURE__ */ p(et, {
|
|
2736
3280
|
name: n,
|
|
2737
3281
|
label: r,
|
|
2738
3282
|
showAsterisk: i,
|
|
@@ -2740,7 +3284,7 @@ function Un(e) {
|
|
|
2740
3284
|
errorMessage: x,
|
|
2741
3285
|
unShowFieldTemplate: f,
|
|
2742
3286
|
orientation: h,
|
|
2743
|
-
children: /* @__PURE__ */ m(
|
|
3287
|
+
children: /* @__PURE__ */ m(pr, {
|
|
2744
3288
|
isError: S,
|
|
2745
3289
|
size: c,
|
|
2746
3290
|
value: o || _,
|
|
@@ -2761,7 +3305,7 @@ function Un(e) {
|
|
|
2761
3305
|
}
|
|
2762
3306
|
//#endregion
|
|
2763
3307
|
//#region src/services/isBlockActive.ts
|
|
2764
|
-
function
|
|
3308
|
+
function _r(e, t, n = "type") {
|
|
2765
3309
|
let { selection: r } = e;
|
|
2766
3310
|
if (!r) return !1;
|
|
2767
3311
|
let [i] = Array.from(ue.nodes(e, {
|
|
@@ -2772,15 +3316,15 @@ function Wn(e, t, n = "type") {
|
|
|
2772
3316
|
}
|
|
2773
3317
|
//#endregion
|
|
2774
3318
|
//#region src/templates/richTextTemplates.ts
|
|
2775
|
-
var
|
|
3319
|
+
var vr = {
|
|
2776
3320
|
"mod+b": "bold",
|
|
2777
3321
|
"mod+i": "italic",
|
|
2778
3322
|
"mod+u": "underline",
|
|
2779
3323
|
"mod+`": "code"
|
|
2780
|
-
},
|
|
3324
|
+
}, yr = [{
|
|
2781
3325
|
type: "paragraph",
|
|
2782
3326
|
children: [{ text: "" }]
|
|
2783
|
-
}],
|
|
3327
|
+
}], br = ["listItem", "numberedList"], xr = [
|
|
2784
3328
|
"left",
|
|
2785
3329
|
"center",
|
|
2786
3330
|
"right",
|
|
@@ -2788,14 +3332,14 @@ var Gn = {
|
|
|
2788
3332
|
];
|
|
2789
3333
|
//#endregion
|
|
2790
3334
|
//#region src/services/toggleBlock.ts
|
|
2791
|
-
function
|
|
2792
|
-
let n =
|
|
3335
|
+
function Sr(e, t) {
|
|
3336
|
+
let n = _r(e, t, xr.includes(t) ? "align" : "type"), r = br.includes(t);
|
|
2793
3337
|
me.unwrapNodes(e, {
|
|
2794
|
-
match: (e) => !ue.isEditor(e) && de.isElement(e) &&
|
|
3338
|
+
match: (e) => !ue.isEditor(e) && de.isElement(e) && br.includes(e.type) && !xr.includes(t),
|
|
2795
3339
|
split: !0
|
|
2796
3340
|
});
|
|
2797
3341
|
let i;
|
|
2798
|
-
if (i =
|
|
3342
|
+
if (i = xr.includes(t) ? { align: n ? void 0 : t } : { type: n ? "paragraph" : r ? "listItem" : t }, me.setNodes(e, i), !n && r) {
|
|
2799
3343
|
let n = {
|
|
2800
3344
|
type: t,
|
|
2801
3345
|
children: []
|
|
@@ -2805,10 +3349,10 @@ function Yn(e, t) {
|
|
|
2805
3349
|
}
|
|
2806
3350
|
//#endregion
|
|
2807
3351
|
//#region src/components/richText/blockButton/index.tsx
|
|
2808
|
-
function
|
|
2809
|
-
let n = ye(), r =
|
|
3352
|
+
function Cr({ format: e, icon: t }) {
|
|
3353
|
+
let n = ye(), r = _r(n, e, xr.includes(e) ? "align" : "type") ? "activeTrue" : "activeFalse";
|
|
2810
3354
|
function i(t) {
|
|
2811
|
-
t.preventDefault(),
|
|
3355
|
+
t.preventDefault(), Sr(n, e);
|
|
2812
3356
|
}
|
|
2813
3357
|
return /* @__PURE__ */ p("button", {
|
|
2814
3358
|
type: "button",
|
|
@@ -2819,7 +3363,7 @@ function Xn({ format: e, icon: t }) {
|
|
|
2819
3363
|
}
|
|
2820
3364
|
//#endregion
|
|
2821
3365
|
//#region src/components/richText/element/index.tsx
|
|
2822
|
-
function
|
|
3366
|
+
function wr({ attributes: e, children: t, element: n }) {
|
|
2823
3367
|
let r = { textAlign: n.align };
|
|
2824
3368
|
switch (n.type) {
|
|
2825
3369
|
case "blockQuote": return /* @__PURE__ */ p("blockquote", {
|
|
@@ -2889,20 +3433,20 @@ function Zn({ attributes: e, children: t, element: n }) {
|
|
|
2889
3433
|
}
|
|
2890
3434
|
//#endregion
|
|
2891
3435
|
//#region src/components/tab/tabContext.tsx
|
|
2892
|
-
var
|
|
2893
|
-
function
|
|
2894
|
-
return a(
|
|
3436
|
+
var Tr = n({});
|
|
3437
|
+
function Er() {
|
|
3438
|
+
return a(Tr);
|
|
2895
3439
|
}
|
|
2896
|
-
function
|
|
2897
|
-
return /* @__PURE__ */ p(
|
|
3440
|
+
function Dr(e) {
|
|
3441
|
+
return /* @__PURE__ */ p(Tr.Provider, {
|
|
2898
3442
|
value: e,
|
|
2899
3443
|
children: e.children
|
|
2900
3444
|
});
|
|
2901
3445
|
}
|
|
2902
3446
|
//#endregion
|
|
2903
3447
|
//#region src/components/tab/tabButton/index.tsx
|
|
2904
|
-
function
|
|
2905
|
-
let { children: t, disabled: n = !1, className: r = "", onClick: i, value: a, ...o } = e, { disabled: s, currentTab: c, changeCurrentTab: l } =
|
|
3448
|
+
function Or(e) {
|
|
3449
|
+
let { children: t, disabled: n = !1, className: r = "", onClick: i, value: a, ...o } = e, { disabled: s, currentTab: c, changeCurrentTab: l } = Er(), u = s || n, d = `arkynTabButton ${u ? "isDisabled" : ""} ${c === a && a ? "isActive" : ""} ${r}`;
|
|
2906
3450
|
function f(e) {
|
|
2907
3451
|
l(a), i && i(e);
|
|
2908
3452
|
}
|
|
@@ -2917,12 +3461,12 @@ function tr(e) {
|
|
|
2917
3461
|
}
|
|
2918
3462
|
//#endregion
|
|
2919
3463
|
//#region src/components/tab/tabContainer/index.tsx
|
|
2920
|
-
function
|
|
3464
|
+
function kr(e) {
|
|
2921
3465
|
let { children: t, onChange: n, defaultValue: r, disabled: i = !1, className: a, ...o } = e, [s, c] = u(r || ""), l = `arkynTabContainer ${a || ""}`;
|
|
2922
3466
|
function d(e) {
|
|
2923
3467
|
c(e), n && n(e);
|
|
2924
3468
|
}
|
|
2925
|
-
return /* @__PURE__ */ p(
|
|
3469
|
+
return /* @__PURE__ */ p(Dr, {
|
|
2926
3470
|
disabled: i,
|
|
2927
3471
|
currentTab: s,
|
|
2928
3472
|
changeCurrentTab: d,
|
|
@@ -2935,7 +3479,7 @@ function nr(e) {
|
|
|
2935
3479
|
}
|
|
2936
3480
|
//#endregion
|
|
2937
3481
|
//#region src/components/richText/insertImage/index.tsx
|
|
2938
|
-
function
|
|
3482
|
+
function Ar(e) {
|
|
2939
3483
|
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 = ye(), [l, d] = u(!1), [h, g] = u(""), [_, v] = u("url");
|
|
2940
3484
|
function y(e) {
|
|
2941
3485
|
e.preventDefault(), !(!h || h === "") && (c.insertNodes([
|
|
@@ -2959,26 +3503,26 @@ function rr(e) {
|
|
|
2959
3503
|
className: "arkynRichTextInsertImage",
|
|
2960
3504
|
onMouseDown: () => d(!0),
|
|
2961
3505
|
children: /* @__PURE__ */ p(P, {})
|
|
2962
|
-
}), /* @__PURE__ */ m(
|
|
3506
|
+
}), /* @__PURE__ */ m(Pn, {
|
|
2963
3507
|
isVisible: l,
|
|
2964
3508
|
makeInvisible: () => d(!1),
|
|
2965
3509
|
children: [
|
|
2966
|
-
/* @__PURE__ */ p(
|
|
3510
|
+
/* @__PURE__ */ p(In, { children: s }),
|
|
2967
3511
|
/* @__PURE__ */ m("div", {
|
|
2968
3512
|
className: "arkynRichTextInsertImageModalContent",
|
|
2969
3513
|
children: [
|
|
2970
|
-
/* @__PURE__ */ m(
|
|
3514
|
+
/* @__PURE__ */ m(kr, {
|
|
2971
3515
|
defaultValue: _,
|
|
2972
3516
|
onChange: v,
|
|
2973
|
-
children: [/* @__PURE__ */ p(
|
|
3517
|
+
children: [/* @__PURE__ */ p(Or, {
|
|
2974
3518
|
value: "url",
|
|
2975
3519
|
children: n[0]
|
|
2976
|
-
}), /* @__PURE__ */ p(
|
|
3520
|
+
}), /* @__PURE__ */ p(Or, {
|
|
2977
3521
|
value: "file",
|
|
2978
3522
|
children: n[1]
|
|
2979
3523
|
})]
|
|
2980
3524
|
}),
|
|
2981
|
-
_ === "url" && /* @__PURE__ */ m(f, { children: [/* @__PURE__ */ p(
|
|
3525
|
+
_ === "url" && /* @__PURE__ */ m(f, { children: [/* @__PURE__ */ p(st, {
|
|
2982
3526
|
type: "text",
|
|
2983
3527
|
name: "richTextImageURL",
|
|
2984
3528
|
label: o,
|
|
@@ -2990,7 +3534,7 @@ function rr(e) {
|
|
|
2990
3534
|
src: h,
|
|
2991
3535
|
alt: "preview"
|
|
2992
3536
|
})] }),
|
|
2993
|
-
_ === "file" && /* @__PURE__ */ p(
|
|
3537
|
+
_ === "file" && /* @__PURE__ */ p(Tn, {
|
|
2994
3538
|
name: "richTextImageURL",
|
|
2995
3539
|
action: t,
|
|
2996
3540
|
label: a,
|
|
@@ -3000,7 +3544,7 @@ function rr(e) {
|
|
|
3000
3544
|
})
|
|
3001
3545
|
]
|
|
3002
3546
|
}),
|
|
3003
|
-
/* @__PURE__ */ m(
|
|
3547
|
+
/* @__PURE__ */ m(Fn, { children: [/* @__PURE__ */ p(Q, {
|
|
3004
3548
|
type: "button",
|
|
3005
3549
|
scheme: "danger",
|
|
3006
3550
|
variant: "outline",
|
|
@@ -3016,7 +3560,7 @@ function rr(e) {
|
|
|
3016
3560
|
}
|
|
3017
3561
|
//#endregion
|
|
3018
3562
|
//#region src/components/richText/insertVideo/index.tsx
|
|
3019
|
-
function
|
|
3563
|
+
function jr(e) {
|
|
3020
3564
|
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 = ye(), [c, l] = u(!1), [d, h] = u(""), [g, _] = u(""), [v, y] = u("");
|
|
3021
3565
|
function b(e) {
|
|
3022
3566
|
if (e.preventDefault(), !d || d === "") return;
|
|
@@ -3049,14 +3593,14 @@ function ir(e) {
|
|
|
3049
3593
|
className: "arkynRichTextInsertVideo",
|
|
3050
3594
|
onMouseDown: () => l(!0),
|
|
3051
3595
|
children: /* @__PURE__ */ p(G, {})
|
|
3052
|
-
}), /* @__PURE__ */ m(
|
|
3596
|
+
}), /* @__PURE__ */ m(Pn, {
|
|
3053
3597
|
isVisible: c,
|
|
3054
3598
|
makeInvisible: () => l(!1),
|
|
3055
3599
|
children: [
|
|
3056
|
-
/* @__PURE__ */ p(
|
|
3600
|
+
/* @__PURE__ */ p(In, { children: i }),
|
|
3057
3601
|
/* @__PURE__ */ m("div", {
|
|
3058
3602
|
className: "arkynRichTextInsertVideoModalContent",
|
|
3059
|
-
children: [/* @__PURE__ */ p(
|
|
3603
|
+
children: [/* @__PURE__ */ p(st, {
|
|
3060
3604
|
type: "text",
|
|
3061
3605
|
name: "richTextVideoURL",
|
|
3062
3606
|
label: r,
|
|
@@ -3074,7 +3618,7 @@ function ir(e) {
|
|
|
3074
3618
|
allowFullScreen: !0
|
|
3075
3619
|
})]
|
|
3076
3620
|
}),
|
|
3077
|
-
/* @__PURE__ */ m(
|
|
3621
|
+
/* @__PURE__ */ m(Fn, { children: [/* @__PURE__ */ p(Q, {
|
|
3078
3622
|
type: "button",
|
|
3079
3623
|
scheme: "danger",
|
|
3080
3624
|
variant: "outline",
|
|
@@ -3091,7 +3635,7 @@ function ir(e) {
|
|
|
3091
3635
|
}
|
|
3092
3636
|
//#endregion
|
|
3093
3637
|
//#region src/components/richText/leaf/index.tsx
|
|
3094
|
-
function
|
|
3638
|
+
function Mr({ attributes: e, children: t, leaf: n }) {
|
|
3095
3639
|
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 })), /* @__PURE__ */ p("span", {
|
|
3096
3640
|
...e,
|
|
3097
3641
|
children: t
|
|
@@ -3099,21 +3643,21 @@ function ar({ attributes: e, children: t, leaf: n }) {
|
|
|
3099
3643
|
}
|
|
3100
3644
|
//#endregion
|
|
3101
3645
|
//#region src/services/isMarkActive.ts
|
|
3102
|
-
function
|
|
3646
|
+
function Nr(e, t) {
|
|
3103
3647
|
let n = ue.marks(e);
|
|
3104
3648
|
return n ? n[t] === !0 : !1;
|
|
3105
3649
|
}
|
|
3106
3650
|
//#endregion
|
|
3107
3651
|
//#region src/services/toggleMark.ts
|
|
3108
|
-
function
|
|
3109
|
-
|
|
3652
|
+
function Pr(e, t) {
|
|
3653
|
+
Nr(e, t) ? ue.removeMark(e, t) : ue.addMark(e, t, !0);
|
|
3110
3654
|
}
|
|
3111
3655
|
//#endregion
|
|
3112
3656
|
//#region src/components/richText/markButton/index.tsx
|
|
3113
|
-
function
|
|
3114
|
-
let n = ye(), r =
|
|
3657
|
+
function Fr({ format: e, icon: t }) {
|
|
3658
|
+
let n = ye(), r = Nr(n, e) ? "activeTrue" : "activeFalse";
|
|
3115
3659
|
function i(t) {
|
|
3116
|
-
t.preventDefault(),
|
|
3660
|
+
t.preventDefault(), Pr(n, e);
|
|
3117
3661
|
}
|
|
3118
3662
|
return /* @__PURE__ */ p("button", {
|
|
3119
3663
|
type: "button",
|
|
@@ -3124,7 +3668,7 @@ function cr({ format: e, icon: t }) {
|
|
|
3124
3668
|
}
|
|
3125
3669
|
//#endregion
|
|
3126
3670
|
//#region src/components/richText/toolbar/index.tsx
|
|
3127
|
-
function
|
|
3671
|
+
function Ir({ children: e }) {
|
|
3128
3672
|
return /* @__PURE__ */ p("div", {
|
|
3129
3673
|
className: "arkynRichTextToolbar",
|
|
3130
3674
|
children: e
|
|
@@ -3132,31 +3676,31 @@ function lr({ children: e }) {
|
|
|
3132
3676
|
}
|
|
3133
3677
|
//#endregion
|
|
3134
3678
|
//#region src/services/extractTextFromNode.ts
|
|
3135
|
-
function
|
|
3679
|
+
function Lr(e) {
|
|
3136
3680
|
return e.map((e) => fe.string(e)).join("");
|
|
3137
3681
|
}
|
|
3138
3682
|
//#endregion
|
|
3139
3683
|
//#region src/components/richText/index.tsx
|
|
3140
|
-
function
|
|
3141
|
-
let { name: t, hiddenButtons: n, imageConfig: r, videoConfig: a, className: o = "", defaultValue: d = "[]", enforceCharacterLimit: f = !1, onChangeCharactersCount: h, baseErrorMessage: x, maxLimit: S = 1e4, onChange: C, isError: w, label: T, showAsterisk: D, id: O, orientation: k = "
|
|
3684
|
+
function Rr(e) {
|
|
3685
|
+
let { name: t, hiddenButtons: n, imageConfig: r, videoConfig: a, className: o = "", defaultValue: d = "[]", enforceCharacterLimit: f = !1, onChangeCharactersCount: h, baseErrorMessage: x, maxLimit: S = 1e4, onChange: C, isError: w, label: T, showAsterisk: D, id: O, orientation: k = "vertical", unShowFieldTemplate: A = !1 } = e, j = c(() => ge(be(he())), []), { fieldErrors: P } = X();
|
|
3142
3686
|
function F() {
|
|
3143
3687
|
try {
|
|
3144
3688
|
let e = JSON.parse(d);
|
|
3145
|
-
return !Array.isArray(e) || e.length <= 0 ?
|
|
3689
|
+
return !Array.isArray(e) || e.length <= 0 ? yr : e.every((e) => typeof e == "object" && !!e && "type" in e && "children" in e) ? e : yr;
|
|
3146
3690
|
} catch {
|
|
3147
|
-
return
|
|
3691
|
+
return yr;
|
|
3148
3692
|
}
|
|
3149
3693
|
}
|
|
3150
|
-
let [L, R] = u(
|
|
3694
|
+
let [L, R] = u(Lr(F()).length), [z, B] = u(JSON.stringify(F()) || "[]"), [H, U] = u(!1), G = l(null), K = O || s(), q = x || P?.[t], ee = w || !!q, J = i(Mr, []), te = i(wr, []);
|
|
3151
3695
|
function ne(e) {
|
|
3152
|
-
let t =
|
|
3696
|
+
let t = Lr(e);
|
|
3153
3697
|
R(t.length), h && h(t.length), !(f && t.length >= S) && (B(JSON.stringify(e)), C && C(e), j.children = e, me.setNodes(j, { children: e }));
|
|
3154
3698
|
}
|
|
3155
3699
|
let re = `arkynRichText ${ee || S < L ? "errorTrue" : "errorFalse"} ${H ? "focusTrue" : "focusFalse"}`, ie = S - L;
|
|
3156
3700
|
function Y(e) {
|
|
3157
3701
|
return !n?.includes(e);
|
|
3158
3702
|
}
|
|
3159
|
-
return /* @__PURE__ */ p(
|
|
3703
|
+
return /* @__PURE__ */ p(et, {
|
|
3160
3704
|
name: t,
|
|
3161
3705
|
label: T,
|
|
3162
3706
|
showAsterisk: D,
|
|
@@ -3173,68 +3717,68 @@ function dr(e) {
|
|
|
3173
3717
|
/* @__PURE__ */ m("div", {
|
|
3174
3718
|
className: re,
|
|
3175
3719
|
children: [
|
|
3176
|
-
/* @__PURE__ */ m(
|
|
3177
|
-
Y("headingOne") && /* @__PURE__ */ p(
|
|
3720
|
+
/* @__PURE__ */ m(Ir, { children: [
|
|
3721
|
+
Y("headingOne") && /* @__PURE__ */ p(Cr, {
|
|
3178
3722
|
format: "headingOne",
|
|
3179
3723
|
icon: M
|
|
3180
3724
|
}),
|
|
3181
|
-
Y("headingTwo") && /* @__PURE__ */ p(
|
|
3725
|
+
Y("headingTwo") && /* @__PURE__ */ p(Cr, {
|
|
3182
3726
|
format: "headingTwo",
|
|
3183
3727
|
icon: N
|
|
3184
3728
|
}),
|
|
3185
|
-
Y("blockQuote") && /* @__PURE__ */ p(
|
|
3729
|
+
Y("blockQuote") && /* @__PURE__ */ p(Cr, {
|
|
3186
3730
|
format: "blockQuote",
|
|
3187
3731
|
icon: V
|
|
3188
3732
|
}),
|
|
3189
|
-
Y("bold") && /* @__PURE__ */ p(
|
|
3733
|
+
Y("bold") && /* @__PURE__ */ p(Fr, {
|
|
3190
3734
|
format: "bold",
|
|
3191
3735
|
icon: b
|
|
3192
3736
|
}),
|
|
3193
|
-
Y("italic") && /* @__PURE__ */ p(
|
|
3737
|
+
Y("italic") && /* @__PURE__ */ p(Fr, {
|
|
3194
3738
|
format: "italic",
|
|
3195
3739
|
icon: I
|
|
3196
3740
|
}),
|
|
3197
|
-
Y("underline") && /* @__PURE__ */ p(
|
|
3741
|
+
Y("underline") && /* @__PURE__ */ p(Fr, {
|
|
3198
3742
|
format: "underline",
|
|
3199
3743
|
icon: W
|
|
3200
3744
|
}),
|
|
3201
|
-
Y("code") && /* @__PURE__ */ p(
|
|
3745
|
+
Y("code") && /* @__PURE__ */ p(Fr, {
|
|
3202
3746
|
format: "code",
|
|
3203
3747
|
icon: E
|
|
3204
3748
|
}),
|
|
3205
|
-
Y("left") && /* @__PURE__ */ p(
|
|
3749
|
+
Y("left") && /* @__PURE__ */ p(Cr, {
|
|
3206
3750
|
format: "left",
|
|
3207
3751
|
icon: v
|
|
3208
3752
|
}),
|
|
3209
|
-
Y("right") && /* @__PURE__ */ p(
|
|
3753
|
+
Y("right") && /* @__PURE__ */ p(Cr, {
|
|
3210
3754
|
format: "right",
|
|
3211
3755
|
icon: y
|
|
3212
3756
|
}),
|
|
3213
|
-
Y("center") && /* @__PURE__ */ p(
|
|
3757
|
+
Y("center") && /* @__PURE__ */ p(Cr, {
|
|
3214
3758
|
format: "center",
|
|
3215
3759
|
icon: g
|
|
3216
3760
|
}),
|
|
3217
|
-
Y("justify") && /* @__PURE__ */ p(
|
|
3761
|
+
Y("justify") && /* @__PURE__ */ p(Cr, {
|
|
3218
3762
|
format: "justify",
|
|
3219
3763
|
icon: _
|
|
3220
3764
|
}),
|
|
3221
|
-
r && Y("image") && /* @__PURE__ */ p(
|
|
3222
|
-
Y("video") && /* @__PURE__ */ p(
|
|
3765
|
+
r && Y("image") && /* @__PURE__ */ p(Ar, { ...r }),
|
|
3766
|
+
Y("video") && /* @__PURE__ */ p(jr, { ...a })
|
|
3223
3767
|
] }),
|
|
3224
3768
|
/* @__PURE__ */ p(_e, {
|
|
3225
3769
|
className: "editorContainer",
|
|
3226
|
-
renderElement:
|
|
3227
|
-
renderLeaf:
|
|
3770
|
+
renderElement: te,
|
|
3771
|
+
renderLeaf: J,
|
|
3228
3772
|
spellCheck: !0,
|
|
3229
3773
|
ref: G,
|
|
3230
3774
|
id: K,
|
|
3231
3775
|
onFocus: () => U(!0),
|
|
3232
3776
|
onBlur: () => U(!1),
|
|
3233
3777
|
onKeyDown: (e) => {
|
|
3234
|
-
for (let t in
|
|
3778
|
+
for (let t in vr) if (le(t, e)) {
|
|
3235
3779
|
e.preventDefault();
|
|
3236
|
-
let n =
|
|
3237
|
-
|
|
3780
|
+
let n = vr[t];
|
|
3781
|
+
Pr(j, n);
|
|
3238
3782
|
}
|
|
3239
3783
|
}
|
|
3240
3784
|
}),
|
|
@@ -3260,7 +3804,7 @@ function dr(e) {
|
|
|
3260
3804
|
}
|
|
3261
3805
|
//#endregion
|
|
3262
3806
|
//#region src/components/searchPlaces.tsx
|
|
3263
|
-
function
|
|
3807
|
+
function zr(e) {
|
|
3264
3808
|
let { onChange: t, onPlaceChanged: n, options: r, ...i } = e, [a, o] = u(null);
|
|
3265
3809
|
return /* @__PURE__ */ p(xe, {
|
|
3266
3810
|
onLoad: (e) => o(e),
|
|
@@ -3303,7 +3847,7 @@ function fr(e) {
|
|
|
3303
3847
|
}
|
|
3304
3848
|
},
|
|
3305
3849
|
options: r,
|
|
3306
|
-
children: /* @__PURE__ */ p(
|
|
3850
|
+
children: /* @__PURE__ */ p(st, {
|
|
3307
3851
|
type: "text",
|
|
3308
3852
|
autoComplete: "off",
|
|
3309
3853
|
onChange: (e) => t && t(e.target.value),
|
|
@@ -3313,12 +3857,12 @@ function fr(e) {
|
|
|
3313
3857
|
}
|
|
3314
3858
|
//#endregion
|
|
3315
3859
|
//#region src/components/switch/index.tsx
|
|
3316
|
-
function
|
|
3860
|
+
function Br(e) {
|
|
3317
3861
|
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 = m || s(), [C, w] = u(r), T = typeof i == "boolean" ? i : C;
|
|
3318
3862
|
function E() {
|
|
3319
3863
|
w(!C), f && f(T ? o : a || "checked");
|
|
3320
3864
|
}
|
|
3321
|
-
return /* @__PURE__ */ p(
|
|
3865
|
+
return /* @__PURE__ */ p(et, {
|
|
3322
3866
|
name: c,
|
|
3323
3867
|
label: t,
|
|
3324
3868
|
showAsterisk: _,
|
|
@@ -3344,7 +3888,7 @@ function pr(e) {
|
|
|
3344
3888
|
}
|
|
3345
3889
|
//#endregion
|
|
3346
3890
|
//#region src/components/table/tableBody/index.tsx
|
|
3347
|
-
function
|
|
3891
|
+
function Vr(t) {
|
|
3348
3892
|
let { emptyMessage: n = "Nenhum dado adicionado.", className: r, children: i, ...a } = t, o = `arkynTableBody ${r}`, s = e.count(i) === 0;
|
|
3349
3893
|
return /* @__PURE__ */ p("tbody", {
|
|
3350
3894
|
className: o.trim(),
|
|
@@ -3360,7 +3904,7 @@ function mr(t) {
|
|
|
3360
3904
|
}
|
|
3361
3905
|
//#endregion
|
|
3362
3906
|
//#region src/components/table/tableCaption/index.tsx
|
|
3363
|
-
function
|
|
3907
|
+
function Hr(e) {
|
|
3364
3908
|
let { className: t, children: n, ...r } = e;
|
|
3365
3909
|
return /* @__PURE__ */ p("caption", {
|
|
3366
3910
|
className: `arkynTableCaption ${t}`.trim(),
|
|
@@ -3373,7 +3917,7 @@ function hr(e) {
|
|
|
3373
3917
|
}
|
|
3374
3918
|
//#endregion
|
|
3375
3919
|
//#region src/components/table/tableContainer/index.tsx
|
|
3376
|
-
function
|
|
3920
|
+
function Ur(e) {
|
|
3377
3921
|
let { children: t, className: n, ...r } = e;
|
|
3378
3922
|
return /* @__PURE__ */ p("div", {
|
|
3379
3923
|
className: `arkynTableContainer ${n}`.trim(),
|
|
@@ -3383,7 +3927,7 @@ function gr(e) {
|
|
|
3383
3927
|
}
|
|
3384
3928
|
//#endregion
|
|
3385
3929
|
//#region src/components/table/tableFooter/index.tsx
|
|
3386
|
-
function
|
|
3930
|
+
function Wr(e) {
|
|
3387
3931
|
let { className: t, children: n, ...r } = e;
|
|
3388
3932
|
return /* @__PURE__ */ m("tfoot", {
|
|
3389
3933
|
className: `arkynTableFooter ${t}`.trim(),
|
|
@@ -3399,7 +3943,7 @@ function _r(e) {
|
|
|
3399
3943
|
}
|
|
3400
3944
|
//#endregion
|
|
3401
3945
|
//#region src/components/table/tableHeader/index.tsx
|
|
3402
|
-
function
|
|
3946
|
+
function Gr(e) {
|
|
3403
3947
|
let { className: t, children: n, ...r } = e;
|
|
3404
3948
|
return /* @__PURE__ */ m("thead", {
|
|
3405
3949
|
className: `arkynTableHeader ${t}`.trim(),
|
|
@@ -3409,7 +3953,7 @@ function vr(e) {
|
|
|
3409
3953
|
}
|
|
3410
3954
|
//#endregion
|
|
3411
3955
|
//#region src/components/textarea/index.tsx
|
|
3412
|
-
function
|
|
3956
|
+
function Kr(e) {
|
|
3413
3957
|
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 } = X(), [T, E] = u(!1), D = l(null), O = S || s(), k = i || w?.[f], A = `arkynTextarea ${t} ${n} ${a || o ? "opacityTrue" : "opacityFalse"} ${k ? "errorTrue" : "errorFalse"} ${T ? "focusedTrue" : "focusedFalse"}`;
|
|
3414
3958
|
function j() {
|
|
3415
3959
|
a || !D?.current || (E(!0), D.current.focus());
|
|
@@ -3453,8 +3997,8 @@ function yr(e) {
|
|
|
3453
3997
|
}
|
|
3454
3998
|
//#endregion
|
|
3455
3999
|
//#region src/providers/modalProvider.tsx
|
|
3456
|
-
var
|
|
3457
|
-
function
|
|
4000
|
+
var qr = n({});
|
|
4001
|
+
function Jr(e) {
|
|
3458
4002
|
let { children: t = !1 } = e, [n, r] = u([]);
|
|
3459
4003
|
function i(e) {
|
|
3460
4004
|
return !!n.some((t) => t.key === e);
|
|
@@ -3477,7 +4021,7 @@ function xr(e) {
|
|
|
3477
4021
|
function c() {
|
|
3478
4022
|
r([]);
|
|
3479
4023
|
}
|
|
3480
|
-
return /* @__PURE__ */ p(
|
|
4024
|
+
return /* @__PURE__ */ p(qr.Provider, {
|
|
3481
4025
|
value: {
|
|
3482
4026
|
modalIsOpen: i,
|
|
3483
4027
|
modalData: a,
|
|
@@ -3490,8 +4034,8 @@ function xr(e) {
|
|
|
3490
4034
|
}
|
|
3491
4035
|
//#endregion
|
|
3492
4036
|
//#region src/hooks/useModal.ts
|
|
3493
|
-
function
|
|
3494
|
-
let t = a(
|
|
4037
|
+
function Yr(e) {
|
|
4038
|
+
let t = a(qr);
|
|
3495
4039
|
if (Object.entries(t).length === 0) throw Error("useModal must be used within a Provider");
|
|
3496
4040
|
if (e) {
|
|
3497
4041
|
let { modalData: n, modalIsOpen: r, openModal: i, closeModal: a } = t;
|
|
@@ -3505,8 +4049,8 @@ function Sr(e) {
|
|
|
3505
4049
|
}
|
|
3506
4050
|
//#endregion
|
|
3507
4051
|
//#region src/providers/toastProvider.tsx
|
|
3508
|
-
var
|
|
3509
|
-
function
|
|
4052
|
+
var Xr = n({});
|
|
4053
|
+
function Zr({ children: e }) {
|
|
3510
4054
|
function t(e) {
|
|
3511
4055
|
switch (e.type) {
|
|
3512
4056
|
case "success": return we.success(e.message, {
|
|
@@ -3537,7 +4081,7 @@ function wr({ children: e }) {
|
|
|
3537
4081
|
});
|
|
3538
4082
|
}
|
|
3539
4083
|
}
|
|
3540
|
-
return /* @__PURE__ */ m(
|
|
4084
|
+
return /* @__PURE__ */ m(Xr.Provider, {
|
|
3541
4085
|
value: { showToast: t },
|
|
3542
4086
|
children: [/* @__PURE__ */ p(Te, {
|
|
3543
4087
|
position: "top-right",
|
|
@@ -3547,14 +4091,14 @@ function wr({ children: e }) {
|
|
|
3547
4091
|
}
|
|
3548
4092
|
//#endregion
|
|
3549
4093
|
//#region src/hooks/useToast.ts
|
|
3550
|
-
function
|
|
3551
|
-
let e = a(
|
|
4094
|
+
function Qr() {
|
|
4095
|
+
let e = a(Xr);
|
|
3552
4096
|
if (Object.entries(e).length === 0) throw Error("useToast must be used within a Provider");
|
|
3553
4097
|
return e;
|
|
3554
4098
|
}
|
|
3555
4099
|
//#endregion
|
|
3556
4100
|
//#region src/templates/badResponses.ts
|
|
3557
|
-
var
|
|
4101
|
+
var $r = [
|
|
3558
4102
|
"BadGateway",
|
|
3559
4103
|
"BadRequest",
|
|
3560
4104
|
"Conflict",
|
|
@@ -3564,7 +4108,7 @@ var Er = [
|
|
|
3564
4108
|
"ServerError",
|
|
3565
4109
|
"Unauthorized",
|
|
3566
4110
|
"UnprocessableEntity"
|
|
3567
|
-
],
|
|
4111
|
+
], ei = [
|
|
3568
4112
|
"Created",
|
|
3569
4113
|
"Found",
|
|
3570
4114
|
"Success",
|
|
@@ -3572,15 +4116,15 @@ var Er = [
|
|
|
3572
4116
|
];
|
|
3573
4117
|
//#endregion
|
|
3574
4118
|
//#region src/hooks/useAutomation.ts
|
|
3575
|
-
function
|
|
3576
|
-
let { closeAll: t } =
|
|
4119
|
+
function ti(e) {
|
|
4120
|
+
let { closeAll: t } = Yr(), { showToast: n } = Qr(), r = e?.closeModal, i = e?.message, a = e?.name, s = e?.cause?.data?.scrollTo, c = e?.cause?.fieldErrors ? Object.values(e?.cause?.fieldErrors)[0] : null;
|
|
3577
4121
|
function l() {
|
|
3578
4122
|
if (!(!i && !c)) {
|
|
3579
|
-
if (
|
|
4123
|
+
if (ei.includes(a)) return n({
|
|
3580
4124
|
message: i,
|
|
3581
4125
|
type: "success"
|
|
3582
4126
|
});
|
|
3583
|
-
if (
|
|
4127
|
+
if ($r.includes(a)) {
|
|
3584
4128
|
if (c) return n({
|
|
3585
4129
|
message: c,
|
|
3586
4130
|
type: "danger"
|
|
@@ -3601,8 +4145,8 @@ function Or(e) {
|
|
|
3601
4145
|
}
|
|
3602
4146
|
//#endregion
|
|
3603
4147
|
//#region src/providers/drawerProvider.tsx
|
|
3604
|
-
var
|
|
3605
|
-
function
|
|
4148
|
+
var ni = n({});
|
|
4149
|
+
function ri(e) {
|
|
3606
4150
|
let { children: t = !1 } = e, [n, r] = u([]);
|
|
3607
4151
|
function i(e) {
|
|
3608
4152
|
return !!n.some((t) => t.key === e);
|
|
@@ -3622,7 +4166,7 @@ function Ar(e) {
|
|
|
3622
4166
|
function s(e) {
|
|
3623
4167
|
r(n.filter((t) => t.key !== e));
|
|
3624
4168
|
}
|
|
3625
|
-
return /* @__PURE__ */ p(
|
|
4169
|
+
return /* @__PURE__ */ p(ni.Provider, {
|
|
3626
4170
|
value: {
|
|
3627
4171
|
drawerIsOpen: i,
|
|
3628
4172
|
drawerData: a,
|
|
@@ -3634,8 +4178,8 @@ function Ar(e) {
|
|
|
3634
4178
|
}
|
|
3635
4179
|
//#endregion
|
|
3636
4180
|
//#region src/hooks/useDrawer.ts
|
|
3637
|
-
function
|
|
3638
|
-
let t = a(
|
|
4181
|
+
function ii(e) {
|
|
4182
|
+
let t = a(ni);
|
|
3639
4183
|
if (Object.entries(t).length === 0) throw Error("useDrawer must be used within a Provider");
|
|
3640
4184
|
if (e) {
|
|
3641
4185
|
let { drawerData: n, drawerIsOpen: r, openDrawer: i, closeDrawer: a } = t;
|
|
@@ -3649,7 +4193,7 @@ function jr(e) {
|
|
|
3649
4193
|
}
|
|
3650
4194
|
//#endregion
|
|
3651
4195
|
//#region src/hooks/useScopedParams.ts
|
|
3652
|
-
function
|
|
4196
|
+
function ai(e, t = "") {
|
|
3653
4197
|
let n = new URLSearchParams(e), r = t ? `${t}:` : "", i = (e) => {
|
|
3654
4198
|
Object.entries(e).forEach(([e, t]) => {
|
|
3655
4199
|
t === void 0 ? n.delete(`${r}${e}`) : n.set(`${r}${e}`, String(t));
|
|
@@ -3666,8 +4210,8 @@ function Mr(e, t = "") {
|
|
|
3666
4210
|
}
|
|
3667
4211
|
//#endregion
|
|
3668
4212
|
//#region src/hooks/useSearchAutomation.ts
|
|
3669
|
-
function
|
|
3670
|
-
let { closeAll: n } =
|
|
4213
|
+
function oi(e, t = "") {
|
|
4214
|
+
let { closeAll: n } = Yr(), { showToast: r } = Qr(), { getParam: i } = ai(e, t), a = i("closeModal") === "true", s = i("message"), c = i("name"), l = i("type");
|
|
3671
4215
|
o(() => {
|
|
3672
4216
|
a && n(), s && (l === "success" && r({
|
|
3673
4217
|
message: s,
|
|
@@ -3675,10 +4219,10 @@ function Nr(e, t = "") {
|
|
|
3675
4219
|
}), l === "danger" && r({
|
|
3676
4220
|
message: s,
|
|
3677
4221
|
type: "danger"
|
|
3678
|
-
}), c &&
|
|
4222
|
+
}), c && $r.includes(c) && !$r.includes(s) && r({
|
|
3679
4223
|
message: s,
|
|
3680
4224
|
type: "danger"
|
|
3681
|
-
}), c &&
|
|
4225
|
+
}), c && ei.includes(c) && !ei.includes(s) && r({
|
|
3682
4226
|
message: s,
|
|
3683
4227
|
type: "success"
|
|
3684
4228
|
}));
|
|
@@ -3691,28 +4235,28 @@ function Nr(e, t = "") {
|
|
|
3691
4235
|
}
|
|
3692
4236
|
//#endregion
|
|
3693
4237
|
//#region src/providers/placesProvider.tsx
|
|
3694
|
-
var
|
|
4238
|
+
var si = [
|
|
3695
4239
|
"places",
|
|
3696
4240
|
"marker",
|
|
3697
4241
|
"maps"
|
|
3698
4242
|
];
|
|
3699
|
-
function
|
|
4243
|
+
function ci(e) {
|
|
3700
4244
|
let { apiKey: t, children: n, preventFontsLoading: r = !0 } = e, { isLoaded: i } = Se({
|
|
3701
4245
|
googleMapsApiKey: t,
|
|
3702
|
-
libraries:
|
|
4246
|
+
libraries: si,
|
|
3703
4247
|
preventGoogleFontsLoading: r
|
|
3704
4248
|
});
|
|
3705
4249
|
return /* @__PURE__ */ p(f, { children: n(i) });
|
|
3706
4250
|
}
|
|
3707
4251
|
//#endregion
|
|
3708
4252
|
//#region src/utils/richTextUtilities.ts
|
|
3709
|
-
function
|
|
4253
|
+
function li(e) {
|
|
3710
4254
|
if (pe.isText(e)) {
|
|
3711
4255
|
let t = e?.text;
|
|
3712
4256
|
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>`), t;
|
|
3713
4257
|
}
|
|
3714
4258
|
if (de.isElement(e)) {
|
|
3715
|
-
let t = e.children?.map((e) =>
|
|
4259
|
+
let t = e.children?.map((e) => li(e)).join(""), n = e.align || "left";
|
|
3716
4260
|
switch (e.type) {
|
|
3717
4261
|
case "video": return `<iframe src="${e.src}" class="align_${n}" />`;
|
|
3718
4262
|
case "image": return `<img src="${e.src}" class="align_${n}" />`;
|
|
@@ -3728,9 +4272,9 @@ function Ir(e) {
|
|
|
3728
4272
|
}
|
|
3729
4273
|
return "";
|
|
3730
4274
|
}
|
|
3731
|
-
function
|
|
4275
|
+
function ui(e) {
|
|
3732
4276
|
if (typeof e == "string") return { text: e };
|
|
3733
|
-
let t = Array.isArray(e.props.children) ? e.props.children.map((e) =>
|
|
4277
|
+
let t = Array.isArray(e.props.children) ? e.props.children.map((e) => ui(e)) : [{ text: e.props.children || "" }], n = e.props.className?.replace("align_", "");
|
|
3734
4278
|
switch (e.type) {
|
|
3735
4279
|
case "img": return {
|
|
3736
4280
|
type: "image",
|
|
@@ -3794,14 +4338,14 @@ function Lr(e) {
|
|
|
3794
4338
|
}
|
|
3795
4339
|
//#endregion
|
|
3796
4340
|
//#region src/services/toHtml.ts
|
|
3797
|
-
function
|
|
3798
|
-
return e.map((e) =>
|
|
4341
|
+
function di(e) {
|
|
4342
|
+
return e.map((e) => li(e)).join("");
|
|
3799
4343
|
}
|
|
3800
4344
|
//#endregion
|
|
3801
4345
|
//#region src/services/toRichTextValue.ts
|
|
3802
|
-
function
|
|
4346
|
+
function fi(e) {
|
|
3803
4347
|
let t = Ee(e);
|
|
3804
|
-
return Array.isArray(t) ? t.map((e) => typeof e == "string" ? { text: e } :
|
|
4348
|
+
return Array.isArray(t) ? t.map((e) => typeof e == "string" ? { text: e } : ui(e)) : typeof t == "string" ? [{ text: t }] : [ui(t)];
|
|
3805
4349
|
}
|
|
3806
4350
|
//#endregion
|
|
3807
|
-
export { Ae as AlertContainer, je as AlertContent, Me as AlertDescription, Ne as AlertIcon, De as AlertTitle, Ie as AudioPlayer, qe as AudioUpload, Je as Badge, Q as Button,
|
|
4351
|
+
export { Ae as AlertContainer, je as AlertContent, Me as AlertDescription, Ne as AlertIcon, De as AlertTitle, Ie as AudioPlayer, qe as AudioUpload, Je as Badge, Q as Button, _t as Calendar, xt as CardTabButton, St as CardTabContainer, Ct as Checkbox, Et as ClientOnly, kt as CurrencyInput, He as Divider, Nt as DrawerContainer, Pt as DrawerHeader, ri as DrawerProvider, Lt as FacebookPixel, ze as FieldError, Be as FieldLabel, Ve as FieldWrapper, Bt as FileUpload, Re as FormProvider, pn as FullCalendar, _n as GoogleAnalytics, Sn as GoogleTagManager, Ue as IconButton, Tn as ImageUpload, st as Input, On as MapView, An as MaskedInput, Pn as ModalContainer, Fn as ModalFooter, In as ModalHeader, Jr as ModalProvider, Gn as MultiSelect, Zn as Pagination, ur as PhoneInput, ci as PlacesProvider, dr as Popover, hr as RadioBox, gr as RadioGroup, Rr as RichText, zr as SearchPlaces, dt as Select, Fe as Slider, Br as Switch, Or as TabButton, kr as TabContainer, Vr as TableBody, Hr as TableCaption, Ur as TableContainer, Wr as TableFooter, Gr as TableHeader, Kr as Textarea, Zr as ToastProvider, We as Tooltip, di as toHtml, fi as toRichTextValue, ti as useAutomation, ii as useDrawer, X as useForm, Tt as useHydrated, Yr as useModal, ai as useScopedParams, ot as useScrollLock, oi as useSearchAutomation, Pe as useSlider, Qr as useToast };
|