@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,28 +1,28 @@
|
|
|
1
1
|
import { jsx as t, jsxs as h, Fragment as at } from "react/jsx-runtime";
|
|
2
|
-
import { forwardRef as it, useState as me, useRef as
|
|
3
|
-
import { c as
|
|
2
|
+
import { forwardRef as it, useState as me, useRef as F, useMemo as M, useImperativeHandle as st, useCallback as z, useEffect as Y } from "react";
|
|
3
|
+
import { c as O } from "./index-D2ZczOXr.js";
|
|
4
4
|
import { useTranslation as C } from "react-i18next";
|
|
5
|
-
import { A as
|
|
5
|
+
import { A as X } from "./alert-9kEwDza3.js";
|
|
6
6
|
import { A as Se } from "./avatar-a6042Ox2.js";
|
|
7
7
|
import { B as ee } from "./button-DohK_Ak_.js";
|
|
8
8
|
import { D } from "./dropdown-menu-D1we7oAY.js";
|
|
9
9
|
import { E as rt } from "./empty-state-DwJ5YNzz.js";
|
|
10
|
-
import { M as ot } from "./map-view
|
|
10
|
+
import { M as ot } from "./map-view--c9bJDRw.js";
|
|
11
11
|
import { R as Le } from "./rating-CGYpg5dj.js";
|
|
12
12
|
import { S as I } from "./sheet-uZZXaO_S.js";
|
|
13
|
-
import { S as
|
|
14
|
-
import { S as
|
|
13
|
+
import { S as ct } from "./skeleton-tTWJpvAq.js";
|
|
14
|
+
import { S as lt } from "./spinner-CoflYlEx.js";
|
|
15
15
|
import { B as $ } from "./badge-BUk4RjTS.js";
|
|
16
16
|
import { u as dt } from "./use-media-query-CcAx5SMM.js";
|
|
17
17
|
import { b as ut, a as Ce } from "./format-price-BcFBa-WP.js";
|
|
18
18
|
import { u as mt } from "./registry-DvAUVLHh.js";
|
|
19
|
-
import { c as
|
|
20
|
-
import { R as
|
|
19
|
+
import { c as ft } from "./createLucideIcon-DhHxpK9K.js";
|
|
20
|
+
import { R as pt } from "./refresh-cw-DnI0cLFC.js";
|
|
21
21
|
import { C as Pe } from "./chevron-down-DWE7GSq9.js";
|
|
22
22
|
import { L as Ae } from "./languages-CGLX6Qpe.js";
|
|
23
23
|
import { S as Me } from "./shield-check-DCJALLVh.js";
|
|
24
|
-
import { H as
|
|
25
|
-
import { M as
|
|
24
|
+
import { H as Fe } from "./heart--qCA4ffe.js";
|
|
25
|
+
import { M as fe } from "./map-pin-BaY37-Km.js";
|
|
26
26
|
import { C as ht } from "./calendar-clock-hbObjfGY.js";
|
|
27
27
|
import { C as gt } from "./calendar-plus-BFrIRE4r.js";
|
|
28
28
|
/**
|
|
@@ -41,7 +41,7 @@ const vt = [
|
|
|
41
41
|
],
|
|
42
42
|
["path", { d: "M15 5.764v15", key: "1pn4in" }],
|
|
43
43
|
["path", { d: "M9 3.236v15", key: "1uimfh" }]
|
|
44
|
-
], bt =
|
|
44
|
+
], bt = ft("map", vt), xt = {
|
|
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
|
|
@@ -124,6 +124,7 @@ const vt = [
|
|
|
124
124
|
"distance",
|
|
125
125
|
"rating",
|
|
126
126
|
"next-available",
|
|
127
|
+
"price",
|
|
127
128
|
"relevance"
|
|
128
129
|
];
|
|
129
130
|
function Ie(e, n, i) {
|
|
@@ -139,23 +140,23 @@ function B(e, n) {
|
|
|
139
140
|
}
|
|
140
141
|
}
|
|
141
142
|
function Z(e, n, i, s) {
|
|
142
|
-
const r = e.findIndex((
|
|
143
|
+
const r = e.findIndex((l) => l.id === n);
|
|
143
144
|
if (r < 0) return;
|
|
144
145
|
const a = e[r];
|
|
145
146
|
a && (B("serp_result_clicked", { resultId: n, source: i, position: r }), s(a, i));
|
|
146
147
|
}
|
|
147
148
|
function kt(e, n) {
|
|
148
|
-
const s = (n.lat - e.lat) * Math.PI / 180, r = (n.lng - e.lng) * Math.PI / 180, a = e.lat * Math.PI / 180,
|
|
149
|
-
return 2 * 6371 * Math.asin(Math.min(1, Math.sqrt(
|
|
149
|
+
const s = (n.lat - e.lat) * Math.PI / 180, r = (n.lng - e.lng) * Math.PI / 180, a = e.lat * Math.PI / 180, l = n.lat * Math.PI / 180, d = Math.sin(s / 2), o = Math.sin(r / 2), p = d * d + Math.cos(a) * Math.cos(l) * o * o;
|
|
150
|
+
return 2 * 6371 * Math.asin(Math.min(1, Math.sqrt(p)));
|
|
150
151
|
}
|
|
151
152
|
function Ct(e, n, i) {
|
|
152
153
|
var r;
|
|
153
154
|
const s = [];
|
|
154
155
|
for (const a of e) {
|
|
155
|
-
const
|
|
156
|
-
(
|
|
156
|
+
const l = a.field ?? a.key, d = (((r = i == null ? void 0 : i[a.key]) == null ? void 0 : r.length) ?? 0) > 0, o = a.type === "boolean" || a.type !== "options" && a.options.length === 0 && (d || n.some(
|
|
157
|
+
(p) => typeof p[l] == "boolean"
|
|
157
158
|
));
|
|
158
|
-
!o && a.options.length === 0 || s.push({ ...a, boolean: o, booleanField:
|
|
159
|
+
!o && a.options.length === 0 || s.push({ ...a, boolean: o, booleanField: l });
|
|
159
160
|
}
|
|
160
161
|
return s;
|
|
161
162
|
}
|
|
@@ -168,28 +169,47 @@ function Rt(e, n, i) {
|
|
|
168
169
|
if (s[r.booleanField] !== !0) return !1;
|
|
169
170
|
continue;
|
|
170
171
|
}
|
|
171
|
-
const
|
|
172
|
-
if (!Array.isArray(
|
|
172
|
+
const l = r.key === "insurance" ? s.insurances : r.key === "language" ? s.languages : s[r.key];
|
|
173
|
+
if (!Array.isArray(l) || !(r.multi ? a.some((o) => l.includes(o)) : l.includes(a[0]))) return !1;
|
|
173
174
|
}
|
|
174
175
|
return !0;
|
|
175
176
|
});
|
|
176
177
|
}
|
|
177
|
-
function Nt(e
|
|
178
|
+
function Nt(e) {
|
|
179
|
+
const n = e.firstVisitPrice && Number.isFinite(e.firstVisitPrice.minCents) ? e.firstVisitPrice.minCents : e.firstVisitPriceCents;
|
|
180
|
+
return n != null && Number.isFinite(n) && n >= 0 ? n : 1 / 0;
|
|
181
|
+
}
|
|
182
|
+
function St(e) {
|
|
183
|
+
return e.firstVisitPrice && Number.isFinite(e.firstVisitPrice.minCents) ? e.firstVisitPrice.kind === "fixed" : !0;
|
|
184
|
+
}
|
|
185
|
+
function Re(e, n) {
|
|
186
|
+
return e == null && n == null ? 0 : e == null ? 1 : n == null ? -1 : e - n;
|
|
187
|
+
}
|
|
188
|
+
function Lt(e, n, i) {
|
|
178
189
|
const s = e.map((a) => {
|
|
179
|
-
const
|
|
180
|
-
return {
|
|
181
|
-
|
|
182
|
-
|
|
190
|
+
const l = a.location ? a.location.distanceKm ?? (i ? kt(i, a.location) : void 0) : void 0;
|
|
191
|
+
return {
|
|
192
|
+
result: a,
|
|
193
|
+
distanceKm: l,
|
|
194
|
+
price: n === "price" ? Nt(a) : void 0,
|
|
195
|
+
fixed: n === "price" ? St(a) : !1
|
|
196
|
+
};
|
|
197
|
+
}), r = (a, l) => {
|
|
198
|
+
var d, o, p, c;
|
|
183
199
|
switch (n) {
|
|
184
200
|
case "distance":
|
|
185
|
-
return a.distanceKm
|
|
201
|
+
return Re(a.distanceKm, l.distanceKm);
|
|
202
|
+
case "price": {
|
|
203
|
+
const u = a.price ?? 1 / 0, f = l.price ?? 1 / 0;
|
|
204
|
+
return u !== f ? u - f : u !== 1 / 0 && a.fixed !== l.fixed ? a.fixed ? -1 : 1 : Re(a.distanceKm, l.distanceKm);
|
|
205
|
+
}
|
|
186
206
|
case "rating": {
|
|
187
|
-
const
|
|
188
|
-
return (((o =
|
|
207
|
+
const u = ((d = a.result.rating) == null ? void 0 : d.value) ?? -1;
|
|
208
|
+
return (((o = l.result.rating) == null ? void 0 : o.value) ?? -1) - u;
|
|
189
209
|
}
|
|
190
210
|
case "next-available": {
|
|
191
|
-
const
|
|
192
|
-
return !
|
|
211
|
+
const u = ((p = a.result.nextAvailableSlot) == null ? void 0 : p.dateTime) ?? "", f = ((c = l.result.nextAvailableSlot) == null ? void 0 : c.dateTime) ?? "";
|
|
212
|
+
return !u && !f ? 0 : u ? f ? u.localeCompare(f) : -1 : 1;
|
|
193
213
|
}
|
|
194
214
|
case "relevance":
|
|
195
215
|
default:
|
|
@@ -197,24 +217,24 @@ function Nt(e, n, i) {
|
|
|
197
217
|
}
|
|
198
218
|
};
|
|
199
219
|
return [...s].sort(r).map(
|
|
200
|
-
({ result: a, distanceKm:
|
|
220
|
+
({ result: a, distanceKm: l }) => l != null && a.location ? {
|
|
201
221
|
...a,
|
|
202
|
-
location: { ...a.location, distanceKm:
|
|
222
|
+
location: { ...a.location, distanceKm: l }
|
|
203
223
|
} : a
|
|
204
224
|
);
|
|
205
225
|
}
|
|
206
|
-
function
|
|
226
|
+
function Pt(e) {
|
|
207
227
|
let n = -1 / 0, i = 1 / 0, s = -1 / 0, r = 1 / 0, a = !1;
|
|
208
|
-
for (const
|
|
209
|
-
if (!
|
|
228
|
+
for (const l of e) {
|
|
229
|
+
if (!l.location) continue;
|
|
210
230
|
a = !0;
|
|
211
|
-
const { lat:
|
|
212
|
-
|
|
231
|
+
const { lat: d, lng: o } = l.location;
|
|
232
|
+
d > n && (n = d), d < i && (i = d), o > s && (s = o), o < r && (r = o);
|
|
213
233
|
}
|
|
214
234
|
if (a)
|
|
215
235
|
return { north: n, south: i, east: s, west: r };
|
|
216
236
|
}
|
|
217
|
-
const
|
|
237
|
+
const At = O(
|
|
218
238
|
"ds:flex ds:w-full ds:flex-col ds:text-[var(--foreground)] ds:gap-[var(--spacing-md)]",
|
|
219
239
|
{
|
|
220
240
|
variants: {
|
|
@@ -227,33 +247,33 @@ const St = V(
|
|
|
227
247
|
defaultVariants: { variant: "split-list-map" }
|
|
228
248
|
}
|
|
229
249
|
);
|
|
230
|
-
function
|
|
250
|
+
function Te({
|
|
231
251
|
heading: e,
|
|
232
252
|
headingLevel: n,
|
|
233
253
|
intro: i,
|
|
234
254
|
totalCount: s,
|
|
235
255
|
searchCentreLabel: r
|
|
236
256
|
}) {
|
|
237
|
-
const { t: a } = C("ui"),
|
|
257
|
+
const { t: a } = C("ui"), l = `h${n}`;
|
|
238
258
|
if (!e && !i && s == null) return null;
|
|
239
|
-
const
|
|
259
|
+
const d = s != null ? r ? a("practiceResults.results.heading", {
|
|
240
260
|
count: s,
|
|
241
261
|
place: r
|
|
242
262
|
}) : a("practiceResults.results.summary", { count: s }) : void 0;
|
|
243
263
|
return /* @__PURE__ */ h("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-xs)]", children: [
|
|
244
|
-
e ? /* @__PURE__ */ t(
|
|
264
|
+
e ? /* @__PURE__ */ t(l, { className: "type-title-section ds:m-0 ds:text-[var(--foreground)]", children: e }) : null,
|
|
245
265
|
i ? /* @__PURE__ */ t("p", { className: "type-body ds:m-0 ds:text-[var(--muted-foreground)]", children: i }) : null,
|
|
246
|
-
|
|
266
|
+
d ? /* @__PURE__ */ t(
|
|
247
267
|
"p",
|
|
248
268
|
{
|
|
249
269
|
className: "type-body-sm ds:m-0 ds:text-[var(--muted-foreground)]",
|
|
250
270
|
"aria-live": "polite",
|
|
251
|
-
children:
|
|
271
|
+
children: d
|
|
252
272
|
}
|
|
253
273
|
) : null
|
|
254
274
|
] });
|
|
255
275
|
}
|
|
256
|
-
const te =
|
|
276
|
+
const te = O(
|
|
257
277
|
[
|
|
258
278
|
"ds:inline-flex ds:items-center ds:gap-[var(--spacing-xs)]",
|
|
259
279
|
"ds:min-h-[var(--min-target-size)]",
|
|
@@ -275,7 +295,7 @@ const te = V(
|
|
|
275
295
|
},
|
|
276
296
|
defaultVariants: { state: "idle" }
|
|
277
297
|
}
|
|
278
|
-
),
|
|
298
|
+
), Mt = O(
|
|
279
299
|
"ds:flex ds:flex-wrap ds:items-center ds:gap-[var(--spacing-xs)]",
|
|
280
300
|
{
|
|
281
301
|
variants: {
|
|
@@ -294,7 +314,7 @@ const te = V(
|
|
|
294
314
|
},
|
|
295
315
|
defaultVariants: { placement: "inline" }
|
|
296
316
|
}
|
|
297
|
-
),
|
|
317
|
+
), Ft = O(
|
|
298
318
|
[
|
|
299
319
|
"ds:ms-[var(--spacing-xs)] ds:inline-flex ds:items-center ds:gap-[var(--spacing-xs)]",
|
|
300
320
|
"ds:min-h-[var(--min-target-size)] ds:ps-[var(--spacing-xs)] ds:pe-[var(--spacing-xs)]",
|
|
@@ -311,20 +331,20 @@ function _e({
|
|
|
311
331
|
onChange: i,
|
|
312
332
|
floating: s
|
|
313
333
|
}) {
|
|
314
|
-
const { t: r } = C("ui"), a = M(() => n ?? {}, [n]),
|
|
315
|
-
() => Object.values(a).some((
|
|
334
|
+
const { t: r } = C("ui"), a = M(() => n ?? {}, [n]), l = M(
|
|
335
|
+
() => Object.values(a).some((c) => c && c.length > 0),
|
|
316
336
|
[a]
|
|
317
|
-
),
|
|
318
|
-
const
|
|
319
|
-
|
|
320
|
-
}, o = (
|
|
321
|
-
var
|
|
322
|
-
const
|
|
323
|
-
|
|
324
|
-
},
|
|
325
|
-
const
|
|
337
|
+
), d = (c, u) => {
|
|
338
|
+
const f = { ...a };
|
|
339
|
+
u.length === 0 ? delete f[c] : f[c] = u, i(f), B("serp_filter_changed", { key: c, values: u });
|
|
340
|
+
}, o = (c) => {
|
|
341
|
+
var f;
|
|
342
|
+
const u = (((f = a[c]) == null ? void 0 : f.length) ?? 0) > 0;
|
|
343
|
+
d(c, u ? [] : ["true"]);
|
|
344
|
+
}, p = (c, u) => {
|
|
345
|
+
const f = a[c.key] ?? [], x = f.includes(u);
|
|
326
346
|
let g;
|
|
327
|
-
|
|
347
|
+
c.multi ? g = x ? f.filter((y) => y !== u) : [...f, u] : g = x ? [] : [u], d(c.key, g);
|
|
328
348
|
};
|
|
329
349
|
return e.length === 0 ? null : /* @__PURE__ */ h(
|
|
330
350
|
"div",
|
|
@@ -332,40 +352,40 @@ function _e({
|
|
|
332
352
|
"data-component": "practice-results-filters",
|
|
333
353
|
role: "group",
|
|
334
354
|
"aria-label": r("practiceResults.filters.label"),
|
|
335
|
-
className:
|
|
355
|
+
className: Mt({
|
|
336
356
|
placement: s ? "floating" : "inline"
|
|
337
357
|
}),
|
|
338
358
|
children: [
|
|
339
|
-
e.map((
|
|
340
|
-
const
|
|
341
|
-
if (
|
|
359
|
+
e.map((c) => {
|
|
360
|
+
const u = c.boolean, f = a[c.key] ?? [], x = f.length > 0;
|
|
361
|
+
if (u)
|
|
342
362
|
return /* @__PURE__ */ t(
|
|
343
363
|
"button",
|
|
344
364
|
{
|
|
345
365
|
type: "button",
|
|
346
|
-
"aria-pressed":
|
|
347
|
-
"aria-label":
|
|
348
|
-
onClick: () => o(
|
|
366
|
+
"aria-pressed": x,
|
|
367
|
+
"aria-label": c.label,
|
|
368
|
+
onClick: () => o(c.key),
|
|
349
369
|
className: te({
|
|
350
|
-
state:
|
|
370
|
+
state: x ? "active" : "idle"
|
|
351
371
|
}),
|
|
352
|
-
children: /* @__PURE__ */ t("span", { children:
|
|
372
|
+
children: /* @__PURE__ */ t("span", { children: c.label })
|
|
353
373
|
},
|
|
354
|
-
|
|
374
|
+
c.key
|
|
355
375
|
);
|
|
356
|
-
const g =
|
|
376
|
+
const g = x ? ` (${f.length})` : "";
|
|
357
377
|
return /* @__PURE__ */ h(D.Root, { children: [
|
|
358
378
|
/* @__PURE__ */ t(D.Trigger, { asChild: !0, children: /* @__PURE__ */ h(
|
|
359
379
|
"button",
|
|
360
380
|
{
|
|
361
381
|
type: "button",
|
|
362
|
-
"aria-label": `${
|
|
382
|
+
"aria-label": `${c.label}${g}`,
|
|
363
383
|
className: te({
|
|
364
|
-
state:
|
|
384
|
+
state: x ? "active" : "idle"
|
|
365
385
|
}),
|
|
366
386
|
children: [
|
|
367
387
|
/* @__PURE__ */ h("span", { children: [
|
|
368
|
-
|
|
388
|
+
c.label,
|
|
369
389
|
g
|
|
370
390
|
] }),
|
|
371
391
|
/* @__PURE__ */ t(
|
|
@@ -378,27 +398,27 @@ function _e({
|
|
|
378
398
|
]
|
|
379
399
|
}
|
|
380
400
|
) }),
|
|
381
|
-
/* @__PURE__ */ t(D.Content, { sideOffset: 8, align: "start", children:
|
|
401
|
+
/* @__PURE__ */ t(D.Content, { sideOffset: 8, align: "start", children: c.options.map((y) => /* @__PURE__ */ t(
|
|
382
402
|
D.CheckboxItem,
|
|
383
403
|
{
|
|
384
|
-
checked:
|
|
404
|
+
checked: f.includes(y.value),
|
|
385
405
|
onSelect: (k) => {
|
|
386
|
-
|
|
406
|
+
c.multi && k.preventDefault(), p(c, y.value);
|
|
387
407
|
},
|
|
388
|
-
children:
|
|
408
|
+
children: y.label
|
|
389
409
|
},
|
|
390
|
-
|
|
410
|
+
y.value
|
|
391
411
|
)) })
|
|
392
|
-
] },
|
|
412
|
+
] }, c.key);
|
|
393
413
|
}),
|
|
394
|
-
|
|
414
|
+
l ? /* @__PURE__ */ t(
|
|
395
415
|
"button",
|
|
396
416
|
{
|
|
397
417
|
type: "button",
|
|
398
418
|
onClick: () => {
|
|
399
419
|
i({}), B("serp_filter_changed", { key: "*", values: [] });
|
|
400
420
|
},
|
|
401
|
-
className:
|
|
421
|
+
className: Ft(),
|
|
402
422
|
children: r("practiceResults.filters.clear")
|
|
403
423
|
}
|
|
404
424
|
) : null
|
|
@@ -415,6 +435,8 @@ function de({ value: e, onChange: n }) {
|
|
|
415
435
|
return i("practiceResults.sort.rating");
|
|
416
436
|
case "next-available":
|
|
417
437
|
return i("practiceResults.sort.nextAvailable");
|
|
438
|
+
case "price":
|
|
439
|
+
return i("practiceResults.sort.price");
|
|
418
440
|
case "relevance":
|
|
419
441
|
default:
|
|
420
442
|
return i("practiceResults.sort.relevance");
|
|
@@ -450,7 +472,7 @@ function de({ value: e, onChange: n }) {
|
|
|
450
472
|
) })
|
|
451
473
|
] });
|
|
452
474
|
}
|
|
453
|
-
function
|
|
475
|
+
function It({ distanceKm: e }) {
|
|
454
476
|
const { t: n, i18n: i } = C("ui"), s = M(() => {
|
|
455
477
|
if (e < 1) return n("practiceResults.distance.below");
|
|
456
478
|
const r = new Intl.NumberFormat(i.language, {
|
|
@@ -458,9 +480,9 @@ function At({ distanceKm: e }) {
|
|
|
458
480
|
}).format(e);
|
|
459
481
|
return n("practiceResults.distance.km", { distance: r });
|
|
460
482
|
}, [e, n, i.language]);
|
|
461
|
-
return /* @__PURE__ */ t($, { variant: "neutral", leading: /* @__PURE__ */ t(
|
|
483
|
+
return /* @__PURE__ */ t($, { variant: "neutral", leading: /* @__PURE__ */ t(fe, { "aria-hidden": "true" }), children: s });
|
|
462
484
|
}
|
|
463
|
-
const Ne =
|
|
485
|
+
const Ne = O(
|
|
464
486
|
[
|
|
465
487
|
"ds:inline-size-[12rem] ds:block-size-[8rem] ds:shrink-0",
|
|
466
488
|
"ds:rounded-[var(--radius-md)] ds:overflow-hidden"
|
|
@@ -479,12 +501,12 @@ const Ne = V(
|
|
|
479
501
|
defaultVariants: { state: "placeholder" }
|
|
480
502
|
}
|
|
481
503
|
);
|
|
482
|
-
function
|
|
504
|
+
function Tt() {
|
|
483
505
|
if (typeof document > "u") return "4945a3";
|
|
484
506
|
const e = getComputedStyle(document.documentElement).getPropertyValue("--map-marker-color").trim(), n = /^#?([0-9a-fA-F]{6})$/.exec(e);
|
|
485
507
|
return n ? n[1] : "4945a3";
|
|
486
508
|
}
|
|
487
|
-
function
|
|
509
|
+
function _t({
|
|
488
510
|
apiKey: e,
|
|
489
511
|
center: n,
|
|
490
512
|
zoom: i = 14,
|
|
@@ -498,16 +520,16 @@ function Tt({
|
|
|
498
520
|
"aria-hidden": s ? void 0 : "true",
|
|
499
521
|
className: Ne({ state: "placeholder" }),
|
|
500
522
|
children: [
|
|
501
|
-
/* @__PURE__ */ t(
|
|
523
|
+
/* @__PURE__ */ t(fe, { "aria-hidden": "true", className: "ds:size-5 ds:shrink-0" }),
|
|
502
524
|
s ? /* @__PURE__ */ t("span", { dir: "auto", className: "type-meta ds:[overflow-wrap:anywhere]", children: s }) : null
|
|
503
525
|
]
|
|
504
526
|
}
|
|
505
527
|
);
|
|
506
|
-
const a =
|
|
528
|
+
const a = Tt(), l = `https://maps.googleapis.com/maps/api/staticmap?center=${n.lat},${n.lng}&zoom=${i}&size=240x160&scale=2&markers=color:0x${a}%7C${n.lat},${n.lng}&key=${encodeURIComponent(e)}`;
|
|
507
529
|
return /* @__PURE__ */ t(
|
|
508
530
|
"img",
|
|
509
531
|
{
|
|
510
|
-
src:
|
|
532
|
+
src: l,
|
|
511
533
|
alt: r("practiceResults.thumbnail.alt"),
|
|
512
534
|
loading: "lazy",
|
|
513
535
|
decoding: "async",
|
|
@@ -517,7 +539,7 @@ function Tt({
|
|
|
517
539
|
}
|
|
518
540
|
);
|
|
519
541
|
}
|
|
520
|
-
function
|
|
542
|
+
function Vt({ tagline: e }) {
|
|
521
543
|
return e ? /* @__PURE__ */ t(
|
|
522
544
|
"span",
|
|
523
545
|
{
|
|
@@ -528,7 +550,7 @@ function It({ tagline: e }) {
|
|
|
528
550
|
}
|
|
529
551
|
) : null;
|
|
530
552
|
}
|
|
531
|
-
const
|
|
553
|
+
const Ht = O(
|
|
532
554
|
"type-body-sm ds:m-0 ds:text-[var(--muted-foreground)] ds:whitespace-pre-line ds:break-words",
|
|
533
555
|
{
|
|
534
556
|
variants: {
|
|
@@ -540,7 +562,7 @@ const Ft = V(
|
|
|
540
562
|
defaultVariants: { density: "compact" }
|
|
541
563
|
}
|
|
542
564
|
);
|
|
543
|
-
function
|
|
565
|
+
function Ve({
|
|
544
566
|
description: e,
|
|
545
567
|
density: n
|
|
546
568
|
}) {
|
|
@@ -549,12 +571,12 @@ function He({
|
|
|
549
571
|
{
|
|
550
572
|
"data-component": "practice-result-description",
|
|
551
573
|
dir: "auto",
|
|
552
|
-
className:
|
|
574
|
+
className: Ht({ density: n }),
|
|
553
575
|
children: e
|
|
554
576
|
}
|
|
555
577
|
) : null;
|
|
556
578
|
}
|
|
557
|
-
function
|
|
579
|
+
function zt(e, n, i, s) {
|
|
558
580
|
if (e.kind === "fixed")
|
|
559
581
|
return ut(
|
|
560
582
|
e.minCents,
|
|
@@ -568,7 +590,7 @@ function _t(e, n, i, s) {
|
|
|
568
590
|
max: Ce(e.maxCents, n, i)
|
|
569
591
|
}) : s("practiceResults.card.priceFrom", { price: r });
|
|
570
592
|
}
|
|
571
|
-
const
|
|
593
|
+
const $t = O(
|
|
572
594
|
"ds:min-w-0 ds:max-w-full ds:[overflow-wrap:anywhere]",
|
|
573
595
|
{
|
|
574
596
|
variants: {
|
|
@@ -576,23 +598,23 @@ const Ht = V(
|
|
|
576
598
|
}
|
|
577
599
|
}
|
|
578
600
|
);
|
|
579
|
-
function
|
|
601
|
+
function Bt({
|
|
580
602
|
price: e,
|
|
581
603
|
cents: n,
|
|
582
604
|
currencyCode: i = "EUR"
|
|
583
605
|
}) {
|
|
584
|
-
var
|
|
585
|
-
const { t: s, i18n: r } = C("ui"), a = e && Number.isFinite(e.minCents) ? e : void 0,
|
|
586
|
-
() =>
|
|
587
|
-
{ kind:
|
|
606
|
+
var f;
|
|
607
|
+
const { t: s, i18n: r } = C("ui"), a = e && Number.isFinite(e.minCents) ? e : void 0, l = (a == null ? void 0 : a.kind) ?? "fixed", d = (a == null ? void 0 : a.minCents) ?? n, o = a == null ? void 0 : a.maxCents, p = M(
|
|
608
|
+
() => d == null ? void 0 : zt(
|
|
609
|
+
{ kind: l, minCents: d, maxCents: o },
|
|
588
610
|
i,
|
|
589
611
|
r.language ?? "en",
|
|
590
612
|
s
|
|
591
613
|
),
|
|
592
|
-
[
|
|
614
|
+
[l, d, o, i, r.language, s]
|
|
593
615
|
);
|
|
594
|
-
if (
|
|
595
|
-
const
|
|
616
|
+
if (p === void 0) return null;
|
|
617
|
+
const c = (f = a == null ? void 0 : a.label) == null ? void 0 : f.trim().replace(/:$/, "").trim(), u = c || s("practiceResults.card.firstVisitPrice");
|
|
596
618
|
return /* @__PURE__ */ h(
|
|
597
619
|
"span",
|
|
598
620
|
{
|
|
@@ -603,11 +625,11 @@ function zt({
|
|
|
603
625
|
"span",
|
|
604
626
|
{
|
|
605
627
|
dir: "auto",
|
|
606
|
-
title:
|
|
607
|
-
className:
|
|
608
|
-
practiceWritten: !!
|
|
628
|
+
title: u,
|
|
629
|
+
className: $t({
|
|
630
|
+
practiceWritten: !!c
|
|
609
631
|
}),
|
|
610
|
-
children:
|
|
632
|
+
children: u
|
|
611
633
|
}
|
|
612
634
|
),
|
|
613
635
|
/* @__PURE__ */ t("span", { className: "ds:sr-only", children: ": " }),
|
|
@@ -618,14 +640,14 @@ function zt({
|
|
|
618
640
|
size: "lg",
|
|
619
641
|
dir: "auto",
|
|
620
642
|
className: "ds:h-auto ds:min-h-6 ds:min-w-0 ds:max-w-full ds:whitespace-normal ds:[overflow-wrap:anywhere]",
|
|
621
|
-
children:
|
|
643
|
+
children: p
|
|
622
644
|
}
|
|
623
645
|
)
|
|
624
646
|
]
|
|
625
647
|
}
|
|
626
648
|
);
|
|
627
649
|
}
|
|
628
|
-
function
|
|
650
|
+
function He({ time: e }) {
|
|
629
651
|
const { t: n } = C("ui");
|
|
630
652
|
return /* @__PURE__ */ h("span", { className: "type-body-sm ds:text-[var(--muted-foreground)] ds:inline-flex ds:items-center ds:gap-[var(--spacing-xs)]", children: [
|
|
631
653
|
/* @__PURE__ */ t(
|
|
@@ -638,7 +660,7 @@ function ze({ time: e }) {
|
|
|
638
660
|
n("practiceResults.nextSlot.summary", { time: e })
|
|
639
661
|
] });
|
|
640
662
|
}
|
|
641
|
-
function
|
|
663
|
+
function ze({
|
|
642
664
|
result: e,
|
|
643
665
|
openLabel: n,
|
|
644
666
|
bookLabel: i,
|
|
@@ -646,7 +668,7 @@ function $e({
|
|
|
646
668
|
onOpenClick: r,
|
|
647
669
|
onBookClick: a
|
|
648
670
|
}) {
|
|
649
|
-
const { t:
|
|
671
|
+
const { t: l } = C("ui"), d = e.nextAvailableSlot, o = (d == null ? void 0 : d.bookingHref) ?? e.bookingHref ?? e.href, p = d && s ? l("practiceResults.nextSlot.cta", { time: s }) : i;
|
|
650
672
|
return /* @__PURE__ */ h("div", { className: "ds:mt-[var(--spacing-xs)] ds:flex ds:flex-wrap ds:items-center ds:justify-end ds:gap-[var(--spacing-xs)]", children: [
|
|
651
673
|
n !== void 0 ? /* @__PURE__ */ t(ee, { intent: "secondary", size: "sm", asChild: !0, onClick: r, children: /* @__PURE__ */ h("a", { href: e.href, "data-component": "practice-result-open-cta", children: [
|
|
652
674
|
n,
|
|
@@ -666,9 +688,9 @@ function $e({
|
|
|
666
688
|
{
|
|
667
689
|
href: o,
|
|
668
690
|
"data-component": "practice-result-book-cta",
|
|
669
|
-
"data-slot-aware":
|
|
691
|
+
"data-slot-aware": d ? "true" : void 0,
|
|
670
692
|
children: [
|
|
671
|
-
|
|
693
|
+
p,
|
|
672
694
|
" ",
|
|
673
695
|
/* @__PURE__ */ t("span", { className: "ds:sr-only", children: e.name })
|
|
674
696
|
]
|
|
@@ -678,7 +700,7 @@ function $e({
|
|
|
678
700
|
)
|
|
679
701
|
] });
|
|
680
702
|
}
|
|
681
|
-
const
|
|
703
|
+
const $e = O(
|
|
682
704
|
[
|
|
683
705
|
"ds:@container/result-card ds:relative ds:flex ds:w-full ds:cursor-pointer",
|
|
684
706
|
"ds:rounded-[var(--radius-lg)]",
|
|
@@ -706,14 +728,14 @@ const Be = V(
|
|
|
706
728
|
},
|
|
707
729
|
defaultVariants: { density: "compact" }
|
|
708
730
|
}
|
|
709
|
-
),
|
|
731
|
+
), Dt = O([
|
|
710
732
|
"ds:text-[var(--foreground)] ds:no-underline ds:hover:underline",
|
|
711
733
|
"ds:rounded-[var(--radius-xs)]",
|
|
712
734
|
"ds:focus-visible:outline-[length:var(--focus-ring-width)] ds:focus-visible:outline-solid",
|
|
713
735
|
"ds:focus-visible:outline-[color:var(--ring)] ds:focus-visible:outline-offset-[length:var(--focus-ring-offset)]",
|
|
714
736
|
"ds:forced-colors:focus-visible:outline-[CanvasText]"
|
|
715
737
|
]);
|
|
716
|
-
function
|
|
738
|
+
function Ot({
|
|
717
739
|
result: e,
|
|
718
740
|
headingLevel: n
|
|
719
741
|
}) {
|
|
@@ -730,14 +752,14 @@ function Bt({
|
|
|
730
752
|
href: e.href,
|
|
731
753
|
dir: "auto",
|
|
732
754
|
"data-component": "practice-result-name-link",
|
|
733
|
-
className:
|
|
755
|
+
className: Dt(),
|
|
734
756
|
children: e.name
|
|
735
757
|
}
|
|
736
758
|
)
|
|
737
759
|
}
|
|
738
760
|
);
|
|
739
761
|
}
|
|
740
|
-
function
|
|
762
|
+
function Be({
|
|
741
763
|
result: e,
|
|
742
764
|
headingLevel: n
|
|
743
765
|
}) {
|
|
@@ -750,18 +772,18 @@ function Oe({
|
|
|
750
772
|
children: /* @__PURE__ */ h("div", { className: "ds:flex ds:min-w-0 ds:flex-col ds:items-start ds:gap-[var(--spacing-xs)] ds:sm:@min-[280px]/result-heading:flex-row ds:sm:@min-[280px]/result-heading:gap-[var(--spacing-md)]", children: [
|
|
751
773
|
/* @__PURE__ */ h("div", { className: "ds:flex ds:min-w-0 ds:w-full ds:flex-1 ds:flex-col ds:gap-[var(--spacing-2xs)]", children: [
|
|
752
774
|
/* @__PURE__ */ h("div", { className: "ds:flex ds:flex-wrap ds:items-center ds:gap-[var(--spacing-xs)]", children: [
|
|
753
|
-
/* @__PURE__ */ t(
|
|
754
|
-
((i = e.location) == null ? void 0 : i.distanceKm) != null ? /* @__PURE__ */ t(
|
|
775
|
+
/* @__PURE__ */ t(Ot, { result: e, headingLevel: n }),
|
|
776
|
+
((i = e.location) == null ? void 0 : i.distanceKm) != null ? /* @__PURE__ */ t(It, { distanceKm: e.location.distanceKm }) : null
|
|
755
777
|
] }),
|
|
756
778
|
e.subtitle ? /* @__PURE__ */ t("span", { className: "type-body-sm ds:text-[var(--muted-foreground)]", children: e.subtitle }) : null,
|
|
757
|
-
/* @__PURE__ */ t(
|
|
779
|
+
/* @__PURE__ */ t(Vt, { tagline: e.tagline }),
|
|
758
780
|
(s = e.location) != null && s.address ? /* @__PURE__ */ h(
|
|
759
781
|
"span",
|
|
760
782
|
{
|
|
761
783
|
"data-component": "practice-result-address",
|
|
762
784
|
className: "type-meta ds:text-[var(--muted-foreground)] ds:inline-flex ds:items-center ds:gap-[var(--spacing-2xs)]",
|
|
763
785
|
children: [
|
|
764
|
-
/* @__PURE__ */ t(
|
|
786
|
+
/* @__PURE__ */ t(fe, { "aria-hidden": "true", className: "ds:size-3.5 ds:shrink-0" }),
|
|
765
787
|
/* @__PURE__ */ t(
|
|
766
788
|
"span",
|
|
767
789
|
{
|
|
@@ -775,7 +797,7 @@ function Oe({
|
|
|
775
797
|
) : null
|
|
776
798
|
] }),
|
|
777
799
|
/* @__PURE__ */ t(
|
|
778
|
-
|
|
800
|
+
Bt,
|
|
779
801
|
{
|
|
780
802
|
price: e.firstVisitPrice,
|
|
781
803
|
cents: e.firstVisitPriceCents,
|
|
@@ -792,24 +814,24 @@ function De(e) {
|
|
|
792
814
|
);
|
|
793
815
|
return n !== null && n !== e.currentTarget && e.currentTarget.contains(n);
|
|
794
816
|
}
|
|
795
|
-
function
|
|
817
|
+
function Et({
|
|
796
818
|
result: e,
|
|
797
819
|
headingLevel: n,
|
|
798
820
|
highlighted: i,
|
|
799
821
|
onSelect: s,
|
|
800
822
|
onOpenClick: r,
|
|
801
823
|
onHover: a,
|
|
802
|
-
density:
|
|
803
|
-
openLabel:
|
|
824
|
+
density: l = "compact",
|
|
825
|
+
openLabel: d,
|
|
804
826
|
bookLabel: o,
|
|
805
|
-
onBookClick:
|
|
806
|
-
nextSlotText:
|
|
807
|
-
maxInsuranceChips:
|
|
808
|
-
maxLanguageChips:
|
|
809
|
-
children:
|
|
827
|
+
onBookClick: p,
|
|
828
|
+
nextSlotText: c,
|
|
829
|
+
maxInsuranceChips: u = 3,
|
|
830
|
+
maxLanguageChips: f = 4,
|
|
831
|
+
children: x
|
|
810
832
|
}) {
|
|
811
|
-
var q, U, G,
|
|
812
|
-
const { t: g, i18n:
|
|
833
|
+
var q, U, G, E;
|
|
834
|
+
const { t: g, i18n: y } = C("ui"), k = e.rating, w = (((q = e.languages) == null ? void 0 : q.length) ?? 0) > 0, b = (((U = e.insurances) == null ? void 0 : U.length) ?? 0) > 0, m = e.specializedInFearPatients, N = w || b || m, L = (e.languages ?? []).slice(0, f), T = (((G = e.languages) == null ? void 0 : G.length) ?? 0) - L.length, _ = (e.insurances ?? []).slice(0, u), P = (((E = e.insurances) == null ? void 0 : E.length) ?? 0) - _.length;
|
|
813
835
|
return (
|
|
814
836
|
// 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.
|
|
815
837
|
/* @__PURE__ */ h(
|
|
@@ -825,7 +847,7 @@ function Ot({
|
|
|
825
847
|
},
|
|
826
848
|
onMouseEnter: a,
|
|
827
849
|
onFocus: a,
|
|
828
|
-
className:
|
|
850
|
+
className: $e({ density: l }),
|
|
829
851
|
children: [
|
|
830
852
|
/* @__PURE__ */ t(
|
|
831
853
|
Se,
|
|
@@ -839,7 +861,7 @@ function Ot({
|
|
|
839
861
|
}
|
|
840
862
|
),
|
|
841
863
|
/* @__PURE__ */ h("div", { className: "ds:flex ds:min-w-0 ds:flex-1 ds:flex-col ds:gap-[var(--spacing-xs)]", children: [
|
|
842
|
-
/* @__PURE__ */ t(
|
|
864
|
+
/* @__PURE__ */ t(Be, { result: e, headingLevel: n }),
|
|
843
865
|
k && k.count > 0 ? /* @__PURE__ */ t(
|
|
844
866
|
Le,
|
|
845
867
|
{
|
|
@@ -848,17 +870,17 @@ function Ot({
|
|
|
848
870
|
size: "sm"
|
|
849
871
|
}
|
|
850
872
|
) : null,
|
|
851
|
-
|
|
852
|
-
|
|
873
|
+
N ? /* @__PURE__ */ h("div", { className: "ds:flex ds:flex-wrap ds:items-center ds:gap-[var(--spacing-xs)]", children: [
|
|
874
|
+
L.map((A) => /* @__PURE__ */ t(
|
|
853
875
|
$,
|
|
854
876
|
{
|
|
855
877
|
variant: "neutral",
|
|
856
878
|
leading: /* @__PURE__ */ t(Ae, { "aria-hidden": "true" }),
|
|
857
|
-
children: Ie(A, g,
|
|
879
|
+
children: Ie(A, g, y)
|
|
858
880
|
},
|
|
859
881
|
`lang-${A}`
|
|
860
882
|
)),
|
|
861
|
-
|
|
883
|
+
T > 0 ? /* @__PURE__ */ t($, { variant: "neutral", children: `+${T}` }) : null,
|
|
862
884
|
_.map((A) => /* @__PURE__ */ t(
|
|
863
885
|
$,
|
|
864
886
|
{
|
|
@@ -868,21 +890,21 @@ function Ot({
|
|
|
868
890
|
},
|
|
869
891
|
`ins-${A}`
|
|
870
892
|
)),
|
|
871
|
-
|
|
872
|
-
|
|
893
|
+
P > 0 ? /* @__PURE__ */ t($, { variant: "neutral", children: `+${P}` }) : null,
|
|
894
|
+
m ? /* @__PURE__ */ t($, { variant: "info", leading: /* @__PURE__ */ t(Fe, { "aria-hidden": "true" }), children: g("practiceResults.fearPatient.label") }) : null
|
|
873
895
|
] }) : null,
|
|
874
|
-
/* @__PURE__ */ t(
|
|
875
|
-
e.nextAvailableSlot &&
|
|
876
|
-
|
|
896
|
+
/* @__PURE__ */ t(Ve, { description: e.description, density: "compact" }),
|
|
897
|
+
e.nextAvailableSlot && c ? /* @__PURE__ */ t(He, { time: c }) : null,
|
|
898
|
+
x,
|
|
877
899
|
/* @__PURE__ */ t(
|
|
878
|
-
|
|
900
|
+
ze,
|
|
879
901
|
{
|
|
880
902
|
result: e,
|
|
881
|
-
openLabel:
|
|
903
|
+
openLabel: d,
|
|
882
904
|
bookLabel: o,
|
|
883
|
-
nextSlotText:
|
|
905
|
+
nextSlotText: c,
|
|
884
906
|
onOpenClick: r,
|
|
885
|
-
onBookClick:
|
|
907
|
+
onBookClick: p
|
|
886
908
|
}
|
|
887
909
|
)
|
|
888
910
|
] })
|
|
@@ -891,23 +913,23 @@ function Ot({
|
|
|
891
913
|
)
|
|
892
914
|
);
|
|
893
915
|
}
|
|
894
|
-
function
|
|
916
|
+
function jt({
|
|
895
917
|
result: e,
|
|
896
918
|
headingLevel: n,
|
|
897
919
|
apiKey: i,
|
|
898
920
|
highlighted: s,
|
|
899
921
|
onSelect: r,
|
|
900
922
|
onOpenClick: a,
|
|
901
|
-
onBookClick:
|
|
902
|
-
onHover:
|
|
923
|
+
onBookClick: l,
|
|
924
|
+
onHover: d,
|
|
903
925
|
openLabel: o,
|
|
904
|
-
bookLabel:
|
|
926
|
+
bookLabel: p
|
|
905
927
|
}) {
|
|
906
|
-
var
|
|
907
|
-
const { t:
|
|
928
|
+
var w, b;
|
|
929
|
+
const { t: c, i18n: u } = C("ui"), f = M(() => {
|
|
908
930
|
if (e.nextAvailableSlot)
|
|
909
931
|
try {
|
|
910
|
-
return new Intl.DateTimeFormat(
|
|
932
|
+
return new Intl.DateTimeFormat(u.language, {
|
|
911
933
|
weekday: "short",
|
|
912
934
|
hour: "numeric",
|
|
913
935
|
minute: "numeric"
|
|
@@ -915,7 +937,7 @@ function Dt({
|
|
|
915
937
|
} catch {
|
|
916
938
|
return e.nextAvailableSlot.dateTime;
|
|
917
939
|
}
|
|
918
|
-
}, [e.nextAvailableSlot,
|
|
940
|
+
}, [e.nextAvailableSlot, u.language]), x = (((w = e.languages) == null ? void 0 : w.length) ?? 0) > 0, g = (((b = e.insurances) == null ? void 0 : b.length) ?? 0) > 0, y = e.specializedInFearPatients, k = x || g || y;
|
|
919
941
|
return (
|
|
920
942
|
// 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.
|
|
921
943
|
/* @__PURE__ */ h(
|
|
@@ -927,15 +949,15 @@ function Dt({
|
|
|
927
949
|
"data-highlighted": s ? "true" : "false",
|
|
928
950
|
role: "group",
|
|
929
951
|
"aria-labelledby": `practice-result-${e.id}-name`,
|
|
930
|
-
onClick: (
|
|
931
|
-
De(
|
|
952
|
+
onClick: (m) => {
|
|
953
|
+
De(m) || r();
|
|
932
954
|
},
|
|
933
|
-
onMouseEnter:
|
|
934
|
-
onFocus:
|
|
935
|
-
className:
|
|
955
|
+
onMouseEnter: d,
|
|
956
|
+
onFocus: d,
|
|
957
|
+
className: $e({ density: "rich" }),
|
|
936
958
|
children: [
|
|
937
959
|
e.location ? /* @__PURE__ */ t("div", { className: "ds:hidden ds:@min-[640px]/result-card:block", children: /* @__PURE__ */ t(
|
|
938
|
-
|
|
960
|
+
_t,
|
|
939
961
|
{
|
|
940
962
|
apiKey: i,
|
|
941
963
|
center: {
|
|
@@ -958,7 +980,7 @@ function Dt({
|
|
|
958
980
|
ratio: "4:3"
|
|
959
981
|
}
|
|
960
982
|
),
|
|
961
|
-
/* @__PURE__ */ t(
|
|
983
|
+
/* @__PURE__ */ t(Be, { result: e, headingLevel: n })
|
|
962
984
|
] }),
|
|
963
985
|
e.rating && e.rating.count > 0 ? /* @__PURE__ */ t(
|
|
964
986
|
Le,
|
|
@@ -969,37 +991,37 @@ function Dt({
|
|
|
969
991
|
}
|
|
970
992
|
) : null,
|
|
971
993
|
k ? /* @__PURE__ */ h("div", { className: "ds:flex ds:flex-wrap ds:items-center ds:gap-[var(--spacing-xs)]", children: [
|
|
972
|
-
|
|
994
|
+
x ? (e.languages ?? []).map((m) => /* @__PURE__ */ t(
|
|
973
995
|
$,
|
|
974
996
|
{
|
|
975
997
|
variant: "neutral",
|
|
976
998
|
leading: /* @__PURE__ */ t(Ae, { "aria-hidden": "true" }),
|
|
977
|
-
children: Ie(
|
|
999
|
+
children: Ie(m, c, u)
|
|
978
1000
|
},
|
|
979
|
-
`lang-${
|
|
1001
|
+
`lang-${m}`
|
|
980
1002
|
)) : null,
|
|
981
|
-
g ? (e.insurances ?? []).map((
|
|
1003
|
+
g ? (e.insurances ?? []).map((m) => /* @__PURE__ */ t(
|
|
982
1004
|
$,
|
|
983
1005
|
{
|
|
984
1006
|
variant: "info",
|
|
985
1007
|
leading: /* @__PURE__ */ t(Me, { "aria-hidden": "true" }),
|
|
986
|
-
children:
|
|
1008
|
+
children: m
|
|
987
1009
|
},
|
|
988
|
-
`ins-${
|
|
1010
|
+
`ins-${m}`
|
|
989
1011
|
)) : null,
|
|
990
|
-
|
|
1012
|
+
y ? /* @__PURE__ */ t($, { variant: "info", leading: /* @__PURE__ */ t(Fe, { "aria-hidden": "true" }), children: c("practiceResults.fearPatient.label") }) : null
|
|
991
1013
|
] }) : null,
|
|
992
|
-
/* @__PURE__ */ t(
|
|
993
|
-
e.nextAvailableSlot &&
|
|
1014
|
+
/* @__PURE__ */ t(Ve, { description: e.description, density: "rich" }),
|
|
1015
|
+
e.nextAvailableSlot && f ? /* @__PURE__ */ t(He, { time: f }) : null,
|
|
994
1016
|
/* @__PURE__ */ t(
|
|
995
|
-
|
|
1017
|
+
ze,
|
|
996
1018
|
{
|
|
997
1019
|
result: e,
|
|
998
1020
|
openLabel: o,
|
|
999
|
-
bookLabel:
|
|
1000
|
-
nextSlotText:
|
|
1021
|
+
bookLabel: p,
|
|
1022
|
+
nextSlotText: f,
|
|
1001
1023
|
onOpenClick: a,
|
|
1002
|
-
onBookClick:
|
|
1024
|
+
onBookClick: l
|
|
1003
1025
|
}
|
|
1004
1026
|
)
|
|
1005
1027
|
] })
|
|
@@ -1008,100 +1030,100 @@ function Dt({
|
|
|
1008
1030
|
)
|
|
1009
1031
|
);
|
|
1010
1032
|
}
|
|
1011
|
-
function
|
|
1033
|
+
function pe({
|
|
1012
1034
|
results: e,
|
|
1013
1035
|
headingLevel: n,
|
|
1014
1036
|
highlightedId: i,
|
|
1015
1037
|
onCardHover: s,
|
|
1016
1038
|
onCardSelect: r,
|
|
1017
1039
|
onCardOpenClick: a,
|
|
1018
|
-
onCardBookClick:
|
|
1019
|
-
openLabel:
|
|
1040
|
+
onCardBookClick: l,
|
|
1041
|
+
openLabel: d,
|
|
1020
1042
|
bookLabel: o,
|
|
1021
|
-
formatNextSlot:
|
|
1022
|
-
onLoadMore:
|
|
1023
|
-
loadingMore:
|
|
1024
|
-
loadingSkeletons:
|
|
1025
|
-
density:
|
|
1043
|
+
formatNextSlot: p,
|
|
1044
|
+
onLoadMore: c,
|
|
1045
|
+
loadingMore: u,
|
|
1046
|
+
loadingSkeletons: f,
|
|
1047
|
+
density: x = "compact",
|
|
1026
1048
|
apiKey: g,
|
|
1027
|
-
containerRef:
|
|
1049
|
+
containerRef: y
|
|
1028
1050
|
}) {
|
|
1029
|
-
const { t: k } = C("ui"),
|
|
1030
|
-
return
|
|
1031
|
-
if (!
|
|
1032
|
-
const
|
|
1033
|
-
if (!
|
|
1034
|
-
const
|
|
1035
|
-
(
|
|
1036
|
-
for (const
|
|
1037
|
-
|
|
1051
|
+
const { t: k } = C("ui"), w = F(null);
|
|
1052
|
+
return Y(() => {
|
|
1053
|
+
if (!c) return;
|
|
1054
|
+
const b = w.current;
|
|
1055
|
+
if (!b || typeof IntersectionObserver > "u") return;
|
|
1056
|
+
const m = new IntersectionObserver(
|
|
1057
|
+
(N) => {
|
|
1058
|
+
for (const L of N)
|
|
1059
|
+
L.isIntersecting && (B("serp_load_more", {
|
|
1038
1060
|
currentCount: e.length
|
|
1039
|
-
}),
|
|
1061
|
+
}), c());
|
|
1040
1062
|
},
|
|
1041
1063
|
{ root: null, rootMargin: "200px" }
|
|
1042
1064
|
);
|
|
1043
|
-
return
|
|
1044
|
-
}, [
|
|
1065
|
+
return m.observe(b), () => m.disconnect();
|
|
1066
|
+
}, [c, e.length]), f ? /* @__PURE__ */ t(
|
|
1045
1067
|
"div",
|
|
1046
1068
|
{
|
|
1047
1069
|
role: "status",
|
|
1048
1070
|
"aria-live": "polite",
|
|
1049
1071
|
"aria-label": k("practiceResults.loading"),
|
|
1050
1072
|
className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)]",
|
|
1051
|
-
children: Array.from({ length: 4 }).map((
|
|
1052
|
-
|
|
1073
|
+
children: Array.from({ length: 4 }).map((b, m) => /* @__PURE__ */ t(
|
|
1074
|
+
ct,
|
|
1053
1075
|
{
|
|
1054
1076
|
variant: "rounded",
|
|
1055
|
-
height:
|
|
1077
|
+
height: x === "rich" ? "11rem" : "7rem"
|
|
1056
1078
|
},
|
|
1057
|
-
`pr-skel-${
|
|
1079
|
+
`pr-skel-${m}`
|
|
1058
1080
|
))
|
|
1059
1081
|
}
|
|
1060
1082
|
) : /* @__PURE__ */ h(
|
|
1061
1083
|
"div",
|
|
1062
1084
|
{
|
|
1063
|
-
ref:
|
|
1085
|
+
ref: y,
|
|
1064
1086
|
"data-component": "practice-results-list",
|
|
1065
1087
|
role: "list",
|
|
1066
1088
|
"aria-label": k("practiceResults.list.label"),
|
|
1067
1089
|
className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)] ds:overflow-y-auto",
|
|
1068
1090
|
children: [
|
|
1069
|
-
e.map((
|
|
1070
|
-
|
|
1091
|
+
e.map((b) => /* @__PURE__ */ t("div", { role: "listitem", children: x === "rich" ? /* @__PURE__ */ t(
|
|
1092
|
+
jt,
|
|
1071
1093
|
{
|
|
1072
|
-
result:
|
|
1094
|
+
result: b,
|
|
1073
1095
|
headingLevel: n,
|
|
1074
1096
|
apiKey: g,
|
|
1075
|
-
highlighted: i ===
|
|
1076
|
-
onSelect: () => r(
|
|
1077
|
-
onOpenClick: () => a(
|
|
1078
|
-
onBookClick: () =>
|
|
1079
|
-
onHover: () => s(
|
|
1080
|
-
openLabel:
|
|
1097
|
+
highlighted: i === b.id,
|
|
1098
|
+
onSelect: () => r(b.id),
|
|
1099
|
+
onOpenClick: () => a(b.id),
|
|
1100
|
+
onBookClick: () => l(b.id),
|
|
1101
|
+
onHover: () => s(b.id),
|
|
1102
|
+
openLabel: d,
|
|
1081
1103
|
bookLabel: o
|
|
1082
1104
|
}
|
|
1083
1105
|
) : /* @__PURE__ */ t(
|
|
1084
|
-
|
|
1106
|
+
Et,
|
|
1085
1107
|
{
|
|
1086
|
-
result:
|
|
1108
|
+
result: b,
|
|
1087
1109
|
headingLevel: n,
|
|
1088
|
-
highlighted: i ===
|
|
1089
|
-
onSelect: () => r(
|
|
1090
|
-
onOpenClick: () => a(
|
|
1091
|
-
onBookClick: () =>
|
|
1092
|
-
onHover: () => s(
|
|
1093
|
-
openLabel:
|
|
1110
|
+
highlighted: i === b.id,
|
|
1111
|
+
onSelect: () => r(b.id),
|
|
1112
|
+
onOpenClick: () => a(b.id),
|
|
1113
|
+
onBookClick: () => l(b.id),
|
|
1114
|
+
onHover: () => s(b.id),
|
|
1115
|
+
openLabel: d,
|
|
1094
1116
|
bookLabel: o,
|
|
1095
|
-
nextSlotText:
|
|
1117
|
+
nextSlotText: p(b)
|
|
1096
1118
|
}
|
|
1097
|
-
) },
|
|
1098
|
-
|
|
1119
|
+
) }, b.id)),
|
|
1120
|
+
c ? /* @__PURE__ */ t(
|
|
1099
1121
|
"div",
|
|
1100
1122
|
{
|
|
1101
|
-
ref:
|
|
1123
|
+
ref: w,
|
|
1102
1124
|
"aria-hidden": "true",
|
|
1103
1125
|
className: "ds:flex ds:items-center ds:justify-center ds:py-[var(--spacing-md)]",
|
|
1104
|
-
children:
|
|
1126
|
+
children: u ? /* @__PURE__ */ t(lt, { size: "md", variant: "pulse" }) : /* @__PURE__ */ t("span", { className: "ds:size-1" })
|
|
1105
1127
|
}
|
|
1106
1128
|
) : null
|
|
1107
1129
|
]
|
|
@@ -1115,45 +1137,46 @@ function ue({
|
|
|
1115
1137
|
apiKey: s,
|
|
1116
1138
|
mapId: r,
|
|
1117
1139
|
highlightedId: a,
|
|
1118
|
-
onPinClick:
|
|
1119
|
-
onPinHover:
|
|
1140
|
+
onPinClick: l,
|
|
1141
|
+
onPinHover: d,
|
|
1120
1142
|
onPinFirstInteract: o,
|
|
1121
|
-
onBoundsChange:
|
|
1122
|
-
consentGranted:
|
|
1123
|
-
onConsentRequest:
|
|
1124
|
-
mapHandleRef:
|
|
1143
|
+
onBoundsChange: p,
|
|
1144
|
+
consentGranted: c,
|
|
1145
|
+
onConsentRequest: u,
|
|
1146
|
+
mapHandleRef: f
|
|
1125
1147
|
}) {
|
|
1126
|
-
const { t:
|
|
1148
|
+
const { t: x } = C("ui"), g = M(
|
|
1127
1149
|
() => e.filter(
|
|
1128
|
-
(
|
|
1129
|
-
).map((
|
|
1130
|
-
id:
|
|
1150
|
+
(m) => !!m.location
|
|
1151
|
+
).map((m) => ({
|
|
1152
|
+
id: m.id,
|
|
1131
1153
|
position: {
|
|
1132
|
-
lat:
|
|
1133
|
-
lng:
|
|
1154
|
+
lat: m.location.lat,
|
|
1155
|
+
lng: m.location.lng
|
|
1134
1156
|
},
|
|
1135
|
-
label:
|
|
1157
|
+
label: m.name
|
|
1136
1158
|
})),
|
|
1137
1159
|
[e]
|
|
1138
|
-
),
|
|
1139
|
-
() => g.map((
|
|
1160
|
+
), y = M(
|
|
1161
|
+
() => g.map((m) => ({ ...m.position, id: m.id })),
|
|
1140
1162
|
[g]
|
|
1141
1163
|
), k = M(
|
|
1142
|
-
() => g.map((
|
|
1164
|
+
() => g.map((m) => m.id).sort().join("|"),
|
|
1143
1165
|
[g]
|
|
1144
|
-
),
|
|
1166
|
+
), w = M(() => {
|
|
1145
1167
|
if (n) return n;
|
|
1146
|
-
const
|
|
1147
|
-
return
|
|
1148
|
-
lat: (
|
|
1149
|
-
lng: (
|
|
1168
|
+
const m = Pt(e);
|
|
1169
|
+
return m ? {
|
|
1170
|
+
lat: (m.north + m.south) / 2,
|
|
1171
|
+
lng: (m.east + m.west) / 2
|
|
1150
1172
|
} : { lat: 45.4642, lng: 9.19 };
|
|
1151
|
-
}, [e, n])
|
|
1152
|
-
|
|
1153
|
-
|
|
1154
|
-
|
|
1155
|
-
|
|
1156
|
-
|
|
1173
|
+
}, [e, n]), b = z(
|
|
1174
|
+
(m, { userInteraction: N }) => {
|
|
1175
|
+
p == null || p(m), N && B("serp_map_panned", { bounds: m });
|
|
1176
|
+
},
|
|
1177
|
+
[p]
|
|
1178
|
+
);
|
|
1179
|
+
return /* @__PURE__ */ t(
|
|
1157
1180
|
"div",
|
|
1158
1181
|
{
|
|
1159
1182
|
"data-component": "practice-results-map-panel",
|
|
@@ -1161,21 +1184,22 @@ function ue({
|
|
|
1161
1184
|
children: /* @__PURE__ */ t(
|
|
1162
1185
|
ot,
|
|
1163
1186
|
{
|
|
1164
|
-
ref:
|
|
1187
|
+
ref: f,
|
|
1165
1188
|
apiKey: s ?? "",
|
|
1166
1189
|
mapId: r,
|
|
1167
|
-
center:
|
|
1190
|
+
center: w,
|
|
1168
1191
|
zoom: i,
|
|
1169
1192
|
markers: g,
|
|
1170
|
-
fitToPoints:
|
|
1193
|
+
fitToPoints: y,
|
|
1171
1194
|
fitKey: k,
|
|
1172
1195
|
selectedMarkerId: a,
|
|
1173
|
-
consentGranted: !!
|
|
1174
|
-
onConsentRequest:
|
|
1175
|
-
|
|
1176
|
-
|
|
1196
|
+
consentGranted: !!c,
|
|
1197
|
+
onConsentRequest: u,
|
|
1198
|
+
onBoundsChange: b,
|
|
1199
|
+
onMarkerClick: (m) => {
|
|
1200
|
+
m != null && (d(m), o(m), l(m));
|
|
1177
1201
|
},
|
|
1178
|
-
ariaLabel:
|
|
1202
|
+
ariaLabel: x("practiceResults.map.label"),
|
|
1179
1203
|
size: "fill",
|
|
1180
1204
|
surface: "bordered",
|
|
1181
1205
|
className: "ds:size-full"
|
|
@@ -1187,16 +1211,16 @@ function ue({
|
|
|
1187
1211
|
function he({
|
|
1188
1212
|
variantBodyProps: e
|
|
1189
1213
|
}) {
|
|
1190
|
-
const { facets: n, value: i, onChange: s, heading: r, intro: a, totalCount:
|
|
1214
|
+
const { facets: n, value: i, onChange: s, heading: r, intro: a, totalCount: l, searchCentre: d } = e;
|
|
1191
1215
|
return /* @__PURE__ */ h("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-sm)]", children: [
|
|
1192
1216
|
/* @__PURE__ */ t(
|
|
1193
|
-
|
|
1217
|
+
Te,
|
|
1194
1218
|
{
|
|
1195
1219
|
heading: r,
|
|
1196
1220
|
headingLevel: e.headingLevel,
|
|
1197
1221
|
intro: a,
|
|
1198
|
-
totalCount:
|
|
1199
|
-
searchCentreLabel:
|
|
1222
|
+
totalCount: l,
|
|
1223
|
+
searchCentreLabel: d == null ? void 0 : d.label
|
|
1200
1224
|
}
|
|
1201
1225
|
),
|
|
1202
1226
|
n.length > 0 ? /* @__PURE__ */ h("div", { className: "ds:flex ds:flex-wrap ds:items-center ds:justify-between ds:gap-[var(--spacing-sm)]", children: [
|
|
@@ -1246,48 +1270,48 @@ function be({
|
|
|
1246
1270
|
headingLevel: n
|
|
1247
1271
|
}) {
|
|
1248
1272
|
const { t: i } = C("ui"), s = ge(n);
|
|
1249
|
-
return /* @__PURE__ */ h(
|
|
1250
|
-
/* @__PURE__ */ t(
|
|
1251
|
-
/* @__PURE__ */ t(
|
|
1252
|
-
e ? /* @__PURE__ */ t(
|
|
1273
|
+
return /* @__PURE__ */ h(X, { variant: "error", children: [
|
|
1274
|
+
/* @__PURE__ */ t(X.Title, { as: `h${s}`, children: i("practiceResults.error.title") }),
|
|
1275
|
+
/* @__PURE__ */ t(X.Description, { children: i("practiceResults.error.description") }),
|
|
1276
|
+
e ? /* @__PURE__ */ t(X.Action, { children: /* @__PURE__ */ t(
|
|
1253
1277
|
ee,
|
|
1254
1278
|
{
|
|
1255
1279
|
intent: "secondary",
|
|
1256
1280
|
size: "sm",
|
|
1257
|
-
startIcon: /* @__PURE__ */ t(
|
|
1281
|
+
startIcon: /* @__PURE__ */ t(pt, { "aria-hidden": "true" }),
|
|
1258
1282
|
onClick: e,
|
|
1259
1283
|
children: i("practiceResults.error.retry")
|
|
1260
1284
|
}
|
|
1261
1285
|
) }) : null
|
|
1262
1286
|
] });
|
|
1263
1287
|
}
|
|
1264
|
-
function
|
|
1288
|
+
function Kt(e) {
|
|
1265
1289
|
const {
|
|
1266
1290
|
results: n,
|
|
1267
1291
|
apiKey: i,
|
|
1268
1292
|
mapId: s,
|
|
1269
1293
|
zoom: r,
|
|
1270
1294
|
searchCentre: a,
|
|
1271
|
-
onLoadMore:
|
|
1272
|
-
loadingMore:
|
|
1295
|
+
onLoadMore: l,
|
|
1296
|
+
loadingMore: d,
|
|
1273
1297
|
loadingSkeletons: o,
|
|
1274
|
-
emptyResultsSlot:
|
|
1275
|
-
errorSlot:
|
|
1276
|
-
error:
|
|
1277
|
-
onRetry:
|
|
1278
|
-
highlightedId:
|
|
1298
|
+
emptyResultsSlot: p,
|
|
1299
|
+
errorSlot: c,
|
|
1300
|
+
error: u,
|
|
1301
|
+
onRetry: f,
|
|
1302
|
+
highlightedId: x,
|
|
1279
1303
|
onCardHover: g,
|
|
1280
|
-
onPinClick:
|
|
1304
|
+
onPinClick: y,
|
|
1281
1305
|
consentGranted: k,
|
|
1282
|
-
onConsentRequest:
|
|
1283
|
-
onBoundsChange:
|
|
1284
|
-
listContainerRef:
|
|
1285
|
-
} = e, { t:
|
|
1286
|
-
|
|
1306
|
+
onConsentRequest: w,
|
|
1307
|
+
onBoundsChange: b,
|
|
1308
|
+
listContainerRef: m
|
|
1309
|
+
} = e, { t: N } = C("ui"), [L, T] = me(!1), _ = u ? c ?? /* @__PURE__ */ t(be, { onRetry: f, headingLevel: e.headingLevel }) : n.length === 0 && !o ? p ?? /* @__PURE__ */ t(ve, { headingLevel: e.headingLevel }) : /* @__PURE__ */ t(
|
|
1310
|
+
pe,
|
|
1287
1311
|
{
|
|
1288
1312
|
results: n,
|
|
1289
1313
|
headingLevel: e.headingLevel,
|
|
1290
|
-
highlightedId:
|
|
1314
|
+
highlightedId: x,
|
|
1291
1315
|
onCardHover: g,
|
|
1292
1316
|
onCardSelect: e.onCardSelect,
|
|
1293
1317
|
onCardOpenClick: e.onCardOpenClick,
|
|
@@ -1295,11 +1319,11 @@ function Vt(e) {
|
|
|
1295
1319
|
openLabel: e.openLabel,
|
|
1296
1320
|
bookLabel: e.bookLabel,
|
|
1297
1321
|
formatNextSlot: e.formatNextSlot,
|
|
1298
|
-
onLoadMore:
|
|
1299
|
-
loadingMore:
|
|
1322
|
+
onLoadMore: l,
|
|
1323
|
+
loadingMore: d,
|
|
1300
1324
|
loadingSkeletons: o,
|
|
1301
1325
|
density: "compact",
|
|
1302
|
-
containerRef:
|
|
1326
|
+
containerRef: m
|
|
1303
1327
|
}
|
|
1304
1328
|
);
|
|
1305
1329
|
return /* @__PURE__ */ h("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)]", children: [
|
|
@@ -1314,15 +1338,15 @@ function Vt(e) {
|
|
|
1314
1338
|
zoom: r,
|
|
1315
1339
|
apiKey: i,
|
|
1316
1340
|
mapId: s,
|
|
1317
|
-
highlightedId:
|
|
1318
|
-
onPinClick: (
|
|
1319
|
-
Z(n,
|
|
1341
|
+
highlightedId: x,
|
|
1342
|
+
onPinClick: (P) => {
|
|
1343
|
+
Z(n, P, "pin", e.onResultSelect), y(P);
|
|
1320
1344
|
},
|
|
1321
1345
|
onPinHover: g,
|
|
1322
1346
|
onPinFirstInteract: e.onPinFirstInteract,
|
|
1323
|
-
onBoundsChange:
|
|
1347
|
+
onBoundsChange: b,
|
|
1324
1348
|
consentGranted: k,
|
|
1325
|
-
onConsentRequest:
|
|
1349
|
+
onConsentRequest: w,
|
|
1326
1350
|
mapHandleRef: e.mapHandleRef
|
|
1327
1351
|
}
|
|
1328
1352
|
) })
|
|
@@ -1333,14 +1357,14 @@ function Vt(e) {
|
|
|
1333
1357
|
intent: "primary",
|
|
1334
1358
|
size: "md",
|
|
1335
1359
|
startIcon: /* @__PURE__ */ t(bt, { "aria-hidden": "true" }),
|
|
1336
|
-
onClick: () =>
|
|
1337
|
-
children:
|
|
1360
|
+
onClick: () => T(!0),
|
|
1361
|
+
children: N("practiceResults.viewMap")
|
|
1338
1362
|
}
|
|
1339
1363
|
) }),
|
|
1340
|
-
/* @__PURE__ */ t(I.Root, { open:
|
|
1341
|
-
/* @__PURE__ */ t(I.Header, { children: /* @__PURE__ */ t(I.Title, { children:
|
|
1364
|
+
/* @__PURE__ */ t(I.Root, { open: L, onOpenChange: T, children: /* @__PURE__ */ h(I.Content, { side: "bottom", size: "lg", children: [
|
|
1365
|
+
/* @__PURE__ */ t(I.Header, { children: /* @__PURE__ */ t(I.Title, { children: N("practiceResults.map.label") }) }),
|
|
1342
1366
|
/* @__PURE__ */ h(I.Body, { children: [
|
|
1343
|
-
/* @__PURE__ */ t(I.Description, { className: "ds:sr-only", children:
|
|
1367
|
+
/* @__PURE__ */ t(I.Description, { className: "ds:sr-only", children: N("practiceResults.sheet.description") }),
|
|
1344
1368
|
/* @__PURE__ */ h("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)]", children: [
|
|
1345
1369
|
/* @__PURE__ */ t("div", { className: "ds:h-[20rem]", children: /* @__PURE__ */ t(
|
|
1346
1370
|
ue,
|
|
@@ -1350,15 +1374,15 @@ function Vt(e) {
|
|
|
1350
1374
|
zoom: r,
|
|
1351
1375
|
apiKey: i,
|
|
1352
1376
|
mapId: s,
|
|
1353
|
-
highlightedId:
|
|
1354
|
-
onPinClick: (
|
|
1355
|
-
Z(n,
|
|
1377
|
+
highlightedId: x,
|
|
1378
|
+
onPinClick: (P) => {
|
|
1379
|
+
Z(n, P, "pin", e.onResultSelect), y(P);
|
|
1356
1380
|
},
|
|
1357
1381
|
onPinHover: g,
|
|
1358
1382
|
onPinFirstInteract: e.onPinFirstInteract,
|
|
1359
|
-
onBoundsChange:
|
|
1383
|
+
onBoundsChange: b,
|
|
1360
1384
|
consentGranted: k,
|
|
1361
|
-
onConsentRequest:
|
|
1385
|
+
onConsentRequest: w,
|
|
1362
1386
|
mapHandleRef: e.mapHandleRef
|
|
1363
1387
|
}
|
|
1364
1388
|
) }),
|
|
@@ -1368,46 +1392,46 @@ function Vt(e) {
|
|
|
1368
1392
|
] }) })
|
|
1369
1393
|
] });
|
|
1370
1394
|
}
|
|
1371
|
-
const
|
|
1395
|
+
const qt = {
|
|
1372
1396
|
peek: "sm",
|
|
1373
1397
|
half: "md",
|
|
1374
1398
|
full: "lg"
|
|
1375
|
-
},
|
|
1399
|
+
}, K = [
|
|
1376
1400
|
"peek",
|
|
1377
1401
|
"half",
|
|
1378
1402
|
"full"
|
|
1379
1403
|
];
|
|
1380
|
-
function
|
|
1381
|
-
const { t: i, i18n: s } = C("ui"), r = s.dir() === "rtl", a =
|
|
1404
|
+
function Ut({ value: e, onChange: n }) {
|
|
1405
|
+
const { t: i, i18n: s } = C("ui"), r = s.dir() === "rtl", a = F(
|
|
1382
1406
|
/* @__PURE__ */ new Map()
|
|
1383
|
-
),
|
|
1384
|
-
var
|
|
1385
|
-
(
|
|
1386
|
-
}, []),
|
|
1387
|
-
(o,
|
|
1388
|
-
const
|
|
1407
|
+
), l = z((o) => {
|
|
1408
|
+
var p;
|
|
1409
|
+
(p = a.current.get(o)) == null || p.focus();
|
|
1410
|
+
}, []), d = z(
|
|
1411
|
+
(o, p) => {
|
|
1412
|
+
const c = K.indexOf(p), u = K.length, f = r ? "ArrowLeft" : "ArrowRight", x = r ? "ArrowRight" : "ArrowLeft";
|
|
1389
1413
|
let g = null;
|
|
1390
1414
|
switch (o.key) {
|
|
1391
|
-
case
|
|
1415
|
+
case f:
|
|
1392
1416
|
case "ArrowDown":
|
|
1393
|
-
g =
|
|
1417
|
+
g = K[(c + 1) % u];
|
|
1394
1418
|
break;
|
|
1395
|
-
case
|
|
1419
|
+
case x:
|
|
1396
1420
|
case "ArrowUp":
|
|
1397
|
-
g =
|
|
1421
|
+
g = K[(c - 1 + u) % u];
|
|
1398
1422
|
break;
|
|
1399
1423
|
case "Home":
|
|
1400
|
-
g =
|
|
1424
|
+
g = K[0];
|
|
1401
1425
|
break;
|
|
1402
1426
|
case "End":
|
|
1403
|
-
g =
|
|
1427
|
+
g = K[u - 1];
|
|
1404
1428
|
break;
|
|
1405
1429
|
default:
|
|
1406
1430
|
return;
|
|
1407
1431
|
}
|
|
1408
|
-
o.preventDefault(), g && g !==
|
|
1432
|
+
o.preventDefault(), g && g !== p && n(g), g && l(g);
|
|
1409
1433
|
},
|
|
1410
|
-
[
|
|
1434
|
+
[l, r, n]
|
|
1411
1435
|
);
|
|
1412
1436
|
return /* @__PURE__ */ t(
|
|
1413
1437
|
"div",
|
|
@@ -1415,23 +1439,23 @@ function Et({ value: e, onChange: n }) {
|
|
|
1415
1439
|
role: "radiogroup",
|
|
1416
1440
|
"aria-label": i("practiceResults.sheet.snap.label"),
|
|
1417
1441
|
className: "ds:inline-flex ds:items-center ds:gap-[var(--spacing-2xs)]",
|
|
1418
|
-
children:
|
|
1419
|
-
const
|
|
1442
|
+
children: K.map((o) => {
|
|
1443
|
+
const p = e === o;
|
|
1420
1444
|
return /* @__PURE__ */ t(
|
|
1421
1445
|
"button",
|
|
1422
1446
|
{
|
|
1423
|
-
ref: (
|
|
1424
|
-
|
|
1447
|
+
ref: (c) => {
|
|
1448
|
+
c ? a.current.set(o, c) : a.current.delete(o);
|
|
1425
1449
|
},
|
|
1426
1450
|
type: "button",
|
|
1427
1451
|
role: "radio",
|
|
1428
|
-
"aria-checked":
|
|
1452
|
+
"aria-checked": p,
|
|
1429
1453
|
"aria-label": i(`practiceResults.sheet.snap.${o}`),
|
|
1430
|
-
tabIndex:
|
|
1454
|
+
tabIndex: p ? 0 : -1,
|
|
1431
1455
|
onClick: () => n(o),
|
|
1432
|
-
onKeyDown: (
|
|
1456
|
+
onKeyDown: (c) => d(c, o),
|
|
1433
1457
|
className: te({
|
|
1434
|
-
state:
|
|
1458
|
+
state: p ? "active" : "idle"
|
|
1435
1459
|
}),
|
|
1436
1460
|
children: i(`practiceResults.sheet.snap.${o}`)
|
|
1437
1461
|
},
|
|
@@ -1441,36 +1465,36 @@ function Et({ value: e, onChange: n }) {
|
|
|
1441
1465
|
}
|
|
1442
1466
|
);
|
|
1443
1467
|
}
|
|
1444
|
-
function
|
|
1468
|
+
function Gt(e) {
|
|
1445
1469
|
const {
|
|
1446
1470
|
results: n,
|
|
1447
1471
|
apiKey: i,
|
|
1448
1472
|
mapId: s,
|
|
1449
1473
|
zoom: r,
|
|
1450
1474
|
searchCentre: a,
|
|
1451
|
-
onLoadMore:
|
|
1452
|
-
loadingMore:
|
|
1475
|
+
onLoadMore: l,
|
|
1476
|
+
loadingMore: d,
|
|
1453
1477
|
loadingSkeletons: o,
|
|
1454
|
-
emptyResultsSlot:
|
|
1455
|
-
errorSlot:
|
|
1456
|
-
error:
|
|
1457
|
-
onRetry:
|
|
1458
|
-
highlightedId:
|
|
1478
|
+
emptyResultsSlot: p,
|
|
1479
|
+
errorSlot: c,
|
|
1480
|
+
error: u,
|
|
1481
|
+
onRetry: f,
|
|
1482
|
+
highlightedId: x,
|
|
1459
1483
|
onCardHover: g,
|
|
1460
|
-
onPinClick:
|
|
1484
|
+
onPinClick: y,
|
|
1461
1485
|
consentGranted: k,
|
|
1462
|
-
onConsentRequest:
|
|
1463
|
-
onBoundsChange:
|
|
1464
|
-
listContainerRef:
|
|
1465
|
-
facets:
|
|
1466
|
-
value:
|
|
1467
|
-
onChange:
|
|
1468
|
-
} = e, { t: _ } = C("ui"), [
|
|
1469
|
-
|
|
1486
|
+
onConsentRequest: w,
|
|
1487
|
+
onBoundsChange: b,
|
|
1488
|
+
listContainerRef: m,
|
|
1489
|
+
facets: N,
|
|
1490
|
+
value: L,
|
|
1491
|
+
onChange: T
|
|
1492
|
+
} = e, { t: _ } = C("ui"), [P, q] = me("half"), U = qt[P], G = dt("(min-width: 1024px)"), E = u ? c ?? /* @__PURE__ */ t(be, { onRetry: f, headingLevel: e.headingLevel }) : n.length === 0 && !o ? p ?? /* @__PURE__ */ t(ve, { headingLevel: e.headingLevel }) : /* @__PURE__ */ t(
|
|
1493
|
+
pe,
|
|
1470
1494
|
{
|
|
1471
1495
|
results: n,
|
|
1472
1496
|
headingLevel: e.headingLevel,
|
|
1473
|
-
highlightedId:
|
|
1497
|
+
highlightedId: x,
|
|
1474
1498
|
onCardHover: g,
|
|
1475
1499
|
onCardSelect: e.onCardSelect,
|
|
1476
1500
|
onCardOpenClick: e.onCardOpenClick,
|
|
@@ -1478,12 +1502,12 @@ function jt(e) {
|
|
|
1478
1502
|
openLabel: e.openLabel,
|
|
1479
1503
|
bookLabel: e.bookLabel,
|
|
1480
1504
|
formatNextSlot: e.formatNextSlot,
|
|
1481
|
-
onLoadMore:
|
|
1482
|
-
loadingMore:
|
|
1505
|
+
onLoadMore: l,
|
|
1506
|
+
loadingMore: d,
|
|
1483
1507
|
loadingSkeletons: o,
|
|
1484
1508
|
density: "compact",
|
|
1485
1509
|
apiKey: i,
|
|
1486
|
-
containerRef:
|
|
1510
|
+
containerRef: m
|
|
1487
1511
|
}
|
|
1488
1512
|
), A = /* @__PURE__ */ t(
|
|
1489
1513
|
ue,
|
|
@@ -1493,23 +1517,23 @@ function jt(e) {
|
|
|
1493
1517
|
zoom: r,
|
|
1494
1518
|
apiKey: i,
|
|
1495
1519
|
mapId: s,
|
|
1496
|
-
highlightedId:
|
|
1497
|
-
onPinClick: (
|
|
1498
|
-
Z(n,
|
|
1520
|
+
highlightedId: x,
|
|
1521
|
+
onPinClick: (S) => {
|
|
1522
|
+
Z(n, S, "pin", e.onResultSelect), y(S);
|
|
1499
1523
|
},
|
|
1500
1524
|
onPinHover: g,
|
|
1501
1525
|
onPinFirstInteract: e.onPinFirstInteract,
|
|
1502
|
-
onBoundsChange:
|
|
1526
|
+
onBoundsChange: b,
|
|
1503
1527
|
consentGranted: k,
|
|
1504
|
-
onConsentRequest:
|
|
1528
|
+
onConsentRequest: w,
|
|
1505
1529
|
mapHandleRef: e.mapHandleRef
|
|
1506
1530
|
}
|
|
1507
|
-
), W =
|
|
1531
|
+
), W = N.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(
|
|
1508
1532
|
_e,
|
|
1509
1533
|
{
|
|
1510
|
-
facets:
|
|
1511
|
-
value:
|
|
1512
|
-
onChange: (
|
|
1534
|
+
facets: N,
|
|
1535
|
+
value: L.facets,
|
|
1536
|
+
onChange: (S) => T({ ...L, facets: S }),
|
|
1513
1537
|
floating: !0
|
|
1514
1538
|
}
|
|
1515
1539
|
) }) : null;
|
|
@@ -1535,7 +1559,7 @@ function jt(e) {
|
|
|
1535
1559
|
/* @__PURE__ */ t(he, { variantBodyProps: e }),
|
|
1536
1560
|
/* @__PURE__ */ h("div", { className: "ds:grid ds:grid-cols-[65fr_35fr] ds:gap-[var(--spacing-lg)] ds:items-start", children: [
|
|
1537
1561
|
/* @__PURE__ */ t("div", { className: "ds:sticky ds:top-[var(--spacing-md)] ds:h-[44rem]", children: A }),
|
|
1538
|
-
/* @__PURE__ */ t("div", { className: "ds:min-w-0", children:
|
|
1562
|
+
/* @__PURE__ */ t("div", { className: "ds:min-w-0", children: E })
|
|
1539
1563
|
] })
|
|
1540
1564
|
] })
|
|
1541
1565
|
) : (
|
|
@@ -1547,7 +1571,7 @@ function jt(e) {
|
|
|
1547
1571
|
// chrome, so floating chips are the only place for them.
|
|
1548
1572
|
/* @__PURE__ */ h("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)]", children: [
|
|
1549
1573
|
/* @__PURE__ */ t(
|
|
1550
|
-
|
|
1574
|
+
Te,
|
|
1551
1575
|
{
|
|
1552
1576
|
heading: e.heading,
|
|
1553
1577
|
headingLevel: e.headingLevel,
|
|
@@ -1565,9 +1589,9 @@ function jt(e) {
|
|
|
1565
1589
|
{
|
|
1566
1590
|
side: "bottom",
|
|
1567
1591
|
size: U,
|
|
1568
|
-
onEscapeKeyDown: (
|
|
1569
|
-
onPointerDownOutside: (
|
|
1570
|
-
onInteractOutside: (
|
|
1592
|
+
onEscapeKeyDown: (S) => S.preventDefault(),
|
|
1593
|
+
onPointerDownOutside: (S) => S.preventDefault(),
|
|
1594
|
+
onInteractOutside: (S) => S.preventDefault(),
|
|
1571
1595
|
children: /* @__PURE__ */ h(I.Body, { children: [
|
|
1572
1596
|
/* @__PURE__ */ t(I.Description, { className: "ds:sr-only", children: _("practiceResults.sheet.descriptionMapFirst") }),
|
|
1573
1597
|
/* @__PURE__ */ h("div", { className: "ds:flex ds:items-start ds:justify-between ds:gap-[var(--spacing-sm)] ds:pb-[var(--spacing-sm)]", children: [
|
|
@@ -1575,9 +1599,9 @@ function jt(e) {
|
|
|
1575
1599
|
count: e.totalCount ?? n.length
|
|
1576
1600
|
}) }),
|
|
1577
1601
|
/* @__PURE__ */ t(
|
|
1578
|
-
|
|
1602
|
+
Ut,
|
|
1579
1603
|
{
|
|
1580
|
-
value:
|
|
1604
|
+
value: P,
|
|
1581
1605
|
onChange: q
|
|
1582
1606
|
}
|
|
1583
1607
|
)
|
|
@@ -1585,38 +1609,38 @@ function jt(e) {
|
|
|
1585
1609
|
/* @__PURE__ */ t("div", { className: "ds:pb-[var(--spacing-sm)]", children: /* @__PURE__ */ t(
|
|
1586
1610
|
de,
|
|
1587
1611
|
{
|
|
1588
|
-
value:
|
|
1589
|
-
onChange: (
|
|
1612
|
+
value: L.sort ?? "relevance",
|
|
1613
|
+
onChange: (S) => T({ ...L, sort: S })
|
|
1590
1614
|
}
|
|
1591
1615
|
) }),
|
|
1592
|
-
|
|
1616
|
+
E
|
|
1593
1617
|
] })
|
|
1594
1618
|
}
|
|
1595
1619
|
) })
|
|
1596
1620
|
] })
|
|
1597
1621
|
) });
|
|
1598
1622
|
}
|
|
1599
|
-
function
|
|
1623
|
+
function Zt(e) {
|
|
1600
1624
|
const {
|
|
1601
1625
|
results: n,
|
|
1602
1626
|
apiKey: i,
|
|
1603
1627
|
onLoadMore: s,
|
|
1604
1628
|
loadingMore: r,
|
|
1605
1629
|
loadingSkeletons: a,
|
|
1606
|
-
emptyResultsSlot:
|
|
1607
|
-
errorSlot:
|
|
1630
|
+
emptyResultsSlot: l,
|
|
1631
|
+
errorSlot: d,
|
|
1608
1632
|
error: o,
|
|
1609
|
-
onRetry:
|
|
1610
|
-
highlightedId:
|
|
1611
|
-
onCardHover:
|
|
1612
|
-
listContainerRef:
|
|
1613
|
-
} = e,
|
|
1614
|
-
|
|
1633
|
+
onRetry: p,
|
|
1634
|
+
highlightedId: c,
|
|
1635
|
+
onCardHover: u,
|
|
1636
|
+
listContainerRef: f
|
|
1637
|
+
} = e, x = o ? d ?? /* @__PURE__ */ t(be, { onRetry: p, headingLevel: e.headingLevel }) : n.length === 0 && !a ? l ?? /* @__PURE__ */ t(ve, { headingLevel: e.headingLevel }) : /* @__PURE__ */ t(
|
|
1638
|
+
pe,
|
|
1615
1639
|
{
|
|
1616
1640
|
results: n,
|
|
1617
1641
|
headingLevel: e.headingLevel,
|
|
1618
|
-
highlightedId:
|
|
1619
|
-
onCardHover:
|
|
1642
|
+
highlightedId: c,
|
|
1643
|
+
onCardHover: u,
|
|
1620
1644
|
onCardSelect: e.onCardSelect,
|
|
1621
1645
|
onCardOpenClick: e.onCardOpenClick,
|
|
1622
1646
|
onCardBookClick: e.onCardBookClick,
|
|
@@ -1628,55 +1652,55 @@ function qt(e) {
|
|
|
1628
1652
|
loadingSkeletons: a,
|
|
1629
1653
|
density: "rich",
|
|
1630
1654
|
apiKey: i,
|
|
1631
|
-
containerRef:
|
|
1655
|
+
containerRef: f
|
|
1632
1656
|
}
|
|
1633
1657
|
);
|
|
1634
1658
|
return /* @__PURE__ */ h("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)]", children: [
|
|
1635
1659
|
/* @__PURE__ */ t(he, { variantBodyProps: e }),
|
|
1636
|
-
|
|
1660
|
+
x
|
|
1637
1661
|
] });
|
|
1638
1662
|
}
|
|
1639
|
-
const
|
|
1663
|
+
const Wt = it(function({
|
|
1640
1664
|
variant: n = "split-list-map",
|
|
1641
1665
|
results: i,
|
|
1642
1666
|
totalCount: s,
|
|
1643
1667
|
searchCentre: r,
|
|
1644
1668
|
facets: a,
|
|
1645
|
-
googleMapsApiKey:
|
|
1646
|
-
mapId:
|
|
1669
|
+
googleMapsApiKey: l,
|
|
1670
|
+
mapId: d,
|
|
1647
1671
|
defaultZoom: o = yt,
|
|
1648
|
-
onBoundsChange:
|
|
1649
|
-
consentGranted:
|
|
1650
|
-
onConsentRequest:
|
|
1651
|
-
skipConsentGate:
|
|
1652
|
-
onLoadMore:
|
|
1672
|
+
onBoundsChange: p,
|
|
1673
|
+
consentGranted: c,
|
|
1674
|
+
onConsentRequest: u,
|
|
1675
|
+
skipConsentGate: f = !1,
|
|
1676
|
+
onLoadMore: x,
|
|
1653
1677
|
loadingMore: g,
|
|
1654
|
-
value:
|
|
1678
|
+
value: y,
|
|
1655
1679
|
onChange: k,
|
|
1656
|
-
onResultSelect:
|
|
1657
|
-
loading:
|
|
1658
|
-
emptyResultsSlot:
|
|
1659
|
-
errorSlot:
|
|
1660
|
-
error:
|
|
1661
|
-
onRetry:
|
|
1680
|
+
onResultSelect: w,
|
|
1681
|
+
loading: b,
|
|
1682
|
+
emptyResultsSlot: m,
|
|
1683
|
+
errorSlot: N,
|
|
1684
|
+
error: L,
|
|
1685
|
+
onRetry: T,
|
|
1662
1686
|
heading: _,
|
|
1663
|
-
headingLevel:
|
|
1687
|
+
headingLevel: P = 2,
|
|
1664
1688
|
intro: q,
|
|
1665
1689
|
cardOpenButtonLabel: U,
|
|
1666
1690
|
cardBookButtonLabel: G,
|
|
1667
|
-
showCardOpenButton:
|
|
1691
|
+
showCardOpenButton: E = !0,
|
|
1668
1692
|
"aria-label": A,
|
|
1669
1693
|
id: W,
|
|
1670
|
-
className:
|
|
1671
|
-
...
|
|
1672
|
-
},
|
|
1673
|
-
const { t: ne, i18n: xe } = C("ui"), [
|
|
1694
|
+
className: S,
|
|
1695
|
+
...Oe
|
|
1696
|
+
}, Ee) {
|
|
1697
|
+
const { t: ne, i18n: xe } = C("ui"), [je, Q] = me(null), J = F(/* @__PURE__ */ new Set()), ae = F(/* @__PURE__ */ new Set()), Ke = F(null), ie = F(null), se = M(
|
|
1674
1698
|
() => ({
|
|
1675
1699
|
getVariant: () => n,
|
|
1676
1700
|
scrollToResult: (v) => {
|
|
1677
|
-
const
|
|
1678
|
-
if (!
|
|
1679
|
-
const R =
|
|
1701
|
+
const H = ie.current;
|
|
1702
|
+
if (!H) return;
|
|
1703
|
+
const R = H.querySelector(
|
|
1680
1704
|
`[data-component="practice-result-card"][data-result-id="${CSS.escape(v)}"]`
|
|
1681
1705
|
);
|
|
1682
1706
|
R && (R.scrollIntoView({ behavior: "smooth", block: "nearest" }), Q(v));
|
|
@@ -1687,8 +1711,8 @@ const Ut = it(function({
|
|
|
1687
1711
|
}),
|
|
1688
1712
|
[n]
|
|
1689
1713
|
);
|
|
1690
|
-
st(
|
|
1691
|
-
const qe =
|
|
1714
|
+
st(Ee, () => se, [se]), mt(xt, se, W);
|
|
1715
|
+
const qe = E ? U ?? ne("practiceResults.card.open") : void 0, Ue = G ?? ne("practiceResults.card.book"), Ge = z(
|
|
1692
1716
|
(v) => {
|
|
1693
1717
|
if (v.nextAvailableSlot)
|
|
1694
1718
|
try {
|
|
@@ -1702,113 +1726,113 @@ const Ut = it(function({
|
|
|
1702
1726
|
}
|
|
1703
1727
|
},
|
|
1704
1728
|
[xe.language]
|
|
1705
|
-
), ye =
|
|
1706
|
-
|
|
1729
|
+
), ye = F(null);
|
|
1730
|
+
Y(() => {
|
|
1707
1731
|
ye.current !== n && (ye.current = n, B("serp_variant_exposed", {
|
|
1708
1732
|
variant: n,
|
|
1709
1733
|
totalCount: s ?? i.length
|
|
1710
|
-
}),
|
|
1734
|
+
}), J.current = /* @__PURE__ */ new Set(), ae.current = /* @__PURE__ */ new Set());
|
|
1711
1735
|
}, [n]);
|
|
1712
|
-
const re =
|
|
1713
|
-
() => Ct(a ?? [], i,
|
|
1714
|
-
[a, i,
|
|
1715
|
-
),
|
|
1716
|
-
const v = Rt(i,
|
|
1717
|
-
return
|
|
1718
|
-
}, [i,
|
|
1719
|
-
|
|
1720
|
-
const v =
|
|
1736
|
+
const re = F(!1), oe = M(
|
|
1737
|
+
() => Ct(a ?? [], i, y.facets),
|
|
1738
|
+
[a, i, y.facets]
|
|
1739
|
+
), ce = y.sort ?? (r ? "distance" : "relevance"), V = M(() => {
|
|
1740
|
+
const v = Rt(i, y.facets, oe);
|
|
1741
|
+
return Lt(v, ce, r);
|
|
1742
|
+
}, [i, y.facets, oe, ce, r]);
|
|
1743
|
+
Y(() => {
|
|
1744
|
+
const v = V.length === 0;
|
|
1721
1745
|
v && !re.current ? (B("serp_empty_results", {
|
|
1722
|
-
appliedFacets:
|
|
1746
|
+
appliedFacets: y.facets ?? {}
|
|
1723
1747
|
}), re.current = !0) : v || (re.current = !1);
|
|
1724
|
-
}, [
|
|
1725
|
-
const
|
|
1726
|
-
|
|
1748
|
+
}, [V.length, y.facets]);
|
|
1749
|
+
const j = F(null), we = F(null);
|
|
1750
|
+
Y(
|
|
1727
1751
|
() => () => {
|
|
1728
|
-
|
|
1752
|
+
j.current && clearTimeout(j.current);
|
|
1729
1753
|
},
|
|
1730
1754
|
[]
|
|
1731
1755
|
);
|
|
1732
|
-
const Ze =
|
|
1733
|
-
Q(v), !
|
|
1734
|
-
|
|
1756
|
+
const Ze = z((v) => {
|
|
1757
|
+
Q(v), !J.current.has(v) && (we.current === v && j.current || (j.current && clearTimeout(j.current), we.current = v, j.current = setTimeout(() => {
|
|
1758
|
+
J.current.has(v) || (J.current.add(v), B("serp_result_hovered_card", { resultId: v })), j.current = null;
|
|
1735
1759
|
}, 500)));
|
|
1736
|
-
}, []), We =
|
|
1760
|
+
}, []), We = z((v) => {
|
|
1737
1761
|
Q(v);
|
|
1738
|
-
const
|
|
1739
|
-
if (!
|
|
1740
|
-
const R =
|
|
1762
|
+
const H = ie.current;
|
|
1763
|
+
if (!H) return;
|
|
1764
|
+
const R = H.querySelector(
|
|
1741
1765
|
`[data-component="practice-result-card"][data-result-id="${CSS.escape(v)}"]`
|
|
1742
1766
|
);
|
|
1743
1767
|
R == null || R.scrollIntoView({ behavior: "smooth", block: "nearest" });
|
|
1744
|
-
}, []), Qe =
|
|
1768
|
+
}, []), Qe = z((v) => {
|
|
1745
1769
|
ae.current.has(v) || (ae.current.add(v), B("serp_result_hovered_pin", { resultId: v }));
|
|
1746
|
-
}, []), ke =
|
|
1770
|
+
}, []), ke = F(null), Je = z(
|
|
1747
1771
|
(v) => {
|
|
1748
1772
|
Q(v);
|
|
1749
|
-
const
|
|
1750
|
-
if (
|
|
1751
|
-
if (
|
|
1773
|
+
const H = V.find((R) => R.id === v);
|
|
1774
|
+
if (H) {
|
|
1775
|
+
if (H.location) {
|
|
1752
1776
|
const R = ke.current;
|
|
1753
1777
|
R == null || R.panTo({
|
|
1754
|
-
lat:
|
|
1755
|
-
lng:
|
|
1778
|
+
lat: H.location.lat,
|
|
1779
|
+
lng: H.location.lng
|
|
1756
1780
|
}), R == null || R.setZoom(16);
|
|
1757
1781
|
}
|
|
1758
|
-
Z(
|
|
1782
|
+
Z(V, v, "card", w);
|
|
1759
1783
|
}
|
|
1760
1784
|
},
|
|
1761
|
-
[
|
|
1762
|
-
), Xe =
|
|
1785
|
+
[V, w]
|
|
1786
|
+
), Xe = z(
|
|
1763
1787
|
(v) => {
|
|
1764
1788
|
Z(
|
|
1765
|
-
|
|
1789
|
+
V,
|
|
1766
1790
|
v,
|
|
1767
1791
|
"open-button",
|
|
1768
|
-
|
|
1792
|
+
w
|
|
1769
1793
|
);
|
|
1770
1794
|
},
|
|
1771
|
-
[
|
|
1772
|
-
), Ye =
|
|
1795
|
+
[V, w]
|
|
1796
|
+
), Ye = z(
|
|
1773
1797
|
(v) => {
|
|
1774
1798
|
Z(
|
|
1775
|
-
|
|
1799
|
+
V,
|
|
1776
1800
|
v,
|
|
1777
1801
|
"book-button",
|
|
1778
|
-
|
|
1802
|
+
w
|
|
1779
1803
|
);
|
|
1780
1804
|
},
|
|
1781
|
-
[
|
|
1782
|
-
), et = !!
|
|
1783
|
-
results:
|
|
1805
|
+
[V, w]
|
|
1806
|
+
), et = !!b && i.length === 0, le = {
|
|
1807
|
+
results: V,
|
|
1784
1808
|
totalCount: s,
|
|
1785
1809
|
searchCentre: r,
|
|
1786
1810
|
facets: oe,
|
|
1787
|
-
value: { ...
|
|
1811
|
+
value: { ...y, sort: ce },
|
|
1788
1812
|
onChange: k,
|
|
1789
|
-
onResultSelect:
|
|
1790
|
-
onLoadMore:
|
|
1813
|
+
onResultSelect: w,
|
|
1814
|
+
onLoadMore: x,
|
|
1791
1815
|
loadingMore: g,
|
|
1792
|
-
apiKey:
|
|
1793
|
-
mapId:
|
|
1816
|
+
apiKey: l,
|
|
1817
|
+
mapId: d,
|
|
1794
1818
|
zoom: o,
|
|
1795
1819
|
// 0.31.4: when `skipConsentGate` is true the kit synthesises
|
|
1796
1820
|
// `consentGranted=true` for every internal MapView; the consumer's
|
|
1797
1821
|
// CMP at the page level is responsible for whether the Google Maps
|
|
1798
1822
|
// loader script is present at all. `onConsentRequest` is dropped
|
|
1799
1823
|
// because no placeholder renders — nothing to fire it from.
|
|
1800
|
-
consentGranted:
|
|
1801
|
-
onConsentRequest:
|
|
1802
|
-
onBoundsChange:
|
|
1824
|
+
consentGranted: f ? !0 : c,
|
|
1825
|
+
onConsentRequest: f ? void 0 : u,
|
|
1826
|
+
onBoundsChange: p,
|
|
1803
1827
|
loadingSkeletons: et,
|
|
1804
|
-
emptyResultsSlot:
|
|
1805
|
-
errorSlot:
|
|
1806
|
-
error:
|
|
1807
|
-
onRetry:
|
|
1828
|
+
emptyResultsSlot: m,
|
|
1829
|
+
errorSlot: N,
|
|
1830
|
+
error: L,
|
|
1831
|
+
onRetry: T,
|
|
1808
1832
|
heading: _,
|
|
1809
|
-
headingLevel:
|
|
1833
|
+
headingLevel: P,
|
|
1810
1834
|
intro: q,
|
|
1811
|
-
highlightedId:
|
|
1835
|
+
highlightedId: je,
|
|
1812
1836
|
onCardHover: Ze,
|
|
1813
1837
|
onPinClick: We,
|
|
1814
1838
|
onPinFirstInteract: Qe,
|
|
@@ -1818,17 +1842,17 @@ const Ut = it(function({
|
|
|
1818
1842
|
openLabel: qe,
|
|
1819
1843
|
bookLabel: Ue,
|
|
1820
1844
|
formatNextSlot: Ge,
|
|
1821
|
-
listContainerRef:
|
|
1845
|
+
listContainerRef: Ke,
|
|
1822
1846
|
mapHandleRef: ke
|
|
1823
1847
|
}, tt = (() => {
|
|
1824
1848
|
switch (n) {
|
|
1825
1849
|
case "map-first":
|
|
1826
|
-
return /* @__PURE__ */ t(
|
|
1850
|
+
return /* @__PURE__ */ t(Gt, { ...le });
|
|
1827
1851
|
case "rich-cards":
|
|
1828
|
-
return /* @__PURE__ */ t(
|
|
1852
|
+
return /* @__PURE__ */ t(Zt, { ...le });
|
|
1829
1853
|
case "split-list-map":
|
|
1830
1854
|
default:
|
|
1831
|
-
return /* @__PURE__ */ t(
|
|
1855
|
+
return /* @__PURE__ */ t(Kt, { ...le });
|
|
1832
1856
|
}
|
|
1833
1857
|
})(), nt = A ?? ne("practiceResults.regionLabel");
|
|
1834
1858
|
return /* @__PURE__ */ t(
|
|
@@ -1841,15 +1865,15 @@ const Ut = it(function({
|
|
|
1841
1865
|
"data-component": "practice-results",
|
|
1842
1866
|
"data-component-id": W,
|
|
1843
1867
|
"data-variant": n,
|
|
1844
|
-
className:
|
|
1845
|
-
...
|
|
1868
|
+
className: At({ variant: n, className: S }),
|
|
1869
|
+
...Oe,
|
|
1846
1870
|
children: tt
|
|
1847
1871
|
}
|
|
1848
1872
|
);
|
|
1849
1873
|
});
|
|
1850
|
-
|
|
1874
|
+
Wt.displayName = "PracticeResults";
|
|
1851
1875
|
export {
|
|
1852
|
-
|
|
1876
|
+
Wt as P,
|
|
1853
1877
|
xt as p
|
|
1854
1878
|
};
|
|
1855
|
-
//# sourceMappingURL=practice-results-
|
|
1879
|
+
//# sourceMappingURL=practice-results-BWX9y6mS.js.map
|