@loczer/storefront-sdk 0.198.0 → 0.200.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/StorefrontContext.d.ts +483 -0
- package/dist/StorefrontContext.d.ts.map +1 -0
- package/dist/StorefrontContext.js +39 -0
- package/dist/StorefrontProvider.d.ts +6 -486
- package/dist/StorefrontProvider.d.ts.map +1 -1
- package/dist/StorefrontProvider.js +34 -67
- package/dist/components/AboutSection/index.js +5 -5
- package/dist/components/BikeProductCard/index.d.ts.map +1 -1
- package/dist/components/BikeProductCard/index.js +27 -27
- package/dist/components/BookingBikeQuickAddCard/index.d.ts.map +1 -1
- package/dist/components/BookingBikeQuickAddCard/index.js +54 -61
- package/dist/components/BookingBikeVariantDialog/index.d.ts.map +1 -1
- package/dist/components/BookingBikeVariantDialog/index.js +129 -116
- package/dist/components/ContactSection/index.js +107 -107
- package/dist/components/ContractSaleDocument/Invoice.d.ts.map +1 -1
- package/dist/components/ContractSaleDocument/Invoice.js +117 -111
- package/dist/components/Header/index.js +4 -4
- package/dist/components/Layout/index.d.ts.map +1 -1
- package/dist/components/Layout/index.js +47 -40
- package/dist/components/ProductPriceBadge/index.d.ts +2 -1
- package/dist/components/ProductPriceBadge/index.d.ts.map +1 -1
- package/dist/components/ProductPriceBadge/index.js +72 -70
- package/dist/components/StorefrontCancellationPolicyNotice/index.d.ts.map +1 -1
- package/dist/components/StorefrontCancellationPolicyNotice/index.js +3 -6
- package/dist/components/StorefrontInsuranceNotice/index.d.ts.map +1 -1
- package/dist/components/StorefrontInsuranceNotice/index.js +3 -6
- package/dist/components/TestimonialsSection/index.js +1 -1
- package/dist/i18n/en.d.ts +1 -0
- package/dist/i18n/en.d.ts.map +1 -1
- package/dist/i18n/en.js +1 -0
- package/dist/i18n/fr.d.ts +1 -0
- package/dist/i18n/fr.d.ts.map +1 -1
- package/dist/i18n/fr.js +1 -0
- package/dist/index.d.ts +15 -2
- package/dist/index.js +59 -58
- package/dist/lib/cartSummary.js +7 -7
- package/dist/lib/productVariants.d.ts +1 -0
- package/dist/lib/productVariants.d.ts.map +1 -1
- package/dist/lib/productVariants.js +27 -15
- package/dist/lib/products.d.ts +6 -0
- package/dist/lib/products.d.ts.map +1 -1
- package/dist/lib/products.js +36 -32
- package/dist/lib/toast.d.ts +9 -0
- package/dist/lib/toast.d.ts.map +1 -0
- package/dist/lib/toast.js +13 -0
- package/dist/pages/BookingPage.d.ts.map +1 -1
- package/dist/pages/BookingPage.js +143 -138
- package/dist/pages/CheckoutPage.js +217 -217
- package/dist/pages/CheckoutPaymentPage.js +124 -124
- package/dist/pages/ContractSaleDocumentPage.d.ts.map +1 -1
- package/dist/pages/ContractSaleDocumentPage.js +83 -83
- package/dist/pages/HomePage.js +6 -3
- package/dist/pages/ProductPage.d.ts.map +1 -1
- package/dist/pages/ProductPage.js +177 -165
- package/package.json +2 -1
|
@@ -1,188 +1,201 @@
|
|
|
1
|
-
import { getProductVariantAttributeValue as e, getStorefrontProductVariantDisplay as t } from "../../lib/productVariants.js";
|
|
2
|
-
import { getAvailabilityVariant as n } from "../../lib/utils.js";
|
|
1
|
+
import { getProductVariantAttributeValue as e, getStorefrontProductVariantDisplay as t, getStorefrontProductVariantHeightRange as n } from "../../lib/productVariants.js";
|
|
3
2
|
import { getLocalizedValue as r } from "../../localization.js";
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
3
|
+
import { getAvailabilityVariant as i } from "../../lib/utils.js";
|
|
4
|
+
import { Badge as a } from "../../ui/badge.js";
|
|
5
|
+
import { Button as o } from "../../ui/button.js";
|
|
6
|
+
import { RESPONSIVE_DIALOG_MOBILE_MEDIA_QUERY as s, ResponsiveDialog as c, ResponsiveDialogContent as l, ResponsiveDialogDescription as u, ResponsiveDialogFooter as d, ResponsiveDialogHeader as f, ResponsiveDialogTitle as p } from "../../chunks/pkg/ui/dist/ResponsiveDialog-BVwhTZQo.js";
|
|
7
|
+
import { Input as m } from "../../ui/input.js";
|
|
8
|
+
import { useStorefrontWorkspaceLanguage as h } from "../../StorefrontContext.js";
|
|
9
|
+
import { ProductWarningNotice as g } from "../ProductWarningNotice/index.js";
|
|
10
|
+
import { ProductPriceBadge as _ } from "../ProductPriceBadge/index.js";
|
|
11
|
+
import { resolveProductImageContainerStyle as v } from "../../lib/productImageStyles.js";
|
|
12
|
+
import { useEffect as y, useState as b } from "react";
|
|
13
|
+
import { jsx as x, jsxs as S } from "react/jsx-runtime";
|
|
14
|
+
import { useMediaQuery as C } from "@rpcbase/client";
|
|
15
|
+
import { useTranslation as w } from "react-i18next";
|
|
16
|
+
import { cn as T } from "@rpcbase/ui";
|
|
17
|
+
import { Bike as E, CheckCircle2 as D, Package as O, Plus as k } from "lucide-react";
|
|
18
18
|
//#region src/components/BookingBikeVariantDialog/index.tsx
|
|
19
|
-
var
|
|
19
|
+
var A = (e) => {
|
|
20
20
|
let t = Number.parseInt(e, 10);
|
|
21
21
|
return !Number.isFinite(t) || t < 1 ? 1 : t;
|
|
22
22
|
};
|
|
23
|
-
function
|
|
24
|
-
let { t:
|
|
25
|
-
if (
|
|
26
|
-
!
|
|
27
|
-
}, [
|
|
28
|
-
let
|
|
29
|
-
|
|
23
|
+
function j({ open: m, product: j, onOpenChange: N, getVariantAvailabilityLabel: P, isVariantOutOfCapacity: F, addDisabled: I = !1, onAddVariant: L }) {
|
|
24
|
+
let { t: R, i18n: z } = w(), B = C(s), V = h(), [H, U] = b({});
|
|
25
|
+
if (y(() => {
|
|
26
|
+
!j || !m || U((j.productVariants ?? []).reduce((e, t) => (e[t.id] = "1", e), {}));
|
|
27
|
+
}, [m, j]), !j) return null;
|
|
28
|
+
let W = (e, t) => {
|
|
29
|
+
U((n) => ({
|
|
30
30
|
...n,
|
|
31
31
|
[e]: t
|
|
32
32
|
}));
|
|
33
|
-
},
|
|
34
|
-
return /* @__PURE__ */
|
|
35
|
-
open:
|
|
36
|
-
onOpenChange:
|
|
37
|
-
children: /* @__PURE__ */
|
|
33
|
+
}, G = r(j.name, z.language, V), K = r(j.description, z.language, V), q = r(j.warning, z.language, V), J = typeof j.images?.[0] == "string" ? j.images[0].trim() : "", Y = v(j.primaryImageStyle), X = i(j.availabilityStatus), Z = j.features?.slice(0, 4) ?? [], Q = j.productVariants ?? [], $ = Q.some((t) => !!e(t, "size")) ? R("product_size_label") : R("product_variant_label");
|
|
34
|
+
return /* @__PURE__ */ x(c, {
|
|
35
|
+
open: m,
|
|
36
|
+
onOpenChange: N,
|
|
37
|
+
children: /* @__PURE__ */ x(l, {
|
|
38
38
|
"data-testid": "storefront-booking-bike-dialog-content",
|
|
39
39
|
className: "overflow-hidden border-slate-200 bg-white p-0",
|
|
40
40
|
desktopClassName: "max-w-4xl gap-0",
|
|
41
41
|
mobileClassName: "max-h-[95dvh] gap-0",
|
|
42
|
-
children: /* @__PURE__ */
|
|
42
|
+
children: /* @__PURE__ */ S("div", {
|
|
43
43
|
"data-testid": "storefront-booking-bike-dialog",
|
|
44
44
|
className: "flex max-h-[92dvh] flex-col",
|
|
45
45
|
children: [
|
|
46
|
-
/* @__PURE__ */
|
|
46
|
+
/* @__PURE__ */ S(f, {
|
|
47
47
|
className: "border-b border-slate-200 px-5 py-4 text-left sm:px-6",
|
|
48
|
-
children: [/* @__PURE__ */
|
|
48
|
+
children: [/* @__PURE__ */ x(p, {
|
|
49
49
|
className: "text-left text-lg font-semibold text-slate-950",
|
|
50
|
-
children: /* @__PURE__ */
|
|
51
|
-
}), /* @__PURE__ */
|
|
50
|
+
children: /* @__PURE__ */ x("span", { children: G })
|
|
51
|
+
}), /* @__PURE__ */ x(u, {
|
|
52
52
|
className: "line-clamp-2 text-left text-sm text-slate-600",
|
|
53
|
-
children: /* @__PURE__ */
|
|
53
|
+
children: /* @__PURE__ */ x("span", { children: K })
|
|
54
54
|
})]
|
|
55
55
|
}),
|
|
56
|
-
/* @__PURE__ */
|
|
56
|
+
/* @__PURE__ */ x("div", {
|
|
57
57
|
className: "overflow-y-auto",
|
|
58
|
-
children: /* @__PURE__ */
|
|
58
|
+
children: /* @__PURE__ */ S("div", {
|
|
59
59
|
className: "grid gap-5 px-5 py-5 sm:grid-cols-[minmax(0,0.92fr)_minmax(0,1.08fr)] sm:px-6",
|
|
60
|
-
children: [/* @__PURE__ */
|
|
60
|
+
children: [/* @__PURE__ */ S("div", {
|
|
61
61
|
className: "grid gap-4",
|
|
62
62
|
children: [
|
|
63
|
-
/* @__PURE__ */
|
|
64
|
-
className:
|
|
65
|
-
style:
|
|
66
|
-
children:
|
|
67
|
-
src:
|
|
68
|
-
alt:
|
|
63
|
+
/* @__PURE__ */ x("div", {
|
|
64
|
+
className: T("relative aspect-[1618/1000] overflow-hidden rounded-2xl", Y.className),
|
|
65
|
+
style: Y.style,
|
|
66
|
+
children: J ? /* @__PURE__ */ x("img", {
|
|
67
|
+
src: J,
|
|
68
|
+
alt: G,
|
|
69
69
|
className: "absolute inset-0 h-full w-full object-contain p-2",
|
|
70
70
|
loading: "lazy"
|
|
71
|
-
}) : /* @__PURE__ */
|
|
71
|
+
}) : /* @__PURE__ */ x("div", {
|
|
72
72
|
className: "absolute inset-0 flex items-center justify-center text-slate-400",
|
|
73
|
-
children:
|
|
73
|
+
children: j.kind === "accessory" ? /* @__PURE__ */ x(O, {
|
|
74
74
|
className: "h-12 w-12",
|
|
75
75
|
"aria-hidden": "true"
|
|
76
|
-
}) : /* @__PURE__ */
|
|
76
|
+
}) : /* @__PURE__ */ x(E, {
|
|
77
77
|
className: "h-12 w-12",
|
|
78
78
|
"aria-hidden": "true"
|
|
79
79
|
})
|
|
80
80
|
})
|
|
81
81
|
}),
|
|
82
|
-
|
|
82
|
+
B ? null : /* @__PURE__ */ S("div", {
|
|
83
83
|
className: "flex flex-wrap items-center gap-2",
|
|
84
|
-
children: [/* @__PURE__ */
|
|
85
|
-
variant:
|
|
86
|
-
children: /* @__PURE__ */
|
|
87
|
-
}), /* @__PURE__ */
|
|
84
|
+
children: [/* @__PURE__ */ x(a, {
|
|
85
|
+
variant: X.variant,
|
|
86
|
+
children: /* @__PURE__ */ x("span", { children: R(X.labelKey) })
|
|
87
|
+
}), /* @__PURE__ */ x(_, {
|
|
88
|
+
prices: j.prices,
|
|
89
|
+
openOnHover: j.kind !== "accessory"
|
|
90
|
+
})]
|
|
88
91
|
}),
|
|
89
|
-
!
|
|
92
|
+
!B && Z.length > 0 ? /* @__PURE__ */ S("div", {
|
|
90
93
|
className: "grid gap-2",
|
|
91
|
-
children: [/* @__PURE__ */
|
|
94
|
+
children: [/* @__PURE__ */ x("p", {
|
|
92
95
|
className: "text-sm font-semibold text-slate-950",
|
|
93
|
-
children: /* @__PURE__ */
|
|
94
|
-
}), /* @__PURE__ */
|
|
96
|
+
children: /* @__PURE__ */ x("span", { children: R("product_features_title") })
|
|
97
|
+
}), /* @__PURE__ */ x("ul", {
|
|
95
98
|
className: "grid gap-1.5 text-sm text-slate-700",
|
|
96
|
-
children:
|
|
99
|
+
children: Z.map((e, t) => /* @__PURE__ */ S("li", {
|
|
97
100
|
className: "inline-flex items-start gap-2",
|
|
98
|
-
children: [/* @__PURE__ */
|
|
101
|
+
children: [/* @__PURE__ */ x(D, {
|
|
99
102
|
className: "mt-0.5 h-4 w-4 text-success",
|
|
100
103
|
"aria-hidden": "true"
|
|
101
|
-
}), /* @__PURE__ */
|
|
102
|
-
}, `${
|
|
104
|
+
}), /* @__PURE__ */ x("span", { children: r(e, z.language, V) })]
|
|
105
|
+
}, `${j.id}-${t}`))
|
|
103
106
|
})]
|
|
104
107
|
}) : null,
|
|
105
|
-
|
|
108
|
+
B ? null : /* @__PURE__ */ x(g, { warning: q })
|
|
106
109
|
]
|
|
107
|
-
}), /* @__PURE__ */
|
|
110
|
+
}), /* @__PURE__ */ S("div", {
|
|
108
111
|
className: "grid content-start gap-3",
|
|
109
112
|
children: [
|
|
110
|
-
|
|
113
|
+
B ? /* @__PURE__ */ S("div", {
|
|
111
114
|
className: "flex flex-wrap items-center gap-2",
|
|
112
|
-
children: [/* @__PURE__ */
|
|
113
|
-
variant:
|
|
114
|
-
children: /* @__PURE__ */
|
|
115
|
-
}), /* @__PURE__ */
|
|
115
|
+
children: [/* @__PURE__ */ x(a, {
|
|
116
|
+
variant: X.variant,
|
|
117
|
+
children: /* @__PURE__ */ x("span", { children: R(X.labelKey) })
|
|
118
|
+
}), /* @__PURE__ */ x(_, {
|
|
119
|
+
prices: j.prices,
|
|
120
|
+
openOnHover: j.kind !== "accessory"
|
|
121
|
+
})]
|
|
116
122
|
}) : null,
|
|
117
|
-
|
|
123
|
+
B && Z.length > 0 ? /* @__PURE__ */ S("details", {
|
|
118
124
|
className: "group rounded-2xl border border-slate-200 bg-slate-50",
|
|
119
|
-
children: [/* @__PURE__ */
|
|
125
|
+
children: [/* @__PURE__ */ S("summary", {
|
|
120
126
|
className: "flex cursor-pointer list-none items-center justify-between gap-3 px-3 py-2.5 text-sm font-semibold text-slate-950 [&::-webkit-details-marker]:hidden",
|
|
121
|
-
children: [/* @__PURE__ */
|
|
127
|
+
children: [/* @__PURE__ */ x("span", { children: R("product_features_title") }), /* @__PURE__ */ x(k, {
|
|
122
128
|
className: "h-4 w-4 shrink-0 transition-transform group-open:rotate-45",
|
|
123
129
|
"aria-hidden": "true"
|
|
124
130
|
})]
|
|
125
|
-
}), /* @__PURE__ */
|
|
131
|
+
}), /* @__PURE__ */ x("div", {
|
|
126
132
|
className: "border-t border-slate-200 px-3 py-3",
|
|
127
|
-
children: /* @__PURE__ */
|
|
133
|
+
children: /* @__PURE__ */ x("ul", {
|
|
128
134
|
className: "grid gap-1.5 text-sm text-slate-700",
|
|
129
|
-
children:
|
|
135
|
+
children: Z.map((e, t) => /* @__PURE__ */ S("li", {
|
|
130
136
|
className: "inline-flex items-start gap-2",
|
|
131
|
-
children: [/* @__PURE__ */
|
|
137
|
+
children: [/* @__PURE__ */ x(D, {
|
|
132
138
|
className: "mt-0.5 h-4 w-4 text-success",
|
|
133
139
|
"aria-hidden": "true"
|
|
134
|
-
}), /* @__PURE__ */
|
|
135
|
-
}, `${
|
|
140
|
+
}), /* @__PURE__ */ x("span", { children: r(e, z.language, V) })]
|
|
141
|
+
}, `${j.id}-mobile-${t}`))
|
|
136
142
|
})
|
|
137
143
|
})]
|
|
138
144
|
}) : null,
|
|
139
|
-
|
|
140
|
-
/* @__PURE__ */
|
|
145
|
+
B ? /* @__PURE__ */ x(g, { warning: q }) : null,
|
|
146
|
+
/* @__PURE__ */ x("p", {
|
|
141
147
|
className: "text-2xs font-medium uppercase tracking-[0.18em] text-slate-500",
|
|
142
|
-
children: /* @__PURE__ */
|
|
148
|
+
children: /* @__PURE__ */ x("span", { children: $ })
|
|
143
149
|
}),
|
|
144
|
-
/* @__PURE__ */
|
|
150
|
+
/* @__PURE__ */ x("div", {
|
|
145
151
|
className: "grid gap-2",
|
|
146
|
-
children:
|
|
147
|
-
let
|
|
148
|
-
return /* @__PURE__ */
|
|
149
|
-
"data-testid":
|
|
150
|
-
className:
|
|
151
|
-
children: [/* @__PURE__ */
|
|
152
|
+
children: Q.map((e) => {
|
|
153
|
+
let r = `storefront-booking-bike-dialog-variant-option-${j.id}-${e.id}`.toLowerCase(), { label: i, description: s } = t(e), c = n(e), l = H[e.id] ?? "1", u = F?.(e.id) === !0, d = P?.(e.id) ?? null;
|
|
154
|
+
return /* @__PURE__ */ S("div", {
|
|
155
|
+
"data-testid": r,
|
|
156
|
+
className: T("flex flex-col gap-3 rounded-2xl border p-3 sm:flex-row sm:items-center sm:justify-between", "border-slate-200 bg-slate-50"),
|
|
157
|
+
children: [/* @__PURE__ */ S("div", {
|
|
152
158
|
className: "flex min-w-0 flex-1 flex-col gap-0.5",
|
|
153
159
|
children: [
|
|
154
|
-
/* @__PURE__ */
|
|
155
|
-
className: "
|
|
156
|
-
children:
|
|
160
|
+
/* @__PURE__ */ S("div", {
|
|
161
|
+
className: "flex min-w-0 items-baseline gap-2",
|
|
162
|
+
children: [/* @__PURE__ */ x("span", {
|
|
163
|
+
className: "min-w-0 truncate text-sm font-medium text-slate-950",
|
|
164
|
+
title: i,
|
|
165
|
+
children: i
|
|
166
|
+
}), c ? /* @__PURE__ */ x("span", {
|
|
167
|
+
className: "truncate text-xs text-slate-500",
|
|
168
|
+
children: c
|
|
169
|
+
}) : null]
|
|
157
170
|
}),
|
|
158
|
-
|
|
171
|
+
s ? /* @__PURE__ */ x("span", {
|
|
159
172
|
className: "text-xs text-slate-600",
|
|
160
|
-
children:
|
|
173
|
+
children: s
|
|
161
174
|
}) : null,
|
|
162
|
-
|
|
175
|
+
d ? /* @__PURE__ */ x("span", {
|
|
163
176
|
className: "pt-1",
|
|
164
|
-
children: /* @__PURE__ */
|
|
165
|
-
variant:
|
|
166
|
-
children: /* @__PURE__ */
|
|
177
|
+
children: /* @__PURE__ */ x(a, {
|
|
178
|
+
variant: u ? "destructive" : "outline",
|
|
179
|
+
children: /* @__PURE__ */ x("span", { children: d })
|
|
167
180
|
})
|
|
168
181
|
}) : null
|
|
169
182
|
]
|
|
170
|
-
}), /* @__PURE__ */
|
|
183
|
+
}), /* @__PURE__ */ S("div", {
|
|
171
184
|
className: "flex flex-wrap items-center gap-2 sm:justify-end",
|
|
172
|
-
children: [/* @__PURE__ */
|
|
173
|
-
quantity:
|
|
174
|
-
ariaLabel:
|
|
175
|
-
onQuantityChange: (t) =>
|
|
176
|
-
testIdPrefix: `storefront-booking-bike-dialog-variant-quantity-${
|
|
177
|
-
}), /* @__PURE__ */
|
|
185
|
+
children: [/* @__PURE__ */ x(M, {
|
|
186
|
+
quantity: l,
|
|
187
|
+
ariaLabel: R("quantity_label"),
|
|
188
|
+
onQuantityChange: (t) => W(e.id, t),
|
|
189
|
+
testIdPrefix: `storefront-booking-bike-dialog-variant-quantity-${j.id}-${e.id}`.toLowerCase()
|
|
190
|
+
}), /* @__PURE__ */ S(o, {
|
|
178
191
|
type: "button",
|
|
179
192
|
className: "gap-1.5 rounded-xl",
|
|
180
|
-
"data-testid": `storefront-booking-bike-dialog-variant-add-${
|
|
181
|
-
disabled:
|
|
193
|
+
"data-testid": `storefront-booking-bike-dialog-variant-add-${j.id}-${e.id}`.toLowerCase(),
|
|
194
|
+
disabled: I,
|
|
182
195
|
onClick: () => {
|
|
183
|
-
|
|
196
|
+
L(e.id, A(l));
|
|
184
197
|
},
|
|
185
|
-
children: [/* @__PURE__ */
|
|
198
|
+
children: [/* @__PURE__ */ x("span", { children: R("add_short") }), /* @__PURE__ */ x(k, {
|
|
186
199
|
className: "h-4 w-4",
|
|
187
200
|
"aria-hidden": "true"
|
|
188
201
|
})]
|
|
@@ -195,14 +208,14 @@ function A({ open: p, product: A, onOpenChange: M, getVariantAvailabilityLabel:
|
|
|
195
208
|
})]
|
|
196
209
|
})
|
|
197
210
|
}),
|
|
198
|
-
/* @__PURE__ */
|
|
211
|
+
/* @__PURE__ */ x(d, {
|
|
199
212
|
className: "border-t border-slate-200 px-5 py-4 sm:px-6",
|
|
200
|
-
children: /* @__PURE__ */
|
|
213
|
+
children: /* @__PURE__ */ x(o, {
|
|
201
214
|
type: "button",
|
|
202
215
|
variant: "outline",
|
|
203
216
|
className: "h-11 w-full rounded-xl sm:w-auto",
|
|
204
|
-
onClick: () =>
|
|
205
|
-
children: /* @__PURE__ */
|
|
217
|
+
onClick: () => N(!1),
|
|
218
|
+
children: /* @__PURE__ */ x("span", { children: R("close_modal") })
|
|
206
219
|
})
|
|
207
220
|
})
|
|
208
221
|
]
|
|
@@ -210,19 +223,19 @@ function A({ open: p, product: A, onOpenChange: M, getVariantAvailabilityLabel:
|
|
|
210
223
|
})
|
|
211
224
|
});
|
|
212
225
|
}
|
|
213
|
-
function
|
|
214
|
-
return /* @__PURE__ */
|
|
226
|
+
function M({ ariaLabel: e, onQuantityChange: t, quantity: n, testIdPrefix: r }) {
|
|
227
|
+
return /* @__PURE__ */ x("div", {
|
|
215
228
|
className: "flex items-center",
|
|
216
|
-
children: /* @__PURE__ */
|
|
229
|
+
children: /* @__PURE__ */ x(m, {
|
|
217
230
|
type: "text",
|
|
218
231
|
inputMode: "numeric",
|
|
219
232
|
pattern: "[0-9]*",
|
|
220
233
|
value: n,
|
|
221
234
|
onChange: (e) => {
|
|
222
235
|
let n = e.target.value.replace(/\D/g, "");
|
|
223
|
-
t(n ? String(
|
|
236
|
+
t(n ? String(A(n)) : "");
|
|
224
237
|
},
|
|
225
|
-
onBlur: () => t(String(
|
|
238
|
+
onBlur: () => t(String(A(n))),
|
|
226
239
|
className: "h-9 w-16 text-center",
|
|
227
240
|
"aria-label": e,
|
|
228
241
|
"data-testid": `${r}-value`
|
|
@@ -230,4 +243,4 @@ function j({ ariaLabel: e, onQuantityChange: t, quantity: n, testIdPrefix: r })
|
|
|
230
243
|
});
|
|
231
244
|
}
|
|
232
245
|
//#endregion
|
|
233
|
-
export {
|
|
246
|
+
export { j as BookingBikeVariantDialog };
|