@wix/form-elements 1.127.0 → 1.129.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-BrC7gcpn.js → appointment-rac-BFrtR9Kx.js} +4 -4
- package/dist/component/{bookings-address-rac-D-UmBxjD.js → bookings-address-rac-BiOaHkHb.js} +1 -1
- package/dist/component/{bookings-email-rac-CjHDzU0Q.js → bookings-email-rac-AWVBomja.js} +1 -1
- package/dist/component/{bookings-first-name-rac-ChBkkkWm.js → bookings-first-name-rac-BVxrEBSC.js} +1 -1
- package/dist/component/{bookings-header-rac-ERfGeYyw.js → bookings-header-rac-DZWoWz45.js} +1 -1
- package/dist/component/{bookings-last-name-rac-CuTJ7Y8w.js → bookings-last-name-rac-wsOIAERt.js} +1 -1
- package/dist/component/{bookings-login-bar-rac-pudlQ67l.js → bookings-login-bar-rac-BEFZtTeh.js} +1 -1
- package/dist/component/{bookings-phone-rac-nLPnLRfS.js → bookings-phone-rac-DClujcXK.js} +1 -1
- package/dist/component/{bookings-rich-text-rac-DOmGQlyG.js → bookings-rich-text-rac-ghEjDW-p.js} +1 -1
- package/dist/component/{checkbox-field-rac-DLazY-iO.js → checkbox-field-rac-DvsNu9Rv.js} +4 -4
- package/dist/component/{checkbox-group-field-headless-CPyWmFBH.js → checkbox-group-field-headless-C9-35Ull.js} +3 -3
- package/dist/component/{checkbox-group-field-rac-Bir3gaI9.js → checkbox-group-field-rac-Cj09BgU-.js} +4 -4
- package/dist/component/{checkbox-group-rac-BGXUl-sJ.js → checkbox-group-rac-Buxfb0mq.js} +1 -1
- package/dist/component/{checkbox-rac-D_wZVUFV.js → checkbox-rac-DiHUcWo3.js} +1 -1
- package/dist/component/{contacts-address-rac-CNldSQbf.js → contacts-address-rac-P0OBiw6-.js} +1 -1
- package/dist/component/{contacts-birthdate-rac-AVyldaRF.js → contacts-birthdate-rac-IDz3KjEo.js} +1 -1
- package/dist/component/{contacts-company-rac-CiP1Ctpa.js → contacts-company-rac-CC_USKNp.js} +1 -1
- package/dist/component/{contacts-email-rac-CzjMVEJZ.js → contacts-email-rac-BcRvtene.js} +1 -1
- package/dist/component/{contacts-first-name-rac-G0kE0HmA.js → contacts-first-name-rac-DsybqPgd.js} +1 -1
- package/dist/component/{contacts-last-name-rac-cnTTtnMZ.js → contacts-last-name-rac-BOKeJmHo.js} +1 -1
- package/dist/component/{contacts-phone-rac-DJ9oxox4.js → contacts-phone-rac-Dc_3ZdY_.js} +1 -1
- package/dist/component/{contacts-position-rac-e0uQ-eqL.js → contacts-position-rac-Bn5kybDQ.js} +1 -1
- package/dist/component/{contacts-subscribe-rac-D4J2x78f.js → contacts-subscribe-rac-BouQEOeS.js} +1 -1
- package/dist/component/{contacts-tax-id-rac-DwJuNH-C.js → contacts-tax-id-rac-DJFrxRyu.js} +1 -1
- package/dist/component/{date-availability-D2BSwZ_r.js → date-availability-CWfQIoX1.js} +1 -1
- package/dist/component/{date-input-field-rac-ztJ02C60.js → date-input-field-rac-CP15ihpI.js} +86 -86
- package/dist/component/{date-input-rac-D-SFsC6P.js → date-input-rac-Bf0H1oiA.js} +1 -1
- package/dist/component/{date-picker-field-rac-DaNwsa8z.js → date-picker-field-rac-SOddu2Zu.js} +92 -91
- package/dist/component/{date-picker-rac-Bn0sA6P1.js → date-picker-rac-BdRbAhSB.js} +1 -1
- package/dist/component/date-time-input-field-rac-Bj_uDj6E.js +427 -0
- package/dist/component/{date-time-input-rac-qYLa3IDx.js → date-time-input-rac-Mv_mEil2.js} +1 -1
- package/dist/component/{dext-checkbox-group-rac-Dir6tyvo.js → dext-checkbox-group-rac-8kR2EZfL.js} +2 -2
- package/dist/component/{dext-checkbox-rac-ByiMc3BH.js → dext-checkbox-rac-B5CWQuVt.js} +1 -1
- package/dist/component/{dext-date-picker-rac-BwOozu5y.js → dext-date-picker-rac-D_hbdOUB.js} +1 -1
- package/dist/component/{dext-date-time-input-rac-CaJEzZa4.js → dext-date-time-input-rac-DJa6HIBI.js} +1 -1
- package/dist/component/{dext-dropdown-rac-DJnMjggU.js → dext-dropdown-rac-rUST_4lA.js} +1 -1
- package/dist/component/{dext-email-rac-CF4SQ86l.js → dext-email-rac-BN1-DKDv.js} +1 -1
- package/dist/component/{dext-number-input-rac--3goVI8C.js → dext-number-input-rac-CjoV2Zr-.js} +1 -1
- package/dist/component/{dext-phone-rac-MYJYG040.js → dext-phone-rac-BZK-MfUB.js} +1 -1
- package/dist/component/{dext-radio-group-rac-Q2J5Hk5W.js → dext-radio-group-rac-CdSOS1sE.js} +2 -2
- package/dist/component/{dext-rating-input-rac-CAWhD-lI.js → dext-rating-input-rac-DAZjknQn.js} +1 -1
- package/dist/component/{dext-tags-rac-DyxI5ooy.js → dext-tags-rac-ButsCV5O.js} +2 -2
- package/dist/component/{dext-text-area-rac-CZpM-r49.js → dext-text-area-rac-TKwYp5Cp.js} +1 -1
- package/dist/component/{dext-text-input-rac-Bv5Mhyw6.js → dext-text-input-rac-Clcifgwu.js} +1 -1
- package/dist/component/{dext-url-input-rac-BkbTjbAI.js → dext-url-input-rac-1oQFTxHV.js} +1 -1
- package/dist/component/{donation-rac-DZjFeJFy.js → donation-rac-Bh_D5aEJ.js} +5 -5
- package/dist/component/dropdown-field-headless-C-rtyAEo.js +91 -0
- package/dist/component/{dropdown-field-rac-DOAlecw8.js → dropdown-field-rac-Bo3lqJDR.js} +4 -4
- package/dist/component/{dropdown-rac-D8HtaeBe.js → dropdown-rac-C29h60zI.js} +1 -1
- package/dist/component/{ecom-address-rac-B25o-GVv.js → ecom-address-rac-gs7OAQTj.js} +1 -1
- package/dist/component/{ecom-subscription-checkbox-rac-NvdWnD0v.js → ecom-subscription-checkbox-rac-CI9zbJqB.js} +2 -2
- package/dist/component/{email-input-field-rac-rWyojsu0.js → email-input-field-rac-D75vjW_1.js} +3 -3
- package/dist/component/{events-repeater-rac-D2HvNt0y.js → events-repeater-rac-UgCJlo2O.js} +4 -4
- package/dist/component/{events-rsvp-rac-D4WLn0Bx.js → events-rsvp-rac-D5YhJy0C.js} +3 -3
- package/dist/component/{field-error-headless-DU0YsEXR.js → field-error-headless-44vAUpwr.js} +1 -1
- package/dist/component/{field-label-headless-CvdTZi6i.js → field-label-headless-Cfo9v3VS.js} +1 -1
- package/dist/component/{file-upload-rac-CMelyfA8.js → file-upload-rac-B-rYIzhu.js} +4 -4
- package/dist/component/{fixed-payment-rac-CewsqE-k.js → fixed-payment-rac-CkbmX7hl.js} +3 -3
- package/dist/component/{form-D9IxiDXP.js → form-tScYihAT.js} +69 -69
- package/dist/component/form.css +1 -1
- package/dist/component/form.js +1 -1
- package/dist/component/{header-field-rac-CYBfb_5D.js → header-field-rac-BtKN5X7s.js} +2 -2
- package/dist/component/{header-rac-BIq3DmbL.js → header-rac-pmryP48d.js} +1 -1
- package/dist/component/{image-choice-rac-aOObRIMi.js → image-choice-rac-ByBjTccP.js} +4 -4
- package/dist/component/{index-D-g3wQ-z.js → index-DXsujvrm.js} +5 -5
- package/dist/component/{index-BXqA4oNj.js → index-Dyso3MNS.js} +2 -2
- package/dist/component/{isObjectLike-BNDXzCto.js → isObjectLike-CUj2YjST.js} +1 -1
- package/dist/component/{multiline-address-field-rac-BcTa7Von.js → multiline-address-field-rac-CkifK7lO.js} +7 -7
- package/dist/component/{multiline-address-rac-Cd_BFreP.js → multiline-address-rac-DfnDSoTY.js} +1 -1
- package/dist/component/non-modal-popover-D-u13tmp.js +64 -0
- package/dist/component/{number-input-field-rac-_JlH34_3.js → number-input-field-rac-BG8cRLXY.js} +4 -4
- package/dist/component/{number-input-rac-CiM20ScT.js → number-input-rac-Byuz2Nub.js} +1 -1
- package/dist/component/{password-rac-DrpXSY74.js → password-rac-BOus-ku5.js} +4 -4
- package/dist/component/{payment-input-rac-RnMeVWDc.js → payment-input-rac-D-CZ6cKL.js} +4 -4
- package/dist/component/{phone-input-field-rac-nNp7D7gK.js → phone-input-field-rac-DCfc-MrP.js} +7 -7
- package/dist/component/{phone-rac-B2JjPT2w.js → phone-rac-1J-t9-Og.js} +1 -1
- package/dist/component/{product-list-rac-Cv_fjFn3.js → product-list-rac-CJ1YZvV9.js} +4 -4
- package/dist/component/{quiz-radio-group-rac-CNqF6Tq3.js → quiz-radio-group-rac-C_JnWUd3.js} +1 -1
- package/dist/component/{radio-button-module-classes-vqR4TN-z.js → radio-button-module-classes-DWh_AiLg.js} +3 -3
- package/dist/component/{radio-group-field-rac-Bpyr40q-.js → radio-group-field-rac-Cp48ayde.js} +4 -4
- package/dist/component/{radio-group-rac-DBLPP0YC.js → radio-group-rac-B7jR2Rb-.js} +1 -1
- package/dist/component/{rating-input-field-rac-BOi0G37L.js → rating-input-field-rac-CHEWLp0k.js} +4 -4
- package/dist/component/{rating-input-rac-CxpmV0Pa.js → rating-input-rac-BX4osXZU.js} +1 -1
- package/dist/component/{rich-content-rac.module-Dmm9GyQq.js → rich-content-rac.module-Ce08oqQ9.js} +1 -1
- package/dist/component/{rich-text-field-rac-C466OrTf.js → rich-text-field-rac-Bi1SDfiU.js} +2 -2
- package/dist/component/{rich-text-rac-BvVxD7oJ.js → rich-text-rac-DdT8jmAf.js} +1 -1
- package/dist/component/{service-dropdown-rac-pmUKH0sP.js → service-dropdown-rac-DPeHyyz_.js} +5 -5
- package/dist/component/{services-multi-choice-rac-B65i6q2D.js → services-multi-choice-rac-CKdjXJR8.js} +5 -5
- package/dist/component/{signature-rac-BRyM06Vz.js → signature-rac-ffVbFXfs.js} +4 -4
- package/dist/component/{submit-button-rac-DaCRjZlQ.js → submit-button-rac-C55AG9QQ.js} +2 -2
- package/dist/component/{tags-field-rac-CEdfh-EQ.js → tags-field-rac-BO2-TOy4.js} +5 -5
- package/dist/component/{tags-rac-CGSTQ0qK.js → tags-rac-BkCC7NCe.js} +1 -1
- package/dist/component/{text-area-field-rac-C-EHPWwQ.js → text-area-field-rac-BwYibo91.js} +4 -4
- package/dist/component/{text-area-rac-Df1nSb2q.js → text-area-rac-DZdY4txw.js} +1 -1
- package/dist/component/{text-input-field-rac-DmCZtBi_.js → text-input-field-rac-WiCBhW6i.js} +3 -3
- package/dist/component/{text-input-headless-DAxEZP1P.js → text-input-headless-B3KeulEf.js} +3 -3
- package/dist/component/{text-input-rac-DgpO17dl.js → text-input-rac-BIyCqBJv.js} +1 -1
- package/dist/component/{time-input-rac-Dld_tLub.js → time-input-rac-CC4UwoED.js} +65 -64
- package/dist/component/{url-input-field-rac-DHZ6bpxZ.js → url-input-field-rac-OppUVl3A.js} +4 -4
- package/dist/component/{url-input-rac-CZlWy5RB.js → url-input-rac-B5_eh6hN.js} +1 -1
- package/dist/component/{use-dropdown-option-class-name-opBd-YJA.js → use-dropdown-option-class-name-Bgp-eVle.js} +2 -2
- package/dist/component/{use-dropdown-trigger-class-name-BGQH0WCO.js → use-dropdown-trigger-class-name-BjjdE7MT.js} +2 -2
- package/dist/component/{use-element-state-class-name-B2ecLjwN.js → use-element-state-class-name-BXqvGrEm.js} +1 -1
- package/dist/component/{use-hoverable-input-class-name-B42rAp82.js → use-hoverable-input-class-name-CFgJ095f.js} +2 -2
- package/dist/component/{use-service-options-base-D60-jNUT.js → use-service-options-base-Cspzf1ks.js} +1 -1
- package/dist/component/use-text-input-class-name-DUHXnnCn.js +6 -0
- package/package.json +2 -2
- package/dist/component/date-time-input-field-rac-D-ArMpcJ.js +0 -426
- package/dist/component/dropdown-field-headless-C7l2TQYy.js +0 -91
- package/dist/component/non-modal-popover-DtIMXHbe.js +0 -63
- package/dist/component/use-text-input-class-name-DGpCdZ_e.js +0 -6
|
@@ -0,0 +1,427 @@
|
|
|
1
|
+
import { RicosViewer as se } from "@wix/ricos/viewer";
|
|
2
|
+
import h from "classnames";
|
|
3
|
+
import t, { useMemo as O, useState as G, useCallback as H, useRef as U, useContext as oe } from "react";
|
|
4
|
+
import { parseTime as le } from "@internationalized/date";
|
|
5
|
+
import { UNSAFE_PortalProvider as ie } from "react-aria";
|
|
6
|
+
import { ListBoxItem as ce, Select as me, TextField as Q, TimeField as de, SelectValue as ue, Input as J, DateInput as pe, DateSegment as B, TimeFieldStateContext as Ee } from "react-aria-components";
|
|
7
|
+
import { bh as f, be as W, b9 as $, aO as X, a$ as Z, aB as d, br as L, b3 as K, aQ as fe, aI as he, b6 as be, aK as j, bj as z, I as R, U as ge, K as Ie, v as Ne, p as De } from "./form-tScYihAT.js";
|
|
8
|
+
import { f as u, a as P } from "./find-child-C60k4CxG.js";
|
|
9
|
+
import { g as _e } from "./helpers-HmkkXrh2.js";
|
|
10
|
+
import { D as ye, E as Te } from "./field-error-headless-44vAUpwr.js";
|
|
11
|
+
import { L as Oe } from "./field-label-headless-Cfo9v3VS.js";
|
|
12
|
+
import { F as Le } from "./fieldset-headless-CD3fds9J.js";
|
|
13
|
+
import { N as Ce, E as Fe, S as Pe } from "./non-modal-popover-D-u13tmp.js";
|
|
14
|
+
import { a as Me, u as Se } from "./use-dropdown-trigger-class-name-BjjdE7MT.js";
|
|
15
|
+
import { V as Re, u as Ae } from "./use-dropdown-option-class-name-Bgp-eVle.js";
|
|
16
|
+
import { C as Ve } from "./chevron-down-icon-CcpVm6B-.js";
|
|
17
|
+
import { E as ve } from "./error-icon-hZxQ6DEy.js";
|
|
18
|
+
import { H as k } from "./custom-focus-class-_483Pkwp.js";
|
|
19
|
+
import { s as g } from "./field-rac.module-BIBNQEOK.js";
|
|
20
|
+
import { u as x } from "./use-text-input-class-name-DUHXnnCn.js";
|
|
21
|
+
const l = ({ children: e, className: a }) => {
|
|
22
|
+
const { id: n, required: r, onBlur: s, onFocus: o, FieldLayout: i } = f(), { inputId: m, labelId: c, ariaDescribedBy: b } = W(), { regionalFormat: p } = $(), _ = O(() => X(p).filter(Z).map((S) => S.toUpperCase()), [
|
|
23
|
+
p
|
|
24
|
+
]), M = u(e, l.Label), v = u(e, l.Description), N = u(e, l.Error), D = {
|
|
25
|
+
[d.MONTH]: u(e, l.Month),
|
|
26
|
+
[d.DAY]: u(e, l.Day),
|
|
27
|
+
[d.YEAR]: u(e, l.Year)
|
|
28
|
+
}, y = u(e, l.Time);
|
|
29
|
+
return /* @__PURE__ */ t.createElement(i, {
|
|
30
|
+
fieldId: n,
|
|
31
|
+
renderLabel: () => P(M, {
|
|
32
|
+
as: "div"
|
|
33
|
+
}),
|
|
34
|
+
renderInput: () => /* @__PURE__ */ t.createElement(Le, {
|
|
35
|
+
id: m,
|
|
36
|
+
ariaLabelledBy: c,
|
|
37
|
+
ariaDescribedBy: b,
|
|
38
|
+
required: r,
|
|
39
|
+
onBlur: s,
|
|
40
|
+
onFocus: o,
|
|
41
|
+
className: a
|
|
42
|
+
}, D[_[0]], D[_[1]], D[_[2]], y),
|
|
43
|
+
renderDescription: () => /* @__PURE__ */ t.createElement(t.Fragment, null, N, v)
|
|
44
|
+
});
|
|
45
|
+
}, C = ({ children: e, className: a }) => {
|
|
46
|
+
const { id: n, disabled: r, readOnly: s, showDateLabels: o, hidePlaceholder: i } = f(), { labelId: m } = T(d.MONTH), { partValue: c, partError: b, onPartChange: p } = F(d.MONTH), { t: _ } = L(), [M, v] = G(!1), N = Me(n), [D, y] = G(null), S = i ? Fe : _("field.date.placeholder.month"), ee = H((Y) => {
|
|
47
|
+
s || p(typeof Y == "string" ? Y : "");
|
|
48
|
+
}, [
|
|
49
|
+
p,
|
|
50
|
+
s
|
|
51
|
+
]), te = H((Y) => {
|
|
52
|
+
v(Y && !s);
|
|
53
|
+
}, [
|
|
54
|
+
s
|
|
55
|
+
]), ae = u(e, C.Label), ne = u(e, C.Trigger), re = u(e, C.Options);
|
|
56
|
+
return /* @__PURE__ */ t.createElement("div", {
|
|
57
|
+
className: a,
|
|
58
|
+
"data-date-field": !0
|
|
59
|
+
}, o ? ae : null, /* @__PURE__ */ t.createElement("div", {
|
|
60
|
+
ref: y,
|
|
61
|
+
style: {
|
|
62
|
+
display: "contents"
|
|
63
|
+
}
|
|
64
|
+
}), /* @__PURE__ */ t.createElement(ie, {
|
|
65
|
+
getContainer: () => D
|
|
66
|
+
}, /* @__PURE__ */ t.createElement(me, {
|
|
67
|
+
"aria-labelledby": o ? m : void 0,
|
|
68
|
+
value: c || null,
|
|
69
|
+
onChange: ee,
|
|
70
|
+
isDisabled: r,
|
|
71
|
+
isInvalid: b,
|
|
72
|
+
placeholder: S,
|
|
73
|
+
isOpen: N || M,
|
|
74
|
+
onOpenChange: N ? void 0 : te
|
|
75
|
+
}, ne, P(re, {
|
|
76
|
+
isForcedOpen: N
|
|
77
|
+
}))));
|
|
78
|
+
}, Ye = ({ className: e }) => /* @__PURE__ */ t.createElement(q, {
|
|
79
|
+
datePart: d.MONTH,
|
|
80
|
+
className: e
|
|
81
|
+
}), ke = ({ children: e, className: a }) => {
|
|
82
|
+
const { id: n, readOnly: r } = f(), { inputId: s } = T(d.MONTH), { partError: o, isFirstPart: i } = F(d.MONTH), m = U(null);
|
|
83
|
+
return z(() => {
|
|
84
|
+
var c;
|
|
85
|
+
i && ((c = m.current) == null || c.focus());
|
|
86
|
+
}, n), /* @__PURE__ */ t.createElement(Pe, {
|
|
87
|
+
ref: m,
|
|
88
|
+
id: s,
|
|
89
|
+
className: a,
|
|
90
|
+
"data-hook": d.MONTH,
|
|
91
|
+
"data-invalid": o || void 0,
|
|
92
|
+
"data-readonly": r || void 0
|
|
93
|
+
}, /* @__PURE__ */ t.createElement(ue, null), e);
|
|
94
|
+
}, w = ({ children: e, className: a, ...n }) => {
|
|
95
|
+
const { isForcedOpen: r } = n, { language: s } = $(), o = O(() => _e(s), [
|
|
96
|
+
s
|
|
97
|
+
]), i = u(e, w.Option) ?? /* @__PURE__ */ t.createElement(w.Option, null);
|
|
98
|
+
return /* @__PURE__ */ t.createElement(Ce, {
|
|
99
|
+
className: a,
|
|
100
|
+
containerPadding: 0,
|
|
101
|
+
offset: 0
|
|
102
|
+
}, /* @__PURE__ */ t.createElement(Re, {
|
|
103
|
+
isForcedOpen: r,
|
|
104
|
+
autoFocus: r ? !1 : void 0
|
|
105
|
+
}, o.map((m, c) => P(i, {
|
|
106
|
+
key: String(c + 1),
|
|
107
|
+
value: String(c + 1),
|
|
108
|
+
label: m
|
|
109
|
+
}))));
|
|
110
|
+
}, He = ({ className: e, ...a }) => {
|
|
111
|
+
const { value: n, label: r } = a;
|
|
112
|
+
return /* @__PURE__ */ t.createElement(ce, {
|
|
113
|
+
className: e,
|
|
114
|
+
id: n,
|
|
115
|
+
textValue: r
|
|
116
|
+
}, r);
|
|
117
|
+
};
|
|
118
|
+
C.Label = Ye;
|
|
119
|
+
C.Trigger = ke;
|
|
120
|
+
C.Options = w;
|
|
121
|
+
w.Option = He;
|
|
122
|
+
const A = ({ children: e, className: a }) => {
|
|
123
|
+
const { disabled: n, readOnly: r, showDateLabels: s } = f(), { labelId: o } = T(d.DAY), { partValue: i, partError: m, onPartChange: c } = F(d.DAY), b = u(e, A.Label), p = u(e, A.Input);
|
|
124
|
+
return /* @__PURE__ */ t.createElement("div", {
|
|
125
|
+
className: a,
|
|
126
|
+
"data-date-field": !0
|
|
127
|
+
}, s && b, /* @__PURE__ */ t.createElement(Q, {
|
|
128
|
+
"aria-labelledby": s ? o : void 0,
|
|
129
|
+
value: i,
|
|
130
|
+
onChange: c,
|
|
131
|
+
isDisabled: n,
|
|
132
|
+
isReadOnly: r,
|
|
133
|
+
isInvalid: m
|
|
134
|
+
}, p));
|
|
135
|
+
}, we = ({ className: e }) => /* @__PURE__ */ t.createElement(q, {
|
|
136
|
+
datePart: d.DAY,
|
|
137
|
+
className: e
|
|
138
|
+
}), Be = ({ className: e }) => {
|
|
139
|
+
const { id: a, hidePlaceholder: n } = f(), { inputId: r } = T(d.DAY), { isFirstPart: s } = F(d.DAY), { t: o } = L(), i = U(null), m = n ? void 0 : o("field.date.placeholder.day");
|
|
140
|
+
return z(() => {
|
|
141
|
+
var c;
|
|
142
|
+
s && ((c = i.current) == null || c.focus());
|
|
143
|
+
}, a), /* @__PURE__ */ t.createElement(J, {
|
|
144
|
+
ref: i,
|
|
145
|
+
id: r,
|
|
146
|
+
className: e,
|
|
147
|
+
placeholder: m,
|
|
148
|
+
maxLength: 2,
|
|
149
|
+
inputMode: "numeric",
|
|
150
|
+
"data-hook": d.DAY
|
|
151
|
+
});
|
|
152
|
+
};
|
|
153
|
+
A.Label = we;
|
|
154
|
+
A.Input = Be;
|
|
155
|
+
const V = ({ children: e, className: a }) => {
|
|
156
|
+
const { disabled: n, readOnly: r, showDateLabels: s } = f(), { labelId: o } = T(d.YEAR), { partValue: i, partError: m, onPartChange: c } = F(d.YEAR), b = u(e, V.Label), p = u(e, V.Input);
|
|
157
|
+
return /* @__PURE__ */ t.createElement("div", {
|
|
158
|
+
className: a,
|
|
159
|
+
"data-date-field": !0
|
|
160
|
+
}, s && b, /* @__PURE__ */ t.createElement(Q, {
|
|
161
|
+
"aria-labelledby": s ? o : void 0,
|
|
162
|
+
value: i,
|
|
163
|
+
onChange: c,
|
|
164
|
+
isDisabled: n,
|
|
165
|
+
isReadOnly: r,
|
|
166
|
+
isInvalid: m
|
|
167
|
+
}, p));
|
|
168
|
+
}, xe = ({ className: e }) => /* @__PURE__ */ t.createElement(q, {
|
|
169
|
+
datePart: d.YEAR,
|
|
170
|
+
className: e
|
|
171
|
+
}), Ue = ({ className: e }) => {
|
|
172
|
+
const { id: a, hidePlaceholder: n } = f(), { inputId: r } = T(d.YEAR), { isFirstPart: s } = F(d.YEAR), { t: o } = L(), i = U(null), m = n ? void 0 : o("field.date.placeholder.year");
|
|
173
|
+
return z(() => {
|
|
174
|
+
var c;
|
|
175
|
+
s && ((c = i.current) == null || c.focus());
|
|
176
|
+
}, a), /* @__PURE__ */ t.createElement(J, {
|
|
177
|
+
ref: i,
|
|
178
|
+
id: r,
|
|
179
|
+
className: e,
|
|
180
|
+
placeholder: m,
|
|
181
|
+
maxLength: 4,
|
|
182
|
+
inputMode: "numeric",
|
|
183
|
+
"data-hook": d.YEAR
|
|
184
|
+
});
|
|
185
|
+
};
|
|
186
|
+
V.Label = xe;
|
|
187
|
+
V.Input = Ue;
|
|
188
|
+
const I = ({ children: e, className: a }) => {
|
|
189
|
+
const { disabled: n, readOnly: r, use24HourFormat: s, showDateLabels: o } = f(), { labelId: i } = T("time"), { partValue: m, partError: c, onPartChange: b } = F("time"), p = u(e, I.Label), _ = u(e, I.Input);
|
|
190
|
+
return /* @__PURE__ */ t.createElement("div", {
|
|
191
|
+
className: a,
|
|
192
|
+
"data-date-field": !0
|
|
193
|
+
}, o && p, /* @__PURE__ */ t.createElement(de, {
|
|
194
|
+
"aria-labelledby": o ? i : void 0,
|
|
195
|
+
value: m,
|
|
196
|
+
onChange: b,
|
|
197
|
+
isDisabled: n,
|
|
198
|
+
isReadOnly: r,
|
|
199
|
+
isInvalid: c,
|
|
200
|
+
hourCycle: s ? 24 : 12
|
|
201
|
+
}, _));
|
|
202
|
+
}, $e = ({ className: e }) => {
|
|
203
|
+
const { inputId: a, labelId: n } = T("time"), { t: r } = L(), s = r("field.date.label.time");
|
|
204
|
+
return /* @__PURE__ */ t.createElement("label", {
|
|
205
|
+
id: n,
|
|
206
|
+
htmlFor: a,
|
|
207
|
+
className: e
|
|
208
|
+
}, s);
|
|
209
|
+
}, ze = ({ children: e, className: a }) => {
|
|
210
|
+
const { hidePlaceholder: n } = f(), r = u(e, I.Hour), s = u(e, I.Minute), o = u(e, I.Period);
|
|
211
|
+
return /* @__PURE__ */ t.createElement(pe, {
|
|
212
|
+
className: a,
|
|
213
|
+
"data-hook": "time",
|
|
214
|
+
"data-placeholder-hidden": n || void 0
|
|
215
|
+
}, (i) => {
|
|
216
|
+
switch (i.type) {
|
|
217
|
+
case "hour":
|
|
218
|
+
return P(r, {
|
|
219
|
+
segment: i
|
|
220
|
+
}) || /* @__PURE__ */ t.createElement(t.Fragment, null);
|
|
221
|
+
case "minute":
|
|
222
|
+
return P(s, {
|
|
223
|
+
segment: i
|
|
224
|
+
}) || /* @__PURE__ */ t.createElement(t.Fragment, null);
|
|
225
|
+
case "dayPeriod":
|
|
226
|
+
return P(o, {
|
|
227
|
+
segment: i
|
|
228
|
+
}) || /* @__PURE__ */ t.createElement(t.Fragment, null);
|
|
229
|
+
case "literal":
|
|
230
|
+
return /* @__PURE__ */ t.createElement(B, {
|
|
231
|
+
segment: i
|
|
232
|
+
});
|
|
233
|
+
default:
|
|
234
|
+
return /* @__PURE__ */ t.createElement(t.Fragment, null);
|
|
235
|
+
}
|
|
236
|
+
});
|
|
237
|
+
}, qe = ({ className: e, ...a }) => {
|
|
238
|
+
const { hidePlaceholder: n } = f(), { segment: r } = a, { t: s } = L(), o = n ? void 0 : s("field.date.placeholder.hour");
|
|
239
|
+
return /* @__PURE__ */ t.createElement(B, {
|
|
240
|
+
segment: r,
|
|
241
|
+
className: e,
|
|
242
|
+
...o && {
|
|
243
|
+
placeholder: o
|
|
244
|
+
}
|
|
245
|
+
});
|
|
246
|
+
}, Ge = ({ className: e, ...a }) => {
|
|
247
|
+
const { hidePlaceholder: n } = f(), { segment: r } = a, { t: s } = L(), o = n ? void 0 : s("field.date.placeholder.minute");
|
|
248
|
+
return /* @__PURE__ */ t.createElement(B, {
|
|
249
|
+
segment: r,
|
|
250
|
+
className: e,
|
|
251
|
+
...o && {
|
|
252
|
+
placeholder: o
|
|
253
|
+
}
|
|
254
|
+
});
|
|
255
|
+
}, Ke = ({ className: e, ...a }) => {
|
|
256
|
+
const { hidePlaceholder: n } = f(), { segment: r } = a, { t: s } = L(), o = oe(Ee), i = n ? void 0 : s("field.date.placeholder.period"), m = () => o == null ? void 0 : o.increment("dayPeriod");
|
|
257
|
+
return /* @__PURE__ */ t.createElement(B, {
|
|
258
|
+
segment: r,
|
|
259
|
+
className: e,
|
|
260
|
+
onClick: m,
|
|
261
|
+
...i && {
|
|
262
|
+
placeholder: i
|
|
263
|
+
}
|
|
264
|
+
});
|
|
265
|
+
};
|
|
266
|
+
I.Label = $e;
|
|
267
|
+
I.Input = ze;
|
|
268
|
+
I.Hour = qe;
|
|
269
|
+
I.Minute = Ge;
|
|
270
|
+
I.Period = Ke;
|
|
271
|
+
l.Label = Oe;
|
|
272
|
+
l.Month = C;
|
|
273
|
+
l.Day = A;
|
|
274
|
+
l.Year = V;
|
|
275
|
+
l.Time = I;
|
|
276
|
+
l.Description = ye;
|
|
277
|
+
l.Error = Te;
|
|
278
|
+
function T(e) {
|
|
279
|
+
const { inputId: a } = W();
|
|
280
|
+
return O(() => {
|
|
281
|
+
const n = e.toLowerCase();
|
|
282
|
+
return {
|
|
283
|
+
inputId: `${a}-${n}-input`,
|
|
284
|
+
labelId: `${a}-${n}-label`
|
|
285
|
+
};
|
|
286
|
+
}, [
|
|
287
|
+
a,
|
|
288
|
+
e
|
|
289
|
+
]);
|
|
290
|
+
}
|
|
291
|
+
function F(e) {
|
|
292
|
+
const { value: a, onChange: n, hasError: r = !1 } = f(), { regionalFormat: s } = $(), [o, i] = O(() => K(a ?? ""), [
|
|
293
|
+
a
|
|
294
|
+
]), m = O(() => fe(r, a ?? ""), [
|
|
295
|
+
a,
|
|
296
|
+
r
|
|
297
|
+
]), c = O(() => he(o), [
|
|
298
|
+
o
|
|
299
|
+
]), b = O(() => je(i), [
|
|
300
|
+
i
|
|
301
|
+
]), p = H((N) => {
|
|
302
|
+
const D = Qe(N), y = j(o, D);
|
|
303
|
+
n(y);
|
|
304
|
+
}, [
|
|
305
|
+
n,
|
|
306
|
+
o
|
|
307
|
+
]), _ = H((N) => {
|
|
308
|
+
const [, D] = K(a ?? ""), y = be(N, e, c), S = j(y, D);
|
|
309
|
+
n(S);
|
|
310
|
+
}, [
|
|
311
|
+
n,
|
|
312
|
+
a,
|
|
313
|
+
c,
|
|
314
|
+
e
|
|
315
|
+
]), M = O(() => e === "time" ? !1 : X(s).filter(Z).map((y) => y.toUpperCase())[0] === e, [
|
|
316
|
+
s,
|
|
317
|
+
e
|
|
318
|
+
]);
|
|
319
|
+
return e === "time" ? {
|
|
320
|
+
partValue: b,
|
|
321
|
+
partError: m.TIME,
|
|
322
|
+
onPartChange: p,
|
|
323
|
+
isFirstPart: !1
|
|
324
|
+
} : {
|
|
325
|
+
partValue: c[e] || "",
|
|
326
|
+
partError: m[e],
|
|
327
|
+
onPartChange: _,
|
|
328
|
+
isFirstPart: M
|
|
329
|
+
};
|
|
330
|
+
}
|
|
331
|
+
function q({ datePart: e, className: a }) {
|
|
332
|
+
const { inputId: n, labelId: r } = T(e), { t: s } = L(), o = `field.date.label.${e.toLowerCase()}`, i = s(o);
|
|
333
|
+
return /* @__PURE__ */ t.createElement("label", {
|
|
334
|
+
id: r,
|
|
335
|
+
htmlFor: n,
|
|
336
|
+
className: a
|
|
337
|
+
}, i);
|
|
338
|
+
}
|
|
339
|
+
function je(e) {
|
|
340
|
+
if (!e)
|
|
341
|
+
return null;
|
|
342
|
+
try {
|
|
343
|
+
return le(e);
|
|
344
|
+
} catch {
|
|
345
|
+
return null;
|
|
346
|
+
}
|
|
347
|
+
}
|
|
348
|
+
function Qe(e) {
|
|
349
|
+
if (!e)
|
|
350
|
+
return null;
|
|
351
|
+
const a = String(e.hour).padStart(2, "0"), n = String(e.minute).padStart(2, "0"), r = String(e.second).padStart(2, "0");
|
|
352
|
+
return [
|
|
353
|
+
a,
|
|
354
|
+
n,
|
|
355
|
+
r
|
|
356
|
+
].join(":");
|
|
357
|
+
}
|
|
358
|
+
const Je = "_fields_1meki_1", We = "_month_1meki_10", Xe = "_day_1meki_11", Ze = "_year_1meki_12", et = "_timeGroup_1meki_13", tt = "_dayInput_1meki_34", at = "_yearInput_1meki_35", nt = "_monthTrigger_1meki_39", rt = "_monthOption_1meki_59", st = "_time_1meki_13", ot = "_hour_1meki_78", lt = "_minute_1meki_79", it = "_period_1meki_80", E = {
|
|
359
|
+
fields: Je,
|
|
360
|
+
month: We,
|
|
361
|
+
day: Xe,
|
|
362
|
+
year: Ze,
|
|
363
|
+
timeGroup: et,
|
|
364
|
+
dayInput: tt,
|
|
365
|
+
yearInput: at,
|
|
366
|
+
monthTrigger: nt,
|
|
367
|
+
monthOption: rt,
|
|
368
|
+
time: st,
|
|
369
|
+
hour: ot,
|
|
370
|
+
minute: lt,
|
|
371
|
+
period: it
|
|
372
|
+
}, ct = ({ content: e, locale: a }) => /* @__PURE__ */ t.createElement(se, {
|
|
373
|
+
content: e,
|
|
374
|
+
locale: a
|
|
375
|
+
}), Mt = () => {
|
|
376
|
+
const e = Se(E.monthTrigger), a = Ae(E.monthOption, k), n = x(E.dayInput), r = x(E.yearInput), s = x(E.time);
|
|
377
|
+
return /* @__PURE__ */ t.createElement(l, {
|
|
378
|
+
className: E.fields
|
|
379
|
+
}, /* @__PURE__ */ t.createElement(l.Label, {
|
|
380
|
+
className: h(R, g.label)
|
|
381
|
+
}, /* @__PURE__ */ t.createElement(l.Label.Required, {
|
|
382
|
+
className: h(ge, g.requiredMark)
|
|
383
|
+
})), /* @__PURE__ */ t.createElement(l.Month, {
|
|
384
|
+
className: E.month
|
|
385
|
+
}, /* @__PURE__ */ t.createElement(l.Month.Label, {
|
|
386
|
+
className: h(R, g.label)
|
|
387
|
+
}), /* @__PURE__ */ t.createElement(l.Month.Trigger, {
|
|
388
|
+
className: e
|
|
389
|
+
}, /* @__PURE__ */ t.createElement(Ve, {
|
|
390
|
+
className: g.dropdownIcon
|
|
391
|
+
})), /* @__PURE__ */ t.createElement(l.Month.Options, {
|
|
392
|
+
className: h(Ie, g.selectPopover, g.dropdownPopover)
|
|
393
|
+
}, /* @__PURE__ */ t.createElement(l.Month.Options.Option, {
|
|
394
|
+
className: a
|
|
395
|
+
}))), /* @__PURE__ */ t.createElement(l.Day, {
|
|
396
|
+
className: E.day
|
|
397
|
+
}, /* @__PURE__ */ t.createElement(l.Day.Label, {
|
|
398
|
+
className: h(R, g.label)
|
|
399
|
+
}), /* @__PURE__ */ t.createElement(l.Day.Input, {
|
|
400
|
+
className: n
|
|
401
|
+
})), /* @__PURE__ */ t.createElement(l.Year, {
|
|
402
|
+
className: E.year
|
|
403
|
+
}, /* @__PURE__ */ t.createElement(l.Year.Label, {
|
|
404
|
+
className: h(R, g.label)
|
|
405
|
+
}), /* @__PURE__ */ t.createElement(l.Year.Input, {
|
|
406
|
+
className: r
|
|
407
|
+
})), /* @__PURE__ */ t.createElement(l.Time, {
|
|
408
|
+
className: E.timeGroup
|
|
409
|
+
}, /* @__PURE__ */ t.createElement(l.Time.Label, {
|
|
410
|
+
className: h(R, g.label)
|
|
411
|
+
}), /* @__PURE__ */ t.createElement(l.Time.Input, {
|
|
412
|
+
className: s
|
|
413
|
+
}, /* @__PURE__ */ t.createElement(l.Time.Hour, {
|
|
414
|
+
className: h(E.hour, k)
|
|
415
|
+
}), /* @__PURE__ */ t.createElement(l.Time.Minute, {
|
|
416
|
+
className: h(E.minute, k)
|
|
417
|
+
}), /* @__PURE__ */ t.createElement(l.Time.Period, {
|
|
418
|
+
className: h(E.period, k)
|
|
419
|
+
}))), /* @__PURE__ */ t.createElement(l.Error, {
|
|
420
|
+
className: h(Ne, g.error)
|
|
421
|
+
}, /* @__PURE__ */ t.createElement(ve, null), /* @__PURE__ */ t.createElement(l.Error.Text, null)), /* @__PURE__ */ t.createElement(l.Description, {
|
|
422
|
+
className: h(De, g.description)
|
|
423
|
+
}, ct));
|
|
424
|
+
};
|
|
425
|
+
export {
|
|
426
|
+
Mt as D
|
|
427
|
+
};
|
package/dist/component/{dext-checkbox-group-rac-Dir6tyvo.js → dext-checkbox-group-rac-8kR2EZfL.js}
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import o from "react";
|
|
2
|
-
import { bh as e, aj as t } from "./form-
|
|
3
|
-
import { C as p } from "./checkbox-group-field-rac-
|
|
2
|
+
import { bh as e, aj as t } from "./form-tScYihAT.js";
|
|
3
|
+
import { C as p } from "./checkbox-group-field-rac-Cj09BgU-.js";
|
|
4
4
|
import { D as s } from "./default-limits-D7qVv_Hv.js";
|
|
5
5
|
const C = () => {
|
|
6
6
|
const r = {
|
package/dist/component/{dext-radio-group-rac-Q2J5Hk5W.js → dext-radio-group-rac-CdSOS1sE.js}
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import r from "react";
|
|
2
|
-
import { bh as e, aj as t } from "./form-
|
|
3
|
-
import { R as p } from "./radio-group-field-rac-
|
|
2
|
+
import { bh as e, aj as t } from "./form-tScYihAT.js";
|
|
3
|
+
import { R as p } from "./radio-group-field-rac-Cp48ayde.js";
|
|
4
4
|
import { a } from "./default-limits-D7qVv_Hv.js";
|
|
5
5
|
const l = () => {
|
|
6
6
|
const o = {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import r from "react";
|
|
2
|
-
import { bh as e, aj as o } from "./form-
|
|
3
|
-
import { T as s } from "./tags-field-rac-
|
|
2
|
+
import { bh as e, aj as o } from "./form-tScYihAT.js";
|
|
3
|
+
import { T as s } from "./tags-field-rac-BO2-TOy4.js";
|
|
4
4
|
import { b as a } from "./default-limits-D7qVv_Hv.js";
|
|
5
5
|
const l = () => {
|
|
6
6
|
const t = {
|
|
@@ -3,19 +3,19 @@ import { RicosViewer as re } from "@wix/ricos/viewer";
|
|
|
3
3
|
import D from "classnames";
|
|
4
4
|
import { RadioGroup as se, RadioField as G, RadioButton as Y, TextField as ae, Group as le, Input as ie } from "react-aria-components";
|
|
5
5
|
import { debounce as ce } from "ts-debounce";
|
|
6
|
-
import { ax as Q, bh as L, be as B, br as ue, b9 as j, bj as me, I as pe, U as de, q as Ie, v as fe, p as Ce, r as Ee } from "./form-
|
|
6
|
+
import { ax as Q, bh as L, be as B, br as ue, b9 as j, bj as me, I as pe, U as de, q as Ie, v as fe, p as Ce, r as Ee } from "./form-tScYihAT.js";
|
|
7
7
|
import { f as E, a as y } from "./find-child-C60k4CxG.js";
|
|
8
8
|
import { a as W } from "./format-currency-BwShJ9vM.js";
|
|
9
|
-
import { D as he, E as Oe } from "./field-error-headless-
|
|
10
|
-
import { L as _e } from "./field-label-headless-
|
|
9
|
+
import { D as he, E as Oe } from "./field-error-headless-44vAUpwr.js";
|
|
10
|
+
import { L as _e } from "./field-label-headless-Cfo9v3VS.js";
|
|
11
11
|
import { a as be, b as ye } from "./numeric-input-utils-CuBMi4-a.js";
|
|
12
12
|
import { g as Ne } from "./payment-field-utils-DobiK5Xh.js";
|
|
13
13
|
import { u as ge } from "./use-synced-display-value-DcAxdn3M.js";
|
|
14
14
|
import { E as Fe } from "./error-icon-hZxQ6DEy.js";
|
|
15
15
|
import { s as v } from "./field-rac.module-BIBNQEOK.js";
|
|
16
16
|
import { o as De } from "./options-rac.module-_THNq6Qq.js";
|
|
17
|
-
import { u as ve } from "./use-element-state-class-name-
|
|
18
|
-
import { u as Se } from "./use-text-input-class-name-
|
|
17
|
+
import { u as ve } from "./use-element-state-class-name-BXqvGrEm.js";
|
|
18
|
+
import { u as Se } from "./use-text-input-class-name-DUHXnnCn.js";
|
|
19
19
|
function Re(e, t) {
|
|
20
20
|
return e.reduce((o, r) => (o[r[t]] = r, o), {});
|
|
21
21
|
}
|
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
import e, { useState as b, useCallback as g, useRef as k } from "react";
|
|
2
|
+
import { UNSAFE_PortalProvider as q } from "react-aria";
|
|
3
|
+
import { Select as M, SelectValue as j, ListBoxItem as H } from "react-aria-components";
|
|
4
|
+
import { bh as E, be as O, bj as U } from "./form-tScYihAT.js";
|
|
5
|
+
import { f as d, a as F } from "./find-child-C60k4CxG.js";
|
|
6
|
+
import { D as Y, E as z } from "./field-error-headless-44vAUpwr.js";
|
|
7
|
+
import { L as G } from "./field-label-headless-Cfo9v3VS.js";
|
|
8
|
+
import { E as J, S as K, N as Q } from "./non-modal-popover-D-u13tmp.js";
|
|
9
|
+
import { a as W } from "./use-dropdown-trigger-class-name-BjjdE7MT.js";
|
|
10
|
+
import { V as X } from "./use-dropdown-option-class-name-Bgp-eVle.js";
|
|
11
|
+
const r = ({ children: n }) => {
|
|
12
|
+
const { id: l, value: a, defaultValue: o, options: u = [], readOnly: s, onChange: t, placeholder: m, disabled: i, required: v, onBlur: L, onFocus: y, FieldLayout: C, hasError: D } = E(), [h, I] = b(!1), p = W(l), [P, S] = b(null), T = a && u.some((c) => (c.value ?? c.label) === a) ? a : o || null, { labelId: B } = O(), N = g((c) => {
|
|
13
|
+
s || t(typeof c == "string" ? c : null);
|
|
14
|
+
}, [
|
|
15
|
+
t,
|
|
16
|
+
s
|
|
17
|
+
]), V = g((c) => I(c && !i && !s), [
|
|
18
|
+
i,
|
|
19
|
+
s
|
|
20
|
+
]), R = d(n, r.Label), x = d(n, r.Trigger), w = d(n, r.Options), A = d(n, r.Description), _ = d(n, r.Error);
|
|
21
|
+
return /* @__PURE__ */ e.createElement(C, {
|
|
22
|
+
fieldId: l,
|
|
23
|
+
renderLabel: () => R,
|
|
24
|
+
renderInput: () => /* @__PURE__ */ e.createElement(e.Fragment, null, /* @__PURE__ */ e.createElement("div", {
|
|
25
|
+
ref: S,
|
|
26
|
+
style: {
|
|
27
|
+
display: "contents"
|
|
28
|
+
}
|
|
29
|
+
}), /* @__PURE__ */ e.createElement(q, {
|
|
30
|
+
getContainer: () => P
|
|
31
|
+
}, /* @__PURE__ */ e.createElement(M, {
|
|
32
|
+
"aria-labelledby": B,
|
|
33
|
+
value: T,
|
|
34
|
+
isOpen: p || h && !i && !s,
|
|
35
|
+
onOpenChange: p ? void 0 : V,
|
|
36
|
+
onChange: N,
|
|
37
|
+
isDisabled: i,
|
|
38
|
+
isInvalid: D,
|
|
39
|
+
isRequired: v,
|
|
40
|
+
placeholder: m || J,
|
|
41
|
+
onBlur: L,
|
|
42
|
+
onFocus: y
|
|
43
|
+
}, x, F(w, {
|
|
44
|
+
isForcedOpen: p
|
|
45
|
+
})))),
|
|
46
|
+
renderDescription: () => /* @__PURE__ */ e.createElement(e.Fragment, null, _, A)
|
|
47
|
+
});
|
|
48
|
+
}, Z = ({ children: n, className: l }) => {
|
|
49
|
+
const { inputId: a, ariaDescribedBy: o } = O(), { id: u, hasError: s, isLoading: t } = E(), m = k(null);
|
|
50
|
+
return U(() => {
|
|
51
|
+
var i;
|
|
52
|
+
(i = m.current) == null || i.focus();
|
|
53
|
+
}, u), /* @__PURE__ */ e.createElement(K, {
|
|
54
|
+
ref: m,
|
|
55
|
+
id: a,
|
|
56
|
+
"aria-describedby": o,
|
|
57
|
+
className: l,
|
|
58
|
+
"data-invalid": s || void 0,
|
|
59
|
+
"data-loading": t || void 0
|
|
60
|
+
}, /* @__PURE__ */ e.createElement(j, null), n);
|
|
61
|
+
}, f = ({ children: n, className: l, ...a }) => {
|
|
62
|
+
const { isForcedOpen: o } = a, { options: u = [] } = E(), s = d(n, f.Option);
|
|
63
|
+
return /* @__PURE__ */ e.createElement(Q, {
|
|
64
|
+
className: l,
|
|
65
|
+
containerPadding: 0,
|
|
66
|
+
offset: 0
|
|
67
|
+
}, /* @__PURE__ */ e.createElement(X, {
|
|
68
|
+
isForcedOpen: o,
|
|
69
|
+
autoFocus: o ? !1 : void 0
|
|
70
|
+
}, u.map((t) => F(s, {
|
|
71
|
+
key: t.value ?? t.label,
|
|
72
|
+
value: t.value ?? t.label,
|
|
73
|
+
label: t.label
|
|
74
|
+
}))));
|
|
75
|
+
}, $ = ({ className: n, ...l }) => {
|
|
76
|
+
const { value: a, label: o } = l;
|
|
77
|
+
return /* @__PURE__ */ e.createElement(H, {
|
|
78
|
+
className: n,
|
|
79
|
+
id: a,
|
|
80
|
+
textValue: o
|
|
81
|
+
}, o);
|
|
82
|
+
};
|
|
83
|
+
f.Option = $;
|
|
84
|
+
r.Label = G;
|
|
85
|
+
r.Trigger = Z;
|
|
86
|
+
r.Options = f;
|
|
87
|
+
r.Description = Y;
|
|
88
|
+
r.Error = z;
|
|
89
|
+
export {
|
|
90
|
+
r as D
|
|
91
|
+
};
|