@wix/form-elements 1.93.0 → 1.95.0
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/component/{appointment-rac-bw0pvoxP.js → appointment-rac-mhQIjy3A.js} +310 -311
- package/dist/component/{bookings-address-rac-DECq7eWR.js → bookings-address-rac-pcZeAN2d.js} +1 -1
- package/dist/component/{bookings-email-rac-DTLjh6Zw.js → bookings-email-rac-BHdvWhcv.js} +1 -1
- package/dist/component/{bookings-first-name-rac-DObRe-Gq.js → bookings-first-name-rac-mPNuMBGo.js} +1 -1
- package/dist/component/{bookings-header-rac-DjpmYRJG.js → bookings-header-rac-CUzR91gM.js} +1 -1
- package/dist/component/{bookings-last-name-rac-Ds3o0ABM.js → bookings-last-name-rac-q2bsOPke.js} +1 -1
- package/dist/component/{bookings-login-bar-rac-DPUL2jWj.js → bookings-login-bar-rac-BpwVjQwz.js} +4 -4
- package/dist/component/{bookings-phone-rac-DIIHPxEP.js → bookings-phone-rac-DWdDpi-n.js} +1 -1
- package/dist/component/{bookings-rich-text-rac-BrcQO9xx.js → bookings-rich-text-rac-CZnGLPwv.js} +1 -1
- package/dist/component/{get-first-day-of-the-week-DvnsxYhQ.js → calendar.module-DnhTT4QT.js} +23 -18
- package/dist/component/{checkbox-field-rac-CD1MP1LT.js → checkbox-field-rac-DRVjITJ_.js} +7 -7
- package/dist/component/{checkbox-group-field-headless-C0V6zq0u.js → checkbox-group-field-headless-CKXgbUdv.js} +3 -3
- package/dist/component/{checkbox-group-field-rac-B-MYpz53.js → checkbox-group-field-rac-Dt3yWmua.js} +14 -14
- package/dist/component/{checkbox-group-rac-BejQjiO2.js → checkbox-group-rac-BTFoDjxn.js} +1 -1
- package/dist/component/{checkbox-indicator-module-classes-mJ7hl_8K.js → checkbox-indicator-module-classes-DhbNznSB.js} +1 -1
- package/dist/component/{checkbox-rac-B0YgCj29.js → checkbox-rac-Crn5HP7E.js} +1 -1
- package/dist/component/{contacts-address-rac-B1QNl3Lb.js → contacts-address-rac-c1zfBJgx.js} +1 -1
- package/dist/component/{contacts-birthdate-rac-Cp-gh3P-.js → contacts-birthdate-rac-BaaSPZgO.js} +1 -1
- package/dist/component/{contacts-company-rac-CSCU7JGm.js → contacts-company-rac-CzuRjr1D.js} +1 -1
- package/dist/component/{contacts-email-rac-B1Oov6-3.js → contacts-email-rac-hL98o3x4.js} +1 -1
- package/dist/component/{contacts-first-name-rac-rsHIOcjr.js → contacts-first-name-rac-BXTnd1aU.js} +1 -1
- package/dist/component/{contacts-last-name-rac-Csgq53Wm.js → contacts-last-name-rac-DYjmWO4_.js} +1 -1
- package/dist/component/{contacts-phone-rac-r9SwjDZ4.js → contacts-phone-rac-KMnorQhu.js} +1 -1
- package/dist/component/{contacts-position-rac-D7VcCM7v.js → contacts-position-rac-ylzvuGhD.js} +1 -1
- package/dist/component/{contacts-subscribe-rac-8Nu9ncZW.js → contacts-subscribe-rac-Bi3ZazuW.js} +2 -2
- package/dist/component/{contacts-tax-id-rac-CL_JSl_W.js → contacts-tax-id-rac-C01LkO1D.js} +1 -1
- package/dist/component/{date-availability-DLOKY9C4.js → date-availability-BXwnYCBt.js} +1 -1
- package/dist/component/{date-input-field-rac-D23Al-Mr.js → date-input-field-rac-BMdPQoFk.js} +58 -57
- package/dist/component/{date-input-rac-B6zgkw-L.js → date-input-rac-D2mDdJ_4.js} +1 -1
- package/dist/component/date-picker-field-rac-7gyRMkPp.js +317 -0
- package/dist/component/{date-picker-rac-C7g6aceb.js → date-picker-rac-FyNcNbTc.js} +1 -1
- package/dist/component/{date-time-input-field-rac-BENzf6gc.js → date-time-input-field-rac-BTjqn_g-.js} +54 -53
- package/dist/component/{date-time-input-rac-CVpK3mgw.js → date-time-input-rac-C81cN7rJ.js} +1 -1
- package/dist/component/{dext-checkbox-group-rac-CbEFDD3H.js → dext-checkbox-group-rac-DAjQPdi_.js} +2 -2
- package/dist/component/{dext-checkbox-rac-BdtZvn6I.js → dext-checkbox-rac-DVt9mAXM.js} +1 -1
- package/dist/component/{dext-date-picker-rac-BAhFvUEx.js → dext-date-picker-rac-BnaExh1i.js} +1 -1
- package/dist/component/{dext-date-time-input-rac-iXMKMwQY.js → dext-date-time-input-rac-DPAW4eBA.js} +1 -1
- package/dist/component/{dext-dropdown-rac-D-NPziZS.js → dext-dropdown-rac-P9T1vh24.js} +1 -1
- package/dist/component/{dext-email-rac-DYSwyB80.js → dext-email-rac-BfEuFGaV.js} +1 -1
- package/dist/component/{dext-number-input-rac-DXx8hgFg.js → dext-number-input-rac-B5eN2rLP.js} +1 -1
- package/dist/component/{dext-phone-rac-BtuLROzm.js → dext-phone-rac-DA-h_tpZ.js} +1 -1
- package/dist/component/{dext-radio-group-rac-MdKNiJ2i.js → dext-radio-group-rac-BjpkApRr.js} +2 -2
- package/dist/component/{dext-rating-input-rac-d998xond.js → dext-rating-input-rac-DUMRW9uI.js} +1 -1
- package/dist/component/{dext-tags-rac-DnSpOM9T.js → dext-tags-rac-s0WchM4X.js} +2 -2
- package/dist/component/{dext-text-area-rac-KqjeDDWe.js → dext-text-area-rac-BRMsiGEH.js} +1 -1
- package/dist/component/{dext-text-input-rac-CtCnClfX.js → dext-text-input-rac-BBZi3D8V.js} +1 -1
- package/dist/component/{dext-url-input-rac-DSJQcLLr.js → dext-url-input-rac-jKMWbCGB.js} +1 -1
- package/dist/component/{donation-rac-B_KGkBgo.js → donation-rac-DyeKbodo.js} +30 -30
- package/dist/component/{dropdown-field-headless-BUilB8wZ.js → dropdown-field-headless-BK8BN3u4.js} +4 -4
- package/dist/component/{dropdown-field-rac-COupYC1a.js → dropdown-field-rac-B6yzL_R0.js} +6 -6
- package/dist/component/{dropdown-rac-Dj0UZrE0.js → dropdown-rac-CQaMpex2.js} +1 -1
- package/dist/component/{ecom-address-rac-C0xnn86e.js → ecom-address-rac-DQr3-QeV.js} +1 -1
- package/dist/component/{ecom-subscription-checkbox-rac-D-ekxwUE.js → ecom-subscription-checkbox-rac-CZ-pj21A.js} +3 -3
- package/dist/component/{email-input-field-rac-DVj1qz_R.js → email-input-field-rac-Vp0YfQOe.js} +41 -41
- package/dist/component/{events-repeater-rac-U0aq9Z4Q.js → events-repeater-rac-BPE4Hn_G.js} +6 -6
- package/dist/component/{events-rsvp-rac-C7J58_5q.js → events-rsvp-rac-u_BDmDJ2.js} +21 -21
- package/dist/component/{field-error-headless-2nYJ2792.js → field-error-headless-BOlFtckJ.js} +1 -1
- package/dist/component/{field-label-headless-D97ACnmc.js → field-label-headless-Dx3VrM-U.js} +1 -1
- package/dist/component/field-rac.module-DobpyqOd.js +26 -0
- package/dist/component/{file-upload-rac-BR7QpuPW.js → file-upload-rac-DaFuvO-g.js} +44 -44
- package/dist/component/{fixed-payment-rac-COl18wW1.js → fixed-payment-rac-DpBwOtOf.js} +11 -11
- package/dist/component/{form-DKKTSAj1.js → form-Wsx4lguO.js} +69 -69
- package/dist/component/{form-element-classes-CLZXu-91.js → form-element-classes-BtKlobUX.js} +60 -59
- package/dist/component/form.css +1 -1
- package/dist/component/form.js +1 -1
- package/dist/component/{header-field-rac-B6DyMG3U.js → header-field-rac-C8FlksmH.js} +3 -3
- package/dist/component/{header-rac-x4H2qMky.js → header-rac-C2J-pLq-.js} +1 -1
- package/dist/component/{image-choice-rac-BVgmKTKk.js → image-choice-rac-i4C_OXyb.js} +16 -16
- package/dist/component/{index-C47UMGhd.js → index-C34urqyX.js} +4 -4
- package/dist/component/{index-DnpqBcg5.js → index-CRI82pG6.js} +2 -2
- package/dist/component/{isObjectLike-BrrFBP4f.js → isObjectLike-D-9JnXmU.js} +1 -1
- package/dist/component/{multiline-address-field-rac-B6ka-2Wy.js → multiline-address-field-rac-Dkfso46f.js} +87 -86
- package/dist/component/{multiline-address-rac-Bh58qUEe.js → multiline-address-rac-BjrwDwOk.js} +1 -1
- package/dist/component/{number-input-field-rac-pAmxvk3A.js → number-input-field-rac-CgHi83Q1.js} +19 -19
- package/dist/component/{number-input-rac-mKA2njIU.js → number-input-rac-BinBxOCS.js} +1 -1
- package/dist/component/{password-rac-BbD7PQXO.js → password-rac-CDGqIRW5.js} +38 -38
- package/dist/component/{payment-input-rac-UdkwC1ek.js → payment-input-rac-f4uuGeJF.js} +23 -23
- package/dist/component/{phone-input-field-rac-BVLVVDTq.js → phone-input-field-rac-IdBqjM9Q.js} +33 -32
- package/dist/component/{phone-rac-LixcB9WV.js → phone-rac-VHPMrSpw.js} +1 -1
- package/dist/component/{product-list-rac-B_dL1Ov-.js → product-list-rac-Bk8q5y5L.js} +17 -17
- package/dist/component/{quiz-radio-group-rac-Bj5XfqNf.js → quiz-radio-group-rac-kTWqvAoW.js} +2 -2
- package/dist/component/{radio-button-module-classes-y_PtsZPP.js → radio-button-module-classes-D77Nc48M.js} +3 -3
- package/dist/component/{radio-group-field-rac-C8OElNAQ.js → radio-group-field-rac-DC-AYSOH.js} +5 -5
- package/dist/component/{radio-group-rac-BqJFboHE.js → radio-group-rac-BkswH1Py.js} +1 -1
- package/dist/component/{rating-input-field-rac-C9_ITvEh.js → rating-input-field-rac-Cqgw6PjV.js} +32 -32
- package/dist/component/{rating-input-rac-CvTpEUoU.js → rating-input-rac-CbZhlK3h.js} +1 -1
- package/dist/component/{rich-content-rac.module-D4pEN-TY.js → rich-content-rac.module-j_9YbXMI.js} +1 -1
- package/dist/component/{rich-text-field-rac-B8cqCmaf.js → rich-text-field-rac-Da1EIb3b.js} +3 -3
- package/dist/component/{rich-text-rac-C1o-tfXG.js → rich-text-rac-BarNBtgP.js} +1 -1
- package/dist/component/{service-dropdown-rac-BOXqB2aq.js → service-dropdown-rac-DLIC_csj.js} +36 -36
- package/dist/component/{services-multi-choice-rac-Dk4rz-fw.js → services-multi-choice-rac-vyxtwSM2.js} +14 -14
- package/dist/component/{signature-rac-h9GWVdez.js → signature-rac-DIM2Uwsg.js} +102 -102
- package/dist/component/{submit-button-rac-qNaTyCxd.js → submit-button-rac-DgxjomCu.js} +2 -2
- package/dist/component/{tags-field-rac-NMRn0YnW.js → tags-field-rac-BFlkxifd.js} +67 -67
- package/dist/component/{tags-rac-DGx4KxEn.js → tags-rac-D4TwrAWc.js} +1 -1
- package/dist/component/{text-area-field-rac-C7u0D4l3.js → text-area-field-rac-Dcz7VUQ5.js} +28 -28
- package/dist/component/{text-area-rac-Yo-RIyLm.js → text-area-rac-DhloXdO2.js} +1 -1
- package/dist/component/{text-input-field-rac-CvU-1clq.js → text-input-field-rac-C8e3TMxI.js} +8 -8
- package/dist/component/{text-input-headless-DLRwVmwf.js → text-input-headless-fl7qoZzR.js} +3 -3
- package/dist/component/{text-input-rac-CWh5xjZA.js → text-input-rac-CBn6bHtP.js} +1 -1
- package/dist/component/{time-input-rac-BZlso9qK.js → time-input-rac-Dsm7_vrf.js} +26 -26
- package/dist/component/{url-input-field-rac-Bax0TB4Q.js → url-input-field-rac-9Hfx1xzO.js} +20 -20
- package/dist/component/{url-input-rac-Bw2nfybR.js → url-input-rac-CVlE4pcg.js} +1 -1
- package/dist/component/use-dropdown-option-class-name-Dsxto42_.js +21 -0
- package/dist/component/{use-element-state-class-name-C0zLrsDR.js → use-element-state-class-name-BIqDbVvI.js} +1 -1
- package/dist/component/use-is-forced-open-dropdown-BMPqRDVW.js +41 -0
- package/dist/component/{use-service-options-base-Bkj6BSQL.js → use-service-options-base-07_rqXcG.js} +1 -1
- package/dist/component/{use-text-input-class-name-Biu89Ma7.js → use-text-input-class-name-DqFt59gd.js} +4 -4
- package/package.json +2 -2
- package/dist/component/date-picker-field-rac-BqdzPPzK.js +0 -304
- package/dist/component/field-rac.module-BUvPquav.js +0 -26
- package/dist/component/use-dropdown-option-class-name-vKSagp3b.js +0 -57
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import a from "classnames";
|
|
2
|
+
import { s as o } from "./field-rac.module-DobpyqOd.js";
|
|
3
|
+
import { m as r } from "./form-element-classes-BtKlobUX.js";
|
|
4
|
+
import { u as l } from "./use-element-state-class-name-BIqDbVvI.js";
|
|
5
|
+
const m = {
|
|
6
|
+
base: o.selectOption,
|
|
7
|
+
selected: o.selectOptionSelected,
|
|
8
|
+
hover: o.selectOptionHover
|
|
9
|
+
}, O = ({ isSelected: e, isHovered: s, isFocused: t }) => ({
|
|
10
|
+
isSelected: e,
|
|
11
|
+
isHovered: (s || t) && !e
|
|
12
|
+
}), N = (...e) => {
|
|
13
|
+
const s = l({
|
|
14
|
+
globalClasses: r,
|
|
15
|
+
moduleClasses: m
|
|
16
|
+
});
|
|
17
|
+
return (t) => a(s(O(t)), e);
|
|
18
|
+
};
|
|
19
|
+
export {
|
|
20
|
+
N as u
|
|
21
|
+
};
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { useContext as T, useMemo as p } from "react";
|
|
2
|
+
import { ae as u, l as O, ac as _, F as n } from "./form-Wsx4lguO.js";
|
|
3
|
+
const a = [
|
|
4
|
+
n.DROPDOWN,
|
|
5
|
+
n.DEXT_DROPDOWN,
|
|
6
|
+
n.SERVICES_DROPDOWN,
|
|
7
|
+
n.DATE_INPUT,
|
|
8
|
+
n.CONTACTS_BIRTHDATE,
|
|
9
|
+
n.DATE_TIME_INPUT,
|
|
10
|
+
n.DEXT_DATE_TIME_INPUT,
|
|
11
|
+
n.DATE_PICKER,
|
|
12
|
+
n.DEXT_DATE_PICKER
|
|
13
|
+
], c = [
|
|
14
|
+
n.PHONE,
|
|
15
|
+
n.CONTACTS_PHONE,
|
|
16
|
+
n.BOOKINGS_PHONE,
|
|
17
|
+
n.DEXT_PHONE
|
|
18
|
+
], d = [
|
|
19
|
+
n.MULTILINE_ADDRESS,
|
|
20
|
+
n.BOOKINGS_ADDRESS,
|
|
21
|
+
n.ECOM_ADDRESS
|
|
22
|
+
], l = ({ properties: o }) => {
|
|
23
|
+
var t, e, s, r;
|
|
24
|
+
return ((r = (s = (e = (t = o.validation) == null ? void 0 : t.string) == null ? void 0 : e.phoneOptions) == null ? void 0 : s.allowedCountryCodes) == null ? void 0 : r.length) !== 1;
|
|
25
|
+
}, I = ({ properties: o }) => {
|
|
26
|
+
var t, e;
|
|
27
|
+
return ((e = (t = o.fieldSettings) == null ? void 0 : t.country) == null ? void 0 : e.show) !== !1;
|
|
28
|
+
}, P = (o, t) => c.includes(o.fieldType) ? !t && l(o) : d.includes(o.fieldType) ? I(o) : a.includes(o.fieldType), S = (o, t) => P(o, t) && !o.properties.hidden && !o.properties.disabled && !o.properties.readOnly, N = (o, t) => o.layout.row - t.layout.row || o.layout.column - t.layout.column, w = (o) => {
|
|
29
|
+
var E;
|
|
30
|
+
const t = ((E = u().dropdown) == null ? void 0 : E.open) === !0, e = T(O), { isMobile: s = !1 } = _(), r = p(() => {
|
|
31
|
+
var D;
|
|
32
|
+
return e && !e.parentId ? (D = e.fields.filter((i) => S(i, s)).sort(N)[0]) == null ? void 0 : D.id : void 0;
|
|
33
|
+
}, [
|
|
34
|
+
e,
|
|
35
|
+
s
|
|
36
|
+
]);
|
|
37
|
+
return t && r === o;
|
|
38
|
+
};
|
|
39
|
+
export {
|
|
40
|
+
w as u
|
|
41
|
+
};
|
package/dist/component/{use-service-options-base-Bkj6BSQL.js → use-service-options-base-07_rqXcG.js}
RENAMED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { useState as o, useCallback as D, useEffect as m, useMemo as b } from "react";
|
|
2
|
-
import { aj as v } from "./form-
|
|
2
|
+
import { aj as v } from "./form-Wsx4lguO.js";
|
|
3
3
|
const j = (I) => {
|
|
4
4
|
const { fieldType: L, isEditor: t = !1, postProcessOptions: i, customFetchLogic: a, onInitialDataLoaded: n } = I, [O, h] = o(!1), [g, p] = o([]), [E, u] = o(!1), [c, f] = o(!1), s = v(L), r = D((e) => {
|
|
5
5
|
let d = e.map((l) => ({
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { ak as l } from "./form-
|
|
2
|
-
import { s } from "./field-rac.module-
|
|
3
|
-
import {
|
|
4
|
-
import { u as i } from "./use-element-state-class-name-
|
|
1
|
+
import { ak as l } from "./form-Wsx4lguO.js";
|
|
2
|
+
import { s } from "./field-rac.module-DobpyqOd.js";
|
|
3
|
+
import { a1 as m } from "./form-element-classes-BtKlobUX.js";
|
|
4
|
+
import { u as i } from "./use-element-state-class-name-BIqDbVvI.js";
|
|
5
5
|
const c = (...e) => {
|
|
6
6
|
const { disabled: a, readOnly: t } = l(), o = i({
|
|
7
7
|
globalClasses: m,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wix/form-elements",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.95.0",
|
|
4
4
|
"description": "The Wix Forms rendering element for Builder apps, loaded at runtime as @wix/form-elements/Form",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"files": [
|
|
@@ -155,5 +155,5 @@
|
|
|
155
155
|
]
|
|
156
156
|
}
|
|
157
157
|
},
|
|
158
|
-
"falconPackageHash": "
|
|
158
|
+
"falconPackageHash": "e28c46e74662494bbde43b9631a814dd26691b3df5376ffc2659f6ce"
|
|
159
159
|
}
|
|
@@ -1,304 +0,0 @@
|
|
|
1
|
-
import { RicosViewer as G } from "@wix/ricos/viewer";
|
|
2
|
-
import y from "classnames";
|
|
3
|
-
import e, { useState as z, useCallback as F, useContext as Q, useRef as L, useMemo as _ } from "react";
|
|
4
|
-
import { D, ak as v, ah as A, ac as S, am as Z } from "./form-DKKTSAj1.js";
|
|
5
|
-
import { parseDate as J } from "@internationalized/date";
|
|
6
|
-
import { UNSAFE_PortalProvider as X } from "react-aria";
|
|
7
|
-
import { I18nProvider as ee, DatePicker as te, DatePickerStateContext as re, Group as ae, DateInput as ne, DateSegment as oe, Dialog as le, Calendar as se, CalendarMonthPicker as ce, CalendarYearPicker as ie, CalendarGrid as me, CalendarCell as ue, Button as R, Select as O, SelectValue as x, ListBox as k, ListBoxItem as M } from "react-aria-components";
|
|
8
|
-
import { g as de } from "./get-first-day-of-the-week-DvnsxYhQ.js";
|
|
9
|
-
import { f as E, a as b } from "./find-child-C60k4CxG.js";
|
|
10
|
-
import { D as ge, E as Ee } from "./field-error-headless-2nYJ2792.js";
|
|
11
|
-
import { L as pe } from "./field-label-headless-D97ACnmc.js";
|
|
12
|
-
import { D as De, N as I, S as w } from "./non-modal-popover-DtIMXHbe.js";
|
|
13
|
-
import { i as fe } from "./date-availability-DLOKY9C4.js";
|
|
14
|
-
import { C as N } from "./chevron-down-icon-CcpVm6B-.js";
|
|
15
|
-
import { E as Ce } from "./error-icon-hZxQ6DEy.js";
|
|
16
|
-
import { s as p } from "./field-rac.module-BUvPquav.js";
|
|
17
|
-
import { B as ye, R as he, z as ve, D as Se, q as Te, i as be } from "./form-element-classes-CLZXu-91.js";
|
|
18
|
-
const _e = [
|
|
19
|
-
D.SUNDAY,
|
|
20
|
-
D.MONDAY,
|
|
21
|
-
D.TUESDAY,
|
|
22
|
-
D.WEDNESDAY,
|
|
23
|
-
D.THURSDAY,
|
|
24
|
-
D.FRIDAY,
|
|
25
|
-
D.SATURDAY
|
|
26
|
-
], Ne = {
|
|
27
|
-
availableDays: _e
|
|
28
|
-
}, a = ({ children: t }) => {
|
|
29
|
-
const { id: r, value: n, onChange: l, disabled: i, required: c, onBlur: d, onFocus: o, FieldLayout: m, hasError: u, readOnly: f } = v(), { labelId: C } = A(), { regionalFormat: s } = S(), [T, Y] = z(null), B = F((H) => {
|
|
30
|
-
const j = Me(H);
|
|
31
|
-
l(j);
|
|
32
|
-
}, [
|
|
33
|
-
l
|
|
34
|
-
]), q = E(t, a.Label), V = E(t, a.Control), U = E(t, a.Calendar), W = E(t, a.Description), K = E(t, a.Error), $ = ke(n);
|
|
35
|
-
return /* @__PURE__ */ e.createElement(m, {
|
|
36
|
-
fieldId: r,
|
|
37
|
-
renderLabel: () => q,
|
|
38
|
-
renderInput: () => /* @__PURE__ */ e.createElement(ee, {
|
|
39
|
-
locale: s
|
|
40
|
-
}, /* @__PURE__ */ e.createElement("div", {
|
|
41
|
-
ref: Y,
|
|
42
|
-
style: {
|
|
43
|
-
display: "contents"
|
|
44
|
-
}
|
|
45
|
-
}), /* @__PURE__ */ e.createElement(X, {
|
|
46
|
-
getContainer: () => T
|
|
47
|
-
}, /* @__PURE__ */ e.createElement(te, {
|
|
48
|
-
"aria-labelledby": C,
|
|
49
|
-
value: $,
|
|
50
|
-
onChange: B,
|
|
51
|
-
isDisabled: i,
|
|
52
|
-
isInvalid: u,
|
|
53
|
-
isReadOnly: f,
|
|
54
|
-
isRequired: c,
|
|
55
|
-
onBlur: d,
|
|
56
|
-
onFocus: o
|
|
57
|
-
}, V, U))),
|
|
58
|
-
renderDescription: () => /* @__PURE__ */ e.createElement(e.Fragment, null, K, W)
|
|
59
|
-
});
|
|
60
|
-
}, Ie = ({ children: t, className: r }) => {
|
|
61
|
-
const { inputId: n, ariaDescribedBy: l } = A(), { hasError: i, disabled: c, readOnly: d } = v(), o = Q(re), m = F((u) => {
|
|
62
|
-
if (!o || o.isOpen || c || d)
|
|
63
|
-
return;
|
|
64
|
-
const f = u.target;
|
|
65
|
-
if (f.closest("button"))
|
|
66
|
-
return;
|
|
67
|
-
const C = f.closest("[data-type]");
|
|
68
|
-
C && C.getAttribute("data-type") !== "literal" || o.setOpen(!0);
|
|
69
|
-
}, [
|
|
70
|
-
o,
|
|
71
|
-
c,
|
|
72
|
-
d
|
|
73
|
-
]);
|
|
74
|
-
return /* @__PURE__ */ e.createElement(ae, {
|
|
75
|
-
id: n,
|
|
76
|
-
"aria-describedby": l,
|
|
77
|
-
className: r,
|
|
78
|
-
"data-invalid": i,
|
|
79
|
-
onPointerDownCapture: m
|
|
80
|
-
}, t);
|
|
81
|
-
}, Le = ({ className: t }) => {
|
|
82
|
-
const { id: r, placeholder: n } = v(), { regionalFormat: l } = S(), i = L(null), c = L(!1);
|
|
83
|
-
Z(() => {
|
|
84
|
-
var o;
|
|
85
|
-
(o = i.current) == null || o.focus();
|
|
86
|
-
}, r);
|
|
87
|
-
const d = _(() => we(l), [
|
|
88
|
-
l
|
|
89
|
-
]);
|
|
90
|
-
return /* @__PURE__ */ e.createElement(ne, {
|
|
91
|
-
className: t
|
|
92
|
-
}, (o) => {
|
|
93
|
-
const m = o.type === d && o.isPlaceholder && !!n;
|
|
94
|
-
return /* @__PURE__ */ e.createElement(oe, {
|
|
95
|
-
segment: o,
|
|
96
|
-
"data-first-segment": m || void 0,
|
|
97
|
-
ref: (u) => {
|
|
98
|
-
if (!u && c.current) {
|
|
99
|
-
i.current = null, c.current = !1;
|
|
100
|
-
return;
|
|
101
|
-
}
|
|
102
|
-
if (u && !c.current) {
|
|
103
|
-
i.current = u, c.current = !0;
|
|
104
|
-
return;
|
|
105
|
-
}
|
|
106
|
-
}
|
|
107
|
-
}, (u) => !u.isPlaceholder || !n ? u.text : m ? n : u.text);
|
|
108
|
-
});
|
|
109
|
-
}, Pe = ({ children: t, className: r }) => /* @__PURE__ */ e.createElement(De, {
|
|
110
|
-
className: r
|
|
111
|
-
}, t), g = ({ children: t, className: r }) => {
|
|
112
|
-
const { regionalFormat: n, isMobile: l } = S(), { availability: i } = v(), c = _(() => de(n), [
|
|
113
|
-
n
|
|
114
|
-
]), d = _(() => (s) => {
|
|
115
|
-
const T = new Date(s.year, s.month - 1, s.day);
|
|
116
|
-
return !fe(T, i || Ne);
|
|
117
|
-
}, [
|
|
118
|
-
i
|
|
119
|
-
]), o = E(t, g.Day) ?? /* @__PURE__ */ e.createElement(g.Day, null), m = E(t, g.PreviousTrigger), u = E(t, g.NextTrigger), f = E(t, g.MonthTrigger), C = E(t, g.YearTrigger);
|
|
120
|
-
return /* @__PURE__ */ e.createElement(I, {
|
|
121
|
-
className: r,
|
|
122
|
-
containerPadding: 0
|
|
123
|
-
}, /* @__PURE__ */ e.createElement(le, null, /* @__PURE__ */ e.createElement(se, {
|
|
124
|
-
firstDayOfWeek: Ye(c),
|
|
125
|
-
isDateUnavailable: d
|
|
126
|
-
}, /* @__PURE__ */ e.createElement("header", null, m, /* @__PURE__ */ e.createElement(ce, null, (s) => b(f, {
|
|
127
|
-
ariaLabel: s["aria-label"],
|
|
128
|
-
selectedKey: s.value,
|
|
129
|
-
onSelectionChange: s.onChange,
|
|
130
|
-
items: s.items,
|
|
131
|
-
popoverClassName: r
|
|
132
|
-
})), /* @__PURE__ */ e.createElement(ie, {
|
|
133
|
-
visibleYears: 100
|
|
134
|
-
}, (s) => b(C, {
|
|
135
|
-
ariaLabel: s["aria-label"],
|
|
136
|
-
selectedKey: s.value,
|
|
137
|
-
onSelectionChange: s.onChange,
|
|
138
|
-
items: s.items,
|
|
139
|
-
popoverClassName: r
|
|
140
|
-
})), u), /* @__PURE__ */ e.createElement(me, {
|
|
141
|
-
weekdayStyle: l ? "narrow" : "short"
|
|
142
|
-
}, (s) => b(o, {
|
|
143
|
-
date: s
|
|
144
|
-
})))));
|
|
145
|
-
}, Fe = ({ className: t, ...r }) => {
|
|
146
|
-
const { date: n } = r;
|
|
147
|
-
return /* @__PURE__ */ e.createElement(ue, {
|
|
148
|
-
className: t,
|
|
149
|
-
date: n
|
|
150
|
-
});
|
|
151
|
-
}, Ae = ({ children: t, className: r }) => /* @__PURE__ */ e.createElement(R, {
|
|
152
|
-
slot: "previous",
|
|
153
|
-
className: r
|
|
154
|
-
}, t), Re = ({ children: t, className: r }) => /* @__PURE__ */ e.createElement(R, {
|
|
155
|
-
slot: "next",
|
|
156
|
-
className: r
|
|
157
|
-
}, t), Oe = ({ children: t, className: r, ...n }) => {
|
|
158
|
-
const { ariaLabel: l, selectedKey: i, onSelectionChange: c, items: d, popoverClassName: o } = n;
|
|
159
|
-
return /* @__PURE__ */ e.createElement(O, {
|
|
160
|
-
"aria-label": l,
|
|
161
|
-
selectedKey: i,
|
|
162
|
-
onSelectionChange: c
|
|
163
|
-
}, /* @__PURE__ */ e.createElement(w, {
|
|
164
|
-
className: r
|
|
165
|
-
}, /* @__PURE__ */ e.createElement(x, null), t), /* @__PURE__ */ e.createElement(I, {
|
|
166
|
-
className: o,
|
|
167
|
-
containerPadding: 0
|
|
168
|
-
}, /* @__PURE__ */ e.createElement(k, {
|
|
169
|
-
items: d
|
|
170
|
-
}, (m) => /* @__PURE__ */ e.createElement(M, {
|
|
171
|
-
id: m.id
|
|
172
|
-
}, m.formatted))));
|
|
173
|
-
}, xe = ({ children: t, className: r, ...n }) => {
|
|
174
|
-
const { ariaLabel: l, selectedKey: i, onSelectionChange: c, items: d, popoverClassName: o } = n;
|
|
175
|
-
return /* @__PURE__ */ e.createElement(O, {
|
|
176
|
-
"aria-label": l,
|
|
177
|
-
selectedKey: i,
|
|
178
|
-
onSelectionChange: c
|
|
179
|
-
}, /* @__PURE__ */ e.createElement(w, {
|
|
180
|
-
className: r
|
|
181
|
-
}, /* @__PURE__ */ e.createElement(x, null), t), /* @__PURE__ */ e.createElement(I, {
|
|
182
|
-
className: o,
|
|
183
|
-
containerPadding: 0
|
|
184
|
-
}, /* @__PURE__ */ e.createElement(k, {
|
|
185
|
-
items: d
|
|
186
|
-
}, (m) => /* @__PURE__ */ e.createElement(M, {
|
|
187
|
-
id: m.id
|
|
188
|
-
}, m.formatted))));
|
|
189
|
-
};
|
|
190
|
-
g.Day = Fe;
|
|
191
|
-
g.PreviousTrigger = Ae;
|
|
192
|
-
g.NextTrigger = Re;
|
|
193
|
-
g.MonthTrigger = Oe;
|
|
194
|
-
g.YearTrigger = xe;
|
|
195
|
-
a.Label = pe;
|
|
196
|
-
a.Control = Ie;
|
|
197
|
-
a.Input = Le;
|
|
198
|
-
a.Trigger = Pe;
|
|
199
|
-
a.Calendar = g;
|
|
200
|
-
a.Description = ge;
|
|
201
|
-
a.Error = Ee;
|
|
202
|
-
function ke(t) {
|
|
203
|
-
if (!t)
|
|
204
|
-
return null;
|
|
205
|
-
try {
|
|
206
|
-
return J(t);
|
|
207
|
-
} catch {
|
|
208
|
-
return null;
|
|
209
|
-
}
|
|
210
|
-
}
|
|
211
|
-
function Me(t) {
|
|
212
|
-
if (!t)
|
|
213
|
-
return null;
|
|
214
|
-
const r = String(t.year).padStart(4, "0"), n = String(t.month).padStart(2, "0"), l = String(t.day).padStart(2, "0");
|
|
215
|
-
return `${r}-${n}-${l}`;
|
|
216
|
-
}
|
|
217
|
-
function we(t) {
|
|
218
|
-
var r;
|
|
219
|
-
try {
|
|
220
|
-
return ((r = new Intl.DateTimeFormat(t, {
|
|
221
|
-
year: "numeric",
|
|
222
|
-
month: "2-digit",
|
|
223
|
-
day: "2-digit"
|
|
224
|
-
}).formatToParts(/* @__PURE__ */ new Date()).find((l) => l.type !== "literal")) == null ? void 0 : r.type) ?? "month";
|
|
225
|
-
} catch {
|
|
226
|
-
return "month";
|
|
227
|
-
}
|
|
228
|
-
}
|
|
229
|
-
function Ye(t) {
|
|
230
|
-
return [
|
|
231
|
-
"sun",
|
|
232
|
-
"mon",
|
|
233
|
-
"tue",
|
|
234
|
-
"wed",
|
|
235
|
-
"thu",
|
|
236
|
-
"fri",
|
|
237
|
-
"sat"
|
|
238
|
-
][t] || "mon";
|
|
239
|
-
}
|
|
240
|
-
const Be = (t) => /* @__PURE__ */ e.createElement("svg", {
|
|
241
|
-
viewBox: "0 0 24 24",
|
|
242
|
-
fill: "none",
|
|
243
|
-
width: 14,
|
|
244
|
-
height: 14,
|
|
245
|
-
"aria-hidden": "true",
|
|
246
|
-
...t
|
|
247
|
-
}, /* @__PURE__ */ e.createElement("path", {
|
|
248
|
-
d: "M7 2v2M17 2v2M3 8h18M5 4h14a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2Z",
|
|
249
|
-
stroke: "currentColor",
|
|
250
|
-
strokeWidth: "1.5",
|
|
251
|
-
strokeLinecap: "round",
|
|
252
|
-
strokeLinejoin: "round"
|
|
253
|
-
})), qe = "_control_1xqv5_1", Ve = "_segments_1xqv5_14", Ue = "_trigger_1xqv5_65", We = "_calendarPopover_1xqv5_96", Ke = "_calendarDay_1xqv5_219", $e = "_mobile_1xqv5_262", h = {
|
|
254
|
-
control: qe,
|
|
255
|
-
segments: Ve,
|
|
256
|
-
trigger: Ue,
|
|
257
|
-
calendarPopover: We,
|
|
258
|
-
calendarDay: Ke,
|
|
259
|
-
mobile: $e
|
|
260
|
-
}, He = ({ content: t, locale: r }) => /* @__PURE__ */ e.createElement(G, {
|
|
261
|
-
content: t,
|
|
262
|
-
locale: r
|
|
263
|
-
}), je = {
|
|
264
|
-
left: 90,
|
|
265
|
-
right: -90
|
|
266
|
-
}, P = ({ direction: t }) => /* @__PURE__ */ e.createElement(N, {
|
|
267
|
-
style: {
|
|
268
|
-
transform: `rotate(${je[t]}deg)`
|
|
269
|
-
}
|
|
270
|
-
}), ut = () => {
|
|
271
|
-
const { isMobile: t } = S();
|
|
272
|
-
return /* @__PURE__ */ e.createElement(a, null, /* @__PURE__ */ e.createElement(a.Label, {
|
|
273
|
-
className: y(ye, p.label)
|
|
274
|
-
}, /* @__PURE__ */ e.createElement(a.Label.Required, {
|
|
275
|
-
className: y(he, p.requiredMark)
|
|
276
|
-
})), /* @__PURE__ */ e.createElement(a.Control, {
|
|
277
|
-
className: y(ve, p.input, h.control)
|
|
278
|
-
}, /* @__PURE__ */ e.createElement(a.Trigger, {
|
|
279
|
-
className: h.trigger
|
|
280
|
-
}, /* @__PURE__ */ e.createElement(Be, null)), /* @__PURE__ */ e.createElement(a.Input, {
|
|
281
|
-
className: h.segments
|
|
282
|
-
})), /* @__PURE__ */ e.createElement(a.Calendar, {
|
|
283
|
-
className: y(Se, p.selectPopover, h.calendarPopover, {
|
|
284
|
-
[h.mobile]: t
|
|
285
|
-
})
|
|
286
|
-
}, /* @__PURE__ */ e.createElement(a.Calendar.PreviousTrigger, null, /* @__PURE__ */ e.createElement(P, {
|
|
287
|
-
direction: "left"
|
|
288
|
-
})), /* @__PURE__ */ e.createElement(a.Calendar.MonthTrigger, null, /* @__PURE__ */ e.createElement(N, {
|
|
289
|
-
className: p.dropdownIcon
|
|
290
|
-
})), /* @__PURE__ */ e.createElement(a.Calendar.YearTrigger, null, /* @__PURE__ */ e.createElement(N, {
|
|
291
|
-
className: p.dropdownIcon
|
|
292
|
-
})), /* @__PURE__ */ e.createElement(a.Calendar.NextTrigger, null, /* @__PURE__ */ e.createElement(P, {
|
|
293
|
-
direction: "right"
|
|
294
|
-
})), /* @__PURE__ */ e.createElement(a.Calendar.Day, {
|
|
295
|
-
className: h.calendarDay
|
|
296
|
-
})), /* @__PURE__ */ e.createElement(a.Error, {
|
|
297
|
-
className: y(Te, p.error)
|
|
298
|
-
}, /* @__PURE__ */ e.createElement(Ce, null), /* @__PURE__ */ e.createElement(a.Error.Text, null)), /* @__PURE__ */ e.createElement(a.Description, {
|
|
299
|
-
className: y(be, p.description)
|
|
300
|
-
}, He));
|
|
301
|
-
};
|
|
302
|
-
export {
|
|
303
|
-
ut as D
|
|
304
|
-
};
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
const o = "_label_1o0o9_1", e = "_requiredMark_1o0o9_11", t = "_input_1o0o9_16", n = "_inputGroup_1o0o9_17", c = "_inputHover_1o0o9_69", _ = "_innerInput_1o0o9_130", r = "_dropdownTrigger_1o0o9_178", p = "_dropdownIcon_1o0o9_188", s = "_dropdownPopover_1o0o9_207", i = "_selectPopover_1o0o9_213", u = "_selectOption_1o0o9_240", d = "_selectOptionHover_1o0o9_263", l = "_selectOptionSelected_1o0o9_267", h = "_selectOptionWithoutFocusRing_1o0o9_271", b = "_description_1o0o9_277", k = "_error_1o0o9_293", v = "_checkbox_1o0o9_312", I = "_checkboxInput_1o0o9_335", x = "_checkboxInputSelected_1o0o9_374", O = "_checkboxInputHover_1o0o9_378", a = "_uploadButton_1o0o9_425", g = {
|
|
2
|
-
label: o,
|
|
3
|
-
requiredMark: e,
|
|
4
|
-
input: t,
|
|
5
|
-
inputGroup: n,
|
|
6
|
-
inputHover: c,
|
|
7
|
-
innerInput: _,
|
|
8
|
-
dropdownTrigger: r,
|
|
9
|
-
dropdownIcon: p,
|
|
10
|
-
dropdownPopover: s,
|
|
11
|
-
selectPopover: i,
|
|
12
|
-
selectOption: u,
|
|
13
|
-
selectOptionHover: d,
|
|
14
|
-
selectOptionSelected: l,
|
|
15
|
-
selectOptionWithoutFocusRing: h,
|
|
16
|
-
description: b,
|
|
17
|
-
error: k,
|
|
18
|
-
checkbox: v,
|
|
19
|
-
checkboxInput: I,
|
|
20
|
-
checkboxInputSelected: x,
|
|
21
|
-
checkboxInputHover: O,
|
|
22
|
-
uploadButton: a
|
|
23
|
-
};
|
|
24
|
-
export {
|
|
25
|
-
g as s
|
|
26
|
-
};
|
|
@@ -1,57 +0,0 @@
|
|
|
1
|
-
import { useContext as l, useMemo as p } from "react";
|
|
2
|
-
import { ae as E, l as u, ac as c, F as t } from "./form-DKKTSAj1.js";
|
|
3
|
-
import _ from "classnames";
|
|
4
|
-
import { s as a } from "./field-rac.module-BUvPquav.js";
|
|
5
|
-
import { l as S } from "./form-element-classes-CLZXu-91.js";
|
|
6
|
-
import { u as T } from "./use-element-state-class-name-C0zLrsDR.js";
|
|
7
|
-
const d = [
|
|
8
|
-
t.DROPDOWN,
|
|
9
|
-
t.DEXT_DROPDOWN,
|
|
10
|
-
t.SERVICES_DROPDOWN,
|
|
11
|
-
t.DATE_INPUT,
|
|
12
|
-
t.CONTACTS_BIRTHDATE,
|
|
13
|
-
t.DATE_TIME_INPUT,
|
|
14
|
-
t.DEXT_DATE_TIME_INPUT
|
|
15
|
-
], N = [
|
|
16
|
-
t.PHONE,
|
|
17
|
-
t.CONTACTS_PHONE,
|
|
18
|
-
t.BOOKINGS_PHONE,
|
|
19
|
-
t.DEXT_PHONE
|
|
20
|
-
], m = [
|
|
21
|
-
t.MULTILINE_ADDRESS,
|
|
22
|
-
t.BOOKINGS_ADDRESS,
|
|
23
|
-
t.ECOM_ADDRESS
|
|
24
|
-
], P = ({ properties: o }) => {
|
|
25
|
-
var e, s, n, r;
|
|
26
|
-
return ((r = (n = (s = (e = o.validation) == null ? void 0 : e.string) == null ? void 0 : s.phoneOptions) == null ? void 0 : n.allowedCountryCodes) == null ? void 0 : r.length) !== 1;
|
|
27
|
-
}, I = ({ properties: o }) => {
|
|
28
|
-
var e, s;
|
|
29
|
-
return ((s = (e = o.fieldSettings) == null ? void 0 : e.country) == null ? void 0 : s.show) !== !1;
|
|
30
|
-
}, C = (o, e) => N.includes(o.fieldType) ? !e && P(o) : m.includes(o.fieldType) ? I(o) : d.includes(o.fieldType), y = (o, e) => C(o, e) && !o.properties.hidden && !o.properties.disabled && !o.properties.readOnly, w = (o, e) => o.layout.row - e.layout.row || o.layout.column - e.layout.column, b = (o) => {
|
|
31
|
-
var O;
|
|
32
|
-
const e = ((O = E().dropdown) == null ? void 0 : O.open) === !0, s = l(u), { isMobile: n = !1 } = c(), r = p(() => {
|
|
33
|
-
var D;
|
|
34
|
-
return s && !s.parentId ? (D = s.fields.filter((i) => y(i, n)).sort(w)[0]) == null ? void 0 : D.id : void 0;
|
|
35
|
-
}, [
|
|
36
|
-
s,
|
|
37
|
-
n
|
|
38
|
-
]);
|
|
39
|
-
return e && r === o;
|
|
40
|
-
}, R = {
|
|
41
|
-
base: a.selectOption,
|
|
42
|
-
selected: a.selectOptionSelected,
|
|
43
|
-
hover: a.selectOptionHover
|
|
44
|
-
}, f = ({ isSelected: o, isHovered: e, isFocused: s }) => ({
|
|
45
|
-
isSelected: o,
|
|
46
|
-
isHovered: (e || s) && !o
|
|
47
|
-
}), g = (...o) => {
|
|
48
|
-
const e = T({
|
|
49
|
-
globalClasses: S,
|
|
50
|
-
moduleClasses: R
|
|
51
|
-
});
|
|
52
|
-
return (s) => _(e(f(s)), o);
|
|
53
|
-
};
|
|
54
|
-
export {
|
|
55
|
-
b as a,
|
|
56
|
-
g as u
|
|
57
|
-
};
|