@alfadocs/ui-kit-debug 1.91.0 → 1.93.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/README.md +24 -0
- package/dist/_chunks/map-view--c9bJDRw.js +726 -0
- package/dist/_chunks/map-view--c9bJDRw.js.map +1 -0
- package/dist/_chunks/{practice-results-CQ_KvEXK.js → practice-results-BWX9y6mS.js} +495 -471
- package/dist/_chunks/practice-results-BWX9y6mS.js.map +1 -0
- package/dist/_chunks/{booking-opt_h7Uc.js → reserved.agent-C1gLyK2R.js} +1031 -1011
- package/dist/_chunks/reserved.agent-C1gLyK2R.js.map +1 -0
- package/dist/ag-grid.css +2746 -0
- package/dist/agent-catalog.json +15 -1
- package/dist/apexcharts.css +40 -0
- package/dist/components/booking/index.d.ts +3 -0
- package/dist/components/booking/index.d.ts.map +1 -1
- package/dist/components/booking/index.js +6 -4
- package/dist/components/booking/reserved.agent.d.ts +4 -0
- package/dist/components/booking/reserved.agent.d.ts.map +1 -0
- package/dist/components/booking/reserved.d.ts +9 -6
- package/dist/components/booking/reserved.d.ts.map +1 -1
- package/dist/components/map-view/index.d.ts +1 -1
- package/dist/components/map-view/index.d.ts.map +1 -1
- package/dist/components/map-view/index.js +1 -1
- package/dist/components/map-view/map-view.d.ts +17 -0
- package/dist/components/map-view/map-view.d.ts.map +1 -1
- package/dist/components/practice-results/index.js +1 -1
- package/dist/components/practice-results/practice-results.d.ts +2 -2
- package/dist/components/practice-results/practice-results.d.ts.map +1 -1
- package/dist/core.css +2 -0
- package/dist/fullcalendar.css +56 -0
- package/dist/i18n/config.d.ts.map +1 -1
- package/dist/i18n/config.js +81 -81
- package/dist/i18n/config.js.map +1 -1
- package/dist/i18n/locales/ar.d.ts +1 -0
- package/dist/i18n/locales/ar.d.ts.map +1 -1
- package/dist/i18n/locales/ar.js +2 -1
- package/dist/i18n/locales/ar.js.map +1 -1
- package/dist/i18n/locales/de.d.ts +1 -0
- package/dist/i18n/locales/de.d.ts.map +1 -1
- package/dist/i18n/locales/de.js +2 -1
- package/dist/i18n/locales/de.js.map +1 -1
- package/dist/i18n/locales/el.d.ts +1 -0
- package/dist/i18n/locales/el.d.ts.map +1 -1
- package/dist/i18n/locales/el.js +2 -1
- package/dist/i18n/locales/el.js.map +1 -1
- package/dist/i18n/locales/en.d.ts +3 -2
- package/dist/i18n/locales/en.d.ts.map +1 -1
- package/dist/i18n/locales/en.js +2 -1
- package/dist/i18n/locales/en.js.map +1 -1
- package/dist/i18n/locales/es.d.ts +1 -0
- package/dist/i18n/locales/es.d.ts.map +1 -1
- package/dist/i18n/locales/es.js +2 -1
- package/dist/i18n/locales/es.js.map +1 -1
- package/dist/i18n/locales/fr.d.ts +1 -0
- package/dist/i18n/locales/fr.d.ts.map +1 -1
- package/dist/i18n/locales/fr.js +2 -1
- package/dist/i18n/locales/fr.js.map +1 -1
- package/dist/i18n/locales/hi.d.ts +1 -0
- package/dist/i18n/locales/hi.d.ts.map +1 -1
- package/dist/i18n/locales/hi.js +2 -1
- package/dist/i18n/locales/hi.js.map +1 -1
- package/dist/i18n/locales/it.d.ts +1 -0
- package/dist/i18n/locales/it.d.ts.map +1 -1
- package/dist/i18n/locales/it.js +2 -1
- package/dist/i18n/locales/it.js.map +1 -1
- package/dist/i18n/locales/ja.d.ts +1 -0
- package/dist/i18n/locales/ja.d.ts.map +1 -1
- package/dist/i18n/locales/ja.js +2 -1
- package/dist/i18n/locales/ja.js.map +1 -1
- package/dist/i18n/locales/nl.d.ts +1 -0
- package/dist/i18n/locales/nl.d.ts.map +1 -1
- package/dist/i18n/locales/nl.js +2 -1
- package/dist/i18n/locales/nl.js.map +1 -1
- package/dist/i18n/locales/pl.d.ts +1 -0
- package/dist/i18n/locales/pl.d.ts.map +1 -1
- package/dist/i18n/locales/pl.js +2 -1
- package/dist/i18n/locales/pl.js.map +1 -1
- package/dist/i18n/locales/pt.d.ts +1 -0
- package/dist/i18n/locales/pt.d.ts.map +1 -1
- package/dist/i18n/locales/pt.js +2 -1
- package/dist/i18n/locales/pt.js.map +1 -1
- package/dist/i18n/locales/ro.d.ts +1 -0
- package/dist/i18n/locales/ro.d.ts.map +1 -1
- package/dist/i18n/locales/ro.js +2 -1
- package/dist/i18n/locales/ro.js.map +1 -1
- package/dist/i18n/locales/ru.d.ts +1 -0
- package/dist/i18n/locales/ru.d.ts.map +1 -1
- package/dist/i18n/locales/ru.js +2 -1
- package/dist/i18n/locales/ru.js.map +1 -1
- package/dist/i18n/locales/sq.d.ts +1 -0
- package/dist/i18n/locales/sq.d.ts.map +1 -1
- package/dist/i18n/locales/sq.js +2 -1
- package/dist/i18n/locales/sq.js.map +1 -1
- package/dist/i18n/locales/sv.d.ts +1 -0
- package/dist/i18n/locales/sv.d.ts.map +1 -1
- package/dist/i18n/locales/sv.js +2 -1
- package/dist/i18n/locales/sv.js.map +1 -1
- package/dist/i18n/locales/tr.d.ts +1 -0
- package/dist/i18n/locales/tr.d.ts.map +1 -1
- package/dist/i18n/locales/tr.js +2 -1
- package/dist/i18n/locales/tr.js.map +1 -1
- package/dist/i18n/locales/zh.d.ts +1 -0
- package/dist/i18n/locales/zh.d.ts.map +1 -1
- package/dist/i18n/locales/zh.js +2 -1
- package/dist/i18n/locales/zh.js.map +1 -1
- package/dist/index.js +452 -450
- package/dist/locales/ar.json +2 -1
- package/dist/locales/de.json +2 -1
- package/dist/locales/el.json +2 -1
- package/dist/locales/en.json +2 -1
- package/dist/locales/es.json +2 -1
- package/dist/locales/fr.json +2 -1
- package/dist/locales/hi.json +2 -1
- package/dist/locales/it.json +2 -1
- package/dist/locales/ja.json +2 -1
- package/dist/locales/nl.json +2 -1
- package/dist/locales/pl.json +2 -1
- package/dist/locales/pt.json +2 -1
- package/dist/locales/ro.json +2 -1
- package/dist/locales/ru.json +2 -1
- package/dist/locales/sq.json +2 -1
- package/dist/locales/sv.json +2 -1
- package/dist/locales/tr.json +2 -1
- package/dist/locales/zh.json +2 -1
- package/dist/redactor.css +54 -0
- package/package.json +10 -3
- package/dist/_chunks/booking-opt_h7Uc.js.map +0 -1
- package/dist/_chunks/map-view-UrNgxBy3.js +0 -606
- package/dist/_chunks/map-view-UrNgxBy3.js.map +0 -1
- package/dist/_chunks/practice-results-CQ_KvEXK.js.map +0 -1
|
@@ -1,61 +1,61 @@
|
|
|
1
|
-
import { jsx as n, jsxs as
|
|
2
|
-
import { forwardRef as Vn, useId as pt, useRef as A, useLayoutEffect as _t, useCallback as Me, useState as J, useEffect as V, useMemo as K, Fragment as
|
|
1
|
+
import { jsx as n, jsxs as b, Fragment as de } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef as Vn, useId as pt, useRef as A, useLayoutEffect as _t, useCallback as Me, useState as J, useEffect as V, useMemo as K, Fragment as vr, useImperativeHandle as br } from "react";
|
|
3
3
|
import { c as Lt } from "./index-D2ZczOXr.js";
|
|
4
4
|
import { useTranslation as Q, Trans as $n } from "react-i18next";
|
|
5
|
-
import { u as
|
|
5
|
+
import { u as yr } from "./registry-DvAUVLHh.js";
|
|
6
6
|
import { A as re } from "./alert-9kEwDza3.js";
|
|
7
7
|
import { B as Re } from "./button-DohK_Ak_.js";
|
|
8
8
|
import { C as wt } from "./checkbox-a7Sh-dXb.js";
|
|
9
|
-
import { C as
|
|
10
|
-
import { R as
|
|
11
|
-
import { R as
|
|
12
|
-
import { D as
|
|
13
|
-
import { E as
|
|
9
|
+
import { C as kr } from "./checkbox-group-eGdv9fZc.js";
|
|
10
|
+
import { R as Sr } from "./radio-BZQs6_36.js";
|
|
11
|
+
import { R as xr } from "./radio-group-ChIKyeSJ.js";
|
|
12
|
+
import { D as Ir } from "./date-picker-CdhXlgVI.js";
|
|
13
|
+
import { E as Nr } from "./email-input-C7THAwh2.js";
|
|
14
14
|
import { F as Je } from "./form-field-CyHfOVKF.js";
|
|
15
|
-
import { P as
|
|
16
|
-
import { T as
|
|
15
|
+
import { P as wr } from "./phone-input-DJ4BN8tG.js";
|
|
16
|
+
import { T as Cr } from "./text-area-COMVJ1yE.js";
|
|
17
17
|
import { T as Yt } from "./text-input-CaG9ApoE.js";
|
|
18
|
-
import { A as
|
|
18
|
+
import { A as Tr } from "./address-fields-qxQkGwPf.js";
|
|
19
19
|
import { S as qn } from "./spinner-CoflYlEx.js";
|
|
20
20
|
import { a as on } from "./format-price-BcFBa-WP.js";
|
|
21
|
-
import { C as
|
|
22
|
-
import { C as
|
|
23
|
-
import { O as
|
|
24
|
-
import { i as
|
|
21
|
+
import { C as Ar } from "./credit-card-D9XZsHGA.js";
|
|
22
|
+
import { C as Mr } from "./card-BA4Ig_kn.js";
|
|
23
|
+
import { O as Rr } from "./otp-input-gV1446Dw.js";
|
|
24
|
+
import { i as Or } from "./safe-href-5dbsfbQn.js";
|
|
25
25
|
import { B as zn } from "./badge-BUk4RjTS.js";
|
|
26
26
|
import { I as Mn } from "./icon-button-S8_weU3g.js";
|
|
27
27
|
import { S as an } from "./select-4S-eYZUf.js";
|
|
28
28
|
import { C as bn } from "./combobox-D-gpgEDy.js";
|
|
29
29
|
import { M as yn } from "./multi-select-i5MFRpXg.js";
|
|
30
|
-
import { c as
|
|
30
|
+
import { c as Dr } from "./option-row-Dc7BrbK8.js";
|
|
31
31
|
import { S as rn } from "./skeleton-tTWJpvAq.js";
|
|
32
32
|
import { E as kn } from "./empty-state-DwJ5YNzz.js";
|
|
33
|
-
import { S as
|
|
34
|
-
import { S as
|
|
35
|
-
import { S as
|
|
33
|
+
import { S as Er } from "./stepper-accordion-DDTSOUHc.js";
|
|
34
|
+
import { S as Fr } from "./stepper-progress-D6H8wQiV.js";
|
|
35
|
+
import { S as _r } from "./slot-grid-B-IAFX3C.js";
|
|
36
36
|
import { p as fe } from "./parseISO-DZZ5a-zK.js";
|
|
37
|
-
import { C as
|
|
37
|
+
import { C as Br } from "./chevron-down-DWE7GSq9.js";
|
|
38
38
|
import { s as rt, f as nn, d as Rn } from "./format--x5jypvH.js";
|
|
39
|
-
import { x as Kn, i as On, a as ut, b as un, s as Ft, m as
|
|
40
|
-
import { s as
|
|
39
|
+
import { x as Kn, i as On, a as ut, b as un, s as Ft, m as Lr, y as Zt } from "./date-picker-variants-Dt6UbonG.js";
|
|
40
|
+
import { s as Pr } from "./subDays-DKISP2nE.js";
|
|
41
41
|
import { c as _e } from "./createLucideIcon-DhHxpK9K.js";
|
|
42
|
-
import { M as
|
|
43
|
-
import { S as
|
|
44
|
-
import { C as
|
|
45
|
-
import { C as
|
|
46
|
-
import { H as
|
|
47
|
-
import { E as
|
|
48
|
-
import { B as
|
|
49
|
-
import { S as
|
|
50
|
-
import { A as
|
|
51
|
-
import { C as
|
|
42
|
+
import { M as Vr, S as $r } from "./sun-Bj9Mr553.js";
|
|
43
|
+
import { S as qr } from "./stethoscope-sZXGC43m.js";
|
|
44
|
+
import { C as zr } from "./chevron-left-B8cOyH-V.js";
|
|
45
|
+
import { C as Kr } from "./chevron-right-I9AeSxH2.js";
|
|
46
|
+
import { H as jr } from "./heart-pulse-BCppJyN2.js";
|
|
47
|
+
import { E as Ur } from "./eye-BjhN2nYf.js";
|
|
48
|
+
import { B as Hr } from "./baby-Dku-Xvg9.js";
|
|
49
|
+
import { S as Gr } from "./scan-line-CNseIHQ0.js";
|
|
50
|
+
import { A as Jr } from "./astroid-BN4f5VXU.js";
|
|
51
|
+
import { C as Wr } from "./clipboard-check-BeAGxDVT.js";
|
|
52
52
|
/**
|
|
53
53
|
* @license lucide-react v1.22.0 - ISC
|
|
54
54
|
*
|
|
55
55
|
* This source code is licensed under the ISC license.
|
|
56
56
|
* See the LICENSE file in the root directory of this source tree.
|
|
57
57
|
*/
|
|
58
|
-
const
|
|
58
|
+
const Yr = [
|
|
59
59
|
[
|
|
60
60
|
"path",
|
|
61
61
|
{
|
|
@@ -63,14 +63,14 @@ const Jr = [
|
|
|
63
63
|
key: "169zse"
|
|
64
64
|
}
|
|
65
65
|
]
|
|
66
|
-
],
|
|
66
|
+
], Zr = _e("activity", Yr);
|
|
67
67
|
/**
|
|
68
68
|
* @license lucide-react v1.22.0 - ISC
|
|
69
69
|
*
|
|
70
70
|
* This source code is licensed under the ISC license.
|
|
71
71
|
* See the LICENSE file in the root directory of this source tree.
|
|
72
72
|
*/
|
|
73
|
-
const
|
|
73
|
+
const Xr = [
|
|
74
74
|
[
|
|
75
75
|
"path",
|
|
76
76
|
{
|
|
@@ -78,14 +78,14 @@ const Yr = [
|
|
|
78
78
|
key: "w610uw"
|
|
79
79
|
}
|
|
80
80
|
]
|
|
81
|
-
],
|
|
81
|
+
], Qr = _e("bone", Xr);
|
|
82
82
|
/**
|
|
83
83
|
* @license lucide-react v1.22.0 - ISC
|
|
84
84
|
*
|
|
85
85
|
* This source code is licensed under the ISC license.
|
|
86
86
|
* See the LICENSE file in the root directory of this source tree.
|
|
87
87
|
*/
|
|
88
|
-
const
|
|
88
|
+
const es = [
|
|
89
89
|
["path", { d: "M12 18V5", key: "adv99a" }],
|
|
90
90
|
["path", { d: "M15 13a4.17 4.17 0 0 1-3-4 4.17 4.17 0 0 1-3 4", key: "1e3is1" }],
|
|
91
91
|
["path", { d: "M17.598 6.5A3 3 0 1 0 12 5a3 3 0 1 0-5.598 1.5", key: "1gqd8o" }],
|
|
@@ -94,14 +94,14 @@ const Xr = [
|
|
|
94
94
|
["path", { d: "M19.967 17.483A4 4 0 1 1 12 18a4 4 0 1 1-7.967-.517", key: "1gq6am" }],
|
|
95
95
|
["path", { d: "M6 18a4 4 0 0 1-2-7.464", key: "k1g0md" }],
|
|
96
96
|
["path", { d: "M6.003 5.125a4 4 0 0 0-2.526 5.77", key: "q97ue3" }]
|
|
97
|
-
],
|
|
97
|
+
], ts = _e("brain", es);
|
|
98
98
|
/**
|
|
99
99
|
* @license lucide-react v1.22.0 - ISC
|
|
100
100
|
*
|
|
101
101
|
* This source code is licensed under the ISC license.
|
|
102
102
|
* See the LICENSE file in the root directory of this source tree.
|
|
103
103
|
*/
|
|
104
|
-
const
|
|
104
|
+
const ns = [
|
|
105
105
|
["rect", { width: "18", height: "18", x: "3", y: "4", rx: "2", key: "1hopcy" }],
|
|
106
106
|
["path", { d: "M16 2v4", key: "4m81vk" }],
|
|
107
107
|
["path", { d: "M3 10h18", key: "8toen8" }],
|
|
@@ -110,76 +110,76 @@ const es = [
|
|
|
110
110
|
["path", { d: "M13 18H7", key: "bb0bb7" }],
|
|
111
111
|
["path", { d: "M7 14h.01", key: "1qa3f1" }],
|
|
112
112
|
["path", { d: "M17 18h.01", key: "1bdyru" }]
|
|
113
|
-
],
|
|
113
|
+
], rs = _e("calendar-range", ns);
|
|
114
114
|
/**
|
|
115
115
|
* @license lucide-react v1.22.0 - ISC
|
|
116
116
|
*
|
|
117
117
|
* This source code is licensed under the ISC license.
|
|
118
118
|
* See the LICENSE file in the root directory of this source tree.
|
|
119
119
|
*/
|
|
120
|
-
const
|
|
120
|
+
const ss = [
|
|
121
121
|
["path", { d: "M6 8.5a6.5 6.5 0 1 1 13 0c0 6-6 6-6 10a3.5 3.5 0 1 1-7 0", key: "1dfaln" }],
|
|
122
122
|
["path", { d: "M15 8.5a2.5 2.5 0 0 0-5 0v1a2 2 0 1 1 0 4", key: "1qnva7" }]
|
|
123
|
-
],
|
|
123
|
+
], is = _e("ear", ss);
|
|
124
124
|
/**
|
|
125
125
|
* @license lucide-react v1.22.0 - ISC
|
|
126
126
|
*
|
|
127
127
|
* This source code is licensed under the ISC license.
|
|
128
128
|
* See the LICENSE file in the root directory of this source tree.
|
|
129
129
|
*/
|
|
130
|
-
const
|
|
130
|
+
const os = [
|
|
131
131
|
["path", { d: "M6 18h8", key: "1borvv" }],
|
|
132
132
|
["path", { d: "M3 22h18", key: "8prr45" }],
|
|
133
133
|
["path", { d: "M14 22a7 7 0 1 0 0-14h-1", key: "1jwaiy" }],
|
|
134
134
|
["path", { d: "M9 14h2", key: "197e7h" }],
|
|
135
135
|
["path", { d: "M9 12a2 2 0 0 1-2-2V6h6v4a2 2 0 0 1-2 2Z", key: "1bmzmy" }],
|
|
136
136
|
["path", { d: "M12 6V3a1 1 0 0 0-1-1H9a1 1 0 0 0-1 1v3", key: "1drr47" }]
|
|
137
|
-
],
|
|
137
|
+
], as = _e("microscope", os);
|
|
138
138
|
/**
|
|
139
139
|
* @license lucide-react v1.22.0 - ISC
|
|
140
140
|
*
|
|
141
141
|
* This source code is licensed under the ISC license.
|
|
142
142
|
* See the LICENSE file in the root directory of this source tree.
|
|
143
143
|
*/
|
|
144
|
-
const
|
|
144
|
+
const cs = [
|
|
145
145
|
[
|
|
146
146
|
"path",
|
|
147
147
|
{ d: "m10.5 20.5 10-10a4.95 4.95 0 1 0-7-7l-10 10a4.95 4.95 0 1 0 7 7Z", key: "wa1lgi" }
|
|
148
148
|
],
|
|
149
149
|
["path", { d: "m8.5 8.5 7 7", key: "rvfmvr" }]
|
|
150
|
-
],
|
|
150
|
+
], ds = _e("pill", cs);
|
|
151
151
|
/**
|
|
152
152
|
* @license lucide-react v1.22.0 - ISC
|
|
153
153
|
*
|
|
154
154
|
* This source code is licensed under the ISC license.
|
|
155
155
|
* See the LICENSE file in the root directory of this source tree.
|
|
156
156
|
*/
|
|
157
|
-
const
|
|
157
|
+
const ls = [
|
|
158
158
|
["circle", { cx: "6", cy: "6", r: "3", key: "1lh9wr" }],
|
|
159
159
|
["path", { d: "M8.12 8.12 12 12", key: "1alkpv" }],
|
|
160
160
|
["path", { d: "M20 4 8.12 15.88", key: "xgtan2" }],
|
|
161
161
|
["circle", { cx: "6", cy: "18", r: "3", key: "fqmcym" }],
|
|
162
162
|
["path", { d: "M14.8 14.8 20 20", key: "ptml3r" }]
|
|
163
|
-
],
|
|
163
|
+
], us = _e("scissors", ls);
|
|
164
164
|
/**
|
|
165
165
|
* @license lucide-react v1.22.0 - ISC
|
|
166
166
|
*
|
|
167
167
|
* This source code is licensed under the ISC license.
|
|
168
168
|
* See the LICENSE file in the root directory of this source tree.
|
|
169
169
|
*/
|
|
170
|
-
const
|
|
170
|
+
const ms = [
|
|
171
171
|
["circle", { cx: "12", cy: "12", r: "10", key: "1mglay" }],
|
|
172
172
|
["path", { d: "M8 14s1.5 2 4 2 4-2 4-2", key: "1y1vjs" }],
|
|
173
173
|
["line", { x1: "9", x2: "9.01", y1: "9", y2: "9", key: "yxxnd0" }],
|
|
174
174
|
["line", { x1: "15", x2: "15.01", y1: "9", y2: "9", key: "1p4y9e" }]
|
|
175
|
-
],
|
|
175
|
+
], ps = _e("smile", ms);
|
|
176
176
|
/**
|
|
177
177
|
* @license lucide-react v1.22.0 - ISC
|
|
178
178
|
*
|
|
179
179
|
* This source code is licensed under the ISC license.
|
|
180
180
|
* See the LICENSE file in the root directory of this source tree.
|
|
181
181
|
*/
|
|
182
|
-
const
|
|
182
|
+
const fs = [
|
|
183
183
|
["path", { d: "M12 10V2", key: "16sf7g" }],
|
|
184
184
|
["path", { d: "m4.93 10.93 1.41 1.41", key: "2a7f42" }],
|
|
185
185
|
["path", { d: "M2 18h2", key: "j10viu" }],
|
|
@@ -188,25 +188,25 @@ const ms = [
|
|
|
188
188
|
["path", { d: "M22 22H2", key: "19qnx5" }],
|
|
189
189
|
["path", { d: "m16 6-4 4-4-4", key: "6wukr" }],
|
|
190
190
|
["path", { d: "M16 18a4 4 0 0 0-8 0", key: "1lzouq" }]
|
|
191
|
-
],
|
|
191
|
+
], gs = _e("sunset", fs);
|
|
192
192
|
/**
|
|
193
193
|
* @license lucide-react v1.22.0 - ISC
|
|
194
194
|
*
|
|
195
195
|
* This source code is licensed under the ISC license.
|
|
196
196
|
* See the LICENSE file in the root directory of this source tree.
|
|
197
197
|
*/
|
|
198
|
-
const
|
|
198
|
+
const hs = [
|
|
199
199
|
["path", { d: "m18 2 4 4", key: "22kx64" }],
|
|
200
200
|
["path", { d: "m17 7 3-3", key: "1w1zoj" }],
|
|
201
201
|
["path", { d: "M19 9 8.7 19.3c-1 1-2.5 1-3.4 0l-.6-.6c-1-1-1-2.5 0-3.4L15 5", key: "1exhtz" }],
|
|
202
202
|
["path", { d: "m9 11 4 4", key: "rovt3i" }],
|
|
203
203
|
["path", { d: "m5 19-3 3", key: "59f2uf" }],
|
|
204
204
|
["path", { d: "m14 4 6 6", key: "yqp9t2" }]
|
|
205
|
-
], Dn = _e("syringe",
|
|
206
|
-
function
|
|
205
|
+
], Dn = _e("syringe", hs);
|
|
206
|
+
function vs(e, t, r) {
|
|
207
207
|
return Kn(e, -1, r);
|
|
208
208
|
}
|
|
209
|
-
const
|
|
209
|
+
const bs = {
|
|
210
210
|
id: "booking",
|
|
211
211
|
// `view_change` removed (0.69): the layout `variant` is a fixed prop — the
|
|
212
212
|
// handle exposes only `getVariant` (state), no action mutates it. The flow's
|
|
@@ -286,8 +286,8 @@ const hs = {
|
|
|
286
286
|
"email",
|
|
287
287
|
"whatsapp",
|
|
288
288
|
"sms"
|
|
289
|
-
], qe = "all",
|
|
290
|
-
function
|
|
289
|
+
], qe = "all", ys = "de";
|
|
290
|
+
function ks(e) {
|
|
291
291
|
const t = e.lockedOperatorId;
|
|
292
292
|
return [...t ? e.operatorsByService ? e.specialties.filter(
|
|
293
293
|
(i) => e.services.some(
|
|
@@ -304,7 +304,7 @@ function bs(e) {
|
|
|
304
304
|
return a - o;
|
|
305
305
|
});
|
|
306
306
|
}
|
|
307
|
-
function
|
|
307
|
+
function Ss(e) {
|
|
308
308
|
let t = e.services;
|
|
309
309
|
if (e.lockedOperatorId && (t = t.filter(
|
|
310
310
|
(i) => {
|
|
@@ -319,7 +319,7 @@ function ys(e) {
|
|
|
319
319
|
}
|
|
320
320
|
return t;
|
|
321
321
|
}
|
|
322
|
-
function
|
|
322
|
+
function xs(e) {
|
|
323
323
|
const t = e.useSpecialties === void 0 ? e.specialties.length > 0 : e.useSpecialties, r = Ye(e.value);
|
|
324
324
|
if ((!t || e.operatorsByService) && r.length > 0)
|
|
325
325
|
return e.operators.filter(
|
|
@@ -340,20 +340,20 @@ function ks(e) {
|
|
|
340
340
|
}
|
|
341
341
|
return [];
|
|
342
342
|
}
|
|
343
|
-
function
|
|
344
|
-
const r = e.country ===
|
|
343
|
+
function Is(e, t) {
|
|
344
|
+
const r = e.country === ys, i = !r || e.value.insuranceType !== void 0, a = (e.useSpecialties === void 0 ? e.specialties.length > 0 : e.useSpecialties) && i, o = st(e.value).length > 0, u = !a || o, p = Ye(e.value).length > 0, f = !u || p, S = t.operators, g = !!e.allowOperatorSelection && f && p && !e.lockedOperatorId && S.length > 1, l = f && p, v = (!l || e.value.date !== void 0) && e.value.date !== void 0, O = (!v || e.value.slotKey !== void 0) && e.value.slotKey !== void 0, N = p && S.length === 0;
|
|
345
345
|
return {
|
|
346
346
|
insurance: r,
|
|
347
347
|
specialty: a,
|
|
348
|
-
service:
|
|
348
|
+
service: u,
|
|
349
349
|
operator: g,
|
|
350
|
-
date:
|
|
350
|
+
date: l,
|
|
351
351
|
slot: v,
|
|
352
|
-
details:
|
|
353
|
-
onboardingIncomplete:
|
|
352
|
+
details: O,
|
|
353
|
+
onboardingIncomplete: N
|
|
354
354
|
};
|
|
355
355
|
}
|
|
356
|
-
function
|
|
356
|
+
function Ns(e, t) {
|
|
357
357
|
const r = [];
|
|
358
358
|
return t.insurance && r.push(1), t.specialty && r.push(2), r.push(3), t.operator && r.push(4), r.push(5), r.push(6), r.push(7), {
|
|
359
359
|
currentStep: r.find(
|
|
@@ -384,18 +384,18 @@ function We(e, t) {
|
|
|
384
384
|
return !1;
|
|
385
385
|
}
|
|
386
386
|
}
|
|
387
|
-
function
|
|
387
|
+
function ws(e) {
|
|
388
388
|
const t = {
|
|
389
|
-
specialties:
|
|
390
|
-
services:
|
|
391
|
-
operators:
|
|
392
|
-
}, r =
|
|
389
|
+
specialties: ks(e),
|
|
390
|
+
services: Ss(e),
|
|
391
|
+
operators: xs(e)
|
|
392
|
+
}, r = Is(e, t), { currentStep: i, visibleSteps: s } = Ns(e, r);
|
|
393
393
|
let a;
|
|
394
394
|
if (e.value.date && e.value.slotKey) {
|
|
395
395
|
const f = e.availableSlots[e.value.date];
|
|
396
396
|
f && (a = f.find((S) => S.key === e.value.slotKey));
|
|
397
397
|
}
|
|
398
|
-
const o = Ye(e.value), c = o.length > 0 ? e.services.find((f) => f.id === o[0]) : void 0,
|
|
398
|
+
const o = Ye(e.value), c = o.length > 0 ? e.services.find((f) => f.id === o[0]) : void 0, u = st(e.value).length > 0, p = o.length > 0 && e.value.date !== void 0 && e.value.slotKey !== void 0 && (!r.insurance || e.value.insuranceType !== void 0) && (!r.specialty || u);
|
|
399
399
|
return {
|
|
400
400
|
gates: r,
|
|
401
401
|
filtered: t,
|
|
@@ -519,7 +519,7 @@ function Zn(e, t) {
|
|
|
519
519
|
slotKey: t
|
|
520
520
|
};
|
|
521
521
|
}
|
|
522
|
-
function
|
|
522
|
+
function Cs(e, t) {
|
|
523
523
|
let r = e;
|
|
524
524
|
if (t.lockedOperatorId && r.operatorId !== t.lockedOperatorId && (r = { ...r, operatorId: t.lockedOperatorId }), (t.useSpecialties === void 0 ? t.specialties.length > 0 : t.useSpecialties) && t.specialties.length === 1 && r.specialtyId === void 0 && r.specialtyIds === void 0 && (r = { ...r, specialtyId: t.specialties[0].id }), t.autoSelectSingleService) {
|
|
525
525
|
const s = st(r), a = s.length > 0 ? t.services.filter(
|
|
@@ -533,7 +533,7 @@ function Xn(e) {
|
|
|
533
533
|
if (e.operatorId && e.operatorId !== qe)
|
|
534
534
|
return e.operatorId;
|
|
535
535
|
}
|
|
536
|
-
function
|
|
536
|
+
function Ts(e) {
|
|
537
537
|
if (!e) return !1;
|
|
538
538
|
const t = e.trim();
|
|
539
539
|
return /^\+?\d[\d\s\-()]{6,}$/.test(t);
|
|
@@ -545,7 +545,7 @@ function Sn(e) {
|
|
|
545
545
|
function Qn(e, t) {
|
|
546
546
|
return t ?? (e.length === 1 ? e : ["email"]);
|
|
547
547
|
}
|
|
548
|
-
function
|
|
548
|
+
function As(e, t, r) {
|
|
549
549
|
const i = Sn(e), s = new Set(i);
|
|
550
550
|
if (r)
|
|
551
551
|
return fn.filter(
|
|
@@ -553,12 +553,12 @@ function Cs(e, t, r) {
|
|
|
553
553
|
);
|
|
554
554
|
const a = [];
|
|
555
555
|
s.has("email") && a.push("email");
|
|
556
|
-
const o =
|
|
556
|
+
const o = Ts(t), c = s.has("whatsapp");
|
|
557
557
|
c && o && a.push("whatsapp"), !c && s.has("sms") && a.push("sms");
|
|
558
|
-
const
|
|
559
|
-
return fn.filter((p) =>
|
|
558
|
+
const u = new Set(a);
|
|
559
|
+
return fn.filter((p) => u.has(p));
|
|
560
560
|
}
|
|
561
|
-
const
|
|
561
|
+
const Ms = /https?:\/\/(?:(?![.,;:!?'»›]https?:\/\/)[^\s<>"\u060C\u061B\u061F\u06D4\u2000-\u206F\u3000-\u303F\uFF00-\uFFEF])+/gi, Rs = /* @__PURE__ */ new Set([
|
|
562
562
|
".",
|
|
563
563
|
",",
|
|
564
564
|
";",
|
|
@@ -568,15 +568,15 @@ const Ts = /https?:\/\/(?:(?![.,;:!?'»›]https?:\/\/)[^\s<>"\u060C\u061B\u061F
|
|
|
568
568
|
"'",
|
|
569
569
|
"»",
|
|
570
570
|
"›"
|
|
571
|
-
]),
|
|
572
|
-
function
|
|
571
|
+
]), Os = { ")": "(", "]": "[", "}": "{" }, En = (e, t) => e.split(t).length - 1;
|
|
572
|
+
function Ds(e) {
|
|
573
573
|
const t = {};
|
|
574
|
-
for (const [i, s] of Object.entries(
|
|
574
|
+
for (const [i, s] of Object.entries(Os))
|
|
575
575
|
t[i] = En(e, i) - En(e, s);
|
|
576
576
|
let r = e.length;
|
|
577
577
|
for (; r > 0; ) {
|
|
578
578
|
const i = e[r - 1];
|
|
579
|
-
if (
|
|
579
|
+
if (Rs.has(i))
|
|
580
580
|
r -= 1;
|
|
581
581
|
else if (i in t && t[i] > 0)
|
|
582
582
|
t[i] -= 1, r -= 1;
|
|
@@ -585,12 +585,12 @@ function Rs(e) {
|
|
|
585
585
|
}
|
|
586
586
|
return e.slice(0, r);
|
|
587
587
|
}
|
|
588
|
-
const
|
|
589
|
-
function
|
|
590
|
-
const t = e.search(
|
|
591
|
-
return t > 0 &&
|
|
588
|
+
const Es = /[\u0600-\u06FF\u3040-\u30FF\u3400-\u9FFF\uAC00-\uD7AF]/, Fs = /[A-Za-z0-9]/;
|
|
589
|
+
function _s(e) {
|
|
590
|
+
const t = e.search(Es);
|
|
591
|
+
return t > 0 && Fs.test(e[t - 1]) ? e.slice(0, t) : e;
|
|
592
592
|
}
|
|
593
|
-
function
|
|
593
|
+
function Bs(e) {
|
|
594
594
|
try {
|
|
595
595
|
const { protocol: t, hostname: r } = new URL(e);
|
|
596
596
|
return (t === "http:" || t === "https:") && r !== "";
|
|
@@ -598,7 +598,7 @@ function Fs(e) {
|
|
|
598
598
|
return !1;
|
|
599
599
|
}
|
|
600
600
|
}
|
|
601
|
-
function
|
|
601
|
+
function Ls(e) {
|
|
602
602
|
const t = [];
|
|
603
603
|
let r = 0;
|
|
604
604
|
const i = (s) => {
|
|
@@ -606,13 +606,13 @@ function _s(e) {
|
|
|
606
606
|
const a = t[t.length - 1];
|
|
607
607
|
(a == null ? void 0 : a.kind) === "text" ? a.text += s : t.push({ kind: "text", text: s });
|
|
608
608
|
};
|
|
609
|
-
for (const s of e.matchAll(
|
|
610
|
-
const a = s.index ?? 0, o =
|
|
611
|
-
|
|
609
|
+
for (const s of e.matchAll(Ms)) {
|
|
610
|
+
const a = s.index ?? 0, o = Ds(_s(s[0]));
|
|
611
|
+
Bs(o) && (i(e.slice(r, a)), t.push({ kind: "link", text: o, href: o }), r = a + o.length);
|
|
612
612
|
}
|
|
613
613
|
return i(e.slice(r)), t;
|
|
614
614
|
}
|
|
615
|
-
const Fn = 500,
|
|
615
|
+
const Fn = 500, Ps = /^[A-Z0-9]{16}$/, Vs = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 300, mn = "ds:rounded-[var(--radius-sm)] ds:underline ds:text-[var(--foreground)] ds:focus-visible:outline-solid ds:focus-visible:outline-[length:var(--focus-ring-width)] ds:focus-visible:outline-[var(--ring)] ds:focus-visible:outline-offset-[length:var(--focus-ring-offset)]", Xt = (e) => e && /^https?:\/\//i.test(e) ? e : void 0, $s = (e, t) => ({
|
|
616
616
|
street: (e == null ? void 0 : e.address.line1) ?? "",
|
|
617
617
|
city: (e == null ? void 0 : e.address.city) ?? "",
|
|
618
618
|
postcode: (e == null ? void 0 : e.address.postalCode) ?? "",
|
|
@@ -620,7 +620,7 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
620
620
|
// The practice's country only until the patient has an address at all.
|
|
621
621
|
country: (e ? e.address.country : t).toLowerCase(),
|
|
622
622
|
formatted: ""
|
|
623
|
-
}),
|
|
623
|
+
}), qs = (e, t, r = null) => ({
|
|
624
624
|
name: t,
|
|
625
625
|
address: {
|
|
626
626
|
line1: e.street,
|
|
@@ -630,7 +630,7 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
630
630
|
postalCode: e.postcode,
|
|
631
631
|
country: e.country.toUpperCase()
|
|
632
632
|
}
|
|
633
|
-
}),
|
|
633
|
+
}), zs = Lt("ds:flex ds:flex-col ds:border", {
|
|
634
634
|
variants: {
|
|
635
635
|
noticeStyle: {
|
|
636
636
|
plain: "ds:gap-[var(--spacing-xs)] ds:rounded-[var(--radius-md)] ds:border-[var(--border)] ds:bg-[var(--muted)] ds:p-[var(--spacing-sm)]",
|
|
@@ -638,17 +638,17 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
638
638
|
}
|
|
639
639
|
},
|
|
640
640
|
defaultVariants: { noticeStyle: "highlighted" }
|
|
641
|
-
}),
|
|
641
|
+
}), Ks = ["it", "ch", "de", "at", "fr", "sm"], X = {
|
|
642
642
|
country: "billing.country",
|
|
643
643
|
street: "billing.street",
|
|
644
644
|
city: "billing.city",
|
|
645
645
|
postcode: "billing.postcode",
|
|
646
646
|
province: "billing.province"
|
|
647
|
-
}, er = /^\d{5}$/,
|
|
647
|
+
}, er = /^\d{5}$/, js = (e) => {
|
|
648
648
|
if (!e) return !1;
|
|
649
649
|
const { line1: t, city: r, postalCode: i, country: s, state: a } = e.address;
|
|
650
650
|
return !t.trim() || !r.trim() || !i.trim() || !s.trim() ? !1 : s.toUpperCase() !== "IT" ? !0 : !!a.trim() && er.test(i.trim());
|
|
651
|
-
},
|
|
651
|
+
}, Us = (e, t) => {
|
|
652
652
|
var r;
|
|
653
653
|
return {
|
|
654
654
|
name: t,
|
|
@@ -674,7 +674,7 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
674
674
|
X.city,
|
|
675
675
|
X.postcode,
|
|
676
676
|
X.province
|
|
677
|
-
],
|
|
677
|
+
], Hs = /* @__PURE__ */ new Set(), xn = Vn(
|
|
678
678
|
({
|
|
679
679
|
value: e,
|
|
680
680
|
onChange: t,
|
|
@@ -684,54 +684,54 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
684
684
|
requireCodiceFiscale: a = !1,
|
|
685
685
|
requireDateOfBirth: o = !1,
|
|
686
686
|
requireInsuranceNumber: c = !1,
|
|
687
|
-
insuranceType:
|
|
687
|
+
insuranceType: u,
|
|
688
688
|
showNote: p = !1,
|
|
689
689
|
showReturningPatientFlag: f = !1,
|
|
690
690
|
privacyPolicyUrl: S,
|
|
691
691
|
termsUrl: g,
|
|
692
|
-
practiceConsent:
|
|
692
|
+
practiceConsent: l,
|
|
693
693
|
payment: h,
|
|
694
694
|
paymentTermsUrl: v,
|
|
695
|
-
paymentBlocked:
|
|
696
|
-
billingInDetails:
|
|
697
|
-
paymentNoticeStyle:
|
|
698
|
-
criticalInformationToAccept:
|
|
699
|
-
validateCodiceFiscale:
|
|
700
|
-
validateInsuranceNumber:
|
|
701
|
-
submitting:
|
|
702
|
-
locked:
|
|
695
|
+
paymentBlocked: m = !1,
|
|
696
|
+
billingInDetails: O = !1,
|
|
697
|
+
paymentNoticeStyle: N = "highlighted",
|
|
698
|
+
criticalInformationToAccept: w,
|
|
699
|
+
validateCodiceFiscale: C,
|
|
700
|
+
validateInsuranceNumber: M,
|
|
701
|
+
submitting: D = !1,
|
|
702
|
+
locked: _ = !1,
|
|
703
703
|
summarySlot: R,
|
|
704
704
|
defaultPhoneCountry: $,
|
|
705
705
|
confirmationChannels: j,
|
|
706
706
|
defaultConfirmationChannels: T,
|
|
707
707
|
singleConfirmationChannel: k = !1,
|
|
708
708
|
submitError: L
|
|
709
|
-
},
|
|
709
|
+
}, F) => {
|
|
710
710
|
var Ae, Jt, It, Nt, tt;
|
|
711
|
-
const { t:
|
|
711
|
+
const { t: y, i18n: W } = Q("ui"), ne = pt(), Ne = A(null), ge = A(null);
|
|
712
712
|
_t(() => {
|
|
713
|
-
var
|
|
714
|
-
(
|
|
713
|
+
var d;
|
|
714
|
+
(d = ge.current) == null || d.setAttribute("inert", "");
|
|
715
715
|
}, []);
|
|
716
|
-
const
|
|
717
|
-
(
|
|
718
|
-
Ne.current =
|
|
716
|
+
const I = Me(
|
|
717
|
+
(d) => {
|
|
718
|
+
Ne.current = d, typeof F == "function" ? F(d) : F && (F.current = d);
|
|
719
719
|
},
|
|
720
|
-
[
|
|
720
|
+
[F]
|
|
721
721
|
), [q, Y] = J(0);
|
|
722
722
|
V(() => {
|
|
723
|
-
var
|
|
723
|
+
var E;
|
|
724
724
|
if (q === 0) return;
|
|
725
|
-
const
|
|
725
|
+
const d = (E = Ne.current) == null ? void 0 : E.querySelectorAll(
|
|
726
726
|
'[aria-invalid="true"], [role="checkbox"][aria-required="true"][aria-checked="false"], [data-unanswered] [role="checkbox"]'
|
|
727
727
|
);
|
|
728
|
-
for (const ie of
|
|
728
|
+
for (const ie of d ?? [])
|
|
729
729
|
if (ie.focus(), document.activeElement === ie) return;
|
|
730
730
|
}, [q]);
|
|
731
|
-
const U = A(!1), [ze, Be] = J(!1), [he, ve] = J(!1), be =
|
|
732
|
-
(
|
|
731
|
+
const U = A(!1), [ze, Be] = J(!1), [he, ve] = J(!1), be = D || ze, [ye, Oe] = J(Qt), [De, ke] = J(Qt), [oe, ae] = J({}), se = Me(
|
|
732
|
+
(d) => ae((E) => ({ ...E, [d]: !0 })),
|
|
733
733
|
[]
|
|
734
|
-
), [it, ft] = J(
|
|
734
|
+
), [it, ft] = J(Hs), Le = A(null), ot = A(
|
|
735
735
|
null
|
|
736
736
|
);
|
|
737
737
|
V(
|
|
@@ -741,8 +741,8 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
741
741
|
[]
|
|
742
742
|
);
|
|
743
743
|
const Z = Me(
|
|
744
|
-
(
|
|
745
|
-
ve(!1), t({ ...e, ...
|
|
744
|
+
(d) => {
|
|
745
|
+
ve(!1), t({ ...e, ...d });
|
|
746
746
|
},
|
|
747
747
|
[e, t]
|
|
748
748
|
), Ke = h ? JSON.stringify([
|
|
@@ -757,36 +757,36 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
757
757
|
V(() => {
|
|
758
758
|
Vt.current !== Ke && (Vt.current = Ke, Tt(void 0), e.paymentAccepted !== void 0 && Z({ paymentAccepted: h ? !1 : void 0 }));
|
|
759
759
|
}, [Ke, h, Z, e.paymentAccepted]);
|
|
760
|
-
const gt = typeof (
|
|
761
|
-
|
|
762
|
-
|
|
763
|
-
|
|
760
|
+
const gt = typeof (l == null ? void 0 : l.label) == "string" && l.label.trim() !== "", we = l && gt ? JSON.stringify([
|
|
761
|
+
l.label,
|
|
762
|
+
l.url ?? null,
|
|
763
|
+
l.required
|
|
764
764
|
]) : void 0, [At, $t] = J(
|
|
765
765
|
() => e.practiceConsentAccepted ? we : void 0
|
|
766
|
-
), qt = A(we),
|
|
766
|
+
), qt = A(we), le = !!(we !== void 0 && e.practiceConsentAccepted && At === we);
|
|
767
767
|
V(() => {
|
|
768
768
|
qt.current !== we && (qt.current = we, $t(void 0), e.practiceConsentAccepted !== void 0 && Z({ practiceConsentAccepted: void 0 }));
|
|
769
769
|
}, [we, Z, e.practiceConsentAccepted]);
|
|
770
|
-
const ht = h ? on(h.amountCents, h.currencyCode, W.language) : "", Se = Xt(v), Ee =
|
|
770
|
+
const ht = h ? on(h.amountCents, h.currencyCode, W.language) : "", Se = Xt(v), Ee = O && !!h && !m, pe = a, at = ($ || "it").toLowerCase(), vt = !Ee || js(e.billing), ct = $s(e.billing, at), je = ct.country === "it", bt = A(null), Xe = A(
|
|
771
771
|
null
|
|
772
772
|
), Pe = (Ae = e.billing) == null ? void 0 : Ae.address.line1.trim(), z = ((It = (Jt = e.billing) == null ? void 0 : Jt.address.line2) == null ? void 0 : It.trim()) || null;
|
|
773
773
|
V(() => {
|
|
774
|
-
var
|
|
775
|
-
Pe !== void 0 && z ? Xe.current = { street: Pe, line2: z } : (Pe === void 0 || Pe === ((
|
|
774
|
+
var d;
|
|
775
|
+
Pe !== void 0 && z ? Xe.current = { street: Pe, line2: z } : (Pe === void 0 || Pe === ((d = Xe.current) == null ? void 0 : d.street)) && (Xe.current = null);
|
|
776
776
|
}, [Pe, z]);
|
|
777
|
-
const Ve = (
|
|
777
|
+
const Ve = (d) => (
|
|
778
778
|
// Nothing for a block not shown, nor for a province outside Italy.
|
|
779
|
-
!Ee || !oe[X[
|
|
779
|
+
!Ee || !oe[X[d]] || d === "province" && !je ? void 0 : ct[d].trim() ? (
|
|
780
780
|
// The one format the block itself checks: an Italian CAP.
|
|
781
|
-
|
|
782
|
-
) :
|
|
781
|
+
d === "postcode" && je && !er.test(ct.postcode.trim()) ? y("inputs.postalCode.invalid") : void 0
|
|
782
|
+
) : y("booking.details.fieldRequired")
|
|
783
783
|
), yt = Me(
|
|
784
784
|
() => ae(
|
|
785
|
-
(
|
|
786
|
-
...
|
|
785
|
+
(d) => d[X.province] ? d : {
|
|
786
|
+
...d,
|
|
787
787
|
codiceFiscale: !0,
|
|
788
788
|
...Object.fromEntries(
|
|
789
|
-
Object.values(X).map((
|
|
789
|
+
Object.values(X).map((E) => [E, !0])
|
|
790
790
|
)
|
|
791
791
|
}
|
|
792
792
|
),
|
|
@@ -794,12 +794,12 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
794
794
|
), Ce = K(
|
|
795
795
|
() => Sn(j),
|
|
796
796
|
[j]
|
|
797
|
-
), ee = !h && !
|
|
797
|
+
), ee = !h && !m && Ce.length >= 2, xe = K(
|
|
798
798
|
() => k ? [
|
|
799
799
|
(T == null ? void 0 : T.find(
|
|
800
|
-
(
|
|
800
|
+
(d) => Ce.includes(d)
|
|
801
801
|
)) ?? Ce[0]
|
|
802
|
-
] :
|
|
802
|
+
] : As(
|
|
803
803
|
Ce,
|
|
804
804
|
e.mobilePhone,
|
|
805
805
|
T
|
|
@@ -812,7 +812,7 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
812
812
|
]
|
|
813
813
|
), kt = A(!1);
|
|
814
814
|
V(() => {
|
|
815
|
-
if (!(h ||
|
|
815
|
+
if (!(h || m)) {
|
|
816
816
|
if (!ee) {
|
|
817
817
|
e.confirmationChannels !== void 0 && Z({ confirmationChannels: void 0 });
|
|
818
818
|
return;
|
|
@@ -829,7 +829,7 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
829
829
|
xe,
|
|
830
830
|
ee,
|
|
831
831
|
h,
|
|
832
|
-
|
|
832
|
+
m,
|
|
833
833
|
Ce,
|
|
834
834
|
e.mobilePhone,
|
|
835
835
|
T,
|
|
@@ -838,79 +838,79 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
838
838
|
const Ue = e.confirmationChannels ?? xe, St = ee && Ue.length === 0, Te = Qn(
|
|
839
839
|
Ce,
|
|
840
840
|
ee ? Ue : void 0
|
|
841
|
-
), dt = !s || Te.includes("email"), Mt = A(
|
|
841
|
+
), dt = !s || Te.includes("email"), Mt = A(C), zt = A(M);
|
|
842
842
|
V(() => {
|
|
843
|
-
Mt.current =
|
|
844
|
-
}, [
|
|
845
|
-
const Kt = !!
|
|
843
|
+
Mt.current = C, zt.current = M;
|
|
844
|
+
}, [C, M]);
|
|
845
|
+
const Kt = !!C, He = !!M;
|
|
846
846
|
V(() => {
|
|
847
|
-
const
|
|
848
|
-
if (!pe || !Kt || !
|
|
847
|
+
const d = e.codiceFiscale;
|
|
848
|
+
if (!pe || !Kt || !d) {
|
|
849
849
|
Oe(Qt);
|
|
850
850
|
return;
|
|
851
851
|
}
|
|
852
|
-
if (!
|
|
852
|
+
if (!Ps.test(d)) {
|
|
853
853
|
Oe({
|
|
854
854
|
state: "invalid",
|
|
855
|
-
hint:
|
|
855
|
+
hint: y("booking.details.codiceFiscale.invalidFormat")
|
|
856
856
|
});
|
|
857
857
|
return;
|
|
858
858
|
}
|
|
859
859
|
Oe({ state: "pending" });
|
|
860
|
-
let
|
|
860
|
+
let E = !0;
|
|
861
861
|
return Le.current && clearTimeout(Le.current), Le.current = setTimeout(async () => {
|
|
862
862
|
try {
|
|
863
863
|
const ie = Mt.current;
|
|
864
864
|
if (!ie) return;
|
|
865
|
-
const nt = await ie(
|
|
866
|
-
|
|
865
|
+
const nt = await ie(d);
|
|
866
|
+
E && Oe({
|
|
867
867
|
state: nt.valid ? "valid" : "invalid",
|
|
868
868
|
hint: nt.hint,
|
|
869
|
-
value:
|
|
869
|
+
value: d
|
|
870
870
|
});
|
|
871
871
|
} catch {
|
|
872
|
-
|
|
872
|
+
E && Oe({
|
|
873
873
|
state: "invalid",
|
|
874
|
-
hint:
|
|
875
|
-
value:
|
|
874
|
+
hint: y("booking.details.codiceFiscale.unavailable"),
|
|
875
|
+
value: d
|
|
876
876
|
});
|
|
877
877
|
}
|
|
878
878
|
}, _n), () => {
|
|
879
|
-
|
|
879
|
+
E = !1, Le.current && clearTimeout(Le.current);
|
|
880
880
|
};
|
|
881
|
-
}, [pe, Kt, e.codiceFiscale,
|
|
882
|
-
const $e = c &&
|
|
881
|
+
}, [pe, Kt, e.codiceFiscale, y]);
|
|
882
|
+
const $e = c && u === "public";
|
|
883
883
|
V(() => {
|
|
884
|
-
const
|
|
885
|
-
if (!$e || !He || !
|
|
884
|
+
const d = e.insuranceNumber;
|
|
885
|
+
if (!$e || !He || !d) {
|
|
886
886
|
ke(Qt);
|
|
887
887
|
return;
|
|
888
888
|
}
|
|
889
889
|
ke({ state: "pending" }), ot.current && clearTimeout(ot.current), ot.current = setTimeout(() => {
|
|
890
|
-
const
|
|
891
|
-
|
|
890
|
+
const E = zt.current;
|
|
891
|
+
E && E(d).then(
|
|
892
892
|
(ie) => ke(
|
|
893
893
|
ie.valid ? { state: "valid" } : { state: "invalid", hint: ie.hint }
|
|
894
894
|
)
|
|
895
895
|
).catch(
|
|
896
896
|
() => ke({
|
|
897
897
|
state: "invalid",
|
|
898
|
-
hint:
|
|
898
|
+
hint: y("booking.details.insuranceNumber.unavailable")
|
|
899
899
|
})
|
|
900
900
|
);
|
|
901
901
|
}, _n);
|
|
902
|
-
}, [$e, He, e.insuranceNumber,
|
|
902
|
+
}, [$e, He, e.insuranceNumber, y]);
|
|
903
903
|
const G = K(() => {
|
|
904
|
-
var
|
|
904
|
+
var E;
|
|
905
905
|
if (i) return !0;
|
|
906
|
-
const
|
|
907
|
-
return !dt && !
|
|
906
|
+
const d = s ? (E = e.email) == null ? void 0 : E.trim() : e.email;
|
|
907
|
+
return !dt && !d ? !0 : !!(d && Vs.test(d));
|
|
908
908
|
}, [i, s, dt, e.email]), H = K(
|
|
909
909
|
() => !!(e.mobilePhone && e.mobilePhone.length >= 6),
|
|
910
910
|
[e.mobilePhone]
|
|
911
911
|
), jt = K(() => {
|
|
912
|
-
var
|
|
913
|
-
return !(!((
|
|
912
|
+
var d, E;
|
|
913
|
+
return !(!((d = e.firstName) != null && d.trim()) || !((E = e.lastName) != null && E.trim()) || !G || !H || pe && (ye.state !== "valid" || ye.value !== e.codiceFiscale) || !vt || o && !e.dateOfBirth || $e && De.state !== "valid");
|
|
914
914
|
}, [
|
|
915
915
|
e.firstName,
|
|
916
916
|
e.lastName,
|
|
@@ -925,26 +925,26 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
925
925
|
e.dateOfBirth,
|
|
926
926
|
$e,
|
|
927
927
|
De.state
|
|
928
|
-
]), Qe =
|
|
929
|
-
firstName: oe.firstName && !((Nt = e.firstName) != null && Nt.trim()) ?
|
|
930
|
-
lastName: oe.lastName && !((tt = e.lastName) != null && tt.trim()) ?
|
|
931
|
-
email: !i && oe.email && !G ?
|
|
932
|
-
mobilePhone: oe.mobilePhone && !H ?
|
|
933
|
-
codiceFiscale: oe.codiceFiscale && ye.state === "invalid" ? ye.hint ??
|
|
934
|
-
dateOfBirth: oe.dateOfBirth && !e.dateOfBirth ?
|
|
935
|
-
insuranceNumber: oe.insuranceNumber && De.state === "invalid" ? De.hint ??
|
|
928
|
+
]), Qe = w != null && w.trim() ? w : void 0, xt = Qe !== void 0, dn = !xt || !!e.criticalInformationAccepted, ln = !gt || !(l != null && l.required) || le, Ut = !!(e.privacyConsent && e.termsConsent && dn && ln), Ht = !ee || Ue.length > 0, lt = jt && Ut && Ht && (!h || Ze) && !m && !be, Rt = !lt && !be && !m, Ot = `${ne}-submit-hint`, te = {
|
|
929
|
+
firstName: oe.firstName && !((Nt = e.firstName) != null && Nt.trim()) ? y("booking.details.firstName.required") : void 0,
|
|
930
|
+
lastName: oe.lastName && !((tt = e.lastName) != null && tt.trim()) ? y("booking.details.lastName.required") : void 0,
|
|
931
|
+
email: !i && oe.email && !G ? y("booking.details.email.invalid") : void 0,
|
|
932
|
+
mobilePhone: oe.mobilePhone && !H ? y("booking.details.mobilePhone.invalid") : void 0,
|
|
933
|
+
codiceFiscale: oe.codiceFiscale && ye.state === "invalid" ? ye.hint ?? y("booking.details.codiceFiscale.invalid") : oe.codiceFiscale && !e.codiceFiscale ? y("booking.details.fieldRequired") : void 0,
|
|
934
|
+
dateOfBirth: oe.dateOfBirth && !e.dateOfBirth ? y("booking.details.dateOfBirth.required") : void 0,
|
|
935
|
+
insuranceNumber: oe.insuranceNumber && De.state === "invalid" ? De.hint ?? y("booking.details.insuranceNumber.invalid") : void 0,
|
|
936
936
|
[X.country]: Ve("country"),
|
|
937
937
|
[X.street]: Ve("street"),
|
|
938
938
|
[X.city]: Ve("city"),
|
|
939
939
|
[X.postcode]: Ve("postcode"),
|
|
940
940
|
[X.province]: Ve("province")
|
|
941
941
|
}, Dt = Bn.filter(
|
|
942
|
-
(
|
|
942
|
+
(d) => it.has(d) && te[d] !== void 0
|
|
943
943
|
);
|
|
944
944
|
Dt.length !== it.size && ft(new Set(Dt));
|
|
945
|
-
const
|
|
945
|
+
const ue = (d) => !it.has(d), et = async (d) => {
|
|
946
946
|
var ie, nt;
|
|
947
|
-
if (
|
|
947
|
+
if (d.preventDefault(), !be && !U.current && !lt && ft(
|
|
948
948
|
new Set(
|
|
949
949
|
Bn.filter(
|
|
950
950
|
(Ge) => it.has(Ge) || !te[Ge]
|
|
@@ -966,7 +966,7 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
966
966
|
Y((Ge) => Ge + 1);
|
|
967
967
|
return;
|
|
968
968
|
}
|
|
969
|
-
const
|
|
969
|
+
const E = {
|
|
970
970
|
firstName: e.firstName.trim(),
|
|
971
971
|
lastName: e.lastName.trim(),
|
|
972
972
|
...!i && ((ie = e.email) != null && ie.trim()) ? { email: e.email.trim() } : {},
|
|
@@ -981,7 +981,7 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
981
981
|
...xt ? { criticalInformationAccepted: !0 } : {},
|
|
982
982
|
// Sent whenever the practice's box is shown, ticked or not, so the
|
|
983
983
|
// server can record the answer; left out when there is no box.
|
|
984
|
-
...gt ? { practiceConsentAccepted:
|
|
984
|
+
...gt ? { practiceConsentAccepted: le } : {},
|
|
985
985
|
...h ? { paymentAccepted: !0 } : {},
|
|
986
986
|
codiceFiscale: e.codiceFiscale,
|
|
987
987
|
dateOfBirth: e.dateOfBirth,
|
|
@@ -993,7 +993,7 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
993
993
|
// config.
|
|
994
994
|
confirmationChannels: ee ? Ue : void 0,
|
|
995
995
|
...Ee && e.billing ? {
|
|
996
|
-
billing:
|
|
996
|
+
billing: Us(
|
|
997
997
|
e.billing,
|
|
998
998
|
`${e.firstName.trim()} ${e.lastName.trim()}`
|
|
999
999
|
)
|
|
@@ -1001,7 +1001,7 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
1001
1001
|
};
|
|
1002
1002
|
U.current = !0, Be(!0), ve(!1);
|
|
1003
1003
|
try {
|
|
1004
|
-
await r(
|
|
1004
|
+
await r(E);
|
|
1005
1005
|
} catch {
|
|
1006
1006
|
ve(!0);
|
|
1007
1007
|
} finally {
|
|
@@ -1010,30 +1010,30 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
1010
1010
|
}, Et = /* @__PURE__ */ n(
|
|
1011
1011
|
Je,
|
|
1012
1012
|
{
|
|
1013
|
-
label:
|
|
1013
|
+
label: y("booking.details.codiceFiscale.label"),
|
|
1014
1014
|
required: !0,
|
|
1015
|
-
description: ye.state === "pending" ?
|
|
1015
|
+
description: ye.state === "pending" ? y("booking.details.codiceFiscale.checking") : y("booking.details.codiceFiscale.helper"),
|
|
1016
1016
|
error: te.codiceFiscale,
|
|
1017
|
-
announceError:
|
|
1017
|
+
announceError: ue("codiceFiscale"),
|
|
1018
1018
|
children: /* @__PURE__ */ n(
|
|
1019
1019
|
Yt,
|
|
1020
1020
|
{
|
|
1021
1021
|
value: e.codiceFiscale ?? "",
|
|
1022
1022
|
maxLength: 16,
|
|
1023
|
-
onChange: (
|
|
1024
|
-
codiceFiscale:
|
|
1023
|
+
onChange: (d) => Z({
|
|
1024
|
+
codiceFiscale: d.target.value.slice(0, 16).toUpperCase()
|
|
1025
1025
|
}),
|
|
1026
1026
|
onBlur: () => se("codiceFiscale")
|
|
1027
1027
|
}
|
|
1028
1028
|
)
|
|
1029
1029
|
}
|
|
1030
|
-
), Gt = (
|
|
1031
|
-
const ie = Xt(
|
|
1030
|
+
), Gt = (d, E) => {
|
|
1031
|
+
const ie = Xt(E);
|
|
1032
1032
|
return ie ? /* @__PURE__ */ n(
|
|
1033
1033
|
$n,
|
|
1034
1034
|
{
|
|
1035
1035
|
ns: "ui",
|
|
1036
|
-
i18nKey:
|
|
1036
|
+
i18nKey: d,
|
|
1037
1037
|
components: {
|
|
1038
1038
|
// The `<Trans>` runtime injects link text from the i18n
|
|
1039
1039
|
// string. The anchor renders empty at static-analysis time,
|
|
@@ -1054,18 +1054,18 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
1054
1054
|
)
|
|
1055
1055
|
}
|
|
1056
1056
|
}
|
|
1057
|
-
) :
|
|
1057
|
+
) : y(d);
|
|
1058
1058
|
};
|
|
1059
|
-
return /* @__PURE__ */
|
|
1059
|
+
return /* @__PURE__ */ b(
|
|
1060
1060
|
"form",
|
|
1061
1061
|
{
|
|
1062
|
-
ref:
|
|
1062
|
+
ref: I,
|
|
1063
1063
|
id: ne,
|
|
1064
1064
|
noValidate: !0,
|
|
1065
1065
|
onSubmit: et,
|
|
1066
|
-
onFocus: (
|
|
1067
|
-
const
|
|
1068
|
-
!
|
|
1066
|
+
onFocus: (d) => {
|
|
1067
|
+
const E = bt.current;
|
|
1068
|
+
!E || !d.currentTarget.contains(d.target) || !E.contains(d.target) && E.compareDocumentPosition(d.target) & Node.DOCUMENT_POSITION_FOLLOWING && yt();
|
|
1069
1069
|
},
|
|
1070
1070
|
"aria-busy": be || void 0,
|
|
1071
1071
|
className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)]",
|
|
@@ -1088,20 +1088,20 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
1088
1088
|
className: "ds:sr-only ds:pointer-events-none"
|
|
1089
1089
|
}
|
|
1090
1090
|
),
|
|
1091
|
-
/* @__PURE__ */
|
|
1091
|
+
/* @__PURE__ */ b("div", { className: "ds:grid ds:grid-cols-1 ds:gap-[var(--spacing-sm)] ds:sm:grid-cols-2", children: [
|
|
1092
1092
|
/* @__PURE__ */ n(
|
|
1093
1093
|
Je,
|
|
1094
1094
|
{
|
|
1095
|
-
label:
|
|
1095
|
+
label: y("booking.details.firstName.label"),
|
|
1096
1096
|
required: !0,
|
|
1097
1097
|
error: te.firstName,
|
|
1098
|
-
announceError:
|
|
1098
|
+
announceError: ue("firstName"),
|
|
1099
1099
|
children: /* @__PURE__ */ n(
|
|
1100
1100
|
Yt,
|
|
1101
1101
|
{
|
|
1102
1102
|
autoComplete: "given-name",
|
|
1103
1103
|
value: e.firstName ?? "",
|
|
1104
|
-
onChange: (
|
|
1104
|
+
onChange: (d) => Z({ firstName: d.target.value }),
|
|
1105
1105
|
onBlur: () => se("firstName")
|
|
1106
1106
|
}
|
|
1107
1107
|
)
|
|
@@ -1110,23 +1110,23 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
1110
1110
|
/* @__PURE__ */ n(
|
|
1111
1111
|
Je,
|
|
1112
1112
|
{
|
|
1113
|
-
label:
|
|
1113
|
+
label: y("booking.details.lastName.label"),
|
|
1114
1114
|
required: !0,
|
|
1115
1115
|
error: te.lastName,
|
|
1116
|
-
announceError:
|
|
1116
|
+
announceError: ue("lastName"),
|
|
1117
1117
|
children: /* @__PURE__ */ n(
|
|
1118
1118
|
Yt,
|
|
1119
1119
|
{
|
|
1120
1120
|
autoComplete: "family-name",
|
|
1121
1121
|
value: e.lastName ?? "",
|
|
1122
|
-
onChange: (
|
|
1122
|
+
onChange: (d) => Z({ lastName: d.target.value }),
|
|
1123
1123
|
onBlur: () => se("lastName")
|
|
1124
1124
|
}
|
|
1125
1125
|
)
|
|
1126
1126
|
}
|
|
1127
1127
|
)
|
|
1128
1128
|
] }),
|
|
1129
|
-
/* @__PURE__ */
|
|
1129
|
+
/* @__PURE__ */ b(
|
|
1130
1130
|
"div",
|
|
1131
1131
|
{
|
|
1132
1132
|
className: `ds:grid ds:grid-cols-1 ds:gap-[var(--spacing-sm)]${i ? "" : " ds:sm:grid-cols-2"}`,
|
|
@@ -1134,16 +1134,16 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
1134
1134
|
!i && /* @__PURE__ */ n(
|
|
1135
1135
|
Je,
|
|
1136
1136
|
{
|
|
1137
|
-
label:
|
|
1137
|
+
label: y("booking.details.email.label"),
|
|
1138
1138
|
...dt ? { required: !0 } : { optional: !0 },
|
|
1139
1139
|
error: te.email,
|
|
1140
|
-
announceError:
|
|
1140
|
+
announceError: ue("email"),
|
|
1141
1141
|
children: /* @__PURE__ */ n(
|
|
1142
|
-
|
|
1142
|
+
Nr,
|
|
1143
1143
|
{
|
|
1144
1144
|
disableBuiltInValidation: s,
|
|
1145
1145
|
value: e.email ?? "",
|
|
1146
|
-
onChange: (
|
|
1146
|
+
onChange: (d) => Z({ email: d.target.value }),
|
|
1147
1147
|
onBlur: () => se("email")
|
|
1148
1148
|
}
|
|
1149
1149
|
)
|
|
@@ -1152,17 +1152,17 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
1152
1152
|
/* @__PURE__ */ n(
|
|
1153
1153
|
Je,
|
|
1154
1154
|
{
|
|
1155
|
-
label:
|
|
1155
|
+
label: y("booking.details.mobilePhone.label"),
|
|
1156
1156
|
required: !0,
|
|
1157
1157
|
error: te.mobilePhone,
|
|
1158
|
-
announceError:
|
|
1158
|
+
announceError: ue("mobilePhone"),
|
|
1159
1159
|
children: /* @__PURE__ */ n(
|
|
1160
|
-
|
|
1160
|
+
wr,
|
|
1161
1161
|
{
|
|
1162
1162
|
value: e.mobilePhone ?? "",
|
|
1163
1163
|
defaultCountry: $ == null ? void 0 : $.toUpperCase(),
|
|
1164
|
-
onChange: (
|
|
1165
|
-
Z({ mobilePhone:
|
|
1164
|
+
onChange: (d) => {
|
|
1165
|
+
Z({ mobilePhone: d });
|
|
1166
1166
|
},
|
|
1167
1167
|
onBlur: () => se("mobilePhone")
|
|
1168
1168
|
}
|
|
@@ -1172,22 +1172,22 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
1172
1172
|
]
|
|
1173
1173
|
}
|
|
1174
1174
|
),
|
|
1175
|
-
pe && !Ee || o ? /* @__PURE__ */
|
|
1175
|
+
pe && !Ee || o ? /* @__PURE__ */ b("div", { className: "ds:grid ds:grid-cols-1 ds:gap-[var(--spacing-sm)] ds:sm:grid-cols-2", children: [
|
|
1176
1176
|
pe && !Ee ? Et : null,
|
|
1177
1177
|
o ? /* @__PURE__ */ n(
|
|
1178
1178
|
Je,
|
|
1179
1179
|
{
|
|
1180
|
-
label:
|
|
1180
|
+
label: y("booking.details.dateOfBirth.label"),
|
|
1181
1181
|
required: !0,
|
|
1182
1182
|
error: te.dateOfBirth,
|
|
1183
|
-
announceError:
|
|
1183
|
+
announceError: ue("dateOfBirth"),
|
|
1184
1184
|
children: /* @__PURE__ */ n(
|
|
1185
|
-
|
|
1185
|
+
Ir,
|
|
1186
1186
|
{
|
|
1187
1187
|
value: e.dateOfBirth ? new Date(e.dateOfBirth) : void 0,
|
|
1188
|
-
onChange: (
|
|
1188
|
+
onChange: (d) => {
|
|
1189
1189
|
Z({
|
|
1190
|
-
dateOfBirth:
|
|
1190
|
+
dateOfBirth: d ? d.toISOString().slice(0, 10) : void 0
|
|
1191
1191
|
}), se("dateOfBirth");
|
|
1192
1192
|
}
|
|
1193
1193
|
}
|
|
@@ -1198,22 +1198,22 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
1198
1198
|
$e ? /* @__PURE__ */ n(
|
|
1199
1199
|
Je,
|
|
1200
1200
|
{
|
|
1201
|
-
label:
|
|
1201
|
+
label: y("booking.details.insuranceNumber.label"),
|
|
1202
1202
|
required: !0,
|
|
1203
|
-
description: De.state === "pending" ?
|
|
1203
|
+
description: De.state === "pending" ? y("booking.details.insuranceNumber.checking") : void 0,
|
|
1204
1204
|
error: te.insuranceNumber,
|
|
1205
|
-
announceError:
|
|
1205
|
+
announceError: ue("insuranceNumber"),
|
|
1206
1206
|
children: /* @__PURE__ */ n(
|
|
1207
1207
|
Yt,
|
|
1208
1208
|
{
|
|
1209
1209
|
value: e.insuranceNumber ?? "",
|
|
1210
|
-
onChange: (
|
|
1210
|
+
onChange: (d) => Z({ insuranceNumber: d.target.value }),
|
|
1211
1211
|
onBlur: () => se("insuranceNumber")
|
|
1212
1212
|
}
|
|
1213
1213
|
)
|
|
1214
1214
|
}
|
|
1215
1215
|
) : null,
|
|
1216
|
-
Ee ? /* @__PURE__ */
|
|
1216
|
+
Ee ? /* @__PURE__ */ b(
|
|
1217
1217
|
"div",
|
|
1218
1218
|
{
|
|
1219
1219
|
ref: bt,
|
|
@@ -1222,19 +1222,19 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
1222
1222
|
"aria-labelledby": `${ne}-billing-heading`,
|
|
1223
1223
|
"aria-describedby": `${ne}-billing-intro`,
|
|
1224
1224
|
className: "ds:flex ds:flex-col ds:gap-[var(--spacing-sm)] ds:rounded-[var(--radius-md)] ds:border ds:border-[var(--border)] ds:p-[var(--spacing-sm)]",
|
|
1225
|
-
onBlur: (
|
|
1225
|
+
onBlur: (d) => {
|
|
1226
1226
|
var ie;
|
|
1227
|
-
const
|
|
1228
|
-
(
|
|
1227
|
+
const E = (ie = d.target.closest("[data-address-field]")) == null ? void 0 : ie.getAttribute("data-address-field");
|
|
1228
|
+
(E === "street" || E === "city" || E === "postcode") && se(X[E]);
|
|
1229
1229
|
},
|
|
1230
1230
|
children: [
|
|
1231
|
-
/* @__PURE__ */
|
|
1231
|
+
/* @__PURE__ */ b("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-2xs)]", children: [
|
|
1232
1232
|
/* @__PURE__ */ n(
|
|
1233
1233
|
"h3",
|
|
1234
1234
|
{
|
|
1235
1235
|
id: `${ne}-billing-heading`,
|
|
1236
1236
|
className: "type-label ds:m-0 ds:font-[var(--font-weight-semibold)] ds:text-[var(--foreground)]",
|
|
1237
|
-
children:
|
|
1237
|
+
children: y("booking.details.billing.heading")
|
|
1238
1238
|
}
|
|
1239
1239
|
),
|
|
1240
1240
|
/* @__PURE__ */ n(
|
|
@@ -1242,31 +1242,31 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
1242
1242
|
{
|
|
1243
1243
|
id: `${ne}-billing-intro`,
|
|
1244
1244
|
className: "type-body-sm ds:m-0 ds:text-[color:var(--muted-foreground)]",
|
|
1245
|
-
children:
|
|
1245
|
+
children: y("booking.details.billing.intro")
|
|
1246
1246
|
}
|
|
1247
1247
|
)
|
|
1248
1248
|
] }),
|
|
1249
1249
|
pe ? Et : null,
|
|
1250
1250
|
/* @__PURE__ */ n(
|
|
1251
|
-
|
|
1251
|
+
Tr,
|
|
1252
1252
|
{
|
|
1253
1253
|
value: ct,
|
|
1254
|
-
onChange: (
|
|
1255
|
-
var
|
|
1254
|
+
onChange: (d) => {
|
|
1255
|
+
var E;
|
|
1256
1256
|
return (
|
|
1257
1257
|
// The name is set from the patient's own on submit.
|
|
1258
1258
|
Z({
|
|
1259
|
-
billing:
|
|
1260
|
-
|
|
1259
|
+
billing: qs(
|
|
1260
|
+
d,
|
|
1261
1261
|
"",
|
|
1262
1262
|
// A second line belongs to its street: it goes when the
|
|
1263
1263
|
// patient writes another, and returns with the first.
|
|
1264
|
-
|
|
1264
|
+
d.street.trim() === ((E = Xe.current) == null ? void 0 : E.street) ? Xe.current.line2 : null
|
|
1265
1265
|
)
|
|
1266
1266
|
})
|
|
1267
1267
|
);
|
|
1268
1268
|
},
|
|
1269
|
-
popularCountries:
|
|
1269
|
+
popularCountries: Ks,
|
|
1270
1270
|
layout: "grid",
|
|
1271
1271
|
fields: je ? void 0 : ["street", "city", "postcode"],
|
|
1272
1272
|
required: je ? ["country", "street", "city", "postcode", "province"] : ["country", "street", "city", "postcode"],
|
|
@@ -1278,11 +1278,11 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
1278
1278
|
province: te[X.province]
|
|
1279
1279
|
},
|
|
1280
1280
|
announceErrors: {
|
|
1281
|
-
country:
|
|
1282
|
-
street:
|
|
1283
|
-
city:
|
|
1284
|
-
postcode:
|
|
1285
|
-
province:
|
|
1281
|
+
country: ue(X.country),
|
|
1282
|
+
street: ue(X.street),
|
|
1283
|
+
city: ue(X.city),
|
|
1284
|
+
postcode: ue(X.postcode),
|
|
1285
|
+
province: ue(X.province)
|
|
1286
1286
|
}
|
|
1287
1287
|
}
|
|
1288
1288
|
)
|
|
@@ -1292,18 +1292,18 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
1292
1292
|
p ? /* @__PURE__ */ n(
|
|
1293
1293
|
Je,
|
|
1294
1294
|
{
|
|
1295
|
-
label:
|
|
1295
|
+
label: y("booking.details.note.label"),
|
|
1296
1296
|
optional: !0,
|
|
1297
|
-
description:
|
|
1297
|
+
description: y("booking.details.note.helper", {
|
|
1298
1298
|
max: Fn
|
|
1299
1299
|
}),
|
|
1300
1300
|
children: /* @__PURE__ */ n(
|
|
1301
|
-
|
|
1301
|
+
Cr,
|
|
1302
1302
|
{
|
|
1303
1303
|
value: e.note ?? "",
|
|
1304
1304
|
maxLength: Fn,
|
|
1305
1305
|
rows: 3,
|
|
1306
|
-
onChange: (
|
|
1306
|
+
onChange: (d) => Z({ note: d.target.value })
|
|
1307
1307
|
}
|
|
1308
1308
|
)
|
|
1309
1309
|
}
|
|
@@ -1312,11 +1312,11 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
1312
1312
|
wt,
|
|
1313
1313
|
{
|
|
1314
1314
|
checked: !!e.returningPatient,
|
|
1315
|
-
onCheckedChange: (
|
|
1316
|
-
label:
|
|
1315
|
+
onCheckedChange: (d) => Z({ returningPatient: d === !0 }),
|
|
1316
|
+
label: y("booking.details.returningPatient.label")
|
|
1317
1317
|
}
|
|
1318
1318
|
) : null,
|
|
1319
|
-
Qe !== void 0 ? /* @__PURE__ */
|
|
1319
|
+
Qe !== void 0 ? /* @__PURE__ */ b(
|
|
1320
1320
|
"div",
|
|
1321
1321
|
{
|
|
1322
1322
|
"data-component": "booking-critical-information",
|
|
@@ -1329,7 +1329,7 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
1329
1329
|
{
|
|
1330
1330
|
id: `${ne}-critical-information-heading`,
|
|
1331
1331
|
className: "type-label ds:font-[var(--font-weight-semibold)] ds:text-[var(--foreground)] ds:m-0",
|
|
1332
|
-
children:
|
|
1332
|
+
children: y("booking.details.criticalInformation.heading")
|
|
1333
1333
|
}
|
|
1334
1334
|
),
|
|
1335
1335
|
/* @__PURE__ */ n(
|
|
@@ -1337,19 +1337,19 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
1337
1337
|
{
|
|
1338
1338
|
dir: "auto",
|
|
1339
1339
|
className: "type-body-sm ds:m-0 ds:whitespace-pre-wrap ds:break-words ds:text-[var(--foreground)]",
|
|
1340
|
-
children:
|
|
1341
|
-
(
|
|
1340
|
+
children: Ls(Qe).map(
|
|
1341
|
+
(d, E) => d.kind === "link" ? /* @__PURE__ */ n(
|
|
1342
1342
|
"a",
|
|
1343
1343
|
{
|
|
1344
|
-
href:
|
|
1344
|
+
href: d.href,
|
|
1345
1345
|
target: "_blank",
|
|
1346
1346
|
rel: "noopener noreferrer",
|
|
1347
1347
|
dir: "ltr",
|
|
1348
1348
|
className: mn,
|
|
1349
|
-
children:
|
|
1349
|
+
children: d.text
|
|
1350
1350
|
},
|
|
1351
|
-
|
|
1352
|
-
) : /* @__PURE__ */ n(
|
|
1351
|
+
E
|
|
1352
|
+
) : /* @__PURE__ */ n(vr, { children: d.text }, E)
|
|
1353
1353
|
)
|
|
1354
1354
|
}
|
|
1355
1355
|
),
|
|
@@ -1357,10 +1357,10 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
1357
1357
|
wt,
|
|
1358
1358
|
{
|
|
1359
1359
|
checked: !!e.criticalInformationAccepted,
|
|
1360
|
-
onCheckedChange: (
|
|
1360
|
+
onCheckedChange: (d) => Z({ criticalInformationAccepted: d === !0 }),
|
|
1361
1361
|
"aria-required": !0,
|
|
1362
|
-
label: /* @__PURE__ */
|
|
1363
|
-
|
|
1362
|
+
label: /* @__PURE__ */ b(de, { children: [
|
|
1363
|
+
y("booking.details.criticalInformation.accept"),
|
|
1364
1364
|
/* @__PURE__ */ n(
|
|
1365
1365
|
"span",
|
|
1366
1366
|
{
|
|
@@ -1375,25 +1375,25 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
1375
1375
|
]
|
|
1376
1376
|
}
|
|
1377
1377
|
) : null,
|
|
1378
|
-
h ? /* @__PURE__ */
|
|
1378
|
+
h ? /* @__PURE__ */ b(
|
|
1379
1379
|
"div",
|
|
1380
1380
|
{
|
|
1381
1381
|
"data-component": "booking-payment-notice",
|
|
1382
1382
|
role: "group",
|
|
1383
1383
|
"aria-labelledby": `${ne}-payment-heading`,
|
|
1384
|
-
"data-notice-style":
|
|
1385
|
-
className:
|
|
1386
|
-
noticeStyle:
|
|
1384
|
+
"data-notice-style": N,
|
|
1385
|
+
className: zs({
|
|
1386
|
+
noticeStyle: N
|
|
1387
1387
|
}),
|
|
1388
1388
|
children: [
|
|
1389
|
-
|
|
1390
|
-
/* @__PURE__ */ n("span", { className: "ds:flex ds:size-9 ds:shrink-0 ds:items-center ds:justify-center ds:rounded-full ds:bg-[var(--primary)] ds:text-[var(--primary-foreground)]", children: /* @__PURE__ */ n(
|
|
1389
|
+
N === "highlighted" ? /* @__PURE__ */ b("div", { className: "ds:flex ds:items-center ds:gap-[var(--spacing-sm)]", children: [
|
|
1390
|
+
/* @__PURE__ */ n("span", { className: "ds:flex ds:size-9 ds:shrink-0 ds:items-center ds:justify-center ds:rounded-full ds:bg-[var(--primary)] ds:text-[var(--primary-foreground)]", children: /* @__PURE__ */ n(Ar, { "aria-hidden": "true", className: "ds:size-5" }) }),
|
|
1391
1391
|
/* @__PURE__ */ n(
|
|
1392
1392
|
"h3",
|
|
1393
1393
|
{
|
|
1394
1394
|
id: `${ne}-payment-heading`,
|
|
1395
1395
|
className: "type-title-item ds:m-0 ds:flex-1",
|
|
1396
|
-
children:
|
|
1396
|
+
children: y("booking.payment.noticeTitle")
|
|
1397
1397
|
}
|
|
1398
1398
|
),
|
|
1399
1399
|
/* @__PURE__ */ n(
|
|
@@ -1409,10 +1409,10 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
1409
1409
|
{
|
|
1410
1410
|
id: `${ne}-payment-heading`,
|
|
1411
1411
|
className: "type-label ds:m-0",
|
|
1412
|
-
children:
|
|
1412
|
+
children: y("booking.payment.noticeTitle")
|
|
1413
1413
|
}
|
|
1414
1414
|
),
|
|
1415
|
-
/* @__PURE__ */ n("p", { className: "type-body-sm ds:m-0", children:
|
|
1415
|
+
/* @__PURE__ */ n("p", { className: "type-body-sm ds:m-0", children: y("booking.payment.noticeBody", { amount: ht }) }),
|
|
1416
1416
|
Se ? /* @__PURE__ */ n(
|
|
1417
1417
|
"a",
|
|
1418
1418
|
{
|
|
@@ -1420,21 +1420,21 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
1420
1420
|
target: "_blank",
|
|
1421
1421
|
rel: "noopener noreferrer",
|
|
1422
1422
|
className: "type-body-sm ds:inline-flex ds:items-center ds:self-start ds:min-h-[var(--min-target-size)] ds:rounded-[var(--radius-sm)] ds:underline ds:text-[var(--foreground)] ds:focus-visible:outline-solid ds:focus-visible:outline-[length:var(--focus-ring-width)] ds:focus-visible:outline-[var(--ring)] ds:focus-visible:outline-offset-[length:var(--focus-ring-offset)]",
|
|
1423
|
-
children:
|
|
1423
|
+
children: y("booking.payment.terms")
|
|
1424
1424
|
}
|
|
1425
1425
|
) : null,
|
|
1426
1426
|
/* @__PURE__ */ n(
|
|
1427
1427
|
wt,
|
|
1428
1428
|
{
|
|
1429
1429
|
checked: Ze,
|
|
1430
|
-
onCheckedChange: (
|
|
1430
|
+
onCheckedChange: (d) => {
|
|
1431
1431
|
Tt(
|
|
1432
|
-
|
|
1433
|
-
), Z({ paymentAccepted:
|
|
1432
|
+
d === !0 ? Ke : void 0
|
|
1433
|
+
), Z({ paymentAccepted: d === !0 });
|
|
1434
1434
|
},
|
|
1435
1435
|
"aria-required": !0,
|
|
1436
|
-
label: /* @__PURE__ */
|
|
1437
|
-
|
|
1436
|
+
label: /* @__PURE__ */ b(de, { children: [
|
|
1437
|
+
y("booking.payment.accept", { amount: ht }),
|
|
1438
1438
|
/* @__PURE__ */ n(
|
|
1439
1439
|
"span",
|
|
1440
1440
|
{
|
|
@@ -1449,14 +1449,14 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
1449
1449
|
]
|
|
1450
1450
|
}
|
|
1451
1451
|
) : null,
|
|
1452
|
-
/* @__PURE__ */
|
|
1452
|
+
/* @__PURE__ */ b("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-xs)]", children: [
|
|
1453
1453
|
/* @__PURE__ */ n(
|
|
1454
1454
|
wt,
|
|
1455
1455
|
{
|
|
1456
1456
|
checked: !!e.privacyConsent,
|
|
1457
|
-
onCheckedChange: (
|
|
1457
|
+
onCheckedChange: (d) => Z({ privacyConsent: d === !0 }),
|
|
1458
1458
|
"aria-required": !0,
|
|
1459
|
-
label: /* @__PURE__ */
|
|
1459
|
+
label: /* @__PURE__ */ b(de, { children: [
|
|
1460
1460
|
Gt(
|
|
1461
1461
|
"booking.details.consent.privacy.label",
|
|
1462
1462
|
S
|
|
@@ -1476,9 +1476,9 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
1476
1476
|
wt,
|
|
1477
1477
|
{
|
|
1478
1478
|
checked: !!e.termsConsent,
|
|
1479
|
-
onCheckedChange: (
|
|
1479
|
+
onCheckedChange: (d) => Z({ termsConsent: d === !0 }),
|
|
1480
1480
|
"aria-required": !0,
|
|
1481
|
-
label: /* @__PURE__ */
|
|
1481
|
+
label: /* @__PURE__ */ b(de, { children: [
|
|
1482
1482
|
Gt(
|
|
1483
1483
|
"booking.details.consent.terms.label",
|
|
1484
1484
|
g
|
|
@@ -1494,29 +1494,29 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
1494
1494
|
] })
|
|
1495
1495
|
}
|
|
1496
1496
|
),
|
|
1497
|
-
|
|
1497
|
+
l && gt ? /* @__PURE__ */ n(
|
|
1498
1498
|
wt,
|
|
1499
1499
|
{
|
|
1500
|
-
checked:
|
|
1501
|
-
onCheckedChange: (
|
|
1500
|
+
checked: le,
|
|
1501
|
+
onCheckedChange: (d) => {
|
|
1502
1502
|
$t(
|
|
1503
|
-
|
|
1504
|
-
), Z({ practiceConsentAccepted:
|
|
1503
|
+
d === !0 ? we : void 0
|
|
1504
|
+
), Z({ practiceConsentAccepted: d === !0 });
|
|
1505
1505
|
},
|
|
1506
|
-
"aria-required":
|
|
1507
|
-
label: /* @__PURE__ */
|
|
1508
|
-
Xt(
|
|
1506
|
+
"aria-required": l.required || void 0,
|
|
1507
|
+
label: /* @__PURE__ */ b(de, { children: [
|
|
1508
|
+
Xt(l.url) ? /* @__PURE__ */ n(
|
|
1509
1509
|
"a",
|
|
1510
1510
|
{
|
|
1511
1511
|
dir: "auto",
|
|
1512
|
-
href: Xt(
|
|
1512
|
+
href: Xt(l.url),
|
|
1513
1513
|
target: "_blank",
|
|
1514
1514
|
rel: "noopener noreferrer",
|
|
1515
1515
|
className: mn,
|
|
1516
|
-
children:
|
|
1516
|
+
children: l.label
|
|
1517
1517
|
}
|
|
1518
|
-
) : /* @__PURE__ */ n("span", { dir: "auto", children:
|
|
1519
|
-
|
|
1518
|
+
) : /* @__PURE__ */ n("span", { dir: "auto", children: l.label }),
|
|
1519
|
+
l.required ? /* @__PURE__ */ n(
|
|
1520
1520
|
"span",
|
|
1521
1521
|
{
|
|
1522
1522
|
"aria-hidden": "true",
|
|
@@ -1535,54 +1535,54 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
1535
1535
|
"data-unanswered": St || void 0,
|
|
1536
1536
|
className: "ds:flex ds:flex-col ds:gap-[var(--spacing-xs)]",
|
|
1537
1537
|
children: k ? /* @__PURE__ */ n(
|
|
1538
|
-
|
|
1538
|
+
xr,
|
|
1539
1539
|
{
|
|
1540
1540
|
variant: "horizontal",
|
|
1541
|
-
label:
|
|
1541
|
+
label: y("booking.confirmation.heading"),
|
|
1542
1542
|
value: Ue[0] ?? "",
|
|
1543
|
-
onValueChange: (
|
|
1544
|
-
confirmationChannels: [
|
|
1543
|
+
onValueChange: (d) => Z({
|
|
1544
|
+
confirmationChannels: [d]
|
|
1545
1545
|
}),
|
|
1546
|
-
error: St ?
|
|
1547
|
-
children: Ce.map((
|
|
1548
|
-
|
|
1546
|
+
error: St ? y("booking.confirmation.atLeastOne") : void 0,
|
|
1547
|
+
children: Ce.map((d) => /* @__PURE__ */ n(
|
|
1548
|
+
Sr,
|
|
1549
1549
|
{
|
|
1550
|
-
value:
|
|
1551
|
-
label:
|
|
1550
|
+
value: d,
|
|
1551
|
+
label: y(`booking.confirmation.channel.${d}`)
|
|
1552
1552
|
},
|
|
1553
|
-
|
|
1553
|
+
d
|
|
1554
1554
|
))
|
|
1555
1555
|
}
|
|
1556
1556
|
) : /* @__PURE__ */ n(
|
|
1557
|
-
|
|
1557
|
+
kr,
|
|
1558
1558
|
{
|
|
1559
|
-
label:
|
|
1560
|
-
helperText:
|
|
1559
|
+
label: y("booking.confirmation.heading"),
|
|
1560
|
+
helperText: y("booking.confirmation.helper"),
|
|
1561
1561
|
value: Ue,
|
|
1562
|
-
onChange: (
|
|
1563
|
-
confirmationChannels:
|
|
1562
|
+
onChange: (d) => Z({
|
|
1563
|
+
confirmationChannels: d
|
|
1564
1564
|
}),
|
|
1565
1565
|
orientation: "vertical",
|
|
1566
|
-
options: Ce.map((
|
|
1567
|
-
value:
|
|
1568
|
-
label:
|
|
1566
|
+
options: Ce.map((d) => ({
|
|
1567
|
+
value: d,
|
|
1568
|
+
label: y(`booking.confirmation.channel.${d}`)
|
|
1569
1569
|
})),
|
|
1570
|
-
error: St ?
|
|
1570
|
+
error: St ? y("booking.confirmation.atLeastOne") : void 0
|
|
1571
1571
|
}
|
|
1572
1572
|
)
|
|
1573
1573
|
}
|
|
1574
1574
|
) : null,
|
|
1575
|
-
!
|
|
1576
|
-
|
|
1575
|
+
!_ && (L || he || m) ? /* @__PURE__ */ n(re, { variant: "error", children: /* @__PURE__ */ n(re.Description, { children: L ?? y(
|
|
1576
|
+
m ? "booking.payment.unavailable" : "booking.payment.submitFailed"
|
|
1577
1577
|
) }) }) : null,
|
|
1578
|
-
|
|
1578
|
+
_ ? null : /* @__PURE__ */ b("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-xs)]", children: [
|
|
1579
1579
|
Rt ? /* @__PURE__ */ n(
|
|
1580
1580
|
"p",
|
|
1581
1581
|
{
|
|
1582
1582
|
id: Ot,
|
|
1583
1583
|
"data-slot": "submit-hint",
|
|
1584
1584
|
className: "type-body-sm ds:m-0 ds:text-[var(--muted-foreground)]",
|
|
1585
|
-
children:
|
|
1585
|
+
children: y("booking.details.submitHint")
|
|
1586
1586
|
}
|
|
1587
1587
|
) : null,
|
|
1588
1588
|
/* @__PURE__ */ n(
|
|
@@ -1591,11 +1591,11 @@ const Fn = 500, Bs = /^[A-Z0-9]{16}$/, Ls = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, _n = 3
|
|
|
1591
1591
|
intent: "primary",
|
|
1592
1592
|
size: "md",
|
|
1593
1593
|
type: "submit",
|
|
1594
|
-
disabled: be ||
|
|
1594
|
+
disabled: be || m,
|
|
1595
1595
|
"aria-disabled": !lt || void 0,
|
|
1596
1596
|
"aria-describedby": Rt ? Ot : void 0,
|
|
1597
1597
|
startIcon: be ? /* @__PURE__ */ n(qn, { variant: "pulse", size: "sm" }) : void 0,
|
|
1598
|
-
children: h ?
|
|
1598
|
+
children: h ? y("booking.payment.submit", { amount: ht }) : y("booking.details.submit")
|
|
1599
1599
|
}
|
|
1600
1600
|
)
|
|
1601
1601
|
] })
|
|
@@ -1637,7 +1637,7 @@ function tr(e, t) {
|
|
|
1637
1637
|
}
|
|
1638
1638
|
return !0;
|
|
1639
1639
|
}
|
|
1640
|
-
function
|
|
1640
|
+
function Gs(e, t = 1e3) {
|
|
1641
1641
|
let r = !1;
|
|
1642
1642
|
const i = () => {
|
|
1643
1643
|
r || (r = !0, window.removeEventListener("scrollend", i), clearTimeout(s), e());
|
|
@@ -1653,10 +1653,10 @@ function In({
|
|
|
1653
1653
|
label: i,
|
|
1654
1654
|
children: s
|
|
1655
1655
|
}) {
|
|
1656
|
-
const { t: a } = Q("ui"), o = A(null), c = A(!1),
|
|
1656
|
+
const { t: a } = Q("ui"), o = A(null), c = A(!1), u = A(!1);
|
|
1657
1657
|
return V(() => {
|
|
1658
|
-
const p =
|
|
1659
|
-
if (
|
|
1658
|
+
const p = u.current && !t;
|
|
1659
|
+
if (u.current = !!t, !c.current || !p) return;
|
|
1660
1660
|
c.current = !1;
|
|
1661
1661
|
const f = o.current;
|
|
1662
1662
|
if (!f || document.activeElement !== f) return;
|
|
@@ -1675,7 +1675,7 @@ function In({
|
|
|
1675
1675
|
"aria-busy": t || void 0,
|
|
1676
1676
|
"data-slot-load-state": t ? "loading" : e ? "error" : "ready",
|
|
1677
1677
|
className: Bt,
|
|
1678
|
-
children: e && !t ? /* @__PURE__ */
|
|
1678
|
+
children: e && !t ? /* @__PURE__ */ b(re, { variant: "error", children: [
|
|
1679
1679
|
/* @__PURE__ */ n(re.Description, { children: a("booking.slotsLoadError") }),
|
|
1680
1680
|
r ? /* @__PURE__ */ n(re.Action, { children: /* @__PURE__ */ n(
|
|
1681
1681
|
Re,
|
|
@@ -1694,7 +1694,7 @@ function In({
|
|
|
1694
1694
|
}
|
|
1695
1695
|
);
|
|
1696
1696
|
}
|
|
1697
|
-
function
|
|
1697
|
+
function Js({
|
|
1698
1698
|
length: e = 5,
|
|
1699
1699
|
onVerify: t,
|
|
1700
1700
|
onResend: r,
|
|
@@ -1703,58 +1703,58 @@ function Hs({
|
|
|
1703
1703
|
onVerified: a,
|
|
1704
1704
|
onBusyChange: o
|
|
1705
1705
|
}) {
|
|
1706
|
-
const { t: c, i18n:
|
|
1706
|
+
const { t: c, i18n: u } = Q("ui"), p = pt(), f = pt(), S = A(null), g = A(null), l = A(null), h = A(null), v = A(!1), m = A(!1), [O, N] = J(null), [w, C] = J(!1), [M, D] = J(null), [_, R] = J(
|
|
1707
1707
|
null
|
|
1708
1708
|
), [$, j] = J(0), T = Number.isFinite(i) ? Math.max(0, Math.ceil(i)) : 60, [k, L] = J(
|
|
1709
1709
|
() => Date.now() + T * 1e3
|
|
1710
|
-
), [
|
|
1710
|
+
), [F, y] = J(T), W = M === "too-many-attempts";
|
|
1711
1711
|
V(() => {
|
|
1712
|
-
o == null || o(!!
|
|
1713
|
-
}, [
|
|
1712
|
+
o == null || o(!!O);
|
|
1713
|
+
}, [O, o]), V(() => (v.current = !0, () => {
|
|
1714
1714
|
v.current = !1;
|
|
1715
1715
|
}), []), V(() => {
|
|
1716
|
-
var
|
|
1717
|
-
(
|
|
1716
|
+
var I;
|
|
1717
|
+
(I = l.current) == null || I.focus({ preventScroll: !0 }), tr(g.current, "center");
|
|
1718
1718
|
}, [$]), V(() => {
|
|
1719
1719
|
var Y, U;
|
|
1720
|
-
if (
|
|
1721
|
-
const
|
|
1722
|
-
|
|
1723
|
-
}, [
|
|
1724
|
-
if (
|
|
1725
|
-
const
|
|
1726
|
-
|
|
1720
|
+
if (O || !W && _ !== "resend") return;
|
|
1721
|
+
const I = document.activeElement, q = (Y = S.current) == null ? void 0 : Y.closest("section");
|
|
1722
|
+
I && I !== document.body && !(q != null && q.contains(I)) || (h.current && !h.current.disabled ? h.current.focus() : (U = S.current) == null || U.focus());
|
|
1723
|
+
}, [O, W, _]), V(() => {
|
|
1724
|
+
if (F === 0) return;
|
|
1725
|
+
const I = setTimeout(() => {
|
|
1726
|
+
y(Math.max(0, Math.ceil((k - Date.now()) / 1e3)));
|
|
1727
1727
|
}, 1e3);
|
|
1728
|
-
return () => clearTimeout(
|
|
1729
|
-
}, [k,
|
|
1730
|
-
const ne = async (
|
|
1731
|
-
if (!(
|
|
1732
|
-
|
|
1728
|
+
return () => clearTimeout(I);
|
|
1729
|
+
}, [k, F]);
|
|
1730
|
+
const ne = async (I) => {
|
|
1731
|
+
if (!(m.current || W)) {
|
|
1732
|
+
m.current = !0, N("verify"), C(!1), D(null), R(null);
|
|
1733
1733
|
try {
|
|
1734
|
-
const q = await t(
|
|
1734
|
+
const q = await t(I);
|
|
1735
1735
|
if (!v.current) return;
|
|
1736
|
-
q.ok ? a(q.redirectUrl) : (
|
|
1736
|
+
q.ok ? a(q.redirectUrl) : (D(q.reason), q.reason !== "too-many-attempts" && j((Y) => Y + 1));
|
|
1737
1737
|
} catch {
|
|
1738
1738
|
if (!v.current) return;
|
|
1739
1739
|
R("verify"), j((q) => q + 1);
|
|
1740
1740
|
} finally {
|
|
1741
|
-
|
|
1741
|
+
m.current = !1, v.current && N(null);
|
|
1742
1742
|
}
|
|
1743
1743
|
}
|
|
1744
1744
|
}, Ne = async () => {
|
|
1745
|
-
if (!(
|
|
1746
|
-
|
|
1745
|
+
if (!(m.current || Date.now() < k)) {
|
|
1746
|
+
m.current = !0, N("resend"), C(!1), R(null);
|
|
1747
1747
|
try {
|
|
1748
1748
|
if (await r(), !v.current) return;
|
|
1749
|
-
L(Date.now() + T * 1e3),
|
|
1749
|
+
L(Date.now() + T * 1e3), y(T), D(null), C(!0), j((I) => I + 1);
|
|
1750
1750
|
} catch {
|
|
1751
1751
|
v.current && R("resend");
|
|
1752
1752
|
} finally {
|
|
1753
|
-
|
|
1753
|
+
m.current = !1, v.current && N(null);
|
|
1754
1754
|
}
|
|
1755
1755
|
}
|
|
1756
|
-
}, ge =
|
|
1757
|
-
return /* @__PURE__ */ n(
|
|
1756
|
+
}, ge = M === "wrong" ? c("booking.code.wrong") : M === "expired" ? c("booking.code.expired") : W ? c("booking.code.tooManyAttempts") : void 0;
|
|
1757
|
+
return /* @__PURE__ */ n(Mr, { variant: "elevated", asChild: !0, children: /* @__PURE__ */ b(
|
|
1758
1758
|
"section",
|
|
1759
1759
|
{
|
|
1760
1760
|
ref: g,
|
|
@@ -1783,31 +1783,31 @@ function Hs({
|
|
|
1783
1783
|
}
|
|
1784
1784
|
) : c("booking.code.instruction") }),
|
|
1785
1785
|
/* @__PURE__ */ n(Je, { label: c("booking.code.label"), error: ge, children: /* @__PURE__ */ n("div", { dir: "ltr", children: /* @__PURE__ */ n(
|
|
1786
|
-
|
|
1786
|
+
Rr,
|
|
1787
1787
|
{
|
|
1788
|
-
ref:
|
|
1788
|
+
ref: l,
|
|
1789
1789
|
length: e,
|
|
1790
1790
|
mode: "alphanumeric",
|
|
1791
1791
|
"aria-describedby": f,
|
|
1792
|
-
disabled: !!
|
|
1792
|
+
disabled: !!O || W,
|
|
1793
1793
|
onComplete: ne
|
|
1794
1794
|
},
|
|
1795
1795
|
$
|
|
1796
1796
|
) }) }),
|
|
1797
|
-
|
|
1798
|
-
/* @__PURE__ */ n("p", { role: "status", className: "type-body ds:m-0", children:
|
|
1797
|
+
_ ? /* @__PURE__ */ n(re, { variant: "error", className: "ds:self-stretch ds:text-start", children: /* @__PURE__ */ n(re.Description, { children: c(_ === "verify" ? "booking.code.verifyFailed" : "booking.code.resendFailed") }) }) : null,
|
|
1798
|
+
/* @__PURE__ */ n("p", { role: "status", className: "type-body ds:m-0", children: O === "verify" ? c("booking.code.verifying") : w ? c("booking.code.resent") : null }),
|
|
1799
1799
|
/* @__PURE__ */ n(
|
|
1800
1800
|
Re,
|
|
1801
1801
|
{
|
|
1802
1802
|
ref: h,
|
|
1803
1803
|
type: "button",
|
|
1804
1804
|
intent: "secondary",
|
|
1805
|
-
disabled:
|
|
1806
|
-
loading:
|
|
1805
|
+
disabled: F > 0 || !!O,
|
|
1806
|
+
loading: O === "resend",
|
|
1807
1807
|
onClick: Ne,
|
|
1808
|
-
children:
|
|
1809
|
-
seconds: new Intl.NumberFormat(
|
|
1810
|
-
|
|
1808
|
+
children: F > 0 ? c("booking.code.resendCountdown", {
|
|
1809
|
+
seconds: new Intl.NumberFormat(u.language).format(
|
|
1810
|
+
F
|
|
1811
1811
|
)
|
|
1812
1812
|
}) : c("booking.code.resend")
|
|
1813
1813
|
}
|
|
@@ -1828,7 +1828,7 @@ function nr(e) {
|
|
|
1828
1828
|
currencyCode: r
|
|
1829
1829
|
};
|
|
1830
1830
|
}
|
|
1831
|
-
function
|
|
1831
|
+
function Ws(e) {
|
|
1832
1832
|
var s;
|
|
1833
1833
|
const t = (s = e.priceLabel) != null && s.trim() ? e.priceLabel : void 0, r = t ? { label: t } : void 0;
|
|
1834
1834
|
if (!e.payment) return { price: r };
|
|
@@ -1838,7 +1838,7 @@ function Gs(e) {
|
|
|
1838
1838
|
payment: i
|
|
1839
1839
|
} : { price: r, payment: "unavailable" };
|
|
1840
1840
|
}
|
|
1841
|
-
function
|
|
1841
|
+
function Ys(e, t, r) {
|
|
1842
1842
|
const i = e.filter(
|
|
1843
1843
|
(a) => t.includes(a.id)
|
|
1844
1844
|
), s = (r == null ? void 0 : r.serviceId) ?? (t.length === 1 ? t[0] : void 0);
|
|
@@ -1858,7 +1858,7 @@ function en(e) {
|
|
|
1858
1858
|
e.currencyCode
|
|
1859
1859
|
]) : "";
|
|
1860
1860
|
}
|
|
1861
|
-
function
|
|
1861
|
+
function Zs({
|
|
1862
1862
|
services: e,
|
|
1863
1863
|
value: t,
|
|
1864
1864
|
availableSlots: r,
|
|
@@ -1867,10 +1867,10 @@ function Ws({
|
|
|
1867
1867
|
paymentState: a,
|
|
1868
1868
|
submitting: o,
|
|
1869
1869
|
paymentTermsUrl: c,
|
|
1870
|
-
renderPayment:
|
|
1870
|
+
renderPayment: u,
|
|
1871
1871
|
codeStep: p
|
|
1872
1872
|
}) {
|
|
1873
|
-
var ge,
|
|
1873
|
+
var ge, I, q;
|
|
1874
1874
|
const f = JSON.stringify([
|
|
1875
1875
|
t.insuranceType,
|
|
1876
1876
|
t.specialtyId,
|
|
@@ -1882,74 +1882,74 @@ function Ws({
|
|
|
1882
1882
|
t.slotKey
|
|
1883
1883
|
]), S = A(
|
|
1884
1884
|
void 0
|
|
1885
|
-
),
|
|
1885
|
+
), l = (t.date ? (ge = r[t.date]) == null ? void 0 : ge.find((Y) => Y.key === t.slotKey) : void 0) ?? (((I = S.current) == null ? void 0 : I.selection) === f ? S.current.slot : void 0), h = Ys(
|
|
1886
1886
|
e,
|
|
1887
1887
|
Ye(t),
|
|
1888
|
-
|
|
1889
|
-
), v = h.blocked || !!(h.payment && !
|
|
1888
|
+
l
|
|
1889
|
+
), v = h.blocked || !!(h.payment && !u), m = JSON.stringify([
|
|
1890
1890
|
f,
|
|
1891
|
-
|
|
1891
|
+
l == null ? void 0 : l.serviceId,
|
|
1892
1892
|
en(h.payment),
|
|
1893
1893
|
c,
|
|
1894
1894
|
v
|
|
1895
|
-
]),
|
|
1895
|
+
]), O = h.payment ? JSON.stringify([en(h.payment), c]) : "", N = A(void 0), w = !!((q = t.details) != null && q.paymentAccepted);
|
|
1896
1896
|
V(() => {
|
|
1897
|
-
if (!
|
|
1898
|
-
else if (
|
|
1897
|
+
if (!w) N.current = void 0;
|
|
1898
|
+
else if (O) N.current === void 0 ? N.current = O : N.current !== O && (N.current = void 0, s({
|
|
1899
1899
|
...t,
|
|
1900
1900
|
details: { ...t.details, paymentAccepted: !1 }
|
|
1901
1901
|
}));
|
|
1902
1902
|
else return;
|
|
1903
|
-
}, [
|
|
1904
|
-
const
|
|
1905
|
-
|
|
1906
|
-
const [
|
|
1903
|
+
}, [w, O, s, t]);
|
|
1904
|
+
const C = A(m);
|
|
1905
|
+
C.current = m;
|
|
1906
|
+
const [M, D] = J({ status: "idle" }), _ = A(0), R = A(!1), $ = A(!0), j = A(!1), T = A(void 0), k = A(m);
|
|
1907
1907
|
V(() => ($.current = !0, () => {
|
|
1908
|
-
$.current = !1,
|
|
1908
|
+
$.current = !1, _.current += 1;
|
|
1909
1909
|
}), []);
|
|
1910
|
-
const L =
|
|
1910
|
+
const L = M.status === "payment" || M.status === "code" || M.status === "success";
|
|
1911
1911
|
V(() => {
|
|
1912
|
-
k.current ===
|
|
1913
|
-
}, [
|
|
1914
|
-
const
|
|
1915
|
-
() =>
|
|
1916
|
-
[
|
|
1912
|
+
k.current === m || j.current || L || (k.current = m, _.current += 1, R.current = !1, D({ status: "idle" }));
|
|
1913
|
+
}, [m, L]);
|
|
1914
|
+
const F = L || k.current === m ? M.session : void 0, y = K(
|
|
1915
|
+
() => F && (a == null ? void 0 : a.sessionId) === F.id ? a : F ? { sessionId: F.id, status: "ready" } : void 0,
|
|
1916
|
+
[F, a]
|
|
1917
1917
|
);
|
|
1918
|
-
|
|
1918
|
+
F && y && "phase" in y && y.phase === "completion" && (T.current = F.id);
|
|
1919
1919
|
const W = K(
|
|
1920
|
-
() =>
|
|
1921
|
-
sessionId:
|
|
1920
|
+
() => F && T.current === F.id && y && y.status !== "paid" && (!("phase" in y) || y.phase !== "completion") ? {
|
|
1921
|
+
sessionId: F.id,
|
|
1922
1922
|
status: "processing",
|
|
1923
1923
|
phase: "completion"
|
|
1924
|
-
} :
|
|
1925
|
-
[
|
|
1924
|
+
} : y,
|
|
1925
|
+
[F, y]
|
|
1926
1926
|
);
|
|
1927
1927
|
V(() => {
|
|
1928
|
-
if (!(!
|
|
1928
|
+
if (!(!F || !W || j.current))
|
|
1929
1929
|
if (W.status === "paid") {
|
|
1930
|
-
if (
|
|
1931
|
-
j.current = !0,
|
|
1930
|
+
if (M.status !== "payment") return;
|
|
1931
|
+
j.current = !0, D((Y) => ({
|
|
1932
1932
|
...Y,
|
|
1933
1933
|
status: "success",
|
|
1934
1934
|
redirectUrl: W.redirectUrl
|
|
1935
1935
|
}));
|
|
1936
|
-
} else W.status === "cancelled" && (
|
|
1936
|
+
} else W.status === "cancelled" && (_.current += 1, R.current = !1, S.current = void 0, s({
|
|
1937
1937
|
...t,
|
|
1938
1938
|
details: { ...t.details, paymentAccepted: !1 }
|
|
1939
|
-
}),
|
|
1940
|
-
}, [
|
|
1939
|
+
}), D({ status: "idle", cancelled: !0 }));
|
|
1940
|
+
}, [F, W, s, t, M.status]);
|
|
1941
1941
|
const ne = () => {
|
|
1942
|
-
|
|
1942
|
+
_.current += 1, R.current = !1, j.current = !1, T.current = void 0, S.current = void 0, k.current = C.current, D({ status: "idle" });
|
|
1943
1943
|
}, Ne = async (Y) => {
|
|
1944
1944
|
var ye, Oe, De, ke, oe;
|
|
1945
|
-
if (!(
|
|
1945
|
+
if (!(l != null && l.available) || v || o || R.current || M.status === "payment" || M.status === "code" || j.current || h.payment && !Y.paymentAccepted) return;
|
|
1946
1946
|
R.current = !0;
|
|
1947
1947
|
const U = p ? { ...p } : void 0;
|
|
1948
|
-
S.current = { selection: f, slot: { ...
|
|
1949
|
-
const ze = ++
|
|
1948
|
+
S.current = { selection: f, slot: { ...l } };
|
|
1949
|
+
const ze = ++_.current, Be = m;
|
|
1950
1950
|
k.current = Be;
|
|
1951
1951
|
const he = {
|
|
1952
|
-
slot: { ...
|
|
1952
|
+
slot: { ...l, meta: l.meta ? { ...l.meta } : void 0 },
|
|
1953
1953
|
value: {
|
|
1954
1954
|
...t,
|
|
1955
1955
|
serviceIds: (ye = t.serviceIds) == null ? void 0 : ye.slice(),
|
|
@@ -1963,8 +1963,8 @@ function Ws({
|
|
|
1963
1963
|
confirmationChannels: (ke = Y.confirmationChannels) == null ? void 0 : ke.slice()
|
|
1964
1964
|
},
|
|
1965
1965
|
...h.payment ? { payment: { ...h.payment } } : {}
|
|
1966
|
-
}, ve = () => $.current &&
|
|
1967
|
-
|
|
1966
|
+
}, ve = () => $.current && _.current === ze && C.current === Be;
|
|
1967
|
+
D({ status: "submitting" });
|
|
1968
1968
|
let be = !1;
|
|
1969
1969
|
try {
|
|
1970
1970
|
const ae = await i(he);
|
|
@@ -1972,36 +1972,36 @@ function Ws({
|
|
|
1972
1972
|
if (he.payment) {
|
|
1973
1973
|
const se = ae == null ? void 0 : ae.paymentSession;
|
|
1974
1974
|
if (!((oe = se == null ? void 0 : se.id) != null && oe.trim()) || en(se.payment) !== en(he.payment)) {
|
|
1975
|
-
|
|
1975
|
+
D({ status: "error" });
|
|
1976
1976
|
return;
|
|
1977
1977
|
}
|
|
1978
|
-
be = !0,
|
|
1978
|
+
be = !0, D({
|
|
1979
1979
|
status: U ? "code" : "payment",
|
|
1980
1980
|
snapshot: he,
|
|
1981
1981
|
session: { id: se.id, payment: { ...se.payment } },
|
|
1982
1982
|
codeStep: U
|
|
1983
1983
|
});
|
|
1984
|
-
} else ae != null && ae.paymentSession ?
|
|
1984
|
+
} else ae != null && ae.paymentSession ? D({ status: "error" }) : (j.current = !0, D({
|
|
1985
1985
|
status: U ? "code" : "success",
|
|
1986
1986
|
snapshot: he,
|
|
1987
1987
|
codeStep: U
|
|
1988
1988
|
}));
|
|
1989
1989
|
} catch {
|
|
1990
|
-
ve() &&
|
|
1990
|
+
ve() && D({ status: "error" });
|
|
1991
1991
|
} finally {
|
|
1992
1992
|
ve() && !be && (R.current = !1);
|
|
1993
1993
|
}
|
|
1994
1994
|
};
|
|
1995
1995
|
return {
|
|
1996
|
-
...
|
|
1996
|
+
...M,
|
|
1997
1997
|
payment: h.payment,
|
|
1998
1998
|
blocked: v,
|
|
1999
1999
|
state: W,
|
|
2000
|
-
activeSession:
|
|
2000
|
+
activeSession: F,
|
|
2001
2001
|
submit: Ne,
|
|
2002
2002
|
reset: ne,
|
|
2003
2003
|
completeCode: (Y) => {
|
|
2004
|
-
|
|
2004
|
+
D(
|
|
2005
2005
|
(U) => U.status !== "code" ? U : U.session ? { ...U, status: "payment", codeVerified: !0 } : {
|
|
2006
2006
|
...U,
|
|
2007
2007
|
status: "success",
|
|
@@ -2012,8 +2012,23 @@ function Ws({
|
|
|
2012
2012
|
}
|
|
2013
2013
|
};
|
|
2014
2014
|
}
|
|
2015
|
-
const
|
|
2016
|
-
function
|
|
2015
|
+
const Xs = 3e3;
|
|
2016
|
+
function rr(e) {
|
|
2017
|
+
if (typeof e != "string") return;
|
|
2018
|
+
const t = e.trim();
|
|
2019
|
+
try {
|
|
2020
|
+
const { protocol: r } = new URL(t);
|
|
2021
|
+
return (r === "https:" || r === "http:") && Or(t) ? t : void 0;
|
|
2022
|
+
} catch {
|
|
2023
|
+
return;
|
|
2024
|
+
}
|
|
2025
|
+
}
|
|
2026
|
+
const Qs = 2 ** 31 - 1;
|
|
2027
|
+
function sr(e) {
|
|
2028
|
+
return typeof e == "number" && Number.isFinite(e) && e >= 0 ? Math.min(e, Qs) : Xs;
|
|
2029
|
+
}
|
|
2030
|
+
const ei = 5e3, ti = "ds:[stroke-dasharray:1] ds:[stroke-dashoffset:1] ds:animate-[stepper-icon-draw_calc(var(--animation-duration)*3)_var(--ease-out)_forwards]", ni = "ds:block ds:[block-size:100%] ds:rounded-full ds:bg-[var(--primary)] ds:animate-[reserved-bar-fill_linear_forwards] ds:[animation-duration:var(--handover-ms)]";
|
|
2031
|
+
function ri({
|
|
2017
2032
|
url: e,
|
|
2018
2033
|
delayMs: t,
|
|
2019
2034
|
onNavigate: r,
|
|
@@ -2022,25 +2037,28 @@ function Qs({
|
|
|
2022
2037
|
details: a,
|
|
2023
2038
|
shouldTakeFocus: o
|
|
2024
2039
|
}) {
|
|
2025
|
-
const { t: c } = Q("ui"),
|
|
2026
|
-
clearTimeout(
|
|
2027
|
-
|
|
2028
|
-
|
|
2029
|
-
|
|
2030
|
-
|
|
2031
|
-
},
|
|
2032
|
-
var
|
|
2033
|
-
clearTimeout(
|
|
2034
|
-
},
|
|
2035
|
-
return
|
|
2036
|
-
|
|
2040
|
+
const { t: c } = Q("ui"), u = rr(e), p = sr(t), f = A(null), S = A(null), g = A(void 0), l = pt(), h = A(null), [v, m] = J(!1), [O, N] = J(() => vn(null)), w = () => {
|
|
2041
|
+
if (clearTimeout(g.current), !!u)
|
|
2042
|
+
try {
|
|
2043
|
+
r ? r(u) : window.location.assign(u);
|
|
2044
|
+
} catch {
|
|
2045
|
+
}
|
|
2046
|
+
}, C = () => {
|
|
2047
|
+
var D;
|
|
2048
|
+
clearTimeout(g.current), m(!0), (D = h.current) == null || D.focus({ preventScroll: !0 });
|
|
2049
|
+
}, M = A(w);
|
|
2050
|
+
return M.current = w, _t(() => {
|
|
2051
|
+
N(vn(f.current));
|
|
2037
2052
|
}, []), V(() => {
|
|
2038
|
-
const
|
|
2039
|
-
|
|
2040
|
-
}, []), V(() =>
|
|
2053
|
+
const D = S.current;
|
|
2054
|
+
D && f.current && o(f.current) && D.focus({ preventScroll: !0 });
|
|
2055
|
+
}, []), V(() => {
|
|
2056
|
+
if (u)
|
|
2057
|
+
return g.current = setTimeout(() => M.current(), p), () => clearTimeout(g.current);
|
|
2058
|
+
}, [u, p]), /* @__PURE__ */ b(
|
|
2041
2059
|
"div",
|
|
2042
2060
|
{
|
|
2043
|
-
ref:
|
|
2061
|
+
ref: f,
|
|
2044
2062
|
"data-component": "booking-reserved",
|
|
2045
2063
|
className: "ds:flex ds:flex-col ds:items-center ds:gap-[var(--spacing-md)] ds:text-center",
|
|
2046
2064
|
children: [
|
|
@@ -2059,76 +2077,63 @@ function Qs({
|
|
|
2059
2077
|
strokeLinecap: "round",
|
|
2060
2078
|
strokeLinejoin: "round",
|
|
2061
2079
|
className: "ds:size-[var(--spacing-lg)]",
|
|
2062
|
-
children: /* @__PURE__ */ n("path", { pathLength: "1", d: "M5 12l5 5L20 7", className:
|
|
2080
|
+
children: /* @__PURE__ */ n("path", { pathLength: "1", d: "M5 12l5 5L20 7", className: ti })
|
|
2063
2081
|
}
|
|
2064
2082
|
)
|
|
2065
2083
|
}
|
|
2066
2084
|
),
|
|
2067
|
-
/* @__PURE__ */
|
|
2085
|
+
/* @__PURE__ */ b("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-xs)]", children: [
|
|
2068
2086
|
/* @__PURE__ */ n(
|
|
2069
2087
|
"h3",
|
|
2070
2088
|
{
|
|
2071
|
-
ref:
|
|
2089
|
+
ref: S,
|
|
2072
2090
|
tabIndex: -1,
|
|
2073
|
-
"aria-describedby":
|
|
2091
|
+
"aria-describedby": u ? l : void 0,
|
|
2074
2092
|
className: "type-title-card ds:m-0 ds:outline-none",
|
|
2075
2093
|
children: c("booking.reserved.heading")
|
|
2076
2094
|
}
|
|
2077
2095
|
),
|
|
2078
|
-
/* @__PURE__ */ n("p", { className: "type-body ds:m-0 ds:text-[var(--foreground)]", children: i ? c("booking.reserved.when", { date: i, time: s }) : s }),
|
|
2096
|
+
i || s ? /* @__PURE__ */ n("p", { className: "type-body ds:m-0 ds:text-[var(--foreground)]", children: i && s ? c("booking.reserved.when", { date: i, time: s }) : i || s }) : null,
|
|
2079
2097
|
a ? /* @__PURE__ */ n("p", { className: "type-body ds:m-0 ds:text-[var(--muted-foreground)]", children: a }) : null
|
|
2080
2098
|
] }),
|
|
2081
|
-
/* @__PURE__ */
|
|
2082
|
-
|
|
2083
|
-
|
|
2084
|
-
|
|
2099
|
+
u ? /* @__PURE__ */ b(de, { children: [
|
|
2100
|
+
/* @__PURE__ */ n("p", { id: l, role: "status", className: "type-body ds:m-0", children: c(v ? "booking.reserved.stayed" : "booking.reserved.redirecting") }),
|
|
2101
|
+
O || v || p > ei ? null : (
|
|
2102
|
+
// Decorative: the sentence above already says a redirect is coming,
|
|
2103
|
+
// and a progressbar with no value to read would only add noise.
|
|
2104
|
+
/* @__PURE__ */ n(
|
|
2105
|
+
"div",
|
|
2106
|
+
{
|
|
2107
|
+
"aria-hidden": "true",
|
|
2108
|
+
"data-slot": "booking-reserved-bar",
|
|
2109
|
+
className: "ds:[block-size:var(--spacing-xs)] ds:[inline-size:100%] ds:[max-inline-size:calc(var(--spacing-2xl)*5)] ds:overflow-hidden ds:rounded-full ds:bg-[var(--secondary)]",
|
|
2110
|
+
children: /* @__PURE__ */ n(
|
|
2111
|
+
"span",
|
|
2112
|
+
{
|
|
2113
|
+
className: ni,
|
|
2114
|
+
style: { "--handover-ms": `${p}ms` }
|
|
2115
|
+
}
|
|
2116
|
+
)
|
|
2117
|
+
}
|
|
2118
|
+
)
|
|
2119
|
+
),
|
|
2085
2120
|
/* @__PURE__ */ n(
|
|
2086
|
-
|
|
2121
|
+
Re,
|
|
2087
2122
|
{
|
|
2088
|
-
|
|
2089
|
-
|
|
2090
|
-
|
|
2091
|
-
|
|
2092
|
-
|
|
2093
|
-
|
|
2094
|
-
className: Xs,
|
|
2095
|
-
style: { "--handover-ms": `${t}ms` }
|
|
2096
|
-
}
|
|
2097
|
-
)
|
|
2123
|
+
ref: h,
|
|
2124
|
+
type: "button",
|
|
2125
|
+
intent: "secondary",
|
|
2126
|
+
size: "lg",
|
|
2127
|
+
onClick: w,
|
|
2128
|
+
children: c("booking.reserved.goNow")
|
|
2098
2129
|
}
|
|
2099
|
-
)
|
|
2100
|
-
|
|
2101
|
-
|
|
2102
|
-
Re,
|
|
2103
|
-
{
|
|
2104
|
-
ref: g,
|
|
2105
|
-
type: "button",
|
|
2106
|
-
intent: "secondary",
|
|
2107
|
-
size: "lg",
|
|
2108
|
-
onClick: M,
|
|
2109
|
-
children: c("booking.reserved.goNow")
|
|
2110
|
-
}
|
|
2111
|
-
),
|
|
2112
|
-
d ? null : /* @__PURE__ */ n(Re, { type: "button", intent: "ghost", size: "md", onClick: w, children: c("booking.reserved.stay") })
|
|
2130
|
+
),
|
|
2131
|
+
v ? null : /* @__PURE__ */ n(Re, { type: "button", intent: "ghost", size: "md", onClick: C, children: c("booking.reserved.stay") })
|
|
2132
|
+
] }) : null
|
|
2113
2133
|
]
|
|
2114
2134
|
}
|
|
2115
2135
|
);
|
|
2116
2136
|
}
|
|
2117
|
-
const ei = 3e3;
|
|
2118
|
-
function ti(e) {
|
|
2119
|
-
if (typeof e != "string") return;
|
|
2120
|
-
const t = e.trim();
|
|
2121
|
-
try {
|
|
2122
|
-
const { protocol: r } = new URL(t);
|
|
2123
|
-
return (r === "https:" || r === "http:") && Mr(t) ? t : void 0;
|
|
2124
|
-
} catch {
|
|
2125
|
-
return;
|
|
2126
|
-
}
|
|
2127
|
-
}
|
|
2128
|
-
const ni = 2 ** 31 - 1;
|
|
2129
|
-
function ri(e) {
|
|
2130
|
-
return typeof e == "number" && Number.isFinite(e) && e >= 0 ? Math.min(e, ni) : ei;
|
|
2131
|
-
}
|
|
2132
2137
|
const si = Lt(
|
|
2133
2138
|
// --booking-held-height: see the step-8 effects (runtime-measured height).
|
|
2134
2139
|
"ds:flex ds:w-full ds:flex-col ds:text-[var(--foreground)] ds:[min-block-size:var(--booking-held-height,auto)]",
|
|
@@ -2163,21 +2168,21 @@ const si = Lt(
|
|
|
2163
2168
|
/\b(estetic|aesthetic|botox|filler|mesoterap|chirurgia\s*plastic)/i,
|
|
2164
2169
|
Dn
|
|
2165
2170
|
],
|
|
2166
|
-
[/\b(cardio|ecg|elettrocardio|ecocardio|cuore|heart)/i,
|
|
2167
|
-
[/\b(dent|odonto|tooth|teeth|pulizia|igien|smile)/i,
|
|
2168
|
-
[/\b(oftalmo|ocul|ophthal|vision|occhi|eye)/i,
|
|
2169
|
-
[/\b(otorin|udito|orecchi|hearing|ear)/i,
|
|
2170
|
-
[/\b(neuro|brain|cervello)/i,
|
|
2171
|
-
[/\b(pediatr|child|bambin)/i,
|
|
2172
|
-
[/\b(ortop|ortho|osteo|skeleton|ossa|bone)/i,
|
|
2173
|
-
[/\b(lab|analis|test|sang|esami)/i,
|
|
2174
|
-
[/\b(farmaco|pharm|pillol|refill)/i,
|
|
2175
|
-
[/\b(chirurg|surg|intervent|operat)/i,
|
|
2176
|
-
[/\b(scan|rx|x-?ray|raggi|imag|radio|risonan|ecograf|ultras)/i,
|
|
2171
|
+
[/\b(cardio|ecg|elettrocardio|ecocardio|cuore|heart)/i, jr],
|
|
2172
|
+
[/\b(dent|odonto|tooth|teeth|pulizia|igien|smile)/i, ps],
|
|
2173
|
+
[/\b(oftalmo|ocul|ophthal|vision|occhi|eye)/i, Ur],
|
|
2174
|
+
[/\b(otorin|udito|orecchi|hearing|ear)/i, is],
|
|
2175
|
+
[/\b(neuro|brain|cervello)/i, ts],
|
|
2176
|
+
[/\b(pediatr|child|bambin)/i, Hr],
|
|
2177
|
+
[/\b(ortop|ortho|osteo|skeleton|ossa|bone)/i, Qr],
|
|
2178
|
+
[/\b(lab|analis|test|sang|esami)/i, as],
|
|
2179
|
+
[/\b(farmaco|pharm|pillol|refill)/i, ds],
|
|
2180
|
+
[/\b(chirurg|surg|intervent|operat)/i, us],
|
|
2181
|
+
[/\b(scan|rx|x-?ray|raggi|imag|radio|risonan|ecograf|ultras)/i, Gr],
|
|
2177
2182
|
[/\b(vacc|inject|inie|punto)/i, Dn],
|
|
2178
|
-
[/\b(derma|skin|pelle)/i,
|
|
2179
|
-
[/\b(prima\s*visit|first\s*visit|consult|consulto|valutaz)/i,
|
|
2180
|
-
[/\b(general|medicin|family|control|check[-\s]?up)/i,
|
|
2183
|
+
[/\b(derma|skin|pelle)/i, Jr],
|
|
2184
|
+
[/\b(prima\s*visit|first\s*visit|consult|consulto|valutaz)/i, Wr],
|
|
2185
|
+
[/\b(general|medicin|family|control|check[-\s]?up)/i, Zr]
|
|
2181
2186
|
];
|
|
2182
2187
|
function oi(e) {
|
|
2183
2188
|
for (const [t, r] of ii)
|
|
@@ -2185,13 +2190,13 @@ function oi(e) {
|
|
|
2185
2190
|
return null;
|
|
2186
2191
|
}
|
|
2187
2192
|
function ai(e) {
|
|
2188
|
-
const t = oi(e.label) ??
|
|
2193
|
+
const t = oi(e.label) ?? qr;
|
|
2189
2194
|
return /* @__PURE__ */ n(t, { "aria-hidden": "true", className: "ds:size-5" });
|
|
2190
2195
|
}
|
|
2191
|
-
function
|
|
2196
|
+
function ir() {
|
|
2192
2197
|
const { t: e, i18n: t } = Q("ui");
|
|
2193
2198
|
return (r) => {
|
|
2194
|
-
const i =
|
|
2199
|
+
const i = Ws(r), s = (o) => on(o.amountCents, o.currencyCode, t.language), a = i.price ? "label" in i.price ? i.price.label : s(i.price.amount) : void 0;
|
|
2195
2200
|
return i.payment === "unavailable" ? {
|
|
2196
2201
|
price: a,
|
|
2197
2202
|
payment: e("booking.payment.unavailable"),
|
|
@@ -2236,21 +2241,21 @@ function li({
|
|
|
2236
2241
|
locale: i,
|
|
2237
2242
|
loading: s
|
|
2238
2243
|
}) {
|
|
2239
|
-
const { t: a } = Q("ui"), o = K(() => t ? Ft(fe(t)) : e.length > 0 ? Ft(fe(e[0])) : Ft(/* @__PURE__ */ new Date()), [t, e]), [c,
|
|
2240
|
-
const
|
|
2241
|
-
for (let
|
|
2242
|
-
const R = new Date(
|
|
2243
|
-
R.setDate(
|
|
2244
|
+
const { t: a } = Q("ui"), o = K(() => t ? Ft(fe(t)) : e.length > 0 ? Ft(fe(e[0])) : Ft(/* @__PURE__ */ new Date()), [t, e]), [c, u] = J(o), [p, f] = J(null), S = K(() => {
|
|
2245
|
+
const N = Ft(c), w = Lr(c), C = N.getDay(), M = w.getDate(), D = [];
|
|
2246
|
+
for (let _ = C; _ > 0; _ -= 1) {
|
|
2247
|
+
const R = new Date(N);
|
|
2248
|
+
R.setDate(N.getDate() - _), D.push(R);
|
|
2244
2249
|
}
|
|
2245
|
-
for (let
|
|
2246
|
-
const R = new Date(
|
|
2247
|
-
R.setDate(
|
|
2250
|
+
for (let _ = 0; _ < M; _ += 1) {
|
|
2251
|
+
const R = new Date(N);
|
|
2252
|
+
R.setDate(N.getDate() + _), D.push(R);
|
|
2248
2253
|
}
|
|
2249
|
-
for (;
|
|
2250
|
-
const
|
|
2251
|
-
R.setDate(
|
|
2254
|
+
for (; D.length < 42; ) {
|
|
2255
|
+
const _ = D[D.length - 1], R = new Date(_);
|
|
2256
|
+
R.setDate(_.getDate() + 1), D.push(R);
|
|
2252
2257
|
}
|
|
2253
|
-
return
|
|
2258
|
+
return D;
|
|
2254
2259
|
}, [c]), g = K(() => {
|
|
2255
2260
|
try {
|
|
2256
2261
|
return new Intl.DateTimeFormat(i, {
|
|
@@ -2260,62 +2265,62 @@ function li({
|
|
|
2260
2265
|
} catch {
|
|
2261
2266
|
return nn(c, "MMMM yyyy");
|
|
2262
2267
|
}
|
|
2263
|
-
}, [c, i]),
|
|
2264
|
-
const
|
|
2265
|
-
return Array.from({ length: 7 }, (
|
|
2266
|
-
const
|
|
2267
|
-
|
|
2268
|
+
}, [c, i]), l = K(() => {
|
|
2269
|
+
const N = new Date(2024, 0, 7);
|
|
2270
|
+
return Array.from({ length: 7 }, (w, C) => {
|
|
2271
|
+
const M = new Date(N);
|
|
2272
|
+
M.setDate(N.getDate() + C);
|
|
2268
2273
|
try {
|
|
2269
|
-
return new Intl.DateTimeFormat(i, { weekday: "short" }).format(
|
|
2274
|
+
return new Intl.DateTimeFormat(i, { weekday: "short" }).format(M);
|
|
2270
2275
|
} catch {
|
|
2271
|
-
return nn(
|
|
2276
|
+
return nn(M, "EEE");
|
|
2272
2277
|
}
|
|
2273
2278
|
});
|
|
2274
2279
|
}, [i]), h = K(() => new Set(e), [e]), v = Me(
|
|
2275
|
-
(
|
|
2280
|
+
(N) => h.has(mt(N)),
|
|
2276
2281
|
[h]
|
|
2277
|
-
),
|
|
2282
|
+
), m = K(() => {
|
|
2278
2283
|
if (p) return p;
|
|
2279
2284
|
if (t) return fe(t);
|
|
2280
|
-
const
|
|
2281
|
-
(
|
|
2285
|
+
const N = S.find(
|
|
2286
|
+
(w) => Zt(w, c) && v(w)
|
|
2282
2287
|
);
|
|
2283
|
-
return
|
|
2284
|
-
}, [p, t, S, c, v]),
|
|
2285
|
-
(
|
|
2286
|
-
let
|
|
2287
|
-
switch (
|
|
2288
|
+
return N || (S.find((w) => Zt(w, c)) ?? null);
|
|
2289
|
+
}, [p, t, S, c, v]), O = Me(
|
|
2290
|
+
(N, w) => {
|
|
2291
|
+
let C = null;
|
|
2292
|
+
switch (N.key) {
|
|
2288
2293
|
case "ArrowLeft":
|
|
2289
|
-
|
|
2294
|
+
C = new Date(w), C.setDate(w.getDate() - 1);
|
|
2290
2295
|
break;
|
|
2291
2296
|
case "ArrowRight":
|
|
2292
|
-
|
|
2297
|
+
C = new Date(w), C.setDate(w.getDate() + 1);
|
|
2293
2298
|
break;
|
|
2294
2299
|
case "ArrowUp":
|
|
2295
|
-
|
|
2300
|
+
C = new Date(w), C.setDate(w.getDate() - 7);
|
|
2296
2301
|
break;
|
|
2297
2302
|
case "ArrowDown":
|
|
2298
|
-
|
|
2303
|
+
C = new Date(w), C.setDate(w.getDate() + 7);
|
|
2299
2304
|
break;
|
|
2300
2305
|
case "Home":
|
|
2301
|
-
|
|
2306
|
+
C = new Date(w), C.setDate(w.getDate() - w.getDay());
|
|
2302
2307
|
break;
|
|
2303
2308
|
case "End":
|
|
2304
|
-
|
|
2309
|
+
C = new Date(w), C.setDate(w.getDate() + (6 - w.getDay()));
|
|
2305
2310
|
break;
|
|
2306
2311
|
case "Enter":
|
|
2307
2312
|
case " ": {
|
|
2308
|
-
|
|
2313
|
+
N.preventDefault(), v(w) && r(mt(w));
|
|
2309
2314
|
return;
|
|
2310
2315
|
}
|
|
2311
2316
|
default:
|
|
2312
2317
|
return;
|
|
2313
2318
|
}
|
|
2314
|
-
|
|
2319
|
+
C && (N.preventDefault(), Zt(C, c) || u(Ft(C)), f(C));
|
|
2315
2320
|
},
|
|
2316
2321
|
[v, r, c]
|
|
2317
2322
|
);
|
|
2318
|
-
return s ? /* @__PURE__ */
|
|
2323
|
+
return s ? /* @__PURE__ */ b(
|
|
2319
2324
|
"div",
|
|
2320
2325
|
{
|
|
2321
2326
|
role: "status",
|
|
@@ -2324,21 +2329,21 @@ function li({
|
|
|
2324
2329
|
className: "ds:flex ds:flex-col ds:gap-[var(--spacing-sm)]",
|
|
2325
2330
|
children: [
|
|
2326
2331
|
/* @__PURE__ */ n(rn, { variant: "text", width: "40%" }),
|
|
2327
|
-
/* @__PURE__ */ n("div", { className: "ds:grid ds:grid-cols-7 ds:gap-[var(--spacing-2xs)]", children: Array.from({ length: 42 }, (
|
|
2332
|
+
/* @__PURE__ */ n("div", { className: "ds:grid ds:grid-cols-7 ds:gap-[var(--spacing-2xs)]", children: Array.from({ length: 42 }, (N, w) => /* @__PURE__ */ n(rn, { variant: "rounded", height: "2.5rem" }, `mg-skel-${w}`)) })
|
|
2328
2333
|
]
|
|
2329
2334
|
}
|
|
2330
|
-
) : /* @__PURE__ */
|
|
2331
|
-
/* @__PURE__ */
|
|
2335
|
+
) : /* @__PURE__ */ b("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-sm)]", children: [
|
|
2336
|
+
/* @__PURE__ */ b("div", { className: "ds:flex ds:items-center ds:justify-between ds:gap-[var(--spacing-sm)]", children: [
|
|
2332
2337
|
/* @__PURE__ */ n(
|
|
2333
2338
|
Mn,
|
|
2334
2339
|
{
|
|
2335
|
-
icon: /* @__PURE__ */ n(
|
|
2340
|
+
icon: /* @__PURE__ */ n(zr, {}),
|
|
2336
2341
|
"aria-label": a("booking.previousMonth"),
|
|
2337
2342
|
size: "sm",
|
|
2338
2343
|
intent: "ghost",
|
|
2339
2344
|
flipIconInRtl: !0,
|
|
2340
2345
|
onClick: () => {
|
|
2341
|
-
|
|
2346
|
+
u((N) => vs(N)), f(null);
|
|
2342
2347
|
}
|
|
2343
2348
|
}
|
|
2344
2349
|
),
|
|
@@ -2353,18 +2358,18 @@ function li({
|
|
|
2353
2358
|
/* @__PURE__ */ n(
|
|
2354
2359
|
Mn,
|
|
2355
2360
|
{
|
|
2356
|
-
icon: /* @__PURE__ */ n(
|
|
2361
|
+
icon: /* @__PURE__ */ n(Kr, {}),
|
|
2357
2362
|
"aria-label": a("booking.nextMonth"),
|
|
2358
2363
|
size: "sm",
|
|
2359
2364
|
intent: "ghost",
|
|
2360
2365
|
flipIconInRtl: !0,
|
|
2361
2366
|
onClick: () => {
|
|
2362
|
-
|
|
2367
|
+
u((N) => Kn(N, 1)), f(null);
|
|
2363
2368
|
}
|
|
2364
2369
|
}
|
|
2365
2370
|
)
|
|
2366
2371
|
] }),
|
|
2367
|
-
/* @__PURE__ */
|
|
2372
|
+
/* @__PURE__ */ b(
|
|
2368
2373
|
"div",
|
|
2369
2374
|
{
|
|
2370
2375
|
role: "grid",
|
|
@@ -2376,30 +2381,30 @@ function li({
|
|
|
2376
2381
|
{
|
|
2377
2382
|
role: "row",
|
|
2378
2383
|
className: "ds:grid ds:grid-cols-7 ds:gap-[var(--spacing-2xs)]",
|
|
2379
|
-
children:
|
|
2384
|
+
children: l.map((N, w) => /* @__PURE__ */ n(
|
|
2380
2385
|
"div",
|
|
2381
2386
|
{
|
|
2382
2387
|
role: "columnheader",
|
|
2383
2388
|
className: "type-meta ds:text-center ds:text-[var(--muted-foreground)] ds:font-[var(--font-weight-medium)]",
|
|
2384
|
-
children:
|
|
2389
|
+
children: N
|
|
2385
2390
|
},
|
|
2386
|
-
`wd-${
|
|
2391
|
+
`wd-${w}`
|
|
2387
2392
|
))
|
|
2388
2393
|
}
|
|
2389
2394
|
),
|
|
2390
|
-
Array.from({ length: 6 }, (
|
|
2395
|
+
Array.from({ length: 6 }, (N, w) => /* @__PURE__ */ n(
|
|
2391
2396
|
"div",
|
|
2392
2397
|
{
|
|
2393
2398
|
role: "row",
|
|
2394
2399
|
className: "ds:grid ds:grid-cols-7 ds:gap-[var(--spacing-2xs)]",
|
|
2395
|
-
children: S.slice(
|
|
2396
|
-
const
|
|
2400
|
+
children: S.slice(w * 7, w * 7 + 7).map((C, M) => {
|
|
2401
|
+
const D = w * 7 + M, _ = Zt(C, c), R = _ && v(C), $ = t ? Rn(C, fe(t)) : !1, j = _ ? $ ? "selected" : R ? "available" : "unavailable" : "outside", T = m ? Rn(m, C) : !1, k = (() => {
|
|
2397
2402
|
try {
|
|
2398
2403
|
return new Intl.DateTimeFormat(i, {
|
|
2399
2404
|
dateStyle: "full"
|
|
2400
|
-
}).format(
|
|
2405
|
+
}).format(C);
|
|
2401
2406
|
} catch {
|
|
2402
|
-
return nn(
|
|
2407
|
+
return nn(C, "PPP");
|
|
2403
2408
|
}
|
|
2404
2409
|
})();
|
|
2405
2410
|
return /* @__PURE__ */ n(
|
|
@@ -2413,17 +2418,17 @@ function li({
|
|
|
2413
2418
|
tabIndex: T ? 0 : -1,
|
|
2414
2419
|
disabled: !R,
|
|
2415
2420
|
onClick: () => {
|
|
2416
|
-
R && r(mt(
|
|
2421
|
+
R && r(mt(C));
|
|
2417
2422
|
},
|
|
2418
|
-
onKeyDown: (L) =>
|
|
2423
|
+
onKeyDown: (L) => O(L, C),
|
|
2419
2424
|
className: di({ state: j }),
|
|
2420
|
-
children: /* @__PURE__ */ n("span", { "aria-hidden": "true", children:
|
|
2425
|
+
children: /* @__PURE__ */ n("span", { "aria-hidden": "true", children: C.getDate() })
|
|
2421
2426
|
},
|
|
2422
|
-
`mg-cell-${
|
|
2427
|
+
`mg-cell-${D}`
|
|
2423
2428
|
);
|
|
2424
2429
|
})
|
|
2425
2430
|
},
|
|
2426
|
-
`mg-row-${
|
|
2431
|
+
`mg-row-${w}`
|
|
2427
2432
|
))
|
|
2428
2433
|
]
|
|
2429
2434
|
}
|
|
@@ -2462,42 +2467,42 @@ function mi({
|
|
|
2462
2467
|
onSelect: r,
|
|
2463
2468
|
showDuration: i
|
|
2464
2469
|
}) {
|
|
2465
|
-
const { t: s } = Q("ui"), a =
|
|
2470
|
+
const { t: s } = Q("ui"), a = ir(), o = pt(), [c, u] = J(() => {
|
|
2466
2471
|
if (t) {
|
|
2467
|
-
const g = e.findIndex((
|
|
2472
|
+
const g = e.findIndex((l) => l.id === t);
|
|
2468
2473
|
if (g >= 0) return g;
|
|
2469
2474
|
}
|
|
2470
2475
|
return 0;
|
|
2471
2476
|
}), p = A(/* @__PURE__ */ new Map()), f = Me((g) => {
|
|
2472
|
-
var
|
|
2473
|
-
(
|
|
2477
|
+
var l;
|
|
2478
|
+
(l = p.current.get(g)) == null || l.focus();
|
|
2474
2479
|
}, []), S = Me(
|
|
2475
|
-
(g,
|
|
2480
|
+
(g, l, h) => {
|
|
2476
2481
|
const v = e.length;
|
|
2477
2482
|
if (v !== 0)
|
|
2478
2483
|
switch (g.key) {
|
|
2479
2484
|
case "ArrowDown":
|
|
2480
2485
|
case "ArrowRight": {
|
|
2481
2486
|
g.preventDefault();
|
|
2482
|
-
const
|
|
2483
|
-
m
|
|
2487
|
+
const m = (l + 1) % v;
|
|
2488
|
+
u(m), f(m);
|
|
2484
2489
|
break;
|
|
2485
2490
|
}
|
|
2486
2491
|
case "ArrowUp":
|
|
2487
2492
|
case "ArrowLeft": {
|
|
2488
2493
|
g.preventDefault();
|
|
2489
|
-
const
|
|
2490
|
-
m
|
|
2494
|
+
const m = (l - 1 + v) % v;
|
|
2495
|
+
u(m), f(m);
|
|
2491
2496
|
break;
|
|
2492
2497
|
}
|
|
2493
2498
|
case "Home": {
|
|
2494
|
-
g.preventDefault(),
|
|
2499
|
+
g.preventDefault(), u(0), f(0);
|
|
2495
2500
|
break;
|
|
2496
2501
|
}
|
|
2497
2502
|
case "End": {
|
|
2498
2503
|
g.preventDefault();
|
|
2499
|
-
const
|
|
2500
|
-
m
|
|
2504
|
+
const m = v - 1;
|
|
2505
|
+
u(m), f(m);
|
|
2501
2506
|
break;
|
|
2502
2507
|
}
|
|
2503
2508
|
case "Enter":
|
|
@@ -2516,35 +2521,35 @@ function mi({
|
|
|
2516
2521
|
"aria-label": s("booking.serviceListLabel"),
|
|
2517
2522
|
id: o,
|
|
2518
2523
|
className: "ds:flex ds:flex-col ds:gap-[var(--spacing-sm)]",
|
|
2519
|
-
children: e.map((g,
|
|
2520
|
-
const h = t === g.id, v = c ===
|
|
2524
|
+
children: e.map((g, l) => {
|
|
2525
|
+
const h = t === g.id, v = c === l, { price: m, payment: O, paymentTone: N } = a(g), w = m ? O ? s("booking.serviceCardLabelPayment", {
|
|
2521
2526
|
label: g.label,
|
|
2522
|
-
price:
|
|
2523
|
-
payment:
|
|
2527
|
+
price: m,
|
|
2528
|
+
payment: O
|
|
2524
2529
|
}) : s("booking.serviceCardLabelPrice", {
|
|
2525
2530
|
label: g.label,
|
|
2526
|
-
price:
|
|
2527
|
-
}) :
|
|
2531
|
+
price: m
|
|
2532
|
+
}) : O ? s("booking.serviceCardLabelPaymentNoPrice", {
|
|
2528
2533
|
label: g.label,
|
|
2529
|
-
payment:
|
|
2534
|
+
payment: O
|
|
2530
2535
|
}) : i ? s("booking.serviceCardLabel", {
|
|
2531
2536
|
label: g.label,
|
|
2532
2537
|
duration: g.durationMin
|
|
2533
|
-
}) : g.label,
|
|
2534
|
-
return /* @__PURE__ */
|
|
2538
|
+
}) : g.label, C = ai(g);
|
|
2539
|
+
return /* @__PURE__ */ b(
|
|
2535
2540
|
"button",
|
|
2536
2541
|
{
|
|
2537
|
-
ref: (
|
|
2538
|
-
|
|
2542
|
+
ref: (M) => {
|
|
2543
|
+
M ? p.current.set(l, M) : p.current.delete(l);
|
|
2539
2544
|
},
|
|
2540
2545
|
type: "button",
|
|
2541
2546
|
role: "radio",
|
|
2542
2547
|
"aria-checked": h,
|
|
2543
|
-
"aria-label":
|
|
2548
|
+
"aria-label": w,
|
|
2544
2549
|
tabIndex: v ? 0 : -1,
|
|
2545
2550
|
onClick: () => r(g.id),
|
|
2546
|
-
onFocus: () =>
|
|
2547
|
-
onKeyDown: (
|
|
2551
|
+
onFocus: () => u(l),
|
|
2552
|
+
onKeyDown: (M) => S(M, l, g.id),
|
|
2548
2553
|
className: ui({
|
|
2549
2554
|
state: h ? "selected" : "idle"
|
|
2550
2555
|
}),
|
|
@@ -2554,10 +2559,10 @@ function mi({
|
|
|
2554
2559
|
{
|
|
2555
2560
|
"aria-hidden": "true",
|
|
2556
2561
|
className: "ds:flex ds:size-10 ds:shrink-0 ds:items-center ds:justify-center ds:rounded-[var(--radius-sm)] ds:bg-[var(--primary)]/10 ds:text-[var(--primary)]",
|
|
2557
|
-
children:
|
|
2562
|
+
children: C
|
|
2558
2563
|
}
|
|
2559
2564
|
),
|
|
2560
|
-
/* @__PURE__ */
|
|
2565
|
+
/* @__PURE__ */ b("span", { className: "ds:flex ds:min-w-0 ds:flex-1 ds:flex-col ds:gap-[var(--spacing-2xs)]", children: [
|
|
2561
2566
|
/* @__PURE__ */ n(
|
|
2562
2567
|
"span",
|
|
2563
2568
|
{
|
|
@@ -2566,22 +2571,22 @@ function mi({
|
|
|
2566
2571
|
children: g.label
|
|
2567
2572
|
}
|
|
2568
2573
|
),
|
|
2569
|
-
|
|
2574
|
+
O ? /* @__PURE__ */ n(
|
|
2570
2575
|
"span",
|
|
2571
2576
|
{
|
|
2572
|
-
className:
|
|
2573
|
-
children:
|
|
2577
|
+
className: Dr({ tone: N }),
|
|
2578
|
+
children: O
|
|
2574
2579
|
}
|
|
2575
|
-
) :
|
|
2580
|
+
) : m || !i ? null : /* @__PURE__ */ n("span", { className: "type-meta ds:text-[var(--muted-foreground)]", children: s("booking.serviceSummary", {
|
|
2576
2581
|
minutes: g.durationMin
|
|
2577
2582
|
}) })
|
|
2578
2583
|
] }),
|
|
2579
|
-
|
|
2584
|
+
m ? /* @__PURE__ */ n(
|
|
2580
2585
|
"span",
|
|
2581
2586
|
{
|
|
2582
2587
|
"aria-hidden": "true",
|
|
2583
2588
|
className: "ds:inline-flex ds:shrink-0 ds:items-center ds:ms-auto",
|
|
2584
|
-
children: /* @__PURE__ */ n(zn, { variant: "accentSoft", size: "lg", children:
|
|
2589
|
+
children: /* @__PURE__ */ n(zn, { variant: "accentSoft", size: "lg", children: m })
|
|
2585
2590
|
}
|
|
2586
2591
|
) : null
|
|
2587
2592
|
]
|
|
@@ -2634,9 +2639,9 @@ function sn(e, t, r) {
|
|
|
2634
2639
|
}
|
|
2635
2640
|
}
|
|
2636
2641
|
const gi = {
|
|
2637
|
-
morning:
|
|
2638
|
-
afternoon:
|
|
2639
|
-
evening:
|
|
2642
|
+
morning: $r,
|
|
2643
|
+
afternoon: gs,
|
|
2644
|
+
evening: Vr
|
|
2640
2645
|
};
|
|
2641
2646
|
function hi({
|
|
2642
2647
|
emptyDescription: e,
|
|
@@ -2647,7 +2652,7 @@ function hi({
|
|
|
2647
2652
|
loading: a,
|
|
2648
2653
|
locale: o
|
|
2649
2654
|
}) {
|
|
2650
|
-
const { t: c } = Q("ui"),
|
|
2655
|
+
const { t: c } = Q("ui"), u = K(() => {
|
|
2651
2656
|
try {
|
|
2652
2657
|
return new Intl.DateTimeFormat(o, {
|
|
2653
2658
|
weekday: "long",
|
|
@@ -2663,17 +2668,17 @@ function hi({
|
|
|
2663
2668
|
afternoon: [],
|
|
2664
2669
|
evening: []
|
|
2665
2670
|
};
|
|
2666
|
-
for (const
|
|
2667
|
-
g[fi(
|
|
2671
|
+
for (const l of r)
|
|
2672
|
+
g[fi(l.time)].push(l);
|
|
2668
2673
|
return g;
|
|
2669
2674
|
}, [r]), f = r.filter((g) => g.available).length, S = ["morning", "afternoon", "evening"];
|
|
2670
|
-
return a ? /* @__PURE__ */
|
|
2675
|
+
return a ? /* @__PURE__ */ b("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-sm)]", children: [
|
|
2671
2676
|
/* @__PURE__ */ n(rn, { variant: "text", width: "60%" }),
|
|
2672
2677
|
[0, 1].map((g) => /* @__PURE__ */ n(
|
|
2673
2678
|
"div",
|
|
2674
2679
|
{
|
|
2675
2680
|
className: "ds:grid ds:grid-cols-3 ds:gap-[var(--spacing-xs)]",
|
|
2676
|
-
children: [0, 1, 2].map((
|
|
2681
|
+
children: [0, 1, 2].map((l) => /* @__PURE__ */ n(rn, { variant: "rounded", height: "44px" }, l))
|
|
2677
2682
|
},
|
|
2678
2683
|
g
|
|
2679
2684
|
))
|
|
@@ -2684,30 +2689,30 @@ function hi({
|
|
|
2684
2689
|
title: c("booking.noSlotsForDate"),
|
|
2685
2690
|
description: e
|
|
2686
2691
|
}
|
|
2687
|
-
) : /* @__PURE__ */
|
|
2688
|
-
/* @__PURE__ */
|
|
2689
|
-
/* @__PURE__ */
|
|
2692
|
+
) : /* @__PURE__ */ b("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)]", children: [
|
|
2693
|
+
/* @__PURE__ */ b("div", { className: "ds:flex ds:items-baseline ds:justify-between ds:gap-[var(--spacing-sm)]", children: [
|
|
2694
|
+
/* @__PURE__ */ b("div", { className: "ds:flex ds:items-center ds:gap-[var(--spacing-xs)]", children: [
|
|
2690
2695
|
/* @__PURE__ */ n(
|
|
2691
|
-
|
|
2696
|
+
rs,
|
|
2692
2697
|
{
|
|
2693
2698
|
"aria-hidden": "true",
|
|
2694
2699
|
className: "ds:size-4 ds:text-[color:var(--accent)]"
|
|
2695
2700
|
}
|
|
2696
2701
|
),
|
|
2697
|
-
/* @__PURE__ */ n("h3", { className: "type-label ds:font-[var(--font-weight-semibold)] ds:text-[var(--foreground)] ds:m-0", children:
|
|
2702
|
+
/* @__PURE__ */ n("h3", { className: "type-label ds:font-[var(--font-weight-semibold)] ds:text-[var(--foreground)] ds:m-0", children: u })
|
|
2698
2703
|
] }),
|
|
2699
2704
|
/* @__PURE__ */ n("span", { className: "type-meta ds:text-[var(--muted-foreground)]", children: c("booking.slotsAvailable", { count: f }) })
|
|
2700
2705
|
] }),
|
|
2701
2706
|
S.map((g) => {
|
|
2702
|
-
const
|
|
2703
|
-
if (
|
|
2707
|
+
const l = p[g];
|
|
2708
|
+
if (l.length === 0) return null;
|
|
2704
2709
|
const h = gi[g];
|
|
2705
|
-
return /* @__PURE__ */
|
|
2710
|
+
return /* @__PURE__ */ b(
|
|
2706
2711
|
"div",
|
|
2707
2712
|
{
|
|
2708
2713
|
className: "ds:flex ds:flex-col ds:gap-[var(--spacing-xs)]",
|
|
2709
2714
|
children: [
|
|
2710
|
-
/* @__PURE__ */
|
|
2715
|
+
/* @__PURE__ */ b("div", { className: "ds:flex ds:items-center ds:gap-[var(--spacing-xs)] ds:text-[color:var(--muted-foreground)]", children: [
|
|
2711
2716
|
/* @__PURE__ */ n(h, { "aria-hidden": "true", className: "ds:size-3.5" }),
|
|
2712
2717
|
/* @__PURE__ */ n("span", { className: "type-meta ds:font-[var(--font-weight-semibold)] ds:uppercase", children: c(`booking.timeOfDay.${g}`) })
|
|
2713
2718
|
] }),
|
|
@@ -2717,20 +2722,20 @@ function hi({
|
|
|
2717
2722
|
role: "group",
|
|
2718
2723
|
"aria-label": c(`booking.timeOfDay.${g}`),
|
|
2719
2724
|
className: "ds:grid ds:grid-cols-3 ds:gap-[var(--spacing-xs)] ds:sm:grid-cols-4",
|
|
2720
|
-
children:
|
|
2721
|
-
const
|
|
2725
|
+
children: l.map((v) => {
|
|
2726
|
+
const m = v.key === i, O = v.available ? m ? "selected" : "idle" : "unavailable";
|
|
2722
2727
|
return /* @__PURE__ */ n(
|
|
2723
2728
|
"button",
|
|
2724
2729
|
{
|
|
2725
2730
|
type: "button",
|
|
2726
2731
|
"data-slot-id": v.key,
|
|
2727
2732
|
disabled: !v.available,
|
|
2728
|
-
"aria-pressed":
|
|
2733
|
+
"aria-pressed": m,
|
|
2729
2734
|
"aria-label": c("booking.slotAvailableLabel", {
|
|
2730
2735
|
time: sn(t, v.time, o)
|
|
2731
2736
|
}),
|
|
2732
2737
|
onClick: () => v.available && s(v),
|
|
2733
|
-
className: pi({ state:
|
|
2738
|
+
className: pi({ state: O }),
|
|
2734
2739
|
children: sn(t, v.time, o)
|
|
2735
2740
|
},
|
|
2736
2741
|
v.key
|
|
@@ -2755,31 +2760,31 @@ function vi({
|
|
|
2755
2760
|
onWindowChange: a,
|
|
2756
2761
|
nextAvailableDate: o,
|
|
2757
2762
|
loadingDates: c,
|
|
2758
|
-
loadingSlots:
|
|
2763
|
+
loadingSlots: u,
|
|
2759
2764
|
slotLoadError: p,
|
|
2760
2765
|
onRetrySlots: f,
|
|
2761
2766
|
emptySlotsDescription: S,
|
|
2762
2767
|
locale: g,
|
|
2763
|
-
agentIdBase:
|
|
2768
|
+
agentIdBase: l
|
|
2764
2769
|
}) {
|
|
2765
2770
|
var Ne, ge;
|
|
2766
2771
|
const h = K(() => rt(/* @__PURE__ */ new Date()), []), v = A(
|
|
2767
2772
|
e.length > 0 || !!(r.date && !On(rt(fe(r.date)), h))
|
|
2768
|
-
), [
|
|
2773
|
+
), [m, O] = J(() => {
|
|
2769
2774
|
if (r.date) {
|
|
2770
|
-
const
|
|
2771
|
-
if (!ut(h,
|
|
2775
|
+
const I = rt(fe(r.date));
|
|
2776
|
+
if (!ut(h, I)) return I;
|
|
2772
2777
|
}
|
|
2773
2778
|
if (e.length > 0) {
|
|
2774
|
-
const
|
|
2775
|
-
if (ut(
|
|
2779
|
+
const I = rt(fe(e[0]));
|
|
2780
|
+
if (ut(I, h)) return I;
|
|
2776
2781
|
}
|
|
2777
2782
|
return h;
|
|
2778
|
-
}),
|
|
2779
|
-
() => un(
|
|
2780
|
-
[
|
|
2781
|
-
),
|
|
2782
|
-
const Y = un(
|
|
2783
|
+
}), N = K(
|
|
2784
|
+
() => un(m, tn - 1),
|
|
2785
|
+
[m]
|
|
2786
|
+
), w = K(() => Array.from({ length: tn }, (I, q) => {
|
|
2787
|
+
const Y = un(m, q), U = mt(Y), Be = (t[U] ?? []).map((he) => ({
|
|
2783
2788
|
id: he.key,
|
|
2784
2789
|
// SlotGrid formats `start` as a time via Intl.DateTimeFormat —
|
|
2785
2790
|
// compose a full ISO from the column's date + the slot's HH:mm
|
|
@@ -2788,13 +2793,13 @@ function vi({
|
|
|
2788
2793
|
available: he.available
|
|
2789
2794
|
}));
|
|
2790
2795
|
return { date: U, slots: Be };
|
|
2791
|
-
}), [
|
|
2792
|
-
v.current = !0,
|
|
2793
|
-
const q =
|
|
2796
|
+
}), [m, t]), C = ut(m, h), M = !0, D = Me(() => {
|
|
2797
|
+
v.current = !0, O((I) => {
|
|
2798
|
+
const q = Pr(I, tn);
|
|
2794
2799
|
return ut(h, q) ? h : q;
|
|
2795
2800
|
});
|
|
2796
|
-
}, [h]),
|
|
2797
|
-
v.current = !0,
|
|
2801
|
+
}, [h]), _ = Me(() => {
|
|
2802
|
+
v.current = !0, O((I) => un(I, tn));
|
|
2798
2803
|
}, []), R = [
|
|
2799
2804
|
r.serviceId,
|
|
2800
2805
|
(Ne = r.serviceIds) == null ? void 0 : Ne.join(","),
|
|
@@ -2809,30 +2814,30 @@ function vi({
|
|
|
2809
2814
|
T.current = null;
|
|
2810
2815
|
}
|
|
2811
2816
|
v.current = !0;
|
|
2812
|
-
const
|
|
2813
|
-
!ut(
|
|
2817
|
+
const I = rt(fe(e[0]));
|
|
2818
|
+
!ut(I, h) || e.some((Y) => {
|
|
2814
2819
|
const U = rt(fe(Y));
|
|
2815
|
-
return !ut(U,
|
|
2816
|
-
}) ||
|
|
2817
|
-
}, [e, $, R, h,
|
|
2818
|
-
a == null || a(mt(
|
|
2819
|
-
}, [
|
|
2820
|
+
return !ut(U, N) && !On(U, m);
|
|
2821
|
+
}) || O(I);
|
|
2822
|
+
}, [e, $, R, h, m, N]), V(() => {
|
|
2823
|
+
a == null || a(mt(m), mt(N));
|
|
2824
|
+
}, [m, N, a]);
|
|
2820
2825
|
const k = Me(
|
|
2821
|
-
(
|
|
2826
|
+
(I, q) => {
|
|
2822
2827
|
const Y = typeof q.date == "string" ? q.date : mt(q.date);
|
|
2823
2828
|
i({
|
|
2824
|
-
...Zn(hn(r, Y),
|
|
2829
|
+
...Zn(hn(r, Y), I.id)
|
|
2825
2830
|
}), s == null || s(Y);
|
|
2826
2831
|
},
|
|
2827
2832
|
[i, s, r]
|
|
2828
|
-
), L = c ||
|
|
2829
|
-
return /* @__PURE__ */
|
|
2830
|
-
L !== "loading" && !p && !
|
|
2831
|
-
|
|
2833
|
+
), L = c || u ? "loading" : "default", F = w.some((I) => I.slots.length > 0), W = (e.length === 0 && o ? [o] : e).filter((I) => ut(rt(fe(I)), N)).sort()[0];
|
|
2834
|
+
return /* @__PURE__ */ b("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-sm)]", children: [
|
|
2835
|
+
L !== "loading" && !p && !F && !!W ? /* @__PURE__ */ n(
|
|
2836
|
+
pr,
|
|
2832
2837
|
{
|
|
2833
2838
|
nextAvailableDate: W,
|
|
2834
2839
|
onJump: () => {
|
|
2835
|
-
v.current = !0,
|
|
2840
|
+
v.current = !0, O(rt(fe(W))), s == null || s(W);
|
|
2836
2841
|
},
|
|
2837
2842
|
locale: g
|
|
2838
2843
|
}
|
|
@@ -2845,27 +2850,27 @@ function vi({
|
|
|
2845
2850
|
loading: L === "loading",
|
|
2846
2851
|
onRetry: f,
|
|
2847
2852
|
children: /* @__PURE__ */ n(
|
|
2848
|
-
|
|
2853
|
+
_r,
|
|
2849
2854
|
{
|
|
2850
|
-
id:
|
|
2851
|
-
days:
|
|
2855
|
+
id: l ? `${l}-slots` : void 0,
|
|
2856
|
+
days: w,
|
|
2852
2857
|
emptyDescription: S,
|
|
2853
2858
|
state: L,
|
|
2854
2859
|
selectedSlotId: r.slotKey,
|
|
2855
2860
|
maxInitialSlotsPerDay: 6,
|
|
2856
2861
|
locale: g,
|
|
2857
|
-
hasPrevious:
|
|
2858
|
-
hasNext:
|
|
2862
|
+
hasPrevious: C,
|
|
2863
|
+
hasNext: M,
|
|
2859
2864
|
onSlotSelect: k,
|
|
2860
|
-
onPreviousDays:
|
|
2861
|
-
onNextDays:
|
|
2865
|
+
onPreviousDays: D,
|
|
2866
|
+
onNextDays: _
|
|
2862
2867
|
}
|
|
2863
2868
|
)
|
|
2864
2869
|
}
|
|
2865
2870
|
)
|
|
2866
2871
|
] });
|
|
2867
2872
|
}
|
|
2868
|
-
function
|
|
2873
|
+
function or(e) {
|
|
2869
2874
|
const {
|
|
2870
2875
|
inputs: t,
|
|
2871
2876
|
value: r,
|
|
@@ -2874,12 +2879,12 @@ function sr(e) {
|
|
|
2874
2879
|
onWindowChange: a,
|
|
2875
2880
|
loadingDates: o,
|
|
2876
2881
|
loadingSlots: c,
|
|
2877
|
-
slotLoadError:
|
|
2882
|
+
slotLoadError: u,
|
|
2878
2883
|
onRetrySlots: p,
|
|
2879
2884
|
emptySlotsDescription: f,
|
|
2880
2885
|
locale: S,
|
|
2881
2886
|
datePickerStyle: g,
|
|
2882
|
-
agentIdBase:
|
|
2887
|
+
agentIdBase: l
|
|
2883
2888
|
} = e;
|
|
2884
2889
|
return g === "four-day-grid" ? /* @__PURE__ */ n(
|
|
2885
2890
|
vi,
|
|
@@ -2893,17 +2898,17 @@ function sr(e) {
|
|
|
2893
2898
|
nextAvailableDate: t.nextAvailableDate,
|
|
2894
2899
|
loadingDates: o,
|
|
2895
2900
|
loadingSlots: c,
|
|
2896
|
-
slotLoadError:
|
|
2901
|
+
slotLoadError: u,
|
|
2897
2902
|
onRetrySlots: p,
|
|
2898
2903
|
emptySlotsDescription: f,
|
|
2899
2904
|
locale: S,
|
|
2900
|
-
agentIdBase:
|
|
2905
|
+
agentIdBase: l
|
|
2901
2906
|
}
|
|
2902
|
-
) :
|
|
2907
|
+
) : u && r.date && e.activeStep > 5 && !o && !c ? null : /* @__PURE__ */ n(
|
|
2903
2908
|
In,
|
|
2904
2909
|
{
|
|
2905
2910
|
label: "date",
|
|
2906
|
-
error:
|
|
2911
|
+
error: u,
|
|
2907
2912
|
loading: o || c,
|
|
2908
2913
|
onRetry: p,
|
|
2909
2914
|
children: /* @__PURE__ */ n(bi, { ...e })
|
|
@@ -2918,19 +2923,19 @@ function bi(e) {
|
|
|
2918
2923
|
onDateSelect: a,
|
|
2919
2924
|
loadingDates: o,
|
|
2920
2925
|
loadingSlots: c,
|
|
2921
|
-
locale:
|
|
2926
|
+
locale: u,
|
|
2922
2927
|
emptySlotsDescription: p
|
|
2923
2928
|
} = e;
|
|
2924
2929
|
if (!o && !c && r.availableDates.length === 0) {
|
|
2925
2930
|
if (r.nextAvailableDate)
|
|
2926
2931
|
return /* @__PURE__ */ n(
|
|
2927
|
-
|
|
2932
|
+
pr,
|
|
2928
2933
|
{
|
|
2929
2934
|
nextAvailableDate: r.nextAvailableDate,
|
|
2930
2935
|
onJump: (f) => {
|
|
2931
2936
|
s(hn(i, f)), a == null || a(f);
|
|
2932
2937
|
},
|
|
2933
|
-
locale:
|
|
2938
|
+
locale: u
|
|
2934
2939
|
}
|
|
2935
2940
|
);
|
|
2936
2941
|
if (p !== void 0)
|
|
@@ -2951,12 +2956,12 @@ function bi(e) {
|
|
|
2951
2956
|
onSelectDate: (f) => {
|
|
2952
2957
|
s(hn(i, f)), a == null || a(f);
|
|
2953
2958
|
},
|
|
2954
|
-
locale:
|
|
2959
|
+
locale: u,
|
|
2955
2960
|
loading: o ?? c
|
|
2956
2961
|
}
|
|
2957
2962
|
);
|
|
2958
2963
|
}
|
|
2959
|
-
function
|
|
2964
|
+
function ar(e) {
|
|
2960
2965
|
const {
|
|
2961
2966
|
inputs: t,
|
|
2962
2967
|
value: r,
|
|
@@ -2965,7 +2970,7 @@ function ir(e) {
|
|
|
2965
2970
|
loadingSlots: a,
|
|
2966
2971
|
slotLoadError: o,
|
|
2967
2972
|
onRetrySlots: c,
|
|
2968
|
-
emptySlotsDescription:
|
|
2973
|
+
emptySlotsDescription: u,
|
|
2969
2974
|
locale: p,
|
|
2970
2975
|
datePickerStyle: f
|
|
2971
2976
|
} = e;
|
|
@@ -2984,19 +2989,19 @@ function ir(e) {
|
|
|
2984
2989
|
selectedSlotKey: r.slotKey,
|
|
2985
2990
|
onSelect: (S) => i(Zn(r, S.key)),
|
|
2986
2991
|
loading: s || a,
|
|
2987
|
-
emptyDescription:
|
|
2992
|
+
emptyDescription: u,
|
|
2988
2993
|
locale: p
|
|
2989
2994
|
}
|
|
2990
2995
|
)
|
|
2991
2996
|
}
|
|
2992
2997
|
);
|
|
2993
2998
|
}
|
|
2994
|
-
function
|
|
2999
|
+
function cr({ value: e, onChange: t }) {
|
|
2995
3000
|
const { t: r } = Q("ui"), i = [
|
|
2996
3001
|
{ value: "private", label: r("booking.insurance.private") },
|
|
2997
3002
|
{ value: "public", label: r("booking.insurance.public") }
|
|
2998
3003
|
];
|
|
2999
|
-
return /* @__PURE__ */
|
|
3004
|
+
return /* @__PURE__ */ b("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-sm)]", children: [
|
|
3000
3005
|
/* @__PURE__ */ n("h3", { className: "type-label ds:font-[var(--font-weight-semibold)] ds:text-[var(--foreground)] ds:m-0", children: r("booking.insurance.heading") }),
|
|
3001
3006
|
/* @__PURE__ */ n(
|
|
3002
3007
|
an,
|
|
@@ -3012,7 +3017,7 @@ function or({ value: e, onChange: t }) {
|
|
|
3012
3017
|
)
|
|
3013
3018
|
] });
|
|
3014
3019
|
}
|
|
3015
|
-
function
|
|
3020
|
+
function dr({
|
|
3016
3021
|
specialties: e,
|
|
3017
3022
|
value: t,
|
|
3018
3023
|
valueIds: r,
|
|
@@ -3024,9 +3029,9 @@ function ar({
|
|
|
3024
3029
|
value: p.id,
|
|
3025
3030
|
label: p.label,
|
|
3026
3031
|
dir: "auto"
|
|
3027
|
-
})),
|
|
3028
|
-
return a === "multi-select" && s ? /* @__PURE__ */
|
|
3029
|
-
|
|
3032
|
+
})), u = /* @__PURE__ */ n("h3", { className: "type-label ds:font-[var(--font-weight-semibold)] ds:text-[var(--foreground)] ds:m-0", children: o("booking.specialty.heading") });
|
|
3033
|
+
return a === "multi-select" && s ? /* @__PURE__ */ b("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-sm)]", children: [
|
|
3034
|
+
u,
|
|
3030
3035
|
/* @__PURE__ */ n(
|
|
3031
3036
|
yn,
|
|
3032
3037
|
{
|
|
@@ -3038,8 +3043,8 @@ function ar({
|
|
|
3038
3043
|
allowClear: !0
|
|
3039
3044
|
}
|
|
3040
3045
|
)
|
|
3041
|
-
] }) : a === "combobox" ? /* @__PURE__ */
|
|
3042
|
-
|
|
3046
|
+
] }) : a === "combobox" ? /* @__PURE__ */ b("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-sm)]", children: [
|
|
3047
|
+
u,
|
|
3043
3048
|
/* @__PURE__ */ n(
|
|
3044
3049
|
bn,
|
|
3045
3050
|
{
|
|
@@ -3051,8 +3056,8 @@ function ar({
|
|
|
3051
3056
|
clearable: !0
|
|
3052
3057
|
}
|
|
3053
3058
|
)
|
|
3054
|
-
] }) : /* @__PURE__ */
|
|
3055
|
-
|
|
3059
|
+
] }) : /* @__PURE__ */ b("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-sm)]", children: [
|
|
3060
|
+
u,
|
|
3056
3061
|
/* @__PURE__ */ n(
|
|
3057
3062
|
an,
|
|
3058
3063
|
{
|
|
@@ -3065,7 +3070,7 @@ function ar({
|
|
|
3065
3070
|
)
|
|
3066
3071
|
] });
|
|
3067
3072
|
}
|
|
3068
|
-
function
|
|
3073
|
+
function lr({
|
|
3069
3074
|
services: e,
|
|
3070
3075
|
value: t,
|
|
3071
3076
|
valueIds: r,
|
|
@@ -3075,23 +3080,23 @@ function cr({
|
|
|
3075
3080
|
compact: o,
|
|
3076
3081
|
showDuration: c
|
|
3077
3082
|
}) {
|
|
3078
|
-
const { t:
|
|
3079
|
-
const { price: h, payment: v, paymentTone:
|
|
3083
|
+
const { t: u } = Q("ui"), p = ir(), f = a ?? (o ? "select" : "cards"), S = e.map((l) => {
|
|
3084
|
+
const { price: h, payment: v, paymentTone: m } = p(l);
|
|
3080
3085
|
return {
|
|
3081
|
-
value:
|
|
3086
|
+
value: l.id,
|
|
3082
3087
|
// The practice's service name leads the label, so it decides the
|
|
3083
3088
|
// direction, even when the kit's duration is appended after it.
|
|
3084
3089
|
dir: "auto",
|
|
3085
|
-
label: h || v || !c ?
|
|
3086
|
-
minutes:
|
|
3090
|
+
label: h || v || !c ? l.label : `${l.label} · ${u("booking.serviceSummary", {
|
|
3091
|
+
minutes: l.durationMin
|
|
3087
3092
|
})}`,
|
|
3088
3093
|
...h ? {
|
|
3089
3094
|
endContent: /* @__PURE__ */ n(zn, { variant: "accentSoft", size: "lg", children: h })
|
|
3090
3095
|
} : {},
|
|
3091
|
-
...v ? { description: v, descriptionTone:
|
|
3096
|
+
...v ? { description: v, descriptionTone: m } : {}
|
|
3092
3097
|
};
|
|
3093
|
-
}), g = /* @__PURE__ */ n("h3", { className: "type-label ds:font-[var(--font-weight-semibold)] ds:text-[var(--foreground)] ds:m-0", children:
|
|
3094
|
-
return f === "multi-select" && s ? /* @__PURE__ */
|
|
3098
|
+
}), g = /* @__PURE__ */ n("h3", { className: "type-label ds:font-[var(--font-weight-semibold)] ds:text-[var(--foreground)] ds:m-0", children: u("booking.service.heading") });
|
|
3099
|
+
return f === "multi-select" && s ? /* @__PURE__ */ b("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-sm)]", children: [
|
|
3095
3100
|
g,
|
|
3096
3101
|
/* @__PURE__ */ n(
|
|
3097
3102
|
yn,
|
|
@@ -3099,42 +3104,42 @@ function cr({
|
|
|
3099
3104
|
options: S,
|
|
3100
3105
|
value: r ?? [],
|
|
3101
3106
|
onChange: s,
|
|
3102
|
-
placeholder:
|
|
3103
|
-
"aria-label":
|
|
3107
|
+
placeholder: u("booking.service.placeholder"),
|
|
3108
|
+
"aria-label": u("booking.service.heading"),
|
|
3104
3109
|
allowClear: !0,
|
|
3105
3110
|
wrapOptionLabels: !0
|
|
3106
3111
|
}
|
|
3107
3112
|
)
|
|
3108
|
-
] }) : f === "combobox" ? /* @__PURE__ */
|
|
3113
|
+
] }) : f === "combobox" ? /* @__PURE__ */ b("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-sm)]", children: [
|
|
3109
3114
|
g,
|
|
3110
3115
|
/* @__PURE__ */ n(
|
|
3111
3116
|
bn,
|
|
3112
3117
|
{
|
|
3113
3118
|
options: S,
|
|
3114
3119
|
value: t ?? "",
|
|
3115
|
-
onValueChange: (
|
|
3116
|
-
placeholder:
|
|
3117
|
-
"aria-label":
|
|
3120
|
+
onValueChange: (l) => i(l === "" ? "" : l),
|
|
3121
|
+
placeholder: u("booking.service.placeholder"),
|
|
3122
|
+
"aria-label": u("booking.service.heading"),
|
|
3118
3123
|
clearable: !0,
|
|
3119
3124
|
wrapOptionLabels: !0
|
|
3120
3125
|
}
|
|
3121
3126
|
)
|
|
3122
|
-
] }) : f === "select" ? /* @__PURE__ */
|
|
3127
|
+
] }) : f === "select" ? /* @__PURE__ */ b("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-sm)]", children: [
|
|
3123
3128
|
g,
|
|
3124
3129
|
/* @__PURE__ */ n(
|
|
3125
3130
|
an,
|
|
3126
3131
|
{
|
|
3127
3132
|
options: S,
|
|
3128
3133
|
value: t ?? "",
|
|
3129
|
-
onValueChange: (
|
|
3130
|
-
placeholder:
|
|
3131
|
-
"aria-label":
|
|
3134
|
+
onValueChange: (l) => i(l),
|
|
3135
|
+
placeholder: u("booking.service.placeholder"),
|
|
3136
|
+
"aria-label": u("booking.service.heading"),
|
|
3132
3137
|
showDescriptions: !0,
|
|
3133
3138
|
descriptionInName: !0,
|
|
3134
3139
|
wrapOptionLabels: !0
|
|
3135
3140
|
}
|
|
3136
3141
|
)
|
|
3137
|
-
] }) : /* @__PURE__ */
|
|
3142
|
+
] }) : /* @__PURE__ */ b("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-sm)]", children: [
|
|
3138
3143
|
g,
|
|
3139
3144
|
/* @__PURE__ */ n(
|
|
3140
3145
|
mi,
|
|
@@ -3147,7 +3152,7 @@ function cr({
|
|
|
3147
3152
|
)
|
|
3148
3153
|
] });
|
|
3149
3154
|
}
|
|
3150
|
-
function
|
|
3155
|
+
function ur({
|
|
3151
3156
|
operators: e,
|
|
3152
3157
|
value: t,
|
|
3153
3158
|
valueIds: r,
|
|
@@ -3162,7 +3167,7 @@ function dr({
|
|
|
3162
3167
|
label: f.name,
|
|
3163
3168
|
dir: "auto"
|
|
3164
3169
|
}));
|
|
3165
|
-
return /* @__PURE__ */
|
|
3170
|
+
return /* @__PURE__ */ b("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-sm)]", children: [
|
|
3166
3171
|
c,
|
|
3167
3172
|
/* @__PURE__ */ n(
|
|
3168
3173
|
yn,
|
|
@@ -3177,18 +3182,18 @@ function dr({
|
|
|
3177
3182
|
)
|
|
3178
3183
|
] });
|
|
3179
3184
|
}
|
|
3180
|
-
const
|
|
3185
|
+
const u = [
|
|
3181
3186
|
{ value: qe, label: o("booking.operator.all") },
|
|
3182
3187
|
...e.map(
|
|
3183
3188
|
(p) => ({ value: p.id, label: p.name, dir: "auto" })
|
|
3184
3189
|
)
|
|
3185
3190
|
];
|
|
3186
|
-
return a === "combobox" ? /* @__PURE__ */
|
|
3191
|
+
return a === "combobox" ? /* @__PURE__ */ b("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-sm)]", children: [
|
|
3187
3192
|
c,
|
|
3188
3193
|
/* @__PURE__ */ n(
|
|
3189
3194
|
bn,
|
|
3190
3195
|
{
|
|
3191
|
-
options:
|
|
3196
|
+
options: u,
|
|
3192
3197
|
value: t ?? qe,
|
|
3193
3198
|
onValueChange: (p) => i(p === "" ? qe : p),
|
|
3194
3199
|
placeholder: o("booking.operator.placeholder"),
|
|
@@ -3196,12 +3201,12 @@ function dr({
|
|
|
3196
3201
|
clearable: !0
|
|
3197
3202
|
}
|
|
3198
3203
|
)
|
|
3199
|
-
] }) : /* @__PURE__ */
|
|
3204
|
+
] }) : /* @__PURE__ */ b("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-sm)]", children: [
|
|
3200
3205
|
c,
|
|
3201
3206
|
/* @__PURE__ */ n(
|
|
3202
3207
|
an,
|
|
3203
3208
|
{
|
|
3204
|
-
options:
|
|
3209
|
+
options: u,
|
|
3205
3210
|
value: t ?? qe,
|
|
3206
3211
|
onValueChange: (p) => i(p),
|
|
3207
3212
|
placeholder: o("booking.operator.placeholder"),
|
|
@@ -3210,16 +3215,16 @@ function dr({
|
|
|
3210
3215
|
)
|
|
3211
3216
|
] });
|
|
3212
3217
|
}
|
|
3213
|
-
function
|
|
3218
|
+
function mr({
|
|
3214
3219
|
customSlot: e
|
|
3215
3220
|
}) {
|
|
3216
3221
|
const { t } = Q("ui");
|
|
3217
|
-
return e ? /* @__PURE__ */ n(
|
|
3222
|
+
return e ? /* @__PURE__ */ n(de, { children: e }) : /* @__PURE__ */ b(re, { variant: "warning", children: [
|
|
3218
3223
|
/* @__PURE__ */ n(re.Title, { as: "h4", children: t("booking.onboardingIncomplete.title") }),
|
|
3219
3224
|
/* @__PURE__ */ n(re.Description, { children: t("booking.onboardingIncomplete.description") })
|
|
3220
3225
|
] });
|
|
3221
3226
|
}
|
|
3222
|
-
function
|
|
3227
|
+
function pr({
|
|
3223
3228
|
nextAvailableDate: e,
|
|
3224
3229
|
onJump: t,
|
|
3225
3230
|
locale: r
|
|
@@ -3233,7 +3238,7 @@ function ur({
|
|
|
3233
3238
|
return e;
|
|
3234
3239
|
}
|
|
3235
3240
|
}, [e, r]);
|
|
3236
|
-
return /* @__PURE__ */
|
|
3241
|
+
return /* @__PURE__ */ b(re, { variant: "info", children: [
|
|
3237
3242
|
/* @__PURE__ */ n(re.Description, { children: i("booking.nextAvailable.description", { date: s }) }),
|
|
3238
3243
|
/* @__PURE__ */ n(re.Action, { children: /* @__PURE__ */ n(
|
|
3239
3244
|
Re,
|
|
@@ -3255,33 +3260,33 @@ function yi({
|
|
|
3255
3260
|
confirmationChannels: a,
|
|
3256
3261
|
snapshot: o,
|
|
3257
3262
|
operators: c,
|
|
3258
|
-
specialties:
|
|
3263
|
+
specialties: u,
|
|
3259
3264
|
services: p,
|
|
3260
3265
|
locale: f,
|
|
3261
3266
|
mode: S,
|
|
3262
3267
|
showModify: g,
|
|
3263
|
-
onReset:
|
|
3268
|
+
onReset: l,
|
|
3264
3269
|
onModify: h,
|
|
3265
3270
|
focusWasLost: v
|
|
3266
3271
|
}) {
|
|
3267
|
-
const { t:
|
|
3272
|
+
const { t: m } = Q("ui"), O = A(null);
|
|
3268
3273
|
V(() => {
|
|
3269
|
-
const T =
|
|
3274
|
+
const T = O.current, k = document.activeElement, L = T == null ? void 0 : T.closest('[data-component="booking"]');
|
|
3270
3275
|
T && (k && (L != null && L.contains(k)) || v()) && T.focus();
|
|
3271
3276
|
}, []);
|
|
3272
|
-
const
|
|
3273
|
-
|
|
3277
|
+
const N = Sn(a), C = Qn(
|
|
3278
|
+
N,
|
|
3274
3279
|
o.details.confirmationChannels
|
|
3275
3280
|
).map(
|
|
3276
|
-
(T) =>
|
|
3277
|
-
),
|
|
3281
|
+
(T) => m(`booking.confirmation.channel.${T}`)
|
|
3282
|
+
), M = s ? on(s.amountCents, s.currencyCode, f) : "", D = s ? m(
|
|
3278
3283
|
S === "demo" ? "booking.payment.paidDemo" : "booking.payment.paidBody",
|
|
3279
|
-
{ amount:
|
|
3280
|
-
) : e ?
|
|
3281
|
-
channels:
|
|
3282
|
-
}) :
|
|
3283
|
-
channel:
|
|
3284
|
-
}),
|
|
3284
|
+
{ amount: M }
|
|
3285
|
+
) : e ? m(S === "demo" ? "booking.code.confirmedDemo" : "booking.code.confirmedBody") : S === "demo" ? m("booking.success.descriptionDemo") : C.length > 1 ? m("booking.success.descriptionMultiple", {
|
|
3286
|
+
channels: C.join(" · ")
|
|
3287
|
+
}) : m("booking.success.descriptionSingle", {
|
|
3288
|
+
channel: C[0]
|
|
3289
|
+
}), _ = K(() => {
|
|
3285
3290
|
if (o.date)
|
|
3286
3291
|
try {
|
|
3287
3292
|
return new Intl.DateTimeFormat(f, {
|
|
@@ -3294,8 +3299,8 @@ function yi({
|
|
|
3294
3299
|
}
|
|
3295
3300
|
}, [o.date, f]), R = K(() => {
|
|
3296
3301
|
const k = (o.operatorIds && o.operatorIds.length > 0 ? o.operatorIds : o.operatorId ? [o.operatorId] : []).filter((L) => L !== qe).map((L) => {
|
|
3297
|
-
var
|
|
3298
|
-
return (
|
|
3302
|
+
var F;
|
|
3303
|
+
return (F = c.find((y) => y.id === L)) == null ? void 0 : F.name;
|
|
3299
3304
|
}).filter((L) => L !== void 0);
|
|
3300
3305
|
if (k.length === 0) return [];
|
|
3301
3306
|
try {
|
|
@@ -3304,12 +3309,12 @@ function yi({
|
|
|
3304
3309
|
type: "conjunction"
|
|
3305
3310
|
}).formatToParts(k);
|
|
3306
3311
|
} catch {
|
|
3307
|
-
return k.flatMap((L,
|
|
3308
|
-
...
|
|
3312
|
+
return k.flatMap((L, F) => [
|
|
3313
|
+
...F > 0 ? [{ type: "literal", value: ", " }] : [],
|
|
3309
3314
|
{ type: "element", value: L }
|
|
3310
3315
|
]);
|
|
3311
3316
|
}
|
|
3312
|
-
}, [o.operatorIds, o.operatorId, c, f]), $ = o.specialtyId ?
|
|
3317
|
+
}, [o.operatorIds, o.operatorId, c, f]), $ = o.specialtyId ? u.find((T) => T.id === o.specialtyId) : void 0, j = o.serviceId ? p.find((T) => T.id === o.serviceId) : void 0;
|
|
3313
3318
|
if (t) {
|
|
3314
3319
|
let T;
|
|
3315
3320
|
if (o.date)
|
|
@@ -3323,56 +3328,56 @@ function yi({
|
|
|
3323
3328
|
T = o.date;
|
|
3324
3329
|
}
|
|
3325
3330
|
const k = (j == null ? void 0 : j.label) ?? ($ == null ? void 0 : $.label), L = R.map(
|
|
3326
|
-
(
|
|
3331
|
+
(F, y) => F.type === "element" ? /* @__PURE__ */ n("bdi", { children: F.value }, y) : F.value
|
|
3327
3332
|
);
|
|
3328
3333
|
return /* @__PURE__ */ n(
|
|
3329
|
-
|
|
3334
|
+
ri,
|
|
3330
3335
|
{
|
|
3331
3336
|
url: t,
|
|
3332
|
-
delayMs:
|
|
3337
|
+
delayMs: sr(r),
|
|
3333
3338
|
onNavigate: i,
|
|
3334
3339
|
date: T,
|
|
3335
3340
|
time: sn(o.date, o.slot.time, f),
|
|
3336
|
-
details: k || L.length > 0 ? /* @__PURE__ */
|
|
3341
|
+
details: k || L.length > 0 ? /* @__PURE__ */ b(de, { children: [
|
|
3337
3342
|
k ? /* @__PURE__ */ n("bdi", { children: k }) : null,
|
|
3338
3343
|
k && L.length > 0 ? " · " : null,
|
|
3339
3344
|
L
|
|
3340
3345
|
] }) : void 0,
|
|
3341
|
-
shouldTakeFocus: (
|
|
3342
|
-
const
|
|
3343
|
-
return !!(
|
|
3346
|
+
shouldTakeFocus: (F) => {
|
|
3347
|
+
const y = document.activeElement, W = F.closest('[data-component="booking"]');
|
|
3348
|
+
return !!(y && (W != null && W.contains(y)) || v());
|
|
3344
3349
|
}
|
|
3345
3350
|
}
|
|
3346
3351
|
);
|
|
3347
3352
|
}
|
|
3348
|
-
return /* @__PURE__ */
|
|
3353
|
+
return /* @__PURE__ */ b(
|
|
3349
3354
|
"div",
|
|
3350
3355
|
{
|
|
3351
3356
|
"data-component": "booking-success",
|
|
3352
3357
|
className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)]",
|
|
3353
3358
|
children: [
|
|
3354
|
-
/* @__PURE__ */
|
|
3359
|
+
/* @__PURE__ */ b(re, { variant: "success", children: [
|
|
3355
3360
|
/* @__PURE__ */ n(
|
|
3356
3361
|
re.Title,
|
|
3357
3362
|
{
|
|
3358
3363
|
as: "h3",
|
|
3359
|
-
ref:
|
|
3364
|
+
ref: O,
|
|
3360
3365
|
tabIndex: -1,
|
|
3361
3366
|
className: "ds:outline-none",
|
|
3362
|
-
children:
|
|
3367
|
+
children: m(
|
|
3363
3368
|
s ? S === "demo" ? "booking.payment.paidDemoTitle" : "booking.payment.paidTitle" : e ? "booking.code.confirmedHeading" : "booking.success.heading"
|
|
3364
3369
|
)
|
|
3365
3370
|
}
|
|
3366
3371
|
),
|
|
3367
|
-
/* @__PURE__ */ n(re.Description, { children:
|
|
3372
|
+
/* @__PURE__ */ n(re.Description, { children: D })
|
|
3368
3373
|
] }),
|
|
3369
|
-
/* @__PURE__ */ n("div", { className: "ds:rounded-[var(--radius-md)] ds:bg-[var(--secondary)] ds:p-[var(--spacing-md)]", children: /* @__PURE__ */
|
|
3370
|
-
s && S !== "demo" ? /* @__PURE__ */
|
|
3371
|
-
/* @__PURE__ */ n("dt", { className: "type-label ds:text-[var(--muted-foreground)]", children:
|
|
3372
|
-
/* @__PURE__ */ n("dd", { className: "type-body ds:m-0 ds:text-[var(--foreground)]", children:
|
|
3374
|
+
/* @__PURE__ */ n("div", { className: "ds:rounded-[var(--radius-md)] ds:bg-[var(--secondary)] ds:p-[var(--spacing-md)]", children: /* @__PURE__ */ b("dl", { className: "ds:grid ds:grid-cols-[auto_minmax(0,1fr)] ds:gap-x-[var(--spacing-md)] ds:gap-y-[var(--spacing-xs)] ds:m-0", children: [
|
|
3375
|
+
s && S !== "demo" ? /* @__PURE__ */ b(de, { children: [
|
|
3376
|
+
/* @__PURE__ */ n("dt", { className: "type-label ds:text-[var(--muted-foreground)]", children: m("booking.payment.summaryPaid") }),
|
|
3377
|
+
/* @__PURE__ */ n("dd", { className: "type-body ds:m-0 ds:text-[var(--foreground)]", children: M })
|
|
3373
3378
|
] }) : null,
|
|
3374
|
-
$ ? /* @__PURE__ */
|
|
3375
|
-
/* @__PURE__ */ n("dt", { className: "type-label ds:text-[var(--muted-foreground)]", children:
|
|
3379
|
+
$ ? /* @__PURE__ */ b(de, { children: [
|
|
3380
|
+
/* @__PURE__ */ n("dt", { className: "type-label ds:text-[var(--muted-foreground)]", children: m("booking.success.summarySpecialty") }),
|
|
3376
3381
|
/* @__PURE__ */ n(
|
|
3377
3382
|
"dd",
|
|
3378
3383
|
{
|
|
@@ -3382,8 +3387,8 @@ function yi({
|
|
|
3382
3387
|
}
|
|
3383
3388
|
)
|
|
3384
3389
|
] }) : null,
|
|
3385
|
-
j ? /* @__PURE__ */
|
|
3386
|
-
/* @__PURE__ */ n("dt", { className: "type-label ds:text-[var(--muted-foreground)]", children:
|
|
3390
|
+
j ? /* @__PURE__ */ b(de, { children: [
|
|
3391
|
+
/* @__PURE__ */ n("dt", { className: "type-label ds:text-[var(--muted-foreground)]", children: m("booking.success.summaryService") }),
|
|
3387
3392
|
/* @__PURE__ */ n(
|
|
3388
3393
|
"dd",
|
|
3389
3394
|
{
|
|
@@ -3393,30 +3398,30 @@ function yi({
|
|
|
3393
3398
|
}
|
|
3394
3399
|
)
|
|
3395
3400
|
] }) : null,
|
|
3396
|
-
|
|
3397
|
-
/* @__PURE__ */ n("dt", { className: "type-label ds:text-[var(--muted-foreground)]", children:
|
|
3398
|
-
/* @__PURE__ */ n("dd", { className: "type-body ds:m-0 ds:text-[var(--foreground)]", children:
|
|
3401
|
+
_ ? /* @__PURE__ */ b(de, { children: [
|
|
3402
|
+
/* @__PURE__ */ n("dt", { className: "type-label ds:text-[var(--muted-foreground)]", children: m("booking.success.summaryDate") }),
|
|
3403
|
+
/* @__PURE__ */ n("dd", { className: "type-body ds:m-0 ds:text-[var(--foreground)]", children: _ })
|
|
3399
3404
|
] }) : null,
|
|
3400
|
-
/* @__PURE__ */ n("dt", { className: "type-label ds:text-[var(--muted-foreground)]", children:
|
|
3405
|
+
/* @__PURE__ */ n("dt", { className: "type-label ds:text-[var(--muted-foreground)]", children: m("booking.success.summaryTime") }),
|
|
3401
3406
|
/* @__PURE__ */ n("dd", { className: "type-body ds:m-0 ds:text-[var(--foreground)]", children: sn(o.date, o.slot.time, f) }),
|
|
3402
|
-
R.length > 0 ? /* @__PURE__ */
|
|
3403
|
-
/* @__PURE__ */ n("dt", { className: "type-label ds:text-[var(--muted-foreground)]", children:
|
|
3407
|
+
R.length > 0 ? /* @__PURE__ */ b(de, { children: [
|
|
3408
|
+
/* @__PURE__ */ n("dt", { className: "type-label ds:text-[var(--muted-foreground)]", children: m("booking.success.summaryProvider") }),
|
|
3404
3409
|
/* @__PURE__ */ n("dd", { className: "type-body ds:m-0 ds:text-[var(--foreground)]", children: R.map(
|
|
3405
3410
|
(T, k) => T.type === "element" ? /* @__PURE__ */ n("bdi", { children: T.value }, k) : T.value
|
|
3406
3411
|
) })
|
|
3407
3412
|
] }) : null
|
|
3408
3413
|
] }) }),
|
|
3409
|
-
/* @__PURE__ */
|
|
3410
|
-
/* @__PURE__ */ n(Re, { intent: "secondary", size: "md", onClick:
|
|
3411
|
-
g ? /* @__PURE__ */ n(Re, { intent: "ghost", size: "md", onClick: h, children:
|
|
3414
|
+
/* @__PURE__ */ b("div", { className: "ds:flex ds:flex-wrap ds:items-center ds:gap-[var(--spacing-sm)]", children: [
|
|
3415
|
+
/* @__PURE__ */ n(Re, { intent: "secondary", size: "md", onClick: l, children: m("booking.success.bookAnother") }),
|
|
3416
|
+
g ? /* @__PURE__ */ n(Re, { intent: "ghost", size: "md", onClick: h, children: m("booking.success.modifyBooking") }) : null
|
|
3412
3417
|
] })
|
|
3413
3418
|
]
|
|
3414
3419
|
}
|
|
3415
3420
|
);
|
|
3416
3421
|
}
|
|
3417
|
-
function
|
|
3422
|
+
function fr({ customSlot: e }) {
|
|
3418
3423
|
const { t } = Q("ui");
|
|
3419
|
-
return e ? /* @__PURE__ */ n(
|
|
3424
|
+
return e ? /* @__PURE__ */ n(de, { children: e }) : /* @__PURE__ */ n(
|
|
3420
3425
|
kn,
|
|
3421
3426
|
{
|
|
3422
3427
|
variant: "no-results",
|
|
@@ -3425,7 +3430,7 @@ function mr({ customSlot: e }) {
|
|
|
3425
3430
|
}
|
|
3426
3431
|
);
|
|
3427
3432
|
}
|
|
3428
|
-
const
|
|
3433
|
+
const gr = "data-booking-step-active", Ln = `[${gr}]`;
|
|
3429
3434
|
function ce({
|
|
3430
3435
|
step: e,
|
|
3431
3436
|
active: t,
|
|
@@ -3438,7 +3443,7 @@ function ce({
|
|
|
3438
3443
|
{
|
|
3439
3444
|
id: i,
|
|
3440
3445
|
"data-booking-step": String(e),
|
|
3441
|
-
...t ? { [
|
|
3446
|
+
...t ? { [gr]: "" } : null,
|
|
3442
3447
|
tabIndex: -1,
|
|
3443
3448
|
className: r ? `${r} ${Bt}` : Bt,
|
|
3444
3449
|
children: s
|
|
@@ -3457,113 +3462,113 @@ function ki(e) {
|
|
|
3457
3462
|
onSubmit: a,
|
|
3458
3463
|
emptyServicesSlot: o,
|
|
3459
3464
|
onboardingIncompleteSlot: c,
|
|
3460
|
-
loadingDates:
|
|
3465
|
+
loadingDates: u,
|
|
3461
3466
|
loadingSlots: p,
|
|
3462
3467
|
slotLoadError: f,
|
|
3463
3468
|
onRetrySlots: S,
|
|
3464
3469
|
emptySlotsDescription: g,
|
|
3465
|
-
onDateSelect:
|
|
3470
|
+
onDateSelect: l,
|
|
3466
3471
|
onWindowChange: h,
|
|
3467
3472
|
datePickerStyle: v,
|
|
3468
|
-
specialtyPickerStyle:
|
|
3469
|
-
servicePickerStyle:
|
|
3470
|
-
showServiceDuration:
|
|
3471
|
-
operatorPickerStyle:
|
|
3472
|
-
submitting:
|
|
3473
|
-
locale:
|
|
3474
|
-
detailsProps:
|
|
3475
|
-
agentIdBase:
|
|
3473
|
+
specialtyPickerStyle: m,
|
|
3474
|
+
servicePickerStyle: O,
|
|
3475
|
+
showServiceDuration: N,
|
|
3476
|
+
operatorPickerStyle: w,
|
|
3477
|
+
submitting: C,
|
|
3478
|
+
locale: M,
|
|
3479
|
+
detailsProps: D,
|
|
3480
|
+
agentIdBase: _,
|
|
3476
3481
|
activeStep: R
|
|
3477
3482
|
} = e, { t: $ } = Q("ui"), j = Ct(R, v), T = (k, L) => ({
|
|
3478
3483
|
step: k,
|
|
3479
3484
|
active: k === j,
|
|
3480
3485
|
className: L
|
|
3481
3486
|
});
|
|
3482
|
-
return /* @__PURE__ */
|
|
3487
|
+
return /* @__PURE__ */ b("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)]", children: [
|
|
3483
3488
|
t.gates.insurance ? /* @__PURE__ */ n(ce, { ...T(1), children: /* @__PURE__ */ n(
|
|
3484
|
-
|
|
3489
|
+
cr,
|
|
3485
3490
|
{
|
|
3486
3491
|
value: i.insuranceType,
|
|
3487
3492
|
onChange: (k) => s(jn(i, k))
|
|
3488
3493
|
}
|
|
3489
3494
|
) }) : null,
|
|
3490
3495
|
t.gates.specialty ? /* @__PURE__ */ n(ce, { ...T(2), children: /* @__PURE__ */ n(
|
|
3491
|
-
|
|
3496
|
+
dr,
|
|
3492
3497
|
{
|
|
3493
3498
|
specialties: t.filtered.specialties,
|
|
3494
3499
|
value: i.specialtyId,
|
|
3495
3500
|
valueIds: i.specialtyIds,
|
|
3496
3501
|
onChange: (k) => s(Un(i, k)),
|
|
3497
3502
|
onChangeIds: (k) => s(Hn(i, k)),
|
|
3498
|
-
pickerStyle:
|
|
3503
|
+
pickerStyle: m
|
|
3499
3504
|
}
|
|
3500
3505
|
) }) : null,
|
|
3501
|
-
t.gates.service ? /* @__PURE__ */ n(ce, { ...T(3), children: t.filtered.services.length === 0 ? /* @__PURE__ */ n(
|
|
3502
|
-
|
|
3506
|
+
t.gates.service ? /* @__PURE__ */ n(ce, { ...T(3), children: t.filtered.services.length === 0 ? /* @__PURE__ */ n(fr, { customSlot: o }) : /* @__PURE__ */ n(
|
|
3507
|
+
lr,
|
|
3503
3508
|
{
|
|
3504
3509
|
services: t.filtered.services,
|
|
3505
3510
|
value: i.serviceId,
|
|
3506
3511
|
valueIds: i.serviceIds,
|
|
3507
3512
|
onChange: (k) => s(Gn(i, k)),
|
|
3508
3513
|
onChangeIds: (k) => s(Jn(i, k)),
|
|
3509
|
-
pickerStyle:
|
|
3510
|
-
showDuration:
|
|
3514
|
+
pickerStyle: O,
|
|
3515
|
+
showDuration: N
|
|
3511
3516
|
}
|
|
3512
3517
|
) }) : null,
|
|
3513
|
-
t.gates.onboardingIncomplete ? /* @__PURE__ */ n(
|
|
3518
|
+
t.gates.onboardingIncomplete ? /* @__PURE__ */ n(mr, { customSlot: c }) : null,
|
|
3514
3519
|
t.gates.operator ? /* @__PURE__ */ n(ce, { ...T(4), children: /* @__PURE__ */ n(
|
|
3515
|
-
|
|
3520
|
+
ur,
|
|
3516
3521
|
{
|
|
3517
3522
|
operators: t.filtered.operators,
|
|
3518
3523
|
value: i.operatorId,
|
|
3519
3524
|
valueIds: i.operatorIds,
|
|
3520
3525
|
onChange: (k) => s(Wn(i, k)),
|
|
3521
3526
|
onChangeIds: (k) => s(Yn(i, k)),
|
|
3522
|
-
pickerStyle:
|
|
3527
|
+
pickerStyle: w
|
|
3523
3528
|
}
|
|
3524
3529
|
) }) : null,
|
|
3525
|
-
t.gates.date ? /* @__PURE__ */
|
|
3530
|
+
t.gates.date ? /* @__PURE__ */ b(
|
|
3526
3531
|
ce,
|
|
3527
3532
|
{
|
|
3528
3533
|
...T(5, "ds:flex ds:flex-col ds:gap-[var(--spacing-sm)]"),
|
|
3529
3534
|
children: [
|
|
3530
3535
|
/* @__PURE__ */ n("h3", { className: "type-label ds:font-[var(--font-weight-semibold)] ds:text-[var(--foreground)] ds:m-0", children: $("booking.date.heading") }),
|
|
3531
|
-
|
|
3536
|
+
or({
|
|
3532
3537
|
activeStep: R,
|
|
3533
3538
|
inputs: r,
|
|
3534
3539
|
value: i,
|
|
3535
3540
|
onChange: s,
|
|
3536
|
-
onDateSelect:
|
|
3541
|
+
onDateSelect: l,
|
|
3537
3542
|
onWindowChange: h,
|
|
3538
|
-
loadingDates:
|
|
3543
|
+
loadingDates: u,
|
|
3539
3544
|
loadingSlots: p,
|
|
3540
3545
|
slotLoadError: f,
|
|
3541
3546
|
onRetrySlots: S,
|
|
3542
3547
|
emptySlotsDescription: g,
|
|
3543
|
-
locale:
|
|
3548
|
+
locale: M,
|
|
3544
3549
|
datePickerStyle: v,
|
|
3545
|
-
agentIdBase:
|
|
3550
|
+
agentIdBase: _
|
|
3546
3551
|
})
|
|
3547
3552
|
]
|
|
3548
3553
|
}
|
|
3549
3554
|
) : null,
|
|
3550
|
-
t.gates.slot && i.date && v === "month-calendar" ? /* @__PURE__ */
|
|
3555
|
+
t.gates.slot && i.date && v === "month-calendar" ? /* @__PURE__ */ b(
|
|
3551
3556
|
ce,
|
|
3552
3557
|
{
|
|
3553
3558
|
...T(6, "ds:flex ds:flex-col ds:gap-[var(--spacing-sm)]"),
|
|
3554
3559
|
children: [
|
|
3555
3560
|
/* @__PURE__ */ n("h3", { className: "type-label ds:font-[var(--font-weight-semibold)] ds:text-[var(--foreground)] ds:m-0", children: $("booking.slot.heading") }),
|
|
3556
|
-
|
|
3561
|
+
ar({
|
|
3557
3562
|
activeStep: R,
|
|
3558
3563
|
inputs: r,
|
|
3559
3564
|
value: i,
|
|
3560
3565
|
onChange: s,
|
|
3561
|
-
loadingDates:
|
|
3566
|
+
loadingDates: u,
|
|
3562
3567
|
loadingSlots: p,
|
|
3563
3568
|
slotLoadError: f,
|
|
3564
3569
|
onRetrySlots: S,
|
|
3565
3570
|
emptySlotsDescription: g,
|
|
3566
|
-
locale:
|
|
3571
|
+
locale: M,
|
|
3567
3572
|
datePickerStyle: v
|
|
3568
3573
|
})
|
|
3569
3574
|
]
|
|
@@ -3572,11 +3577,11 @@ function ki(e) {
|
|
|
3572
3577
|
t.gates.details && t.selectedSlot ? /* @__PURE__ */ n(ce, { ...T(7), children: /* @__PURE__ */ n(
|
|
3573
3578
|
xn,
|
|
3574
3579
|
{
|
|
3575
|
-
...
|
|
3580
|
+
...D,
|
|
3576
3581
|
value: i.details ?? {},
|
|
3577
3582
|
onChange: (k) => s({ ...i, details: k }),
|
|
3578
3583
|
onSubmit: a,
|
|
3579
|
-
submitting:
|
|
3584
|
+
submitting: C,
|
|
3580
3585
|
defaultPhoneCountry: e.policy.country
|
|
3581
3586
|
}
|
|
3582
3587
|
) }) : null
|
|
@@ -3589,22 +3594,22 @@ function Fe(e, t, r = {}) {
|
|
|
3589
3594
|
inputs: a,
|
|
3590
3595
|
value: o,
|
|
3591
3596
|
onChange: c,
|
|
3592
|
-
onSubmit:
|
|
3597
|
+
onSubmit: u,
|
|
3593
3598
|
emptyServicesSlot: p,
|
|
3594
3599
|
onboardingIncompleteSlot: f,
|
|
3595
3600
|
loadingDates: S,
|
|
3596
3601
|
loadingSlots: g,
|
|
3597
|
-
slotLoadError:
|
|
3602
|
+
slotLoadError: l,
|
|
3598
3603
|
onRetrySlots: h,
|
|
3599
3604
|
emptySlotsDescription: v,
|
|
3600
|
-
onDateSelect:
|
|
3601
|
-
onWindowChange:
|
|
3602
|
-
datePickerStyle:
|
|
3603
|
-
specialtyPickerStyle:
|
|
3604
|
-
servicePickerStyle:
|
|
3605
|
-
showServiceDuration:
|
|
3606
|
-
operatorPickerStyle:
|
|
3607
|
-
submitting:
|
|
3605
|
+
onDateSelect: m,
|
|
3606
|
+
onWindowChange: O,
|
|
3607
|
+
datePickerStyle: N,
|
|
3608
|
+
specialtyPickerStyle: w,
|
|
3609
|
+
servicePickerStyle: C,
|
|
3610
|
+
showServiceDuration: M,
|
|
3611
|
+
operatorPickerStyle: D,
|
|
3612
|
+
submitting: _,
|
|
3608
3613
|
locale: R,
|
|
3609
3614
|
detailsProps: $,
|
|
3610
3615
|
policy: j,
|
|
@@ -3613,7 +3618,7 @@ function Fe(e, t, r = {}) {
|
|
|
3613
3618
|
switch (e) {
|
|
3614
3619
|
case 1:
|
|
3615
3620
|
return /* @__PURE__ */ n(
|
|
3616
|
-
|
|
3621
|
+
cr,
|
|
3617
3622
|
{
|
|
3618
3623
|
value: o.insuranceType,
|
|
3619
3624
|
onChange: (k) => c(jn(o, k))
|
|
@@ -3621,72 +3626,72 @@ function Fe(e, t, r = {}) {
|
|
|
3621
3626
|
);
|
|
3622
3627
|
case 2:
|
|
3623
3628
|
return /* @__PURE__ */ n(
|
|
3624
|
-
|
|
3629
|
+
dr,
|
|
3625
3630
|
{
|
|
3626
3631
|
specialties: s.filtered.specialties,
|
|
3627
3632
|
value: o.specialtyId,
|
|
3628
3633
|
valueIds: o.specialtyIds,
|
|
3629
3634
|
onChange: (k) => c(Un(o, k)),
|
|
3630
3635
|
onChangeIds: (k) => c(Hn(o, k)),
|
|
3631
|
-
pickerStyle:
|
|
3636
|
+
pickerStyle: w
|
|
3632
3637
|
}
|
|
3633
3638
|
);
|
|
3634
3639
|
case 3:
|
|
3635
|
-
return s.filtered.services.length === 0 ? /* @__PURE__ */ n(
|
|
3636
|
-
|
|
3640
|
+
return s.filtered.services.length === 0 ? /* @__PURE__ */ n(fr, { customSlot: p }) : s.gates.onboardingIncomplete ? /* @__PURE__ */ n(mr, { customSlot: f }) : /* @__PURE__ */ n(
|
|
3641
|
+
lr,
|
|
3637
3642
|
{
|
|
3638
3643
|
services: s.filtered.services,
|
|
3639
3644
|
value: o.serviceId,
|
|
3640
3645
|
valueIds: o.serviceIds,
|
|
3641
3646
|
onChange: (k) => c(Gn(o, k)),
|
|
3642
3647
|
onChangeIds: (k) => c(Jn(o, k)),
|
|
3643
|
-
pickerStyle:
|
|
3648
|
+
pickerStyle: C,
|
|
3644
3649
|
compact: r.compactService,
|
|
3645
|
-
showDuration:
|
|
3650
|
+
showDuration: M
|
|
3646
3651
|
}
|
|
3647
3652
|
);
|
|
3648
3653
|
case 4:
|
|
3649
3654
|
return /* @__PURE__ */ n(
|
|
3650
|
-
|
|
3655
|
+
ur,
|
|
3651
3656
|
{
|
|
3652
3657
|
operators: s.filtered.operators,
|
|
3653
3658
|
value: o.operatorId,
|
|
3654
3659
|
valueIds: o.operatorIds,
|
|
3655
3660
|
onChange: (k) => c(Wn(o, k)),
|
|
3656
3661
|
onChangeIds: (k) => c(Yn(o, k)),
|
|
3657
|
-
pickerStyle:
|
|
3662
|
+
pickerStyle: D
|
|
3658
3663
|
}
|
|
3659
3664
|
);
|
|
3660
3665
|
case 5:
|
|
3661
|
-
return
|
|
3666
|
+
return or({
|
|
3662
3667
|
activeStep: i,
|
|
3663
3668
|
inputs: a,
|
|
3664
3669
|
value: o,
|
|
3665
3670
|
onChange: c,
|
|
3666
|
-
onDateSelect:
|
|
3667
|
-
onWindowChange:
|
|
3671
|
+
onDateSelect: m,
|
|
3672
|
+
onWindowChange: O,
|
|
3668
3673
|
loadingDates: S,
|
|
3669
3674
|
loadingSlots: g,
|
|
3670
|
-
slotLoadError:
|
|
3675
|
+
slotLoadError: l,
|
|
3671
3676
|
onRetrySlots: h,
|
|
3672
3677
|
emptySlotsDescription: v,
|
|
3673
3678
|
locale: R,
|
|
3674
|
-
datePickerStyle:
|
|
3679
|
+
datePickerStyle: N,
|
|
3675
3680
|
agentIdBase: T
|
|
3676
3681
|
});
|
|
3677
3682
|
case 6:
|
|
3678
|
-
return
|
|
3683
|
+
return ar({
|
|
3679
3684
|
activeStep: i,
|
|
3680
3685
|
inputs: a,
|
|
3681
3686
|
value: o,
|
|
3682
3687
|
onChange: c,
|
|
3683
3688
|
loadingDates: S,
|
|
3684
3689
|
loadingSlots: g,
|
|
3685
|
-
slotLoadError:
|
|
3690
|
+
slotLoadError: l,
|
|
3686
3691
|
onRetrySlots: h,
|
|
3687
3692
|
emptySlotsDescription: v,
|
|
3688
3693
|
locale: R,
|
|
3689
|
-
datePickerStyle:
|
|
3694
|
+
datePickerStyle: N
|
|
3690
3695
|
});
|
|
3691
3696
|
case 7:
|
|
3692
3697
|
return s.selectedSlot ? /* @__PURE__ */ n(
|
|
@@ -3695,8 +3700,8 @@ function Fe(e, t, r = {}) {
|
|
|
3695
3700
|
...$,
|
|
3696
3701
|
value: o.details ?? {},
|
|
3697
3702
|
onChange: (k) => c({ ...o, details: k }),
|
|
3698
|
-
onSubmit:
|
|
3699
|
-
submitting:
|
|
3703
|
+
onSubmit: u,
|
|
3704
|
+
submitting: _,
|
|
3700
3705
|
defaultPhoneCountry: j.country
|
|
3701
3706
|
}
|
|
3702
3707
|
) : null;
|
|
@@ -3724,15 +3729,15 @@ function Ct(e, t) {
|
|
|
3724
3729
|
return t === "four-day-grid" && e === 6 ? 5 : e;
|
|
3725
3730
|
}
|
|
3726
3731
|
function Si(e) {
|
|
3727
|
-
const { cascade: t, value: r, activeStep: i, setActiveStep: s, datePickerStyle: a } = e, o = cn(), { t: c } = Q("ui"),
|
|
3732
|
+
const { cascade: t, value: r, activeStep: i, setActiveStep: s, datePickerStyle: a } = e, o = cn(), { t: c } = Q("ui"), u = c("booking.operator.all"), p = K(
|
|
3728
3733
|
() => Nn(t.visibleSteps, a),
|
|
3729
3734
|
[t.visibleSteps, a]
|
|
3730
3735
|
), f = Ct(i, a), S = Math.max(0, p.indexOf(f)), g = K(
|
|
3731
|
-
() => p.map((
|
|
3732
|
-
label: o[
|
|
3733
|
-
summary:
|
|
3734
|
-
status: xi(
|
|
3735
|
-
content: /* @__PURE__ */ n(ce, { step:
|
|
3736
|
+
() => p.map((l) => ({
|
|
3737
|
+
label: o[l],
|
|
3738
|
+
summary: hr(l, r, t, u),
|
|
3739
|
+
status: xi(l, r, t),
|
|
3740
|
+
content: /* @__PURE__ */ n(ce, { step: l, active: l === f, children: Fe(l, e, { compactService: !0 }) })
|
|
3736
3741
|
})),
|
|
3737
3742
|
[
|
|
3738
3743
|
p,
|
|
@@ -3741,16 +3746,16 @@ function Si(e) {
|
|
|
3741
3746
|
t,
|
|
3742
3747
|
e,
|
|
3743
3748
|
f,
|
|
3744
|
-
|
|
3749
|
+
u
|
|
3745
3750
|
]
|
|
3746
3751
|
);
|
|
3747
3752
|
return /* @__PURE__ */ n(
|
|
3748
|
-
|
|
3753
|
+
Er,
|
|
3749
3754
|
{
|
|
3750
3755
|
activeStep: S,
|
|
3751
3756
|
steps: g,
|
|
3752
|
-
onStepChange: (
|
|
3753
|
-
const h = p[
|
|
3757
|
+
onStepChange: (l) => {
|
|
3758
|
+
const h = p[l];
|
|
3754
3759
|
h && s(h);
|
|
3755
3760
|
}
|
|
3756
3761
|
}
|
|
@@ -3769,7 +3774,7 @@ function pn(e, t) {
|
|
|
3769
3774
|
}).filter((i) => i !== void 0);
|
|
3770
3775
|
return r.length > 0 ? r.join(", ") : void 0;
|
|
3771
3776
|
}
|
|
3772
|
-
function
|
|
3777
|
+
function hr(e, t, r, i) {
|
|
3773
3778
|
var s;
|
|
3774
3779
|
if (We(e, t))
|
|
3775
3780
|
switch (e) {
|
|
@@ -3783,11 +3788,11 @@ function fr(e, t, r, i) {
|
|
|
3783
3788
|
case 3:
|
|
3784
3789
|
return pn(Ye(t), r.filtered.services);
|
|
3785
3790
|
case 4: {
|
|
3786
|
-
const o = gn(t).filter((
|
|
3791
|
+
const o = gn(t).filter((u) => u !== qe), c = pn(
|
|
3787
3792
|
o,
|
|
3788
|
-
r.filtered.operators.map((
|
|
3789
|
-
id:
|
|
3790
|
-
label:
|
|
3793
|
+
r.filtered.operators.map((u) => ({
|
|
3794
|
+
id: u.id,
|
|
3795
|
+
label: u.name
|
|
3791
3796
|
}))
|
|
3792
3797
|
);
|
|
3793
3798
|
return c !== void 0 ? c : o.length === 0 ? i : void 0;
|
|
@@ -3801,52 +3806,52 @@ function fr(e, t, r, i) {
|
|
|
3801
3806
|
}
|
|
3802
3807
|
}
|
|
3803
3808
|
function Ii(e) {
|
|
3804
|
-
const { cascade: t, value: r, activeStep: i, setActiveStep: s } = e, { t: a } = Q("ui"), o = cn(), c = a("booking.operator.all"),
|
|
3805
|
-
(
|
|
3809
|
+
const { cascade: t, value: r, activeStep: i, setActiveStep: s } = e, { t: a } = Q("ui"), o = cn(), c = a("booking.operator.all"), u = `${pt()}-filter`, p = Ct(i, e.datePickerStyle), f = t.visibleSteps.filter(
|
|
3810
|
+
(l) => l === 1 || l === 2 || l === 3 || l === 4
|
|
3806
3811
|
), S = f.some(
|
|
3807
|
-
(
|
|
3812
|
+
(l) => !We(l, r)
|
|
3808
3813
|
), g = f.some(
|
|
3809
|
-
(
|
|
3810
|
-
) ? i : f.find((
|
|
3811
|
-
return /* @__PURE__ */
|
|
3814
|
+
(l) => l === i
|
|
3815
|
+
) ? i : f.find((l) => !We(l, r));
|
|
3816
|
+
return /* @__PURE__ */ b("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)]", children: [
|
|
3812
3817
|
f.length > 0 ? /* @__PURE__ */ n(
|
|
3813
3818
|
"div",
|
|
3814
3819
|
{
|
|
3815
3820
|
role: "group",
|
|
3816
3821
|
"aria-label": a("booking.filtersLabel"),
|
|
3817
3822
|
className: "ds:flex ds:flex-wrap ds:items-center ds:gap-[var(--spacing-xs)]",
|
|
3818
|
-
children: f.map((
|
|
3819
|
-
const h =
|
|
3820
|
-
|
|
3823
|
+
children: f.map((l) => {
|
|
3824
|
+
const h = hr(
|
|
3825
|
+
l,
|
|
3821
3826
|
r,
|
|
3822
3827
|
t,
|
|
3823
3828
|
c
|
|
3824
|
-
), v =
|
|
3829
|
+
), v = l === g, m = We(l, r);
|
|
3825
3830
|
return /* @__PURE__ */ n(
|
|
3826
3831
|
Re,
|
|
3827
3832
|
{
|
|
3828
3833
|
intent: v ? "primary" : "outline",
|
|
3829
3834
|
size: "sm",
|
|
3830
3835
|
endIcon: /* @__PURE__ */ n(
|
|
3831
|
-
|
|
3836
|
+
Br,
|
|
3832
3837
|
{
|
|
3833
3838
|
"aria-hidden": "true",
|
|
3834
3839
|
className: v ? "ds:rotate-180" : void 0
|
|
3835
3840
|
}
|
|
3836
3841
|
),
|
|
3837
|
-
"aria-expanded":
|
|
3838
|
-
"aria-controls":
|
|
3839
|
-
"aria-current": !
|
|
3842
|
+
"aria-expanded": m ? v : void 0,
|
|
3843
|
+
"aria-controls": m && v ? u : void 0,
|
|
3844
|
+
"aria-current": !m && v ? "step" : void 0,
|
|
3840
3845
|
onClick: () => s(
|
|
3841
|
-
|
|
3846
|
+
m && v ? t.currentStep : l
|
|
3842
3847
|
),
|
|
3843
|
-
children: h ? /* @__PURE__ */
|
|
3844
|
-
o[
|
|
3848
|
+
children: h ? /* @__PURE__ */ b(de, { children: [
|
|
3849
|
+
o[l],
|
|
3845
3850
|
": ",
|
|
3846
3851
|
h
|
|
3847
|
-
] }) : o[
|
|
3852
|
+
] }) : o[l]
|
|
3848
3853
|
},
|
|
3849
|
-
`csc-${
|
|
3854
|
+
`csc-${l}`
|
|
3850
3855
|
);
|
|
3851
3856
|
})
|
|
3852
3857
|
}
|
|
@@ -3856,7 +3861,7 @@ function Ii(e) {
|
|
|
3856
3861
|
{
|
|
3857
3862
|
step: g,
|
|
3858
3863
|
active: g === p,
|
|
3859
|
-
id:
|
|
3864
|
+
id: u,
|
|
3860
3865
|
children: Fe(g, e, { compactService: !0 })
|
|
3861
3866
|
}
|
|
3862
3867
|
) : null,
|
|
@@ -3865,7 +3870,7 @@ function Ii(e) {
|
|
|
3865
3870
|
// historic 2-col date|slot split collapses to a single column
|
|
3866
3871
|
// so the picker spans the full width instead of orphaning an
|
|
3867
3872
|
// empty right cell.
|
|
3868
|
-
e.datePickerStyle === "four-day-grid" ? /* @__PURE__ */ n(ce, { step: 5, active: p === 5, children: Fe(5, e) }) : /* @__PURE__ */
|
|
3873
|
+
e.datePickerStyle === "four-day-grid" ? /* @__PURE__ */ n(ce, { step: 5, active: p === 5, children: Fe(5, e) }) : /* @__PURE__ */ b("div", { className: "ds:grid ds:grid-cols-1 ds:gap-[var(--spacing-md)] ds:md:grid-cols-2", children: [
|
|
3869
3874
|
/* @__PURE__ */ n(
|
|
3870
3875
|
ce,
|
|
3871
3876
|
{
|
|
@@ -3893,14 +3898,14 @@ function Ni(e) {
|
|
|
3893
3898
|
const { cascade: t, datePickerStyle: r, activeStep: i } = e, s = Ct(i, r), a = t.visibleSteps.filter(
|
|
3894
3899
|
(c) => c === 1 || c === 2 || c === 3 || c === 4
|
|
3895
3900
|
);
|
|
3896
|
-
return /* @__PURE__ */
|
|
3897
|
-
/* @__PURE__ */
|
|
3901
|
+
return /* @__PURE__ */ b("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)]", children: [
|
|
3902
|
+
/* @__PURE__ */ b(
|
|
3898
3903
|
"div",
|
|
3899
3904
|
{
|
|
3900
3905
|
className: r === "four-day-grid" ? "ds:flex ds:flex-col ds:gap-[var(--spacing-md)]" : "ds:grid ds:grid-cols-1 ds:gap-[var(--spacing-md)] ds:md:grid-cols-2",
|
|
3901
3906
|
children: [
|
|
3902
3907
|
/* @__PURE__ */ n("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)]", children: a.map((c) => /* @__PURE__ */ n(ce, { step: c, active: c === s, children: Fe(c, e, { compactService: !0 }) }, `fbf-${c}`)) }),
|
|
3903
|
-
/* @__PURE__ */
|
|
3908
|
+
/* @__PURE__ */ b("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)]", children: [
|
|
3904
3909
|
t.gates.date ? /* @__PURE__ */ n(ce, { step: 5, active: s === 5, children: Fe(5, e) }) : null,
|
|
3905
3910
|
t.gates.slot && e.value.date && r === "month-calendar" ? /* @__PURE__ */ n(ce, { step: 6, active: s === 6, children: Fe(6, e) }) : null
|
|
3906
3911
|
] })
|
|
@@ -3911,26 +3916,26 @@ function Ni(e) {
|
|
|
3911
3916
|
] });
|
|
3912
3917
|
}
|
|
3913
3918
|
function wi(e) {
|
|
3914
|
-
const { cascade: t, value: r, activeStep: i, setActiveStep: s, datePickerStyle: a } = e, { t: o } = Q("ui"), c = cn(),
|
|
3919
|
+
const { cascade: t, value: r, activeStep: i, setActiveStep: s, datePickerStyle: a } = e, { t: o } = Q("ui"), c = cn(), u = K(
|
|
3915
3920
|
() => Nn(t.visibleSteps, a),
|
|
3916
3921
|
[t.visibleSteps, a]
|
|
3917
|
-
), p = Ct(i, a), f = Math.max(0,
|
|
3918
|
-
() =>
|
|
3919
|
-
[
|
|
3920
|
-
),
|
|
3921
|
-
return /* @__PURE__ */
|
|
3922
|
-
/* @__PURE__ */ n(
|
|
3922
|
+
), p = Ct(i, a), f = Math.max(0, u.indexOf(p)), S = u.length, g = K(
|
|
3923
|
+
() => u.map((m) => ({ label: c[m] })),
|
|
3924
|
+
[u, c]
|
|
3925
|
+
), l = f > 0, h = p === 5 && a === "four-day-grid", v = f < S - 1 && u[f + 1] <= t.currentStep && We(p, r) && (!h || We(6, r));
|
|
3926
|
+
return /* @__PURE__ */ b("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)]", children: [
|
|
3927
|
+
/* @__PURE__ */ n(Fr, { activeStep: f, steps: g }),
|
|
3923
3928
|
/* @__PURE__ */ n(ce, { step: p, active: !0, children: Fe(p, e, { compactService: !0 }) }),
|
|
3924
|
-
/* @__PURE__ */
|
|
3929
|
+
/* @__PURE__ */ b("div", { className: "ds:flex ds:flex-wrap ds:items-center ds:justify-between ds:gap-[var(--spacing-sm)]", children: [
|
|
3925
3930
|
/* @__PURE__ */ n(
|
|
3926
3931
|
Re,
|
|
3927
3932
|
{
|
|
3928
3933
|
intent: "ghost",
|
|
3929
3934
|
size: "md",
|
|
3930
|
-
disabled: !
|
|
3935
|
+
disabled: !l,
|
|
3931
3936
|
onClick: () => {
|
|
3932
|
-
const
|
|
3933
|
-
|
|
3937
|
+
const m = u[f - 1];
|
|
3938
|
+
m && s(m);
|
|
3934
3939
|
},
|
|
3935
3940
|
children: o("booking.actions.back")
|
|
3936
3941
|
}
|
|
@@ -3942,8 +3947,8 @@ function wi(e) {
|
|
|
3942
3947
|
size: "md",
|
|
3943
3948
|
disabled: !v,
|
|
3944
3949
|
onClick: () => {
|
|
3945
|
-
const
|
|
3946
|
-
|
|
3950
|
+
const m = u[f + 1];
|
|
3951
|
+
m && s(m);
|
|
3947
3952
|
},
|
|
3948
3953
|
children: o("booking.actions.next")
|
|
3949
3954
|
}
|
|
@@ -3968,35 +3973,35 @@ const Mi = Vn(
|
|
|
3968
3973
|
operatorsByService: a = !1,
|
|
3969
3974
|
autoSelectSingleService: o = !1,
|
|
3970
3975
|
specialties: c,
|
|
3971
|
-
services:
|
|
3976
|
+
services: u,
|
|
3972
3977
|
operators: p,
|
|
3973
3978
|
availableDates: f,
|
|
3974
3979
|
availableSlots: S,
|
|
3975
3980
|
nextAvailableDate: g,
|
|
3976
|
-
hideEmail:
|
|
3981
|
+
hideEmail: l = !1,
|
|
3977
3982
|
emailOptional: h = !1,
|
|
3978
3983
|
requireCodiceFiscale: v,
|
|
3979
|
-
requireDateOfBirth:
|
|
3980
|
-
requireInsuranceNumber:
|
|
3981
|
-
billingInDetails:
|
|
3982
|
-
paymentNoticeStyle:
|
|
3983
|
-
showNote:
|
|
3984
|
-
showReturningPatientFlag:
|
|
3985
|
-
privacyPolicyUrl:
|
|
3986
|
-
termsUrl:
|
|
3984
|
+
requireDateOfBirth: m,
|
|
3985
|
+
requireInsuranceNumber: O,
|
|
3986
|
+
billingInDetails: N = !1,
|
|
3987
|
+
paymentNoticeStyle: w = "highlighted",
|
|
3988
|
+
showNote: C,
|
|
3989
|
+
showReturningPatientFlag: M,
|
|
3990
|
+
privacyPolicyUrl: D,
|
|
3991
|
+
termsUrl: _,
|
|
3987
3992
|
practiceConsent: R,
|
|
3988
3993
|
paymentTermsUrl: $,
|
|
3989
3994
|
paymentState: j,
|
|
3990
3995
|
handoverDelayMs: T,
|
|
3991
3996
|
onNavigate: k,
|
|
3992
3997
|
renderPayment: L,
|
|
3993
|
-
renderPaymentCompletion:
|
|
3994
|
-
validateCodiceFiscale:
|
|
3998
|
+
renderPaymentCompletion: F,
|
|
3999
|
+
validateCodiceFiscale: y,
|
|
3995
4000
|
validateInsuranceNumber: W,
|
|
3996
4001
|
confirmationChannels: ne,
|
|
3997
4002
|
defaultConfirmationChannels: Ne,
|
|
3998
4003
|
singleConfirmationChannel: ge,
|
|
3999
|
-
value:
|
|
4004
|
+
value: I,
|
|
4000
4005
|
onChange: q,
|
|
4001
4006
|
onSubmit: Y,
|
|
4002
4007
|
codeStep: U,
|
|
@@ -4028,22 +4033,22 @@ const Mi = Vn(
|
|
|
4028
4033
|
...$t
|
|
4029
4034
|
}, qt) => {
|
|
4030
4035
|
var wn, Cn, Tn;
|
|
4031
|
-
const { t:
|
|
4036
|
+
const { t: le, i18n: ht } = Q("ui"), Se = e ?? "inline-list", Ee = ht.language ?? "en", pe = c ?? Ci, at = p ?? Ti;
|
|
4032
4037
|
V(() => {
|
|
4033
|
-
const x =
|
|
4038
|
+
const x = Cs(I, {
|
|
4034
4039
|
useSpecialties: r,
|
|
4035
4040
|
lockedOperatorId: s,
|
|
4036
4041
|
autoSelectSingleService: o,
|
|
4037
4042
|
specialties: pe,
|
|
4038
|
-
services:
|
|
4043
|
+
services: u
|
|
4039
4044
|
});
|
|
4040
|
-
(x.specialtyId !==
|
|
4045
|
+
(x.specialtyId !== I.specialtyId || x.operatorId !== I.operatorId || x.serviceId !== I.serviceId) && q(x);
|
|
4041
4046
|
}, [
|
|
4042
4047
|
s,
|
|
4043
4048
|
r,
|
|
4044
4049
|
o,
|
|
4045
4050
|
pe,
|
|
4046
|
-
|
|
4051
|
+
u
|
|
4047
4052
|
]);
|
|
4048
4053
|
const [vt, ct] = J(!1), je = A(!1), bt = !!(ke || oe);
|
|
4049
4054
|
V(() => {
|
|
@@ -4061,17 +4066,17 @@ const Mi = Vn(
|
|
|
4061
4066
|
} : void 0,
|
|
4062
4067
|
[se]
|
|
4063
4068
|
), Pe = !!(ae || vt && bt), z = K(
|
|
4064
|
-
() =>
|
|
4069
|
+
() => ws({
|
|
4065
4070
|
country: t,
|
|
4066
4071
|
useSpecialties: r,
|
|
4067
4072
|
allowOperatorSelection: i,
|
|
4068
4073
|
lockedOperatorId: s,
|
|
4069
4074
|
operatorsByService: a,
|
|
4070
4075
|
specialties: pe,
|
|
4071
|
-
services:
|
|
4076
|
+
services: u,
|
|
4072
4077
|
operators: at,
|
|
4073
4078
|
availableSlots: S,
|
|
4074
|
-
value: Pe ? { ...
|
|
4079
|
+
value: Pe ? { ...I, slotKey: void 0 } : I
|
|
4075
4080
|
}),
|
|
4076
4081
|
[
|
|
4077
4082
|
t,
|
|
@@ -4081,34 +4086,34 @@ const Mi = Vn(
|
|
|
4081
4086
|
a,
|
|
4082
4087
|
o,
|
|
4083
4088
|
pe,
|
|
4084
|
-
|
|
4089
|
+
u,
|
|
4085
4090
|
at,
|
|
4086
4091
|
f,
|
|
4087
4092
|
S,
|
|
4088
|
-
|
|
4093
|
+
I,
|
|
4089
4094
|
Pe
|
|
4090
4095
|
]
|
|
4091
4096
|
), Ve = K(
|
|
4092
4097
|
() => [
|
|
4093
|
-
JSON.stringify(
|
|
4094
|
-
JSON.stringify(st(
|
|
4095
|
-
JSON.stringify(Ye(
|
|
4096
|
-
JSON.stringify(gn(
|
|
4097
|
-
JSON.stringify(
|
|
4098
|
-
JSON.stringify(
|
|
4098
|
+
JSON.stringify(I.insuranceType),
|
|
4099
|
+
JSON.stringify(st(I)),
|
|
4100
|
+
JSON.stringify(Ye(I)),
|
|
4101
|
+
JSON.stringify(gn(I)),
|
|
4102
|
+
JSON.stringify(I.date),
|
|
4103
|
+
JSON.stringify(I.slotKey)
|
|
4099
4104
|
],
|
|
4100
|
-
[
|
|
4105
|
+
[I]
|
|
4101
4106
|
), yt = Se === "progress", Ce = Me(
|
|
4102
4107
|
(x) => {
|
|
4103
|
-
if (x === 4 && z.visibleSteps.includes(4) && gn(
|
|
4108
|
+
if (x === 4 && z.visibleSteps.includes(4) && gn(I).length === 0)
|
|
4104
4109
|
return Math.min(4, z.currentStep);
|
|
4105
4110
|
if (!yt) return z.currentStep;
|
|
4106
|
-
const
|
|
4107
|
-
(P) => P > x && !Pn(P,
|
|
4111
|
+
const B = z.visibleSteps.find(
|
|
4112
|
+
(P) => P > x && !Pn(P, I)
|
|
4108
4113
|
);
|
|
4109
|
-
return
|
|
4114
|
+
return B === void 0 ? z.currentStep : Math.min(B, z.currentStep);
|
|
4110
4115
|
},
|
|
4111
|
-
[yt, z.visibleSteps, z.currentStep,
|
|
4116
|
+
[yt, z.visibleSteps, z.currentStep, I]
|
|
4112
4117
|
), [ee, xe] = J(
|
|
4113
4118
|
z.currentStep
|
|
4114
4119
|
), kt = A(null);
|
|
@@ -4127,7 +4132,7 @@ const Mi = Vn(
|
|
|
4127
4132
|
}, [Pe, ee, z.currentStep]);
|
|
4128
4133
|
const Ue = A(Ve), St = A(z.visibleSteps);
|
|
4129
4134
|
V(() => {
|
|
4130
|
-
const x = Ue.current,
|
|
4135
|
+
const x = Ue.current, B = St.current;
|
|
4131
4136
|
Ue.current = Ve, St.current = z.visibleSteps;
|
|
4132
4137
|
const P = Ve.findIndex(
|
|
4133
4138
|
(Ie, An) => Ie !== x[An]
|
|
@@ -4136,11 +4141,11 @@ const Mi = Vn(
|
|
|
4136
4141
|
xe(Ce(P + 1));
|
|
4137
4142
|
return;
|
|
4138
4143
|
}
|
|
4139
|
-
const
|
|
4140
|
-
(Ie) => Ie < ee && !
|
|
4144
|
+
const me = yt ? z.visibleSteps.find(
|
|
4145
|
+
(Ie) => Ie < ee && !B.includes(Ie) && !Pn(Ie, I)
|
|
4141
4146
|
) : void 0;
|
|
4142
|
-
if (
|
|
4143
|
-
xe(
|
|
4147
|
+
if (me !== void 0) {
|
|
4148
|
+
xe(me);
|
|
4144
4149
|
return;
|
|
4145
4150
|
}
|
|
4146
4151
|
z.visibleSteps.includes(ee) || xe(z.currentStep);
|
|
@@ -4151,18 +4156,18 @@ const Mi = Vn(
|
|
|
4151
4156
|
z.currentStep,
|
|
4152
4157
|
z.visibleSteps,
|
|
4153
4158
|
ee,
|
|
4154
|
-
|
|
4159
|
+
I
|
|
4155
4160
|
]);
|
|
4156
4161
|
const Te = A(null), dt = K(
|
|
4157
4162
|
() => Nn(z.visibleSteps, ve),
|
|
4158
4163
|
[z.visibleSteps, ve]
|
|
4159
4164
|
), Mt = cn(), [zt, Kt] = J(""), He = A(null), $e = A(null);
|
|
4160
4165
|
_t(() => {
|
|
4161
|
-
const x = He.current,
|
|
4162
|
-
if (!
|
|
4166
|
+
const x = He.current, B = Te.current;
|
|
4167
|
+
if (!B || !x || x.isConnected || document.activeElement !== document.body)
|
|
4163
4168
|
return;
|
|
4164
|
-
const P =
|
|
4165
|
-
((ae && !ke && !oe ?
|
|
4169
|
+
const P = B.querySelector(Ln);
|
|
4170
|
+
((ae && !ke && !oe ? B.querySelector("[data-slot-retry]") : null) ?? (P == null ? void 0 : P.querySelector("[data-slot-load-state]")) ?? P ?? B).focus({ preventScroll: !0 });
|
|
4166
4171
|
}, [ae, ke, oe]), V(() => {
|
|
4167
4172
|
const x = Ct(ee, ve);
|
|
4168
4173
|
if ($e.current === null) {
|
|
@@ -4171,21 +4176,21 @@ const Mi = Vn(
|
|
|
4171
4176
|
}
|
|
4172
4177
|
if ($e.current === x) return;
|
|
4173
4178
|
$e.current = x;
|
|
4174
|
-
const
|
|
4179
|
+
const B = dt.indexOf(x);
|
|
4175
4180
|
Kt(
|
|
4176
|
-
|
|
4177
|
-
current:
|
|
4181
|
+
B === -1 ? "" : le("booking.stepAnnouncement", {
|
|
4182
|
+
current: B + 1,
|
|
4178
4183
|
total: dt.length,
|
|
4179
4184
|
label: Mt[x]
|
|
4180
4185
|
})
|
|
4181
4186
|
);
|
|
4182
4187
|
const P = He.current;
|
|
4183
4188
|
if (!P || P.isConnected) return;
|
|
4184
|
-
const
|
|
4185
|
-
if (!
|
|
4189
|
+
const me = Te.current;
|
|
4190
|
+
if (!me) return;
|
|
4186
4191
|
const Ie = document.activeElement;
|
|
4187
|
-
if (!(Ie === null || Ie === document.body || !
|
|
4188
|
-
const Wt =
|
|
4192
|
+
if (!(Ie === null || Ie === document.body || !me.contains(Ie))) return;
|
|
4193
|
+
const Wt = me.querySelector(Ln) ?? me;
|
|
4189
4194
|
if (Wt.focus({ preventScroll: !0 }), typeof Wt.scrollIntoView == "function")
|
|
4190
4195
|
try {
|
|
4191
4196
|
Wt.scrollIntoView({
|
|
@@ -4195,10 +4200,10 @@ const Mi = Vn(
|
|
|
4195
4200
|
} catch {
|
|
4196
4201
|
Wt.scrollIntoView();
|
|
4197
4202
|
}
|
|
4198
|
-
}, [ee, ve, dt, Mt,
|
|
4199
|
-
const G =
|
|
4200
|
-
services:
|
|
4201
|
-
value:
|
|
4203
|
+
}, [ee, ve, dt, Mt, le]);
|
|
4204
|
+
const G = Zs({
|
|
4205
|
+
services: u,
|
|
4206
|
+
value: I,
|
|
4202
4207
|
availableSlots: S,
|
|
4203
4208
|
onSubmit: Y,
|
|
4204
4209
|
onChange: q,
|
|
@@ -4211,42 +4216,42 @@ const Mi = Vn(
|
|
|
4211
4216
|
Qe.current = G.reset;
|
|
4212
4217
|
const xt = A(!1), [dn, ln] = J(!1);
|
|
4213
4218
|
V(() => {
|
|
4214
|
-
var
|
|
4219
|
+
var B, P;
|
|
4215
4220
|
if (!xt.current || H !== "idle") return;
|
|
4216
4221
|
xt.current = !1;
|
|
4217
|
-
const x = (
|
|
4222
|
+
const x = (B = Te.current) == null ? void 0 : B.querySelector(
|
|
4218
4223
|
'form input:not([type="hidden"]):not([data-honeypot]):not(:disabled), form select:not(:disabled), form textarea:not(:disabled)'
|
|
4219
4224
|
);
|
|
4220
4225
|
x && (x.focus({ preventScroll: !0 }), (P = x.scrollIntoView) == null || P.call(x, { block: "nearest" }));
|
|
4221
4226
|
}, [H]);
|
|
4222
4227
|
const Ut = pt(), Ht = A(null), lt = A(null), Rt = ((wn = G.state) == null ? void 0 : wn.status) === "failed", Ot = G.state && "phase" in G.state && G.state.phase === "completion";
|
|
4223
4228
|
V(() => {
|
|
4224
|
-
var x,
|
|
4229
|
+
var x, B;
|
|
4225
4230
|
if (H === "payment") {
|
|
4226
4231
|
const P = document.activeElement;
|
|
4227
|
-
(!Ot || !P || P === document.body || !((x = Te.current) != null && x.contains(P))) && ((
|
|
4232
|
+
(!Ot || !P || P === document.body || !((x = Te.current) != null && x.contains(P))) && ((B = Ht.current) == null || B.focus());
|
|
4228
4233
|
}
|
|
4229
4234
|
}, [H, Ot]), V(() => {
|
|
4230
4235
|
var x;
|
|
4231
4236
|
H === "payment" && Rt && ((x = lt.current) == null || x.focus());
|
|
4232
|
-
}, [H, Rt]),
|
|
4233
|
-
const te = H === "success" ? 8 : H === "payment" || H === "code" ? 7 : z.currentStep, Dt = A(null),
|
|
4237
|
+
}, [H, Rt]), br(qt, () => Te.current, []);
|
|
4238
|
+
const te = H === "success" ? 8 : H === "payment" || H === "code" ? 7 : z.currentStep, Dt = A(null), ue = A(0);
|
|
4234
4239
|
_t(() => {
|
|
4235
4240
|
var x;
|
|
4236
|
-
(H === "submitting" || H === "code" || H === "payment") && (
|
|
4241
|
+
(H === "submitting" || H === "code" || H === "payment") && (ue.current = ((x = Te.current) == null ? void 0 : x.offsetHeight) ?? 0);
|
|
4237
4242
|
}), _t(() => {
|
|
4238
4243
|
const x = Te.current;
|
|
4239
|
-
te !== 8 || !x ||
|
|
4244
|
+
te !== 8 || !x || ue.current === 0 || (x.style.setProperty(
|
|
4240
4245
|
"--booking-held-height",
|
|
4241
|
-
`${
|
|
4242
|
-
),
|
|
4246
|
+
`${ue.current}px`
|
|
4247
|
+
), ue.current = 0);
|
|
4243
4248
|
}, [te]), V(() => {
|
|
4244
4249
|
if (te === Dt.current) return;
|
|
4245
4250
|
Dt.current = te, ze == null || ze(te);
|
|
4246
4251
|
const x = Te.current;
|
|
4247
4252
|
if (te !== 8 || !x) return;
|
|
4248
|
-
const
|
|
4249
|
-
tr(x, "start") ?
|
|
4253
|
+
const B = () => x.style.removeProperty("--booking-held-height");
|
|
4254
|
+
tr(x, "start") ? Gs(B) : B();
|
|
4250
4255
|
}, [te, ze]);
|
|
4251
4256
|
const et = A({ activeStep: ee, cascade: z, submitState: H });
|
|
4252
4257
|
V(() => {
|
|
@@ -4263,18 +4268,18 @@ const Mi = Vn(
|
|
|
4263
4268
|
et.current.submitState === "payment" || et.current.submitState === "code" || (q({}), Qe.current(), xe(1));
|
|
4264
4269
|
},
|
|
4265
4270
|
goToStep: (x) => {
|
|
4266
|
-
const
|
|
4267
|
-
et.current = { ...
|
|
4271
|
+
const B = et.current, P = B.cascade.visibleSteps.includes(x), me = B.cascade.currentStep, Ie = B.submitState === "payment" || B.submitState === "code" ? 7 : !P || x > me ? me : x;
|
|
4272
|
+
et.current = { ...B, activeStep: Ie }, xe(Ie);
|
|
4268
4273
|
}
|
|
4269
4274
|
}),
|
|
4270
4275
|
[Se, q]
|
|
4271
4276
|
);
|
|
4272
|
-
|
|
4273
|
-
const Gt = Vt ??
|
|
4277
|
+
yr(bs, Et, Ze);
|
|
4278
|
+
const Gt = Vt ?? le("booking.regionLabel"), Ae = G.snapshot, Jt = H === "success" && Ae ? /* @__PURE__ */ n(
|
|
4274
4279
|
yi,
|
|
4275
4280
|
{
|
|
4276
4281
|
codeVerified: G.codeVerified,
|
|
4277
|
-
handoverUrl:
|
|
4282
|
+
handoverUrl: rr(G.redirectUrl),
|
|
4278
4283
|
handoverDelayMs: T,
|
|
4279
4284
|
onNavigate: k,
|
|
4280
4285
|
payment: Ae.payment,
|
|
@@ -4287,38 +4292,38 @@ const Mi = Vn(
|
|
|
4287
4292
|
},
|
|
4288
4293
|
operators: at,
|
|
4289
4294
|
specialties: pe,
|
|
4290
|
-
services:
|
|
4295
|
+
services: u,
|
|
4291
4296
|
locale: Ee,
|
|
4292
4297
|
mode: ot,
|
|
4293
4298
|
showModify: Z && !Ae.payment && !G.codeVerified,
|
|
4294
4299
|
onReset: () => Et.reset(),
|
|
4295
4300
|
focusWasLost: () => {
|
|
4296
|
-
const x = He.current,
|
|
4297
|
-
return !!(x && !x.isConnected) && (!
|
|
4301
|
+
const x = He.current, B = document.activeElement;
|
|
4302
|
+
return !!(x && !x.isConnected) && (!B || B === document.body);
|
|
4298
4303
|
},
|
|
4299
4304
|
onModify: () => {
|
|
4300
4305
|
Qe.current(), xe(7);
|
|
4301
4306
|
}
|
|
4302
4307
|
}
|
|
4303
4308
|
) : null, It = H === "code" && G.codeStep ? /* @__PURE__ */ n(
|
|
4304
|
-
|
|
4309
|
+
Js,
|
|
4305
4310
|
{
|
|
4306
4311
|
...G.codeStep,
|
|
4307
4312
|
...U,
|
|
4308
4313
|
onVerified: G.completeCode,
|
|
4309
4314
|
onBusyChange: ln
|
|
4310
4315
|
}
|
|
4311
|
-
) : null, Nt = G.activeSession, tt = G.state,
|
|
4316
|
+
) : null, Nt = G.activeSession, tt = G.state, d = Nt && tt ? {
|
|
4312
4317
|
session: Nt,
|
|
4313
4318
|
payment: Nt.payment,
|
|
4314
4319
|
state: tt,
|
|
4315
4320
|
billing: (Tn = G.snapshot) == null ? void 0 : Tn.details.billing
|
|
4316
|
-
} : void 0,
|
|
4321
|
+
} : void 0, E = tt && "phase" in tt && tt.phase === "completion", ie = H === "payment" && d ? /* @__PURE__ */ b(
|
|
4317
4322
|
"section",
|
|
4318
4323
|
{
|
|
4319
4324
|
"aria-labelledby": Ut,
|
|
4320
4325
|
"data-component": "booking-payment",
|
|
4321
|
-
"data-payment-status":
|
|
4326
|
+
"data-payment-status": d.state.status,
|
|
4322
4327
|
className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)]",
|
|
4323
4328
|
children: [
|
|
4324
4329
|
/* @__PURE__ */ n(
|
|
@@ -4328,15 +4333,15 @@ const Mi = Vn(
|
|
|
4328
4333
|
id: Ut,
|
|
4329
4334
|
tabIndex: -1,
|
|
4330
4335
|
className: "type-title-card ds:m-0",
|
|
4331
|
-
children:
|
|
4332
|
-
|
|
4336
|
+
children: le(
|
|
4337
|
+
E ? "booking.payment.confirming" : "booking.payment.heading"
|
|
4333
4338
|
)
|
|
4334
4339
|
}
|
|
4335
4340
|
),
|
|
4336
|
-
|
|
4341
|
+
E ? null : /* @__PURE__ */ n("p", { className: "type-body ds:m-0", children: le("booking.payment.noticeBody", {
|
|
4337
4342
|
amount: on(
|
|
4338
|
-
|
|
4339
|
-
|
|
4343
|
+
d.payment.amountCents,
|
|
4344
|
+
d.payment.currencyCode,
|
|
4340
4345
|
Ee
|
|
4341
4346
|
)
|
|
4342
4347
|
}) }),
|
|
@@ -4344,83 +4349,83 @@ const Mi = Vn(
|
|
|
4344
4349
|
"p",
|
|
4345
4350
|
{
|
|
4346
4351
|
role: "status",
|
|
4347
|
-
className:
|
|
4348
|
-
children:
|
|
4352
|
+
className: d.state.status === "processing" ? "type-body ds:m-0 ds:flex ds:items-center ds:gap-[var(--spacing-sm)]" : "ds:sr-only",
|
|
4353
|
+
children: d.state.status === "processing" ? /* @__PURE__ */ b(de, { children: [
|
|
4349
4354
|
/* @__PURE__ */ n(qn, { variant: "pulse", size: "lg", "aria-hidden": "true" }),
|
|
4350
|
-
/* @__PURE__ */ n("span", { children:
|
|
4351
|
-
|
|
4355
|
+
/* @__PURE__ */ n("span", { children: le(
|
|
4356
|
+
E ? "booking.payment.confirming" : "booking.payment.processing"
|
|
4352
4357
|
) })
|
|
4353
4358
|
] }) : null
|
|
4354
4359
|
}
|
|
4355
4360
|
),
|
|
4356
|
-
|
|
4361
|
+
d.state.status === "failed" ? /* @__PURE__ */ n(
|
|
4357
4362
|
re,
|
|
4358
4363
|
{
|
|
4359
4364
|
ref: lt,
|
|
4360
4365
|
variant: "error",
|
|
4361
4366
|
tabIndex: -1,
|
|
4362
4367
|
className: Bt,
|
|
4363
|
-
children: /* @__PURE__ */ n(re.Description, { children:
|
|
4364
|
-
|
|
4368
|
+
children: /* @__PURE__ */ n(re.Description, { children: d.state.error ?? le(
|
|
4369
|
+
E ? "booking.payment.completionFailed" : "booking.payment.failed"
|
|
4365
4370
|
) })
|
|
4366
4371
|
}
|
|
4367
4372
|
) : null,
|
|
4368
|
-
|
|
4373
|
+
E ? F == null ? void 0 : F(d) : L == null ? void 0 : L(d)
|
|
4369
4374
|
]
|
|
4370
4375
|
}
|
|
4371
4376
|
) : null, nt = K(() => {
|
|
4372
|
-
const x = new Set(Ye(
|
|
4373
|
-
var
|
|
4377
|
+
const x = new Set(Ye(I)), B = u.filter((P) => x.has(P.id)).map((P) => {
|
|
4378
|
+
var me;
|
|
4374
4379
|
return {
|
|
4375
4380
|
label: P.label,
|
|
4376
|
-
text: ((
|
|
4381
|
+
text: ((me = P.criticalInformationToAccept) == null ? void 0 : me.trim()) ?? ""
|
|
4377
4382
|
};
|
|
4378
4383
|
}).filter((P) => P.text.length > 0);
|
|
4379
|
-
if (
|
|
4380
|
-
return
|
|
4384
|
+
if (B.length !== 0)
|
|
4385
|
+
return B.length === 1 ? B[0].text : B.map((P) => `${P.label}: ${P.text}`).join(`
|
|
4381
4386
|
|
|
4382
4387
|
`);
|
|
4383
|
-
}, [
|
|
4388
|
+
}, [u, I]), Ge = K(() => {
|
|
4384
4389
|
if (H === "success" || H === "payment") return null;
|
|
4385
|
-
const x = Se === "accordion" ? Si : Se === "calendar" ? Ii : Se === "flexible" ? Ni : Se === "progress" ? wi : ki,
|
|
4390
|
+
const x = Se === "accordion" ? Si : Se === "calendar" ? Ii : Se === "flexible" ? Ni : Se === "progress" ? wi : ki, B = {
|
|
4386
4391
|
cascade: z,
|
|
4387
4392
|
inputs: {
|
|
4388
4393
|
specialties: pe,
|
|
4389
|
-
services:
|
|
4394
|
+
services: u,
|
|
4390
4395
|
operators: at,
|
|
4391
4396
|
availableDates: f,
|
|
4392
4397
|
availableSlots: S,
|
|
4393
4398
|
nextAvailableDate: g
|
|
4394
4399
|
},
|
|
4395
|
-
value:
|
|
4400
|
+
value: I,
|
|
4396
4401
|
onChange: q,
|
|
4397
4402
|
onSubmit: jt,
|
|
4398
4403
|
policy: { country: t, lockedOperatorId: s },
|
|
4399
4404
|
detailsProps: {
|
|
4400
|
-
hideEmail:
|
|
4405
|
+
hideEmail: l,
|
|
4401
4406
|
emailOptional: h,
|
|
4402
4407
|
requireCodiceFiscale: v,
|
|
4403
|
-
requireDateOfBirth:
|
|
4404
|
-
requireInsuranceNumber:
|
|
4405
|
-
insuranceType:
|
|
4406
|
-
showNote:
|
|
4407
|
-
showReturningPatientFlag:
|
|
4408
|
-
privacyPolicyUrl:
|
|
4409
|
-
termsUrl:
|
|
4408
|
+
requireDateOfBirth: m,
|
|
4409
|
+
requireInsuranceNumber: O,
|
|
4410
|
+
insuranceType: I.insuranceType,
|
|
4411
|
+
showNote: C,
|
|
4412
|
+
showReturningPatientFlag: M,
|
|
4413
|
+
privacyPolicyUrl: D,
|
|
4414
|
+
termsUrl: _,
|
|
4410
4415
|
practiceConsent: R,
|
|
4411
4416
|
criticalInformationToAccept: nt,
|
|
4412
4417
|
locked: H === "code",
|
|
4413
4418
|
payment: G.payment,
|
|
4414
4419
|
paymentTermsUrl: $,
|
|
4415
4420
|
paymentBlocked: G.blocked,
|
|
4416
|
-
billingInDetails:
|
|
4417
|
-
paymentNoticeStyle:
|
|
4418
|
-
validateCodiceFiscale:
|
|
4421
|
+
billingInDetails: N,
|
|
4422
|
+
paymentNoticeStyle: w,
|
|
4423
|
+
validateCodiceFiscale: y,
|
|
4419
4424
|
validateInsuranceNumber: W,
|
|
4420
4425
|
confirmationChannels: ne,
|
|
4421
4426
|
defaultConfirmationChannels: Ne,
|
|
4422
4427
|
singleConfirmationChannel: ge,
|
|
4423
|
-
submitError: Le ?? (H === "error" ?
|
|
4428
|
+
submitError: Le ?? (H === "error" ? le("booking.payment.submitFailed") : void 0)
|
|
4424
4429
|
},
|
|
4425
4430
|
emptyServicesSlot: Pt,
|
|
4426
4431
|
onboardingIncompleteSlot: Tt,
|
|
@@ -4442,41 +4447,41 @@ const Mi = Vn(
|
|
|
4442
4447
|
setActiveStep: xe,
|
|
4443
4448
|
agentIdBase: Ze
|
|
4444
4449
|
};
|
|
4445
|
-
return /* @__PURE__ */ n(x, { ...
|
|
4450
|
+
return /* @__PURE__ */ n(x, { ...B });
|
|
4446
4451
|
}, [
|
|
4447
4452
|
H,
|
|
4448
4453
|
G.payment,
|
|
4449
4454
|
G.blocked,
|
|
4450
4455
|
$,
|
|
4451
|
-
|
|
4456
|
+
le,
|
|
4452
4457
|
Se,
|
|
4453
4458
|
z,
|
|
4454
4459
|
pe,
|
|
4455
|
-
|
|
4460
|
+
u,
|
|
4456
4461
|
at,
|
|
4457
4462
|
f,
|
|
4458
4463
|
S,
|
|
4459
4464
|
g,
|
|
4460
|
-
|
|
4465
|
+
I,
|
|
4461
4466
|
q,
|
|
4462
4467
|
jt,
|
|
4463
4468
|
t,
|
|
4464
4469
|
s,
|
|
4465
|
-
|
|
4470
|
+
l,
|
|
4466
4471
|
h,
|
|
4467
4472
|
v,
|
|
4468
|
-
|
|
4469
|
-
|
|
4473
|
+
m,
|
|
4474
|
+
O,
|
|
4475
|
+
N,
|
|
4470
4476
|
w,
|
|
4471
|
-
C,
|
|
4472
4477
|
Le,
|
|
4473
|
-
|
|
4474
|
-
|
|
4475
|
-
|
|
4476
|
-
|
|
4478
|
+
C,
|
|
4479
|
+
M,
|
|
4480
|
+
D,
|
|
4481
|
+
_,
|
|
4477
4482
|
R,
|
|
4478
4483
|
nt,
|
|
4479
|
-
|
|
4484
|
+
y,
|
|
4480
4485
|
W,
|
|
4481
4486
|
ne,
|
|
4482
4487
|
Ne,
|
|
@@ -4500,7 +4505,7 @@ const Mi = Vn(
|
|
|
4500
4505
|
ee,
|
|
4501
4506
|
Ze
|
|
4502
4507
|
]);
|
|
4503
|
-
return /* @__PURE__ */
|
|
4508
|
+
return /* @__PURE__ */ b(
|
|
4504
4509
|
"div",
|
|
4505
4510
|
{
|
|
4506
4511
|
ref: Te,
|
|
@@ -4520,17 +4525,17 @@ const Mi = Vn(
|
|
|
4520
4525
|
He.current = x.target, we == null || we(x);
|
|
4521
4526
|
},
|
|
4522
4527
|
onBlur: (x) => {
|
|
4523
|
-
const
|
|
4528
|
+
const B = x.target;
|
|
4524
4529
|
window.setTimeout(() => {
|
|
4525
|
-
var
|
|
4530
|
+
var me;
|
|
4526
4531
|
const P = document.activeElement;
|
|
4527
|
-
He.current ===
|
|
4532
|
+
He.current === B && B.isConnected && !(P && ((me = Te.current) != null && me.contains(P))) && (He.current = null);
|
|
4528
4533
|
}), At == null || At(x);
|
|
4529
4534
|
},
|
|
4530
4535
|
...$t,
|
|
4531
4536
|
children: [
|
|
4532
4537
|
/* @__PURE__ */ n("div", { role: "status", className: "ds:sr-only", children: zt }),
|
|
4533
|
-
/* @__PURE__ */
|
|
4538
|
+
/* @__PURE__ */ b(
|
|
4534
4539
|
"div",
|
|
4535
4540
|
{
|
|
4536
4541
|
className: [
|
|
@@ -4542,13 +4547,13 @@ const Mi = Vn(
|
|
|
4542
4547
|
"ds:pt-[var(--spacing-md)] ds:pb-[var(--spacing-md)]"
|
|
4543
4548
|
].join(" "),
|
|
4544
4549
|
children: [
|
|
4545
|
-
/* @__PURE__ */ n("h2", { className: "type-title-card ds:text-[var(--foreground)] ds:m-0", children:
|
|
4546
|
-
/* @__PURE__ */ n("p", { className: "type-body-sm ds:text-[var(--foreground)] ds:m-0", children:
|
|
4550
|
+
/* @__PURE__ */ n("h2", { className: "type-title-card ds:text-[var(--foreground)] ds:m-0", children: le("booking.regionLabel") }),
|
|
4551
|
+
/* @__PURE__ */ n("p", { className: "type-body-sm ds:text-[var(--foreground)] ds:m-0", children: le("booking.headingSubtitle") })
|
|
4547
4552
|
]
|
|
4548
4553
|
}
|
|
4549
4554
|
),
|
|
4550
|
-
G.cancelled ? /* @__PURE__ */ n(re, { variant: "info", children: /* @__PURE__ */ n(re.Description, { children:
|
|
4551
|
-
Jt ?? ie ?? /* @__PURE__ */
|
|
4555
|
+
G.cancelled ? /* @__PURE__ */ n(re, { variant: "info", children: /* @__PURE__ */ n(re.Description, { children: le("booking.payment.cancelled") }) }) : null,
|
|
4556
|
+
Jt ?? ie ?? /* @__PURE__ */ b(de, { children: [
|
|
4552
4557
|
U ? /* @__PURE__ */ n(
|
|
4553
4558
|
"fieldset",
|
|
4554
4559
|
{
|
|
@@ -4558,7 +4563,7 @@ const Mi = Vn(
|
|
|
4558
4563
|
children: Ge
|
|
4559
4564
|
}
|
|
4560
4565
|
) : Ge,
|
|
4561
|
-
It ? /* @__PURE__ */
|
|
4566
|
+
It ? /* @__PURE__ */ b(de, { children: [
|
|
4562
4567
|
/* @__PURE__ */ n("div", { className: "ds:flex ds:justify-end", children: /* @__PURE__ */ n(
|
|
4563
4568
|
Re,
|
|
4564
4569
|
{
|
|
@@ -4569,7 +4574,7 @@ const Mi = Vn(
|
|
|
4569
4574
|
onClick: () => {
|
|
4570
4575
|
xt.current = !0, Qe.current();
|
|
4571
4576
|
},
|
|
4572
|
-
children:
|
|
4577
|
+
children: le("booking.actions.change")
|
|
4573
4578
|
}
|
|
4574
4579
|
) }),
|
|
4575
4580
|
It
|
|
@@ -4581,10 +4586,25 @@ const Mi = Vn(
|
|
|
4581
4586
|
}
|
|
4582
4587
|
);
|
|
4583
4588
|
Mi.displayName = "Booking";
|
|
4589
|
+
const Ao = {
|
|
4590
|
+
id: "booking-reserved",
|
|
4591
|
+
capabilities: [],
|
|
4592
|
+
state: {},
|
|
4593
|
+
actions: {},
|
|
4594
|
+
domHooks: {
|
|
4595
|
+
root: {
|
|
4596
|
+
attr: "data-component",
|
|
4597
|
+
value: "booking-reserved",
|
|
4598
|
+
description: "Marks the standalone or embedded reserved-time handover. The host verifies the booking and supplies the destination. No URL, appointment details or patient data are exposed through the adapter."
|
|
4599
|
+
}
|
|
4600
|
+
}
|
|
4601
|
+
};
|
|
4584
4602
|
export {
|
|
4585
4603
|
Mi as B,
|
|
4586
4604
|
fn as C,
|
|
4587
4605
|
qe as O,
|
|
4588
|
-
|
|
4606
|
+
ri as a,
|
|
4607
|
+
bs as b,
|
|
4608
|
+
Ao as c
|
|
4589
4609
|
};
|
|
4590
|
-
//# sourceMappingURL=
|
|
4610
|
+
//# sourceMappingURL=reserved.agent-C1gLyK2R.js.map
|