@wix/form-elements 1.224.0 → 1.226.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-UcRjJTHp.js → appointment-rac-C2ClvRys.js} +5 -5
- package/dist/component/{bookings-address-rac-DDjZGEhk.js → bookings-address-rac-CPQjosbZ.js} +1 -1
- package/dist/component/{bookings-email-rac-Dy2vh3dy.js → bookings-email-rac-DWvVUcBN.js} +1 -1
- package/dist/component/{bookings-first-name-rac-fDHMNznn.js → bookings-first-name-rac-_iG2xJiA.js} +1 -1
- package/dist/component/{bookings-header-rac-DLOeNNQf.js → bookings-header-rac-BbGm_Z8W.js} +1 -1
- package/dist/component/{bookings-last-name-rac-Bx19ROVT.js → bookings-last-name-rac-77Z29aHO.js} +1 -1
- package/dist/component/{bookings-login-bar-rac-8FbvPiv1.js → bookings-login-bar-rac-DfqRpARE.js} +1 -1
- package/dist/component/{bookings-phone-rac-CvPQgtvq.js → bookings-phone-rac-BKoU7X0X.js} +1 -1
- package/dist/component/{bookings-rich-text-rac-CO8bHRpD.js → bookings-rich-text-rac-DgSN4_f0.js} +1 -1
- package/dist/component/calendar-icon-DOeHn3jt.js +19 -0
- package/dist/component/{checkbox-field-rac-tzsGw10P.js → checkbox-field-rac-BLJ3Xb7C.js} +6 -6
- package/dist/component/{checkbox-group-field-headless-CL18dpkq.js → checkbox-group-field-headless-BeU8DG0A.js} +3 -3
- package/dist/component/{checkbox-group-field-rac-BmbxaprJ.js → checkbox-group-field-rac-ClRi6Ljp.js} +6 -6
- package/dist/component/{checkbox-group-rac-shsbUvRc.js → checkbox-group-rac--cM57qqw.js} +1 -1
- package/dist/component/{checkbox-indicator-module-classes-DOxE4UQg.js → checkbox-indicator-module-classes-Cozvs_kk.js} +1 -1
- package/dist/component/{checkbox-rac-CobYYayd.js → checkbox-rac-DnslW6as.js} +1 -1
- package/dist/component/{contacts-address-rac-BoDqJCi1.js → contacts-address-rac-Bpq_0vvi.js} +1 -1
- package/dist/component/{contacts-birthdate-rac-GAujbm-z.js → contacts-birthdate-rac-CB1h6kRm.js} +1 -1
- package/dist/component/{contacts-company-rac-CLcEz04V.js → contacts-company-rac-DvYX4SLX.js} +1 -1
- package/dist/component/{contacts-email-rac-D9q7TJwy.js → contacts-email-rac-sxbgKBUR.js} +1 -1
- package/dist/component/{contacts-first-name-rac-BAecbeNQ.js → contacts-first-name-rac-C4_o2nwv.js} +1 -1
- package/dist/component/{contacts-last-name-rac-Ccrw8BDa.js → contacts-last-name-rac-B3s96wWt.js} +1 -1
- package/dist/component/{contacts-phone-rac-DA2N033V.js → contacts-phone-rac-B5NZeYaI.js} +1 -1
- package/dist/component/{contacts-position-rac-0lAd-nCW.js → contacts-position-rac-CO4Bo4jG.js} +1 -1
- package/dist/component/{contacts-subscribe-rac-DB2ssF-E.js → contacts-subscribe-rac-CWmo3C6c.js} +1 -1
- package/dist/component/{contacts-tax-id-rac-B-Sn92Ho.js → contacts-tax-id-rac-pi_bJeA7.js} +1 -1
- package/dist/component/{date-availability-CtfWLvii.js → date-availability-DL8Xboob.js} +1 -1
- package/dist/component/date-input-field-rac-Di2pwVW7.js +365 -0
- package/dist/component/{date-input-rac-BnWwBe2i.js → date-input-rac-C5xC7fbz.js} +1 -1
- package/dist/component/date-picker-field-rac-DyPkuVVe.js +386 -0
- package/dist/component/{date-picker-rac-BhI6jOQE.js → date-picker-rac-CKNlOGZG.js} +1 -1
- package/dist/component/date-time-input-field-rac-Dk15pWyb.js +507 -0
- package/dist/component/{date-time-input-rac-DAbopLQt.js → date-time-input-rac-oOUelldq.js} +1 -1
- package/dist/component/{dext-checkbox-group-rac-D_HLv0tP.js → dext-checkbox-group-rac--jmNDOV2.js} +2 -2
- package/dist/component/{dext-checkbox-rac-BnBTlqEI.js → dext-checkbox-rac-BOjbBRrg.js} +1 -1
- package/dist/component/{dext-date-picker-rac-Co_yfhuz.js → dext-date-picker-rac-CHi5TisB.js} +1 -1
- package/dist/component/{dext-date-time-input-rac-BSpUehb2.js → dext-date-time-input-rac-CcF4ocHx.js} +1 -1
- package/dist/component/{dext-dropdown-rac-DPApx74L.js → dext-dropdown-rac-LLYhuGt_.js} +1 -1
- package/dist/component/{dext-email-rac-Dns6jFl4.js → dext-email-rac-CbC1crzT.js} +1 -1
- package/dist/component/{dext-number-input-rac-DfN-xRID.js → dext-number-input-rac-3-U9Hxre.js} +1 -1
- package/dist/component/{dext-phone-rac-b5Ix3aTQ.js → dext-phone-rac-CdMFXUNf.js} +1 -1
- package/dist/component/{dext-radio-group-rac-BAwIkDsJ.js → dext-radio-group-rac-Bg33r95T.js} +2 -2
- package/dist/component/{dext-rating-input-rac-mwQpCQUI.js → dext-rating-input-rac-DV8jA90b.js} +1 -1
- package/dist/component/{dext-tags-rac-BGmElgw8.js → dext-tags-rac-B-hpvZgE.js} +2 -2
- package/dist/component/{dext-text-area-rac-DN5HPqdg.js → dext-text-area-rac-kBBc0Xjo.js} +1 -1
- package/dist/component/{dext-text-input-rac-DEyDRhQ2.js → dext-text-input-rac-CImXblhX.js} +1 -1
- package/dist/component/{dext-url-input-rac-B1o3BAZE.js → dext-url-input-rac-J-7QABnD.js} +1 -1
- package/dist/component/dismiss-icon-Bw_zbdk_.js +69 -0
- package/dist/component/{donation-rac-Dp6PmATz.js → donation-rac-CvWwng6S.js} +6 -6
- package/dist/component/dropdown-field-rac-Dm9Qs8bh.js +40 -0
- package/dist/component/{dropdown-rac-eqQW-Z9k.js → dropdown-rac-BHqeUIje.js} +1 -1
- package/dist/component/{ecom-address-rac-Q02N1v6i.js → ecom-address-rac-NtuG7Q_T.js} +1 -1
- package/dist/component/{ecom-subscription-checkbox-rac-CmqVje9n.js → ecom-subscription-checkbox-rac-DAJnX_RJ.js} +2 -2
- package/dist/component/{email-input-field-rac-HmrdF3g7.js → email-input-field-rac-ompvaCLM.js} +4 -4
- package/dist/component/{events-repeater-rac-BSML2My0.js → events-repeater-rac-kHEFBH7l.js} +6 -6
- package/dist/component/{events-rsvp-rac-0pI3cb2e.js → events-rsvp-rac-R4F9aw6y.js} +4 -4
- package/dist/component/{field-error-headless-B3U_Gymg.js → field-error-headless-o2u5ldAp.js} +1 -1
- package/dist/component/{field-label-headless-Cyy9_5qJ.js → field-label-headless-DvNWYzXc.js} +1 -1
- package/dist/component/field-rac.module-D0QzJXUv.js +32 -0
- package/dist/component/{file-upload-rac-hR9TZqk2.js → file-upload-rac-DlE4dp0D.js} +5 -5
- package/dist/component/{fixed-payment-rac-CghZp6bR.js → fixed-payment-rac-BxsFHhXP.js} +4 -4
- package/dist/component/{form-BmSV4tOz.js → form-Co7SkMqj.js} +1701 -1688
- package/dist/component/form.css +1 -1
- package/dist/component/form.js +1 -1
- package/dist/component/{header-field-rac-C7LDm89o.js → header-field-rac-D56CKAtM.js} +2 -2
- package/dist/component/{header-rac-BNNzF5wQ.js → header-rac-DdYSBcq1.js} +1 -1
- package/dist/component/{image-choice-rac-DLgxkKIZ.js → image-choice-rac-g23R5qLL.js} +5 -5
- package/dist/component/{index-Dg8Fefid.js → index-BmOwghzn.js} +2 -2
- package/dist/component/{index-B8ObIJtL.js → index-C0yPsVXz.js} +4 -4
- package/dist/component/{isObjectLike-oBQcCfqW.js → isObjectLike-mlNAmhLJ.js} +1 -1
- package/dist/component/multiline-address-field-rac-ApBLSWB_.js +1818 -0
- package/dist/component/{multiline-address-rac-8MZkKfqY.js → multiline-address-rac-tdENoXBT.js} +1 -1
- package/dist/component/native-select-BbxBpe3S.js +32 -0
- package/dist/component/{number-input-field-rac-Dmp8pNIq.js → number-input-field-rac-CCIuPPeP.js} +5 -5
- package/dist/component/{number-input-rac-2cN_bN_s.js → number-input-rac-DxodjaRb.js} +1 -1
- package/dist/component/{password-rac-CFdC1hoi.js → password-rac-h9U6siGg.js} +5 -5
- package/dist/component/{payment-input-rac-BWElGzuv.js → payment-input-rac-YFXgnLS6.js} +5 -5
- package/dist/component/phone-input-field-rac-B9PUQJUP.js +558 -0
- package/dist/component/{phone-rac-CE9-90C3.js → phone-rac-B1Q9HXAB.js} +1 -1
- package/dist/component/{product-list-rac-QU7Ocwvy.js → product-list-rac-D63k_IAW.js} +6 -6
- package/dist/component/{quiz-radio-group-rac-Hm7B7RlU.js → quiz-radio-group-rac-Bl6DYjmg.js} +1 -1
- package/dist/component/{radio-button-module-classes-CcGF7N_Y.js → radio-button-module-classes-BRHKk6XZ.js} +3 -3
- package/dist/component/{radio-group-field-rac-Bk1JBBts.js → radio-group-field-rac-B8yEmx79.js} +5 -5
- package/dist/component/{radio-group-rac-D_YZnpID.js → radio-group-rac-xX_sfxL0.js} +1 -1
- package/dist/component/{rating-input-field-rac-zvA6QBGo.js → rating-input-field-rac-_p1u5oCL.js} +5 -5
- package/dist/component/{rating-input-rac-CXVQUoi-.js → rating-input-rac-C_i6Nwdz.js} +1 -1
- package/dist/component/{rich-content-rac.module-CnZ4lMBG.js → rich-content-rac.module-BlHWoitq.js} +1 -1
- package/dist/component/{rich-text-field-rac-DYQgVXdV.js → rich-text-field-rac-EiH-NdJm.js} +2 -2
- package/dist/component/{rich-text-rac-Dk8396e-.js → rich-text-rac-eZvghmFV.js} +1 -1
- package/dist/component/service-dropdown-rac-bujnhWyl.js +150 -0
- package/dist/component/{services-multi-choice-rac-D1RiVaLW.js → services-multi-choice-rac-FXrJOBdY.js} +7 -7
- package/dist/component/{signature-rac-DcGKMX84.js → signature-rac-CoVHMOpK.js} +5 -5
- package/dist/component/{submit-button-rac-DbMxQlNH.js → submit-button-rac-B8w753Be.js} +36 -36
- package/dist/component/{tags-field-rac-Bi4lKutL.js → tags-field-rac-iitBlZ8l.js} +6 -6
- package/dist/component/{tags-rac-DDCPnT8M.js → tags-rac-DJSUQlkc.js} +1 -1
- package/dist/component/{text-area-field-rac-cre_K0MD.js → text-area-field-rac-CePWfCbx.js} +5 -5
- package/dist/component/{text-area-rac-61wsMj-j.js → text-area-rac-m18L6Zwk.js} +1 -1
- package/dist/component/{text-input-field-rac-CV5_ba0x.js → text-input-field-rac-BSo_dbkm.js} +4 -4
- package/dist/component/{text-input-headless-kRv3KpSL.js → text-input-headless-D-o9wyGb.js} +3 -3
- package/dist/component/{text-input-rac-CwqZ6NXO.js → text-input-rac-CcGgoWaF.js} +1 -1
- package/dist/component/time-input-rac-DRIFM107.js +212 -0
- package/dist/component/to-native-time-Co_gOLkc.js +9 -0
- package/dist/component/{url-input-field-rac-C1JL_m6D.js → url-input-field-rac-Dpn9-sDD.js} +5 -5
- package/dist/component/{url-input-rac-C1CiGrCn.js → url-input-rac-CDSl1LX1.js} +1 -1
- package/dist/component/{use-dropdown-option-class-name-COGEk5d6.js → use-dropdown-option-class-name-CHg44uaJ.js} +3 -3
- package/dist/component/use-dropdown-trigger-class-name-Dpwl6OCY.js +137 -0
- package/dist/component/{use-element-state-class-name-pSOX0Y0p.js → use-element-state-class-name-BUu6zq-d.js} +1 -1
- package/dist/component/{use-hoverable-input-class-name-DGEpOAdi.js → use-hoverable-input-class-name-B1V7zCNe.js} +3 -3
- package/dist/component/{use-is-forced-open-dropdown-DPG1e5E9.js → use-is-forced-open-dropdown-BbHOZTaj.js} +1 -1
- package/dist/component/use-native-mobile-input-Ct8ysLL3.js +31 -0
- package/dist/component/use-native-state-class-name-B0m2ghbS.js +18 -0
- package/dist/component/{use-service-options-base-BgIZ94V9.js → use-service-options-base-u-WCeJHQ.js} +1 -1
- package/dist/component/use-text-input-class-name-DfNU2oQf.js +6 -0
- package/package.json +3 -2
- package/dist/component/date-input-field-rac-CiAaOiYY.js +0 -309
- package/dist/component/date-picker-field-rac-Dg-chlTL.js +0 -320
- package/dist/component/date-time-input-field-rac-CbDvEPIp.js +0 -441
- package/dist/component/dropdown-field-rac-DY3GGJgP.js +0 -36
- package/dist/component/field-rac.module-DcyJyi2B.js +0 -25
- package/dist/component/multiline-address-field-rac-CgH7lDce.js +0 -1738
- package/dist/component/phone-input-field-rac-CsJGw_OE.js +0 -520
- package/dist/component/service-dropdown-rac-BSXYuBPJ.js +0 -145
- package/dist/component/time-input-rac-DuQar6zW.js +0 -161
- package/dist/component/use-dropdown-trigger-class-name-D6c-3Lyw.js +0 -98
- package/dist/component/use-text-input-class-name-BcbHdFV-.js +0 -6
|
@@ -5,13 +5,13 @@ import { C as he } from "./chevron-down-icon-CcpVm6B-.js";
|
|
|
5
5
|
import { E as lt } from "./error-icon-hZxQ6DEy.js";
|
|
6
6
|
import { g as ct, c as Ce } from "./calendar.module-BMUyMVja.js";
|
|
7
7
|
import { H as me } from "./custom-focus-class-_483Pkwp.js";
|
|
8
|
-
import { s as ue } from "./field-rac.module-
|
|
9
|
-
import { bF as Ee, bE as mt, bJ as ge, bH as ut, bY as dt, bX as Dt, bN as ie, bK as le, bP as ft, bM as Et, F as St, h as _t, X as Nt, am as pt, g as At, j as We, i as yt, n as It, k as Ot, l as Lt, M as Tt, I as bt, m as gt } from "./form-
|
|
10
|
-
import { u as vt } from "./use-element-state-class-name-
|
|
8
|
+
import { s as ue } from "./field-rac.module-D0QzJXUv.js";
|
|
9
|
+
import { bF as Ee, bE as mt, bJ as ge, bH as ut, bY as dt, bX as Dt, bN as ie, bK as le, bP as ft, bM as Et, F as St, h as _t, X as Nt, am as pt, g as At, j as We, i as yt, n as It, k as Ot, l as Lt, M as Tt, I as bt, m as gt } from "./form-Co7SkMqj.js";
|
|
10
|
+
import { u as vt } from "./use-element-state-class-name-BUu6zq-d.js";
|
|
11
11
|
import { ListBox as Rt, Button as ve, ListBoxItem as kt, RadioGroup as Mt, RadioField as Ft, RadioButton as wt } from "react-aria-components";
|
|
12
12
|
import { f as v, a as Se } from "./find-child-C60k4CxG.js";
|
|
13
|
-
import { D as ht, E as Ct } from "./field-error-headless-
|
|
14
|
-
import { L as Wt } from "./field-label-headless-
|
|
13
|
+
import { D as ht, E as Ct } from "./field-error-headless-o2u5ldAp.js";
|
|
14
|
+
import { L as Wt } from "./field-label-headless-DvNWYzXc.js";
|
|
15
15
|
import { F as xt } from "./fieldset-headless-CD3fds9J.js";
|
|
16
16
|
import "date-fns";
|
|
17
17
|
import { V as Ge } from "./headless-styles-CmcyA_pi.js";
|
package/dist/component/{bookings-login-bar-rac-8FbvPiv1.js → bookings-login-bar-rac-DfqRpARE.js}
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import o from "react";
|
|
2
2
|
import E from "classnames";
|
|
3
|
-
import { bN as d, bY as b, bF as f, bJ as x, W as p } from "./form-
|
|
3
|
+
import { bN as d, bY as b, bF as f, bJ as x, W as p } from "./form-Co7SkMqj.js";
|
|
4
4
|
import { Button as L } from "react-aria-components";
|
|
5
5
|
import { a as m, f as g } from "./find-child-C60k4CxG.js";
|
|
6
6
|
const l = ({ children: n }) => {
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import e from "react";
|
|
2
|
+
const o = /^\d{4}-\d{2}-\d{2}$/, n = (t) => t && o.test(t) ? t : "", a = (t) => /* @__PURE__ */ e.createElement("svg", {
|
|
3
|
+
viewBox: "0 0 24 24",
|
|
4
|
+
fill: "none",
|
|
5
|
+
width: 14,
|
|
6
|
+
height: 14,
|
|
7
|
+
"aria-hidden": "true",
|
|
8
|
+
...t
|
|
9
|
+
}, /* @__PURE__ */ e.createElement("path", {
|
|
10
|
+
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",
|
|
11
|
+
stroke: "currentColor",
|
|
12
|
+
strokeWidth: "1.5",
|
|
13
|
+
strokeLinecap: "round",
|
|
14
|
+
strokeLinejoin: "round"
|
|
15
|
+
}));
|
|
16
|
+
export {
|
|
17
|
+
a as C,
|
|
18
|
+
n as t
|
|
19
|
+
};
|
|
@@ -2,16 +2,16 @@ import { RicosViewer as $n } from "@wix/ricos/viewer";
|
|
|
2
2
|
import B from "classnames";
|
|
3
3
|
import g, { useMemo as Jn, useRef as Yn, useCallback as Qn } from "react";
|
|
4
4
|
import { CheckboxField as Zn, CheckboxButton as ei } from "react-aria-components";
|
|
5
|
-
import { bk as ri, bN as et, b2 as Zr, b1 as ln, bY as ti, bF as ai, bs as ni, bK as ii, bP as si, bW as oi, o as ui, am as ci, t as fi, aY as li, M as _i, I as vi, s as hi } from "./form-
|
|
5
|
+
import { bk as ri, bN as et, b2 as Zr, b1 as ln, bY as ti, bF as ai, bs as ni, bK as ii, bP as si, bW as oi, o as ui, am as ci, t as fi, aY as li, M as _i, I as vi, s as hi } from "./form-Co7SkMqj.js";
|
|
6
6
|
import { f as W, a as yt } from "./find-child-C60k4CxG.js";
|
|
7
|
-
import { D as pi, E as di } from "./field-error-headless-
|
|
7
|
+
import { D as pi, E as di } from "./field-error-headless-o2u5ldAp.js";
|
|
8
8
|
import { Node_Type as yi } from "@wix/ricos/schema";
|
|
9
|
-
import { c as re, r as $, e as E, a as J, d as bi, b as gi } from "./isObjectLike-
|
|
9
|
+
import { c as re, r as $, e as E, a as J, d as bi, b as gi } from "./isObjectLike-mlNAmhLJ.js";
|
|
10
10
|
import { S as qi } from "./selection-indicator-XQ8MYHUQ.js";
|
|
11
11
|
import { E as Ci } from "./error-icon-hZxQ6DEy.js";
|
|
12
|
-
import { C as Ai } from "./checkbox-indicator-module-classes-
|
|
13
|
-
import { s as oe } from "./field-rac.module-
|
|
14
|
-
import { u as mi } from "./use-element-state-class-name-
|
|
12
|
+
import { C as Ai } from "./checkbox-indicator-module-classes-Cozvs_kk.js";
|
|
13
|
+
import { s as oe } from "./field-rac.module-D0QzJXUv.js";
|
|
14
|
+
import { u as mi } from "./use-element-state-class-name-BUu6zq-d.js";
|
|
15
15
|
var ue, bt;
|
|
16
16
|
function Ii() {
|
|
17
17
|
if (bt) return ue;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import o, { useRef as q, useMemo as F, useCallback as $, useState as w, useEffect as K } from "react";
|
|
2
2
|
import { CheckboxGroup as A, CheckboxField as M, CheckboxButton as Y, TextField as j, Input as z } from "react-aria-components";
|
|
3
3
|
import { debounce as J } from "ts-debounce";
|
|
4
|
-
import { bN as R, bK as Q, bW as U, bY as X, bP as Z } from "./form-
|
|
4
|
+
import { bN as R, bK as Q, bW as U, bY as X, bP as Z } from "./form-Co7SkMqj.js";
|
|
5
5
|
import { f as I, a as k } from "./find-child-C60k4CxG.js";
|
|
6
|
-
import { D as ee, E as te } from "./field-error-headless-
|
|
7
|
-
import { L as ae } from "./field-label-headless-
|
|
6
|
+
import { D as ee, E as te } from "./field-error-headless-o2u5ldAp.js";
|
|
7
|
+
import { L as ae } from "./field-label-headless-DvNWYzXc.js";
|
|
8
8
|
import { F as ne } from "./fieldset-headless-CD3fds9J.js";
|
|
9
9
|
import { S as le } from "./selection-indicator-XQ8MYHUQ.js";
|
|
10
10
|
const N = "Other", se = (e, t) => e.some((r) => !t.includes(r)), B = (e, t) => e.length > 0 && se(e, t), re = (e, t) => {
|
package/dist/component/{checkbox-group-field-rac-BmbxaprJ.js → checkbox-group-field-rac-ClRi6Ljp.js}
RENAMED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import { RicosViewer as m } from "@wix/ricos/viewer";
|
|
2
2
|
import a from "classnames";
|
|
3
3
|
import e from "react";
|
|
4
|
-
import { C as t } from "./checkbox-group-field-headless-
|
|
4
|
+
import { C as t } from "./checkbox-group-field-headless-BeU8DG0A.js";
|
|
5
5
|
import { E as n } from "./error-icon-hZxQ6DEy.js";
|
|
6
|
-
import { C as c } from "./checkbox-indicator-module-classes-
|
|
7
|
-
import { s } from "./field-rac.module-
|
|
8
|
-
import { X as i, am as E, p, r as C, M as O, I as _, q as I } from "./form-
|
|
6
|
+
import { C as c } from "./checkbox-indicator-module-classes-Cozvs_kk.js";
|
|
7
|
+
import { s } from "./field-rac.module-D0QzJXUv.js";
|
|
8
|
+
import { X as i, am as E, p, r as C, M as O, I as _, q as I } from "./form-Co7SkMqj.js";
|
|
9
9
|
import { o as l } from "./options-rac.module-_THNq6Qq.js";
|
|
10
|
-
import { u as L } from "./use-element-state-class-name-
|
|
11
|
-
import { u as R } from "./use-text-input-class-name-
|
|
10
|
+
import { u as L } from "./use-element-state-class-name-BUu6zq-d.js";
|
|
11
|
+
import { u as R } from "./use-text-input-class-name-DfNU2oQf.js";
|
|
12
12
|
const u = ({ content: r, locale: o }) => /* @__PURE__ */ e.createElement(m, {
|
|
13
13
|
content: r,
|
|
14
14
|
locale: o
|
|
@@ -0,0 +1,365 @@
|
|
|
1
|
+
import { RicosViewer as oe } from "@wix/ricos/viewer";
|
|
2
|
+
import f from "classnames";
|
|
3
|
+
import t, { useMemo as T, useRef as Y, Children as se, isValidElement as le, useState as ee, useCallback as Q } from "react";
|
|
4
|
+
import { b4 as c, bN as _, bK as j, bF as G, bh as te, bu as ae, bP as k, bY as H, bb as ce, bi as ie, bC as me, u as ue, X as de, am as pe, w as W, x as Ee, M as be, I as Ne, v as fe, y as De, z as X } from "./form-Co7SkMqj.js";
|
|
5
|
+
import { mergeProps as Ie, UNSAFE_PortalProvider as Ce } from "react-aria";
|
|
6
|
+
import { ListBoxItem as _e, Select as ge, TextField as ne, SelectValue as Oe, Input as re } from "react-aria-components";
|
|
7
|
+
import { f as p, a as q } from "./find-child-C60k4CxG.js";
|
|
8
|
+
import { g as ye } from "./helpers-HmkkXrh2.js";
|
|
9
|
+
import { D as he, E as Le } from "./field-error-headless-o2u5ldAp.js";
|
|
10
|
+
import { L as Fe } from "./field-label-headless-DvNWYzXc.js";
|
|
11
|
+
import { F as ve } from "./fieldset-headless-CD3fds9J.js";
|
|
12
|
+
import { u as Te, a as Ae, N as Pe, D as Re } from "./dismiss-icon-Bw_zbdk_.js";
|
|
13
|
+
import { u as Me, N as Se } from "./use-native-mobile-input-Ct8ysLL3.js";
|
|
14
|
+
import { N as Ye, E as Be, S as xe } from "./non-modal-popover-D-u13tmp.js";
|
|
15
|
+
import { t as He, C as Ve } from "./calendar-icon-DOeHn3jt.js";
|
|
16
|
+
import { u as Ue } from "./use-is-forced-open-dropdown-BbHOZTaj.js";
|
|
17
|
+
import { u as we } from "./use-native-state-class-name-B0m2ghbS.js";
|
|
18
|
+
import { V as ke, a as qe } from "./use-dropdown-option-class-name-CHg44uaJ.js";
|
|
19
|
+
import { C as $e } from "./chevron-down-icon-CcpVm6B-.js";
|
|
20
|
+
import { E as ze } from "./error-icon-hZxQ6DEy.js";
|
|
21
|
+
import { H as Ke } from "./custom-focus-class-_483Pkwp.js";
|
|
22
|
+
import { s as E } from "./field-rac.module-D0QzJXUv.js";
|
|
23
|
+
import { u as V } from "./use-hoverable-input-class-name-B1V7zCNe.js";
|
|
24
|
+
const We = {
|
|
25
|
+
[c.MONTH]: "bday-month",
|
|
26
|
+
[c.DAY]: "bday-day",
|
|
27
|
+
[c.YEAR]: "bday-year"
|
|
28
|
+
}, J = (e, a) => e === "bday" ? We[a] : void 0, n = ({ children: e, className: a }) => {
|
|
29
|
+
const { id: o, required: s, onBlur: r, onFocus: l, FieldLayout: m } = _(), { inputId: i, labelId: u, ariaDescribedBy: d } = j(), { regionalFormat: b } = G(), N = Me(), D = T(() => te(b).filter(ae).map((S) => S.toUpperCase()), [
|
|
30
|
+
b
|
|
31
|
+
]), g = p(e, n.Label), P = p(e, n.Description), I = p(e, n.Error), L = p(e, n.NativeDate), C = {
|
|
32
|
+
[c.MONTH]: p(e, n.Month),
|
|
33
|
+
[c.DAY]: p(e, n.Day),
|
|
34
|
+
[c.YEAR]: p(e, n.Year)
|
|
35
|
+
}, R = N ? g : q(g, {
|
|
36
|
+
as: "div"
|
|
37
|
+
}), M = N ? L : /* @__PURE__ */ t.createElement(ve, {
|
|
38
|
+
id: i,
|
|
39
|
+
ariaLabelledBy: u,
|
|
40
|
+
ariaDescribedBy: d,
|
|
41
|
+
required: s,
|
|
42
|
+
onBlur: r,
|
|
43
|
+
onFocus: l,
|
|
44
|
+
className: a
|
|
45
|
+
}, C[D[0]], C[D[1]], C[D[2]]);
|
|
46
|
+
return /* @__PURE__ */ t.createElement(m, {
|
|
47
|
+
fieldId: o,
|
|
48
|
+
renderLabel: () => R,
|
|
49
|
+
renderInput: () => M,
|
|
50
|
+
renderDescription: () => /* @__PURE__ */ t.createElement(t.Fragment, null, I, P)
|
|
51
|
+
});
|
|
52
|
+
}, y = ({ children: e, className: a }) => {
|
|
53
|
+
const { id: o, disabled: s, readOnly: r, showDateLabels: l, hidePlaceholder: m, autoComplete: i } = _(), { labelId: u } = h(c.MONTH), { partValue: d, partError: b, onPartChange: N } = A(c.MONTH), { t: D } = H(), [g, P] = ee(!1), I = Ue(o), [L, C] = ee(null), R = m ? Be : D("field.date.placeholder.month"), M = Q((F) => {
|
|
54
|
+
r || N(typeof F == "string" ? F : "");
|
|
55
|
+
}, [
|
|
56
|
+
N,
|
|
57
|
+
r
|
|
58
|
+
]), S = Q((F) => {
|
|
59
|
+
P(F && !r);
|
|
60
|
+
}, [
|
|
61
|
+
r
|
|
62
|
+
]), $ = p(e, y.Label), z = p(e, y.Trigger), K = p(e, y.Options);
|
|
63
|
+
return /* @__PURE__ */ t.createElement("div", {
|
|
64
|
+
className: a,
|
|
65
|
+
"data-date-field": !0
|
|
66
|
+
}, l ? $ : null, /* @__PURE__ */ t.createElement("div", {
|
|
67
|
+
ref: C,
|
|
68
|
+
style: {
|
|
69
|
+
display: "contents"
|
|
70
|
+
}
|
|
71
|
+
}), /* @__PURE__ */ t.createElement(Ce, {
|
|
72
|
+
getContainer: () => L
|
|
73
|
+
}, /* @__PURE__ */ t.createElement(ge, {
|
|
74
|
+
autoComplete: J(i, c.MONTH),
|
|
75
|
+
"aria-labelledby": l ? u : void 0,
|
|
76
|
+
value: d || null,
|
|
77
|
+
onChange: M,
|
|
78
|
+
isDisabled: s,
|
|
79
|
+
isInvalid: b,
|
|
80
|
+
placeholder: R,
|
|
81
|
+
isOpen: I || g,
|
|
82
|
+
onOpenChange: I ? void 0 : S
|
|
83
|
+
}, z, q(K, {
|
|
84
|
+
isForcedOpen: I
|
|
85
|
+
}))));
|
|
86
|
+
}, Xe = ({ className: e }) => /* @__PURE__ */ t.createElement(Z, {
|
|
87
|
+
datePart: c.MONTH,
|
|
88
|
+
className: e
|
|
89
|
+
}), Qe = ({ children: e, className: a }) => {
|
|
90
|
+
const { id: o, readOnly: s } = _(), { inputId: r } = h(c.MONTH), { partError: l, isFirstPart: m } = A(c.MONTH), i = Y(null);
|
|
91
|
+
return k(() => {
|
|
92
|
+
var u;
|
|
93
|
+
m && ((u = i.current) == null || u.focus({
|
|
94
|
+
preventScroll: !0
|
|
95
|
+
}));
|
|
96
|
+
}, o), /* @__PURE__ */ t.createElement(xe, {
|
|
97
|
+
ref: i,
|
|
98
|
+
id: r,
|
|
99
|
+
className: a,
|
|
100
|
+
"data-hook": c.MONTH,
|
|
101
|
+
"data-invalid": l || void 0,
|
|
102
|
+
"data-readonly": s || void 0
|
|
103
|
+
}, /* @__PURE__ */ t.createElement(Oe, null), e);
|
|
104
|
+
}, U = ({ children: e, className: a, ...o }) => {
|
|
105
|
+
const { isForcedOpen: s } = o, { language: r } = G(), l = T(() => ye(r), [
|
|
106
|
+
r
|
|
107
|
+
]), m = p(e, U.Option) ?? /* @__PURE__ */ t.createElement(U.Option, null);
|
|
108
|
+
return /* @__PURE__ */ t.createElement(Ye, {
|
|
109
|
+
className: a,
|
|
110
|
+
containerPadding: 0,
|
|
111
|
+
offset: 0
|
|
112
|
+
}, /* @__PURE__ */ t.createElement(ke, {
|
|
113
|
+
isForcedOpen: s,
|
|
114
|
+
autoFocus: s ? !1 : void 0
|
|
115
|
+
}, l.map((i, u) => q(m, {
|
|
116
|
+
key: String(u + 1),
|
|
117
|
+
value: String(u + 1),
|
|
118
|
+
label: i
|
|
119
|
+
}))));
|
|
120
|
+
}, je = ({ className: e, ...a }) => {
|
|
121
|
+
const { value: o, label: s } = a;
|
|
122
|
+
return /* @__PURE__ */ t.createElement(_e, {
|
|
123
|
+
className: e,
|
|
124
|
+
id: o,
|
|
125
|
+
textValue: s
|
|
126
|
+
}, s);
|
|
127
|
+
};
|
|
128
|
+
y.Label = Xe;
|
|
129
|
+
y.Trigger = Qe;
|
|
130
|
+
y.Options = U;
|
|
131
|
+
U.Option = je;
|
|
132
|
+
const B = ({ children: e, className: a }) => {
|
|
133
|
+
const { disabled: o, readOnly: s, showDateLabels: r } = _(), { labelId: l } = h(c.DAY), { partValue: m, partError: i, onPartChange: u } = A(c.DAY), d = p(e, B.Label), b = p(e, B.Input);
|
|
134
|
+
return /* @__PURE__ */ t.createElement("div", {
|
|
135
|
+
className: a,
|
|
136
|
+
"data-date-field": !0
|
|
137
|
+
}, r && d, /* @__PURE__ */ t.createElement(ne, {
|
|
138
|
+
"aria-labelledby": r ? l : void 0,
|
|
139
|
+
value: m,
|
|
140
|
+
onChange: u,
|
|
141
|
+
isDisabled: o,
|
|
142
|
+
isReadOnly: s,
|
|
143
|
+
isInvalid: i
|
|
144
|
+
}, b));
|
|
145
|
+
}, Ge = ({ className: e }) => /* @__PURE__ */ t.createElement(Z, {
|
|
146
|
+
datePart: c.DAY,
|
|
147
|
+
className: e
|
|
148
|
+
}), Je = ({ className: e }) => {
|
|
149
|
+
const { id: a, hidePlaceholder: o, autoComplete: s } = _(), { inputId: r } = h(c.DAY), { isFirstPart: l } = A(c.DAY), { t: m } = H(), i = Y(null), u = o ? void 0 : m("field.date.placeholder.day");
|
|
150
|
+
return k(() => {
|
|
151
|
+
var d;
|
|
152
|
+
l && ((d = i.current) == null || d.focus({
|
|
153
|
+
preventScroll: !0
|
|
154
|
+
}));
|
|
155
|
+
}, a), /* @__PURE__ */ t.createElement(re, {
|
|
156
|
+
ref: i,
|
|
157
|
+
id: r,
|
|
158
|
+
className: e,
|
|
159
|
+
placeholder: u,
|
|
160
|
+
autoComplete: J(s, c.DAY),
|
|
161
|
+
maxLength: 2,
|
|
162
|
+
inputMode: "numeric",
|
|
163
|
+
"data-hook": c.DAY
|
|
164
|
+
});
|
|
165
|
+
};
|
|
166
|
+
B.Label = Ge;
|
|
167
|
+
B.Input = Je;
|
|
168
|
+
const x = ({ children: e, className: a }) => {
|
|
169
|
+
const { disabled: o, readOnly: s, showDateLabels: r } = _(), { labelId: l } = h(c.YEAR), { partValue: m, partError: i, onPartChange: u } = A(c.YEAR), d = p(e, x.Label), b = p(e, x.Input);
|
|
170
|
+
return /* @__PURE__ */ t.createElement("div", {
|
|
171
|
+
className: a,
|
|
172
|
+
"data-date-field": !0
|
|
173
|
+
}, r && d, /* @__PURE__ */ t.createElement(ne, {
|
|
174
|
+
"aria-labelledby": r ? l : void 0,
|
|
175
|
+
value: m,
|
|
176
|
+
onChange: u,
|
|
177
|
+
isDisabled: o,
|
|
178
|
+
isReadOnly: s,
|
|
179
|
+
isInvalid: i
|
|
180
|
+
}, b));
|
|
181
|
+
}, Ze = ({ className: e }) => /* @__PURE__ */ t.createElement(Z, {
|
|
182
|
+
datePart: c.YEAR,
|
|
183
|
+
className: e
|
|
184
|
+
}), et = ({ className: e }) => {
|
|
185
|
+
const { id: a, hidePlaceholder: o, autoComplete: s } = _(), { inputId: r } = h(c.YEAR), { isFirstPart: l } = A(c.YEAR), { t: m } = H(), i = Y(null), u = o ? void 0 : m("field.date.placeholder.year");
|
|
186
|
+
return k(() => {
|
|
187
|
+
var d;
|
|
188
|
+
l && ((d = i.current) == null || d.focus({
|
|
189
|
+
preventScroll: !0
|
|
190
|
+
}));
|
|
191
|
+
}, a), /* @__PURE__ */ t.createElement(re, {
|
|
192
|
+
ref: i,
|
|
193
|
+
id: r,
|
|
194
|
+
className: e,
|
|
195
|
+
placeholder: u,
|
|
196
|
+
autoComplete: J(s, c.YEAR),
|
|
197
|
+
maxLength: 4,
|
|
198
|
+
inputMode: "numeric",
|
|
199
|
+
"data-hook": c.YEAR
|
|
200
|
+
});
|
|
201
|
+
};
|
|
202
|
+
x.Label = Ze;
|
|
203
|
+
x.Input = et;
|
|
204
|
+
const w = ({ className: e, children: a }) => {
|
|
205
|
+
const { id: o, value: s, onChange: r, required: l, disabled: m, readOnly: i, hasError: u, autoComplete: d, onBlur: b, onFocus: N } = _(), { inputId: D, labelId: g, ariaDescribedBy: P } = j(), I = Y(null), L = Y(null);
|
|
206
|
+
k(() => {
|
|
207
|
+
var v;
|
|
208
|
+
(v = I.current) == null || v.focus({
|
|
209
|
+
preventScroll: !0
|
|
210
|
+
});
|
|
211
|
+
}, o);
|
|
212
|
+
const C = He(s), { announcement: R, announceCleared: M } = Te(!!C), S = !!C && !l && !m && !i, $ = p(a, w.Clear), z = se.map(a, (v) => /* @__PURE__ */ le(v) && v.type === w.Clear ? null : v), { className: K, stateProps: F } = we(e);
|
|
213
|
+
return /* @__PURE__ */ t.createElement(Se, {
|
|
214
|
+
ref: L,
|
|
215
|
+
groupLabelId: g,
|
|
216
|
+
announcement: R
|
|
217
|
+
}, /* @__PURE__ */ t.createElement(Ae, {
|
|
218
|
+
ref: I,
|
|
219
|
+
type: "date",
|
|
220
|
+
id: D,
|
|
221
|
+
className: K,
|
|
222
|
+
...Ie(F, {
|
|
223
|
+
onFocus: N,
|
|
224
|
+
onBlur: b
|
|
225
|
+
}),
|
|
226
|
+
"aria-labelledby": g,
|
|
227
|
+
"aria-describedby": P,
|
|
228
|
+
"aria-invalid": u || void 0,
|
|
229
|
+
autoComplete: d,
|
|
230
|
+
value: C,
|
|
231
|
+
onChange: r,
|
|
232
|
+
disabled: m,
|
|
233
|
+
readOnly: i,
|
|
234
|
+
required: l
|
|
235
|
+
}), z, S ? q($, {
|
|
236
|
+
input: I,
|
|
237
|
+
control: L,
|
|
238
|
+
labelId: g,
|
|
239
|
+
onClear: () => {
|
|
240
|
+
r(""), M();
|
|
241
|
+
}
|
|
242
|
+
}) : null);
|
|
243
|
+
};
|
|
244
|
+
w.Clear = Pe;
|
|
245
|
+
n.Label = Fe;
|
|
246
|
+
n.NativeDate = w;
|
|
247
|
+
n.Month = y;
|
|
248
|
+
n.Day = B;
|
|
249
|
+
n.Year = x;
|
|
250
|
+
n.Description = he;
|
|
251
|
+
n.Error = Le;
|
|
252
|
+
function h(e) {
|
|
253
|
+
const { inputId: a } = j();
|
|
254
|
+
return T(() => {
|
|
255
|
+
const o = e.toLowerCase();
|
|
256
|
+
return {
|
|
257
|
+
inputId: `${a}-${o}-input`,
|
|
258
|
+
labelId: `${a}-${o}-label`
|
|
259
|
+
};
|
|
260
|
+
}, [
|
|
261
|
+
a,
|
|
262
|
+
e
|
|
263
|
+
]);
|
|
264
|
+
}
|
|
265
|
+
function A(e) {
|
|
266
|
+
const { value: a, onChange: o, hasError: s = !1 } = _(), { regionalFormat: r } = G(), l = T(() => ce(a ?? ""), [
|
|
267
|
+
a
|
|
268
|
+
]), m = T(() => ie(s, a ?? ""), [
|
|
269
|
+
a,
|
|
270
|
+
s
|
|
271
|
+
]), i = l[e] || "", u = Q((b) => {
|
|
272
|
+
const N = me(b, e, l);
|
|
273
|
+
o(N);
|
|
274
|
+
}, [
|
|
275
|
+
o,
|
|
276
|
+
l,
|
|
277
|
+
e
|
|
278
|
+
]), d = T(() => te(r).filter(ae).map((D) => D.toUpperCase())[0] === e, [
|
|
279
|
+
r,
|
|
280
|
+
e
|
|
281
|
+
]);
|
|
282
|
+
return {
|
|
283
|
+
partValue: i,
|
|
284
|
+
partError: m[e],
|
|
285
|
+
onPartChange: u,
|
|
286
|
+
isFirstPart: d
|
|
287
|
+
};
|
|
288
|
+
}
|
|
289
|
+
function Z({ datePart: e, className: a }) {
|
|
290
|
+
const { inputId: o, labelId: s } = h(e), { t: r } = H(), l = `field.date.label.${e.toLowerCase()}`, m = r(l);
|
|
291
|
+
return /* @__PURE__ */ t.createElement("label", {
|
|
292
|
+
id: s,
|
|
293
|
+
htmlFor: o,
|
|
294
|
+
className: a
|
|
295
|
+
}, m);
|
|
296
|
+
}
|
|
297
|
+
const tt = "_fields_b2cgx_1", at = "_month_b2cgx_10", nt = "_day_b2cgx_11", rt = "_year_b2cgx_12", ot = "_dayInput_b2cgx_28", st = "_yearInput_b2cgx_29", lt = "_monthTrigger_b2cgx_33", ct = "_monthOption_b2cgx_53", O = {
|
|
298
|
+
fields: tt,
|
|
299
|
+
month: at,
|
|
300
|
+
day: nt,
|
|
301
|
+
year: rt,
|
|
302
|
+
dayInput: ot,
|
|
303
|
+
yearInput: st,
|
|
304
|
+
monthTrigger: lt,
|
|
305
|
+
monthOption: ct
|
|
306
|
+
}, it = ({ content: e, locale: a }) => /* @__PURE__ */ t.createElement(oe, {
|
|
307
|
+
content: e,
|
|
308
|
+
locale: a
|
|
309
|
+
}), Mt = () => {
|
|
310
|
+
const { t: e } = H(), a = V(fe, [
|
|
311
|
+
O.monthTrigger
|
|
312
|
+
]), o = qe(De, O.monthOption, Ke), s = V(X, [
|
|
313
|
+
O.dayInput
|
|
314
|
+
]), r = V(X, [
|
|
315
|
+
O.yearInput
|
|
316
|
+
]), l = V(X, [
|
|
317
|
+
E.nativeInput,
|
|
318
|
+
E.nativeWithLeadingIcon
|
|
319
|
+
]);
|
|
320
|
+
return /* @__PURE__ */ t.createElement(n, {
|
|
321
|
+
className: f(ue, O.fields)
|
|
322
|
+
}, /* @__PURE__ */ t.createElement(n.Label, {
|
|
323
|
+
className: f(de, E.label)
|
|
324
|
+
}, /* @__PURE__ */ t.createElement(n.Label.Required, {
|
|
325
|
+
className: f(pe, E.requiredMark)
|
|
326
|
+
})), /* @__PURE__ */ t.createElement(n.Month, {
|
|
327
|
+
className: O.month
|
|
328
|
+
}, /* @__PURE__ */ t.createElement(n.Month.Label, {
|
|
329
|
+
className: f(W, E.label)
|
|
330
|
+
}), /* @__PURE__ */ t.createElement(n.Month.Trigger, {
|
|
331
|
+
className: a
|
|
332
|
+
}, /* @__PURE__ */ t.createElement($e, {
|
|
333
|
+
className: E.dropdownIcon
|
|
334
|
+
})), /* @__PURE__ */ t.createElement(n.Month.Options, {
|
|
335
|
+
className: f(Ee, E.selectPopover, E.dropdownPopover)
|
|
336
|
+
}, /* @__PURE__ */ t.createElement(n.Month.Options.Option, {
|
|
337
|
+
className: o
|
|
338
|
+
}))), /* @__PURE__ */ t.createElement(n.Day, {
|
|
339
|
+
className: O.day
|
|
340
|
+
}, /* @__PURE__ */ t.createElement(n.Day.Label, {
|
|
341
|
+
className: f(W, E.label)
|
|
342
|
+
}), /* @__PURE__ */ t.createElement(n.Day.Input, {
|
|
343
|
+
className: s
|
|
344
|
+
})), /* @__PURE__ */ t.createElement(n.Year, {
|
|
345
|
+
className: O.year
|
|
346
|
+
}, /* @__PURE__ */ t.createElement(n.Year.Label, {
|
|
347
|
+
className: f(W, E.label)
|
|
348
|
+
}), /* @__PURE__ */ t.createElement(n.Year.Input, {
|
|
349
|
+
className: r
|
|
350
|
+
})), /* @__PURE__ */ t.createElement(n.NativeDate, {
|
|
351
|
+
className: l
|
|
352
|
+
}, /* @__PURE__ */ t.createElement(Ve, {
|
|
353
|
+
className: f(E.nativeDecoration, E.nativeLeadingIcon)
|
|
354
|
+
}), /* @__PURE__ */ t.createElement(n.NativeDate.Clear, {
|
|
355
|
+
className: E.nativeClearButton,
|
|
356
|
+
"aria-label": e("date-picker.a11y.clear-button")
|
|
357
|
+
}, /* @__PURE__ */ t.createElement(Re, null))), /* @__PURE__ */ t.createElement(n.Error, {
|
|
358
|
+
className: f(be, E.error)
|
|
359
|
+
}, /* @__PURE__ */ t.createElement(ze, null), /* @__PURE__ */ t.createElement(n.Error.Text, null)), /* @__PURE__ */ t.createElement(n.Description, {
|
|
360
|
+
className: f(Ne, E.description)
|
|
361
|
+
}, it));
|
|
362
|
+
};
|
|
363
|
+
export {
|
|
364
|
+
Mt as D
|
|
365
|
+
};
|