@alfadocs/ui-kit 1.75.1 → 1.77.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/_chunks/{balance-badge-cell-B49xgL6H.js → balance-badge-cell-Dzd-Z_5W.js} +2 -2
- package/dist/_chunks/booking-Cz_QjIJe.js +4051 -0
- package/dist/_chunks/{breadcrumb-Boan-5n8.js → breadcrumb-Bn29NCnf.js} +8 -8
- package/dist/_chunks/{calendar-appointment-editor-dialog-B4My4eiB.js → calendar-appointment-editor-dialog-cvUpUjj-.js} +4 -4
- package/dist/_chunks/{control-room-rail-CKZ2nemY.js → control-room-rail-DcJpHbp4.js} +2 -2
- package/dist/_chunks/{data-table-DTKGWUQm.js → data-table-BlONA1rP.js} +2 -2
- package/dist/_chunks/{file-manager-Ct5QpZZI.js → file-manager-C9iJjDZt.js} +3 -3
- package/dist/_chunks/{header-settings-Coh1r41O.js → header-settings-BYpVmLip.js} +2 -2
- package/dist/_chunks/{heatmap-Ba9cgfSY.js → heatmap-C2Rg-SV_.js} +2 -2
- package/dist/_chunks/{marketplace-app-shell-Ck5NVJcO.js → marketplace-app-shell-mS7Q2-81.js} +3 -3
- package/dist/_chunks/{notes-panel-CxjMovCh.js → notes-panel-CZO1qsD-.js} +2 -2
- package/dist/_chunks/{otp-input-CGMu30_e.js → otp-input-BgEZi0py.js} +54 -53
- package/dist/_chunks/{practice-results-B4Z5q46r.js → practice-results-By2BZFCz.js} +820 -783
- package/dist/_chunks/{recaptcha-widget-CsvwlYTE.js → recaptcha-widget-iglUBIF3.js} +2 -2
- package/dist/_chunks/{registration-form-DeK2QiJu.js → registration-form-xORq2s4p.js} +3 -3
- package/dist/_chunks/signature-request-DjY-X62H.js +2448 -0
- package/dist/_chunks/{tasks-panel-Cmr0oMvc.js → tasks-panel-BkjtgjQ8.js} +2 -2
- package/dist/_chunks/{theme-toggle-DTrUzIBG.js → theme-toggle-DKpzb0-M.js} +2 -2
- package/dist/_chunks/{tool-rail-C_9lm0TC.js → tool-rail-Kup1b7xI.js} +2 -2
- package/dist/_chunks/use-theme-CYGyzFgZ.js +196 -0
- package/dist/agent-catalog.json +46 -10
- package/dist/agent-i18n/en.json +5 -4
- package/dist/components/booking/booking-types.d.ts +22 -1
- package/dist/components/booking/booking.d.ts +1 -1
- package/dist/components/booking/code-step.d.ts +6 -0
- package/dist/components/booking/index.d.ts +1 -1
- package/dist/components/booking/index.js +1 -1
- package/dist/components/booking/step-focus.d.ts +9 -0
- package/dist/components/booking/use-booking-payment.d.ts +6 -3
- package/dist/components/breadcrumb/index.js +1 -1
- package/dist/components/control-room-rail/index.js +1 -1
- package/dist/components/data-table/index.js +1 -1
- package/dist/components/file-manager/index.js +1 -1
- package/dist/components/header-settings/index.js +1 -1
- package/dist/components/heatmap/index.js +1 -1
- package/dist/components/index.d.ts +1 -1
- package/dist/components/notes-panel/index.js +1 -1
- package/dist/components/otp-input/index.js +1 -1
- package/dist/components/otp-input/otp-input.d.ts +1 -0
- package/dist/components/patient-table/index.js +1 -1
- package/dist/components/practice-results/index.d.ts +1 -1
- package/dist/components/practice-results/index.js +1 -1
- package/dist/components/practice-results/practice-results.d.ts +4 -0
- package/dist/components/recaptcha-widget/index.js +1 -1
- package/dist/components/tasks-panel/index.js +1 -1
- package/dist/components/theme-toggle/index.js +1 -1
- package/dist/components/tool-rail/index.js +1 -1
- package/dist/hooks/index.d.ts +1 -1
- package/dist/hooks/index.js +88 -86
- package/dist/hooks/use-theme.d.ts +9 -0
- package/dist/host-compat.css +4 -1
- package/dist/i18n/locales/ar.d.ts +29 -0
- package/dist/i18n/locales/ar.js +30 -1
- package/dist/i18n/locales/de.d.ts +29 -0
- package/dist/i18n/locales/de.js +30 -1
- package/dist/i18n/locales/el.d.ts +29 -0
- package/dist/i18n/locales/el.js +30 -1
- package/dist/i18n/locales/en.d.ts +29 -0
- package/dist/i18n/locales/en.js +30 -1
- package/dist/i18n/locales/es.d.ts +29 -0
- package/dist/i18n/locales/es.js +30 -1
- package/dist/i18n/locales/fr.d.ts +29 -0
- package/dist/i18n/locales/fr.js +30 -1
- package/dist/i18n/locales/hi.d.ts +29 -0
- package/dist/i18n/locales/hi.js +30 -1
- package/dist/i18n/locales/it.d.ts +29 -0
- package/dist/i18n/locales/it.js +30 -1
- package/dist/i18n/locales/ja.d.ts +29 -0
- package/dist/i18n/locales/ja.js +30 -1
- package/dist/i18n/locales/nl.d.ts +29 -0
- package/dist/i18n/locales/nl.js +30 -1
- package/dist/i18n/locales/pl.d.ts +29 -0
- package/dist/i18n/locales/pl.js +30 -1
- package/dist/i18n/locales/pt.d.ts +29 -0
- package/dist/i18n/locales/pt.js +30 -1
- package/dist/i18n/locales/ro.d.ts +29 -0
- package/dist/i18n/locales/ro.js +30 -1
- package/dist/i18n/locales/ru.d.ts +29 -0
- package/dist/i18n/locales/ru.js +30 -1
- package/dist/i18n/locales/sq.d.ts +29 -0
- package/dist/i18n/locales/sq.js +30 -1
- package/dist/i18n/locales/sv.d.ts +29 -0
- package/dist/i18n/locales/sv.js +30 -1
- package/dist/i18n/locales/tr.d.ts +29 -0
- package/dist/i18n/locales/tr.js +30 -1
- package/dist/i18n/locales/zh.d.ts +29 -0
- package/dist/i18n/locales/zh.js +30 -1
- package/dist/index.js +1209 -1207
- package/dist/locales/ar.json +30 -1
- package/dist/locales/de.json +30 -1
- package/dist/locales/el.json +30 -1
- package/dist/locales/en.json +30 -1
- package/dist/locales/es.json +30 -1
- package/dist/locales/fr.json +30 -1
- package/dist/locales/hi.json +30 -1
- package/dist/locales/it.json +30 -1
- package/dist/locales/ja.json +30 -1
- package/dist/locales/nl.json +30 -1
- package/dist/locales/pl.json +30 -1
- package/dist/locales/pt.json +30 -1
- package/dist/locales/ro.json +30 -1
- package/dist/locales/ru.json +30 -1
- package/dist/locales/sq.json +30 -1
- package/dist/locales/sv.json +30 -1
- package/dist/locales/tr.json +30 -1
- package/dist/locales/zh.json +30 -1
- package/dist/patterns/calendar/index.js +1 -1
- package/dist/patterns/marketplace-app-shell/index.js +1 -1
- package/dist/patterns/registration-form/index.js +1 -1
- package/dist/patterns/signature-request/channel-meta.d.ts +8 -2
- package/dist/patterns/signature-request/index.js +1 -1
- package/dist/patterns/signature-request/minor-patient.d.ts +41 -0
- package/dist/patterns/signature-request/required-documents.d.ts +4 -3
- package/dist/patterns/signature-request/signature-request.d.ts +62 -12
- package/dist/theme-boot.js +26 -0
- package/dist/tokens.css +1 -1
- package/package.json +4 -2
- package/dist/_chunks/booking-D2r19Lia.js +0 -3901
- package/dist/_chunks/signature-request-ldmXj2X6.js +0 -2221
- package/dist/_chunks/use-theme-CAuo6EYT.js +0 -159
|
@@ -1,37 +1,37 @@
|
|
|
1
|
-
import { jsx as t, jsxs as m, Fragment as
|
|
2
|
-
import { forwardRef as
|
|
3
|
-
import { c as
|
|
4
|
-
import { useTranslation as
|
|
5
|
-
import { A as
|
|
6
|
-
import { A as
|
|
7
|
-
import { B as
|
|
8
|
-
import { D } from "./dropdown-menu-D1we7oAY.js";
|
|
9
|
-
import { E as
|
|
10
|
-
import { M as
|
|
11
|
-
import { R as
|
|
12
|
-
import { S as
|
|
13
|
-
import { S as
|
|
14
|
-
import { S as
|
|
15
|
-
import { B as
|
|
16
|
-
import { u as
|
|
17
|
-
import { b as
|
|
18
|
-
import { u as
|
|
19
|
-
import { c as
|
|
20
|
-
import { R as
|
|
21
|
-
import { C as
|
|
22
|
-
import { M as
|
|
23
|
-
import { L as
|
|
24
|
-
import { S as
|
|
25
|
-
import { H as
|
|
26
|
-
import { C as
|
|
27
|
-
import { C as
|
|
1
|
+
import { jsx as t, jsxs as m, Fragment as it } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef as st, useState as fe, useRef as T, useMemo as M, useImperativeHandle as rt, useCallback as B, useEffect as X } from "react";
|
|
3
|
+
import { c as V } from "./index-D2ZczOXr.js";
|
|
4
|
+
import { useTranslation as C } from "react-i18next";
|
|
5
|
+
import { A as ee } from "./alert-9kEwDza3.js";
|
|
6
|
+
import { A as Se } from "./avatar-BPiPL7ND.js";
|
|
7
|
+
import { B as te } from "./button-DohK_Ak_.js";
|
|
8
|
+
import { D as $ } from "./dropdown-menu-D1we7oAY.js";
|
|
9
|
+
import { E as ot } from "./empty-state-DwJ5YNzz.js";
|
|
10
|
+
import { M as lt } from "./map-view-C6MIVaqn.js";
|
|
11
|
+
import { R as Le } from "./rating-CGYpg5dj.js";
|
|
12
|
+
import { S as I } from "./sheet-uZZXaO_S.js";
|
|
13
|
+
import { S as ct } from "./skeleton-tTWJpvAq.js";
|
|
14
|
+
import { S as dt } from "./spinner-CoflYlEx.js";
|
|
15
|
+
import { B as O } from "./badge-BUk4RjTS.js";
|
|
16
|
+
import { u as ut } from "./use-media-query-CcAx5SMM.js";
|
|
17
|
+
import { b as mt } from "./format-price-BcFBa-WP.js";
|
|
18
|
+
import { u as pt } from "./registry-DvAUVLHh.js";
|
|
19
|
+
import { c as ft } from "./createLucideIcon-DhHxpK9K.js";
|
|
20
|
+
import { R as ht } from "./refresh-cw-DnI0cLFC.js";
|
|
21
|
+
import { C as Pe } from "./chevron-down-DWE7GSq9.js";
|
|
22
|
+
import { M as ae } from "./map-pin-BaY37-Km.js";
|
|
23
|
+
import { L as Ae, B as gt } from "./languages-CZqBaPwI.js";
|
|
24
|
+
import { S as Me } from "./shield-check-DCJALLVh.js";
|
|
25
|
+
import { H as Te } from "./heart--qCA4ffe.js";
|
|
26
|
+
import { C as vt } from "./calendar-clock-hbObjfGY.js";
|
|
27
|
+
import { C as bt } from "./calendar-plus-BFrIRE4r.js";
|
|
28
28
|
/**
|
|
29
29
|
* @license lucide-react v1.22.0 - ISC
|
|
30
30
|
*
|
|
31
31
|
* This source code is licensed under the ISC license.
|
|
32
32
|
* See the LICENSE file in the root directory of this source tree.
|
|
33
33
|
*/
|
|
34
|
-
const
|
|
34
|
+
const yt = [
|
|
35
35
|
[
|
|
36
36
|
"path",
|
|
37
37
|
{
|
|
@@ -41,7 +41,7 @@ const gt = [
|
|
|
41
41
|
],
|
|
42
42
|
["path", { d: "M15 5.764v15", key: "1pn4in" }],
|
|
43
43
|
["path", { d: "M9 3.236v15", key: "1uimfh" }]
|
|
44
|
-
],
|
|
44
|
+
], xt = ft("map", yt), kt = {
|
|
45
45
|
id: "practice-results",
|
|
46
46
|
// `scroll` backs scroll_to_result; `pick` backs focus_pin (a non-persisting
|
|
47
47
|
// pin highlight). The active variant is consumer-owned via props, so there is
|
|
@@ -108,7 +108,7 @@ const gt = [
|
|
|
108
108
|
root: {
|
|
109
109
|
attr: "data-component",
|
|
110
110
|
value: "practice-results",
|
|
111
|
-
description: "Marks the PracticeResults root region."
|
|
111
|
+
description: "Marks the PracticeResults root region. The headingLevel prop accepts 1 to 6 (default 2) for the optional results heading; use 1 when it is the page title. Card names and default error and empty-state titles use the next level, capped at 6."
|
|
112
112
|
},
|
|
113
113
|
instanceId: {
|
|
114
114
|
attr: "data-component-id",
|
|
@@ -117,104 +117,104 @@ const gt = [
|
|
|
117
117
|
},
|
|
118
118
|
item: {
|
|
119
119
|
attr: "data-result-id",
|
|
120
|
-
description: 'Stable result id emitted on each rendered result card. Used by scroll_to_result / focus_pin to address a single result. Each card also carries up to two anchors: data-component="practice-result-open-cta" (practice page; absent when the consumer sets showCardOpenButton=false) and data-component="practice-result-book-cta" (booking flow; data-slot-aware="true" when it deep-links to a next slot). Card content carries its own read-only hooks: data-component="practice-result-tagline", data-component="practice-result-description", and data-component="practice-result-price" (the kit-formatted first-visit cost
|
|
120
|
+
description: 'Stable result id emitted on each rendered result card. Used by scroll_to_result / focus_pin to address a single result. The non-focusable card group is labelled by the practice-result-{id}-name heading, which contains data-component="practice-result-name-link": a visible link to result.href that navigates without firing onResultSelect or click telemetry. Each card also carries up to two CTA anchors: data-component="practice-result-open-cta" (practice page; absent when the consumer sets showCardOpenButton=false) and data-component="practice-result-book-cta" (booking flow; data-slot-aware="true" when it deep-links to a next slot). Card content carries its own read-only hooks: data-component="practice-result-tagline", data-component="practice-result-description", and data-component="practice-result-price" (the kit-formatted first-visit cost, present only when the practice set one).'
|
|
121
121
|
}
|
|
122
122
|
}
|
|
123
|
-
},
|
|
123
|
+
}, Ct = 13, wt = [
|
|
124
124
|
"distance",
|
|
125
125
|
"rating",
|
|
126
126
|
"next-available",
|
|
127
127
|
"relevance"
|
|
128
128
|
];
|
|
129
|
-
function Ie(e, n,
|
|
130
|
-
const
|
|
131
|
-
return
|
|
129
|
+
function Ie(e, n, a) {
|
|
130
|
+
const s = `languages.${e}`;
|
|
131
|
+
return a.exists(s) ? n(s) : e.toUpperCase();
|
|
132
132
|
}
|
|
133
|
-
function
|
|
133
|
+
function H(e, n) {
|
|
134
134
|
if (typeof window > "u") return;
|
|
135
|
-
const
|
|
135
|
+
const a = window.track;
|
|
136
136
|
try {
|
|
137
|
-
|
|
137
|
+
a == null || a(e, n);
|
|
138
138
|
} catch {
|
|
139
139
|
}
|
|
140
140
|
}
|
|
141
|
-
function
|
|
142
|
-
const
|
|
143
|
-
if (
|
|
144
|
-
const
|
|
145
|
-
|
|
141
|
+
function J(e, n, a, s) {
|
|
142
|
+
const r = e.findIndex((d) => d.id === n);
|
|
143
|
+
if (r < 0) return;
|
|
144
|
+
const i = e[r];
|
|
145
|
+
i && (H("serp_result_clicked", { resultId: n, source: a, position: r }), s(i, a));
|
|
146
146
|
}
|
|
147
|
-
function
|
|
148
|
-
const
|
|
149
|
-
return 2 * 6371 * Math.asin(Math.min(1, Math.sqrt(
|
|
147
|
+
function Rt(e, n) {
|
|
148
|
+
const s = (n.lat - e.lat) * Math.PI / 180, r = (n.lng - e.lng) * Math.PI / 180, i = e.lat * Math.PI / 180, d = n.lat * Math.PI / 180, u = Math.sin(s / 2), l = Math.sin(r / 2), g = u * u + Math.cos(i) * Math.cos(d) * l * l;
|
|
149
|
+
return 2 * 6371 * Math.asin(Math.min(1, Math.sqrt(g)));
|
|
150
150
|
}
|
|
151
|
-
function
|
|
152
|
-
var
|
|
153
|
-
const
|
|
154
|
-
for (const
|
|
155
|
-
const
|
|
156
|
-
(
|
|
151
|
+
function Nt(e, n, a) {
|
|
152
|
+
var r;
|
|
153
|
+
const s = [];
|
|
154
|
+
for (const i of e) {
|
|
155
|
+
const d = i.field ?? i.key, u = (((r = a == null ? void 0 : a[i.key]) == null ? void 0 : r.length) ?? 0) > 0, l = i.type === "boolean" || i.type !== "options" && i.options.length === 0 && (u || n.some(
|
|
156
|
+
(g) => typeof g[d] == "boolean"
|
|
157
157
|
));
|
|
158
|
-
!
|
|
158
|
+
!l && i.options.length === 0 || s.push({ ...i, boolean: l, booleanField: d });
|
|
159
159
|
}
|
|
160
|
-
return
|
|
160
|
+
return s;
|
|
161
161
|
}
|
|
162
|
-
function
|
|
163
|
-
return !n || Object.keys(n).length === 0 ? e : e.filter((
|
|
164
|
-
for (const
|
|
165
|
-
const
|
|
166
|
-
if (!
|
|
167
|
-
if (
|
|
168
|
-
if (r
|
|
162
|
+
function St(e, n, a) {
|
|
163
|
+
return !n || Object.keys(n).length === 0 ? e : e.filter((s) => {
|
|
164
|
+
for (const r of a) {
|
|
165
|
+
const i = n[r.key];
|
|
166
|
+
if (!i || i.length === 0) continue;
|
|
167
|
+
if (r.boolean) {
|
|
168
|
+
if (s[r.booleanField] !== !0) return !1;
|
|
169
169
|
continue;
|
|
170
170
|
}
|
|
171
|
-
const
|
|
172
|
-
if (!Array.isArray(
|
|
171
|
+
const d = r.key === "insurance" ? s.insurances : r.key === "language" ? s.languages : s[r.key];
|
|
172
|
+
if (!Array.isArray(d) || !(r.multi ? i.some((l) => d.includes(l)) : d.includes(i[0]))) return !1;
|
|
173
173
|
}
|
|
174
174
|
return !0;
|
|
175
175
|
});
|
|
176
176
|
}
|
|
177
|
-
function
|
|
178
|
-
const
|
|
179
|
-
const
|
|
180
|
-
return { result:
|
|
181
|
-
}),
|
|
182
|
-
var
|
|
177
|
+
function Lt(e, n, a) {
|
|
178
|
+
const s = e.map((i) => {
|
|
179
|
+
const d = i.location ? i.location.distanceKm ?? (a ? Rt(a, i.location) : void 0) : void 0;
|
|
180
|
+
return { result: i, distanceKm: d };
|
|
181
|
+
}), r = (i, d) => {
|
|
182
|
+
var u, l, g, o;
|
|
183
183
|
switch (n) {
|
|
184
184
|
case "distance":
|
|
185
|
-
return
|
|
185
|
+
return i.distanceKm == null && d.distanceKm == null ? 0 : i.distanceKm == null ? 1 : d.distanceKm == null ? -1 : i.distanceKm - d.distanceKm;
|
|
186
186
|
case "rating": {
|
|
187
|
-
const
|
|
188
|
-
return (((
|
|
187
|
+
const p = ((u = i.result.rating) == null ? void 0 : u.value) ?? -1;
|
|
188
|
+
return (((l = d.result.rating) == null ? void 0 : l.value) ?? -1) - p;
|
|
189
189
|
}
|
|
190
190
|
case "next-available": {
|
|
191
|
-
const
|
|
192
|
-
return !
|
|
191
|
+
const p = ((g = i.result.nextAvailableSlot) == null ? void 0 : g.dateTime) ?? "", f = ((o = d.result.nextAvailableSlot) == null ? void 0 : o.dateTime) ?? "";
|
|
192
|
+
return !p && !f ? 0 : p ? f ? p.localeCompare(f) : -1 : 1;
|
|
193
193
|
}
|
|
194
194
|
case "relevance":
|
|
195
195
|
default:
|
|
196
196
|
return 0;
|
|
197
197
|
}
|
|
198
198
|
};
|
|
199
|
-
return [...
|
|
200
|
-
({ result:
|
|
201
|
-
...
|
|
202
|
-
location: { ...
|
|
203
|
-
} :
|
|
199
|
+
return [...s].sort(r).map(
|
|
200
|
+
({ result: i, distanceKm: d }) => d != null && i.location ? {
|
|
201
|
+
...i,
|
|
202
|
+
location: { ...i.location, distanceKm: d }
|
|
203
|
+
} : i
|
|
204
204
|
);
|
|
205
205
|
}
|
|
206
|
-
function
|
|
207
|
-
let n = -1 / 0,
|
|
208
|
-
for (const
|
|
209
|
-
if (!
|
|
210
|
-
|
|
211
|
-
const { lat:
|
|
212
|
-
|
|
206
|
+
function Re(e) {
|
|
207
|
+
let n = -1 / 0, a = 1 / 0, s = -1 / 0, r = 1 / 0, i = !1;
|
|
208
|
+
for (const d of e) {
|
|
209
|
+
if (!d.location) continue;
|
|
210
|
+
i = !0;
|
|
211
|
+
const { lat: u, lng: l } = d.location;
|
|
212
|
+
u > n && (n = u), u < a && (a = u), l > s && (s = l), l < r && (r = l);
|
|
213
213
|
}
|
|
214
|
-
if (
|
|
215
|
-
return { north: n, south:
|
|
214
|
+
if (i)
|
|
215
|
+
return { north: n, south: a, east: s, west: r };
|
|
216
216
|
}
|
|
217
|
-
const
|
|
217
|
+
const Pt = V(
|
|
218
218
|
"ds:flex ds:w-full ds:flex-col ds:text-[var(--foreground)] ds:gap-[var(--spacing-md)]",
|
|
219
219
|
{
|
|
220
220
|
variants: {
|
|
@@ -229,30 +229,31 @@ const Nt = j(
|
|
|
229
229
|
);
|
|
230
230
|
function _e({
|
|
231
231
|
heading: e,
|
|
232
|
-
|
|
232
|
+
headingLevel: n,
|
|
233
|
+
intro: a,
|
|
233
234
|
totalCount: s,
|
|
234
235
|
searchCentreLabel: r
|
|
235
236
|
}) {
|
|
236
|
-
const { t: i } =
|
|
237
|
-
if (!e && !
|
|
238
|
-
const
|
|
237
|
+
const { t: i } = C("ui"), d = `h${n}`;
|
|
238
|
+
if (!e && !a && s == null) return null;
|
|
239
|
+
const u = s != null ? r ? i("practiceResults.results.heading", {
|
|
239
240
|
count: s,
|
|
240
241
|
place: r
|
|
241
242
|
}) : i("practiceResults.results.summary", { count: s }) : void 0;
|
|
242
243
|
return /* @__PURE__ */ m("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-xs)]", children: [
|
|
243
|
-
e ? /* @__PURE__ */ t(
|
|
244
|
-
|
|
245
|
-
|
|
244
|
+
e ? /* @__PURE__ */ t(d, { className: "type-title-section ds:m-0 ds:text-[var(--foreground)]", children: e }) : null,
|
|
245
|
+
a ? /* @__PURE__ */ t("p", { className: "type-body ds:m-0 ds:text-[var(--muted-foreground)]", children: a }) : null,
|
|
246
|
+
u ? /* @__PURE__ */ t(
|
|
246
247
|
"p",
|
|
247
248
|
{
|
|
248
249
|
className: "type-body-sm ds:m-0 ds:text-[var(--muted-foreground)]",
|
|
249
250
|
"aria-live": "polite",
|
|
250
|
-
children:
|
|
251
|
+
children: u
|
|
251
252
|
}
|
|
252
253
|
) : null
|
|
253
254
|
] });
|
|
254
255
|
}
|
|
255
|
-
const
|
|
256
|
+
const ne = V(
|
|
256
257
|
[
|
|
257
258
|
"ds:inline-flex ds:items-center ds:gap-[var(--spacing-xs)]",
|
|
258
259
|
"ds:min-h-[var(--min-target-size)]",
|
|
@@ -274,7 +275,7 @@ const te = j(
|
|
|
274
275
|
},
|
|
275
276
|
defaultVariants: { state: "idle" }
|
|
276
277
|
}
|
|
277
|
-
),
|
|
278
|
+
), At = V(
|
|
278
279
|
"ds:flex ds:flex-wrap ds:items-center ds:gap-[var(--spacing-xs)]",
|
|
279
280
|
{
|
|
280
281
|
variants: {
|
|
@@ -293,7 +294,7 @@ const te = j(
|
|
|
293
294
|
},
|
|
294
295
|
defaultVariants: { placement: "inline" }
|
|
295
296
|
}
|
|
296
|
-
),
|
|
297
|
+
), Mt = V(
|
|
297
298
|
[
|
|
298
299
|
"ds:ms-[var(--spacing-xs)] ds:inline-flex ds:items-center ds:gap-[var(--spacing-xs)]",
|
|
299
300
|
"ds:min-h-[var(--min-target-size)] ds:ps-[var(--spacing-xs)] ds:pe-[var(--spacing-xs)]",
|
|
@@ -304,71 +305,71 @@ const te = j(
|
|
|
304
305
|
"ds:focus-visible:outline-[color:var(--ring)] ds:focus-visible:outline-offset-[length:var(--focus-ring-offset)]"
|
|
305
306
|
].join(" ")
|
|
306
307
|
);
|
|
307
|
-
function
|
|
308
|
+
function ze({
|
|
308
309
|
facets: e,
|
|
309
310
|
value: n,
|
|
310
|
-
onChange:
|
|
311
|
-
floating:
|
|
311
|
+
onChange: a,
|
|
312
|
+
floating: s
|
|
312
313
|
}) {
|
|
313
|
-
const { t:
|
|
314
|
-
() => Object.values(
|
|
315
|
-
[
|
|
316
|
-
),
|
|
317
|
-
const
|
|
318
|
-
|
|
319
|
-
},
|
|
320
|
-
var
|
|
321
|
-
const
|
|
322
|
-
|
|
323
|
-
},
|
|
324
|
-
const
|
|
325
|
-
let
|
|
326
|
-
o.multi ?
|
|
314
|
+
const { t: r } = C("ui"), i = M(() => n ?? {}, [n]), d = M(
|
|
315
|
+
() => Object.values(i).some((o) => o && o.length > 0),
|
|
316
|
+
[i]
|
|
317
|
+
), u = (o, p) => {
|
|
318
|
+
const f = { ...i };
|
|
319
|
+
p.length === 0 ? delete f[o] : f[o] = p, a(f), H("serp_filter_changed", { key: o, values: p });
|
|
320
|
+
}, l = (o) => {
|
|
321
|
+
var f;
|
|
322
|
+
const p = (((f = i[o]) == null ? void 0 : f.length) ?? 0) > 0;
|
|
323
|
+
u(o, p ? [] : ["true"]);
|
|
324
|
+
}, g = (o, p) => {
|
|
325
|
+
const f = i[o.key] ?? [], b = f.includes(p);
|
|
326
|
+
let h;
|
|
327
|
+
o.multi ? h = b ? f.filter((y) => y !== p) : [...f, p] : h = b ? [] : [p], u(o.key, h);
|
|
327
328
|
};
|
|
328
329
|
return e.length === 0 ? null : /* @__PURE__ */ m(
|
|
329
330
|
"div",
|
|
330
331
|
{
|
|
331
332
|
"data-component": "practice-results-filters",
|
|
332
333
|
role: "group",
|
|
333
|
-
"aria-label":
|
|
334
|
-
className:
|
|
335
|
-
placement:
|
|
334
|
+
"aria-label": r("practiceResults.filters.label"),
|
|
335
|
+
className: At({
|
|
336
|
+
placement: s ? "floating" : "inline"
|
|
336
337
|
}),
|
|
337
338
|
children: [
|
|
338
339
|
e.map((o) => {
|
|
339
|
-
const
|
|
340
|
-
if (
|
|
340
|
+
const p = o.boolean, f = i[o.key] ?? [], b = f.length > 0;
|
|
341
|
+
if (p)
|
|
341
342
|
return /* @__PURE__ */ t(
|
|
342
343
|
"button",
|
|
343
344
|
{
|
|
344
345
|
type: "button",
|
|
345
|
-
"aria-pressed":
|
|
346
|
+
"aria-pressed": b,
|
|
346
347
|
"aria-label": o.label,
|
|
347
|
-
onClick: () =>
|
|
348
|
-
className:
|
|
349
|
-
state:
|
|
348
|
+
onClick: () => l(o.key),
|
|
349
|
+
className: ne({
|
|
350
|
+
state: b ? "active" : "idle"
|
|
350
351
|
}),
|
|
351
352
|
children: /* @__PURE__ */ t("span", { children: o.label })
|
|
352
353
|
},
|
|
353
354
|
o.key
|
|
354
355
|
);
|
|
355
|
-
const
|
|
356
|
-
return /* @__PURE__ */ m(
|
|
357
|
-
/* @__PURE__ */ t(
|
|
356
|
+
const h = b ? ` (${f.length})` : "";
|
|
357
|
+
return /* @__PURE__ */ m($.Root, { children: [
|
|
358
|
+
/* @__PURE__ */ t($.Trigger, { asChild: !0, children: /* @__PURE__ */ m(
|
|
358
359
|
"button",
|
|
359
360
|
{
|
|
360
361
|
type: "button",
|
|
361
|
-
"aria-label": `${o.label}${
|
|
362
|
-
className:
|
|
363
|
-
state:
|
|
362
|
+
"aria-label": `${o.label}${h}`,
|
|
363
|
+
className: ne({
|
|
364
|
+
state: b ? "active" : "idle"
|
|
364
365
|
}),
|
|
365
366
|
children: [
|
|
366
367
|
/* @__PURE__ */ m("span", { children: [
|
|
367
368
|
o.label,
|
|
368
|
-
|
|
369
|
+
h
|
|
369
370
|
] }),
|
|
370
371
|
/* @__PURE__ */ t(
|
|
371
|
-
|
|
372
|
+
Pe,
|
|
372
373
|
{
|
|
373
374
|
"aria-hidden": "true",
|
|
374
375
|
className: "ds:size-3.5 ds:shrink-0"
|
|
@@ -377,12 +378,12 @@ function Te({
|
|
|
377
378
|
]
|
|
378
379
|
}
|
|
379
380
|
) }),
|
|
380
|
-
/* @__PURE__ */ t(
|
|
381
|
-
|
|
381
|
+
/* @__PURE__ */ t($.Content, { sideOffset: 8, align: "start", children: o.options.map((y) => /* @__PURE__ */ t(
|
|
382
|
+
$.CheckboxItem,
|
|
382
383
|
{
|
|
383
|
-
checked:
|
|
384
|
-
onSelect: (
|
|
385
|
-
o.multi &&
|
|
384
|
+
checked: f.includes(y.value),
|
|
385
|
+
onSelect: (k) => {
|
|
386
|
+
o.multi && k.preventDefault(), g(o, y.value);
|
|
386
387
|
},
|
|
387
388
|
children: y.label
|
|
388
389
|
},
|
|
@@ -390,76 +391,76 @@ function Te({
|
|
|
390
391
|
)) })
|
|
391
392
|
] }, o.key);
|
|
392
393
|
}),
|
|
393
|
-
|
|
394
|
+
d ? /* @__PURE__ */ t(
|
|
394
395
|
"button",
|
|
395
396
|
{
|
|
396
397
|
type: "button",
|
|
397
398
|
onClick: () => {
|
|
398
|
-
|
|
399
|
+
a({}), H("serp_filter_changed", { key: "*", values: [] });
|
|
399
400
|
},
|
|
400
|
-
className:
|
|
401
|
-
children:
|
|
401
|
+
className: Mt(),
|
|
402
|
+
children: r("practiceResults.filters.clear")
|
|
402
403
|
}
|
|
403
404
|
) : null
|
|
404
405
|
]
|
|
405
406
|
}
|
|
406
407
|
);
|
|
407
408
|
}
|
|
408
|
-
function
|
|
409
|
-
const { t:
|
|
410
|
-
switch (
|
|
409
|
+
function me({ value: e, onChange: n }) {
|
|
410
|
+
const { t: a } = C("ui"), s = (r) => {
|
|
411
|
+
switch (r) {
|
|
411
412
|
case "distance":
|
|
412
|
-
return
|
|
413
|
+
return a("practiceResults.sort.distance");
|
|
413
414
|
case "rating":
|
|
414
|
-
return
|
|
415
|
+
return a("practiceResults.sort.rating");
|
|
415
416
|
case "next-available":
|
|
416
|
-
return
|
|
417
|
+
return a("practiceResults.sort.nextAvailable");
|
|
417
418
|
case "relevance":
|
|
418
419
|
default:
|
|
419
|
-
return
|
|
420
|
+
return a("practiceResults.sort.relevance");
|
|
420
421
|
}
|
|
421
422
|
};
|
|
422
|
-
return /* @__PURE__ */ m(
|
|
423
|
-
/* @__PURE__ */ t(
|
|
423
|
+
return /* @__PURE__ */ m($.Root, { children: [
|
|
424
|
+
/* @__PURE__ */ t($.Trigger, { asChild: !0, children: /* @__PURE__ */ m(
|
|
424
425
|
"button",
|
|
425
426
|
{
|
|
426
427
|
type: "button",
|
|
427
|
-
"aria-label": `${
|
|
428
|
-
className:
|
|
428
|
+
"aria-label": `${a("practiceResults.sort.label")}: ${s(e)}`,
|
|
429
|
+
className: ne({ state: "idle" }),
|
|
429
430
|
children: [
|
|
430
431
|
/* @__PURE__ */ m("span", { children: [
|
|
431
|
-
|
|
432
|
+
a("practiceResults.sort.label"),
|
|
432
433
|
": ",
|
|
433
|
-
|
|
434
|
+
s(e)
|
|
434
435
|
] }),
|
|
435
|
-
/* @__PURE__ */ t(
|
|
436
|
+
/* @__PURE__ */ t(Pe, { "aria-hidden": "true", className: "ds:size-3.5 ds:shrink-0" })
|
|
436
437
|
]
|
|
437
438
|
}
|
|
438
439
|
) }),
|
|
439
|
-
/* @__PURE__ */ t(
|
|
440
|
-
|
|
440
|
+
/* @__PURE__ */ t($.Content, { sideOffset: 8, align: "end", children: /* @__PURE__ */ t(
|
|
441
|
+
$.RadioGroup,
|
|
441
442
|
{
|
|
442
443
|
value: e,
|
|
443
|
-
onValueChange: (
|
|
444
|
-
const
|
|
445
|
-
|
|
444
|
+
onValueChange: (r) => {
|
|
445
|
+
const i = r;
|
|
446
|
+
i !== e && (n(i), H("serp_sort_changed", { sort: i }));
|
|
446
447
|
},
|
|
447
|
-
children:
|
|
448
|
+
children: wt.map((r) => /* @__PURE__ */ t($.RadioItem, { value: r, children: s(r) }, r))
|
|
448
449
|
}
|
|
449
450
|
) })
|
|
450
451
|
] });
|
|
451
452
|
}
|
|
452
|
-
function
|
|
453
|
-
const { t: n, i18n:
|
|
453
|
+
function Fe({ distanceKm: e }) {
|
|
454
|
+
const { t: n, i18n: a } = C("ui"), s = M(() => {
|
|
454
455
|
if (e < 1) return n("practiceResults.distance.below");
|
|
455
|
-
const
|
|
456
|
+
const r = new Intl.NumberFormat(a.language, {
|
|
456
457
|
maximumFractionDigits: 1
|
|
457
458
|
}).format(e);
|
|
458
|
-
return n("practiceResults.distance.km", { distance:
|
|
459
|
-
}, [e, n,
|
|
460
|
-
return /* @__PURE__ */ t(
|
|
459
|
+
return n("practiceResults.distance.km", { distance: r });
|
|
460
|
+
}, [e, n, a.language]);
|
|
461
|
+
return /* @__PURE__ */ t(O, { variant: "neutral", leading: /* @__PURE__ */ t(ae, { "aria-hidden": "true" }), children: s });
|
|
461
462
|
}
|
|
462
|
-
const
|
|
463
|
+
const Ne = V(
|
|
463
464
|
[
|
|
464
465
|
"ds:inline-size-[12rem] ds:block-size-[8rem] ds:shrink-0",
|
|
465
466
|
"ds:rounded-[var(--radius-md)] ds:overflow-hidden"
|
|
@@ -478,45 +479,45 @@ const we = j(
|
|
|
478
479
|
defaultVariants: { state: "placeholder" }
|
|
479
480
|
}
|
|
480
481
|
);
|
|
481
|
-
function
|
|
482
|
+
function Tt() {
|
|
482
483
|
if (typeof document > "u") return "4945a3";
|
|
483
484
|
const e = getComputedStyle(document.documentElement).getPropertyValue("--map-marker-color").trim(), n = /^#?([0-9a-fA-F]{6})$/.exec(e);
|
|
484
485
|
return n ? n[1] : "4945a3";
|
|
485
486
|
}
|
|
486
|
-
function
|
|
487
|
+
function It({
|
|
487
488
|
apiKey: e,
|
|
488
489
|
center: n,
|
|
489
|
-
zoom:
|
|
490
|
-
address:
|
|
490
|
+
zoom: a = 14,
|
|
491
|
+
address: s
|
|
491
492
|
}) {
|
|
492
|
-
const { t:
|
|
493
|
+
const { t: r } = C("ui");
|
|
493
494
|
if (!e)
|
|
494
495
|
return /* @__PURE__ */ m(
|
|
495
496
|
"div",
|
|
496
497
|
{
|
|
497
|
-
"aria-hidden":
|
|
498
|
-
className:
|
|
498
|
+
"aria-hidden": s ? void 0 : "true",
|
|
499
|
+
className: Ne({ state: "placeholder" }),
|
|
499
500
|
children: [
|
|
500
|
-
/* @__PURE__ */ t(
|
|
501
|
-
|
|
501
|
+
/* @__PURE__ */ t(ae, { "aria-hidden": "true", className: "ds:size-5 ds:shrink-0" }),
|
|
502
|
+
s ? /* @__PURE__ */ t("span", { dir: "auto", className: "type-meta ds:[overflow-wrap:anywhere]", children: s }) : null
|
|
502
503
|
]
|
|
503
504
|
}
|
|
504
505
|
);
|
|
505
|
-
const
|
|
506
|
+
const i = Tt(), d = `https://maps.googleapis.com/maps/api/staticmap?center=${n.lat},${n.lng}&zoom=${a}&size=240x160&scale=2&markers=color:0x${i}%7C${n.lat},${n.lng}&key=${encodeURIComponent(e)}`;
|
|
506
507
|
return /* @__PURE__ */ t(
|
|
507
508
|
"img",
|
|
508
509
|
{
|
|
509
|
-
src:
|
|
510
|
-
alt:
|
|
510
|
+
src: d,
|
|
511
|
+
alt: r("practiceResults.thumbnail.alt"),
|
|
511
512
|
loading: "lazy",
|
|
512
513
|
decoding: "async",
|
|
513
514
|
width: 240,
|
|
514
515
|
height: 160,
|
|
515
|
-
className:
|
|
516
|
+
className: Ne({ state: "image" })
|
|
516
517
|
}
|
|
517
518
|
);
|
|
518
519
|
}
|
|
519
|
-
function
|
|
520
|
+
function He({ tagline: e }) {
|
|
520
521
|
return e ? /* @__PURE__ */ t(
|
|
521
522
|
"span",
|
|
522
523
|
{
|
|
@@ -527,7 +528,7 @@ function Fe({ tagline: e }) {
|
|
|
527
528
|
}
|
|
528
529
|
) : null;
|
|
529
530
|
}
|
|
530
|
-
const
|
|
531
|
+
const _t = V(
|
|
531
532
|
"type-body-sm ds:m-0 ds:text-[var(--muted-foreground)] ds:whitespace-pre-line ds:break-words",
|
|
532
533
|
{
|
|
533
534
|
variants: {
|
|
@@ -539,7 +540,7 @@ const It = j(
|
|
|
539
540
|
defaultVariants: { density: "compact" }
|
|
540
541
|
}
|
|
541
542
|
);
|
|
542
|
-
function
|
|
543
|
+
function Be({
|
|
543
544
|
description: e,
|
|
544
545
|
density: n
|
|
545
546
|
}) {
|
|
@@ -548,49 +549,49 @@ function Le({
|
|
|
548
549
|
{
|
|
549
550
|
"data-component": "practice-result-description",
|
|
550
551
|
dir: "auto",
|
|
551
|
-
className:
|
|
552
|
+
className: _t({ density: n }),
|
|
552
553
|
children: e
|
|
553
554
|
}
|
|
554
555
|
) : null;
|
|
555
556
|
}
|
|
556
|
-
function
|
|
557
|
+
function $e({
|
|
557
558
|
cents: e,
|
|
558
559
|
currencyCode: n = "EUR"
|
|
559
560
|
}) {
|
|
560
|
-
const { t:
|
|
561
|
-
() => e == null ? void 0 :
|
|
561
|
+
const { t: a, i18n: s } = C("ui"), r = M(
|
|
562
|
+
() => e == null ? void 0 : mt(
|
|
562
563
|
e,
|
|
563
564
|
n,
|
|
564
|
-
|
|
565
|
-
|
|
565
|
+
s.language ?? "en",
|
|
566
|
+
a("common.freeOfCharge")
|
|
566
567
|
),
|
|
567
|
-
[e, n,
|
|
568
|
+
[e, n, s.language, a]
|
|
568
569
|
);
|
|
569
|
-
return
|
|
570
|
+
return r === void 0 ? null : /* @__PURE__ */ m(
|
|
570
571
|
"span",
|
|
571
572
|
{
|
|
572
573
|
"data-component": "practice-result-price",
|
|
573
574
|
className: "type-body-sm ds:inline-flex ds:flex-wrap ds:items-center ds:gap-[var(--spacing-xs)] ds:text-[var(--muted-foreground)]",
|
|
574
575
|
children: [
|
|
575
576
|
/* @__PURE__ */ t(
|
|
576
|
-
|
|
577
|
+
gt,
|
|
577
578
|
{
|
|
578
579
|
"aria-hidden": "true",
|
|
579
580
|
className: "ds:size-4 ds:shrink-0 ds:text-[var(--primary)]"
|
|
580
581
|
}
|
|
581
582
|
),
|
|
582
|
-
|
|
583
|
+
a("practiceResults.card.firstVisitPrice"),
|
|
583
584
|
/* @__PURE__ */ t("span", { className: "ds:sr-only", children: ": " }),
|
|
584
|
-
/* @__PURE__ */ t("span", { className: "ds:font-[var(--font-weight-medium)] ds:text-[var(--foreground)]", children:
|
|
585
|
+
/* @__PURE__ */ t("span", { className: "ds:font-[var(--font-weight-medium)] ds:text-[var(--foreground)]", children: r })
|
|
585
586
|
]
|
|
586
587
|
}
|
|
587
588
|
);
|
|
588
589
|
}
|
|
589
|
-
function
|
|
590
|
-
const { t: n } =
|
|
590
|
+
function Oe({ time: e }) {
|
|
591
|
+
const { t: n } = C("ui");
|
|
591
592
|
return /* @__PURE__ */ m("span", { className: "type-body-sm ds:text-[var(--muted-foreground)] ds:inline-flex ds:items-center ds:gap-[var(--spacing-xs)]", children: [
|
|
592
593
|
/* @__PURE__ */ t(
|
|
593
|
-
|
|
594
|
+
vt,
|
|
594
595
|
{
|
|
595
596
|
"aria-hidden": "true",
|
|
596
597
|
className: "ds:size-4 ds:text-[var(--primary)]"
|
|
@@ -599,24 +600,24 @@ function He({ time: e }) {
|
|
|
599
600
|
n("practiceResults.nextSlot.summary", { time: e })
|
|
600
601
|
] });
|
|
601
602
|
}
|
|
602
|
-
function
|
|
603
|
+
function De({
|
|
603
604
|
result: e,
|
|
604
605
|
openLabel: n,
|
|
605
|
-
bookLabel:
|
|
606
|
-
nextSlotText:
|
|
607
|
-
onOpenClick:
|
|
608
|
-
onBookClick:
|
|
606
|
+
bookLabel: a,
|
|
607
|
+
nextSlotText: s,
|
|
608
|
+
onOpenClick: r,
|
|
609
|
+
onBookClick: i
|
|
609
610
|
}) {
|
|
610
|
-
const { t:
|
|
611
|
+
const { t: d } = C("ui"), u = e.nextAvailableSlot, l = (u == null ? void 0 : u.bookingHref) ?? e.bookingHref ?? e.href, g = u && s ? d("practiceResults.nextSlot.cta", { time: s }) : a;
|
|
611
612
|
return /* @__PURE__ */ m("div", { className: "ds:mt-[var(--spacing-xs)] ds:flex ds:flex-wrap ds:items-center ds:justify-end ds:gap-[var(--spacing-xs)]", children: [
|
|
612
613
|
n !== void 0 ? /* @__PURE__ */ t(
|
|
613
|
-
|
|
614
|
+
te,
|
|
614
615
|
{
|
|
615
616
|
intent: "secondary",
|
|
616
617
|
size: "sm",
|
|
617
618
|
asChild: !0,
|
|
618
619
|
onClick: (o) => {
|
|
619
|
-
o.stopPropagation(),
|
|
620
|
+
o.stopPropagation(), r();
|
|
620
621
|
},
|
|
621
622
|
children: /* @__PURE__ */ m("a", { href: e.href, "data-component": "practice-result-open-cta", children: [
|
|
622
623
|
n,
|
|
@@ -626,23 +627,23 @@ function Oe({
|
|
|
626
627
|
}
|
|
627
628
|
) : null,
|
|
628
629
|
/* @__PURE__ */ t(
|
|
629
|
-
|
|
630
|
+
te,
|
|
630
631
|
{
|
|
631
632
|
intent: "primary",
|
|
632
633
|
size: "sm",
|
|
633
634
|
asChild: !0,
|
|
634
|
-
startIcon: /* @__PURE__ */ t(
|
|
635
|
+
startIcon: /* @__PURE__ */ t(bt, { "aria-hidden": "true" }),
|
|
635
636
|
onClick: (o) => {
|
|
636
|
-
o.stopPropagation(),
|
|
637
|
+
o.stopPropagation(), i();
|
|
637
638
|
},
|
|
638
639
|
children: /* @__PURE__ */ m(
|
|
639
640
|
"a",
|
|
640
641
|
{
|
|
641
|
-
href:
|
|
642
|
+
href: l,
|
|
642
643
|
"data-component": "practice-result-book-cta",
|
|
643
|
-
"data-slot-aware":
|
|
644
|
+
"data-slot-aware": u ? "true" : void 0,
|
|
644
645
|
children: [
|
|
645
|
-
|
|
646
|
+
g,
|
|
646
647
|
" ",
|
|
647
648
|
/* @__PURE__ */ t("span", { className: "ds:sr-only", children: e.name })
|
|
648
649
|
]
|
|
@@ -652,7 +653,7 @@ function Oe({
|
|
|
652
653
|
)
|
|
653
654
|
] });
|
|
654
655
|
}
|
|
655
|
-
const
|
|
656
|
+
const Ve = V(
|
|
656
657
|
[
|
|
657
658
|
"ds:relative ds:flex ds:w-full ds:cursor-pointer",
|
|
658
659
|
"ds:rounded-[var(--radius-lg)]",
|
|
@@ -680,24 +681,56 @@ const De = j(
|
|
|
680
681
|
},
|
|
681
682
|
defaultVariants: { density: "compact" }
|
|
682
683
|
}
|
|
683
|
-
)
|
|
684
|
-
|
|
684
|
+
), zt = V([
|
|
685
|
+
"ds:text-[var(--foreground)] ds:no-underline ds:hover:underline",
|
|
686
|
+
"ds:rounded-[var(--radius-xs)]",
|
|
687
|
+
"ds:focus-visible:outline-[length:var(--focus-ring-width)] ds:focus-visible:outline-solid",
|
|
688
|
+
"ds:focus-visible:outline-[color:var(--ring)] ds:focus-visible:outline-offset-[length:var(--focus-ring-offset)]",
|
|
689
|
+
"ds:forced-colors:focus-visible:outline-[CanvasText]"
|
|
690
|
+
]);
|
|
691
|
+
function Ke({
|
|
685
692
|
result: e,
|
|
686
|
-
|
|
693
|
+
headingLevel: n
|
|
694
|
+
}) {
|
|
695
|
+
const a = `h${ve(n)}`;
|
|
696
|
+
return /* @__PURE__ */ t(
|
|
697
|
+
a,
|
|
698
|
+
{
|
|
699
|
+
id: `practice-result-${e.id}-name`,
|
|
700
|
+
dir: "auto",
|
|
701
|
+
className: "type-title-card ds:m-0 ds:text-[var(--foreground)]",
|
|
702
|
+
children: /* @__PURE__ */ t(
|
|
703
|
+
"a",
|
|
704
|
+
{
|
|
705
|
+
href: e.href,
|
|
706
|
+
dir: "auto",
|
|
707
|
+
"data-component": "practice-result-name-link",
|
|
708
|
+
className: zt(),
|
|
709
|
+
onClick: (s) => s.stopPropagation(),
|
|
710
|
+
children: e.name
|
|
711
|
+
}
|
|
712
|
+
)
|
|
713
|
+
}
|
|
714
|
+
);
|
|
715
|
+
}
|
|
716
|
+
function Ft({
|
|
717
|
+
result: e,
|
|
718
|
+
headingLevel: n,
|
|
719
|
+
highlighted: a,
|
|
687
720
|
onSelect: s,
|
|
688
721
|
onOpenClick: r,
|
|
689
722
|
onHover: i,
|
|
690
|
-
density:
|
|
691
|
-
openLabel:
|
|
692
|
-
bookLabel:
|
|
693
|
-
onBookClick:
|
|
694
|
-
nextSlotText:
|
|
695
|
-
maxInsuranceChips:
|
|
723
|
+
density: d = "compact",
|
|
724
|
+
openLabel: u,
|
|
725
|
+
bookLabel: l,
|
|
726
|
+
onBookClick: g,
|
|
727
|
+
nextSlotText: o,
|
|
728
|
+
maxInsuranceChips: p = 3,
|
|
696
729
|
maxLanguageChips: f = 4,
|
|
697
|
-
children:
|
|
730
|
+
children: b
|
|
698
731
|
}) {
|
|
699
|
-
var
|
|
700
|
-
const { t:
|
|
732
|
+
var Z, Q, K, E, D, w;
|
|
733
|
+
const { t: h, i18n: y } = C("ui"), k = e.rating, x = (Z = e.location) == null ? void 0 : Z.distanceKm, c = (((Q = e.languages) == null ? void 0 : Q.length) ?? 0) > 0, S = (((K = e.insurances) == null ? void 0 : K.length) ?? 0) > 0, R = e.specializedInFearPatients, L = c || S || R, N = (e.languages ?? []).slice(0, f), _ = (((E = e.languages) == null ? void 0 : E.length) ?? 0) - N.length, A = (e.insurances ?? []).slice(0, p), G = (((D = e.insurances) == null ? void 0 : D.length) ?? 0) - A.length;
|
|
701
734
|
return (
|
|
702
735
|
// eslint-disable-next-line jsx-a11y/no-noninteractive-element-interactions, jsx-a11y/click-events-have-key-events -- card is role="group" by design (axe nested-interactive); click handler is mouse-only sync.
|
|
703
736
|
/* @__PURE__ */ m(
|
|
@@ -705,16 +738,16 @@ function _t({
|
|
|
705
738
|
{
|
|
706
739
|
"data-component": "practice-result-card",
|
|
707
740
|
"data-result-id": e.id,
|
|
708
|
-
"data-highlighted":
|
|
741
|
+
"data-highlighted": a ? "true" : "false",
|
|
709
742
|
role: "group",
|
|
710
743
|
"aria-labelledby": `practice-result-${e.id}-name`,
|
|
711
744
|
onClick: s,
|
|
712
745
|
onMouseEnter: i,
|
|
713
746
|
onFocus: i,
|
|
714
|
-
className:
|
|
747
|
+
className: Ve({ density: d }),
|
|
715
748
|
children: [
|
|
716
749
|
/* @__PURE__ */ t(
|
|
717
|
-
|
|
750
|
+
Se,
|
|
718
751
|
{
|
|
719
752
|
src: e.imageUrl,
|
|
720
753
|
name: e.name,
|
|
@@ -726,74 +759,66 @@ function _t({
|
|
|
726
759
|
/* @__PURE__ */ m("div", { className: "ds:flex ds:min-w-0 ds:flex-1 ds:flex-col ds:gap-[var(--spacing-xs)]", children: [
|
|
727
760
|
/* @__PURE__ */ m("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-2xs)]", children: [
|
|
728
761
|
/* @__PURE__ */ m("div", { className: "ds:flex ds:flex-wrap ds:items-center ds:gap-[var(--spacing-xs)]", children: [
|
|
729
|
-
/* @__PURE__ */ t(
|
|
730
|
-
|
|
731
|
-
{
|
|
732
|
-
id: `practice-result-${e.id}-name`,
|
|
733
|
-
dir: "auto",
|
|
734
|
-
className: "type-title-card ds:text-[var(--foreground)]",
|
|
735
|
-
children: e.name
|
|
736
|
-
}
|
|
737
|
-
),
|
|
738
|
-
C != null ? /* @__PURE__ */ t(ze, { distanceKm: C }) : null
|
|
762
|
+
/* @__PURE__ */ t(Ke, { result: e, headingLevel: n }),
|
|
763
|
+
x != null ? /* @__PURE__ */ t(Fe, { distanceKm: x }) : null
|
|
739
764
|
] }),
|
|
740
765
|
e.subtitle ? /* @__PURE__ */ t("span", { className: "type-body-sm ds:text-[var(--muted-foreground)]", children: e.subtitle }) : null,
|
|
741
|
-
/* @__PURE__ */ t(
|
|
742
|
-
(
|
|
743
|
-
/* @__PURE__ */ t(
|
|
766
|
+
/* @__PURE__ */ t(He, { tagline: e.tagline }),
|
|
767
|
+
(w = e.location) != null && w.address ? /* @__PURE__ */ m("span", { className: "type-meta ds:text-[var(--muted-foreground)] ds:inline-flex ds:items-center ds:gap-[var(--spacing-2xs)]", children: [
|
|
768
|
+
/* @__PURE__ */ t(ae, { "aria-hidden": "true", className: "ds:size-3.5 ds:shrink-0" }),
|
|
744
769
|
/* @__PURE__ */ t("span", { dir: "auto", children: e.location.address })
|
|
745
770
|
] }) : null
|
|
746
771
|
] }),
|
|
747
|
-
|
|
748
|
-
|
|
772
|
+
k && k.count > 0 ? /* @__PURE__ */ t(
|
|
773
|
+
Le,
|
|
749
774
|
{
|
|
750
|
-
value:
|
|
751
|
-
reviews: { count:
|
|
775
|
+
value: k.value,
|
|
776
|
+
reviews: { count: k.count },
|
|
752
777
|
size: "sm"
|
|
753
778
|
}
|
|
754
779
|
) : null,
|
|
755
|
-
|
|
756
|
-
|
|
757
|
-
|
|
780
|
+
L ? /* @__PURE__ */ m("div", { className: "ds:flex ds:flex-wrap ds:items-center ds:gap-[var(--spacing-xs)]", children: [
|
|
781
|
+
N.map((j) => /* @__PURE__ */ t(
|
|
782
|
+
O,
|
|
758
783
|
{
|
|
759
784
|
variant: "neutral",
|
|
760
|
-
leading: /* @__PURE__ */ t(
|
|
761
|
-
children: Ie(
|
|
785
|
+
leading: /* @__PURE__ */ t(Ae, { "aria-hidden": "true" }),
|
|
786
|
+
children: Ie(j, h, y)
|
|
762
787
|
},
|
|
763
|
-
`lang-${
|
|
788
|
+
`lang-${j}`
|
|
764
789
|
)),
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
790
|
+
_ > 0 ? /* @__PURE__ */ t(O, { variant: "neutral", children: `+${_}` }) : null,
|
|
791
|
+
A.map((j) => /* @__PURE__ */ t(
|
|
792
|
+
O,
|
|
768
793
|
{
|
|
769
794
|
variant: "info",
|
|
770
|
-
leading: /* @__PURE__ */ t(
|
|
771
|
-
children:
|
|
795
|
+
leading: /* @__PURE__ */ t(Me, { "aria-hidden": "true" }),
|
|
796
|
+
children: j
|
|
772
797
|
},
|
|
773
|
-
`ins-${
|
|
798
|
+
`ins-${j}`
|
|
774
799
|
)),
|
|
775
|
-
|
|
776
|
-
|
|
800
|
+
G > 0 ? /* @__PURE__ */ t(O, { variant: "neutral", children: `+${G}` }) : null,
|
|
801
|
+
R ? /* @__PURE__ */ t(O, { variant: "info", leading: /* @__PURE__ */ t(Te, { "aria-hidden": "true" }), children: h("practiceResults.fearPatient.label") }) : null
|
|
777
802
|
] }) : null,
|
|
778
|
-
/* @__PURE__ */ t(
|
|
803
|
+
/* @__PURE__ */ t(Be, { description: e.description, density: "compact" }),
|
|
779
804
|
/* @__PURE__ */ t(
|
|
780
|
-
|
|
805
|
+
$e,
|
|
781
806
|
{
|
|
782
807
|
cents: e.firstVisitPriceCents,
|
|
783
808
|
currencyCode: e.currencyCode
|
|
784
809
|
}
|
|
785
810
|
),
|
|
786
|
-
e.nextAvailableSlot &&
|
|
787
|
-
|
|
811
|
+
e.nextAvailableSlot && o ? /* @__PURE__ */ t(Oe, { time: o }) : null,
|
|
812
|
+
b,
|
|
788
813
|
/* @__PURE__ */ t(
|
|
789
|
-
|
|
814
|
+
De,
|
|
790
815
|
{
|
|
791
816
|
result: e,
|
|
792
|
-
openLabel:
|
|
793
|
-
bookLabel:
|
|
794
|
-
nextSlotText:
|
|
817
|
+
openLabel: u,
|
|
818
|
+
bookLabel: l,
|
|
819
|
+
nextSlotText: o,
|
|
795
820
|
onOpenClick: r,
|
|
796
|
-
onBookClick:
|
|
821
|
+
onBookClick: g
|
|
797
822
|
}
|
|
798
823
|
)
|
|
799
824
|
] })
|
|
@@ -802,22 +827,23 @@ function _t({
|
|
|
802
827
|
)
|
|
803
828
|
);
|
|
804
829
|
}
|
|
805
|
-
function
|
|
830
|
+
function Ht({
|
|
806
831
|
result: e,
|
|
807
|
-
|
|
832
|
+
headingLevel: n,
|
|
833
|
+
apiKey: a,
|
|
808
834
|
highlighted: s,
|
|
809
835
|
onSelect: r,
|
|
810
836
|
onOpenClick: i,
|
|
811
|
-
onBookClick:
|
|
812
|
-
onHover:
|
|
813
|
-
openLabel:
|
|
814
|
-
bookLabel:
|
|
837
|
+
onBookClick: d,
|
|
838
|
+
onHover: u,
|
|
839
|
+
openLabel: l,
|
|
840
|
+
bookLabel: g
|
|
815
841
|
}) {
|
|
816
|
-
var
|
|
817
|
-
const { t:
|
|
842
|
+
var c, S, R, L;
|
|
843
|
+
const { t: o, i18n: p } = C("ui"), f = M(() => {
|
|
818
844
|
if (e.nextAvailableSlot)
|
|
819
845
|
try {
|
|
820
|
-
return new Intl.DateTimeFormat(
|
|
846
|
+
return new Intl.DateTimeFormat(p.language, {
|
|
821
847
|
weekday: "short",
|
|
822
848
|
hour: "numeric",
|
|
823
849
|
minute: "numeric"
|
|
@@ -825,7 +851,7 @@ function Tt({
|
|
|
825
851
|
} catch {
|
|
826
852
|
return e.nextAvailableSlot.dateTime;
|
|
827
853
|
}
|
|
828
|
-
}, [e.nextAvailableSlot,
|
|
854
|
+
}, [e.nextAvailableSlot, p.language]), b = (((c = e.languages) == null ? void 0 : c.length) ?? 0) > 0, h = (((S = e.insurances) == null ? void 0 : S.length) ?? 0) > 0, y = e.specializedInFearPatients, k = b || h || y, x = (R = e.location) == null ? void 0 : R.distanceKm;
|
|
829
855
|
return (
|
|
830
856
|
// eslint-disable-next-line jsx-a11y/no-noninteractive-element-interactions, jsx-a11y/click-events-have-key-events -- card is role="group" by design (axe nested-interactive); click handler is mouse-only sync.
|
|
831
857
|
/* @__PURE__ */ m(
|
|
@@ -838,14 +864,14 @@ function Tt({
|
|
|
838
864
|
role: "group",
|
|
839
865
|
"aria-labelledby": `practice-result-${e.id}-name`,
|
|
840
866
|
onClick: r,
|
|
841
|
-
onMouseEnter:
|
|
842
|
-
onFocus:
|
|
843
|
-
className:
|
|
867
|
+
onMouseEnter: u,
|
|
868
|
+
onFocus: u,
|
|
869
|
+
className: Ve({ density: "rich" }),
|
|
844
870
|
children: [
|
|
845
871
|
e.location ? /* @__PURE__ */ t(
|
|
846
|
-
|
|
872
|
+
It,
|
|
847
873
|
{
|
|
848
|
-
apiKey:
|
|
874
|
+
apiKey: a,
|
|
849
875
|
center: {
|
|
850
876
|
lat: e.location.lat,
|
|
851
877
|
lng: e.location.lng
|
|
@@ -856,7 +882,7 @@ function Tt({
|
|
|
856
882
|
/* @__PURE__ */ m("div", { className: "ds:flex ds:min-w-0 ds:flex-1 ds:flex-col ds:gap-[var(--spacing-sm)]", children: [
|
|
857
883
|
/* @__PURE__ */ m("div", { className: "ds:flex ds:items-start ds:gap-[var(--spacing-md)]", children: [
|
|
858
884
|
/* @__PURE__ */ t(
|
|
859
|
-
|
|
885
|
+
Se,
|
|
860
886
|
{
|
|
861
887
|
src: e.imageUrl,
|
|
862
888
|
name: e.name,
|
|
@@ -867,22 +893,14 @@ function Tt({
|
|
|
867
893
|
),
|
|
868
894
|
/* @__PURE__ */ m("div", { className: "ds:flex ds:min-w-0 ds:flex-1 ds:flex-col ds:gap-[var(--spacing-2xs)]", children: [
|
|
869
895
|
/* @__PURE__ */ m("div", { className: "ds:flex ds:flex-wrap ds:items-center ds:gap-[var(--spacing-xs)]", children: [
|
|
870
|
-
/* @__PURE__ */ t(
|
|
871
|
-
|
|
872
|
-
{
|
|
873
|
-
id: `practice-result-${e.id}-name`,
|
|
874
|
-
dir: "auto",
|
|
875
|
-
className: "type-title-card ds:text-[var(--foreground)]",
|
|
876
|
-
children: e.name
|
|
877
|
-
}
|
|
878
|
-
),
|
|
879
|
-
C != null ? /* @__PURE__ */ t(ze, { distanceKm: C }) : null
|
|
896
|
+
/* @__PURE__ */ t(Ke, { result: e, headingLevel: n }),
|
|
897
|
+
x != null ? /* @__PURE__ */ t(Fe, { distanceKm: x }) : null
|
|
880
898
|
] }),
|
|
881
899
|
e.subtitle ? /* @__PURE__ */ t("span", { className: "type-body-sm ds:text-[var(--muted-foreground)]", children: e.subtitle }) : null,
|
|
882
|
-
/* @__PURE__ */ t(
|
|
883
|
-
(
|
|
900
|
+
/* @__PURE__ */ t(He, { tagline: e.tagline }),
|
|
901
|
+
(L = e.location) != null && L.address ? /* @__PURE__ */ m("span", { className: "type-meta ds:text-[var(--muted-foreground)] ds:inline-flex ds:items-center ds:gap-[var(--spacing-2xs)]", children: [
|
|
884
902
|
/* @__PURE__ */ t(
|
|
885
|
-
|
|
903
|
+
ae,
|
|
886
904
|
{
|
|
887
905
|
"aria-hidden": "true",
|
|
888
906
|
className: "ds:size-3.5 ds:shrink-0"
|
|
@@ -892,7 +910,7 @@ function Tt({
|
|
|
892
910
|
] }) : null
|
|
893
911
|
] }),
|
|
894
912
|
e.rating && e.rating.count > 0 ? /* @__PURE__ */ t(
|
|
895
|
-
|
|
913
|
+
Le,
|
|
896
914
|
{
|
|
897
915
|
value: e.rating.value,
|
|
898
916
|
reviews: { count: e.rating.count },
|
|
@@ -900,45 +918,45 @@ function Tt({
|
|
|
900
918
|
}
|
|
901
919
|
) : null
|
|
902
920
|
] }),
|
|
903
|
-
|
|
904
|
-
|
|
905
|
-
|
|
921
|
+
k ? /* @__PURE__ */ m("div", { className: "ds:flex ds:flex-wrap ds:items-center ds:gap-[var(--spacing-xs)]", children: [
|
|
922
|
+
b ? (e.languages ?? []).map((N) => /* @__PURE__ */ t(
|
|
923
|
+
O,
|
|
906
924
|
{
|
|
907
925
|
variant: "neutral",
|
|
908
|
-
leading: /* @__PURE__ */ t(
|
|
909
|
-
children: Ie(
|
|
926
|
+
leading: /* @__PURE__ */ t(Ae, { "aria-hidden": "true" }),
|
|
927
|
+
children: Ie(N, o, p)
|
|
910
928
|
},
|
|
911
|
-
`lang-${
|
|
929
|
+
`lang-${N}`
|
|
912
930
|
)) : null,
|
|
913
|
-
|
|
914
|
-
|
|
931
|
+
h ? (e.insurances ?? []).map((N) => /* @__PURE__ */ t(
|
|
932
|
+
O,
|
|
915
933
|
{
|
|
916
934
|
variant: "info",
|
|
917
|
-
leading: /* @__PURE__ */ t(
|
|
918
|
-
children:
|
|
935
|
+
leading: /* @__PURE__ */ t(Me, { "aria-hidden": "true" }),
|
|
936
|
+
children: N
|
|
919
937
|
},
|
|
920
|
-
`ins-${
|
|
938
|
+
`ins-${N}`
|
|
921
939
|
)) : null,
|
|
922
|
-
|
|
940
|
+
y ? /* @__PURE__ */ t(O, { variant: "info", leading: /* @__PURE__ */ t(Te, { "aria-hidden": "true" }), children: o("practiceResults.fearPatient.label") }) : null
|
|
923
941
|
] }) : null,
|
|
924
|
-
/* @__PURE__ */ t(
|
|
942
|
+
/* @__PURE__ */ t(Be, { description: e.description, density: "rich" }),
|
|
925
943
|
/* @__PURE__ */ t(
|
|
926
|
-
|
|
944
|
+
$e,
|
|
927
945
|
{
|
|
928
946
|
cents: e.firstVisitPriceCents,
|
|
929
947
|
currencyCode: e.currencyCode
|
|
930
948
|
}
|
|
931
949
|
),
|
|
932
|
-
e.nextAvailableSlot && f ? /* @__PURE__ */ t(
|
|
950
|
+
e.nextAvailableSlot && f ? /* @__PURE__ */ t(Oe, { time: f }) : null,
|
|
933
951
|
/* @__PURE__ */ t(
|
|
934
|
-
|
|
952
|
+
De,
|
|
935
953
|
{
|
|
936
954
|
result: e,
|
|
937
|
-
openLabel:
|
|
938
|
-
bookLabel:
|
|
955
|
+
openLabel: l,
|
|
956
|
+
bookLabel: g,
|
|
939
957
|
nextSlotText: f,
|
|
940
958
|
onOpenClick: i,
|
|
941
|
-
onBookClick:
|
|
959
|
+
onBookClick: d
|
|
942
960
|
}
|
|
943
961
|
)
|
|
944
962
|
] })
|
|
@@ -947,97 +965,100 @@ function Tt({
|
|
|
947
965
|
)
|
|
948
966
|
);
|
|
949
967
|
}
|
|
950
|
-
function
|
|
968
|
+
function he({
|
|
951
969
|
results: e,
|
|
952
|
-
|
|
970
|
+
headingLevel: n,
|
|
971
|
+
highlightedId: a,
|
|
953
972
|
onCardHover: s,
|
|
954
973
|
onCardSelect: r,
|
|
955
974
|
onCardOpenClick: i,
|
|
956
|
-
onCardBookClick:
|
|
957
|
-
openLabel:
|
|
958
|
-
bookLabel:
|
|
959
|
-
formatNextSlot:
|
|
960
|
-
onLoadMore:
|
|
961
|
-
loadingMore:
|
|
975
|
+
onCardBookClick: d,
|
|
976
|
+
openLabel: u,
|
|
977
|
+
bookLabel: l,
|
|
978
|
+
formatNextSlot: g,
|
|
979
|
+
onLoadMore: o,
|
|
980
|
+
loadingMore: p,
|
|
962
981
|
loadingSkeletons: f,
|
|
963
|
-
density:
|
|
964
|
-
apiKey:
|
|
965
|
-
containerRef:
|
|
982
|
+
density: b = "compact",
|
|
983
|
+
apiKey: h,
|
|
984
|
+
containerRef: y
|
|
966
985
|
}) {
|
|
967
|
-
const { t:
|
|
968
|
-
return
|
|
969
|
-
if (!
|
|
970
|
-
const
|
|
971
|
-
if (!
|
|
972
|
-
const
|
|
973
|
-
(
|
|
974
|
-
for (const
|
|
975
|
-
|
|
986
|
+
const { t: k } = C("ui"), x = T(null);
|
|
987
|
+
return X(() => {
|
|
988
|
+
if (!o) return;
|
|
989
|
+
const c = x.current;
|
|
990
|
+
if (!c || typeof IntersectionObserver > "u") return;
|
|
991
|
+
const S = new IntersectionObserver(
|
|
992
|
+
(R) => {
|
|
993
|
+
for (const L of R)
|
|
994
|
+
L.isIntersecting && (H("serp_load_more", {
|
|
976
995
|
currentCount: e.length
|
|
977
|
-
}),
|
|
996
|
+
}), o());
|
|
978
997
|
},
|
|
979
998
|
{ root: null, rootMargin: "200px" }
|
|
980
999
|
);
|
|
981
|
-
return
|
|
982
|
-
}, [
|
|
1000
|
+
return S.observe(c), () => S.disconnect();
|
|
1001
|
+
}, [o, e.length]), f ? /* @__PURE__ */ t(
|
|
983
1002
|
"div",
|
|
984
1003
|
{
|
|
985
1004
|
role: "status",
|
|
986
1005
|
"aria-live": "polite",
|
|
987
|
-
"aria-label":
|
|
1006
|
+
"aria-label": k("practiceResults.loading"),
|
|
988
1007
|
className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)]",
|
|
989
|
-
children: Array.from({ length: 4 }).map((
|
|
990
|
-
|
|
1008
|
+
children: Array.from({ length: 4 }).map((c, S) => /* @__PURE__ */ t(
|
|
1009
|
+
ct,
|
|
991
1010
|
{
|
|
992
1011
|
variant: "rounded",
|
|
993
|
-
height:
|
|
1012
|
+
height: b === "rich" ? "11rem" : "7rem"
|
|
994
1013
|
},
|
|
995
|
-
`pr-skel-${
|
|
1014
|
+
`pr-skel-${S}`
|
|
996
1015
|
))
|
|
997
1016
|
}
|
|
998
1017
|
) : /* @__PURE__ */ m(
|
|
999
1018
|
"div",
|
|
1000
1019
|
{
|
|
1001
|
-
ref:
|
|
1020
|
+
ref: y,
|
|
1002
1021
|
"data-component": "practice-results-list",
|
|
1003
1022
|
role: "list",
|
|
1004
|
-
"aria-label":
|
|
1023
|
+
"aria-label": k("practiceResults.list.label"),
|
|
1005
1024
|
className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)] ds:overflow-y-auto",
|
|
1006
1025
|
children: [
|
|
1007
|
-
e.map((
|
|
1008
|
-
|
|
1026
|
+
e.map((c) => /* @__PURE__ */ t("div", { role: "listitem", children: b === "rich" ? /* @__PURE__ */ t(
|
|
1027
|
+
Ht,
|
|
1009
1028
|
{
|
|
1010
|
-
result:
|
|
1011
|
-
|
|
1012
|
-
|
|
1013
|
-
|
|
1014
|
-
|
|
1015
|
-
|
|
1016
|
-
|
|
1017
|
-
|
|
1018
|
-
|
|
1029
|
+
result: c,
|
|
1030
|
+
headingLevel: n,
|
|
1031
|
+
apiKey: h,
|
|
1032
|
+
highlighted: a === c.id,
|
|
1033
|
+
onSelect: () => r(c.id),
|
|
1034
|
+
onOpenClick: () => i(c.id),
|
|
1035
|
+
onBookClick: () => d(c.id),
|
|
1036
|
+
onHover: () => s(c.id),
|
|
1037
|
+
openLabel: u,
|
|
1038
|
+
bookLabel: l
|
|
1019
1039
|
}
|
|
1020
1040
|
) : /* @__PURE__ */ t(
|
|
1021
|
-
|
|
1041
|
+
Ft,
|
|
1022
1042
|
{
|
|
1023
|
-
result:
|
|
1024
|
-
|
|
1025
|
-
|
|
1026
|
-
|
|
1027
|
-
|
|
1028
|
-
|
|
1029
|
-
|
|
1030
|
-
|
|
1031
|
-
|
|
1043
|
+
result: c,
|
|
1044
|
+
headingLevel: n,
|
|
1045
|
+
highlighted: a === c.id,
|
|
1046
|
+
onSelect: () => r(c.id),
|
|
1047
|
+
onOpenClick: () => i(c.id),
|
|
1048
|
+
onBookClick: () => d(c.id),
|
|
1049
|
+
onHover: () => s(c.id),
|
|
1050
|
+
openLabel: u,
|
|
1051
|
+
bookLabel: l,
|
|
1052
|
+
nextSlotText: g(c)
|
|
1032
1053
|
}
|
|
1033
|
-
) },
|
|
1034
|
-
|
|
1054
|
+
) }, c.id)),
|
|
1055
|
+
o ? /* @__PURE__ */ t(
|
|
1035
1056
|
"div",
|
|
1036
1057
|
{
|
|
1037
|
-
ref:
|
|
1058
|
+
ref: x,
|
|
1038
1059
|
"aria-hidden": "true",
|
|
1039
1060
|
className: "ds:flex ds:items-center ds:justify-center ds:py-[var(--spacing-md)]",
|
|
1040
|
-
children:
|
|
1061
|
+
children: p ? /* @__PURE__ */ t(dt, { size: "md", variant: "pulse" }) : /* @__PURE__ */ t("span", { className: "ds:size-1" })
|
|
1041
1062
|
}
|
|
1042
1063
|
) : null
|
|
1043
1064
|
]
|
|
@@ -1047,71 +1068,71 @@ function fe({
|
|
|
1047
1068
|
function pe({
|
|
1048
1069
|
results: e,
|
|
1049
1070
|
searchCentre: n,
|
|
1050
|
-
zoom:
|
|
1051
|
-
apiKey:
|
|
1052
|
-
mapId:
|
|
1053
|
-
highlightedId:
|
|
1054
|
-
onPinClick:
|
|
1055
|
-
onPinHover:
|
|
1056
|
-
onPinFirstInteract:
|
|
1057
|
-
onBoundsChange:
|
|
1071
|
+
zoom: a,
|
|
1072
|
+
apiKey: s,
|
|
1073
|
+
mapId: r,
|
|
1074
|
+
highlightedId: i,
|
|
1075
|
+
onPinClick: d,
|
|
1076
|
+
onPinHover: u,
|
|
1077
|
+
onPinFirstInteract: l,
|
|
1078
|
+
onBoundsChange: g,
|
|
1058
1079
|
consentGranted: o,
|
|
1059
|
-
onConsentRequest:
|
|
1060
|
-
mapHandleRef:
|
|
1080
|
+
onConsentRequest: p,
|
|
1081
|
+
mapHandleRef: f
|
|
1061
1082
|
}) {
|
|
1062
|
-
const { t:
|
|
1083
|
+
const { t: b } = C("ui"), h = M(
|
|
1063
1084
|
() => e.filter(
|
|
1064
|
-
(
|
|
1065
|
-
).map((
|
|
1066
|
-
id:
|
|
1085
|
+
(c) => !!c.location
|
|
1086
|
+
).map((c) => ({
|
|
1087
|
+
id: c.id,
|
|
1067
1088
|
position: {
|
|
1068
|
-
lat:
|
|
1069
|
-
lng:
|
|
1089
|
+
lat: c.location.lat,
|
|
1090
|
+
lng: c.location.lng
|
|
1070
1091
|
},
|
|
1071
|
-
label:
|
|
1092
|
+
label: c.name
|
|
1072
1093
|
})),
|
|
1073
1094
|
[e]
|
|
1074
1095
|
), y = M(
|
|
1075
|
-
() =>
|
|
1076
|
-
[
|
|
1077
|
-
),
|
|
1078
|
-
() =>
|
|
1079
|
-
[
|
|
1080
|
-
),
|
|
1096
|
+
() => h.map((c) => ({ ...c.position, id: c.id })),
|
|
1097
|
+
[h]
|
|
1098
|
+
), k = M(
|
|
1099
|
+
() => h.map((c) => c.id).sort().join("|"),
|
|
1100
|
+
[h]
|
|
1101
|
+
), x = M(() => {
|
|
1081
1102
|
if (n) return n;
|
|
1082
|
-
const
|
|
1083
|
-
return
|
|
1084
|
-
lat: (
|
|
1085
|
-
lng: (
|
|
1103
|
+
const c = Re(e);
|
|
1104
|
+
return c ? {
|
|
1105
|
+
lat: (c.north + c.south) / 2,
|
|
1106
|
+
lng: (c.east + c.west) / 2
|
|
1086
1107
|
} : { lat: 45.4642, lng: 9.19 };
|
|
1087
1108
|
}, [e, n]);
|
|
1088
|
-
return
|
|
1089
|
-
if (!
|
|
1090
|
-
const
|
|
1091
|
-
|
|
1092
|
-
}, [e,
|
|
1109
|
+
return X(() => {
|
|
1110
|
+
if (!g) return;
|
|
1111
|
+
const c = Re(e);
|
|
1112
|
+
c && (g(c), H("serp_map_panned", { bounds: c }));
|
|
1113
|
+
}, [e, g]), /* @__PURE__ */ t(
|
|
1093
1114
|
"div",
|
|
1094
1115
|
{
|
|
1095
1116
|
"data-component": "practice-results-map-panel",
|
|
1096
1117
|
className: "ds:relative ds:flex ds:size-full ds:min-h-[24rem] ds:flex-col",
|
|
1097
1118
|
children: /* @__PURE__ */ t(
|
|
1098
|
-
|
|
1119
|
+
lt,
|
|
1099
1120
|
{
|
|
1100
|
-
ref:
|
|
1101
|
-
apiKey:
|
|
1102
|
-
mapId:
|
|
1103
|
-
center:
|
|
1104
|
-
zoom:
|
|
1105
|
-
markers:
|
|
1121
|
+
ref: f,
|
|
1122
|
+
apiKey: s ?? "",
|
|
1123
|
+
mapId: r,
|
|
1124
|
+
center: x,
|
|
1125
|
+
zoom: a,
|
|
1126
|
+
markers: h,
|
|
1106
1127
|
fitToPoints: y,
|
|
1107
|
-
fitKey:
|
|
1108
|
-
selectedMarkerId:
|
|
1128
|
+
fitKey: k,
|
|
1129
|
+
selectedMarkerId: i,
|
|
1109
1130
|
consentGranted: !!o,
|
|
1110
|
-
onConsentRequest:
|
|
1111
|
-
onMarkerClick: (
|
|
1112
|
-
|
|
1131
|
+
onConsentRequest: p,
|
|
1132
|
+
onMarkerClick: (c) => {
|
|
1133
|
+
c != null && (u(c), l(c), d(c));
|
|
1113
1134
|
},
|
|
1114
|
-
ariaLabel:
|
|
1135
|
+
ariaLabel: b("practiceResults.map.label"),
|
|
1115
1136
|
size: "fill",
|
|
1116
1137
|
surface: "bordered",
|
|
1117
1138
|
className: "ds:size-full"
|
|
@@ -1120,324 +1141,336 @@ function pe({
|
|
|
1120
1141
|
}
|
|
1121
1142
|
);
|
|
1122
1143
|
}
|
|
1123
|
-
function
|
|
1144
|
+
function ge({
|
|
1124
1145
|
variantBodyProps: e
|
|
1125
1146
|
}) {
|
|
1126
|
-
const { facets: n, value:
|
|
1147
|
+
const { facets: n, value: a, onChange: s, heading: r, intro: i, totalCount: d, searchCentre: u } = e;
|
|
1127
1148
|
return /* @__PURE__ */ m("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-sm)]", children: [
|
|
1128
1149
|
/* @__PURE__ */ t(
|
|
1129
1150
|
_e,
|
|
1130
1151
|
{
|
|
1131
|
-
heading:
|
|
1132
|
-
|
|
1133
|
-
|
|
1134
|
-
|
|
1152
|
+
heading: r,
|
|
1153
|
+
headingLevel: e.headingLevel,
|
|
1154
|
+
intro: i,
|
|
1155
|
+
totalCount: d,
|
|
1156
|
+
searchCentreLabel: u == null ? void 0 : u.label
|
|
1135
1157
|
}
|
|
1136
1158
|
),
|
|
1137
1159
|
n.length > 0 ? /* @__PURE__ */ m("div", { className: "ds:flex ds:flex-wrap ds:items-center ds:justify-between ds:gap-[var(--spacing-sm)]", children: [
|
|
1138
1160
|
/* @__PURE__ */ t(
|
|
1139
|
-
|
|
1161
|
+
ze,
|
|
1140
1162
|
{
|
|
1141
1163
|
facets: n,
|
|
1142
|
-
value:
|
|
1143
|
-
onChange: (
|
|
1164
|
+
value: a.facets,
|
|
1165
|
+
onChange: (l) => s({ ...a, facets: l })
|
|
1144
1166
|
}
|
|
1145
1167
|
),
|
|
1146
1168
|
/* @__PURE__ */ t(
|
|
1147
|
-
|
|
1169
|
+
me,
|
|
1148
1170
|
{
|
|
1149
|
-
value:
|
|
1150
|
-
onChange: (
|
|
1171
|
+
value: a.sort ?? "relevance",
|
|
1172
|
+
onChange: (l) => s({ ...a, sort: l })
|
|
1151
1173
|
}
|
|
1152
1174
|
)
|
|
1153
1175
|
] }) : /* @__PURE__ */ t("div", { className: "ds:flex ds:justify-end", children: /* @__PURE__ */ t(
|
|
1154
|
-
|
|
1176
|
+
me,
|
|
1155
1177
|
{
|
|
1156
|
-
value:
|
|
1157
|
-
onChange: (
|
|
1178
|
+
value: a.sort ?? "relevance",
|
|
1179
|
+
onChange: (l) => s({ ...a, sort: l })
|
|
1158
1180
|
}
|
|
1159
1181
|
) })
|
|
1160
1182
|
] });
|
|
1161
1183
|
}
|
|
1162
|
-
function
|
|
1163
|
-
|
|
1184
|
+
function ve(e) {
|
|
1185
|
+
return Math.min(e + 1, 6);
|
|
1186
|
+
}
|
|
1187
|
+
function be({
|
|
1188
|
+
headingLevel: e
|
|
1189
|
+
}) {
|
|
1190
|
+
const { t: n } = C("ui");
|
|
1164
1191
|
return /* @__PURE__ */ t(
|
|
1165
|
-
|
|
1192
|
+
ot,
|
|
1166
1193
|
{
|
|
1167
1194
|
variant: "no-results",
|
|
1168
|
-
|
|
1169
|
-
|
|
1195
|
+
headingLevel: ve(e),
|
|
1196
|
+
title: n("practiceResults.empty.title"),
|
|
1197
|
+
description: n("practiceResults.empty.description")
|
|
1170
1198
|
}
|
|
1171
1199
|
);
|
|
1172
1200
|
}
|
|
1173
|
-
function
|
|
1174
|
-
|
|
1175
|
-
|
|
1176
|
-
|
|
1177
|
-
|
|
1178
|
-
|
|
1179
|
-
|
|
1201
|
+
function ye({
|
|
1202
|
+
onRetry: e,
|
|
1203
|
+
headingLevel: n
|
|
1204
|
+
}) {
|
|
1205
|
+
const { t: a } = C("ui"), s = ve(n);
|
|
1206
|
+
return /* @__PURE__ */ m(ee, { variant: "error", children: [
|
|
1207
|
+
/* @__PURE__ */ t(ee.Title, { as: `h${s}`, children: a("practiceResults.error.title") }),
|
|
1208
|
+
/* @__PURE__ */ t(ee.Description, { children: a("practiceResults.error.description") }),
|
|
1209
|
+
e ? /* @__PURE__ */ t(ee.Action, { children: /* @__PURE__ */ t(
|
|
1210
|
+
te,
|
|
1180
1211
|
{
|
|
1181
1212
|
intent: "secondary",
|
|
1182
1213
|
size: "sm",
|
|
1183
|
-
startIcon: /* @__PURE__ */ t(
|
|
1214
|
+
startIcon: /* @__PURE__ */ t(ht, { "aria-hidden": "true" }),
|
|
1184
1215
|
onClick: e,
|
|
1185
|
-
children:
|
|
1216
|
+
children: a("practiceResults.error.retry")
|
|
1186
1217
|
}
|
|
1187
1218
|
) }) : null
|
|
1188
1219
|
] });
|
|
1189
1220
|
}
|
|
1190
|
-
function
|
|
1221
|
+
function Bt(e) {
|
|
1191
1222
|
const {
|
|
1192
1223
|
results: n,
|
|
1193
|
-
apiKey:
|
|
1194
|
-
mapId:
|
|
1195
|
-
zoom:
|
|
1196
|
-
searchCentre:
|
|
1197
|
-
onLoadMore:
|
|
1198
|
-
loadingMore:
|
|
1199
|
-
loadingSkeletons:
|
|
1200
|
-
emptyResultsSlot:
|
|
1224
|
+
apiKey: a,
|
|
1225
|
+
mapId: s,
|
|
1226
|
+
zoom: r,
|
|
1227
|
+
searchCentre: i,
|
|
1228
|
+
onLoadMore: d,
|
|
1229
|
+
loadingMore: u,
|
|
1230
|
+
loadingSkeletons: l,
|
|
1231
|
+
emptyResultsSlot: g,
|
|
1201
1232
|
errorSlot: o,
|
|
1202
|
-
error:
|
|
1203
|
-
onRetry:
|
|
1204
|
-
highlightedId:
|
|
1205
|
-
onCardHover:
|
|
1233
|
+
error: p,
|
|
1234
|
+
onRetry: f,
|
|
1235
|
+
highlightedId: b,
|
|
1236
|
+
onCardHover: h,
|
|
1206
1237
|
onPinClick: y,
|
|
1207
|
-
consentGranted:
|
|
1208
|
-
onConsentRequest:
|
|
1209
|
-
onBoundsChange:
|
|
1210
|
-
listContainerRef:
|
|
1211
|
-
} = e, { t:
|
|
1212
|
-
|
|
1238
|
+
consentGranted: k,
|
|
1239
|
+
onConsentRequest: x,
|
|
1240
|
+
onBoundsChange: c,
|
|
1241
|
+
listContainerRef: S
|
|
1242
|
+
} = e, { t: R } = C("ui"), [L, N] = fe(!1), _ = p ? o ?? /* @__PURE__ */ t(ye, { onRetry: f, headingLevel: e.headingLevel }) : n.length === 0 && !l ? g ?? /* @__PURE__ */ t(be, { headingLevel: e.headingLevel }) : /* @__PURE__ */ t(
|
|
1243
|
+
he,
|
|
1213
1244
|
{
|
|
1214
1245
|
results: n,
|
|
1215
|
-
|
|
1216
|
-
|
|
1246
|
+
headingLevel: e.headingLevel,
|
|
1247
|
+
highlightedId: b,
|
|
1248
|
+
onCardHover: h,
|
|
1217
1249
|
onCardSelect: e.onCardSelect,
|
|
1218
1250
|
onCardOpenClick: e.onCardOpenClick,
|
|
1219
1251
|
onCardBookClick: e.onCardBookClick,
|
|
1220
1252
|
openLabel: e.openLabel,
|
|
1221
1253
|
bookLabel: e.bookLabel,
|
|
1222
1254
|
formatNextSlot: e.formatNextSlot,
|
|
1223
|
-
onLoadMore:
|
|
1224
|
-
loadingMore:
|
|
1225
|
-
loadingSkeletons:
|
|
1255
|
+
onLoadMore: d,
|
|
1256
|
+
loadingMore: u,
|
|
1257
|
+
loadingSkeletons: l,
|
|
1226
1258
|
density: "compact",
|
|
1227
|
-
containerRef:
|
|
1259
|
+
containerRef: S
|
|
1228
1260
|
}
|
|
1229
1261
|
);
|
|
1230
1262
|
return /* @__PURE__ */ m("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)]", children: [
|
|
1231
|
-
/* @__PURE__ */ t(
|
|
1263
|
+
/* @__PURE__ */ t(ge, { variantBodyProps: e }),
|
|
1232
1264
|
/* @__PURE__ */ m("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)] ds:lg:grid ds:lg:grid-cols-[55fr_45fr] ds:lg:gap-[var(--spacing-lg)] ds:lg:items-start", children: [
|
|
1233
|
-
/* @__PURE__ */ t("div", { className: "ds:min-w-0", children:
|
|
1265
|
+
/* @__PURE__ */ t("div", { className: "ds:min-w-0", children: _ }),
|
|
1234
1266
|
/* @__PURE__ */ t("div", { className: "ds:hidden ds:lg:block ds:sticky ds:top-[var(--spacing-md)] ds:h-[40rem]", children: /* @__PURE__ */ t(
|
|
1235
1267
|
pe,
|
|
1236
1268
|
{
|
|
1237
1269
|
results: n,
|
|
1238
|
-
searchCentre:
|
|
1239
|
-
zoom:
|
|
1240
|
-
apiKey:
|
|
1241
|
-
mapId:
|
|
1242
|
-
highlightedId:
|
|
1270
|
+
searchCentre: i,
|
|
1271
|
+
zoom: r,
|
|
1272
|
+
apiKey: a,
|
|
1273
|
+
mapId: s,
|
|
1274
|
+
highlightedId: b,
|
|
1243
1275
|
onPinClick: (A) => {
|
|
1244
|
-
|
|
1276
|
+
J(n, A, "pin", e.onResultSelect), y(A);
|
|
1245
1277
|
},
|
|
1246
|
-
onPinHover:
|
|
1278
|
+
onPinHover: h,
|
|
1247
1279
|
onPinFirstInteract: e.onPinFirstInteract,
|
|
1248
|
-
onBoundsChange:
|
|
1249
|
-
consentGranted:
|
|
1250
|
-
onConsentRequest:
|
|
1280
|
+
onBoundsChange: c,
|
|
1281
|
+
consentGranted: k,
|
|
1282
|
+
onConsentRequest: x,
|
|
1251
1283
|
mapHandleRef: e.mapHandleRef
|
|
1252
1284
|
}
|
|
1253
1285
|
) })
|
|
1254
1286
|
] }),
|
|
1255
1287
|
/* @__PURE__ */ t("div", { className: "ds:flex ds:lg:hidden ds:sticky ds:bottom-[var(--spacing-md)] ds:justify-center", children: /* @__PURE__ */ t(
|
|
1256
|
-
|
|
1288
|
+
te,
|
|
1257
1289
|
{
|
|
1258
1290
|
intent: "primary",
|
|
1259
1291
|
size: "md",
|
|
1260
|
-
startIcon: /* @__PURE__ */ t(
|
|
1261
|
-
onClick: () =>
|
|
1262
|
-
children:
|
|
1292
|
+
startIcon: /* @__PURE__ */ t(xt, { "aria-hidden": "true" }),
|
|
1293
|
+
onClick: () => N(!0),
|
|
1294
|
+
children: R("practiceResults.viewMap")
|
|
1263
1295
|
}
|
|
1264
1296
|
) }),
|
|
1265
|
-
/* @__PURE__ */ t(
|
|
1266
|
-
/* @__PURE__ */ t(
|
|
1267
|
-
/* @__PURE__ */ m(
|
|
1268
|
-
/* @__PURE__ */ t(
|
|
1297
|
+
/* @__PURE__ */ t(I.Root, { open: L, onOpenChange: N, children: /* @__PURE__ */ m(I.Content, { side: "bottom", size: "lg", children: [
|
|
1298
|
+
/* @__PURE__ */ t(I.Header, { children: /* @__PURE__ */ t(I.Title, { children: R("practiceResults.map.label") }) }),
|
|
1299
|
+
/* @__PURE__ */ m(I.Body, { children: [
|
|
1300
|
+
/* @__PURE__ */ t(I.Description, { className: "ds:sr-only", children: R("practiceResults.sheet.description") }),
|
|
1269
1301
|
/* @__PURE__ */ m("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)]", children: [
|
|
1270
1302
|
/* @__PURE__ */ t("div", { className: "ds:h-[20rem]", children: /* @__PURE__ */ t(
|
|
1271
1303
|
pe,
|
|
1272
1304
|
{
|
|
1273
1305
|
results: n,
|
|
1274
|
-
searchCentre:
|
|
1275
|
-
zoom:
|
|
1276
|
-
apiKey:
|
|
1277
|
-
mapId:
|
|
1278
|
-
highlightedId:
|
|
1306
|
+
searchCentre: i,
|
|
1307
|
+
zoom: r,
|
|
1308
|
+
apiKey: a,
|
|
1309
|
+
mapId: s,
|
|
1310
|
+
highlightedId: b,
|
|
1279
1311
|
onPinClick: (A) => {
|
|
1280
|
-
|
|
1312
|
+
J(n, A, "pin", e.onResultSelect), y(A);
|
|
1281
1313
|
},
|
|
1282
|
-
onPinHover:
|
|
1314
|
+
onPinHover: h,
|
|
1283
1315
|
onPinFirstInteract: e.onPinFirstInteract,
|
|
1284
|
-
onBoundsChange:
|
|
1285
|
-
consentGranted:
|
|
1286
|
-
onConsentRequest:
|
|
1316
|
+
onBoundsChange: c,
|
|
1317
|
+
consentGranted: k,
|
|
1318
|
+
onConsentRequest: x,
|
|
1287
1319
|
mapHandleRef: e.mapHandleRef
|
|
1288
1320
|
}
|
|
1289
1321
|
) }),
|
|
1290
|
-
|
|
1322
|
+
_
|
|
1291
1323
|
] })
|
|
1292
1324
|
] })
|
|
1293
1325
|
] }) })
|
|
1294
1326
|
] });
|
|
1295
1327
|
}
|
|
1296
|
-
const
|
|
1328
|
+
const $t = {
|
|
1297
1329
|
peek: "sm",
|
|
1298
1330
|
half: "md",
|
|
1299
1331
|
full: "lg"
|
|
1300
|
-
},
|
|
1332
|
+
}, U = [
|
|
1301
1333
|
"peek",
|
|
1302
1334
|
"half",
|
|
1303
1335
|
"full"
|
|
1304
1336
|
];
|
|
1305
|
-
function
|
|
1306
|
-
const { t:
|
|
1337
|
+
function Ot({ value: e, onChange: n }) {
|
|
1338
|
+
const { t: a, i18n: s } = C("ui"), r = s.dir() === "rtl", i = T(
|
|
1307
1339
|
/* @__PURE__ */ new Map()
|
|
1308
|
-
),
|
|
1309
|
-
var
|
|
1310
|
-
(
|
|
1311
|
-
}, []),
|
|
1312
|
-
(
|
|
1313
|
-
const o =
|
|
1314
|
-
let
|
|
1315
|
-
switch (
|
|
1316
|
-
case
|
|
1340
|
+
), d = B((l) => {
|
|
1341
|
+
var g;
|
|
1342
|
+
(g = i.current.get(l)) == null || g.focus();
|
|
1343
|
+
}, []), u = B(
|
|
1344
|
+
(l, g) => {
|
|
1345
|
+
const o = U.indexOf(g), p = U.length, f = r ? "ArrowLeft" : "ArrowRight", b = r ? "ArrowRight" : "ArrowLeft";
|
|
1346
|
+
let h = null;
|
|
1347
|
+
switch (l.key) {
|
|
1348
|
+
case f:
|
|
1317
1349
|
case "ArrowDown":
|
|
1318
|
-
|
|
1350
|
+
h = U[(o + 1) % p];
|
|
1319
1351
|
break;
|
|
1320
|
-
case
|
|
1352
|
+
case b:
|
|
1321
1353
|
case "ArrowUp":
|
|
1322
|
-
|
|
1354
|
+
h = U[(o - 1 + p) % p];
|
|
1323
1355
|
break;
|
|
1324
1356
|
case "Home":
|
|
1325
|
-
|
|
1357
|
+
h = U[0];
|
|
1326
1358
|
break;
|
|
1327
1359
|
case "End":
|
|
1328
|
-
|
|
1360
|
+
h = U[p - 1];
|
|
1329
1361
|
break;
|
|
1330
1362
|
default:
|
|
1331
1363
|
return;
|
|
1332
1364
|
}
|
|
1333
|
-
|
|
1365
|
+
l.preventDefault(), h && h !== g && n(h), h && d(h);
|
|
1334
1366
|
},
|
|
1335
|
-
[
|
|
1367
|
+
[d, r, n]
|
|
1336
1368
|
);
|
|
1337
1369
|
return /* @__PURE__ */ t(
|
|
1338
1370
|
"div",
|
|
1339
1371
|
{
|
|
1340
1372
|
role: "radiogroup",
|
|
1341
|
-
"aria-label":
|
|
1373
|
+
"aria-label": a("practiceResults.sheet.snap.label"),
|
|
1342
1374
|
className: "ds:inline-flex ds:items-center ds:gap-[var(--spacing-2xs)]",
|
|
1343
|
-
children:
|
|
1344
|
-
const
|
|
1375
|
+
children: U.map((l) => {
|
|
1376
|
+
const g = e === l;
|
|
1345
1377
|
return /* @__PURE__ */ t(
|
|
1346
1378
|
"button",
|
|
1347
1379
|
{
|
|
1348
1380
|
ref: (o) => {
|
|
1349
|
-
o ?
|
|
1381
|
+
o ? i.current.set(l, o) : i.current.delete(l);
|
|
1350
1382
|
},
|
|
1351
1383
|
type: "button",
|
|
1352
1384
|
role: "radio",
|
|
1353
|
-
"aria-checked":
|
|
1354
|
-
"aria-label":
|
|
1355
|
-
tabIndex:
|
|
1356
|
-
onClick: () => n(
|
|
1357
|
-
onKeyDown: (o) =>
|
|
1358
|
-
className:
|
|
1359
|
-
state:
|
|
1385
|
+
"aria-checked": g,
|
|
1386
|
+
"aria-label": a(`practiceResults.sheet.snap.${l}`),
|
|
1387
|
+
tabIndex: g ? 0 : -1,
|
|
1388
|
+
onClick: () => n(l),
|
|
1389
|
+
onKeyDown: (o) => u(o, l),
|
|
1390
|
+
className: ne({
|
|
1391
|
+
state: g ? "active" : "idle"
|
|
1360
1392
|
}),
|
|
1361
|
-
children:
|
|
1393
|
+
children: a(`practiceResults.sheet.snap.${l}`)
|
|
1362
1394
|
},
|
|
1363
|
-
|
|
1395
|
+
l
|
|
1364
1396
|
);
|
|
1365
1397
|
})
|
|
1366
1398
|
}
|
|
1367
1399
|
);
|
|
1368
1400
|
}
|
|
1369
|
-
function
|
|
1401
|
+
function Dt(e) {
|
|
1370
1402
|
const {
|
|
1371
1403
|
results: n,
|
|
1372
|
-
apiKey:
|
|
1373
|
-
mapId:
|
|
1374
|
-
zoom:
|
|
1375
|
-
searchCentre:
|
|
1376
|
-
onLoadMore:
|
|
1377
|
-
loadingMore:
|
|
1378
|
-
loadingSkeletons:
|
|
1379
|
-
emptyResultsSlot:
|
|
1404
|
+
apiKey: a,
|
|
1405
|
+
mapId: s,
|
|
1406
|
+
zoom: r,
|
|
1407
|
+
searchCentre: i,
|
|
1408
|
+
onLoadMore: d,
|
|
1409
|
+
loadingMore: u,
|
|
1410
|
+
loadingSkeletons: l,
|
|
1411
|
+
emptyResultsSlot: g,
|
|
1380
1412
|
errorSlot: o,
|
|
1381
|
-
error:
|
|
1382
|
-
onRetry:
|
|
1383
|
-
highlightedId:
|
|
1384
|
-
onCardHover:
|
|
1413
|
+
error: p,
|
|
1414
|
+
onRetry: f,
|
|
1415
|
+
highlightedId: b,
|
|
1416
|
+
onCardHover: h,
|
|
1385
1417
|
onPinClick: y,
|
|
1386
|
-
consentGranted:
|
|
1387
|
-
onConsentRequest:
|
|
1388
|
-
onBoundsChange:
|
|
1389
|
-
listContainerRef:
|
|
1390
|
-
facets:
|
|
1391
|
-
value:
|
|
1392
|
-
onChange:
|
|
1393
|
-
} = e, { t:
|
|
1394
|
-
|
|
1418
|
+
consentGranted: k,
|
|
1419
|
+
onConsentRequest: x,
|
|
1420
|
+
onBoundsChange: c,
|
|
1421
|
+
listContainerRef: S,
|
|
1422
|
+
facets: R,
|
|
1423
|
+
value: L,
|
|
1424
|
+
onChange: N
|
|
1425
|
+
} = e, { t: _ } = C("ui"), [A, G] = fe("half"), Z = $t[A], Q = ut("(min-width: 1024px)"), K = p ? o ?? /* @__PURE__ */ t(ye, { onRetry: f, headingLevel: e.headingLevel }) : n.length === 0 && !l ? g ?? /* @__PURE__ */ t(be, { headingLevel: e.headingLevel }) : /* @__PURE__ */ t(
|
|
1426
|
+
he,
|
|
1395
1427
|
{
|
|
1396
1428
|
results: n,
|
|
1397
|
-
|
|
1398
|
-
|
|
1429
|
+
headingLevel: e.headingLevel,
|
|
1430
|
+
highlightedId: b,
|
|
1431
|
+
onCardHover: h,
|
|
1399
1432
|
onCardSelect: e.onCardSelect,
|
|
1400
1433
|
onCardOpenClick: e.onCardOpenClick,
|
|
1401
1434
|
onCardBookClick: e.onCardBookClick,
|
|
1402
1435
|
openLabel: e.openLabel,
|
|
1403
1436
|
bookLabel: e.bookLabel,
|
|
1404
1437
|
formatNextSlot: e.formatNextSlot,
|
|
1405
|
-
onLoadMore:
|
|
1406
|
-
loadingMore:
|
|
1407
|
-
loadingSkeletons:
|
|
1438
|
+
onLoadMore: d,
|
|
1439
|
+
loadingMore: u,
|
|
1440
|
+
loadingSkeletons: l,
|
|
1408
1441
|
density: "compact",
|
|
1409
|
-
apiKey:
|
|
1410
|
-
containerRef:
|
|
1442
|
+
apiKey: a,
|
|
1443
|
+
containerRef: S
|
|
1411
1444
|
}
|
|
1412
|
-
),
|
|
1445
|
+
), E = /* @__PURE__ */ t(
|
|
1413
1446
|
pe,
|
|
1414
1447
|
{
|
|
1415
1448
|
results: n,
|
|
1416
|
-
searchCentre:
|
|
1417
|
-
zoom:
|
|
1418
|
-
apiKey:
|
|
1419
|
-
mapId:
|
|
1420
|
-
highlightedId:
|
|
1421
|
-
onPinClick: (
|
|
1422
|
-
|
|
1449
|
+
searchCentre: i,
|
|
1450
|
+
zoom: r,
|
|
1451
|
+
apiKey: a,
|
|
1452
|
+
mapId: s,
|
|
1453
|
+
highlightedId: b,
|
|
1454
|
+
onPinClick: (w) => {
|
|
1455
|
+
J(n, w, "pin", e.onResultSelect), y(w);
|
|
1423
1456
|
},
|
|
1424
|
-
onPinHover:
|
|
1457
|
+
onPinHover: h,
|
|
1425
1458
|
onPinFirstInteract: e.onPinFirstInteract,
|
|
1426
|
-
onBoundsChange:
|
|
1427
|
-
consentGranted:
|
|
1428
|
-
onConsentRequest:
|
|
1459
|
+
onBoundsChange: c,
|
|
1460
|
+
consentGranted: k,
|
|
1461
|
+
onConsentRequest: x,
|
|
1429
1462
|
mapHandleRef: e.mapHandleRef
|
|
1430
1463
|
}
|
|
1431
|
-
),
|
|
1432
|
-
|
|
1464
|
+
), D = R.length > 0 ? /* @__PURE__ */ t("div", { className: "ds:absolute ds:start-[var(--spacing-md)] ds:top-[var(--spacing-md)] ds:max-w-[calc(100%-var(--spacing-lg))]", children: /* @__PURE__ */ t(
|
|
1465
|
+
ze,
|
|
1433
1466
|
{
|
|
1434
|
-
facets:
|
|
1435
|
-
value:
|
|
1436
|
-
onChange: (
|
|
1467
|
+
facets: R,
|
|
1468
|
+
value: L.facets,
|
|
1469
|
+
onChange: (w) => N({ ...L, facets: w }),
|
|
1437
1470
|
floating: !0
|
|
1438
1471
|
}
|
|
1439
1472
|
) }) : null;
|
|
1440
|
-
return /* @__PURE__ */ t("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)]", children:
|
|
1473
|
+
return /* @__PURE__ */ t("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)]", children: Q ? (
|
|
1441
1474
|
// Desktop: 65/35 map left + cards rail right. NO Sheet (the
|
|
1442
1475
|
// Sheet would portal to body and occlude the desktop layout
|
|
1443
1476
|
// regardless of the parent's `lg:hidden` class).
|
|
@@ -1455,11 +1488,11 @@ function Bt(e) {
|
|
|
1455
1488
|
// the map column is `lg:sticky lg:h-[44rem]` (stays visible
|
|
1456
1489
|
// as the patient scrolls cards) and the rail renders at
|
|
1457
1490
|
// natural height. Single page scroll.
|
|
1458
|
-
/* @__PURE__ */ m(
|
|
1459
|
-
/* @__PURE__ */ t(
|
|
1491
|
+
/* @__PURE__ */ m(it, { children: [
|
|
1492
|
+
/* @__PURE__ */ t(ge, { variantBodyProps: e }),
|
|
1460
1493
|
/* @__PURE__ */ m("div", { className: "ds:grid ds:grid-cols-[65fr_35fr] ds:gap-[var(--spacing-lg)] ds:items-start", children: [
|
|
1461
|
-
/* @__PURE__ */ t("div", { className: "ds:sticky ds:top-[var(--spacing-md)] ds:h-[44rem]", children:
|
|
1462
|
-
/* @__PURE__ */ t("div", { className: "ds:min-w-0", children:
|
|
1494
|
+
/* @__PURE__ */ t("div", { className: "ds:sticky ds:top-[var(--spacing-md)] ds:h-[44rem]", children: E }),
|
|
1495
|
+
/* @__PURE__ */ t("div", { className: "ds:min-w-0", children: K })
|
|
1463
1496
|
] })
|
|
1464
1497
|
] })
|
|
1465
1498
|
) : (
|
|
@@ -1474,302 +1507,306 @@ function Bt(e) {
|
|
|
1474
1507
|
_e,
|
|
1475
1508
|
{
|
|
1476
1509
|
heading: e.heading,
|
|
1510
|
+
headingLevel: e.headingLevel,
|
|
1477
1511
|
intro: e.intro,
|
|
1478
1512
|
totalCount: e.totalCount,
|
|
1479
|
-
searchCentreLabel:
|
|
1513
|
+
searchCentreLabel: i == null ? void 0 : i.label
|
|
1480
1514
|
}
|
|
1481
1515
|
),
|
|
1482
1516
|
/* @__PURE__ */ m("div", { className: "ds:relative ds:h-[60vh] ds:min-h-[20rem]", children: [
|
|
1483
|
-
|
|
1484
|
-
|
|
1517
|
+
E,
|
|
1518
|
+
D
|
|
1485
1519
|
] }),
|
|
1486
|
-
/* @__PURE__ */ t(
|
|
1487
|
-
|
|
1520
|
+
/* @__PURE__ */ t(I.Root, { open: !0, children: /* @__PURE__ */ t(
|
|
1521
|
+
I.Content,
|
|
1488
1522
|
{
|
|
1489
1523
|
side: "bottom",
|
|
1490
|
-
size:
|
|
1491
|
-
onEscapeKeyDown: (
|
|
1492
|
-
onPointerDownOutside: (
|
|
1493
|
-
onInteractOutside: (
|
|
1494
|
-
children: /* @__PURE__ */ m(
|
|
1495
|
-
/* @__PURE__ */ t(
|
|
1524
|
+
size: Z,
|
|
1525
|
+
onEscapeKeyDown: (w) => w.preventDefault(),
|
|
1526
|
+
onPointerDownOutside: (w) => w.preventDefault(),
|
|
1527
|
+
onInteractOutside: (w) => w.preventDefault(),
|
|
1528
|
+
children: /* @__PURE__ */ m(I.Body, { children: [
|
|
1529
|
+
/* @__PURE__ */ t(I.Description, { className: "ds:sr-only", children: _("practiceResults.sheet.descriptionMapFirst") }),
|
|
1496
1530
|
/* @__PURE__ */ m("div", { className: "ds:flex ds:items-start ds:justify-between ds:gap-[var(--spacing-sm)] ds:pb-[var(--spacing-sm)]", children: [
|
|
1497
|
-
/* @__PURE__ */ t(
|
|
1531
|
+
/* @__PURE__ */ t(I.Title, { className: "type-title-card ds:m-0 ds:text-[var(--foreground)]", children: _("practiceResults.sheet.title", {
|
|
1498
1532
|
count: e.totalCount ?? n.length
|
|
1499
1533
|
}) }),
|
|
1500
1534
|
/* @__PURE__ */ t(
|
|
1501
|
-
|
|
1535
|
+
Ot,
|
|
1502
1536
|
{
|
|
1503
1537
|
value: A,
|
|
1504
|
-
onChange:
|
|
1538
|
+
onChange: G
|
|
1505
1539
|
}
|
|
1506
1540
|
)
|
|
1507
1541
|
] }),
|
|
1508
1542
|
/* @__PURE__ */ t("div", { className: "ds:pb-[var(--spacing-sm)]", children: /* @__PURE__ */ t(
|
|
1509
|
-
|
|
1543
|
+
me,
|
|
1510
1544
|
{
|
|
1511
|
-
value:
|
|
1512
|
-
onChange: (
|
|
1545
|
+
value: L.sort ?? "relevance",
|
|
1546
|
+
onChange: (w) => N({ ...L, sort: w })
|
|
1513
1547
|
}
|
|
1514
1548
|
) }),
|
|
1515
|
-
|
|
1549
|
+
K
|
|
1516
1550
|
] })
|
|
1517
1551
|
}
|
|
1518
1552
|
) })
|
|
1519
1553
|
] })
|
|
1520
1554
|
) });
|
|
1521
1555
|
}
|
|
1522
|
-
function
|
|
1556
|
+
function Vt(e) {
|
|
1523
1557
|
const {
|
|
1524
1558
|
results: n,
|
|
1525
|
-
apiKey:
|
|
1526
|
-
onLoadMore:
|
|
1527
|
-
loadingMore:
|
|
1528
|
-
loadingSkeletons:
|
|
1529
|
-
emptyResultsSlot:
|
|
1530
|
-
errorSlot:
|
|
1531
|
-
error:
|
|
1532
|
-
onRetry:
|
|
1559
|
+
apiKey: a,
|
|
1560
|
+
onLoadMore: s,
|
|
1561
|
+
loadingMore: r,
|
|
1562
|
+
loadingSkeletons: i,
|
|
1563
|
+
emptyResultsSlot: d,
|
|
1564
|
+
errorSlot: u,
|
|
1565
|
+
error: l,
|
|
1566
|
+
onRetry: g,
|
|
1533
1567
|
highlightedId: o,
|
|
1534
|
-
onCardHover:
|
|
1535
|
-
listContainerRef:
|
|
1536
|
-
} = e,
|
|
1537
|
-
|
|
1568
|
+
onCardHover: p,
|
|
1569
|
+
listContainerRef: f
|
|
1570
|
+
} = e, b = l ? u ?? /* @__PURE__ */ t(ye, { onRetry: g, headingLevel: e.headingLevel }) : n.length === 0 && !i ? d ?? /* @__PURE__ */ t(be, { headingLevel: e.headingLevel }) : /* @__PURE__ */ t(
|
|
1571
|
+
he,
|
|
1538
1572
|
{
|
|
1539
1573
|
results: n,
|
|
1574
|
+
headingLevel: e.headingLevel,
|
|
1540
1575
|
highlightedId: o,
|
|
1541
|
-
onCardHover:
|
|
1576
|
+
onCardHover: p,
|
|
1542
1577
|
onCardSelect: e.onCardSelect,
|
|
1543
1578
|
onCardOpenClick: e.onCardOpenClick,
|
|
1544
1579
|
onCardBookClick: e.onCardBookClick,
|
|
1545
1580
|
openLabel: e.openLabel,
|
|
1546
1581
|
bookLabel: e.bookLabel,
|
|
1547
1582
|
formatNextSlot: e.formatNextSlot,
|
|
1548
|
-
onLoadMore:
|
|
1549
|
-
loadingMore:
|
|
1550
|
-
loadingSkeletons:
|
|
1583
|
+
onLoadMore: s,
|
|
1584
|
+
loadingMore: r,
|
|
1585
|
+
loadingSkeletons: i,
|
|
1551
1586
|
density: "rich",
|
|
1552
|
-
apiKey:
|
|
1553
|
-
containerRef:
|
|
1587
|
+
apiKey: a,
|
|
1588
|
+
containerRef: f
|
|
1554
1589
|
}
|
|
1555
1590
|
);
|
|
1556
1591
|
return /* @__PURE__ */ m("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)]", children: [
|
|
1557
|
-
/* @__PURE__ */ t(
|
|
1558
|
-
|
|
1592
|
+
/* @__PURE__ */ t(ge, { variantBodyProps: e }),
|
|
1593
|
+
b
|
|
1559
1594
|
] });
|
|
1560
1595
|
}
|
|
1561
|
-
const
|
|
1596
|
+
const Kt = st(function({
|
|
1562
1597
|
variant: n = "split-list-map",
|
|
1563
|
-
results:
|
|
1564
|
-
totalCount:
|
|
1565
|
-
searchCentre:
|
|
1566
|
-
facets:
|
|
1567
|
-
googleMapsApiKey:
|
|
1568
|
-
mapId:
|
|
1569
|
-
defaultZoom:
|
|
1570
|
-
onBoundsChange:
|
|
1598
|
+
results: a,
|
|
1599
|
+
totalCount: s,
|
|
1600
|
+
searchCentre: r,
|
|
1601
|
+
facets: i,
|
|
1602
|
+
googleMapsApiKey: d,
|
|
1603
|
+
mapId: u,
|
|
1604
|
+
defaultZoom: l = Ct,
|
|
1605
|
+
onBoundsChange: g,
|
|
1571
1606
|
consentGranted: o,
|
|
1572
|
-
onConsentRequest:
|
|
1573
|
-
skipConsentGate:
|
|
1574
|
-
onLoadMore:
|
|
1575
|
-
loadingMore:
|
|
1607
|
+
onConsentRequest: p,
|
|
1608
|
+
skipConsentGate: f = !1,
|
|
1609
|
+
onLoadMore: b,
|
|
1610
|
+
loadingMore: h,
|
|
1576
1611
|
value: y,
|
|
1577
|
-
onChange:
|
|
1578
|
-
onResultSelect:
|
|
1579
|
-
loading:
|
|
1580
|
-
emptyResultsSlot:
|
|
1581
|
-
errorSlot:
|
|
1582
|
-
error:
|
|
1583
|
-
onRetry:
|
|
1584
|
-
heading:
|
|
1585
|
-
|
|
1586
|
-
|
|
1587
|
-
|
|
1588
|
-
|
|
1589
|
-
|
|
1590
|
-
|
|
1591
|
-
|
|
1592
|
-
|
|
1593
|
-
|
|
1594
|
-
|
|
1612
|
+
onChange: k,
|
|
1613
|
+
onResultSelect: x,
|
|
1614
|
+
loading: c,
|
|
1615
|
+
emptyResultsSlot: S,
|
|
1616
|
+
errorSlot: R,
|
|
1617
|
+
error: L,
|
|
1618
|
+
onRetry: N,
|
|
1619
|
+
heading: _,
|
|
1620
|
+
headingLevel: A = 2,
|
|
1621
|
+
intro: G,
|
|
1622
|
+
cardOpenButtonLabel: Z,
|
|
1623
|
+
cardBookButtonLabel: Q,
|
|
1624
|
+
showCardOpenButton: K = !0,
|
|
1625
|
+
"aria-label": E,
|
|
1626
|
+
id: D,
|
|
1627
|
+
className: w,
|
|
1628
|
+
...j
|
|
1629
|
+
}, Ee) {
|
|
1630
|
+
const { t: ie, i18n: xe } = C("ui"), [je, W] = fe(null), Y = T(/* @__PURE__ */ new Set()), se = T(/* @__PURE__ */ new Set()), qe = T(null), re = T(null), oe = M(
|
|
1595
1631
|
() => ({
|
|
1596
1632
|
getVariant: () => n,
|
|
1597
|
-
scrollToResult: (
|
|
1598
|
-
const
|
|
1599
|
-
if (!
|
|
1600
|
-
const
|
|
1601
|
-
`[data-component="practice-result-card"][data-result-id="${CSS.escape(
|
|
1633
|
+
scrollToResult: (v) => {
|
|
1634
|
+
const F = re.current;
|
|
1635
|
+
if (!F) return;
|
|
1636
|
+
const P = F.querySelector(
|
|
1637
|
+
`[data-component="practice-result-card"][data-result-id="${CSS.escape(v)}"]`
|
|
1602
1638
|
);
|
|
1603
|
-
|
|
1639
|
+
P && (P.scrollIntoView({ behavior: "smooth", block: "nearest" }), W(v));
|
|
1604
1640
|
},
|
|
1605
|
-
focusPin: (
|
|
1606
|
-
|
|
1641
|
+
focusPin: (v) => {
|
|
1642
|
+
W(v);
|
|
1607
1643
|
}
|
|
1608
1644
|
}),
|
|
1609
1645
|
[n]
|
|
1610
1646
|
);
|
|
1611
|
-
|
|
1612
|
-
const
|
|
1613
|
-
(
|
|
1614
|
-
if (
|
|
1647
|
+
rt(Ee, () => oe, [oe]), pt(kt, oe, D);
|
|
1648
|
+
const Ue = K ? Z ?? ie("practiceResults.card.open") : void 0, Ge = Q ?? ie("practiceResults.card.book"), Ze = B(
|
|
1649
|
+
(v) => {
|
|
1650
|
+
if (v.nextAvailableSlot)
|
|
1615
1651
|
try {
|
|
1616
|
-
return new Intl.DateTimeFormat(
|
|
1652
|
+
return new Intl.DateTimeFormat(xe.language, {
|
|
1617
1653
|
weekday: "short",
|
|
1618
1654
|
hour: "numeric",
|
|
1619
1655
|
minute: "numeric"
|
|
1620
|
-
}).format(new Date(
|
|
1656
|
+
}).format(new Date(v.nextAvailableSlot.dateTime));
|
|
1621
1657
|
} catch {
|
|
1622
|
-
return
|
|
1658
|
+
return v.nextAvailableSlot.dateTime;
|
|
1623
1659
|
}
|
|
1624
1660
|
},
|
|
1625
|
-
[
|
|
1626
|
-
),
|
|
1627
|
-
|
|
1628
|
-
|
|
1661
|
+
[xe.language]
|
|
1662
|
+
), ke = T(null);
|
|
1663
|
+
X(() => {
|
|
1664
|
+
ke.current !== n && (ke.current = n, H("serp_variant_exposed", {
|
|
1629
1665
|
variant: n,
|
|
1630
|
-
totalCount:
|
|
1631
|
-
}),
|
|
1666
|
+
totalCount: s ?? a.length
|
|
1667
|
+
}), Y.current = /* @__PURE__ */ new Set(), se.current = /* @__PURE__ */ new Set());
|
|
1632
1668
|
}, [n]);
|
|
1633
|
-
const
|
|
1634
|
-
() =>
|
|
1635
|
-
[
|
|
1636
|
-
),
|
|
1637
|
-
const
|
|
1638
|
-
return
|
|
1639
|
-
}, [
|
|
1640
|
-
|
|
1641
|
-
const
|
|
1642
|
-
|
|
1669
|
+
const le = T(!1), ce = M(
|
|
1670
|
+
() => Nt(i ?? [], a, y.facets),
|
|
1671
|
+
[i, a, y.facets]
|
|
1672
|
+
), de = y.sort ?? (r ? "distance" : "relevance"), z = M(() => {
|
|
1673
|
+
const v = St(a, y.facets, ce);
|
|
1674
|
+
return Lt(v, de, r);
|
|
1675
|
+
}, [a, y.facets, ce, de, r]);
|
|
1676
|
+
X(() => {
|
|
1677
|
+
const v = z.length === 0;
|
|
1678
|
+
v && !le.current ? (H("serp_empty_results", {
|
|
1643
1679
|
appliedFacets: y.facets ?? {}
|
|
1644
|
-
}),
|
|
1645
|
-
}, [
|
|
1646
|
-
const
|
|
1647
|
-
|
|
1680
|
+
}), le.current = !0) : v || (le.current = !1);
|
|
1681
|
+
}, [z.length, y.facets]);
|
|
1682
|
+
const q = T(null), Ce = T(null);
|
|
1683
|
+
X(
|
|
1648
1684
|
() => () => {
|
|
1649
|
-
|
|
1685
|
+
q.current && clearTimeout(q.current);
|
|
1650
1686
|
},
|
|
1651
1687
|
[]
|
|
1652
1688
|
);
|
|
1653
|
-
const
|
|
1654
|
-
|
|
1655
|
-
|
|
1689
|
+
const Qe = B((v) => {
|
|
1690
|
+
W(v), !Y.current.has(v) && (Ce.current === v && q.current || (q.current && clearTimeout(q.current), Ce.current = v, q.current = setTimeout(() => {
|
|
1691
|
+
Y.current.has(v) || (Y.current.add(v), H("serp_result_hovered_card", { resultId: v })), q.current = null;
|
|
1656
1692
|
}, 500)));
|
|
1657
|
-
}, []),
|
|
1658
|
-
|
|
1659
|
-
const
|
|
1660
|
-
if (!
|
|
1661
|
-
const
|
|
1662
|
-
`[data-component="practice-result-card"][data-result-id="${CSS.escape(
|
|
1693
|
+
}, []), Je = B((v) => {
|
|
1694
|
+
W(v);
|
|
1695
|
+
const F = re.current;
|
|
1696
|
+
if (!F) return;
|
|
1697
|
+
const P = F.querySelector(
|
|
1698
|
+
`[data-component="practice-result-card"][data-result-id="${CSS.escape(v)}"]`
|
|
1663
1699
|
);
|
|
1664
|
-
|
|
1665
|
-
}, []),
|
|
1666
|
-
se.current.has(
|
|
1667
|
-
}, []),
|
|
1668
|
-
(
|
|
1669
|
-
|
|
1670
|
-
const
|
|
1671
|
-
if (
|
|
1672
|
-
if (
|
|
1673
|
-
const
|
|
1674
|
-
|
|
1675
|
-
lat:
|
|
1676
|
-
lng:
|
|
1677
|
-
}),
|
|
1700
|
+
P == null || P.scrollIntoView({ behavior: "smooth", block: "nearest" });
|
|
1701
|
+
}, []), We = B((v) => {
|
|
1702
|
+
se.current.has(v) || (se.current.add(v), H("serp_result_hovered_pin", { resultId: v }));
|
|
1703
|
+
}, []), we = T(null), Xe = B(
|
|
1704
|
+
(v) => {
|
|
1705
|
+
W(v);
|
|
1706
|
+
const F = z.find((P) => P.id === v);
|
|
1707
|
+
if (F) {
|
|
1708
|
+
if (F.location) {
|
|
1709
|
+
const P = we.current;
|
|
1710
|
+
P == null || P.panTo({
|
|
1711
|
+
lat: F.location.lat,
|
|
1712
|
+
lng: F.location.lng
|
|
1713
|
+
}), P == null || P.setZoom(16);
|
|
1678
1714
|
}
|
|
1679
|
-
|
|
1715
|
+
J(z, v, "card", x);
|
|
1680
1716
|
}
|
|
1681
1717
|
},
|
|
1682
|
-
[
|
|
1683
|
-
),
|
|
1684
|
-
(
|
|
1685
|
-
|
|
1686
|
-
|
|
1687
|
-
|
|
1718
|
+
[z, x]
|
|
1719
|
+
), Ye = B(
|
|
1720
|
+
(v) => {
|
|
1721
|
+
J(
|
|
1722
|
+
z,
|
|
1723
|
+
v,
|
|
1688
1724
|
"open-button",
|
|
1689
|
-
|
|
1725
|
+
x
|
|
1690
1726
|
);
|
|
1691
1727
|
},
|
|
1692
|
-
[
|
|
1693
|
-
),
|
|
1694
|
-
(
|
|
1695
|
-
|
|
1696
|
-
|
|
1697
|
-
|
|
1728
|
+
[z, x]
|
|
1729
|
+
), et = B(
|
|
1730
|
+
(v) => {
|
|
1731
|
+
J(
|
|
1732
|
+
z,
|
|
1733
|
+
v,
|
|
1698
1734
|
"book-button",
|
|
1699
|
-
|
|
1735
|
+
x
|
|
1700
1736
|
);
|
|
1701
1737
|
},
|
|
1702
|
-
[
|
|
1703
|
-
),
|
|
1704
|
-
results:
|
|
1705
|
-
totalCount:
|
|
1706
|
-
searchCentre:
|
|
1738
|
+
[z, x]
|
|
1739
|
+
), tt = !!c && a.length === 0, ue = {
|
|
1740
|
+
results: z,
|
|
1741
|
+
totalCount: s,
|
|
1742
|
+
searchCentre: r,
|
|
1707
1743
|
facets: ce,
|
|
1708
|
-
value: { ...y, sort:
|
|
1709
|
-
onChange:
|
|
1710
|
-
onResultSelect:
|
|
1711
|
-
onLoadMore:
|
|
1712
|
-
loadingMore:
|
|
1713
|
-
apiKey:
|
|
1714
|
-
mapId:
|
|
1715
|
-
zoom:
|
|
1744
|
+
value: { ...y, sort: de },
|
|
1745
|
+
onChange: k,
|
|
1746
|
+
onResultSelect: x,
|
|
1747
|
+
onLoadMore: b,
|
|
1748
|
+
loadingMore: h,
|
|
1749
|
+
apiKey: d,
|
|
1750
|
+
mapId: u,
|
|
1751
|
+
zoom: l,
|
|
1716
1752
|
// 0.31.4: when `skipConsentGate` is true the kit synthesises
|
|
1717
1753
|
// `consentGranted=true` for every internal MapView; the consumer's
|
|
1718
1754
|
// CMP at the page level is responsible for whether the Google Maps
|
|
1719
1755
|
// loader script is present at all. `onConsentRequest` is dropped
|
|
1720
1756
|
// because no placeholder renders — nothing to fire it from.
|
|
1721
|
-
consentGranted:
|
|
1722
|
-
onConsentRequest:
|
|
1723
|
-
onBoundsChange:
|
|
1724
|
-
loadingSkeletons:
|
|
1725
|
-
emptyResultsSlot:
|
|
1726
|
-
errorSlot:
|
|
1727
|
-
error:
|
|
1728
|
-
onRetry:
|
|
1729
|
-
heading:
|
|
1730
|
-
|
|
1731
|
-
|
|
1732
|
-
|
|
1733
|
-
|
|
1734
|
-
|
|
1735
|
-
|
|
1736
|
-
|
|
1737
|
-
|
|
1738
|
-
|
|
1739
|
-
|
|
1740
|
-
|
|
1741
|
-
|
|
1742
|
-
|
|
1743
|
-
|
|
1757
|
+
consentGranted: f ? !0 : o,
|
|
1758
|
+
onConsentRequest: f ? void 0 : p,
|
|
1759
|
+
onBoundsChange: g,
|
|
1760
|
+
loadingSkeletons: tt,
|
|
1761
|
+
emptyResultsSlot: S,
|
|
1762
|
+
errorSlot: R,
|
|
1763
|
+
error: L,
|
|
1764
|
+
onRetry: N,
|
|
1765
|
+
heading: _,
|
|
1766
|
+
headingLevel: A,
|
|
1767
|
+
intro: G,
|
|
1768
|
+
highlightedId: je,
|
|
1769
|
+
onCardHover: Qe,
|
|
1770
|
+
onPinClick: Je,
|
|
1771
|
+
onPinFirstInteract: We,
|
|
1772
|
+
onCardSelect: Xe,
|
|
1773
|
+
onCardOpenClick: Ye,
|
|
1774
|
+
onCardBookClick: et,
|
|
1775
|
+
openLabel: Ue,
|
|
1776
|
+
bookLabel: Ge,
|
|
1777
|
+
formatNextSlot: Ze,
|
|
1778
|
+
listContainerRef: qe,
|
|
1779
|
+
mapHandleRef: we
|
|
1780
|
+
}, nt = (() => {
|
|
1744
1781
|
switch (n) {
|
|
1745
1782
|
case "map-first":
|
|
1746
|
-
return /* @__PURE__ */ t(
|
|
1783
|
+
return /* @__PURE__ */ t(Dt, { ...ue });
|
|
1747
1784
|
case "rich-cards":
|
|
1748
|
-
return /* @__PURE__ */ t(
|
|
1785
|
+
return /* @__PURE__ */ t(Vt, { ...ue });
|
|
1749
1786
|
case "split-list-map":
|
|
1750
1787
|
default:
|
|
1751
|
-
return /* @__PURE__ */ t(
|
|
1788
|
+
return /* @__PURE__ */ t(Bt, { ...ue });
|
|
1752
1789
|
}
|
|
1753
|
-
})(),
|
|
1790
|
+
})(), at = E ?? ie("practiceResults.regionLabel");
|
|
1754
1791
|
return /* @__PURE__ */ t(
|
|
1755
1792
|
"div",
|
|
1756
1793
|
{
|
|
1757
|
-
ref:
|
|
1794
|
+
ref: re,
|
|
1758
1795
|
role: "region",
|
|
1759
|
-
"aria-label":
|
|
1760
|
-
id:
|
|
1796
|
+
"aria-label": at,
|
|
1797
|
+
id: D,
|
|
1761
1798
|
"data-component": "practice-results",
|
|
1762
|
-
"data-component-id":
|
|
1799
|
+
"data-component-id": D,
|
|
1763
1800
|
"data-variant": n,
|
|
1764
|
-
className:
|
|
1765
|
-
...
|
|
1766
|
-
children:
|
|
1801
|
+
className: Pt({ variant: n, className: w }),
|
|
1802
|
+
...j,
|
|
1803
|
+
children: nt
|
|
1767
1804
|
}
|
|
1768
1805
|
);
|
|
1769
1806
|
});
|
|
1770
|
-
|
|
1807
|
+
Kt.displayName = "PracticeResults";
|
|
1771
1808
|
export {
|
|
1772
|
-
|
|
1773
|
-
|
|
1809
|
+
Kt as P,
|
|
1810
|
+
kt as p
|
|
1774
1811
|
};
|
|
1775
|
-
//# sourceMappingURL=practice-results-
|
|
1812
|
+
//# sourceMappingURL=practice-results-By2BZFCz.js.map
|