@arkyn/components 3.0.1-beta.155 → 3.0.1-beta.156
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/calendar/_viewService.d.ts +1 -1
- package/dist/components/fullCalendar/_viewService.d.ts +2 -2
- package/dist/hooks/useScopedParams.d.ts +1 -1
- package/dist/index.js +4683 -4347
- package/dist/modules/components/alert/alertContainer/index.js +20 -25
- package/dist/modules/components/alert/alertContent/index.js +8 -11
- package/dist/modules/components/alert/alertDescription/index.js +8 -11
- package/dist/modules/components/alert/alertIcon/index.js +19 -27
- package/dist/modules/components/alert/alertTitle/index.js +8 -11
- package/dist/modules/components/audioPlayer/index.js +75 -74
- package/dist/modules/components/audioUpload/hasFileContent/index.js +62 -54
- package/dist/modules/components/audioUpload/index.js +79 -71
- package/dist/modules/components/audioUpload/noFileContent/index.js +45 -35
- package/dist/modules/components/badge/index.js +22 -26
- package/dist/modules/components/button/index.js +32 -39
- package/dist/modules/components/calendar/_calendarProvider.js +63 -38
- package/dist/modules/components/calendar/_viewService.js +140 -132
- package/dist/modules/components/calendar/calendarContainer/index.js +7 -10
- package/dist/modules/components/calendar/calendarHeader/index.js +72 -51
- package/dist/modules/components/calendar/calendarTableBody/index.js +10 -12
- package/dist/modules/components/calendar/calendarTableContainer/index.js +7 -10
- package/dist/modules/components/calendar/calendarTableHeader/index.js +10 -13
- package/dist/modules/components/calendar/calendarTableTd/index.js +23 -20
- package/dist/modules/components/calendar/index.js +49 -31
- package/dist/modules/components/cardTab/cardTabButton/index.js +29 -19
- package/dist/modules/components/cardTab/cardTabContainer/index.js +28 -22
- package/dist/modules/components/cardTab/cardTabContext.js +11 -13
- package/dist/modules/components/checkbox/index.js +64 -37
- package/dist/modules/components/clientOnly.js +8 -8
- package/dist/modules/components/currencyInput/index.js +138 -110
- package/dist/modules/components/divider/index.js +11 -10
- package/dist/modules/components/drawer/drawerContainer/index.js +43 -40
- package/dist/modules/components/drawer/drawerContext.js +11 -13
- package/dist/modules/components/drawer/drawerHeader/index.js +27 -20
- package/dist/modules/components/facebookPixel/facebookPixel.client.js +18 -8
- package/dist/modules/components/facebookPixel/index.js +8 -8
- package/dist/modules/components/facebookPixel/pixel.js +52 -47
- package/dist/modules/components/fieldError/index.js +8 -12
- package/dist/modules/components/fieldLabel/index.js +12 -11
- package/dist/modules/components/fieldWrapper/index.js +13 -12
- package/dist/modules/components/fileUpload/hasFileContent/index.js +67 -59
- package/dist/modules/components/fileUpload/index.js +72 -65
- package/dist/modules/components/fileUpload/noFileContent/index.js +45 -35
- package/dist/modules/components/fullCalendar/_fullCalendarProvider.js +46 -33
- package/dist/modules/components/fullCalendar/_viewService.js +105 -100
- package/dist/modules/components/fullCalendar/dayCalendar/dayCalendarContainer/index.js +7 -10
- package/dist/modules/components/fullCalendar/dayCalendar/dayCalendarEvent/index.js +78 -70
- package/dist/modules/components/fullCalendar/dayCalendar/dayCalendarRow/index.js +33 -28
- package/dist/modules/components/fullCalendar/dayCalendar/index.js +9 -12
- package/dist/modules/components/fullCalendar/fullCalendarContainer/index.js +7 -10
- package/dist/modules/components/fullCalendar/fullCalendarHeader/index.js +70 -67
- package/dist/modules/components/fullCalendar/index.js +30 -30
- package/dist/modules/components/fullCalendar/monthlyCalendar/index.js +12 -9
- package/dist/modules/components/fullCalendar/monthlyCalendar/monthlyCalendarEvent/index.js +36 -28
- package/dist/modules/components/fullCalendar/monthlyCalendar/monthlyCalendarTableBody/index.js +9 -11
- package/dist/modules/components/fullCalendar/monthlyCalendar/monthlyCalendarTableContainer/index.js +9 -10
- package/dist/modules/components/fullCalendar/monthlyCalendar/monthlyCalendarTableHeader/index.js +10 -13
- package/dist/modules/components/fullCalendar/monthlyCalendar/monthlyCalendarTableTd/index.js +36 -35
- package/dist/modules/components/fullCalendar/weekCalendar/index.js +11 -8
- package/dist/modules/components/fullCalendar/weekCalendar/weekCalendarEvent/index.js +78 -70
- package/dist/modules/components/fullCalendar/weekCalendar/weekCalendarTableBody/index.js +20 -17
- package/dist/modules/components/fullCalendar/weekCalendar/weekCalendarTableContainer/index.js +8 -9
- package/dist/modules/components/fullCalendar/weekCalendar/weekCalendarTableHeader/index.js +19 -16
- package/dist/modules/components/fullCalendar/weekCalendar/weekCalendarTableTd/index.js +39 -34
- package/dist/modules/components/googleAnalytics/googleAnalytics.client.js +7 -7
- package/dist/modules/components/googleAnalytics/googleAnalytics.js +17 -17
- package/dist/modules/components/googleAnalytics/index.js +9 -9
- package/dist/modules/components/googleAnalytics/snippets/generateGAElements.js +12 -10
- package/dist/modules/components/googleTagManager/googleTagManager.client.js +6 -6
- package/dist/modules/components/googleTagManager/googleTagManager.js +48 -44
- package/dist/modules/components/googleTagManager/index.js +27 -16
- package/dist/modules/components/googleTagManager/snippets/appendToDataLayer.js +8 -8
- package/dist/modules/components/googleTagManager/snippets/generateGTMElements.js +20 -19
- package/dist/modules/components/iconButton/index.js +29 -31
- package/dist/modules/components/imageUpload/hasFileContent/index.js +63 -46
- package/dist/modules/components/imageUpload/index.js +82 -65
- package/dist/modules/components/imageUpload/noFileContent/index.js +45 -35
- package/dist/modules/components/input/index.js +120 -92
- package/dist/modules/components/mapView/index.js +31 -27
- package/dist/modules/components/mapView/mapView.client.js +51 -49
- package/dist/modules/components/maskedInput/index.js +112 -101
- package/dist/modules/components/modal/modalContainer/index.js +42 -49
- package/dist/modules/components/modal/modalContext.js +11 -13
- package/dist/modules/components/modal/modalFooter/index.js +7 -10
- package/dist/modules/components/modal/modalHeader/index.js +27 -20
- package/dist/modules/components/multiSelect/index.js +154 -115
- package/dist/modules/components/multiSelect/multiSelectChevron/index.js +21 -18
- package/dist/modules/components/multiSelect/multiSelectContainer/index.js +29 -13
- package/dist/modules/components/multiSelect/multiSelectContent/index.js +8 -11
- package/dist/modules/components/multiSelect/multiSelectMark/index.js +22 -19
- package/dist/modules/components/multiSelect/multiSelectOption/index.js +13 -17
- package/dist/modules/components/multiSelect/multiSelectOptionsContainer/index.js +45 -35
- package/dist/modules/components/multiSelect/multiSelectOverlay/index.js +8 -11
- package/dist/modules/components/multiSelect/multiSelectSpinner/index.js +16 -13
- package/dist/modules/components/pagination/chevronButton/index.js +17 -17
- package/dist/modules/components/pagination/currentButton/index.js +7 -11
- package/dist/modules/components/pagination/index.js +83 -51
- package/dist/modules/components/pagination/pageButton/index.js +8 -12
- package/dist/modules/components/pagination/paginationService.js +48 -33
- package/dist/modules/components/pagination/spread/index.js +7 -10
- package/dist/modules/components/phoneInput/index.js +151 -103
- package/dist/modules/components/phoneInput/phoneInputContainer/index.js +19 -12
- package/dist/modules/components/phoneInput/phoneInputCountriesOverlay/index.js +8 -11
- package/dist/modules/components/phoneInput/phoneInputCountryOption/index.js +15 -23
- package/dist/modules/components/phoneInput/phoneInputCountryOptionsContainer/index.js +43 -33
- package/dist/modules/components/phoneInput/phoneInputCountrySelector/index.js +21 -25
- package/dist/modules/components/phoneInput/phoneInputMask/index.js +62 -46
- package/dist/modules/components/popover/index.js +36 -37
- package/dist/modules/components/radio/radioBox/index.js +42 -24
- package/dist/modules/components/radio/radioContext.js +18 -20
- package/dist/modules/components/radio/radioGroup/index.js +64 -41
- package/dist/modules/components/richText/blockButton/index.js +23 -20
- package/dist/modules/components/richText/element/index.js +58 -72
- package/dist/modules/components/richText/index.js +135 -143
- package/dist/modules/components/richText/insertImage/index.js +105 -94
- package/dist/modules/components/richText/insertVideo/index.js +97 -85
- package/dist/modules/components/richText/leaf/index.js +6 -9
- package/dist/modules/components/richText/markButton/index.js +22 -19
- package/dist/modules/components/richText/toolbar/index.js +7 -10
- package/dist/modules/components/searchPlaces.js +66 -57
- package/dist/modules/components/select/index.js +144 -112
- package/dist/modules/components/select/selectChevron/index.js +21 -18
- package/dist/modules/components/select/selectContainer/index.js +29 -13
- package/dist/modules/components/select/selectContent/index.js +8 -11
- package/dist/modules/components/select/selectOption/index.js +13 -17
- package/dist/modules/components/select/selectOptionsContainer/index.js +45 -35
- package/dist/modules/components/select/selectOverlay/index.js +8 -11
- package/dist/modules/components/select/selectSpinner/index.js +9 -13
- package/dist/modules/components/slider/index.js +41 -34
- package/dist/modules/components/switch/index.js +62 -35
- package/dist/modules/components/tab/tabButton/index.js +29 -19
- package/dist/modules/components/tab/tabContainer/index.js +28 -22
- package/dist/modules/components/tab/tabContext.js +10 -12
- package/dist/modules/components/table/tableBody/index.js +14 -19
- package/dist/modules/components/table/tableCaption/index.js +8 -15
- package/dist/modules/components/table/tableContainer/index.js +8 -12
- package/dist/modules/components/table/tableFooter/index.js +11 -18
- package/dist/modules/components/table/tableHeader/index.js +11 -12
- package/dist/modules/components/textarea/index.js +69 -51
- package/dist/modules/components/tooltip/index.js +45 -34
- package/dist/modules/hooks/useAutomation.js +27 -35
- package/dist/modules/hooks/useDrawer.js +19 -17
- package/dist/modules/hooks/useForm.js +6 -6
- package/dist/modules/hooks/useHydrated.js +12 -7
- package/dist/modules/hooks/useModal.js +19 -17
- package/dist/modules/hooks/useScopedParams.js +17 -17
- package/dist/modules/hooks/useScrollLock.js +19 -19
- package/dist/modules/hooks/useSearchAutomation.js +14 -31
- package/dist/modules/hooks/useSlider.js +13 -13
- package/dist/modules/hooks/useToast.js +9 -8
- package/dist/modules/index.js +144 -72
- package/dist/modules/providers/drawerProvider.js +30 -35
- package/dist/modules/providers/formProvider.js +16 -11
- package/dist/modules/providers/modalProvider.js +33 -39
- package/dist/modules/providers/placesProvider.js +16 -16
- package/dist/modules/providers/toastProvider.js +51 -45
- package/dist/modules/services/extractTextFromNode.js +6 -6
- package/dist/modules/services/fieldTemplate.js +23 -22
- package/dist/modules/services/iconRenderer.js +7 -14
- package/dist/modules/services/isBlockActive.js +14 -12
- package/dist/modules/services/isMarkActive.js +6 -6
- package/dist/modules/services/maskCurrencyValues.js +12 -11
- package/dist/modules/services/toHtml.js +6 -6
- package/dist/modules/services/toRichTextValue.js +7 -7
- package/dist/modules/services/toggleBlock.js +19 -20
- package/dist/modules/services/toggleMark.js +7 -7
- package/dist/modules/style.css +1 -0
- package/dist/modules/templates/badResponses.js +13 -13
- package/dist/modules/templates/richTextTemplates.js +14 -17
- package/dist/modules/templates/successResponses.js +4 -9
- package/dist/modules/utils/phoneInputUtilities.js +28 -18
- package/dist/modules/utils/richTextUtilities.js +75 -88
- package/dist/services/fieldTemplate.d.ts +1 -1
- package/dist/services/fieldTemplate.d.ts.map +1 -1
- package/dist/style.css +1 -0
- package/package.json +65 -65
- package/dist/components.css +0 -2
- package/dist/modules/components.css +0 -2
|
@@ -1,112 +1,140 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { jsx as s, jsxs as oe } from "react/jsx-runtime";
|
|
2
|
+
import { Loader2 as $ } from "lucide-react";
|
|
3
|
+
import { useState as z, useRef as ne, useId as re, useEffect as te } from "react";
|
|
4
|
+
import { useForm as ae } from "../../hooks/useForm.js";
|
|
5
|
+
import { FieldTemplate as ie } from "../../services/fieldTemplate.js";
|
|
2
6
|
import { IconRenderer as t } from "../../services/iconRenderer.js";
|
|
3
|
-
import {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
7
|
+
import { maskCurrencyValues as g, normalizeValue as ce } from "../../services/maskCurrencyValues.js";
|
|
8
|
+
/* empty css */
|
|
9
|
+
function Ce(M) {
|
|
10
|
+
const {
|
|
11
|
+
name: l,
|
|
12
|
+
disabled: P,
|
|
13
|
+
title: B,
|
|
14
|
+
style: L,
|
|
15
|
+
variant: j = "solid",
|
|
16
|
+
label: D,
|
|
17
|
+
className: E = "",
|
|
18
|
+
value: f,
|
|
19
|
+
defaultValue: d,
|
|
20
|
+
max: x = 1e9,
|
|
21
|
+
locale: c,
|
|
22
|
+
onChange: y,
|
|
23
|
+
prefix: S,
|
|
24
|
+
suffix: V,
|
|
25
|
+
isLoading: o = !1,
|
|
26
|
+
leftIcon: O,
|
|
27
|
+
readOnly: k,
|
|
28
|
+
onFocus: w,
|
|
29
|
+
onBlur: C,
|
|
30
|
+
errorMessage: R,
|
|
31
|
+
unShowFieldTemplate: T,
|
|
32
|
+
orientation: A,
|
|
33
|
+
showAsterisk: q,
|
|
34
|
+
rightIcon: F,
|
|
35
|
+
size: I = "md",
|
|
36
|
+
id: G,
|
|
37
|
+
...H
|
|
38
|
+
} = M, { fieldErrors: m } = ae(), [J, p] = z(!1), [h, N] = z("0"), a = ne(null), K = G || re(), b = R || (m == null ? void 0 : m[l]), Q = !!b, i = P || o, n = { md: 20, lg: 20 }[I], v = F ? "right" : "left", U = v === "left" && o, W = v === "right" && o;
|
|
39
|
+
function X() {
|
|
40
|
+
i || !(a != null && a.current) || (p(!0), a.current.focus());
|
|
41
|
+
}
|
|
42
|
+
function Y(e) {
|
|
43
|
+
p(!0), w && w(e);
|
|
44
|
+
}
|
|
45
|
+
function Z(e) {
|
|
46
|
+
p(!1), C && C(e);
|
|
47
|
+
}
|
|
48
|
+
const _ = (e) => {
|
|
49
|
+
const [r, u] = g(
|
|
50
|
+
e,
|
|
51
|
+
c
|
|
52
|
+
);
|
|
53
|
+
return !x || r <= x ? (N(u), [r, u]) : g(e, c);
|
|
54
|
+
}, ee = (e) => {
|
|
55
|
+
e.preventDefault();
|
|
56
|
+
const [r, u] = _(e.target.value);
|
|
57
|
+
y && y(e, String(r), String(u));
|
|
58
|
+
};
|
|
59
|
+
te(() => {
|
|
60
|
+
function e() {
|
|
61
|
+
if (typeof f == "number") return f;
|
|
62
|
+
if (typeof d == "number") return d;
|
|
63
|
+
}
|
|
64
|
+
const [, r] = g(e(), c);
|
|
65
|
+
N(r);
|
|
66
|
+
}, [c, d, f]);
|
|
67
|
+
const se = `arkynCurrencyInput ${S ? "hasPrefix" : ""} ${V ? "hasSuffix" : ""} ${j} ${I} ${i || k || o ? "opacity" : ""} ${Q ? "errored" : ""} ${J ? "focused" : ""}`;
|
|
68
|
+
return /* @__PURE__ */ s(
|
|
69
|
+
ie,
|
|
70
|
+
{
|
|
71
|
+
name: l,
|
|
72
|
+
label: D,
|
|
73
|
+
showAsterisk: q,
|
|
74
|
+
className: E,
|
|
75
|
+
errorMessage: b,
|
|
76
|
+
unShowFieldTemplate: T,
|
|
77
|
+
orientation: A,
|
|
78
|
+
children: /* @__PURE__ */ oe(
|
|
79
|
+
"section",
|
|
80
|
+
{
|
|
81
|
+
title: B,
|
|
82
|
+
style: L,
|
|
83
|
+
className: se,
|
|
84
|
+
onClick: X,
|
|
85
|
+
children: [
|
|
86
|
+
/* @__PURE__ */ s(t, { iconSize: n, icon: S, className: "prefix" }),
|
|
87
|
+
/* @__PURE__ */ s(
|
|
88
|
+
t,
|
|
89
|
+
{
|
|
90
|
+
show: U,
|
|
91
|
+
iconSize: n,
|
|
92
|
+
className: "spinner",
|
|
93
|
+
icon: $
|
|
94
|
+
}
|
|
95
|
+
),
|
|
96
|
+
/* @__PURE__ */ s(t, { show: !o, icon: O, iconSize: n }),
|
|
97
|
+
/* @__PURE__ */ s(
|
|
98
|
+
"input",
|
|
99
|
+
{
|
|
100
|
+
disabled: i,
|
|
101
|
+
readOnly: k,
|
|
102
|
+
ref: a,
|
|
103
|
+
onFocus: Y,
|
|
104
|
+
onBlur: Z,
|
|
105
|
+
onChange: ee,
|
|
106
|
+
id: K,
|
|
107
|
+
placeholder: i ? h : void 0,
|
|
108
|
+
value: i ? void 0 : h,
|
|
109
|
+
...H
|
|
110
|
+
}
|
|
111
|
+
),
|
|
112
|
+
/* @__PURE__ */ s(
|
|
113
|
+
"input",
|
|
114
|
+
{
|
|
115
|
+
type: "hidden",
|
|
116
|
+
name: l,
|
|
117
|
+
value: ce(h),
|
|
118
|
+
readOnly: !0
|
|
119
|
+
}
|
|
120
|
+
),
|
|
121
|
+
/* @__PURE__ */ s(t, { show: !o, icon: F, iconSize: n }),
|
|
122
|
+
/* @__PURE__ */ s(
|
|
123
|
+
t,
|
|
124
|
+
{
|
|
125
|
+
show: W,
|
|
126
|
+
iconSize: n,
|
|
127
|
+
className: "spinner",
|
|
128
|
+
icon: $
|
|
129
|
+
}
|
|
130
|
+
),
|
|
131
|
+
/* @__PURE__ */ s(t, { iconSize: n, icon: V, className: "suffix" })
|
|
132
|
+
]
|
|
133
|
+
}
|
|
134
|
+
)
|
|
135
|
+
}
|
|
136
|
+
);
|
|
110
137
|
}
|
|
111
|
-
|
|
112
|
-
|
|
138
|
+
export {
|
|
139
|
+
Ce as CurrencyInput
|
|
140
|
+
};
|
|
@@ -1,12 +1,13 @@
|
|
|
1
|
-
/* empty css */
|
|
2
1
|
import { jsx as e } from "react/jsx-runtime";
|
|
3
|
-
|
|
4
|
-
function
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
2
|
+
/* empty css */
|
|
3
|
+
function m(r) {
|
|
4
|
+
const {
|
|
5
|
+
className: s,
|
|
6
|
+
orientation: a = "horizontal",
|
|
7
|
+
...i
|
|
8
|
+
} = r, t = `arkynDivider ${a} ${s}`;
|
|
9
|
+
return /* @__PURE__ */ e("div", { className: t.trim(), ...i });
|
|
10
10
|
}
|
|
11
|
-
|
|
12
|
-
|
|
11
|
+
export {
|
|
12
|
+
m as Divider
|
|
13
|
+
};
|
|
@@ -1,41 +1,44 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
import {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
1
|
+
import { jsx as a, jsxs as d } from "react/jsx-runtime";
|
|
2
|
+
import { AnimatePresence as f, motion as s } from "framer-motion";
|
|
3
|
+
import { useScrollLock as p } from "../../../hooks/useScrollLock.js";
|
|
4
|
+
import { DrawerProvider as v } from "../drawerContext.js";
|
|
5
|
+
/* empty css */
|
|
6
|
+
function N(n) {
|
|
7
|
+
const {
|
|
8
|
+
isVisible: e,
|
|
9
|
+
makeInvisible: i,
|
|
10
|
+
orientation: r = "left",
|
|
11
|
+
children: o,
|
|
12
|
+
className: l,
|
|
13
|
+
...m
|
|
14
|
+
} = n;
|
|
15
|
+
p(e);
|
|
16
|
+
const t = r === "left" ? "-100%" : "100%", c = `arkynDrawerContainer ${r} ${e ? "visibleTrue" : "visibleFalse"} ${l}`;
|
|
17
|
+
return /* @__PURE__ */ a(v, { makeInvisible: i, children: /* @__PURE__ */ a(f, { children: e && /* @__PURE__ */ d("aside", { className: c.trim(), ...m, children: [
|
|
18
|
+
/* @__PURE__ */ a(
|
|
19
|
+
s.div,
|
|
20
|
+
{
|
|
21
|
+
className: "arkynDrawerContainerOverlay",
|
|
22
|
+
transition: { duration: 0.15, ease: "easeOut" },
|
|
23
|
+
initial: { opacity: 0 },
|
|
24
|
+
animate: { opacity: 1 },
|
|
25
|
+
exit: { opacity: 0 },
|
|
26
|
+
onClick: i
|
|
27
|
+
}
|
|
28
|
+
),
|
|
29
|
+
/* @__PURE__ */ a(
|
|
30
|
+
s.div,
|
|
31
|
+
{
|
|
32
|
+
className: "arkynDrawerContainerContent",
|
|
33
|
+
transition: { ease: "easeOut", duration: 0.15 },
|
|
34
|
+
initial: { transform: `translateX(${t})` },
|
|
35
|
+
animate: { transform: "translateX(0px)" },
|
|
36
|
+
exit: { transform: `translateX(${t})` },
|
|
37
|
+
children: o
|
|
38
|
+
}
|
|
39
|
+
)
|
|
40
|
+
] }) }) });
|
|
39
41
|
}
|
|
40
|
-
|
|
41
|
-
|
|
42
|
+
export {
|
|
43
|
+
N as DrawerContainer
|
|
44
|
+
};
|
|
@@ -1,15 +1,13 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
return /* @__PURE__ */ n(r.Provider, {
|
|
7
|
-
value: { makeInvisible: e.makeInvisible },
|
|
8
|
-
children: e.children
|
|
9
|
-
});
|
|
1
|
+
import { jsx as t } from "react/jsx-runtime";
|
|
2
|
+
import { useContext as n, createContext as i } from "react";
|
|
3
|
+
const e = i({});
|
|
4
|
+
function s(r) {
|
|
5
|
+
return /* @__PURE__ */ t(e.Provider, { value: { makeInvisible: r.makeInvisible }, children: r.children });
|
|
10
6
|
}
|
|
11
|
-
function
|
|
12
|
-
|
|
7
|
+
function u() {
|
|
8
|
+
return n(e);
|
|
13
9
|
}
|
|
14
|
-
|
|
15
|
-
|
|
10
|
+
export {
|
|
11
|
+
s as DrawerProvider,
|
|
12
|
+
u as useDrawer
|
|
13
|
+
};
|
|
@@ -1,21 +1,28 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
import {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
1
|
+
import { jsxs as i, jsx as e } from "react/jsx-runtime";
|
|
2
|
+
import { X as m } from "lucide-react";
|
|
3
|
+
import { useDrawer as c } from "../drawerContext.js";
|
|
4
|
+
/* empty css */
|
|
5
|
+
function b(r) {
|
|
6
|
+
const {
|
|
7
|
+
showCloseButton: a = !0,
|
|
8
|
+
className: s,
|
|
9
|
+
children: t,
|
|
10
|
+
...o
|
|
11
|
+
} = r, { makeInvisible: n } = c(), l = `arkynDrawerHeader ${s}`;
|
|
12
|
+
return /* @__PURE__ */ i("header", { className: l.trim(), ...o, children: [
|
|
13
|
+
t,
|
|
14
|
+
a && /* @__PURE__ */ e(
|
|
15
|
+
"button",
|
|
16
|
+
{
|
|
17
|
+
className: "arkynDrawerHeaderCloseButton",
|
|
18
|
+
type: "button",
|
|
19
|
+
onClick: n,
|
|
20
|
+
"aria-label": "Close drawer",
|
|
21
|
+
children: /* @__PURE__ */ e(m, { size: 24 })
|
|
22
|
+
}
|
|
23
|
+
)
|
|
24
|
+
] });
|
|
19
25
|
}
|
|
20
|
-
|
|
21
|
-
|
|
26
|
+
export {
|
|
27
|
+
b as DrawerHeader
|
|
28
|
+
};
|
|
@@ -1,9 +1,19 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
1
|
+
import { jsx as g, Fragment as l } from "react/jsx-runtime";
|
|
2
|
+
import { FacebookPixel as m } from "./pixel.js";
|
|
3
|
+
function u(a) {
|
|
4
|
+
const {
|
|
5
|
+
pixelId: e,
|
|
6
|
+
options: c,
|
|
7
|
+
pageView: k,
|
|
8
|
+
track: i,
|
|
9
|
+
trackCustom: n,
|
|
10
|
+
trackSingle: o,
|
|
11
|
+
trackSingleCustom: r,
|
|
12
|
+
grantConsent: s,
|
|
13
|
+
revokeConsent: f
|
|
14
|
+
} = a, t = new m(e, c);
|
|
15
|
+
return t.init(), k && t.pageView(), s && t.grantConsent(), f && t.revokeConsent(), i && t.track(...i), n && t.trackCustom(...n), o && t.trackSingle(e, ...o), r && t.trackSingleCustom(e, ...r), /* @__PURE__ */ g(l, {});
|
|
7
16
|
}
|
|
8
|
-
|
|
9
|
-
|
|
17
|
+
export {
|
|
18
|
+
u as FacebookPixelClient
|
|
19
|
+
};
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
return process.env.NODE_ENV !== "production" && !i.showInDevMode ? /* @__PURE__ */ r(n, {}) : /* @__PURE__ */ r(e, { children: () => /* @__PURE__ */ r(t, { ...i }) });
|
|
1
|
+
import { jsx as o, Fragment as r } from "react/jsx-runtime";
|
|
2
|
+
import { ClientOnly as n } from "../clientOnly.js";
|
|
3
|
+
import { FacebookPixelClient as i } from "./facebookPixel.client.js";
|
|
4
|
+
function l(e) {
|
|
5
|
+
return process.env.NODE_ENV !== "production" && !e.showInDevMode ? /* @__PURE__ */ o(r, {}) : /* @__PURE__ */ o(n, { children: () => /* @__PURE__ */ o(i, { ...e }) });
|
|
7
6
|
}
|
|
8
|
-
|
|
9
|
-
|
|
7
|
+
export {
|
|
8
|
+
l as FacebookPixel
|
|
9
|
+
};
|
|
@@ -1,48 +1,53 @@
|
|
|
1
|
-
|
|
2
|
-
var
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
1
|
+
var f = Object.defineProperty;
|
|
2
|
+
var d = (n, i, e) => i in n ? f(n, i, { enumerable: !0, configurable: !0, writable: !0, value: e }) : n[i] = e;
|
|
3
|
+
var o = (n, i, e) => d(n, typeof i != "symbol" ? i + "" : i, e);
|
|
4
|
+
let a = class {
|
|
5
|
+
constructor(i, e) {
|
|
6
|
+
o(this, "pixelId");
|
|
7
|
+
o(this, "autoConfig");
|
|
8
|
+
o(this, "initialized");
|
|
9
|
+
this.pixelId = i, this.autoConfig = (e == null ? void 0 : e.autoConfig) || !0, this.initialized = !1;
|
|
10
|
+
}
|
|
11
|
+
loadFacebookPixel() {
|
|
12
|
+
if (window.fbq) return;
|
|
13
|
+
const i = function(...r) {
|
|
14
|
+
i.callMethod ? i.callMethod.apply(i, r) : i.queue.push(r);
|
|
15
|
+
};
|
|
16
|
+
window._fbq || (window._fbq = i), i.push = i, i.loaded = !0, i.version = "2.0", i.queue = [];
|
|
17
|
+
const e = document.createElement("script");
|
|
18
|
+
e.async = !0, e.src = "https://connect.facebook.net/en_US/fbevents.js";
|
|
19
|
+
const t = document.getElementsByTagName("script")[0];
|
|
20
|
+
if (!t.parentNode)
|
|
21
|
+
throw new Error("No script tag found in the document");
|
|
22
|
+
t.parentNode.insertBefore(e, t), window.fbq = i;
|
|
23
|
+
}
|
|
24
|
+
init(i = {}) {
|
|
25
|
+
if (this.initialized = typeof window < "u" && !!window.fbq, this.loadFacebookPixel(), !window.fbq)
|
|
26
|
+
throw new Error("window.fbq is not defined");
|
|
27
|
+
this.autoConfig === !1 ? window.fbq("set", "autoConfig", !1, this.pixelId) : window.fbq("init", this.pixelId, i), this.initialized = !0;
|
|
28
|
+
}
|
|
29
|
+
pageView() {
|
|
30
|
+
this.initialized && window.fbq && window.fbq("track", "PageView");
|
|
31
|
+
}
|
|
32
|
+
track(i, e) {
|
|
33
|
+
this.initialized && window.fbq && window.fbq("track", i, e);
|
|
34
|
+
}
|
|
35
|
+
trackSingle(i, e, t) {
|
|
36
|
+
this.initialized && window.fbq && window.fbq("trackSingle", i, e, t);
|
|
37
|
+
}
|
|
38
|
+
trackCustom(i, e) {
|
|
39
|
+
this.initialized && window.fbq && window.fbq("trackCustom", i, e);
|
|
40
|
+
}
|
|
41
|
+
trackSingleCustom(i, e, t) {
|
|
42
|
+
this.initialized && window.fbq && window.fbq("trackSingle", i, e, t);
|
|
43
|
+
}
|
|
44
|
+
grantConsent() {
|
|
45
|
+
this.initialized && window.fbq && window.fbq("consent", "grant");
|
|
46
|
+
}
|
|
47
|
+
revokeConsent() {
|
|
48
|
+
this.initialized && window.fbq && window.fbq("consent", "revoke");
|
|
49
|
+
}
|
|
50
|
+
};
|
|
51
|
+
export {
|
|
52
|
+
a as FacebookPixel
|
|
46
53
|
};
|
|
47
|
-
//#endregion
|
|
48
|
-
export { e as FacebookPixel };
|
|
@@ -1,13 +1,9 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
return r ? /* @__PURE__ */ t("strong", {
|
|
7
|
-
className: o.trim(),
|
|
8
|
-
...a,
|
|
9
|
-
children: r
|
|
10
|
-
}) : /* @__PURE__ */ t(e, {});
|
|
1
|
+
import { jsx as s, Fragment as o } from "react/jsx-runtime";
|
|
2
|
+
/* empty css */
|
|
3
|
+
function c(e) {
|
|
4
|
+
const { children: r, className: t, ...a } = e, n = `arkynFieldError ${t}`;
|
|
5
|
+
return r ? /* @__PURE__ */ s("strong", { className: n.trim(), ...a, children: r }) : /* @__PURE__ */ s(o, {});
|
|
11
6
|
}
|
|
12
|
-
|
|
13
|
-
|
|
7
|
+
export {
|
|
8
|
+
c as FieldError
|
|
9
|
+
};
|