@verbb/formie-browser 1.0.15 → 1.0.16
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/CHANGELOG.md +36 -0
- package/dist/chunks/{address-country-BcEQKw0T.js → address-country-DLJF-OkC.js} +4 -8
- package/dist/chunks/{address-finder-BWGINCSA.js → address-finder-QK1m1eyv.js} +1 -1
- package/dist/chunks/{address-state-DI3ndhMU.js → address-state-CHKit8AW.js} +26 -35
- package/dist/chunks/{api-BK9b340y.js → api-BPtH5RBA.js} +152 -120
- package/dist/chunks/{api-Dxl_CKw-.js → api-BR2Gqy37.js} +306 -301
- package/dist/chunks/{api-ghNr2uxX.js → api-CmuOZ0i3.js} +1 -1
- package/dist/chunks/{bpoint-BwtuyN_O.js → bpoint-GvYfyPjD.js} +1 -1
- package/dist/chunks/{calculations-YEoVCG2q.js → calculations-DeEmdUDq.js} +5 -7
- package/dist/chunks/{captcha-eu-DWLoQFKB.js → captcha-eu-eU_M6snp.js} +1 -1
- package/dist/chunks/{checkbox-radio-gsm8QPJg.js → checkbox-radio-CSXo6svm.js} +4 -12
- package/dist/chunks/{combobox-Ba08_cHL.js → combobox-CJh2DoSO.js} +292 -333
- package/dist/chunks/{conditions-Ceeg6ReZ.js → conditions-Dz3068K0.js} +56 -72
- package/dist/chunks/{country-from-ip-DDj_mFki.js → country-from-ip-BqQ-BqLH.js} +1 -1
- package/dist/chunks/{custom-google-maps-C4l2S3GO.js → custom-google-maps-rNm5VFbb.js} +2 -6
- package/dist/chunks/{custom-link-CLazgKYH.js → custom-link-CLqFCssQ.js} +1 -1
- package/dist/chunks/{custom-maps-DqcAlD0v.js → custom-maps-DgjYQDLj.js} +4 -8
- package/dist/chunks/{date-picker-DaPvMrop.js → date-picker-BVJxJVYT.js} +30 -47
- package/dist/chunks/{debug-BV0DvdHx.js → debug-rhzqP1j2.js} +2 -14
- package/dist/chunks/{dist-ZLeW0zZ3.js → dist-CJReDlDK.js} +13 -8
- package/dist/chunks/{eway-uw0DzU-L.js → eway-BZuTBAUW.js} +1 -1
- package/dist/chunks/{field-references.resolver-Ca8MguFv.js → field-references.resolver-uSHf5-NP.js} +1 -1
- package/dist/chunks/{file-upload-B8_mH012.js → file-upload-vEUr_EuP.js} +114 -108
- package/dist/chunks/{friendly-captcha-v1-CVXaXgDO.js → friendly-captcha-v1-C_cF1WD2.js} +2 -2
- package/dist/chunks/{friendly-captcha-v2-DkeIVTKI.js → friendly-captcha-v2-BenESH-n.js} +2 -2
- package/dist/chunks/{friendly-challenge-DPG9MJb1.js → friendly-challenge-BgPBEMXx.js} +21 -35
- package/dist/chunks/{go-cardless-c4wLJdOt.js → go-cardless-DWZeB0Bq.js} +2 -6
- package/dist/chunks/{google-address-JHYvjwgN.js → google-address-DQR6rsbh.js} +2 -2
- package/dist/chunks/{hcaptcha-Dt3ELLlP.js → hcaptcha-COilLmRT.js} +1 -1
- package/dist/chunks/{hidden-BZhXnNPe.js → hidden-Bc2TpcgF.js} +1 -1
- package/dist/chunks/{http-C2QdHuWO.js → http-Dj_skqaa.js} +1 -1
- package/dist/chunks/{leaflet-src-DE6rv6M-.js → leaflet-src-Cg-LUOD8.js} +74 -122
- package/dist/chunks/{loqate-m51iPyO1.js → loqate-ZZClcacr.js} +1 -1
- package/dist/chunks/{mollie-Bn0PX173.js → mollie-8OMXIYa8.js} +2 -6
- package/dist/chunks/{moneris-BRbUvI4t.js → moneris-qYHJ9EFy.js} +1 -1
- package/dist/chunks/opayo-DlWPEnla.js +159 -0
- package/dist/chunks/{paddle-CympHVvd.js → paddle-CArfWih0.js} +1 -1
- package/dist/chunks/{password-validation-C8_uO_c_.js → password-validation-HGOU9kf3.js} +2 -2
- package/dist/chunks/{paypal-h75h6wae.js → paypal-BcaMCMGY.js} +1 -1
- package/dist/chunks/{payway-C9rHTCC_.js → payway-vxC7_bfR.js} +3 -11
- package/dist/chunks/{phone-country-B8fv-L5_.js → phone-country-Bx9EG50h.js} +123 -140
- package/dist/chunks/{place-kit-BnZGQ-L1.js → place-kit-BKk8xDXf.js} +2 -2
- package/dist/chunks/{placekit-autocomplete.esm-CZZERYur.js → placekit-autocomplete.esm-D2A_0iVU.js} +2 -5
- package/dist/chunks/{recaptcha-enterprise-CUs8BO6V.js → recaptcha-enterprise-Cx6HUpMa.js} +6 -12
- package/dist/chunks/recaptcha-shared-CcMI-r8t.js +33 -0
- package/dist/chunks/{recaptcha-v2-checkbox-P1McW4Pv.js → recaptcha-v2-checkbox-DQ9BJzcv.js} +2 -2
- package/dist/chunks/{recaptcha-v2-invisible-FGDqozSP.js → recaptcha-v2-invisible-BP0T8Pan.js} +2 -2
- package/dist/chunks/recaptcha-v3-DKMGQ27K.js +38 -0
- package/dist/chunks/{repeater-CyhDbozO.js → repeater-BR0RUvTs.js} +3 -7
- package/dist/chunks/{rich-text-uV4o_pGk.js → rich-text-H2A6cm1t.js} +33 -11
- package/dist/chunks/{rolldown-runtime-DtPi1Y-2.js → rolldown-runtime-VHNaYcLd.js} +1 -1
- package/dist/chunks/{sdk-lkwSvlpM.js → sdk-_cmrRYgp.js} +4 -16
- package/dist/chunks/{shared-OKhSay59.js → shared-CJ1LIEh3.js} +1 -3
- package/dist/chunks/{signature-7cldFbqj.js → signature-CfKA_poI.js} +9 -41
- package/dist/chunks/{snaptcha-C3QLYxFT.js → snaptcha-P3EoSQud.js} +1 -1
- package/dist/chunks/{square-C1z5DPVw.js → square-Dyz0p_GU.js} +1 -1
- package/dist/chunks/{stripe-Dmkdkq1y.js → stripe-Bfd_jp_k.js} +3 -6
- package/dist/chunks/{summary-Bn-g5SDx.js → summary-B3CAebLV.js} +44 -36
- package/dist/chunks/{survey-likert-fk1hUPff.js → survey-likert-CEtUceag.js} +1 -1
- package/dist/chunks/{survey-rank-BsLGl2LX.js → survey-rank-Dtt97y6s.js} +3 -7
- package/dist/chunks/{survey-rating-DVS6e6fM.js → survey-rating-mlDMI0uq.js} +9 -23
- package/dist/chunks/{table-j7MlLLCc.js → table-0k6Md0IO.js} +1 -1
- package/dist/chunks/{text-limit-LGMPhFuC.js → text-limit-CTVML6s7.js} +10 -10
- package/dist/chunks/{turnstile-ptihQfLl.js → turnstile-Sp4ubowK.js} +1 -1
- package/dist/chunks/{upload-manager-BW7l-BhF.js → upload-manager-Ccg3d_4I.js} +11 -25
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +752 -756
- package/dist/js/core/create-formie-client.d.ts.map +1 -1
- package/dist/js/core/dom-events.d.ts +5 -0
- package/dist/js/core/dom-events.d.ts.map +1 -1
- package/dist/js/core/page-client-event.d.ts.map +1 -1
- package/dist/js/core/submit-result-state.d.ts.map +1 -1
- package/dist/js/core/submit-result-ui.d.ts.map +1 -1
- package/dist/js/core/validation-focus.d.ts.map +1 -1
- package/dist/js/modules/captchas/factories.d.ts.map +1 -1
- package/dist/js/modules/captchas/host.d.ts +4 -1
- package/dist/js/modules/captchas/host.d.ts.map +1 -1
- package/dist/js/modules/captchas/recaptcha-shared.d.ts +1 -1
- package/dist/js/modules/captchas/recaptcha-shared.d.ts.map +1 -1
- package/dist/js/modules/captchas/recaptcha-v3.d.ts.map +1 -1
- package/dist/js/modules/fields/address-state.d.ts.map +1 -1
- package/dist/js/modules/fields/combobox.d.ts +2 -0
- package/dist/js/modules/fields/combobox.d.ts.map +1 -1
- package/dist/js/modules/fields/conditions.d.ts.map +1 -1
- package/dist/js/modules/fields/file-upload.d.ts.map +1 -1
- package/dist/js/modules/fields/phone-country.d.ts.map +1 -1
- package/dist/js/modules/fields/rich-text.d.ts.map +1 -1
- package/dist/js/modules/fields/summary.d.ts.map +1 -1
- package/dist/js/modules/fields/text-limit.d.ts.map +1 -1
- package/dist/js/modules/payments/factories.d.ts.map +1 -1
- package/dist/js/modules/payments/opayo.d.ts.map +1 -1
- package/dist/js/submit/pipeline.d.ts +2 -0
- package/dist/js/submit/pipeline.d.ts.map +1 -1
- package/dist/js/utils/form-started-at.d.ts +1 -0
- package/dist/js/utils/form-started-at.d.ts.map +1 -1
- package/dist/js/utils/unload-warning.d.ts +4 -0
- package/dist/js/utils/unload-warning.d.ts.map +1 -1
- package/dist/js/validation/rules/required.d.ts.map +1 -1
- package/dist/js/validation/submit-readiness.d.ts.map +1 -1
- package/dist/js/validation/validator.d.ts +1 -0
- package/dist/js/validation/validator.d.ts.map +1 -1
- package/package.json +3 -3
- package/src/index.ts +1 -0
- package/src/js/core/create-formie-client.ts +20 -18
- package/src/js/core/dom-events.ts +30 -1
- package/src/js/core/page-client-event.ts +5 -7
- package/src/js/core/submit-result-state.ts +13 -2
- package/src/js/core/submit-result-ui.ts +21 -0
- package/src/js/core/validation-focus.ts +17 -3
- package/src/js/modules/captchas/factories.ts +241 -101
- package/src/js/modules/captchas/host.ts +16 -0
- package/src/js/modules/captchas/recaptcha-enterprise.ts +1 -1
- package/src/js/modules/captchas/recaptcha-shared.ts +23 -5
- package/src/js/modules/captchas/recaptcha-v3.ts +23 -14
- package/src/js/modules/fields/address-state.ts +6 -4
- package/src/js/modules/fields/combobox.ts +19 -1
- package/src/js/modules/fields/conditions.ts +3 -0
- package/src/js/modules/fields/file-upload.ts +11 -4
- package/src/js/modules/fields/phone-country.ts +23 -0
- package/src/js/modules/fields/rich-text.ts +33 -0
- package/src/js/modules/fields/summary.ts +63 -10
- package/src/js/modules/fields/text-limit.ts +11 -0
- package/src/js/modules/payments/factories.ts +87 -54
- package/src/js/modules/payments/opayo.ts +7 -0
- package/src/js/submit/pipeline.ts +16 -9
- package/src/js/utils/form-started-at.ts +19 -4
- package/src/js/utils/unload-warning.ts +63 -7
- package/src/js/validation/rules/required.ts +6 -0
- package/src/js/validation/submit-readiness.ts +2 -0
- package/src/js/validation/validator.ts +15 -4
- package/src/vendor.d.ts +2 -0
- package/dist/chunks/opayo-BwWdInEP.js +0 -188
- package/dist/chunks/recaptcha-shared-DTbTw-MF.js +0 -27
- package/dist/chunks/recaptcha-v3-CflUHeZD.js +0 -28
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { c as e, d as t, l as n } from "./dist-
|
|
1
|
+
import { c as e, d as t, l as n } from "./dist-CJReDlDK.js";
|
|
2
2
|
import { a as r } from "./event-names-BCI2FLD8.js";
|
|
3
|
-
import { t as i } from "./debug-
|
|
3
|
+
import { t as i } from "./debug-rhzqP1j2.js";
|
|
4
4
|
import { n as a } from "./theme-classes-DAQuEqdP.js";
|
|
5
5
|
import { t as o } from "./field-references.keys-58ZSTrCW.js";
|
|
6
|
-
import { r as s } from "./shared-
|
|
6
|
+
import { r as s } from "./shared-CJ1LIEh3.js";
|
|
7
7
|
//#region src/js/modules/fields/conditions/config.ts
|
|
8
8
|
var c = "[data-formie-conditions]";
|
|
9
9
|
function l(e) {
|
|
@@ -90,23 +90,13 @@ function w(e, t) {
|
|
|
90
90
|
}
|
|
91
91
|
var T = "button[type=\"submit\"], button[data-formie-action], input[type=\"submit\"]";
|
|
92
92
|
function E(e, t) {
|
|
93
|
-
|
|
94
|
-
if (t) {
|
|
95
|
-
e.hasAttribute(f) || (e.hasAttribute("disabled") && e.setAttribute(p, "true"), e.setAttribute(f, "true")), e.setAttribute("disabled", "true");
|
|
96
|
-
return;
|
|
97
|
-
}
|
|
98
|
-
e.hasAttribute(f) && (e.hasAttribute(p) ? (e.setAttribute("disabled", "true"), e.removeAttribute(p)) : e.removeAttribute("disabled"), e.removeAttribute(f));
|
|
99
|
-
}
|
|
93
|
+
(e instanceof HTMLButtonElement || e instanceof HTMLInputElement) && (t ? (e.hasAttribute(f) || (e.hasAttribute("disabled") && e.setAttribute(p, "true"), e.setAttribute(f, "true")), e.setAttribute("disabled", "true")) : e.hasAttribute(f) && (e.hasAttribute(p) ? (e.setAttribute("disabled", "true"), e.removeAttribute(p)) : e.removeAttribute("disabled"), e.removeAttribute(f)));
|
|
100
94
|
}
|
|
101
95
|
function D(e, t) {
|
|
102
96
|
e.matches(T) && E(e, t), e.querySelectorAll(T).forEach((e) => {
|
|
103
97
|
E(e, t);
|
|
104
98
|
}), e.querySelectorAll("input, textarea, select").forEach((e) => {
|
|
105
|
-
|
|
106
|
-
e.hasAttribute(f) || (e.hasAttribute("disabled") && e.setAttribute(p, "true"), e.setAttribute(f, "true")), e.setAttribute("disabled", "true");
|
|
107
|
-
return;
|
|
108
|
-
}
|
|
109
|
-
e.hasAttribute(f) && (e.hasAttribute(p) ? (e.setAttribute("disabled", "true"), e.removeAttribute(p)) : e.removeAttribute("disabled"), e.removeAttribute(f));
|
|
99
|
+
t ? (e.hasAttribute(f) || (e.hasAttribute("disabled") && e.setAttribute(p, "true"), e.setAttribute(f, "true")), e.setAttribute("disabled", "true")) : e.hasAttribute(f) && (e.hasAttribute(p) ? (e.setAttribute("disabled", "true"), e.removeAttribute(p)) : e.removeAttribute("disabled"), e.removeAttribute(f));
|
|
110
100
|
});
|
|
111
101
|
}
|
|
112
102
|
function O(e) {
|
|
@@ -117,9 +107,7 @@ function ee(e) {
|
|
|
117
107
|
if (n > 0) {
|
|
118
108
|
let r = String(n);
|
|
119
109
|
e.getAttribute(b) !== r && e.setAttribute(b, r), e.hasAttribute(y) && e.removeAttribute(y), e.classList.remove(...t);
|
|
120
|
-
|
|
121
|
-
}
|
|
122
|
-
e.hasAttribute(b) && e.removeAttribute(b), e.hasAttribute(y) || e.setAttribute(y, "true"), e.classList.add(...t);
|
|
110
|
+
} else e.hasAttribute(b) && e.removeAttribute(b), e.hasAttribute(y) || e.setAttribute(y, "true"), e.classList.add(...t);
|
|
123
111
|
}
|
|
124
112
|
function k(e) {
|
|
125
113
|
e.removeAttribute(v), e.classList.remove(g), e.classList.remove(_);
|
|
@@ -131,121 +119,117 @@ function j(e) {
|
|
|
131
119
|
let t = e.closest(x);
|
|
132
120
|
for (; t;) ee(t), t = t.parentElement?.closest(x) || null;
|
|
133
121
|
}
|
|
134
|
-
function
|
|
122
|
+
function M(e, t, n, r = {}) {
|
|
135
123
|
if (r.disabledOnly) {
|
|
136
124
|
let r = e.hasAttribute("data-formie-conditionally-disabled") !== t;
|
|
137
125
|
return e.toggleAttribute("data-formie-conditionally-disabled", t), D(e, t), t && n && r && C(e), r;
|
|
138
126
|
}
|
|
139
|
-
if (r.displayMode === "muted") return
|
|
127
|
+
if (r.displayMode === "muted") return N(e, t);
|
|
140
128
|
let i = !1;
|
|
141
129
|
return (e.hasAttribute(v) || e.classList.contains(g) || e.classList.contains(_)) && (k(e), i = !0), i = w(e, t) || i, D(e, t), j(e), t && n && i && C(e), i;
|
|
142
130
|
}
|
|
143
|
-
function
|
|
131
|
+
function N(e, t) {
|
|
144
132
|
let n = !1;
|
|
145
133
|
return t ? ((e.hasAttribute(m) || e.hasAttribute(h)) && (A(e), n = !0), e.hasAttribute(v) || (e.setAttribute(v, "true"), n = !0), e.classList.contains(g) || (e.classList.add(g), n = !0)) : ((e.hasAttribute(v) || e.classList.contains(g) || e.classList.contains(_)) && (k(e), n = !0), (e.hasAttribute(m) || e.hasAttribute(h)) && (A(e), n = !0)), j(e), n;
|
|
146
134
|
}
|
|
147
135
|
//#endregion
|
|
148
136
|
//#region src/js/modules/fields/conditions/references.ts
|
|
149
|
-
var
|
|
150
|
-
function
|
|
137
|
+
var P = "input, select, textarea", F = "[data-formie-repeater-item], [data-formie-table-row]";
|
|
138
|
+
function I(e) {
|
|
151
139
|
return e instanceof HTMLInputElement || e instanceof HTMLSelectElement || e instanceof HTMLTextAreaElement;
|
|
152
140
|
}
|
|
153
|
-
function
|
|
154
|
-
let t = e.querySelector(
|
|
141
|
+
function L(e) {
|
|
142
|
+
let t = e.querySelector(P);
|
|
155
143
|
if (!t) return null;
|
|
156
144
|
let n = t.getAttribute("name") || "", r = Array.from(n.matchAll(/\[(\d+)\]/g));
|
|
157
145
|
return r.length && r[r.length - 1]?.[1] || null;
|
|
158
146
|
}
|
|
159
|
-
function
|
|
160
|
-
return e.closest(
|
|
147
|
+
function R(e) {
|
|
148
|
+
return e.closest(F);
|
|
161
149
|
}
|
|
162
|
-
function
|
|
163
|
-
return Array.from(e.querySelectorAll(
|
|
150
|
+
function te(e) {
|
|
151
|
+
return Array.from(e.querySelectorAll(P)).filter((e) => I(e) && !!e.name);
|
|
164
152
|
}
|
|
165
|
-
function
|
|
153
|
+
function ne(e) {
|
|
166
154
|
let t = e.getAttribute("name") || "";
|
|
167
155
|
return Array.from(t.matchAll(/\[([^\]]+)\]/g)).map((e) => e[1] || "").filter(Boolean);
|
|
168
156
|
}
|
|
169
|
-
function
|
|
157
|
+
function re(e, t) {
|
|
170
158
|
if (!t) return !0;
|
|
171
159
|
let n = t.split(/[.:]/).filter(Boolean);
|
|
172
160
|
if (!n.length) return !0;
|
|
173
|
-
let r =
|
|
161
|
+
let r = ne(e);
|
|
174
162
|
return r.length < n.length ? !1 : n.every((e, t) => r[r.length - n.length + t] === e);
|
|
175
163
|
}
|
|
176
|
-
function
|
|
164
|
+
function ie(e, t) {
|
|
177
165
|
if (!t) return e;
|
|
178
|
-
let n = e.filter((e) =>
|
|
166
|
+
let n = e.filter((e) => re(e, t));
|
|
179
167
|
return n.length ? n : e;
|
|
180
168
|
}
|
|
181
|
-
function
|
|
182
|
-
let n =
|
|
169
|
+
function z(e, t) {
|
|
170
|
+
let n = R(e);
|
|
183
171
|
if (!n) return t;
|
|
184
|
-
let r = t.filter((e) =>
|
|
172
|
+
let r = t.filter((e) => R(e) === n);
|
|
185
173
|
return r.length ? r : t;
|
|
186
174
|
}
|
|
187
|
-
function
|
|
175
|
+
function B(e) {
|
|
188
176
|
return !e.source?.target || !e.source.handle ? null : e.source.target === "field" || e.source.target === "submission" ? e.source : null;
|
|
189
177
|
}
|
|
190
|
-
function
|
|
191
|
-
let r =
|
|
178
|
+
function V(e, t, n) {
|
|
179
|
+
let r = B(n);
|
|
192
180
|
if (!r || r.target !== "field" || !r.handle) return [];
|
|
193
181
|
let i = s(r.handle), a = !!r.transformerParams.scope, c = Array.from(e.querySelectorAll(`[data-formie-field-handle="${i}"]`));
|
|
194
|
-
if (c.length) return (a ? c :
|
|
195
|
-
let l = o(r.handle), u = s(l), d = Array.from(e.querySelectorAll(`[name="${u}"]`)).filter((e) =>
|
|
196
|
-
if (d.length || f.length) return a ? [...d, ...f] :
|
|
182
|
+
if (c.length) return (a ? c : z(t, c)).flatMap((e) => ie(te(e), r.selector));
|
|
183
|
+
let l = o(r.handle), u = s(l), d = Array.from(e.querySelectorAll(`[name="${u}"]`)).filter((e) => I(e)), f = Array.from(e.querySelectorAll(`[name="${u}[]"]`)).filter((e) => I(e));
|
|
184
|
+
if (d.length || f.length) return a ? [...d, ...f] : z(t, [...d, ...f]);
|
|
197
185
|
if (!r.handle.includes("__ROW__")) return [];
|
|
198
|
-
let p =
|
|
186
|
+
let p = L(t);
|
|
199
187
|
if (p && !a) {
|
|
200
|
-
let t = o(r.handle.replace(/__ROW__/g, p)), n = s(t), i = Array.from(e.querySelectorAll(`[name="${n}"]`)).filter((e) =>
|
|
188
|
+
let t = o(r.handle.replace(/__ROW__/g, p)), n = s(t), i = Array.from(e.querySelectorAll(`[name="${n}"]`)).filter((e) => I(e)), a = Array.from(e.querySelectorAll(`[name="${n}[]"]`)).filter((e) => I(e));
|
|
201
189
|
if (i.length || a.length) return [...i, ...a];
|
|
202
190
|
}
|
|
203
191
|
if (!a) return [];
|
|
204
192
|
let m = o(r.handle).replace(/[.*+?^${}()|[\]\\]/g, "\\$&").replace(/__ROW__/g, "\\d+"), h = new RegExp(m);
|
|
205
|
-
return Array.from(e.querySelectorAll("[name]")).filter((e) =>
|
|
193
|
+
return Array.from(e.querySelectorAll("[name]")).filter((e) => I(e) && h.test(e.getAttribute("name") || ""));
|
|
206
194
|
}
|
|
207
195
|
//#endregion
|
|
208
196
|
//#region src/js/modules/fields/conditions/submission-context.ts
|
|
209
|
-
var
|
|
210
|
-
function
|
|
197
|
+
var H = "data-formie-submission", U = "formie:submission-context-change";
|
|
198
|
+
function W(e) {
|
|
211
199
|
return !!e && typeof e == "object" && !Array.isArray(e);
|
|
212
200
|
}
|
|
213
|
-
function W(e, t = e) {
|
|
214
|
-
return t.closest(`[${V}]`) || (e instanceof Element && e.hasAttribute("data-formie-submission") ? e : e.querySelector(`[${V}]`));
|
|
215
|
-
}
|
|
216
201
|
function G(e, t = e) {
|
|
217
|
-
|
|
202
|
+
return t.closest(`[${H}]`) || (e instanceof Element && e.hasAttribute("data-formie-submission") ? e : e.querySelector(`[${H}]`));
|
|
203
|
+
}
|
|
204
|
+
function K(e, t = e) {
|
|
205
|
+
let n = G(e, t)?.getAttribute(H);
|
|
218
206
|
if (!n) return {};
|
|
219
207
|
try {
|
|
220
208
|
let e = JSON.parse(n);
|
|
221
|
-
return
|
|
209
|
+
return W(e) ? Object.fromEntries(Object.entries(e).map(([e, t]) => [e, t == null ? "" : String(t)])) : {};
|
|
222
210
|
} catch (e) {
|
|
223
211
|
return console.error("[formie] Invalid submission context JSON.", e), {};
|
|
224
212
|
}
|
|
225
213
|
}
|
|
226
|
-
function
|
|
227
|
-
let r =
|
|
214
|
+
function q(e, t, n = e) {
|
|
215
|
+
let r = K(e, n), i = String(t.handle || "").trim(), a = "";
|
|
228
216
|
return i !== "" && (a = Object.prototype.hasOwnProperty.call(r, i) ? r[i] ?? "" : r[`submission${i.charAt(0).toUpperCase()}${i.slice(1)}`] ?? ""), a === "" && t.defaultValue && (a = t.defaultValue), [a];
|
|
229
217
|
}
|
|
230
218
|
//#endregion
|
|
231
219
|
//#region src/js/modules/fields/conditions/values.ts
|
|
232
|
-
function
|
|
220
|
+
function J(e, t) {
|
|
233
221
|
return e.name || `__condition_input_${t}`;
|
|
234
222
|
}
|
|
235
|
-
function
|
|
223
|
+
function ae(e) {
|
|
236
224
|
return (e.id ? e.ownerDocument.querySelector(`label[for="${e.id}"]`)?.textContent?.trim() : "") || e.closest("label")?.textContent?.trim() || "";
|
|
237
225
|
}
|
|
238
226
|
function oe(e, t = "") {
|
|
239
227
|
let n = e[0];
|
|
240
228
|
if (!n) return [];
|
|
241
229
|
if (n instanceof HTMLInputElement) {
|
|
242
|
-
if (n.type === "checkbox") {
|
|
243
|
-
let n = e.filter((e) => e instanceof HTMLInputElement && e.checked);
|
|
244
|
-
return t === "label" ? n.map((e) => J(e)).filter(Boolean) : n.map((e) => e.value);
|
|
245
|
-
}
|
|
246
|
-
if (n.type === "radio") {
|
|
230
|
+
if (n.type === "checkbox" || n.type === "radio") {
|
|
247
231
|
let n = e.filter((e) => e instanceof HTMLInputElement && e.checked);
|
|
248
|
-
return t === "label" ? n.map((e) =>
|
|
232
|
+
return t === "label" ? n.map((e) => ae(e)).filter(Boolean) : n.map((e) => e.value);
|
|
249
233
|
}
|
|
250
234
|
if (n.type === "file") return Array.from(n.files || []).map((e) => e.name);
|
|
251
235
|
}
|
|
@@ -257,7 +241,7 @@ function Y(e) {
|
|
|
257
241
|
function X(e, t = null) {
|
|
258
242
|
let n = /* @__PURE__ */ new Map();
|
|
259
243
|
e.forEach((e, t) => {
|
|
260
|
-
let r =
|
|
244
|
+
let r = J(e, t), i = n.get(r) || [];
|
|
261
245
|
i.push(e), n.set(r, i);
|
|
262
246
|
});
|
|
263
247
|
let r = Array.from(n.values()).flatMap((e) => oe(e, t?.selector || ""));
|
|
@@ -299,7 +283,7 @@ function Z(e, n, r, i) {
|
|
|
299
283
|
//#region src/js/modules/fields/conditions/evaluator.ts
|
|
300
284
|
function se(t, r, i = {}) {
|
|
301
285
|
let a = i.root, o = i.from || a, s = t.conditions.map((t) => {
|
|
302
|
-
let n = r(t), i =
|
|
286
|
+
let n = r(t), i = B(t), s = i?.target === "submission" && a && o ? q(a, i, o) : X(n, i);
|
|
303
287
|
if (t.browserSafe === !1 || i?.transformerId || i?.isValid === !1 || !n.length && i?.target !== "submission") return {
|
|
304
288
|
value: null,
|
|
305
289
|
diagnostics: [{ code: "unresolvedReference" }]
|
|
@@ -344,7 +328,7 @@ var ce = {
|
|
|
344
328
|
return n ? [{
|
|
345
329
|
node: e,
|
|
346
330
|
settings: n,
|
|
347
|
-
sourceInputs: $(n.conditions.flatMap((n) =>
|
|
331
|
+
sourceInputs: $(n.conditions.flatMap((n) => V(t, e, n)))
|
|
348
332
|
}] : [];
|
|
349
333
|
}), p = (e) => {
|
|
350
334
|
let t = new Map(e.map((e) => [e.node, e])), n = /* @__PURE__ */ new Set(), r = [], i = [];
|
|
@@ -373,10 +357,10 @@ var ce = {
|
|
|
373
357
|
finalResult: !1,
|
|
374
358
|
shouldHide: ["show", "enable"].includes(r.settings.showRule),
|
|
375
359
|
diagnostics: [{ code: "dependencyCycle" }]
|
|
376
|
-
} : se(r.settings, (e) =>
|
|
360
|
+
} : se(r.settings, (e) => V(t, r.node, e), {
|
|
377
361
|
root: t,
|
|
378
362
|
from: r.node
|
|
379
|
-
}), o = r.node.hasAttribute("data-formie-page") ? "hide" : m, s =
|
|
363
|
+
}), o = r.node.hasAttribute("data-formie-page") ? "hide" : m, s = M(r.node, i.shouldHide, r.settings.clearOnHide, {
|
|
380
364
|
displayMode: o,
|
|
381
365
|
disabledOnly: ["enable", "disable"].includes(r.settings.showRule)
|
|
382
366
|
});
|
|
@@ -431,8 +415,8 @@ var ce = {
|
|
|
431
415
|
let a = () => {
|
|
432
416
|
v();
|
|
433
417
|
};
|
|
434
|
-
e.form.addEventListener(
|
|
435
|
-
e.form?.removeEventListener(
|
|
418
|
+
e.form.addEventListener(U, a), n.push(() => {
|
|
419
|
+
e.form?.removeEventListener(U, a);
|
|
436
420
|
});
|
|
437
421
|
}
|
|
438
422
|
}, b = () => {
|
|
@@ -456,9 +440,9 @@ var ce = {
|
|
|
456
440
|
"data-formie-conditionally-hidden",
|
|
457
441
|
"data-formie-page-hidden",
|
|
458
442
|
"data-formie-row-hidden",
|
|
459
|
-
|
|
443
|
+
H
|
|
460
444
|
]
|
|
461
|
-
}), b(), await e.emit("formie:module:conditions:init", { count: i.length }), Q.log("Module setup complete.", { entryCount: i.length }), { destroy: () => {
|
|
445
|
+
}), b(), _(), await e.emit("formie:module:conditions:init", { count: i.length }), Q.log("Module setup complete.", { entryCount: i.length }), { destroy: () => {
|
|
462
446
|
l(), S.disconnect(), Q.log("Module destroy."), e.emit("formie:module:conditions:destroy", {});
|
|
463
447
|
} };
|
|
464
448
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { t as e } from "./request-profile-DhwkeCpS.js";
|
|
2
|
-
import { t } from "./dist-
|
|
2
|
+
import { t } from "./dist-CJReDlDK.js";
|
|
3
3
|
//#region src/js/utils/country-from-ip.ts
|
|
4
4
|
var n = "formie/address/country-from-ip", r = /* @__PURE__ */ new Map();
|
|
5
5
|
function i(e) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { a as e, c as t } from "./shared-
|
|
1
|
+
import { a as e, c as t } from "./shared-CJ1LIEh3.js";
|
|
2
2
|
//#region src/js/modules/fields/custom-google-maps.ts
|
|
3
3
|
var n = "custom-google-maps", r = "[data-formie-custom-google-maps]", i = null;
|
|
4
4
|
function a(e) {
|
|
@@ -170,11 +170,7 @@ async function y(e, t) {
|
|
|
170
170
|
function b(e) {
|
|
171
171
|
let t = s(e), n = o(e), r = null, i = !1;
|
|
172
172
|
return y(t, n).then((e) => {
|
|
173
|
-
|
|
174
|
-
e();
|
|
175
|
-
return;
|
|
176
|
-
}
|
|
177
|
-
r = e;
|
|
173
|
+
i ? e() : r = e;
|
|
178
174
|
}).catch((e) => {
|
|
179
175
|
console.warn("[Formie] Unable to initialize Google Maps custom field.", e);
|
|
180
176
|
}), () => {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { n as e } from "./rolldown-runtime-
|
|
1
|
+
import { n as e } from "./rolldown-runtime-VHNaYcLd.js";
|
|
2
2
|
import { t } from "./styles-BfoIZwJp.js";
|
|
3
|
-
import { a as n, c as r } from "./shared-
|
|
3
|
+
import { a as n, c as r } from "./shared-CJ1LIEh3.js";
|
|
4
4
|
//#region ../../node_modules/leaflet/dist/leaflet.css?inline
|
|
5
5
|
var i = ".leaflet-pane,.leaflet-tile,.leaflet-marker-icon,.leaflet-marker-shadow,.leaflet-tile-container,.leaflet-pane>svg,.leaflet-pane>canvas,.leaflet-zoom-box,.leaflet-image-layer,.leaflet-layer{position:absolute;top:0;left:0}.leaflet-container{overflow:hidden}.leaflet-tile,.leaflet-marker-icon,.leaflet-marker-shadow{-webkit-user-select:none;user-select:none;-webkit-user-drag:none}.leaflet-tile::selection{background:0 0}.leaflet-safari .leaflet-tile{image-rendering:-webkit-optimize-contrast}.leaflet-safari .leaflet-tile-container{-webkit-transform-origin:0 0;width:1600px;height:1600px}.leaflet-marker-icon,.leaflet-marker-shadow{display:block}.leaflet-container .leaflet-overlay-pane svg{max-width:none!important;max-height:none!important}.leaflet-container .leaflet-marker-pane img,.leaflet-container .leaflet-shadow-pane img,.leaflet-container .leaflet-tile-pane img,.leaflet-container img.leaflet-image-layer,.leaflet-container .leaflet-tile{width:auto;padding:0;max-width:none!important;max-height:none!important}.leaflet-container img.leaflet-tile{mix-blend-mode:plus-lighter}.leaflet-container.leaflet-touch-zoom{-ms-touch-action:pan-x pan-y;touch-action:pan-x pan-y}.leaflet-container.leaflet-touch-drag{-ms-touch-action:pinch-zoom;touch-action:none;touch-action:pinch-zoom}.leaflet-container.leaflet-touch-drag.leaflet-touch-zoom{-ms-touch-action:none;touch-action:none}.leaflet-container{-webkit-tap-highlight-color:transparent}.leaflet-container a{-webkit-tap-highlight-color:#33b5e566}.leaflet-tile{filter:inherit;visibility:hidden}.leaflet-tile-loaded{visibility:inherit}.leaflet-zoom-box{box-sizing:border-box;z-index:800;width:0;height:0}.leaflet-overlay-pane svg{-moz-user-select:none}.leaflet-pane{z-index:400}.leaflet-tile-pane{z-index:200}.leaflet-overlay-pane{z-index:400}.leaflet-shadow-pane{z-index:500}.leaflet-marker-pane{z-index:600}.leaflet-tooltip-pane{z-index:650}.leaflet-popup-pane{z-index:700}.leaflet-map-pane canvas{z-index:100}.leaflet-map-pane svg{z-index:200}.leaflet-vml-shape{width:1px;height:1px}.lvml{behavior:url(#default#VML);display:inline-block;position:absolute}.leaflet-control{z-index:800;pointer-events:visiblePainted;pointer-events:auto;position:relative}.leaflet-top,.leaflet-bottom{z-index:1000;pointer-events:none;position:absolute}.leaflet-top{top:0}.leaflet-right{right:0}.leaflet-bottom{bottom:0}.leaflet-left{left:0}.leaflet-control{float:left;clear:both}.leaflet-right .leaflet-control{float:right}.leaflet-top .leaflet-control{margin-top:10px}.leaflet-bottom .leaflet-control{margin-bottom:10px}.leaflet-left .leaflet-control{margin-left:10px}.leaflet-right .leaflet-control{margin-right:10px}.leaflet-fade-anim .leaflet-popup{opacity:0;transition:opacity .2s linear}.leaflet-fade-anim .leaflet-map-pane .leaflet-popup{opacity:1}.leaflet-zoom-animated{transform-origin:0 0}svg.leaflet-zoom-animated{will-change:transform}.leaflet-zoom-anim .leaflet-zoom-animated{-webkit-transition:-webkit-transform .25s cubic-bezier(0,0,.25,1);-moz-transition:-moz-transform .25s cubic-bezier(0,0,.25,1);transition:transform .25s cubic-bezier(0,0,.25,1)}.leaflet-zoom-anim .leaflet-tile,.leaflet-pan-anim .leaflet-tile{transition:none}.leaflet-zoom-anim .leaflet-zoom-hide{visibility:hidden}.leaflet-interactive{cursor:pointer}.leaflet-grab{cursor:-webkit-grab;cursor:-moz-grab;cursor:grab}.leaflet-crosshair,.leaflet-crosshair .leaflet-interactive{cursor:crosshair}.leaflet-popup-pane,.leaflet-control{cursor:auto}.leaflet-dragging .leaflet-grab,.leaflet-dragging .leaflet-grab .leaflet-interactive,.leaflet-dragging .leaflet-marker-draggable{cursor:move;cursor:-webkit-grabbing;cursor:-moz-grabbing;cursor:grabbing}.leaflet-marker-icon,.leaflet-marker-shadow,.leaflet-image-layer,.leaflet-pane>svg path,.leaflet-tile-container{pointer-events:none}.leaflet-marker-icon.leaflet-interactive,.leaflet-image-layer.leaflet-interactive,.leaflet-pane>svg path.leaflet-interactive,svg.leaflet-image-layer.leaflet-interactive path{pointer-events:visiblePainted;pointer-events:auto}.leaflet-container{outline-offset:1px;background:#ddd}.leaflet-container a{color:#0078a8}.leaflet-zoom-box{background:#ffffff80;border:2px dotted #38f}.leaflet-container{font-family:Helvetica Neue,Arial,Helvetica,sans-serif;font-size:.75rem;line-height:1.5}.leaflet-bar{border-radius:4px;box-shadow:0 1px 5px #000000a6}.leaflet-bar a{text-align:center;color:#000;background-color:#fff;border-bottom:1px solid #ccc;width:26px;height:26px;line-height:26px;text-decoration:none;display:block}.leaflet-bar a,.leaflet-control-layers-toggle{background-position:50%;background-repeat:no-repeat;display:block}.leaflet-bar a:hover,.leaflet-bar a:focus{background-color:#f4f4f4}.leaflet-bar a:first-child{border-top-left-radius:4px;border-top-right-radius:4px}.leaflet-bar a:last-child{border-bottom:none;border-bottom-right-radius:4px;border-bottom-left-radius:4px}.leaflet-bar a.leaflet-disabled{cursor:default;color:#bbb;background-color:#f4f4f4}.leaflet-touch .leaflet-bar a{width:30px;height:30px;line-height:30px}.leaflet-touch .leaflet-bar a:first-child{border-top-left-radius:2px;border-top-right-radius:2px}.leaflet-touch .leaflet-bar a:last-child{border-bottom-right-radius:2px;border-bottom-left-radius:2px}.leaflet-control-zoom-in,.leaflet-control-zoom-out{text-indent:1px;font:700 18px Lucida Console,Monaco,monospace}.leaflet-touch .leaflet-control-zoom-in,.leaflet-touch .leaflet-control-zoom-out{font-size:22px}.leaflet-control-layers{background:#fff;border-radius:5px;box-shadow:0 1px 5px #0006}.leaflet-control-layers-toggle{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABoAAAAaCAQAAAADQ4RFAAACf0lEQVR4AY1UM3gkARTePdvdoTxXKc+qTl3aU5U6b2Kbkz3Gtq3Zw6ziLGNPzrYx7946Tr6/ee/XeCQ4D3ykPtL5tHno4n0d/h3+xfuWHGLX81cn7r0iTNzjr7LrlxCqPtkbTQEHeqOrTy4Yyt3VCi/IOB0v7rVC7q45Q3Gr5K6jt+3Gl5nCoDD4MtO+j96Wu8atmhGqcNGHObuf8OM/x3AMx38+4Z2sPqzCxRFK2aF2e5Jol56XTLyggAMTL56XOMoS1W4pOyjUcGGQdZxU6qRh7B9Zp+PfpOFlqt0zyDZckPi1ttmIp03jX8gyJ8a/PG2yutpS/Vol7peZIbZcKBAEEheEIAgFbDkz5H6Zrkm2hVWGiXKiF4Ycw0RWKdtC16Q7qe3X4iOMxruonzegJzWaXFrU9utOSsLUmrc0YjeWYjCW4PDMADElpJSSQ0vQvA1Tm6/JlKnqFs1EGyZiFCqnRZTEJJJiKRYzVYzJck2Rm6P4iH+cmSY0YzimYa8l0EtTODFWhcMIMVqdsI2uiTvKmTisIDHJ3od5GILVhBCarCfVRmo4uTjkhrhzkiBV7SsaqS+TzrzM1qpGGUFt28pIySQHR6h7F6KSwGWm97ay+Z+ZqMcEjEWebE7wxCSQwpkhJqoZA5ivCdZDjJepuJ9IQjGGUmuXJdBFUygxVqVsxFsLMbDe8ZbDYVCGKxs+W080max1hFCarCfV+C1KATwcnvE9gRRuMP2prdbWGowm1KB1y+zwMMENkM755cJ2yPDtqhTI6ED1M/82yIDtC/4j4BijjeObflpO9I9MwXTCsSX8jWAFeHr05WoLTJ5G8IQVS/7vwR6ohirYM7f6HzYpogfS3R2OAAAAAElFTkSuQmCC);width:36px;height:36px}.leaflet-retina .leaflet-control-layers-toggle{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADQAAAA0CAQAAABvcdNgAAAEsklEQVR4AWL4TydIhpZK1kpWOlg0w3ZXP6D2soBtG42jeI6ZmQTHzAxiTbSJsYLjO9HhP+WOmcuhciVnmHVQcJnp7DFvScowZorad/+V/fVzMdMT2g9Cv9guXGv/7pYOrXh2U+RRR3dSd9JRx6bIFc/ekqHI29JC6pJ5ZEh1yWkhkbcFeSjxgx3L2m1cb1C7bceyxA+CNjT/Ifff+/kDk2u/w/33/IeCMOSaWZ4glosqT3DNnNZQ7Cs58/3Ce5HL78iZH/vKVIaYlqzfdLu8Vi7dnvUbEza5Idt36tquZFldl6N5Z/POLof0XLK61mZCmJSWjVF9tEjUluu74IUXvgttuVIHE7YxSkaYhJZam7yiM9Pv82JYfl9nptxZaxMJE4YSPty+vF0+Y2up9d3wwijfjZbabqm/3bZ9ecKHsiGmRflnn1MW4pjHf9oLufyn2z3y1D6n8g8TZhxyzipLNPnAUpsOiuWimg52psrTZYnOWYNDTMuWBWa0tJb4rgq1UvmutpaYEbZlwU3CLJm/ayYjHW5/h7xWLn9Hh1vepDkyf7dE7MtT5LR4e7yYpHrkhOUpEfssBLq2pPhAqoSWKUkk7EDqkmK6RrCEzqDjhNDWNE+XSMvkJRDWlZTmCW0l0PHQGRZY5t1L83kT0Y3l2SItk5JAWHl2dCOBm+fPu3fo5/3v61RMCO9Jx2EEYYhb0rmNQMX/vm7gqOEJLcXTGw3CAuRNeyaPWwjR8PRqKQ1PDA/dpv+on9Shox52WFnx0KY8onHayrJzm87i5h9xGw/tfkev0jGsQizqezUKjk12hBMKJ4kbCqGPVNXudyyrShovGw5CgxsRICxF6aRmSjlBnHRzg7Gx8fKqEubI2rahQYdR1YgDIRQO7JvQyD52hoIQx0mxa0ODtW2Iozn1le2iIRdzwWewedyZzewidueOGqlsn1MvcnQpuVwLGG3/IR1hIKxCjelIDZ8ldqWz25jWAsnldEnK0Zxro19TGVb2ffIZEsIO89EIEDvKMPrzmBOQcKQ+rroye6NgRRxqR4U8EAkz0CL6uSGOm6KQCdWjvjRiSP1BPalCRS5iQYiEIvxuBMJEWgzSoHADcVMuN7IuqqTeyUPq22qFimFtxDyBBJEwNyt6TM88blFHao/6tWWhuuOM4SAK4EI4QmFHA+SEyWlp4EQoJ13cYGzMu7yszEIBOm2rVmHUNqwAIQabISNMRstmdhNWcFLsSm+0tjJH1MdRxO5Nx0WDMhCtgD6OKgZeljJqJKc9po8juskR9XN0Y1lZ3mWjLR9JCO1jRDMd0fpYC2VnvjBSEFg7wBENc0R9HFlb0xvF1+TBEpF68d+DHR6IOWVv2BECtxo46hOFUBd/APU57WIoEwJhIi2CdpyZX0m93BZicktMj1AS9dClteUFAUNUIEygRZCtik5zSxI9MubTBH1GOiHsiLJ3OCoSZkILa9PxiN0EbvhsAo8tdAf9Seepd36lGWHmtNANTv5Jd0z4QYyeo/UEJqxKRpg5LZx6btLPsOaEmdMyxYdlc8LMaJnikDlhclqmPiQnTEpLUIZEwkRagjYkEibQErwhkTAKCLQEbUgkzJQWc/0PstHHcfEdQ+UAAAAASUVORK5CYII=);background-size:26px 26px}.leaflet-touch .leaflet-control-layers-toggle{width:44px;height:44px}.leaflet-control-layers .leaflet-control-layers-list,.leaflet-control-layers-expanded .leaflet-control-layers-toggle{display:none}.leaflet-control-layers-expanded .leaflet-control-layers-list{display:block;position:relative}.leaflet-control-layers-expanded{color:#333;background:#fff;padding:6px 10px 6px 6px}.leaflet-control-layers-scrollbar{padding-right:5px;overflow:hidden scroll}.leaflet-control-layers-selector{margin-top:2px;position:relative;top:1px}.leaflet-control-layers label{font-size:1.08333em;display:block}.leaflet-control-layers-separator{border-top:1px solid #ddd;height:0;margin:5px -10px 5px -6px}.leaflet-default-icon-path{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABkAAAApCAYAAADAk4LOAAAFgUlEQVR4Aa1XA5BjWRTN2oW17d3YaZtr2962HUzbDNpjszW24mRt28p47v7zq/bXZtrp/lWnXr337j3nPCe85NcypgSFdugCpW5YoDAMRaIMqRi6aKq5E3YqDQO3qAwjVWrD8Ncq/RBpykd8oZUb/kaJutow8r1aP9II0WmLKLIsJyv1w/kqw9Ch2MYdB++12Onxee/QMwvf4/Dk/Lfp/i4nxTXtOoQ4pW5Aj7wpici1A9erdAN2OH64x8OSP9j3Ft3b7aWkTg/Fm91siTra0f9on5sQr9INejH6CUUUpavjFNq1B+Oadhxmnfa8RfEmN8VNAsQhPqF55xHkMzz3jSmChWU6f7/XZKNH+9+hBLOHYozuKQPxyMPUKkrX/K0uWnfFaJGS1QPRtZsOPtr3NsW0uyh6NNCOkU3Yz+bXbT3I8G3xE5EXLXtCXbbqwCO9zPQYPRTZ5vIDXD7U+w7rFDEoUUf7ibHIR4y6bLVPXrz8JVZEql13trxwue/uDivd3fkWRbS6/IA2bID4uk0UpF1N8qLlbBlXs4Ee7HLTfV1j54APvODnSfOWBqtKVvjgLKzF5YdEk5ewRkGlK0i33Eofffc7HT56jD7/6U+qH3Cx7SBLNntH5YIPvODnyfIXZYRVDPqgHtLs5ABHD3YzLuespb7t79FY34DjMwrVrcTuwlT55YMPvOBnRrJ4VXTdNnYug5ucHLBjEpt30701A3Ts+HEa73u6dT3FNWwflY86eMHPk+Yu+i6pzUpRrW7SNDg5JHR4KapmM5Wv2E8Tfcb1HoqqHMHU+uWDD7zg54mz5/2BSnizi9T1Dg4QQXLToGNCkb6tb1NU+QAlGr1++eADrzhn/u8Q2YZhQVlZ5+CAOtqfbhmaUCS1ezNFVm2imDbPmPng5wmz+gwh+oHDce0eUtQ6OGDIyR0uUhUsoO3vfDmmgOezH0mZN59x7MBi++WDL1g/eEiU3avlidO671bkLfwbw5XV2P8Pzo0ydy4t2/0eu33xYSOMOD8hTf4CrBtGMSoXfPLchX+J0ruSePw3LZeK0juPJbYzrhkH0io7B3k164hiGvawhOKMLkrQLyVpZg8rHFW7E2uHOL888IBPlNZ1FPzstSJM694fWr6RwpvcJK60+0HCILTBzZLFNdtAzJaohze60T8qBzyh5ZuOg5e7uwQppofEmf2++DYvmySqGBuKaicF1blQjhuHdvCIMvp8whTTfZzI7RldpwtSzL+F1+wkdZ2TBOW2gIF88PBTzD/gpeREAMEbxnJcaJHNHrpzji0gQCS6hdkEeYt9DF/2qPcEC8RM28Hwmr3sdNyht00byAut2k3gufWNtgtOEOFGUwcXWNDbdNbpgBGxEvKkOQsxivJx33iow0Vw5S6SVTrpVq11ysA2Rp7gTfPfktc6zhtXBBC+adRLshf6sG2RfHPZ5EAc4sVZ83yCN00Fk/4kggu40ZTvIEm5g24qtU4KjBrx/BTTH8ifVASAG7gKrnWxJDcU7x8X6Ecczhm3o6YicvsLXWfh3Ch1W0k8x0nXF+0fFxgt4phz8QvypiwCCFKMqXCnqXExjq10beH+UUA7+nG6mdG/Pu0f3LgFcGrl2s0kNNjpmoJ9o4B29CMO8dMT4Q5ox8uitF6fqsrJOr8qnwNbRzv6hSnG5wP+64C7h9lp30hKNtKdWjtdkbuPA19nJ7Tz3zR/ibgARbhb4AlhavcBebmTHcFl2fvYEnW0ox9xMxKBS8btJ+KiEbq9zA4RthQXDhPa0T9TEe69gWupwc6uBUphquXgf+/FrIjweHQS4/pduMe5ERUMHUd9xv8ZR98CxkS4F2n3EUrUZ10EYNw7BWm9x1GiPssi3GgiGRDKWRYZfXlON+dfNbM+GgIwYdwAAAAASUVORK5CYII=)}.leaflet-container .leaflet-control-attribution{background:#fffc;margin:0}.leaflet-control-attribution,.leaflet-control-scale-line{color:#333;padding:0 5px;line-height:1.4}.leaflet-control-attribution a{text-decoration:none}.leaflet-control-attribution a:hover,.leaflet-control-attribution a:focus{text-decoration:underline}.leaflet-attribution-flag{width:1em;height:.6669em;vertical-align:baseline!important;display:inline!important}.leaflet-left .leaflet-control-scale{margin-left:5px}.leaflet-bottom .leaflet-control-scale{margin-bottom:5px}.leaflet-control-scale-line{white-space:nowrap;box-sizing:border-box;text-shadow:1px 1px #fff;background:#fffc;border:2px solid #777;border-top:none;padding:2px 5px 1px;line-height:1.1}.leaflet-control-scale-line:not(:first-child){border-top:2px solid #777;border-bottom:none;margin-top:-2px}.leaflet-control-scale-line:not(:first-child):not(:last-child){border-bottom:2px solid #777}.leaflet-touch .leaflet-control-attribution,.leaflet-touch .leaflet-control-layers,.leaflet-touch .leaflet-bar{box-shadow:none}.leaflet-touch .leaflet-control-layers,.leaflet-touch .leaflet-bar{background-clip:padding-box;border:2px solid #0003}.leaflet-popup{text-align:center;margin-bottom:20px;position:absolute}.leaflet-popup-content-wrapper{text-align:left;border-radius:12px;padding:1px}.leaflet-popup-content{min-height:1px;margin:13px 24px 13px 20px;font-size:1.08333em;line-height:1.3}.leaflet-popup-content p{margin:1.3em 0}.leaflet-popup-tip-container{pointer-events:none;width:40px;height:20px;margin-top:-1px;margin-left:-20px;position:absolute;left:50%;overflow:hidden}.leaflet-popup-tip{pointer-events:auto;width:17px;height:17px;margin:-10px auto 0;padding:1px;transform:rotate(45deg)}.leaflet-popup-content-wrapper,.leaflet-popup-tip{color:#333;background:#fff;box-shadow:0 3px 14px #0006}.leaflet-container a.leaflet-popup-close-button{text-align:center;color:#757575;background:0 0;border:none;width:24px;height:24px;font:16px/24px Tahoma,Verdana,sans-serif;text-decoration:none;position:absolute;top:0;right:0}.leaflet-container a.leaflet-popup-close-button:hover,.leaflet-container a.leaflet-popup-close-button:focus{color:#585858}.leaflet-popup-scrolled{overflow:auto}.leaflet-oldie .leaflet-popup-content-wrapper{-ms-zoom:1}.leaflet-oldie .leaflet-popup-tip{-ms-filter:\"progid:DXImageTransform.Microsoft.Matrix(M11=0.70710678, M12=0.70710678, M21=-0.70710678, M22=0.70710678)\";width:24px;filter:progid:DXImageTransform.Microsoft.Matrix(M11=.707107, M12=.707107, M21=-.707107, M22=.707107);margin:0 auto}.leaflet-oldie .leaflet-control-zoom,.leaflet-oldie .leaflet-control-layers,.leaflet-oldie .leaflet-popup-content-wrapper,.leaflet-oldie .leaflet-popup-tip{border:1px solid #999}.leaflet-div-icon{background:#fff;border:1px solid #666}.leaflet-tooltip{color:#222;white-space:nowrap;-webkit-user-select:none;user-select:none;pointer-events:none;background-color:#fff;border:1px solid #fff;border-radius:3px;padding:6px;position:absolute;box-shadow:0 1px 3px #0006}.leaflet-tooltip.leaflet-interactive{cursor:pointer;pointer-events:auto}.leaflet-tooltip-top:before,.leaflet-tooltip-bottom:before,.leaflet-tooltip-left:before,.leaflet-tooltip-right:before{pointer-events:none;content:\"\";background:0 0;border:6px solid #0000;position:absolute}.leaflet-tooltip-bottom{margin-top:6px}.leaflet-tooltip-top{margin-top:-6px}.leaflet-tooltip-bottom:before,.leaflet-tooltip-top:before{margin-left:-6px;left:50%}.leaflet-tooltip-top:before{border-top-color:#fff;margin-bottom:-12px;bottom:0}.leaflet-tooltip-bottom:before{border-bottom-color:#fff;margin-top:-12px;margin-left:-6px;top:0}.leaflet-tooltip-left{margin-left:-6px}.leaflet-tooltip-right{margin-left:6px}.leaflet-tooltip-left:before,.leaflet-tooltip-right:before{margin-top:-6px;top:50%}.leaflet-tooltip-left:before{border-left-color:#fff;margin-right:-12px;right:0}.leaflet-tooltip-right:before{border-right-color:#fff;margin-left:-12px;left:0}@media print{.leaflet-control{-webkit-print-color-adjust:exact;print-color-adjust:exact}}", a = "custom-maps", o = "[data-formie-custom-maps]";
|
|
6
6
|
t(a, [i]);
|
|
@@ -51,7 +51,7 @@ function h(e, t, n) {
|
|
|
51
51
|
m(e.latInput, t.lat), m(e.lngInput, t.lng), n !== void 0 && m(e.zoomInput, n);
|
|
52
52
|
}
|
|
53
53
|
function g() {
|
|
54
|
-
return s ||= import("./leaflet-src-
|
|
54
|
+
return s ||= import("./leaflet-src-Cg-LUOD8.js").then((t) => /* @__PURE__ */ e(t.default, 1)), s;
|
|
55
55
|
}
|
|
56
56
|
function _(e) {
|
|
57
57
|
switch (e.mapTiles) {
|
|
@@ -139,11 +139,7 @@ async function x(e, t) {
|
|
|
139
139
|
function S(e) {
|
|
140
140
|
let t = u(e), n = l(e), r = null, i = !1;
|
|
141
141
|
return e.getAttribute("data-formie-custom-map-hide-map") !== "1" && x(t, n).then((e) => {
|
|
142
|
-
|
|
143
|
-
e();
|
|
144
|
-
return;
|
|
145
|
-
}
|
|
146
|
-
r = e;
|
|
142
|
+
i ? e() : r = e;
|
|
147
143
|
}), () => {
|
|
148
144
|
i = !0, r?.();
|
|
149
145
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { n as e, t } from "./rolldown-runtime-
|
|
2
|
-
import { t as n } from "./debug-
|
|
1
|
+
import { n as e, t } from "./rolldown-runtime-VHNaYcLd.js";
|
|
2
|
+
import { t as n } from "./debug-rhzqP1j2.js";
|
|
3
3
|
import { t as r } from "./styles-BfoIZwJp.js";
|
|
4
|
-
import { i, n as a, t as o } from "./shared-
|
|
4
|
+
import { i, n as a, t as o } from "./shared-CJ1LIEh3.js";
|
|
5
5
|
//#region ../../node_modules/flatpickr/dist/esm/types/options.js
|
|
6
6
|
var s = [
|
|
7
7
|
"onChange",
|
|
@@ -411,11 +411,8 @@ var b = function() {}, x = function(e, t, n) {
|
|
|
411
411
|
}), s = f ? s : void 0;
|
|
412
412
|
}
|
|
413
413
|
}
|
|
414
|
-
if (!(s instanceof Date && !isNaN(s.getTime())))
|
|
415
|
-
|
|
416
|
-
return;
|
|
417
|
-
}
|
|
418
|
-
return r === !0 && s.setHours(0, 0, 0, 0), s;
|
|
414
|
+
if (!(s instanceof Date && !isNaN(s.getTime()))) n.errorHandler(/* @__PURE__ */ Error("Invalid date provided: " + l));
|
|
415
|
+
else return r === !0 && s.setHours(0, 0, 0, 0), s;
|
|
419
416
|
}
|
|
420
417
|
};
|
|
421
418
|
};
|
|
@@ -589,20 +586,19 @@ function le(e, t) {
|
|
|
589
586
|
Array.prototype.forEach.call(n.element.querySelectorAll("[data-" + e + "]"), function(t) {
|
|
590
587
|
return j(t, "click", n[e]);
|
|
591
588
|
});
|
|
592
|
-
}), n.isMobile)
|
|
593
|
-
|
|
594
|
-
|
|
589
|
+
}), n.isMobile) Ge();
|
|
590
|
+
else {
|
|
591
|
+
var e = f(De, 50);
|
|
592
|
+
n._debouncedChange = f(de, ce), n.daysContainer && !/iPhone|iPad|iPod/i.test(navigator.userAgent) && j(n.daysContainer, "mouseover", function(e) {
|
|
593
|
+
n.config.mode === "range" && J(y(e));
|
|
594
|
+
}), j(n._input, "keydown", Ee), n.calendarContainer !== void 0 && j(n.calendarContainer, "keydown", Ee), !n.config.inline && !n.config.static && j(window, "resize", e), window.ontouchstart === void 0 ? j(window.document, "mousedown", we) : j(window.document, "touchstart", we), j(window.document, "focus", we, { capture: !0 }), n.config.clickOpens === !0 && (j(n._input, "focus", n.open), j(n._input, "click", n.open)), n.daysContainer !== void 0 && (j(n.monthNav, "click", Ze), j(n.monthNav, ["keyup", "increment"], ue), j(n.daysContainer, "click", Le)), n.timeContainer !== void 0 && n.minuteElement !== void 0 && n.hourElement !== void 0 && (j(n.timeContainer, ["increment"], S), j(n.timeContainer, "blur", S, { capture: !0 }), j(n.timeContainer, "click", fe), j([n.hourElement, n.minuteElement], ["focus", "click"], function(e) {
|
|
595
|
+
return y(e).select();
|
|
596
|
+
}), n.secondElement !== void 0 && j(n.secondElement, "focus", function() {
|
|
597
|
+
return n.secondElement && n.secondElement.select();
|
|
598
|
+
}), n.amPM !== void 0 && j(n.amPM, "click", function(e) {
|
|
599
|
+
S(e);
|
|
600
|
+
})), n.config.allowInput && j(n._input, "blur", Te);
|
|
595
601
|
}
|
|
596
|
-
var e = f(De, 50);
|
|
597
|
-
n._debouncedChange = f(de, ce), n.daysContainer && !/iPhone|iPad|iPod/i.test(navigator.userAgent) && j(n.daysContainer, "mouseover", function(e) {
|
|
598
|
-
n.config.mode === "range" && J(y(e));
|
|
599
|
-
}), j(n._input, "keydown", Ee), n.calendarContainer !== void 0 && j(n.calendarContainer, "keydown", Ee), !n.config.inline && !n.config.static && j(window, "resize", e), window.ontouchstart === void 0 ? j(window.document, "mousedown", we) : j(window.document, "touchstart", we), j(window.document, "focus", we, { capture: !0 }), n.config.clickOpens === !0 && (j(n._input, "focus", n.open), j(n._input, "click", n.open)), n.daysContainer !== void 0 && (j(n.monthNav, "click", Ze), j(n.monthNav, ["keyup", "increment"], ue), j(n.daysContainer, "click", Le)), n.timeContainer !== void 0 && n.minuteElement !== void 0 && n.hourElement !== void 0 && (j(n.timeContainer, ["increment"], S), j(n.timeContainer, "blur", S, { capture: !0 }), j(n.timeContainer, "click", fe), j([n.hourElement, n.minuteElement], ["focus", "click"], function(e) {
|
|
600
|
-
return y(e).select();
|
|
601
|
-
}), n.secondElement !== void 0 && j(n.secondElement, "focus", function() {
|
|
602
|
-
return n.secondElement && n.secondElement.select();
|
|
603
|
-
}), n.amPM !== void 0 && j(n.amPM, "click", function(e) {
|
|
604
|
-
S(e);
|
|
605
|
-
})), n.config.allowInput && j(n._input, "blur", Te);
|
|
606
602
|
}
|
|
607
603
|
function N(e, t) {
|
|
608
604
|
var r = e === void 0 ? n.latestSelectedDateObj || (n.config.minDate && n.config.minDate > n.now ? n.config.minDate : n.config.maxDate && n.config.maxDate < n.now ? n.config.maxDate : n.now) : n.parseDate(e), i = n.currentYear, a = n.currentMonth;
|
|
@@ -910,17 +906,13 @@ function le(e, t) {
|
|
|
910
906
|
for (var r = e ? e.dateObj.getTime() : n.days.firstElementChild.dateObj.getTime(), i = n.parseDate(n.selectedDates[0], void 0, !0).getTime(), a = Math.min(r, n.selectedDates[0].getTime()), o = Math.max(r, n.selectedDates[0].getTime()), s = !1, c = 0, l = 0, u = a; u < o; u += ae.DAY) K(new Date(u), !0) || (s ||= u > a && u < o, u < i && (!c || u > c) ? c = u : u > i && (!l || u < l) && (l = u));
|
|
911
907
|
Array.from(n.rContainer.querySelectorAll("*:nth-child(-n+" + n.config.showMonths + ") > ." + t)).forEach(function(t) {
|
|
912
908
|
var a = t.dateObj.getTime(), o = c > 0 && a < c || l > 0 && a > l;
|
|
913
|
-
|
|
914
|
-
|
|
915
|
-
|
|
916
|
-
|
|
917
|
-
|
|
918
|
-
|
|
919
|
-
|
|
920
|
-
});
|
|
921
|
-
return;
|
|
922
|
-
}
|
|
923
|
-
(!s || o) && ([
|
|
909
|
+
o ? (t.classList.add("notAllowed"), [
|
|
910
|
+
"inRange",
|
|
911
|
+
"startRange",
|
|
912
|
+
"endRange"
|
|
913
|
+
].forEach(function(e) {
|
|
914
|
+
t.classList.remove(e);
|
|
915
|
+
})) : (!s || o) && ([
|
|
924
916
|
"startRange",
|
|
925
917
|
"inRange",
|
|
926
918
|
"endRange",
|
|
@@ -942,9 +934,7 @@ function le(e, t) {
|
|
|
942
934
|
r && r.blur();
|
|
943
935
|
}
|
|
944
936
|
n.mobileInput !== void 0 && (n.mobileInput.focus(), n.mobileInput.click()), Z("onOpen");
|
|
945
|
-
|
|
946
|
-
}
|
|
947
|
-
if (!(n._input.disabled || n.config.inline)) {
|
|
937
|
+
} else if (!(n._input.disabled || n.config.inline)) {
|
|
948
938
|
var i = n.isOpen;
|
|
949
939
|
n.isOpen = !0, i || (n.calendarContainer.classList.add("open"), n._input.classList.add("active"), Z("onOpen"), Y(t)), n.config.enableTime === !0 && n.config.noCalendar === !0 && n.config.allowInput === !1 && (e === void 0 || !n.timeContainer.contains(e.relatedTarget)) && setTimeout(function() {
|
|
950
940
|
return n.hourElement.select();
|
|
@@ -1049,11 +1039,8 @@ function le(e, t) {
|
|
|
1049
1039
|
});
|
|
1050
1040
|
}
|
|
1051
1041
|
function Y(e) {
|
|
1052
|
-
if (typeof n.config.position == "function")
|
|
1053
|
-
|
|
1054
|
-
return;
|
|
1055
|
-
}
|
|
1056
|
-
if (n.calendarContainer !== void 0) {
|
|
1042
|
+
if (typeof n.config.position == "function") n.config.position(n, e);
|
|
1043
|
+
else if (n.calendarContainer !== void 0) {
|
|
1057
1044
|
Z("onPreCalendarPosition");
|
|
1058
1045
|
var t = e || n._positionElement, r = Array.prototype.reduce.call(n.calendarContainer.children, (function(e, t) {
|
|
1059
1046
|
return e + t.offsetHeight;
|
|
@@ -1195,11 +1182,7 @@ function le(e, t) {
|
|
|
1195
1182
|
e && ze(e, n.config.dateFormat), n._initialDate = n.selectedDates.length > 0 ? n.selectedDates[0] : n.config.minDate && n.config.minDate.getTime() > n.now.getTime() ? n.config.minDate : n.config.maxDate && n.config.maxDate.getTime() < n.now.getTime() ? n.config.maxDate : n.now, n.currentYear = n._initialDate.getFullYear(), n.currentMonth = n._initialDate.getMonth(), n.selectedDates.length > 0 && (n.latestSelectedDateObj = n.selectedDates[0]), n.config.minTime !== void 0 && (n.config.minTime = n.parseDate(n.config.minTime, "H:i")), n.config.maxTime !== void 0 && (n.config.maxTime = n.parseDate(n.config.maxTime, "H:i")), n.minDateHasTime = !!n.config.minDate && (n.config.minDate.getHours() > 0 || n.config.minDate.getMinutes() > 0 || n.config.minDate.getSeconds() > 0), n.maxDateHasTime = !!n.config.maxDate && (n.config.maxDate.getHours() > 0 || n.config.maxDate.getMinutes() > 0 || n.config.maxDate.getSeconds() > 0);
|
|
1196
1183
|
}
|
|
1197
1184
|
function Ue() {
|
|
1198
|
-
|
|
1199
|
-
n.config.errorHandler(/* @__PURE__ */ Error("Invalid input element specified"));
|
|
1200
|
-
return;
|
|
1201
|
-
}
|
|
1202
|
-
n.input._type = n.input.type, n.input.type = "text", n.input.classList.add("flatpickr-input"), n._input = n.input, n.config.altInput && (n.altInput = h(n.input.nodeName, n.config.altInputClass), n._input = n.altInput, n.altInput.placeholder = n.input.placeholder, n.altInput.disabled = n.input.disabled, n.altInput.required = n.input.required, n.altInput.tabIndex = n.input.tabIndex, n.altInput.type = "text", n.input.setAttribute("type", "hidden"), !n.config.static && n.input.parentNode && n.input.parentNode.insertBefore(n.altInput, n.input.nextSibling)), n.config.allowInput || n._input.setAttribute("readonly", "readonly"), We();
|
|
1185
|
+
n.input = je(), n.input ? (n.input._type = n.input.type, n.input.type = "text", n.input.classList.add("flatpickr-input"), n._input = n.input, n.config.altInput && (n.altInput = h(n.input.nodeName, n.config.altInputClass), n._input = n.altInput, n.altInput.placeholder = n.input.placeholder, n.altInput.disabled = n.input.disabled, n.altInput.required = n.input.required, n.altInput.tabIndex = n.input.tabIndex, n.altInput.type = "text", n.input.setAttribute("type", "hidden"), !n.config.static && n.input.parentNode && n.input.parentNode.insertBefore(n.altInput, n.input.nextSibling)), n.config.allowInput || n._input.setAttribute("readonly", "readonly"), We()) : n.config.errorHandler(/* @__PURE__ */ Error("Invalid input element specified"));
|
|
1203
1186
|
}
|
|
1204
1187
|
function We() {
|
|
1205
1188
|
n._positionElement = n.config.positionElement || n._input;
|
|
@@ -1308,10 +1291,10 @@ O.defaultConfig = {}, O.l10ns = {
|
|
|
1308
1291
|
}, typeof window < "u" && (window.flatpickr = O);
|
|
1309
1292
|
//#endregion
|
|
1310
1293
|
//#region ../../node_modules/flatpickr/dist/flatpickr.css?inline
|
|
1311
|
-
var k = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
|
|
1294
|
+
var k = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t, n) => {
|
|
1312
1295
|
(function(n, r) {
|
|
1313
1296
|
typeof e == "object" && t !== void 0 ? r(e) : typeof define == "function" && define.amd ? define(["exports"], r) : (n = typeof globalThis < "u" ? globalThis : n || self, r(n.index = {}));
|
|
1314
|
-
})(
|
|
1297
|
+
})(n, (function(e) {
|
|
1315
1298
|
var t = function() {
|
|
1316
1299
|
return t = Object.assign || function(e) {
|
|
1317
1300
|
for (var t, n = 1, r = arguments.length; n < r; n++) for (var i in t = arguments[n], t) Object.prototype.hasOwnProperty.call(t, i) && (e[i] = t[i]);
|
|
@@ -9,22 +9,10 @@ function n(t) {
|
|
|
9
9
|
e().__FORMIE_DEBUG__ = t;
|
|
10
10
|
}
|
|
11
11
|
function r(e, n, r) {
|
|
12
|
-
|
|
13
|
-
if (r === void 0) {
|
|
14
|
-
console.log(`[formie:${e}] ${n}`);
|
|
15
|
-
return;
|
|
16
|
-
}
|
|
17
|
-
console.log(`[formie:${e}] ${n}`, r);
|
|
18
|
-
}
|
|
12
|
+
t() && (r === void 0 ? console.log(`[formie:${e}] ${n}`) : console.log(`[formie:${e}] ${n}`, r));
|
|
19
13
|
}
|
|
20
14
|
function i(e, n, r) {
|
|
21
|
-
|
|
22
|
-
if (r === void 0) {
|
|
23
|
-
console.warn(`[formie:${e}] ${n}`);
|
|
24
|
-
return;
|
|
25
|
-
}
|
|
26
|
-
console.warn(`[formie:${e}] ${n}`, r);
|
|
27
|
-
}
|
|
15
|
+
t() && (r === void 0 ? console.warn(`[formie:${e}] ${n}`) : console.warn(`[formie:${e}] ${n}`, r));
|
|
28
16
|
}
|
|
29
17
|
function a(e, t) {
|
|
30
18
|
let n = t ? `${e}:${t}` : e;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
//#region ../formie-core/dist/index.js
|
|
2
|
-
var e = Object.create, t = Object.defineProperty, n = Object.getOwnPropertyDescriptor, r = Object.getOwnPropertyNames, i = Object.getPrototypeOf, a = Object.prototype.hasOwnProperty, o = (e, t) => () => (t || (e((t = { exports: {} }).exports, t), e = null), t.exports), s = (e, i, o, s) => {
|
|
2
|
+
var e = Object.create, t = Object.defineProperty, n = Object.getOwnPropertyDescriptor, r = Object.getOwnPropertyNames, i = Object.getPrototypeOf, a = Object.prototype.hasOwnProperty, o = (e, t) => () => (t || (e((t = { exports: {} }).exports, t, t.exports), e = null), t.exports), s = (e, i, o, s) => {
|
|
3
3
|
if (i && typeof i == "object" || typeof i == "function") for (var c = r(i), l = 0, u = c.length, d; l < u; l++) d = c[l], !a.call(e, d) && d !== o && t(e, d, {
|
|
4
4
|
get: ((e) => i[e]).bind(null, d),
|
|
5
5
|
enumerable: !(s = n(i, d)) || s.enumerable
|
|
@@ -321,10 +321,10 @@ function C(e) {
|
|
|
321
321
|
n.add(e.key);
|
|
322
322
|
}
|
|
323
323
|
}
|
|
324
|
-
var w = /* @__PURE__ */ c((/* @__PURE__ */ o(((e, t) => {
|
|
324
|
+
var w = /* @__PURE__ */ c((/* @__PURE__ */ o(((e, t, n) => {
|
|
325
325
|
(function(n, r) {
|
|
326
326
|
typeof e == "object" && t !== void 0 ? r(e) : typeof define == "function" && define.amd ? define(["exports"], r) : r((n = typeof globalThis < "u" ? globalThis : n || self).ExpressionLanguage = {});
|
|
327
|
-
})(
|
|
327
|
+
})(n, function(e) {
|
|
328
328
|
function t(e, t, n) {
|
|
329
329
|
return (t = function(e) {
|
|
330
330
|
var t = function(e, t) {
|
|
@@ -335,7 +335,7 @@ var w = /* @__PURE__ */ c((/* @__PURE__ */ o(((e, t) => {
|
|
|
335
335
|
if (typeof r != "object") return r;
|
|
336
336
|
throw TypeError("@@toPrimitive must return a primitive value.");
|
|
337
337
|
}
|
|
338
|
-
return
|
|
338
|
+
return String(e);
|
|
339
339
|
}(e, "string");
|
|
340
340
|
return typeof t == "symbol" ? t : t + "";
|
|
341
341
|
}(t)) in e ? Object.defineProperty(e, t, {
|
|
@@ -3204,7 +3204,7 @@ var w = /* @__PURE__ */ c((/* @__PURE__ */ o(((e, t) => {
|
|
|
3204
3204
|
e in n || (n[e] = t[e]);
|
|
3205
3205
|
}), e.ExpressionLanguage = n;
|
|
3206
3206
|
}
|
|
3207
|
-
}(typeof globalThis < "u" ? globalThis : typeof self < "u" ? self :
|
|
3207
|
+
}(typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : n);
|
|
3208
3208
|
})))(), 1), T = null;
|
|
3209
3209
|
function E() {
|
|
3210
3210
|
let e = w, t = e.ExpressionLanguage || e.default || w;
|
|
@@ -3225,9 +3225,7 @@ function ne(e, t) {
|
|
|
3225
3225
|
if (Array.isArray(n)) {
|
|
3226
3226
|
let r = n.map((e) => typeof e == "string" && e.trim() !== "" && !Number.isNaN(Number(e)) ? Number(e) : e), i = r.filter((e) => typeof e == "number");
|
|
3227
3227
|
e[t] = i.length === r.length && r.length > 0 ? i.reduce((e, t) => e + Number(t || 0), 0) : r;
|
|
3228
|
-
|
|
3229
|
-
}
|
|
3230
|
-
typeof n == "string" && n.trim() !== "" && !Number.isNaN(Number(n)) && (e[t] = Number(n));
|
|
3228
|
+
} else typeof n == "string" && n.trim() !== "" && !Number.isNaN(Number(n)) && (e[t] = Number(n));
|
|
3231
3229
|
}), e;
|
|
3232
3230
|
}
|
|
3233
3231
|
function re(e, t) {
|
|
@@ -3238,6 +3236,13 @@ function re(e, t) {
|
|
|
3238
3236
|
return `${t.prefix || ""}${i}${t.suffix || ""}`;
|
|
3239
3237
|
}
|
|
3240
3238
|
function O(e, t) {
|
|
3239
|
+
if (e.numberFormat) {
|
|
3240
|
+
let { prefix: n = "", suffix: r = "" } = e.numberFormat, i = (e) => {
|
|
3241
|
+
let t = e;
|
|
3242
|
+
return n && t.startsWith(n) && (t = t.slice(n.length)), r && t.endsWith(r) && (t = t.slice(0, -r.length)), Number(t || 0);
|
|
3243
|
+
};
|
|
3244
|
+
return Array.isArray(t) ? t.map(i) : i(t);
|
|
3245
|
+
}
|
|
3241
3246
|
let n = e.type?.endsWith("\\Number");
|
|
3242
3247
|
return e.type?.endsWith("\\Checkboxes") ? Array.isArray(t) ? t.length ? t : "" : t ? [t] : "" : Array.isArray(t) ? t.length ? n ? t.map((e) => Number(e || 0)) : t : "" : n ? Number(t || 0) : t;
|
|
3243
3248
|
}
|