@wix/form-elements 1.159.0 → 1.161.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-CpiyUOXo.js → appointment-rac-BubC8I9X.js} +388 -381
- package/dist/component/{bookings-address-rac-BBEUV1t7.js → bookings-address-rac-BbwvVs86.js} +1 -1
- package/dist/component/{bookings-email-rac-DdfoeLFV.js → bookings-email-rac-C2HCkcfa.js} +1 -1
- package/dist/component/{bookings-first-name-rac-DH39yvQ-.js → bookings-first-name-rac-Uy7c5EBs.js} +1 -1
- package/dist/component/{bookings-header-rac-StLm7b4I.js → bookings-header-rac-nmwsWRjS.js} +1 -1
- package/dist/component/{bookings-last-name-rac-DHZMPMOO.js → bookings-last-name-rac-BAioQLCg.js} +1 -1
- package/dist/component/{bookings-login-bar-rac-DrHp1ojM.js → bookings-login-bar-rac-CO6vOBjG.js} +5 -5
- package/dist/component/{bookings-phone-rac-6aGjbavK.js → bookings-phone-rac-Cr16h-_R.js} +1 -1
- package/dist/component/{bookings-rich-text-rac-DBlGZUM5.js → bookings-rich-text-rac-CHLH3jd7.js} +1 -1
- package/dist/component/{checkbox-field-rac-Cna1Va1X.js → checkbox-field-rac-CMwmwFMD.js} +4 -4
- package/dist/component/{checkbox-group-field-headless-m_-10Mdx.js → checkbox-group-field-headless-BNs_S-nT.js} +50 -50
- package/dist/component/{checkbox-group-field-rac-BSCi5hmx.js → checkbox-group-field-rac-BA60EPAN.js} +12 -12
- package/dist/component/{checkbox-group-rac-BWYQZmAI.js → checkbox-group-rac-BJZ4Oer9.js} +1 -1
- package/dist/component/{checkbox-rac-BsUTfSUf.js → checkbox-rac-KsVlI6_V.js} +1 -1
- package/dist/component/{contacts-address-rac-DwCLW8rV.js → contacts-address-rac-CRYkz87z.js} +1 -1
- package/dist/component/{contacts-birthdate-rac-DnNgxbKb.js → contacts-birthdate-rac-BIz-1-ZX.js} +1 -1
- package/dist/component/{contacts-company-rac-BQqXzpNl.js → contacts-company-rac-B8G__j6I.js} +1 -1
- package/dist/component/{contacts-email-rac-BINnZzxp.js → contacts-email-rac-Dztkvp5i.js} +1 -1
- package/dist/component/{contacts-first-name-rac-DBWKFkIU.js → contacts-first-name-rac-CVSEWpLU.js} +1 -1
- package/dist/component/{contacts-last-name-rac-D_-qrF7I.js → contacts-last-name-rac-Blz4M5bk.js} +1 -1
- package/dist/component/{contacts-phone-rac-7n7JkSDr.js → contacts-phone-rac-CPCE5soY.js} +1 -1
- package/dist/component/{contacts-position-rac-DvXP8nvT.js → contacts-position-rac-Dd_kBjqG.js} +1 -1
- package/dist/component/{contacts-subscribe-rac-DnLnV5Gm.js → contacts-subscribe-rac-C6AlsP10.js} +1 -1
- package/dist/component/{contacts-tax-id-rac-BJVWhvYW.js → contacts-tax-id-rac-CQ1n29zI.js} +1 -1
- package/dist/component/{date-availability-Df807-eN.js → date-availability-DDj1j0z5.js} +1 -1
- package/dist/component/date-input-field-rac-D5r1n_ah.js +309 -0
- package/dist/component/{date-input-rac-CSB3MWHW.js → date-input-rac-Cyi5mU_P.js} +1 -1
- package/dist/component/{date-picker-field-rac-CySThPfz.js → date-picker-field-rac-CeG391Zo.js} +79 -79
- package/dist/component/{date-picker-rac-Fp8_pxtf.js → date-picker-rac-Ci9aHgav.js} +1 -1
- package/dist/component/date-time-input-field-rac-CrbYEbJJ.js +441 -0
- package/dist/component/{date-time-input-rac-wctMR4uM.js → date-time-input-rac-DDJLkqs0.js} +1 -1
- package/dist/component/{dext-checkbox-group-rac-erMPfwFL.js → dext-checkbox-group-rac-C3ftVHBA.js} +4 -4
- package/dist/component/{dext-checkbox-rac-DQSq9Lqd.js → dext-checkbox-rac-BGLYWn68.js} +1 -1
- package/dist/component/{dext-date-picker-rac-RCLcd1VV.js → dext-date-picker-rac-Cy9RlDlt.js} +1 -1
- package/dist/component/{dext-date-time-input-rac-DMolWzvy.js → dext-date-time-input-rac-88ZoTd5e.js} +1 -1
- package/dist/component/{dext-dropdown-rac-wQ2GJL4V.js → dext-dropdown-rac-CPxDUuk9.js} +1 -1
- package/dist/component/{dext-email-rac-BtymBVTW.js → dext-email-rac-BAvQwDPA.js} +1 -1
- package/dist/component/{dext-number-input-rac-DHPiK0Z3.js → dext-number-input-rac-D7HYQVKq.js} +1 -1
- package/dist/component/{dext-phone-rac-C58vHEEe.js → dext-phone-rac--FhcplSI.js} +1 -1
- package/dist/component/dext-radio-group-rac-DBz8iCKW.js +18 -0
- package/dist/component/{dext-rating-input-rac-DI0k3tVa.js → dext-rating-input-rac-Cv7nThfe.js} +1 -1
- package/dist/component/{dext-tags-rac-DmF6ctvQ.js → dext-tags-rac-CRUUc5dr.js} +2 -2
- package/dist/component/{dext-text-area-rac-Bv6ridbR.js → dext-text-area-rac-DQBQXV1L.js} +1 -1
- package/dist/component/{dext-text-input-rac-DoTAdUgU.js → dext-text-input-rac-4CpM581y.js} +1 -1
- package/dist/component/{dext-url-input-rac-BuoMS6g2.js → dext-url-input-rac-0C1jTEr9.js} +1 -1
- package/dist/component/{donation-rac-CjZalSgn.js → donation-rac-Cgt0ZE50.js} +79 -79
- package/dist/component/{dropdown-field-rac-By_fpqhx.js → dropdown-field-rac-DlGKR7pZ.js} +14 -14
- package/dist/component/{dropdown-rac-BnIEC4RX.js → dropdown-rac-CYFW_3x_.js} +1 -1
- package/dist/component/{ecom-address-rac-B6Usk1Ty.js → ecom-address-rac-CQfQHpXC.js} +1 -1
- package/dist/component/{ecom-subscription-checkbox-rac-B4B0wzlC.js → ecom-subscription-checkbox-rac-D2v2Upvz.js} +2 -2
- package/dist/component/{email-input-field-rac-Df3KI3_v.js → email-input-field-rac-CVw25yRo.js} +39 -39
- package/dist/component/{events-repeater-rac-B2iBk8lV.js → events-repeater-rac-BCVUcmFj.js} +25 -25
- package/dist/component/{events-rsvp-rac-xl_qCIh3.js → events-rsvp-rac-DwbqEr8z.js} +18 -18
- package/dist/component/{field-error-headless-DWc76YmY.js → field-error-headless-XnVcMmsL.js} +3 -3
- package/dist/component/{field-label-headless-DKBKqI2X.js → field-label-headless-BRTLT2Yt.js} +16 -16
- package/dist/component/{file-upload-rac-BVj4cRqe.js → file-upload-rac-Dkwg9Jk4.js} +118 -118
- package/dist/component/{fixed-payment-rac-BS1Hb4hg.js → fixed-payment-rac-ST98xAa2.js} +13 -13
- package/dist/component/{form-BTUoOcqB.js → form-BUqSKOvc.js} +785 -727
- package/dist/component/form.js +1 -1
- package/dist/component/{header-field-rac-DTJ_Us6u.js → header-field-rac-CzNTGYWq.js} +6 -6
- package/dist/component/{header-rac-CvYp0Jjo.js → header-rac-DUt6AIAE.js} +1 -1
- package/dist/component/{image-choice-rac--qrYqKJl.js → image-choice-rac-DuBgrSt2.js} +23 -23
- package/dist/component/{index-DIl9BH2M.js → index-CDO22hht.js} +66 -66
- package/dist/component/{index-CoEV4QEy.js → index-cZZeAuuu.js} +2 -2
- package/dist/component/{isObjectLike-CLN09X5V.js → isObjectLike-cs4bARpC.js} +11 -11
- package/dist/component/multiline-address-field-rac-vcEWhUCV.js +1664 -0
- package/dist/component/{multiline-address-rac-DtaAJjbR.js → multiline-address-rac-WQaI2eUX.js} +1 -1
- package/dist/component/{number-input-field-rac-2gqDUlw9.js → number-input-field-rac-CBUMqATk.js} +23 -23
- package/dist/component/{number-input-rac-BlciEPLN.js → number-input-rac-B4j5hyzS.js} +1 -1
- package/dist/component/{password-rac-BvvQgafk.js → password-rac-DwLyf45N.js} +27 -27
- package/dist/component/{payment-input-rac-CSRyOPPr.js → payment-input-rac-D0Od---y.js} +31 -31
- package/dist/component/phone-input-field-rac-COlu9IeC.js +512 -0
- package/dist/component/{phone-rac-DMP1MoRs.js → phone-rac-Dh4RacOF.js} +1 -1
- package/dist/component/{product-list-rac-WQ9Qhzum.js → product-list-rac-D7zHDE2D.js} +39 -39
- package/dist/component/{quiz-radio-group-rac-DzrL3-gZ.js → quiz-radio-group-rac-1AaKphJt.js} +1 -1
- package/dist/component/{radio-button-module-classes-CJk18LzO.js → radio-button-module-classes-VqaP6vpA.js} +30 -30
- package/dist/component/{radio-group-field-rac-DGoMoSgo.js → radio-group-field-rac-Cp3LRN3C.js} +8 -8
- package/dist/component/{radio-group-rac-DhAELVNV.js → radio-group-rac-KhmhzYGf.js} +1 -1
- package/dist/component/{rating-input-field-rac-CFoesqmC.js → rating-input-field-rac-10n6ciCr.js} +39 -39
- package/dist/component/{rating-input-rac-CFMIxche.js → rating-input-rac-XZjjY2Gp.js} +1 -1
- package/dist/component/{rich-content-rac.module-xJ03MegT.js → rich-content-rac.module-kMwDoLBa.js} +8 -8
- package/dist/component/{rich-text-field-rac-CBMY4JOB.js → rich-text-field-rac-H5bd8fAt.js} +4 -4
- package/dist/component/{rich-text-rac-CvZ7s1Ct.js → rich-text-rac-88GSQR62.js} +1 -1
- package/dist/component/service-dropdown-rac-B1_Xr_X3.js +145 -0
- package/dist/component/{services-multi-choice-rac-fXOov4K7.js → services-multi-choice-rac-DWp_Llbi.js} +11 -11
- package/dist/component/{signature-rac-CG_Q9Oxr.js → signature-rac-zN_6KRDp.js} +82 -82
- package/dist/component/{submit-button-rac-DAsovEp2.js → submit-button-rac-Dv6UarYX.js} +12 -12
- package/dist/component/{tags-field-rac-9mpOMPLm.js → tags-field-rac-sVN6MHfJ.js} +43 -43
- package/dist/component/{tags-rac-CNBJ08wS.js → tags-rac-DhTHs_XN.js} +1 -1
- package/dist/component/{text-area-field-rac-D4aTm7CM.js → text-area-field-rac-DrWkww7W.js} +19 -19
- package/dist/component/{text-area-rac-DoKiH_Kv.js → text-area-rac-CXXh-ZdY.js} +1 -1
- package/dist/component/{text-input-field-rac-BbvPB26b.js → text-input-field-rac-C2YiMr-g.js} +5 -5
- package/dist/component/text-input-headless-BJMNbsMY.js +47 -0
- package/dist/component/{text-input-rac-1ac1EKad.js → text-input-rac-CpsPh7FH.js} +1 -1
- package/dist/component/{time-input-rac-BS0rR-89.js → time-input-rac-DG_1KxS4.js} +20 -20
- package/dist/component/{url-input-field-rac-DbO6ATng.js → url-input-field-rac-twxRREnl.js} +19 -19
- package/dist/component/{url-input-rac-DHuny3d-.js → url-input-rac-BTStO0NP.js} +1 -1
- package/dist/component/use-dropdown-option-class-name-DbMMg1ws.js +116 -0
- package/dist/component/use-dropdown-trigger-class-name-Yes4kC_0.js +96 -0
- package/dist/component/{use-element-state-class-name-BUsFQfoW.js → use-element-state-class-name-DlncY4hk.js} +1 -1
- package/dist/component/{use-hoverable-input-class-name-C2l3G8gb.js → use-hoverable-input-class-name-C__zqP5j.js} +2 -2
- package/dist/component/use-is-forced-open-dropdown-DnK_MQRO.js +53 -0
- package/dist/component/{use-service-options-base-D_enm38a.js → use-service-options-base-DKJe52Vk.js} +6 -6
- package/dist/component/use-text-input-class-name-D9tJTR-b.js +6 -0
- package/dist/form.d.ts +11 -0
- package/package.json +2 -2
- package/dist/component/date-input-field-rac-CEuPElMH.js +0 -303
- package/dist/component/date-time-input-field-rac-DG5KSBHe.js +0 -433
- package/dist/component/dext-radio-group-rac-Cp-I94HW.js +0 -18
- package/dist/component/dropdown-field-headless-BYEjiIUf.js +0 -93
- package/dist/component/multiline-address-field-rac-BjWzx-LH.js +0 -1659
- package/dist/component/phone-input-field-rac-BVWzH_TY.js +0 -508
- package/dist/component/service-dropdown-rac-B627AgPG.js +0 -145
- package/dist/component/text-input-headless-BGaBRrP1.js +0 -47
- package/dist/component/use-dropdown-trigger-class-name-rcGBzxI1.js +0 -117
- package/dist/component/use-is-forced-open-dropdown-CoOk4W4i.js +0 -48
- package/dist/component/use-text-input-class-name-BLtPQoYE.js +0 -6
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import t, { useMemo as
|
|
2
|
-
import { RicosViewer as
|
|
1
|
+
import t, { useMemo as G, useCallback as v, useRef as U } from "react";
|
|
2
|
+
import { RicosViewer as H } from "@wix/ricos/viewer";
|
|
3
3
|
import b from "classnames";
|
|
4
|
-
import { CheckboxField as
|
|
5
|
-
import {
|
|
4
|
+
import { CheckboxField as $, CheckboxButton as z, NumberField as W, Group as X, Button as Q, Input as Y } from "react-aria-components";
|
|
5
|
+
import { bA as x, bx as J, bs as w, bK as Z, bC as ee, W as te, ac as ne, a2 as ae, a5 as oe, a4 as re, a6 as le, M as se, G as ie, a3 as ce } from "./form-BUqSKOvc.js";
|
|
6
6
|
import { f as I, a as f } from "./find-child-C60k4CxG.js";
|
|
7
|
-
import { L as ue, g as me } from "./field-label-headless-
|
|
7
|
+
import { L as ue, g as me } from "./field-label-headless-BRTLT2Yt.js";
|
|
8
8
|
import { f as pe } from "./format-currency-BwShJ9vM.js";
|
|
9
|
-
import { D as de, E as Ee } from "./field-error-headless-
|
|
9
|
+
import { D as de, E as Ee } from "./field-error-headless-XnVcMmsL.js";
|
|
10
10
|
import { F as ye } from "./fieldset-headless-CD3fds9J.js";
|
|
11
11
|
import { g as _e } from "./payment-field-utils-DobiK5Xh.js";
|
|
12
12
|
import { S as be } from "./selection-indicator-XQ8MYHUQ.js";
|
|
@@ -14,7 +14,7 @@ import { E as fe } from "./error-icon-hZxQ6DEy.js";
|
|
|
14
14
|
import { C as Ie } from "./checkbox-indicator-module-classes-akWZsZNn.js";
|
|
15
15
|
import { s as q } from "./field-rac.module-DP0lkkEv.js";
|
|
16
16
|
import { o as j } from "./options-rac.module-_THNq6Qq.js";
|
|
17
|
-
import { u as Oe } from "./use-element-state-class-name-
|
|
17
|
+
import { u as Oe } from "./use-element-state-class-name-DlncY4hk.js";
|
|
18
18
|
var Le = /* @__PURE__ */ (function(e) {
|
|
19
19
|
return e.crop = "CROP", e.fit = "FIT", e;
|
|
20
20
|
})({}), k = /* @__PURE__ */ (function(e) {
|
|
@@ -28,10 +28,10 @@ function Ce({ maxItems: e, products: a } = {}) {
|
|
|
28
28
|
}
|
|
29
29
|
const o = ({ children: e }) => {
|
|
30
30
|
var D;
|
|
31
|
-
const { id: a, value: l, onChange: n, disabled: r, readOnly: c, required: y, onBlur: O, onFocus: s, hasError: u, validation: m, FieldLayout: p } =
|
|
31
|
+
const { id: a, value: l, onChange: n, disabled: r, readOnly: c, required: y, onBlur: O, onFocus: s, hasError: u, validation: m, FieldLayout: p } = x(), { inputId: M, labelId: N, ariaDescribedBy: h } = J(), _ = I(e, o.Label), g = I(e, o.Options), A = I(e, o.Description), L = I(e, o.Error), i = G(() => l || [], [
|
|
32
32
|
l
|
|
33
|
-
]),
|
|
34
|
-
const d = i.filter((
|
|
33
|
+
]), T = Ce((D = m == null ? void 0 : m.predefined) == null ? void 0 : D.paymentOptions) === k.many, F = v((S, R) => {
|
|
34
|
+
const d = i.filter((K) => K.productId !== S.productId), B = R ? [
|
|
35
35
|
...d,
|
|
36
36
|
S
|
|
37
37
|
] : d;
|
|
@@ -44,33 +44,33 @@ const o = ({ children: e }) => {
|
|
|
44
44
|
fieldId: a,
|
|
45
45
|
renderLabel: () => _,
|
|
46
46
|
renderInput: () => /* @__PURE__ */ t.createElement(ye, {
|
|
47
|
-
id:
|
|
47
|
+
id: M,
|
|
48
48
|
ariaLabelledBy: N,
|
|
49
49
|
ariaDescribedBy: h,
|
|
50
50
|
required: y,
|
|
51
51
|
onBlur: O,
|
|
52
52
|
onFocus: s
|
|
53
53
|
}, g ? f(g, {
|
|
54
|
-
allowMany:
|
|
54
|
+
allowMany: T,
|
|
55
55
|
productValues: i,
|
|
56
56
|
onProductChange: F,
|
|
57
57
|
disabled: r,
|
|
58
58
|
readOnly: c,
|
|
59
59
|
hasError: u
|
|
60
60
|
}) : null),
|
|
61
|
-
renderDescription: () => /* @__PURE__ */ t.createElement(t.Fragment, null, L,
|
|
61
|
+
renderDescription: () => /* @__PURE__ */ t.createElement(t.Fragment, null, L, A)
|
|
62
62
|
});
|
|
63
|
-
},
|
|
64
|
-
const { allowMany: n, productValues: r, onProductChange: c, disabled: y, readOnly: O, hasError: s } = l, { options: u, validation: m, imageResize: p } =
|
|
63
|
+
}, V = ({ children: e, className: a, ...l }) => {
|
|
64
|
+
const { allowMany: n, productValues: r, onProductChange: c, disabled: y, readOnly: O, hasError: s } = l, { options: u, validation: m, imageResize: p } = x(), { currency: M } = w(), { t: N } = Z(), h = I(e, o.Option);
|
|
65
65
|
return /* @__PURE__ */ t.createElement("div", {
|
|
66
66
|
className: a
|
|
67
67
|
}, u == null ? void 0 : u.map((_, g) => {
|
|
68
|
-
var C,
|
|
69
|
-
const
|
|
68
|
+
var C, T, F, D, S;
|
|
69
|
+
const A = ((S = (D = (F = (T = (C = m == null ? void 0 : m.predefined) == null ? void 0 : C.paymentOptions) == null ? void 0 : T.products) == null ? void 0 : F.find((R) => R.id === _.value)) == null ? void 0 : D.fixedPriceOptions) == null ? void 0 : S.price) || "0", L = _e(N, M), i = r.find((R) => R.productId === _.value);
|
|
70
70
|
return f(h, {
|
|
71
71
|
key: _.id || _.value || _.label,
|
|
72
72
|
option: _,
|
|
73
|
-
price:
|
|
73
|
+
price: A,
|
|
74
74
|
quantity: i == null ? void 0 : i.quantity,
|
|
75
75
|
isSelected: !!i,
|
|
76
76
|
allowMany: n,
|
|
@@ -84,14 +84,14 @@ const o = ({ children: e }) => {
|
|
|
84
84
|
});
|
|
85
85
|
}));
|
|
86
86
|
}, E = ({ children: e, className: a, ...l }) => {
|
|
87
|
-
const { option: n, price: r, quantity: c = 0, isSelected: y, allowMany: O, onProductChange: s, disabled: u, readOnly: m, hasError: p, currencyAriaLabel:
|
|
87
|
+
const { option: n, price: r, quantity: c = 0, isSelected: y, allowMany: O, onProductChange: s, disabled: u, readOnly: m, hasError: p, currencyAriaLabel: M, imageResize: N, isFirst: h } = l, { id: _ } = x(), g = U(null), A = U(null), L = I(e, E.Image), i = I(e, E.Label), C = I(e, E.Price), T = I(e, E.Input), F = I(e, E.Quantity);
|
|
88
88
|
ee(() => {
|
|
89
89
|
var d;
|
|
90
|
-
h && ((d = g.current ??
|
|
90
|
+
h && ((d = g.current ?? A.current) == null || d.focus({
|
|
91
91
|
preventScroll: !0
|
|
92
92
|
}));
|
|
93
93
|
}, _);
|
|
94
|
-
const D =
|
|
94
|
+
const D = v((d) => {
|
|
95
95
|
s({
|
|
96
96
|
productId: n.value,
|
|
97
97
|
price: r,
|
|
@@ -101,7 +101,7 @@ const o = ({ children: e }) => {
|
|
|
101
101
|
s,
|
|
102
102
|
n.value,
|
|
103
103
|
r
|
|
104
|
-
]), S =
|
|
104
|
+
]), S = v((d) => {
|
|
105
105
|
s({
|
|
106
106
|
productId: n.value,
|
|
107
107
|
price: r,
|
|
@@ -111,7 +111,7 @@ const o = ({ children: e }) => {
|
|
|
111
111
|
s,
|
|
112
112
|
n.value,
|
|
113
113
|
r
|
|
114
|
-
]), R = `${n.label} ${
|
|
114
|
+
]), R = `${n.label} ${M} ${r}`;
|
|
115
115
|
return O ? /* @__PURE__ */ t.createElement("div", {
|
|
116
116
|
className: a,
|
|
117
117
|
"data-hook": "product"
|
|
@@ -129,15 +129,15 @@ const o = ({ children: e }) => {
|
|
|
129
129
|
readOnly: m,
|
|
130
130
|
hasError: p,
|
|
131
131
|
ariaLabel: R,
|
|
132
|
-
inputRef: h ?
|
|
133
|
-
}) : null) : /* @__PURE__ */ t.createElement(
|
|
132
|
+
inputRef: h ? A : void 0
|
|
133
|
+
}) : null) : /* @__PURE__ */ t.createElement($, {
|
|
134
134
|
isSelected: y,
|
|
135
135
|
onChange: D,
|
|
136
136
|
isDisabled: u,
|
|
137
137
|
isReadOnly: m,
|
|
138
138
|
isInvalid: p,
|
|
139
139
|
"aria-label": R
|
|
140
|
-
}, /* @__PURE__ */ t.createElement(
|
|
140
|
+
}, /* @__PURE__ */ t.createElement(z, {
|
|
141
141
|
ref: g,
|
|
142
142
|
className: a,
|
|
143
143
|
"data-hook": "product"
|
|
@@ -148,7 +148,7 @@ const o = ({ children: e }) => {
|
|
|
148
148
|
label: n.label
|
|
149
149
|
}) : null, C ? f(C, {
|
|
150
150
|
price: r
|
|
151
|
-
}) : null, f(
|
|
151
|
+
}) : null, f(T, {
|
|
152
152
|
isSelected: y,
|
|
153
153
|
isHovered: d,
|
|
154
154
|
isFocused: B
|
|
@@ -176,7 +176,7 @@ const o = ({ children: e }) => {
|
|
|
176
176
|
"data-hook": "product-label"
|
|
177
177
|
}, l || "");
|
|
178
178
|
}, Fe = ({ className: e, ...a }) => {
|
|
179
|
-
const { price: l } = a, { currency: n, regionalFormat: r } =
|
|
179
|
+
const { price: l } = a, { currency: n, regionalFormat: r } = w(), c = pe({
|
|
180
180
|
amount: l,
|
|
181
181
|
currency: n == null ? void 0 : n.code,
|
|
182
182
|
locale: r
|
|
@@ -186,11 +186,11 @@ const o = ({ children: e }) => {
|
|
|
186
186
|
"data-hook": "product-price"
|
|
187
187
|
}, c);
|
|
188
188
|
}, De = ({ className: e, ...a }) => {
|
|
189
|
-
const { quantity: l, onQuantityChange: n, disabled: r, readOnly: c, hasError: y, ariaLabel: O, inputRef: s } = a, u =
|
|
189
|
+
const { quantity: l, onQuantityChange: n, disabled: r, readOnly: c, hasError: y, ariaLabel: O, inputRef: s } = a, u = v((p) => {
|
|
190
190
|
n(p < 0 ? 0 : p);
|
|
191
191
|
}, [
|
|
192
192
|
n
|
|
193
|
-
]), m =
|
|
193
|
+
]), m = v((p) => {
|
|
194
194
|
p.key === "Home" && (p.preventDefault(), u(0));
|
|
195
195
|
}, [
|
|
196
196
|
u
|
|
@@ -221,24 +221,24 @@ E.Label = ge;
|
|
|
221
221
|
E.Price = Fe;
|
|
222
222
|
E.Input = be;
|
|
223
223
|
E.Quantity = De;
|
|
224
|
-
|
|
224
|
+
V.Option = E;
|
|
225
225
|
o.Label = ue;
|
|
226
|
-
o.Options =
|
|
226
|
+
o.Options = V;
|
|
227
227
|
o.Option = E;
|
|
228
228
|
o.Description = de;
|
|
229
229
|
o.Error = Ee;
|
|
230
|
-
const Se = "_options_1jnru_1", Pe = "_option_1jnru_1", Ne = "_optionInput_1jnru_21", he = "_optionImage_1jnru_32",
|
|
230
|
+
const Se = "_options_1jnru_1", Pe = "_option_1jnru_1", Ne = "_optionInput_1jnru_21", he = "_optionImage_1jnru_32", Ae = "_optionLabel_1jnru_66", Te = "_optionPrice_1jnru_73", qe = "_quantity_1jnru_87", P = {
|
|
231
231
|
options: Se,
|
|
232
232
|
option: Pe,
|
|
233
233
|
optionInput: Ne,
|
|
234
234
|
optionImage: he,
|
|
235
|
-
optionLabel:
|
|
236
|
-
optionPrice:
|
|
235
|
+
optionLabel: Ae,
|
|
236
|
+
optionPrice: Te,
|
|
237
237
|
quantity: qe
|
|
238
|
-
},
|
|
238
|
+
}, Me = ({ content: e, locale: a }) => /* @__PURE__ */ t.createElement(H, {
|
|
239
239
|
content: e,
|
|
240
240
|
locale: a
|
|
241
|
-
}),
|
|
241
|
+
}), ve = () => {
|
|
242
242
|
const e = Oe({
|
|
243
243
|
globalClasses: ce,
|
|
244
244
|
moduleClasses: Ie
|
|
@@ -265,8 +265,8 @@ const Se = "_options_1jnru_1", Pe = "_option_1jnru_1", Ne = "_optionInput_1jnru_
|
|
|
265
265
|
className: b(se, q.error)
|
|
266
266
|
}, /* @__PURE__ */ t.createElement(fe, null), /* @__PURE__ */ t.createElement(o.Error.Text, null)), /* @__PURE__ */ t.createElement(o.Description, {
|
|
267
267
|
className: b(ie, q.description)
|
|
268
|
-
},
|
|
269
|
-
}, Ze = () => /* @__PURE__ */ t.createElement(
|
|
268
|
+
}, Me));
|
|
269
|
+
}, Ze = () => /* @__PURE__ */ t.createElement(ve, null);
|
|
270
270
|
export {
|
|
271
271
|
Ze as ProductListRAC
|
|
272
272
|
};
|
|
@@ -1,25 +1,25 @@
|
|
|
1
1
|
import a, { useRef as F, useState as T, useEffect as B, useCallback as H } from "react";
|
|
2
|
-
import { RadioGroup as
|
|
3
|
-
import {
|
|
2
|
+
import { RadioGroup as A, RadioField as k, RadioButton as x, TextField as G, Input as P } from "react-aria-components";
|
|
3
|
+
import { bA as g, bx as $, bK as D, bC as q } from "./form-BUqSKOvc.js";
|
|
4
4
|
import { f as u, a as L } from "./find-child-C60k4CxG.js";
|
|
5
|
-
import { D as U, E as
|
|
6
|
-
import { L as
|
|
7
|
-
import { S as
|
|
8
|
-
const v = "Other",
|
|
5
|
+
import { D as U, E as K } from "./field-error-headless-XnVcMmsL.js";
|
|
6
|
+
import { L as M } from "./field-label-headless-BRTLT2Yt.js";
|
|
7
|
+
import { S as j } from "./selection-indicator-XQ8MYHUQ.js";
|
|
8
|
+
const v = "Other", w = (e, t) => e == null ? void 0 : e.find((n) => (n.value ?? n.label) === t), y = (e, t) => !!t && !w(e, t), z = (e, t) => {
|
|
9
9
|
const l = t ? t.length + 2 : 0;
|
|
10
10
|
return e.slice(l);
|
|
11
11
|
}, i = ({ children: e, className: t }) => {
|
|
12
|
-
const { id: n, value: l, onChange: h, disabled: p, readOnly: O, required: m, onBlur: E, onFocus: b, hasError: r, FieldLayout: c, options: o } = g(), { inputId: f, labelId:
|
|
12
|
+
const { id: n, value: l, onChange: h, disabled: p, readOnly: O, required: m, onBlur: E, onFocus: b, hasError: r, FieldLayout: c, options: o } = g(), { inputId: f, labelId: I, ariaDescribedBy: C } = $(), s = u(e, i.Label), _ = u(e, i.Options), R = u(e, i.Description), N = u(e, i.Error), V = y(o, l) ? v : l || null;
|
|
13
13
|
return /* @__PURE__ */ a.createElement(c, {
|
|
14
14
|
fieldId: n,
|
|
15
15
|
renderLabel: () => L(s, {
|
|
16
16
|
as: "div"
|
|
17
17
|
}),
|
|
18
|
-
renderInput: () => /* @__PURE__ */ a.createElement(
|
|
18
|
+
renderInput: () => /* @__PURE__ */ a.createElement(A, {
|
|
19
19
|
id: f,
|
|
20
20
|
className: t,
|
|
21
|
-
"aria-labelledby":
|
|
22
|
-
"aria-describedby":
|
|
21
|
+
"aria-labelledby": I,
|
|
22
|
+
"aria-describedby": C,
|
|
23
23
|
value: V,
|
|
24
24
|
onChange: h,
|
|
25
25
|
isDisabled: p,
|
|
@@ -31,9 +31,9 @@ const v = "Other", z = (e, t) => e == null ? void 0 : e.find((n) => (n.value ??
|
|
|
31
31
|
}, _),
|
|
32
32
|
renderDescription: () => /* @__PURE__ */ a.createElement(a.Fragment, null, N, R)
|
|
33
33
|
});
|
|
34
|
-
},
|
|
34
|
+
}, J = ({ children: e, className: t }) => {
|
|
35
35
|
const { options: n, addOther: l, addOtherLabel: h, id: p, numberOfColumns: O, hasError: m } = g(), { t: E } = D(), b = u(e, i.Option), r = F(null), c = h || E("add-other.default-other-option-label") || v;
|
|
36
|
-
return
|
|
36
|
+
return q(() => {
|
|
37
37
|
var o;
|
|
38
38
|
(o = r.current) == null || o.focus({
|
|
39
39
|
preventScroll: !0
|
|
@@ -55,15 +55,15 @@ const v = "Other", z = (e, t) => e == null ? void 0 : e.find((n) => (n.value ??
|
|
|
55
55
|
isOther: !0
|
|
56
56
|
}));
|
|
57
57
|
}, d = ({ children: e, className: t, ...n }) => {
|
|
58
|
-
var
|
|
59
|
-
const { value: l, label: h, isOther: p = !1, radioRef: O } = n, { value: m, options: E } = g(), b = u(e, d.Label), r = u(e, d.Input), c = u(e, d.Control), o = u(e, d.OtherInput), f = p ?
|
|
58
|
+
var C;
|
|
59
|
+
const { value: l, label: h, isOther: p = !1, radioRef: O } = n, { value: m, options: E } = g(), b = u(e, d.Label), r = u(e, d.Input), c = u(e, d.Control), o = u(e, d.OtherInput), f = p ? y(E, m) : m === l, I = (C = r == null ? void 0 : r.props) == null ? void 0 : C.className;
|
|
60
60
|
return /* @__PURE__ */ a.createElement("div", {
|
|
61
61
|
className: t
|
|
62
|
-
}, /* @__PURE__ */ a.createElement(
|
|
62
|
+
}, /* @__PURE__ */ a.createElement(k, {
|
|
63
63
|
value: l
|
|
64
|
-
}, /* @__PURE__ */ a.createElement(
|
|
64
|
+
}, /* @__PURE__ */ a.createElement(x, {
|
|
65
65
|
ref: O,
|
|
66
|
-
className:
|
|
66
|
+
className: I
|
|
67
67
|
}, ({ isSelected: s, isHovered: _, isFocused: R }) => /* @__PURE__ */ a.createElement(a.Fragment, null, L(c, {
|
|
68
68
|
isSelected: s,
|
|
69
69
|
isHovered: _,
|
|
@@ -77,16 +77,16 @@ const v = "Other", z = (e, t) => e == null ? void 0 : e.find((n) => (n.value ??
|
|
|
77
77
|
className: e
|
|
78
78
|
}, n);
|
|
79
79
|
}, W = (e) => null, X = ({ className: e }) => {
|
|
80
|
-
const { value: t, onChange: n, addOtherLabel: l, addOtherPlaceholder: h, otherInputCharacterLimit: p, disabled: O, readOnly: m, options: E } = g(), { t: b } = D(), r = F(null), c =
|
|
80
|
+
const { value: t, onChange: n, addOtherLabel: l, addOtherPlaceholder: h, otherInputCharacterLimit: p, disabled: O, readOnly: m, options: E } = g(), { t: b } = D(), r = F(null), c = y(E, t), o = l || b("add-other.default-other-option-label") || v, [f, I] = T(c && t ? z(t, l) : "");
|
|
81
81
|
B(() => {
|
|
82
82
|
var s;
|
|
83
83
|
c && r.current && ((s = r.current) == null || s.focus());
|
|
84
84
|
}, [
|
|
85
85
|
c
|
|
86
86
|
]);
|
|
87
|
-
const
|
|
87
|
+
const C = H((s) => {
|
|
88
88
|
let _;
|
|
89
|
-
s ? _ = `${l}: ${s}` : _ = o, n(_),
|
|
89
|
+
s ? _ = `${l}: ${s}` : _ = o, n(_), I(s);
|
|
90
90
|
}, [
|
|
91
91
|
n,
|
|
92
92
|
l,
|
|
@@ -95,7 +95,7 @@ const v = "Other", z = (e, t) => e == null ? void 0 : e.find((n) => (n.value ??
|
|
|
95
95
|
return /* @__PURE__ */ a.createElement(G, {
|
|
96
96
|
"aria-label": o,
|
|
97
97
|
value: f,
|
|
98
|
-
onChange:
|
|
98
|
+
onChange: C,
|
|
99
99
|
isDisabled: O,
|
|
100
100
|
isReadOnly: m
|
|
101
101
|
}, /* @__PURE__ */ a.createElement(P, {
|
|
@@ -107,14 +107,14 @@ const v = "Other", z = (e, t) => e == null ? void 0 : e.find((n) => (n.value ??
|
|
|
107
107
|
};
|
|
108
108
|
d.Label = Q;
|
|
109
109
|
d.Input = W;
|
|
110
|
-
d.Control =
|
|
110
|
+
d.Control = j;
|
|
111
111
|
d.OtherInput = X;
|
|
112
|
-
i.Label =
|
|
113
|
-
i.Options =
|
|
112
|
+
i.Label = M;
|
|
113
|
+
i.Options = J;
|
|
114
114
|
i.Option = d;
|
|
115
115
|
i.Description = U;
|
|
116
|
-
i.Error =
|
|
117
|
-
const Y = "_labelImage_1u9f2_1", Z = "_option_1u9f2_26", ee = "_optionInput_1u9f2_32", te = "_optionControl_1u9f2_50", oe = "_optionControlHover_1u9f2_72", ne = "_optionControlSelected_1u9f2_90", le = "_optionLabel_1u9f2_137",
|
|
116
|
+
i.Error = K;
|
|
117
|
+
const Y = "_labelImage_1u9f2_1", Z = "_option_1u9f2_26", ee = "_optionInput_1u9f2_32", te = "_optionControl_1u9f2_50", oe = "_optionControlHover_1u9f2_72", ne = "_optionControlSelected_1u9f2_90", le = "_optionLabel_1u9f2_137", S = {
|
|
118
118
|
labelImage: Y,
|
|
119
119
|
option: Z,
|
|
120
120
|
optionInput: ee,
|
|
@@ -123,12 +123,12 @@ const Y = "_labelImage_1u9f2_1", Z = "_option_1u9f2_26", ee = "_optionInput_1u9f
|
|
|
123
123
|
optionControlSelected: ne,
|
|
124
124
|
optionLabel: le
|
|
125
125
|
}, pe = {
|
|
126
|
-
base:
|
|
127
|
-
selected:
|
|
128
|
-
hover:
|
|
126
|
+
base: S.optionControl,
|
|
127
|
+
selected: S.optionControlSelected,
|
|
128
|
+
hover: S.optionControlHover
|
|
129
129
|
};
|
|
130
130
|
export {
|
|
131
131
|
pe as R,
|
|
132
132
|
i as a,
|
|
133
|
-
|
|
133
|
+
S as s
|
|
134
134
|
};
|
package/dist/component/{radio-group-field-rac-DGoMoSgo.js → radio-group-field-rac-Cp3LRN3C.js}
RENAMED
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import { RicosViewer as m } from "@wix/ricos/viewer";
|
|
2
2
|
import t from "classnames";
|
|
3
3
|
import e from "react";
|
|
4
|
-
import { a, s, R as n } from "./radio-button-module-classes-
|
|
4
|
+
import { a, s, R as n } from "./radio-button-module-classes-VqaP6vpA.js";
|
|
5
5
|
import { E as c } from "./error-icon-hZxQ6DEy.js";
|
|
6
6
|
import { s as r } from "./field-rac.module-DP0lkkEv.js";
|
|
7
|
-
import {
|
|
7
|
+
import { W as i, ac as E, a7 as p, a8 as O, M as R, G as _, a9 as I } from "./form-BUqSKOvc.js";
|
|
8
8
|
import { o as L } from "./options-rac.module-_THNq6Qq.js";
|
|
9
|
-
import { u as N } from "./use-element-state-class-name-
|
|
10
|
-
import { u } from "./use-text-input-class-name-
|
|
9
|
+
import { u as N } from "./use-element-state-class-name-DlncY4hk.js";
|
|
10
|
+
import { u } from "./use-text-input-class-name-D9tJTR-b.js";
|
|
11
11
|
const D = ({ content: o, locale: l }) => /* @__PURE__ */ e.createElement(m, {
|
|
12
12
|
content: o,
|
|
13
13
|
locale: l
|
|
14
|
-
}),
|
|
14
|
+
}), G = () => {
|
|
15
15
|
const o = N({
|
|
16
16
|
globalClasses: I,
|
|
17
17
|
moduleClasses: n
|
|
@@ -31,15 +31,15 @@ const D = ({ content: o, locale: l }) => /* @__PURE__ */ e.createElement(m, {
|
|
|
31
31
|
}), /* @__PURE__ */ e.createElement(a.Option.Control, {
|
|
32
32
|
className: o
|
|
33
33
|
}), /* @__PURE__ */ e.createElement(a.Option.Label, {
|
|
34
|
-
className: t(
|
|
34
|
+
className: t(O, s.optionLabel)
|
|
35
35
|
}), /* @__PURE__ */ e.createElement(a.Option.OtherInput, {
|
|
36
36
|
className: l
|
|
37
37
|
}))), /* @__PURE__ */ e.createElement(a.Error, {
|
|
38
|
-
className: t(
|
|
38
|
+
className: t(R, r.error)
|
|
39
39
|
}, /* @__PURE__ */ e.createElement(c, null), /* @__PURE__ */ e.createElement(a.Error.Text, null)), /* @__PURE__ */ e.createElement(a.Description, {
|
|
40
40
|
className: t(_, r.description)
|
|
41
41
|
}, D));
|
|
42
42
|
};
|
|
43
43
|
export {
|
|
44
|
-
|
|
44
|
+
G as R
|
|
45
45
|
};
|
package/dist/component/{rating-input-field-rac-CFoesqmC.js → rating-input-field-rac-10n6ciCr.js}
RENAMED
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
import { RicosViewer as
|
|
1
|
+
import { RicosViewer as y } from "@wix/ricos/viewer";
|
|
2
2
|
import u from "classnames";
|
|
3
3
|
import e, { useCallback as N, useState as O, useRef as A } from "react";
|
|
4
|
-
import {
|
|
5
|
-
import { RadioGroup as
|
|
4
|
+
import { bA as I, bx as v, bK as M, W as T, ac as H, aa as w, M as B, G as P, ab as G } from "./form-BUqSKOvc.js";
|
|
5
|
+
import { RadioGroup as q, RadioField as x, RadioButton as k } from "react-aria-components";
|
|
6
6
|
import { f as E, a as U } from "./find-child-C60k4CxG.js";
|
|
7
|
-
import { D as z, E as
|
|
8
|
-
import { L as
|
|
9
|
-
import { E as
|
|
7
|
+
import { D as z, E as K } from "./field-error-headless-XnVcMmsL.js";
|
|
8
|
+
import { L as Q } from "./field-label-headless-BRTLT2Yt.js";
|
|
9
|
+
import { E as W } from "./error-icon-hZxQ6DEy.js";
|
|
10
10
|
import { s as g } from "./field-rac.module-DP0lkkEv.js";
|
|
11
|
-
import { u as
|
|
11
|
+
import { u as Z } from "./use-element-state-class-name-DlncY4hk.js";
|
|
12
12
|
const t = ({ children: a }) => {
|
|
13
|
-
const { id: n, value: r, onChange: i, disabled: l, readOnly: m, required: d, hasError: c, onBlur: o, onFocus:
|
|
13
|
+
const { id: n, value: r, onChange: i, disabled: l, readOnly: m, required: d, hasError: c, onBlur: o, onFocus: C, FieldLayout: R } = I(), { labelId: _ } = v(), L = N((D) => i(Number(D)), [
|
|
14
14
|
i
|
|
15
|
-
]),
|
|
16
|
-
return /* @__PURE__ */ e.createElement(
|
|
15
|
+
]), b = E(a, t.Label), s = E(a, t.Ratings), f = E(a, t.Description), h = E(a, t.Error);
|
|
16
|
+
return /* @__PURE__ */ e.createElement(R, {
|
|
17
17
|
fieldId: n,
|
|
18
|
-
renderLabel: () =>
|
|
19
|
-
renderInput: () => /* @__PURE__ */ e.createElement(
|
|
18
|
+
renderLabel: () => b,
|
|
19
|
+
renderInput: () => /* @__PURE__ */ e.createElement(q, {
|
|
20
20
|
"aria-labelledby": _,
|
|
21
21
|
value: r ? String(r) : void 0,
|
|
22
22
|
onChange: L,
|
|
@@ -25,21 +25,21 @@ const t = ({ children: a }) => {
|
|
|
25
25
|
isRequired: d,
|
|
26
26
|
isInvalid: c,
|
|
27
27
|
onBlur: o,
|
|
28
|
-
onFocus:
|
|
28
|
+
onFocus: C,
|
|
29
29
|
orientation: "horizontal"
|
|
30
30
|
}, s),
|
|
31
|
-
renderDescription: () => /* @__PURE__ */ e.createElement(e.Fragment, null, h,
|
|
31
|
+
renderDescription: () => /* @__PURE__ */ e.createElement(e.Fragment, null, h, f)
|
|
32
32
|
});
|
|
33
|
-
},
|
|
34
|
-
const { value: i, readOnly: l, hasError: m } =
|
|
33
|
+
}, S = ({ children: a, className: n, getReactionLabel: r }) => {
|
|
34
|
+
const { value: i, readOnly: l, hasError: m } = I(), { inputId: d, ariaDescribedBy: c } = v(), [o, C] = O(), R = A(null), _ = E(a, S.Rating), L = [
|
|
35
35
|
"1",
|
|
36
36
|
"2",
|
|
37
37
|
"3",
|
|
38
38
|
"4",
|
|
39
39
|
"5"
|
|
40
|
-
],
|
|
40
|
+
], b = (s) => o && !l ? o >= s : !!i && i >= Number(s);
|
|
41
41
|
return /* @__PURE__ */ e.createElement("div", {
|
|
42
|
-
ref:
|
|
42
|
+
ref: R,
|
|
43
43
|
id: d,
|
|
44
44
|
"aria-describedby": c,
|
|
45
45
|
className: n,
|
|
@@ -48,11 +48,11 @@ const t = ({ children: a }) => {
|
|
|
48
48
|
}, L.map((s) => U(_, {
|
|
49
49
|
key: s,
|
|
50
50
|
value: s,
|
|
51
|
-
isSelected:
|
|
52
|
-
onHoverChange: (
|
|
51
|
+
isSelected: b(s),
|
|
52
|
+
onHoverChange: (f) => C(f ? s : void 0),
|
|
53
53
|
label: r == null ? void 0 : r(Number(s))
|
|
54
54
|
})));
|
|
55
|
-
},
|
|
55
|
+
}, j = {
|
|
56
56
|
border: 0,
|
|
57
57
|
clipPath: "inset(50%)",
|
|
58
58
|
height: 1,
|
|
@@ -64,9 +64,9 @@ const t = ({ children: a }) => {
|
|
|
64
64
|
whiteSpace: "nowrap"
|
|
65
65
|
}, F = ({ className: a, children: n, ...r }) => {
|
|
66
66
|
const { value: i, isSelected: l, onHoverChange: m, label: d } = r;
|
|
67
|
-
return /* @__PURE__ */ e.createElement(
|
|
67
|
+
return /* @__PURE__ */ e.createElement(x, {
|
|
68
68
|
value: i
|
|
69
|
-
}, /* @__PURE__ */ e.createElement(
|
|
69
|
+
}, /* @__PURE__ */ e.createElement(k, {
|
|
70
70
|
className: ({ isHovered: c, isFocused: o }) => typeof a == "function" ? a({
|
|
71
71
|
isSelected: l,
|
|
72
72
|
isHovered: c,
|
|
@@ -79,16 +79,16 @@ const t = ({ children: a }) => {
|
|
|
79
79
|
isHovered: c,
|
|
80
80
|
isFocused: o
|
|
81
81
|
}) : n, d ? /* @__PURE__ */ e.createElement("span", {
|
|
82
|
-
style:
|
|
82
|
+
style: j
|
|
83
83
|
}, d) : null)));
|
|
84
84
|
};
|
|
85
|
-
|
|
86
|
-
t.Label =
|
|
87
|
-
t.Ratings =
|
|
85
|
+
S.Rating = F;
|
|
86
|
+
t.Label = Q;
|
|
87
|
+
t.Ratings = S;
|
|
88
88
|
t.Rating = F;
|
|
89
89
|
t.Description = z;
|
|
90
|
-
t.Error =
|
|
91
|
-
const
|
|
90
|
+
t.Error = K;
|
|
91
|
+
const J = (a) => /* @__PURE__ */ e.createElement("svg", {
|
|
92
92
|
viewBox: "0 0 32 32",
|
|
93
93
|
width: 32,
|
|
94
94
|
height: 32,
|
|
@@ -98,12 +98,12 @@ const K = (a) => /* @__PURE__ */ e.createElement("svg", {
|
|
|
98
98
|
}, /* @__PURE__ */ e.createElement("path", {
|
|
99
99
|
fillRule: "evenodd",
|
|
100
100
|
d: "M28.6265,13.6325 C28.9655,13.3015 29.0845,12.8175 28.9385,12.3665 C28.7925,11.9165 28.4105,11.5945 27.9415,11.5265 L20.5785,10.4565 C20.5015,10.4445 20.4345,10.3965 20.4005,10.3275 L17.1075,3.6545 L17.1075,3.6535 C16.8975,3.2295 16.4735,2.9655 16.0005,2.9655 L15.9995,2.9655 C15.5255,2.9655 15.1025,3.2295 14.8925,3.6545 L11.5985,10.3275 C11.5645,10.3965 11.4985,10.4445 11.4225,10.4565 L4.0575,11.5265 C3.5895,11.5945 3.2075,11.9165 3.0615,12.3665 C2.9155,12.8175 3.0345,13.3015 3.3735,13.6325 L8.7025,18.8265 C8.7575,18.8805 8.7835,18.9585 8.7705,19.0345 L7.5125,26.3695 C7.4325,26.8355 7.6205,27.2985 8.0035,27.5765 C8.2195,27.7345 8.4735,27.8145 8.7285,27.8145 C8.9245,27.8145 9.1215,27.7665 9.3045,27.6705 L15.8895,24.2085 C15.9595,24.1725 16.0415,24.1725 16.1085,24.2075 L22.6955,27.6705 C23.1155,27.8915 23.6135,27.8555 23.9965,27.5765 C24.3795,27.2985 24.5675,26.8355 24.4875,26.3695 L23.2305,19.0355 C23.2165,18.9585 23.2425,18.8805 23.2975,18.8265 L28.6265,13.6325 Z"
|
|
101
|
-
})),
|
|
102
|
-
ratings:
|
|
103
|
-
rating:
|
|
104
|
-
ratingSelected:
|
|
101
|
+
})), X = "_ratings_a5lgi_1", Y = "_rating_a5lgi_1", $ = "_ratingSelected_a5lgi_37", V = "_ratingHover_a5lgi_44", p = {
|
|
102
|
+
ratings: X,
|
|
103
|
+
rating: Y,
|
|
104
|
+
ratingSelected: $,
|
|
105
105
|
ratingHover: V
|
|
106
|
-
}, ee = ({ content: a, locale: n }) => /* @__PURE__ */ e.createElement(
|
|
106
|
+
}, ee = ({ content: a, locale: n }) => /* @__PURE__ */ e.createElement(y, {
|
|
107
107
|
content: a,
|
|
108
108
|
locale: n
|
|
109
109
|
}), te = {
|
|
@@ -111,14 +111,14 @@ const K = (a) => /* @__PURE__ */ e.createElement("svg", {
|
|
|
111
111
|
selected: p.ratingSelected,
|
|
112
112
|
hover: p.ratingHover
|
|
113
113
|
}, Ee = () => {
|
|
114
|
-
const { t: a } =
|
|
115
|
-
globalClasses:
|
|
114
|
+
const { t: a } = M(), n = Z({
|
|
115
|
+
globalClasses: G,
|
|
116
116
|
moduleClasses: te
|
|
117
117
|
});
|
|
118
118
|
return /* @__PURE__ */ e.createElement(t, null, /* @__PURE__ */ e.createElement(t.Label, {
|
|
119
119
|
className: u(T, g.label)
|
|
120
120
|
}, /* @__PURE__ */ e.createElement(t.Label.Required, {
|
|
121
|
-
className: u(
|
|
121
|
+
className: u(H, g.requiredMark)
|
|
122
122
|
})), /* @__PURE__ */ e.createElement(t.Ratings, {
|
|
123
123
|
className: u(w, p.ratings),
|
|
124
124
|
getReactionLabel: (r) => a("rating-input.a11y.reaction-label", {
|
|
@@ -126,9 +126,9 @@ const K = (a) => /* @__PURE__ */ e.createElement("svg", {
|
|
|
126
126
|
})
|
|
127
127
|
}, /* @__PURE__ */ e.createElement(t.Rating, {
|
|
128
128
|
className: n
|
|
129
|
-
}, /* @__PURE__ */ e.createElement(
|
|
129
|
+
}, /* @__PURE__ */ e.createElement(J, null))), /* @__PURE__ */ e.createElement(t.Error, {
|
|
130
130
|
className: u(B, g.error)
|
|
131
|
-
}, /* @__PURE__ */ e.createElement(
|
|
131
|
+
}, /* @__PURE__ */ e.createElement(W, null), /* @__PURE__ */ e.createElement(t.Error.Text, null)), /* @__PURE__ */ e.createElement(t.Description, {
|
|
132
132
|
className: u(P, g.description)
|
|
133
133
|
}, ee));
|
|
134
134
|
};
|
package/dist/component/{rich-content-rac.module-xJ03MegT.js → rich-content-rac.module-kMwDoLBa.js}
RENAMED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import c, { useState as u } from "react";
|
|
2
|
-
import {
|
|
2
|
+
import { bA as a, bs as i, bK as T } from "./form-BUqSKOvc.js";
|
|
3
3
|
import { Button as d } from "react-aria-components";
|
|
4
4
|
import { D as r } from "./data-hooks-Dkw1pbRj.js";
|
|
5
5
|
import { truncateRichContent as _ } from "@wix/ricos/content";
|
|
@@ -14,17 +14,17 @@ const O = ({ children: e }) => {
|
|
|
14
14
|
}),
|
|
15
15
|
renderDescription: () => null
|
|
16
16
|
});
|
|
17
|
-
},
|
|
18
|
-
toggleTruncate:
|
|
17
|
+
}, f = "_toggleTruncate_5jt03_1", g = {
|
|
18
|
+
toggleTruncate: f
|
|
19
19
|
}, p = ({ isTruncated: e, onClick: t }) => {
|
|
20
20
|
const { t: n } = T(), o = n(e ? "field.rich-text.read-more-button.label" : "field.rich-text.read-less-button.label"), s = e ? r.TOGGLE_TRUNCATE_BUTTON_READ_MORE : r.TOGGLE_TRUNCATE_BUTTON_READ_LESS;
|
|
21
21
|
return /* @__PURE__ */ c.createElement(d, {
|
|
22
22
|
onPress: t,
|
|
23
|
-
className:
|
|
23
|
+
className: g.toggleTruncate,
|
|
24
24
|
"data-hook": s
|
|
25
25
|
}, o);
|
|
26
26
|
};
|
|
27
|
-
function
|
|
27
|
+
function B(e, t) {
|
|
28
28
|
const [n, o] = u(!0);
|
|
29
29
|
function s() {
|
|
30
30
|
o((l) => !l);
|
|
@@ -38,12 +38,12 @@ function y(e, t) {
|
|
|
38
38
|
toggleTruncate: s
|
|
39
39
|
};
|
|
40
40
|
}
|
|
41
|
-
const C = "_richContent_1galb_1",
|
|
41
|
+
const C = "_richContent_1galb_1", D = {
|
|
42
42
|
richContent: C
|
|
43
43
|
};
|
|
44
44
|
export {
|
|
45
45
|
O as R,
|
|
46
46
|
p as T,
|
|
47
|
-
|
|
48
|
-
|
|
47
|
+
D as s,
|
|
48
|
+
B as u
|
|
49
49
|
};
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import l from "classnames";
|
|
2
2
|
import e from "react";
|
|
3
|
-
import {
|
|
4
|
-
import { u as C, R as d, s as g, T as p } from "./rich-content-rac.module-
|
|
3
|
+
import { bA as m, aN as i, av as u, bb as R, be as T } from "./form-BUqSKOvc.js";
|
|
4
|
+
import { u as C, R as d, s as g, T as p } from "./rich-content-rac.module-kMwDoLBa.js";
|
|
5
5
|
const h = {
|
|
6
6
|
colorPalette: T(),
|
|
7
7
|
customStyles: R()
|
|
8
|
-
},
|
|
8
|
+
}, f = ({ truncate: t = !0 } = {}) => {
|
|
9
9
|
const { content: a, maxShownParagraphs: s } = m(), { displayedContent: n, isTruncated: o, isTruncateButtonShown: r, toggleTruncate: c } = C(a, t ? s : void 0);
|
|
10
10
|
return /* @__PURE__ */ e.createElement(d, null, () => /* @__PURE__ */ e.createElement(e.Fragment, null, /* @__PURE__ */ e.createElement(i, {
|
|
11
11
|
className: l(u, g.richContent),
|
|
@@ -17,5 +17,5 @@ const h = {
|
|
|
17
17
|
})));
|
|
18
18
|
};
|
|
19
19
|
export {
|
|
20
|
-
|
|
20
|
+
f as R
|
|
21
21
|
};
|