@wix/form-elements 1.63.0 → 1.65.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-B1VVk_Ui.js → appointment-rac-0kUk8XQJ.js} +5 -5
- package/dist/component/{bookings-address-rac-IQeHFdHT.js → bookings-address-rac-BUM0wpw0.js} +1 -1
- package/dist/component/{bookings-email-rac-z26A790r.js → bookings-email-rac-BHlvupVS.js} +1 -1
- package/dist/component/{bookings-first-name-rac-Djf0GPP4.js → bookings-first-name-rac-Bwn6xv1U.js} +1 -1
- package/dist/component/{bookings-header-rac-CXOzAOpz.js → bookings-header-rac-BkRvQMi4.js} +1 -1
- package/dist/component/{bookings-last-name-rac-CbB8alM9.js → bookings-last-name-rac-DRTj4VdX.js} +1 -1
- package/dist/component/{bookings-login-bar-rac-CXrLx7Pn.js → bookings-login-bar-rac-D-2Bt7Kx.js} +5 -5
- package/dist/component/{bookings-phone-rac-DGYx7h5g.js → bookings-phone-rac-CTcHHpDr.js} +1 -1
- package/dist/component/{bookings-rich-text-rac-viJG57XF.js → bookings-rich-text-rac-n-w9iWII.js} +1 -1
- package/dist/component/{checkbox-field-rac-e-RAmupX.js → checkbox-field-rac-BamOJv3P.js} +43 -43
- package/dist/component/checkbox-group-field-headless-BmKJbEi0.js +210 -0
- package/dist/component/checkbox-group-field-rac-CC8qfj0Y.js +40 -0
- package/dist/component/{checkbox-group-rac-CDfDTWqz.js → checkbox-group-rac-CsrP7zD5.js} +1 -1
- package/dist/component/{checkbox-rac-BRBKYD_5.js → checkbox-rac-X6E-fJ8k.js} +1 -1
- package/dist/component/{contacts-address-rac-BtWWQi77.js → contacts-address-rac-oYnkIZ6m.js} +1 -1
- package/dist/component/{contacts-birthdate-rac-DaEUXJTf.js → contacts-birthdate-rac-B7p8LgYA.js} +1 -1
- package/dist/component/{contacts-company-rac-IgRyjtcM.js → contacts-company-rac-cjLRO5J-.js} +1 -1
- package/dist/component/{contacts-email-rac-BS1MDrMk.js → contacts-email-rac-BlJJSkGK.js} +1 -1
- package/dist/component/{contacts-first-name-rac-BAvXypDF.js → contacts-first-name-rac-Nl-MDndn.js} +1 -1
- package/dist/component/{contacts-last-name-rac-C289RYPl.js → contacts-last-name-rac-DhxAobRI.js} +1 -1
- package/dist/component/{contacts-phone-rac-DIpyskam.js → contacts-phone-rac-CZLWlH0T.js} +1 -1
- package/dist/component/{contacts-position-rac-nPeh3lKU.js → contacts-position-rac-DlKC0lCU.js} +1 -1
- package/dist/component/{contacts-subscribe-rac-Ci5OLk68.js → contacts-subscribe-rac-POSKh1Ta.js} +2 -2
- package/dist/component/{contacts-tax-id-rac-C4WB-SR0.js → contacts-tax-id-rac-uyBKxOJn.js} +1 -1
- package/dist/component/{date-availability-HHjPx4Uv.js → date-availability-DnFJD1aS.js} +1 -1
- package/dist/component/{date-input-field-rac-GFgFcpX2.js → date-input-field-rac-DojzGm-i.js} +22 -22
- package/dist/component/{date-input-rac-B9BUEIA-.js → date-input-rac-BaPKcAuU.js} +1 -1
- package/dist/component/{date-picker-field-rac-BfjYIIuY.js → date-picker-field-rac-C1rzJMV8.js} +24 -24
- package/dist/component/{date-picker-rac-Bd2UN0ZF.js → date-picker-rac-BHsOfkYn.js} +1 -1
- package/dist/component/{date-time-input-field-rac-CAXnxLQP.js → date-time-input-field-rac-B4jAAxU8.js} +32 -32
- package/dist/component/{date-time-input-rac-BuJ3Awlh.js → date-time-input-rac-XyL5z_ma.js} +1 -1
- package/dist/component/{dext-checkbox-group-rac-DKp4cBVa.js → dext-checkbox-group-rac-DzpdOP3i.js} +2 -2
- package/dist/component/{dext-checkbox-rac-BMu_k06A.js → dext-checkbox-rac-BUWkvW5s.js} +1 -1
- package/dist/component/{dext-date-picker-rac-L3sdldhT.js → dext-date-picker-rac-CR0PUoOn.js} +1 -1
- package/dist/component/{dext-date-time-input-rac-UmabFzDN.js → dext-date-time-input-rac-D3WhLSKK.js} +1 -1
- package/dist/component/{dext-dropdown-rac-DbjgYaG-.js → dext-dropdown-rac-BJ1UfAIM.js} +1 -1
- package/dist/component/{dext-email-rac-rNudrOOK.js → dext-email-rac-xk_5C79-.js} +1 -1
- package/dist/component/{dext-number-input-rac-hw1FTrJL.js → dext-number-input-rac-Cu1Sqoac.js} +1 -1
- package/dist/component/{dext-phone-rac-DrZ_Vwv2.js → dext-phone-rac-S34qxXwg.js} +1 -1
- package/dist/component/{dext-radio-group-rac-DAt2ax-I.js → dext-radio-group-rac-DXnAk_eU.js} +2 -2
- package/dist/component/{dext-rating-input-rac-BW2Ike11.js → dext-rating-input-rac-ewGpgB63.js} +1 -1
- package/dist/component/{dext-tags-rac-DDzwlKrR.js → dext-tags-rac-BApZKGqP.js} +2 -2
- package/dist/component/{dext-text-area-rac-D0xf4z3z.js → dext-text-area-rac-DBtuaiwM.js} +1 -1
- package/dist/component/{dext-text-input-rac-Da04OLmq.js → dext-text-input-rac-qI8VECmA.js} +1 -1
- package/dist/component/{dext-url-input-rac-B-g4xTqh.js → dext-url-input-rac-C6vzqNjn.js} +1 -1
- package/dist/component/donation-rac-BDVKvG4j.js +302 -0
- package/dist/component/{dropdown-field-headless-Js5TxdU4.js → dropdown-field-headless-DBl8vGed.js} +16 -16
- package/dist/component/{dropdown-field-rac-BDxcvX00.js → dropdown-field-rac-O6G7_kSn.js} +9 -9
- package/dist/component/{dropdown-rac-B5UHNzV-.js → dropdown-rac-BImZ5Jwe.js} +1 -1
- package/dist/component/{ecom-address-rac-0zm4bX37.js → ecom-address-rac-BU4XZ_Do.js} +1 -1
- package/dist/component/{ecom-subscription-checkbox-rac-DCXoI33l.js → ecom-subscription-checkbox-rac-DLzpoNYm.js} +3 -3
- package/dist/component/{email-input-field-rac-svf6hUHF.js → email-input-field-rac-Ui0p35z5.js} +45 -45
- package/dist/component/{events-repeater-rac-DMIqzuVK.js → events-repeater-rac-bPKOOOit.js} +49 -49
- package/dist/component/{events-rsvp-rac-B_YD4ckO.js → events-rsvp-rac-lsRBBfPQ.js} +3 -3
- package/dist/component/{field-error-headless-DTKnr5Zx.js → field-error-headless-D6iejMQP.js} +3 -3
- package/dist/component/{field-label-headless-DV4aNd5Y.js → field-label-headless-BWLfU3YB.js} +4 -4
- package/dist/component/field-rac.module-DnUIb9Oh.js +21 -0
- package/dist/component/{file-upload-rac-lGKJjG3m.js → file-upload-rac-DqKL8QQZ.js} +116 -116
- package/dist/component/{fixed-payment-rac-BVS6glii.js → fixed-payment-rac-BDtRB8w2.js} +14 -14
- package/dist/component/{form-DzjdnO7t.js → form-CtWkUmxc.js} +1563 -1556
- package/dist/component/form-element-classes-BSMjWijd.js +63 -0
- package/dist/component/form.css +1 -1
- package/dist/component/form.js +1 -1
- package/dist/component/{header-field-rac-tzBH-8Yh.js → header-field-rac-BLM8RCDY.js} +7 -7
- package/dist/component/{header-rac-6thQAvVF.js → header-rac-DViRwafg.js} +1 -1
- package/dist/component/image-choice-rac-D76t2y-b.js +141 -0
- package/dist/component/{index-Lnx0829a.js → index--iRBHLXJ.js} +4 -4
- package/dist/component/{index-DIP7KB8P.js → index-pEItT2oo.js} +2 -2
- package/dist/component/{isObjectLike-B_1KizZV.js → isObjectLike-968AHV2b.js} +1 -1
- package/dist/component/{multiline-address-field-rac-BY2SUp2d.js → multiline-address-field-rac-CObOc8KE.js} +82 -82
- package/dist/component/{multiline-address-rac-BL8Yp4F0.js → multiline-address-rac-1qVZkN41.js} +1 -1
- package/dist/component/{number-input-field-rac-x0yFmXbe.js → number-input-field-rac-CPQ3u0N7.js} +19 -19
- package/dist/component/{number-input-rac-pJXc2YsD.js → number-input-rac-Bq1UyUPZ.js} +1 -1
- package/dist/component/{password-rac-B4XCP64b.js → password-rac-BZPK1VkN.js} +15 -15
- package/dist/component/{payment-input-rac-CZdOAjK4.js → payment-input-rac-CQrV0WmN.js} +28 -28
- package/dist/component/{phone-input-field-rac-DO_V5Z_T.js → phone-input-field-rac-DzUE1-RF.js} +39 -39
- package/dist/component/{phone-rac-D16nLDjP.js → phone-rac-BovOZ7V5.js} +1 -1
- package/dist/component/{product-list-rac-DER8gVqy.js → product-list-rac-CeGm1_WN.js} +71 -71
- package/dist/component/quiz-radio-group-rac-Lw2thQqC.js +13 -0
- package/dist/component/{radio-group-field-rac-Dt2pU0VV.js → radio-group-field-rac-BSVmjEgZ.js} +8 -8
- package/dist/component/{radio-group-field-rac.module--sO0VqCA.js → radio-group-field-rac.module-Cb3mm0f2.js} +7 -7
- package/dist/component/{radio-group-rac-CqCmtkNQ.js → radio-group-rac-BHhOCSQ2.js} +1 -1
- package/dist/component/{rating-input-field-rac-xDrHHcL2.js → rating-input-field-rac-BvbBZZDO.js} +31 -31
- package/dist/component/{rating-input-rac-Bo5E9N87.js → rating-input-rac-DDe1EBpt.js} +1 -1
- package/dist/component/{rich-content-rac.module-CJXbNca9.js → rich-content-rac.module-BacYkzEv.js} +1 -1
- package/dist/component/{rich-text-field-rac-CkV0Z9F-.js → rich-text-field-rac-D1W0mUjr.js} +3 -3
- package/dist/component/{rich-text-rac-59DbKpXz.js → rich-text-rac-B-cOn0RU.js} +1 -1
- package/dist/component/{service-dropdown-rac-BLnflnUr.js → service-dropdown-rac-CebfMkGP.js} +41 -41
- package/dist/component/services-multi-choice-rac-C4bF1xhB.js +76 -0
- package/dist/component/{signature-rac-Bb5IaS28.js → signature-rac-DWWT65Ez.js} +48 -48
- package/dist/component/{submit-button-rac-Bjyi8sUA.js → submit-button-rac-_mgn4ChE.js} +6 -6
- package/dist/component/{tags-field-rac-C_VO3_69.js → tags-field-rac-7coCWj0y.js} +39 -39
- package/dist/component/{tags-rac-CKiutCWe.js → tags-rac-rgsn8Os0.js} +1 -1
- package/dist/component/{text-area-field-rac-Cg-vIhFe.js → text-area-field-rac-5lUQxnNM.js} +15 -15
- package/dist/component/{text-area-rac-tMFx38UD.js → text-area-rac-DpGOBzN3.js} +1 -1
- package/dist/component/{text-input-field-rac-CgN_2hOD.js → text-input-field-rac-CgWadDfM.js} +6 -6
- package/dist/component/{text-input-headless-CkhvKrFp.js → text-input-headless-fhxuPytc.js} +11 -11
- package/dist/component/{text-input-rac-BsyBgd3b.js → text-input-rac-kgWS3UUV.js} +1 -1
- package/dist/component/{time-input-rac-BxRVJtHE.js → time-input-rac-CuLUJcBH.js} +34 -34
- package/dist/component/{url-input-field-rac-B_1yVniS.js → url-input-field-rac-CAGHb2na.js} +22 -22
- package/dist/component/{url-input-rac-D8VrKYVe.js → url-input-rac-s5_SVi0h.js} +1 -1
- package/dist/component/{use-service-options-base-Ci9gIluo.js → use-service-options-base-CYAEJ75H.js} +6 -6
- package/dist/form.d.ts +3 -1
- package/package.json +2 -2
- package/dist/component/checkbox-group-field-headless-Cvia4lL6.js +0 -204
- package/dist/component/checkbox-group-field-rac-BXxk90dk.js +0 -33
- package/dist/component/donation-rac-gKeq72jg.js +0 -305
- package/dist/component/field-rac.module-DtugsLiL.js +0 -21
- package/dist/component/form-element-classes-Bi-nNM8q.js +0 -55
- package/dist/component/image-choice-rac-Dx1b-saW.js +0 -141
- package/dist/component/quiz-radio-group-rac-BgTmHHi4.js +0 -13
- package/dist/component/services-multi-choice-rac-C-bFjwx8.js +0 -76
|
@@ -1,141 +0,0 @@
|
|
|
1
|
-
import e, { useMemo as x, useCallback as w, useRef as v } from "react";
|
|
2
|
-
import { RicosViewer as M } from "@wix/ricos/viewer";
|
|
3
|
-
import E from "classnames";
|
|
4
|
-
import { CheckboxGroup as T, CheckboxField as k, CheckboxButton as B } from "react-aria-components";
|
|
5
|
-
import { ah as O, ae as q, ab as H, aj as P } from "./form-DzjdnO7t.js";
|
|
6
|
-
import { f as p, a as F } from "./find-child-C60k4CxG.js";
|
|
7
|
-
import { L as U, g as G } from "./field-label-headless-DV4aNd5Y.js";
|
|
8
|
-
import { D as V, E as j } from "./field-error-headless-DTKnr5Zx.js";
|
|
9
|
-
import { F as z } from "./fieldset-headless-CD3fds9J.js";
|
|
10
|
-
import { E as Q } from "./error-icon-hZxQ6DEy.js";
|
|
11
|
-
import { s as _ } from "./field-rac.module-DtugsLiL.js";
|
|
12
|
-
import { r as $, H as J, f as K, t as W, l as X, h as Y } from "./form-element-classes-Bi-nNM8q.js";
|
|
13
|
-
const t = ({ children: a }) => {
|
|
14
|
-
const { id: s, value: o, onChange: n, disabled: l, readOnly: i, required: r, onBlur: c, onFocus: m, hasError: u, FieldLayout: f } = O(), { inputId: g, labelId: b, ariaDescribedBy: L } = q(), h = p(a, t.Label), C = p(a, t.Options), D = p(a, t.Description), N = p(a, t.Error), A = x(() => o || [], [
|
|
15
|
-
o
|
|
16
|
-
]), S = w((y) => {
|
|
17
|
-
n == null || n(y);
|
|
18
|
-
}, [
|
|
19
|
-
n
|
|
20
|
-
]);
|
|
21
|
-
return /* @__PURE__ */ e.createElement(f, {
|
|
22
|
-
fieldId: s,
|
|
23
|
-
renderLabel: () => h,
|
|
24
|
-
renderInput: () => /* @__PURE__ */ e.createElement(z, {
|
|
25
|
-
id: g,
|
|
26
|
-
ariaLabelledBy: b,
|
|
27
|
-
ariaDescribedBy: L,
|
|
28
|
-
required: r,
|
|
29
|
-
onBlur: c,
|
|
30
|
-
onFocus: m
|
|
31
|
-
}, /* @__PURE__ */ e.createElement(T, {
|
|
32
|
-
"aria-labelledby": b,
|
|
33
|
-
value: A,
|
|
34
|
-
onChange: S,
|
|
35
|
-
isDisabled: l,
|
|
36
|
-
isReadOnly: i,
|
|
37
|
-
isRequired: r,
|
|
38
|
-
isInvalid: u
|
|
39
|
-
}, C)),
|
|
40
|
-
renderDescription: () => /* @__PURE__ */ e.createElement(e.Fragment, null, N, D)
|
|
41
|
-
});
|
|
42
|
-
}, R = ({ children: a, className: s }) => {
|
|
43
|
-
const { isMobile: o } = H(), { id: n, options: l, numberOfColumns: i } = O(), r = p(a, R.Option);
|
|
44
|
-
return /* @__PURE__ */ e.createElement("div", {
|
|
45
|
-
className: s,
|
|
46
|
-
"data-columns": o ? 1 : i
|
|
47
|
-
}, l == null ? void 0 : l.map((c, m) => F(r, {
|
|
48
|
-
key: c.id || c.label,
|
|
49
|
-
option: c,
|
|
50
|
-
isFirst: m === 0,
|
|
51
|
-
fieldId: n
|
|
52
|
-
})));
|
|
53
|
-
}, Z = ({ className: a }) => /* @__PURE__ */ e.createElement("div", {
|
|
54
|
-
"aria-hidden": "true",
|
|
55
|
-
className: a
|
|
56
|
-
}), ee = ({ className: a, ...s }) => {
|
|
57
|
-
var m, u;
|
|
58
|
-
const { option: o } = s, { choiceImageResize: n, choiceImageAlignment: l } = O(), i = (m = o.media) == null ? void 0 : m.image;
|
|
59
|
-
if (!i)
|
|
60
|
-
return null;
|
|
61
|
-
const r = G(i, i.width, i.height);
|
|
62
|
-
if (!r)
|
|
63
|
-
return null;
|
|
64
|
-
const c = ((u = o.media) == null ? void 0 : u.altText) || o.altText || i.altText || "";
|
|
65
|
-
return /* @__PURE__ */ e.createElement("img", {
|
|
66
|
-
className: a,
|
|
67
|
-
src: r,
|
|
68
|
-
alt: c,
|
|
69
|
-
"data-fit": n,
|
|
70
|
-
"data-alignment": l,
|
|
71
|
-
"data-hook": "image-choice-option-image"
|
|
72
|
-
});
|
|
73
|
-
}, te = ({ className: a, ...s }) => {
|
|
74
|
-
const { option: o } = s;
|
|
75
|
-
return !o.label || o.isLabelHidden ? null : /* @__PURE__ */ e.createElement("span", {
|
|
76
|
-
className: a
|
|
77
|
-
}, o.label);
|
|
78
|
-
}, d = ({ children: a, className: s, ...o }) => {
|
|
79
|
-
const { option: n, isFirst: l = !1, fieldId: i } = o, { disabled: r, readOnly: c, hasError: m } = O(), u = v(null);
|
|
80
|
-
P(() => {
|
|
81
|
-
var L;
|
|
82
|
-
l && ((L = u.current) == null || L.focus({
|
|
83
|
-
preventScroll: !0
|
|
84
|
-
}));
|
|
85
|
-
}, i);
|
|
86
|
-
const f = p(a, d.Input), g = p(a, d.Image), b = p(a, d.Label);
|
|
87
|
-
return /* @__PURE__ */ e.createElement(k, {
|
|
88
|
-
value: n.label,
|
|
89
|
-
isDisabled: r,
|
|
90
|
-
isReadOnly: c,
|
|
91
|
-
isInvalid: m
|
|
92
|
-
}, /* @__PURE__ */ e.createElement(B, {
|
|
93
|
-
ref: u,
|
|
94
|
-
"aria-label": n.isLabelHidden ? n.label : void 0,
|
|
95
|
-
className: s,
|
|
96
|
-
"data-hook": `image-choice-${n.label}`
|
|
97
|
-
}, f, F(g, {
|
|
98
|
-
option: n
|
|
99
|
-
}), F(b, {
|
|
100
|
-
option: n
|
|
101
|
-
})));
|
|
102
|
-
};
|
|
103
|
-
d.Input = Z;
|
|
104
|
-
d.Image = ee;
|
|
105
|
-
d.Label = te;
|
|
106
|
-
t.Label = U;
|
|
107
|
-
t.Options = R;
|
|
108
|
-
R.Option = d;
|
|
109
|
-
t.Description = V;
|
|
110
|
-
t.Error = j;
|
|
111
|
-
const ae = "_options_hwxpw_1", ne = "_optionInput_hwxpw_25", oe = "_option_hwxpw_1", se = "_optionLabel_hwxpw_105", ie = "_optionImage_hwxpw_136", I = {
|
|
112
|
-
options: ae,
|
|
113
|
-
optionInput: ne,
|
|
114
|
-
option: oe,
|
|
115
|
-
optionLabel: se,
|
|
116
|
-
optionImage: ie
|
|
117
|
-
}, le = ({ content: a, locale: s }) => /* @__PURE__ */ e.createElement(M, {
|
|
118
|
-
content: a,
|
|
119
|
-
locale: s
|
|
120
|
-
}), re = () => /* @__PURE__ */ e.createElement(t, null, /* @__PURE__ */ e.createElement(t.Label, {
|
|
121
|
-
className: E($, _.label)
|
|
122
|
-
}, /* @__PURE__ */ e.createElement(t.Label.Required, {
|
|
123
|
-
className: E(J, _.requiredMark)
|
|
124
|
-
})), /* @__PURE__ */ e.createElement(t.Options, {
|
|
125
|
-
className: I.options
|
|
126
|
-
}, /* @__PURE__ */ e.createElement(t.Options.Option, {
|
|
127
|
-
className: E(K, I.option)
|
|
128
|
-
}, /* @__PURE__ */ e.createElement(t.Options.Option.Input, {
|
|
129
|
-
className: I.optionInput
|
|
130
|
-
}), /* @__PURE__ */ e.createElement(t.Options.Option.Image, {
|
|
131
|
-
className: I.optionImage
|
|
132
|
-
}), /* @__PURE__ */ e.createElement(t.Options.Option.Label, {
|
|
133
|
-
className: E(W, I.optionLabel)
|
|
134
|
-
}))), /* @__PURE__ */ e.createElement(t.Error, {
|
|
135
|
-
className: E(X, _.error)
|
|
136
|
-
}, /* @__PURE__ */ e.createElement(Q, null), /* @__PURE__ */ e.createElement(t.Error.Text, null)), /* @__PURE__ */ e.createElement(t.Description, {
|
|
137
|
-
className: E(Y, _.description)
|
|
138
|
-
}, le)), ge = () => /* @__PURE__ */ e.createElement(re, null);
|
|
139
|
-
export {
|
|
140
|
-
ge as ImageChoiceRAC
|
|
141
|
-
};
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import _ from "react";
|
|
2
|
-
import { R } from "./radio-group-field-rac-Dt2pU0VV.js";
|
|
3
|
-
import { B as o, A as r, z as O } from "./form-element-classes-Bi-nNM8q.js";
|
|
4
|
-
const A = () => /* @__PURE__ */ _.createElement(R, {
|
|
5
|
-
classes: {
|
|
6
|
-
container: O,
|
|
7
|
-
label: r,
|
|
8
|
-
control: o
|
|
9
|
-
}
|
|
10
|
-
});
|
|
11
|
-
export {
|
|
12
|
-
A as QuizRadioGroupRAC
|
|
13
|
-
};
|
|
@@ -1,76 +0,0 @@
|
|
|
1
|
-
import e, { useEffect as _, useMemo as C } from "react";
|
|
2
|
-
import { RicosViewer as I } from "@wix/ricos/viewer";
|
|
3
|
-
import s from "classnames";
|
|
4
|
-
import { F as R, ah as F, h as d } from "./form-DzjdnO7t.js";
|
|
5
|
-
import { u as h } from "./use-service-options-base-Ci9gIluo.js";
|
|
6
|
-
import { C as i } from "./checkbox-group-field-headless-Cvia4lL6.js";
|
|
7
|
-
import { E as D } from "./error-icon-hZxQ6DEy.js";
|
|
8
|
-
import { s as n } from "./field-rac.module-DtugsLiL.js";
|
|
9
|
-
import { r as f, H as M, L as N, M as b, N as A, q as v, l as x, h as T } from "./form-element-classes-Bi-nNM8q.js";
|
|
10
|
-
import { o as L } from "./options-rac.module-KM-VT_KY.js";
|
|
11
|
-
const k = (o) => {
|
|
12
|
-
var S;
|
|
13
|
-
const { isLoading: r, options: a, isEmpty: c, shouldRender: E, setOptions: l, setIsEmpty: m, setHasInitialDataLoaded: p } = h({
|
|
14
|
-
fieldType: R.SERVICES_MULTI_CHOICE,
|
|
15
|
-
isEditor: o.isEditor
|
|
16
|
-
}), u = (S = o.options) == null ? void 0 : S.every((O) => O.label && O.id);
|
|
17
|
-
return _(() => {
|
|
18
|
-
if (u && o.options) {
|
|
19
|
-
l(o.options), m(o.options.length === 0), p(!0);
|
|
20
|
-
return;
|
|
21
|
-
}
|
|
22
|
-
}, [
|
|
23
|
-
u,
|
|
24
|
-
o.options,
|
|
25
|
-
l,
|
|
26
|
-
m,
|
|
27
|
-
p
|
|
28
|
-
]), {
|
|
29
|
-
isLoading: r,
|
|
30
|
-
options: a,
|
|
31
|
-
isEmpty: c,
|
|
32
|
-
shouldRender: E
|
|
33
|
-
};
|
|
34
|
-
}, t = ({ children: o }) => {
|
|
35
|
-
const r = F(), { options: a, isEmpty: c, shouldRender: E } = k(r), l = C(() => ({
|
|
36
|
-
...r,
|
|
37
|
-
options: a
|
|
38
|
-
}), [
|
|
39
|
-
r,
|
|
40
|
-
a
|
|
41
|
-
]);
|
|
42
|
-
return !r.isEditor && c || !E ? null : /* @__PURE__ */ e.createElement(d.Provider, {
|
|
43
|
-
value: {
|
|
44
|
-
v2: l
|
|
45
|
-
}
|
|
46
|
-
}, /* @__PURE__ */ e.createElement(i, null, o));
|
|
47
|
-
};
|
|
48
|
-
t.Label = i.Label;
|
|
49
|
-
t.Options = i.Options;
|
|
50
|
-
t.Description = i.Description;
|
|
51
|
-
t.Error = i.Error;
|
|
52
|
-
const P = ({ content: o, locale: r }) => /* @__PURE__ */ e.createElement(I, {
|
|
53
|
-
content: o,
|
|
54
|
-
locale: r
|
|
55
|
-
}), y = () => /* @__PURE__ */ e.createElement(t, null, /* @__PURE__ */ e.createElement(t.Label, {
|
|
56
|
-
className: s(f, n.label)
|
|
57
|
-
}, /* @__PURE__ */ e.createElement(t.Label.Required, {
|
|
58
|
-
className: s(M, n.requiredMark)
|
|
59
|
-
})), /* @__PURE__ */ e.createElement(t.Options, {
|
|
60
|
-
className: s(N, L.options)
|
|
61
|
-
}, /* @__PURE__ */ e.createElement(t.Options.Option, null, /* @__PURE__ */ e.createElement(t.Options.Option.Checkbox, {
|
|
62
|
-
className: n.checkbox
|
|
63
|
-
}, /* @__PURE__ */ e.createElement(t.Options.Option.Checkbox.Input, {
|
|
64
|
-
className: s(b, n.checkboxInput)
|
|
65
|
-
}), /* @__PURE__ */ e.createElement(t.Options.Option.Checkbox.Label, {
|
|
66
|
-
className: s(A, L.optionLabel)
|
|
67
|
-
})), /* @__PURE__ */ e.createElement(t.Options.Option.OtherInput, {
|
|
68
|
-
inputClassName: s(v, n.input)
|
|
69
|
-
}))), /* @__PURE__ */ e.createElement(t.Error, {
|
|
70
|
-
className: s(x, n.error)
|
|
71
|
-
}, /* @__PURE__ */ e.createElement(D, null), /* @__PURE__ */ e.createElement(t.Error.Text, null)), /* @__PURE__ */ e.createElement(t.Description, {
|
|
72
|
-
className: s(T, n.description)
|
|
73
|
-
}, P)), j = () => /* @__PURE__ */ e.createElement(y, null);
|
|
74
|
-
export {
|
|
75
|
-
j as ServicesMultiChoiceRAC
|
|
76
|
-
};
|