@burdenoff/microfe-ggnomad 2026.705.1 → 2026.705.3
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/ggnomad/GGNomadRoot.js +14 -14
- package/dist/ggnomad/components/BookingPanel.js +219 -0
- package/dist/ggnomad/components/BookingPanel.js.map +1 -0
- package/dist/ggnomad/components/DetailHero.js +22 -0
- package/dist/ggnomad/components/DetailHero.js.map +1 -0
- package/dist/ggnomad/components/EntityCard.js +36 -22
- package/dist/ggnomad/components/EntityCard.js.map +1 -1
- package/dist/ggnomad/components/index.js +2 -0
- package/dist/ggnomad/graphql.js +12 -1
- package/dist/ggnomad/graphql.js.map +1 -1
- package/dist/ggnomad/pages/ActivityDetailsPage.js +83 -74
- package/dist/ggnomad/pages/ActivityDetailsPage.js.map +1 -1
- package/dist/ggnomad/pages/BookingsPage.js +1 -1
- package/dist/ggnomad/pages/EntertainmentPage.js +2 -0
- package/dist/ggnomad/pages/EntertainmentPage.js.map +1 -1
- package/dist/ggnomad/pages/EventDetailsPage.js +87 -77
- package/dist/ggnomad/pages/EventDetailsPage.js.map +1 -1
- package/dist/ggnomad/pages/FavoritesPage.js +1 -1
- package/dist/ggnomad/pages/HospitalityPage.js +2 -0
- package/dist/ggnomad/pages/HospitalityPage.js.map +1 -1
- package/dist/ggnomad/pages/PropertyDetailsPage.js +89 -79
- package/dist/ggnomad/pages/PropertyDetailsPage.js.map +1 -1
- package/dist/ggnomad/pages/TourDetailsPage.js +86 -77
- package/dist/ggnomad/pages/TourDetailsPage.js.map +1 -1
- package/dist/ggnomad/pages/TourismPage.js +2 -0
- package/dist/ggnomad/pages/TourismPage.js.map +1 -1
- package/package.json +1 -1
|
@@ -2,105 +2,115 @@ import { GGNOMAD_PROPERTY_QUERY as e } from "../graphql.js";
|
|
|
2
2
|
import { PageShell as t } from "./PageShell.js";
|
|
3
3
|
import { SectionCard as n } from "../components/SectionCard.js";
|
|
4
4
|
import { DetailRow as r } from "../components/DetailRow.js";
|
|
5
|
+
import { DetailHero as i } from "../components/DetailHero.js";
|
|
6
|
+
import { useGGNomad as a } from "../providers/GGNomadProvider.js";
|
|
7
|
+
import { joinPath as o } from "../utils/navigation.js";
|
|
8
|
+
import { BookingPanel as s } from "../components/BookingPanel.js";
|
|
5
9
|
import "../components/index.js";
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import { GlassCard as f, IllustratedEmptyState as p, NextSteps as m, PagePurpose as h } from "@burdenoff/fe-libs/ui";
|
|
13
|
-
import { Fragment as g, jsx as _, jsxs as v } from "react/jsx-runtime";
|
|
10
|
+
import { Hotel as c } from "lucide-react";
|
|
11
|
+
import { useI18n as l } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
|
|
12
|
+
import { useNavigate as u, useParams as d } from "react-router-dom";
|
|
13
|
+
import { useQuery as f } from "@apollo/client/react";
|
|
14
|
+
import { GlassCard as p, IllustratedEmptyState as m, NextSteps as h, PagePurpose as g } from "@burdenoff/fe-libs/ui";
|
|
15
|
+
import { Fragment as _, jsx as v, jsxs as y } from "react/jsx-runtime";
|
|
14
16
|
//#region src/ggnomad/pages/PropertyDetailsPage.tsx
|
|
15
|
-
function
|
|
16
|
-
let { t:
|
|
17
|
-
variables: { id:
|
|
18
|
-
skip: !
|
|
19
|
-
}),
|
|
20
|
-
return /* @__PURE__ */
|
|
21
|
-
title:
|
|
22
|
-
subtitle:
|
|
23
|
-
children:
|
|
24
|
-
/* @__PURE__ */
|
|
25
|
-
|
|
26
|
-
|
|
17
|
+
function b() {
|
|
18
|
+
let { t: b } = l(), x = u(), { basePath: S = "/" } = a(), { id: C = "" } = d(), { data: w } = f(e, {
|
|
19
|
+
variables: { id: C },
|
|
20
|
+
skip: !C
|
|
21
|
+
}), T = w?.ggnomadProperty;
|
|
22
|
+
return /* @__PURE__ */ v(t, {
|
|
23
|
+
title: T?.name ?? b("ggnomad.property.fallbackTitle", "Property details"),
|
|
24
|
+
subtitle: b("ggnomad.property.subtitle", "Detailed hospitality listing view"),
|
|
25
|
+
children: T ? /* @__PURE__ */ y(_, { children: [
|
|
26
|
+
/* @__PURE__ */ v(i, {
|
|
27
|
+
image: T.images?.[0],
|
|
28
|
+
alt: T.name
|
|
27
29
|
}),
|
|
28
|
-
/* @__PURE__ */
|
|
30
|
+
/* @__PURE__ */ v(g, {
|
|
31
|
+
icon: /* @__PURE__ */ v(c, { className: "size-4" }),
|
|
32
|
+
children: b("ggnomad.property.purpose", "Everything you need to decide on this stay — its type, description, nightly price, guest capacity, rating and the provider behind it — before you reserve it.")
|
|
33
|
+
}),
|
|
34
|
+
/* @__PURE__ */ v(h, {
|
|
29
35
|
storageKey: "ggnomad-property-detail",
|
|
30
36
|
steps: [{
|
|
31
|
-
id: "book",
|
|
32
|
-
label: y("ggnomad.property.next.book", "Book this stay"),
|
|
33
|
-
description: y("ggnomad.property.next.bookDesc", "Reserve these dates and track it under Bookings."),
|
|
34
|
-
icon: /* @__PURE__ */ _(o, { className: "size-4" }),
|
|
35
|
-
onClick: () => b(a(x, "bookings"))
|
|
36
|
-
}, {
|
|
37
37
|
id: "browse",
|
|
38
|
-
label:
|
|
39
|
-
description:
|
|
40
|
-
icon: /* @__PURE__ */
|
|
41
|
-
onClick: () =>
|
|
38
|
+
label: b("ggnomad.property.next.browse", "Compare other stays"),
|
|
39
|
+
description: b("ggnomad.property.next.browseDesc", "Go back to hospitality listings to compare options."),
|
|
40
|
+
icon: /* @__PURE__ */ v(c, { className: "size-4" }),
|
|
41
|
+
onClick: () => x(o(S, "hospitality"))
|
|
42
42
|
}]
|
|
43
43
|
}),
|
|
44
|
-
/* @__PURE__ */
|
|
45
|
-
className: "grid gap-4 lg:grid-cols-
|
|
46
|
-
children: [/* @__PURE__ */
|
|
47
|
-
|
|
48
|
-
children: [
|
|
49
|
-
|
|
50
|
-
className: "text-sm text-text-secondary",
|
|
51
|
-
children: y("ggnomad.property.type", "Type")
|
|
52
|
-
}),
|
|
53
|
-
/* @__PURE__ */ _("p", {
|
|
54
|
-
className: "text-text-primary",
|
|
55
|
-
children: w.type
|
|
56
|
-
}),
|
|
57
|
-
/* @__PURE__ */ _("p", {
|
|
58
|
-
className: "mt-3 text-sm text-text-secondary",
|
|
59
|
-
children: y("ggnomad.property.description", "Description")
|
|
60
|
-
}),
|
|
61
|
-
/* @__PURE__ */ _("p", {
|
|
62
|
-
className: "text-text-primary",
|
|
63
|
-
children: w.description ?? y("ggnomad.property.noDescription", "No description")
|
|
64
|
-
})
|
|
65
|
-
]
|
|
66
|
-
}), /* @__PURE__ */ v(f, {
|
|
67
|
-
treatment: "glass",
|
|
68
|
-
glow: !0,
|
|
69
|
-
className: "border-border-seam p-5",
|
|
70
|
-
children: [/* @__PURE__ */ _("h2", {
|
|
71
|
-
className: "mb-4 text-lg font-medium tracking-tight text-text-primary",
|
|
72
|
-
children: y("ggnomad.property.details", "Details")
|
|
73
|
-
}), /* @__PURE__ */ v("dl", {
|
|
74
|
-
className: "space-y-2 text-sm",
|
|
44
|
+
/* @__PURE__ */ y("div", {
|
|
45
|
+
className: "grid gap-4 lg:grid-cols-3",
|
|
46
|
+
children: [/* @__PURE__ */ y("div", {
|
|
47
|
+
className: "lg:col-span-2 space-y-4",
|
|
48
|
+
children: [/* @__PURE__ */ y(n, {
|
|
49
|
+
title: b("ggnomad.property.about", "About"),
|
|
75
50
|
children: [
|
|
76
|
-
/* @__PURE__ */
|
|
77
|
-
|
|
78
|
-
|
|
51
|
+
/* @__PURE__ */ v("p", {
|
|
52
|
+
className: "text-sm text-text-secondary",
|
|
53
|
+
children: b("ggnomad.property.type", "Type")
|
|
79
54
|
}),
|
|
80
|
-
/* @__PURE__ */
|
|
81
|
-
|
|
82
|
-
|
|
55
|
+
/* @__PURE__ */ v("p", {
|
|
56
|
+
className: "text-text-primary",
|
|
57
|
+
children: T.type
|
|
83
58
|
}),
|
|
84
|
-
/* @__PURE__ */
|
|
85
|
-
|
|
86
|
-
|
|
59
|
+
/* @__PURE__ */ v("p", {
|
|
60
|
+
className: "mt-3 text-sm text-text-secondary",
|
|
61
|
+
children: b("ggnomad.property.description", "Description")
|
|
87
62
|
}),
|
|
88
|
-
/* @__PURE__ */
|
|
89
|
-
|
|
90
|
-
|
|
63
|
+
/* @__PURE__ */ v("p", {
|
|
64
|
+
className: "text-text-primary",
|
|
65
|
+
children: T.description ?? b("ggnomad.property.noDescription", "No description")
|
|
91
66
|
})
|
|
92
67
|
]
|
|
68
|
+
}), /* @__PURE__ */ y(p, {
|
|
69
|
+
treatment: "glass",
|
|
70
|
+
glow: !0,
|
|
71
|
+
className: "border-border-seam p-5",
|
|
72
|
+
children: [/* @__PURE__ */ v("h2", {
|
|
73
|
+
className: "mb-4 text-lg font-medium tracking-tight text-text-primary",
|
|
74
|
+
children: b("ggnomad.property.details", "Details")
|
|
75
|
+
}), /* @__PURE__ */ y("dl", {
|
|
76
|
+
className: "space-y-2 text-sm",
|
|
77
|
+
children: [
|
|
78
|
+
/* @__PURE__ */ v(r, {
|
|
79
|
+
label: b("ggnomad.property.price", "Price"),
|
|
80
|
+
value: `${T.currency} ${Number(T.pricePerNight).toFixed(2)}`
|
|
81
|
+
}),
|
|
82
|
+
/* @__PURE__ */ v(r, {
|
|
83
|
+
label: b("ggnomad.property.guests", "Guests"),
|
|
84
|
+
value: String(T.maxGuests)
|
|
85
|
+
}),
|
|
86
|
+
/* @__PURE__ */ v(r, {
|
|
87
|
+
label: b("ggnomad.property.rating", "Rating"),
|
|
88
|
+
value: String(T.rating ?? b("ggnomad.property.noRating", "N/A"))
|
|
89
|
+
}),
|
|
90
|
+
/* @__PURE__ */ v(r, {
|
|
91
|
+
label: b("ggnomad.property.provider", "Provider"),
|
|
92
|
+
value: T.provider?.name ?? b("ggnomad.property.unassigned", "Unassigned")
|
|
93
|
+
})
|
|
94
|
+
]
|
|
95
|
+
})]
|
|
93
96
|
})]
|
|
94
|
-
})
|
|
97
|
+
}), /* @__PURE__ */ v("div", { children: /* @__PURE__ */ v(s, {
|
|
98
|
+
bookingType: "PROPERTY",
|
|
99
|
+
itemId: T.id ?? C,
|
|
100
|
+
itemName: T.name,
|
|
101
|
+
unitPrice: T.pricePerNight ?? 0,
|
|
102
|
+
currency: T.currency ?? "USD",
|
|
103
|
+
nights: 1
|
|
104
|
+
}) })]
|
|
95
105
|
})
|
|
96
|
-
] }) : /* @__PURE__ */
|
|
106
|
+
] }) : /* @__PURE__ */ v(m, {
|
|
97
107
|
illustration: "empty-data",
|
|
98
|
-
title:
|
|
99
|
-
description:
|
|
108
|
+
title: b("ggnomad.property.notFoundTitle", "No property found"),
|
|
109
|
+
description: b("ggnomad.property.notFoundDescription", "This property is unavailable or may have been removed.")
|
|
100
110
|
})
|
|
101
111
|
});
|
|
102
112
|
}
|
|
103
113
|
//#endregion
|
|
104
|
-
export {
|
|
114
|
+
export { b as PropertyDetailsPage };
|
|
105
115
|
|
|
106
116
|
//# sourceMappingURL=PropertyDetailsPage.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PropertyDetailsPage.js","names":[],"sources":["../../../src/ggnomad/pages/PropertyDetailsPage.tsx"],"sourcesContent":["import { useQuery } from '@apollo/client/react';\nimport type { TypedDocumentNode } from '@apollo/client';\nimport { useI18n } from '@burdenoff/fe-libs/shared/providers/shell/I18nProvider';\nimport { useNavigate, useParams } from 'react-router-dom';\nimport {
|
|
1
|
+
{"version":3,"file":"PropertyDetailsPage.js","names":[],"sources":["../../../src/ggnomad/pages/PropertyDetailsPage.tsx"],"sourcesContent":["import { useQuery } from '@apollo/client/react';\nimport type { TypedDocumentNode } from '@apollo/client';\nimport { useI18n } from '@burdenoff/fe-libs/shared/providers/shell/I18nProvider';\nimport { useNavigate, useParams } from 'react-router-dom';\nimport { Hotel } from 'lucide-react';\nimport { GlassCard, IllustratedEmptyState, NextSteps, PagePurpose } from '@burdenoff/fe-libs/ui';\n\nimport { GGNOMAD_PROPERTY_QUERY } from '../graphql';\nimport { useGGNomad } from '../providers/GGNomadProvider';\nimport { joinPath } from '../utils/navigation';\nimport { PageShell } from './PageShell';\nimport { DetailRow, SectionCard, DetailHero, BookingPanel } from '../components';\n\nexport function PropertyDetailsPage() {\n const { t } = useI18n();\n const navigate = useNavigate();\n const { basePath = '/' } = useGGNomad();\n const { id = '' } = useParams();\n const { data } = useQuery(\n GGNOMAD_PROPERTY_QUERY as TypedDocumentNode<\n {\n ggnomadProperty: {\n id: string;\n name: string;\n type: string;\n description?: string;\n currency: string;\n pricePerNight: number;\n maxGuests: number;\n rating?: number;\n provider?: { name: string };\n images?: string[];\n } | null;\n },\n { id: string }\n >,\n { variables: { id }, skip: !id }\n );\n const property = data?.ggnomadProperty;\n\n return (\n <PageShell\n title={property?.name ?? t('ggnomad.property.fallbackTitle', 'Property details')}\n subtitle={t('ggnomad.property.subtitle', 'Detailed hospitality listing view')}\n >\n {!property ? (\n <IllustratedEmptyState\n illustration=\"empty-data\"\n title={t('ggnomad.property.notFoundTitle', 'No property found')}\n description={t(\n 'ggnomad.property.notFoundDescription',\n 'This property is unavailable or may have been removed.'\n )}\n />\n ) : (\n <>\n <DetailHero image={property.images?.[0]} alt={property.name} />\n <PagePurpose icon={<Hotel className=\"size-4\" />}>\n {t(\n 'ggnomad.property.purpose',\n 'Everything you need to decide on this stay — its type, description, nightly price, guest capacity, rating and the provider behind it — before you reserve it.'\n )}\n </PagePurpose>\n\n <NextSteps\n storageKey=\"ggnomad-property-detail\"\n steps={[\n {\n id: 'browse',\n label: t('ggnomad.property.next.browse', 'Compare other stays'),\n description: t(\n 'ggnomad.property.next.browseDesc',\n 'Go back to hospitality listings to compare options.'\n ),\n icon: <Hotel className=\"size-4\" />,\n onClick: () => navigate(joinPath(basePath, 'hospitality')),\n },\n ]}\n />\n\n <div className=\"grid gap-4 lg:grid-cols-3\">\n <div className=\"lg:col-span-2 space-y-4\">\n <SectionCard title={t('ggnomad.property.about', 'About')}>\n <p className=\"text-sm text-text-secondary\">{t('ggnomad.property.type', 'Type')}</p>\n <p className=\"text-text-primary\">{property.type}</p>\n <p className=\"mt-3 text-sm text-text-secondary\">\n {t('ggnomad.property.description', 'Description')}\n </p>\n <p className=\"text-text-primary\">\n {property.description ?? t('ggnomad.property.noDescription', 'No description')}\n </p>\n </SectionCard>\n <GlassCard treatment=\"glass\" glow className=\"border-border-seam p-5\">\n <h2 className=\"mb-4 text-lg font-medium tracking-tight text-text-primary\">\n {t('ggnomad.property.details', 'Details')}\n </h2>\n <dl className=\"space-y-2 text-sm\">\n <DetailRow\n label={t('ggnomad.property.price', 'Price')}\n value={`${property.currency} ${Number(property.pricePerNight).toFixed(2)}`}\n />\n <DetailRow\n label={t('ggnomad.property.guests', 'Guests')}\n value={String(property.maxGuests)}\n />\n <DetailRow\n label={t('ggnomad.property.rating', 'Rating')}\n value={String(property.rating ?? t('ggnomad.property.noRating', 'N/A'))}\n />\n <DetailRow\n label={t('ggnomad.property.provider', 'Provider')}\n value={\n property.provider?.name ?? t('ggnomad.property.unassigned', 'Unassigned')\n }\n />\n </dl>\n </GlassCard>\n </div>\n <div>\n <BookingPanel\n bookingType=\"PROPERTY\"\n itemId={property.id ?? id}\n itemName={property.name}\n unitPrice={property.pricePerNight ?? 0}\n currency={property.currency ?? 'USD'}\n nights={1}\n />\n </div>\n </div>\n </>\n )}\n </PageShell>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;AAaA,SAAgB,IAAsB;CACpC,IAAM,EAAE,SAAM,GAAS,EACjB,IAAW,GAAa,EACxB,EAAE,cAAW,QAAQ,GAAY,EACjC,EAAE,QAAK,OAAO,GAAW,EACzB,EAAE,YAAS,EACf,GAiBA;EAAE,WAAW,EAAE,OAAI;EAAE,MAAM,CAAC;EAAI,CACjC,EACK,IAAW,GAAM;AAEvB,QACE,kBAAC,GAAD;EACE,OAAO,GAAU,QAAQ,EAAE,kCAAkC,mBAAmB;EAChF,UAAU,EAAE,6BAA6B,o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,SAAS;SAC7C,OAAO,OAAO,EAAS,UAAU;SACjC,CAAA;QACF,kBAAC,GAAD;SACE,OAAO,EAAE,2BAA2B,SAAS;SAC7C,OAAO,OAAO,EAAS,UAAU,EAAE,6BAA6B,MAAM,CAAC;SACvE,CAAA;QACF,kBAAC,GAAD;SACE,OAAO,EAAE,6BAA6B,WAAW;SACjD,OACE,EAAS,UAAU,QAAQ,EAAE,+BAA+B,aAAa;SAE3E,CAAA;QACC;SACK;QACR;QACN,kBAAC,OAAD,EAAA,UACE,kBAAC,GAAD;KACE,aAAY;KACZ,QAAQ,EAAS,MAAM;KACvB,UAAU,EAAS;KACnB,WAAW,EAAS,iBAAiB;KACrC,UAAU,EAAS,YAAY;KAC/B,QAAQ;KACR,CAAA,EACE,CAAA,CACF;;GACL,EAAA,CAAA,GAnFH,kBAAC,GAAD;GACE,cAAa;GACb,OAAO,EAAE,kCAAkC,oBAAoB;GAC/D,aAAa,EACX,wCACA,yDACD;GACD,CAAA;EA8EM,CAAA"}
|
|
@@ -2,97 +2,106 @@ import { GGNOMAD_TOUR_QUERY as e } from "../graphql.js";
|
|
|
2
2
|
import { PageShell as t } from "./PageShell.js";
|
|
3
3
|
import { SectionCard as n } from "../components/SectionCard.js";
|
|
4
4
|
import { DetailRow as r } from "../components/DetailRow.js";
|
|
5
|
+
import { DetailHero as i } from "../components/DetailHero.js";
|
|
6
|
+
import { useGGNomad as a } from "../providers/GGNomadProvider.js";
|
|
7
|
+
import { joinPath as o } from "../utils/navigation.js";
|
|
8
|
+
import { BookingPanel as s } from "../components/BookingPanel.js";
|
|
5
9
|
import "../components/index.js";
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import { GlassCard as p, IllustratedEmptyState as m, NextSteps as h, PagePurpose as g } from "@burdenoff/fe-libs/ui";
|
|
13
|
-
import { Fragment as _, jsx as v, jsxs as y } from "react/jsx-runtime";
|
|
10
|
+
import { CheckCircle2 as c, Compass as l } from "lucide-react";
|
|
11
|
+
import { useI18n as u } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
|
|
12
|
+
import { useNavigate as d, useParams as f } from "react-router-dom";
|
|
13
|
+
import { useQuery as p } from "@apollo/client/react";
|
|
14
|
+
import { GlassCard as m, IllustratedEmptyState as h, NextSteps as g, PagePurpose as _ } from "@burdenoff/fe-libs/ui";
|
|
15
|
+
import { Fragment as v, jsx as y, jsxs as b } from "react/jsx-runtime";
|
|
14
16
|
//#region src/ggnomad/pages/TourDetailsPage.tsx
|
|
15
|
-
function
|
|
16
|
-
let { t:
|
|
17
|
-
variables: { id:
|
|
18
|
-
skip: !
|
|
19
|
-
}),
|
|
20
|
-
return /* @__PURE__ */
|
|
21
|
-
title:
|
|
22
|
-
subtitle:
|
|
23
|
-
children:
|
|
24
|
-
/* @__PURE__ */
|
|
25
|
-
|
|
26
|
-
|
|
17
|
+
function x() {
|
|
18
|
+
let { t: x } = u(), S = d(), { basePath: C = "/" } = a(), { id: w = "" } = f(), { data: T } = p(e, {
|
|
19
|
+
variables: { id: w },
|
|
20
|
+
skip: !w
|
|
21
|
+
}), E = T?.ggnomadTour;
|
|
22
|
+
return /* @__PURE__ */ y(t, {
|
|
23
|
+
title: E?.name ?? x("ggnomad.tour.fallbackTitle", "Tour details"),
|
|
24
|
+
subtitle: x("ggnomad.tour.subtitle", "Tour package details and booking context"),
|
|
25
|
+
children: E ? /* @__PURE__ */ b(v, { children: [
|
|
26
|
+
/* @__PURE__ */ y(i, {
|
|
27
|
+
image: E.images?.[0],
|
|
28
|
+
alt: E.name
|
|
27
29
|
}),
|
|
28
|
-
/* @__PURE__ */
|
|
30
|
+
/* @__PURE__ */ y(_, {
|
|
31
|
+
icon: /* @__PURE__ */ y(l, { className: "size-4" }),
|
|
32
|
+
children: x("ggnomad.tour.purpose", "See exactly what this tour involves — duration, difficulty, your guide, price and the highlights you’ll experience — so you can confirm it fits your trip before booking.")
|
|
33
|
+
}),
|
|
34
|
+
/* @__PURE__ */ y(g, {
|
|
29
35
|
storageKey: "ggnomad-tour-detail",
|
|
30
36
|
steps: [{
|
|
31
|
-
id: "book",
|
|
32
|
-
label: b("ggnomad.tour.next.book", "Book this tour"),
|
|
33
|
-
description: b("ggnomad.tour.next.bookDesc", "Add it to your itinerary and track it under Bookings."),
|
|
34
|
-
icon: /* @__PURE__ */ v(o, { className: "size-4" }),
|
|
35
|
-
onClick: () => x(a(S, "bookings"))
|
|
36
|
-
}, {
|
|
37
37
|
id: "browse",
|
|
38
|
-
label:
|
|
39
|
-
description:
|
|
40
|
-
icon: /* @__PURE__ */
|
|
41
|
-
onClick: () =>
|
|
38
|
+
label: x("ggnomad.tour.next.browse", "Explore more experiences"),
|
|
39
|
+
description: x("ggnomad.tour.next.browseDesc", "Return to Tourism to compare tours and activities."),
|
|
40
|
+
icon: /* @__PURE__ */ y(l, { className: "size-4" }),
|
|
41
|
+
onClick: () => S(o(C, "tourism"))
|
|
42
42
|
}]
|
|
43
43
|
}),
|
|
44
|
-
/* @__PURE__ */
|
|
45
|
-
className: "grid gap-4 lg:grid-cols-
|
|
46
|
-
children: [/* @__PURE__ */
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
className: "
|
|
52
|
-
children:
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
44
|
+
/* @__PURE__ */ b("div", {
|
|
45
|
+
className: "grid gap-4 lg:grid-cols-3",
|
|
46
|
+
children: [/* @__PURE__ */ b("div", {
|
|
47
|
+
className: "lg:col-span-2 space-y-4",
|
|
48
|
+
children: [/* @__PURE__ */ b(m, {
|
|
49
|
+
treatment: "glass",
|
|
50
|
+
glow: !0,
|
|
51
|
+
className: "border-border-seam p-5",
|
|
52
|
+
children: [/* @__PURE__ */ y("h2", {
|
|
53
|
+
className: "mb-4 text-lg font-medium tracking-tight text-text-primary",
|
|
54
|
+
children: x("ggnomad.tour.details", "Details")
|
|
55
|
+
}), /* @__PURE__ */ b("dl", {
|
|
56
|
+
className: "space-y-2 text-sm",
|
|
57
|
+
children: [
|
|
58
|
+
/* @__PURE__ */ y(r, {
|
|
59
|
+
label: x("ggnomad.tour.duration", "Duration"),
|
|
60
|
+
value: E.duration
|
|
61
|
+
}),
|
|
62
|
+
/* @__PURE__ */ y(r, {
|
|
63
|
+
label: x("ggnomad.tour.difficulty", "Difficulty"),
|
|
64
|
+
value: E.difficulty ?? x("ggnomad.tour.na", "N/A")
|
|
65
|
+
}),
|
|
66
|
+
/* @__PURE__ */ y(r, {
|
|
67
|
+
label: x("ggnomad.tour.guide", "Guide"),
|
|
68
|
+
value: E.guideName ?? x("ggnomad.tour.na", "N/A")
|
|
69
|
+
}),
|
|
70
|
+
/* @__PURE__ */ y(r, {
|
|
71
|
+
label: x("ggnomad.tour.price", "Price"),
|
|
72
|
+
value: `${E.currency} ${Number(E.price).toFixed(2)}`
|
|
73
|
+
})
|
|
74
|
+
]
|
|
75
|
+
})]
|
|
76
|
+
}), /* @__PURE__ */ y(n, {
|
|
77
|
+
title: x("ggnomad.tour.highlights", "Highlights"),
|
|
78
|
+
children: /* @__PURE__ */ y("ul", {
|
|
79
|
+
className: "space-y-2 text-sm",
|
|
80
|
+
children: (E.highlights ?? []).map((e) => /* @__PURE__ */ b("li", {
|
|
81
|
+
className: "flex items-start gap-2 text-text-primary",
|
|
82
|
+
children: [/* @__PURE__ */ y(c, {
|
|
83
|
+
className: "mt-0.5 size-4 flex-shrink-0 text-status-success-text",
|
|
84
|
+
"aria-hidden": "true"
|
|
85
|
+
}), e]
|
|
86
|
+
}, e))
|
|
87
|
+
})
|
|
73
88
|
})]
|
|
74
|
-
}), /* @__PURE__ */
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
className: "mt-0.5 size-4 flex-shrink-0 text-status-success-text",
|
|
82
|
-
"aria-hidden": "true"
|
|
83
|
-
}), e]
|
|
84
|
-
}, e))
|
|
85
|
-
})
|
|
86
|
-
})]
|
|
89
|
+
}), /* @__PURE__ */ y("div", { children: /* @__PURE__ */ y(s, {
|
|
90
|
+
bookingType: "TOUR",
|
|
91
|
+
itemId: E.id ?? w,
|
|
92
|
+
itemName: E.name,
|
|
93
|
+
unitPrice: E.price ?? 0,
|
|
94
|
+
currency: E.currency ?? "USD"
|
|
95
|
+
}) })]
|
|
87
96
|
})
|
|
88
|
-
] }) : /* @__PURE__ */
|
|
97
|
+
] }) : /* @__PURE__ */ y(h, {
|
|
89
98
|
illustration: "empty-data",
|
|
90
|
-
title:
|
|
91
|
-
description:
|
|
99
|
+
title: x("ggnomad.tour.notFoundTitle", "No tour found"),
|
|
100
|
+
description: x("ggnomad.tour.notFoundDescription", "This tour is unavailable or may have been removed.")
|
|
92
101
|
})
|
|
93
102
|
});
|
|
94
103
|
}
|
|
95
104
|
//#endregion
|
|
96
|
-
export {
|
|
105
|
+
export { x as TourDetailsPage };
|
|
97
106
|
|
|
98
107
|
//# sourceMappingURL=TourDetailsPage.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TourDetailsPage.js","names":[],"sources":["../../../src/ggnomad/pages/TourDetailsPage.tsx"],"sourcesContent":["import { useQuery } from '@apollo/client/react';\nimport type { TypedDocumentNode } from '@apollo/client';\nimport { useI18n } from '@burdenoff/fe-libs/shared/providers/shell/I18nProvider';\nimport { useNavigate, useParams } from 'react-router-dom';\nimport {
|
|
1
|
+
{"version":3,"file":"TourDetailsPage.js","names":[],"sources":["../../../src/ggnomad/pages/TourDetailsPage.tsx"],"sourcesContent":["import { useQuery } from '@apollo/client/react';\nimport type { TypedDocumentNode } from '@apollo/client';\nimport { useI18n } from '@burdenoff/fe-libs/shared/providers/shell/I18nProvider';\nimport { useNavigate, useParams } from 'react-router-dom';\nimport { CheckCircle2, Compass } from 'lucide-react';\nimport { GlassCard, IllustratedEmptyState, NextSteps, PagePurpose } from '@burdenoff/fe-libs/ui';\n\nimport { GGNOMAD_TOUR_QUERY } from '../graphql';\nimport { useGGNomad } from '../providers/GGNomadProvider';\nimport { joinPath } from '../utils/navigation';\nimport { PageShell } from './PageShell';\nimport { DetailRow, SectionCard, DetailHero, BookingPanel } from '../components';\n\nexport function TourDetailsPage() {\n const { t } = useI18n();\n const navigate = useNavigate();\n const { basePath = '/' } = useGGNomad();\n const { id = '' } = useParams();\n const { data } = useQuery(\n GGNOMAD_TOUR_QUERY as TypedDocumentNode<\n {\n ggnomadTour: {\n id: string;\n name: string;\n duration: string;\n difficulty?: string;\n guideName?: string;\n currency: string;\n price: number;\n highlights: string[];\n images?: string[];\n } | null;\n },\n { id: string }\n >,\n { variables: { id }, skip: !id }\n );\n const tour = data?.ggnomadTour;\n\n return (\n <PageShell\n title={tour?.name ?? t('ggnomad.tour.fallbackTitle', 'Tour details')}\n subtitle={t('ggnomad.tour.subtitle', 'Tour package details and booking context')}\n >\n {!tour ? (\n <IllustratedEmptyState\n illustration=\"empty-data\"\n title={t('ggnomad.tour.notFoundTitle', 'No tour found')}\n description={t(\n 'ggnomad.tour.notFoundDescription',\n 'This tour is unavailable or may have been removed.'\n )}\n />\n ) : (\n <>\n <DetailHero image={tour.images?.[0]} alt={tour.name} />\n <PagePurpose icon={<Compass className=\"size-4\" />}>\n {t(\n 'ggnomad.tour.purpose',\n 'See exactly what this tour involves — duration, difficulty, your guide, price and the highlights you’ll experience — so you can confirm it fits your trip before booking.'\n )}\n </PagePurpose>\n\n <NextSteps\n storageKey=\"ggnomad-tour-detail\"\n steps={[\n {\n id: 'browse',\n label: t('ggnomad.tour.next.browse', 'Explore more experiences'),\n description: t(\n 'ggnomad.tour.next.browseDesc',\n 'Return to Tourism to compare tours and activities.'\n ),\n icon: <Compass className=\"size-4\" />,\n onClick: () => navigate(joinPath(basePath, 'tourism')),\n },\n ]}\n />\n\n <div className=\"grid gap-4 lg:grid-cols-3\">\n <div className=\"lg:col-span-2 space-y-4\">\n <GlassCard treatment=\"glass\" glow className=\"border-border-seam p-5\">\n <h2 className=\"mb-4 text-lg font-medium tracking-tight text-text-primary\">\n {t('ggnomad.tour.details', 'Details')}\n </h2>\n <dl className=\"space-y-2 text-sm\">\n <DetailRow label={t('ggnomad.tour.duration', 'Duration')} value={tour.duration} />\n <DetailRow\n label={t('ggnomad.tour.difficulty', 'Difficulty')}\n value={tour.difficulty ?? t('ggnomad.tour.na', 'N/A')}\n />\n <DetailRow\n label={t('ggnomad.tour.guide', 'Guide')}\n value={tour.guideName ?? t('ggnomad.tour.na', 'N/A')}\n />\n <DetailRow\n label={t('ggnomad.tour.price', 'Price')}\n value={`${tour.currency} ${Number(tour.price).toFixed(2)}`}\n />\n </dl>\n </GlassCard>\n <SectionCard title={t('ggnomad.tour.highlights', 'Highlights')}>\n <ul className=\"space-y-2 text-sm\">\n {(tour.highlights ?? []).map((highlight) => (\n <li key={highlight} className=\"flex items-start gap-2 text-text-primary\">\n <CheckCircle2\n className=\"mt-0.5 size-4 flex-shrink-0 text-status-success-text\"\n aria-hidden=\"true\"\n />\n {highlight}\n </li>\n ))}\n </ul>\n </SectionCard>\n </div>\n <div>\n <BookingPanel\n bookingType=\"TOUR\"\n itemId={tour.id ?? id}\n itemName={tour.name}\n unitPrice={tour.price ?? 0}\n currency={tour.currency ?? 'USD'}\n />\n </div>\n </div>\n </>\n )}\n </PageShell>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;AAaA,SAAgB,IAAkB;CAChC,IAAM,EAAE,SAAM,GAAS,EACjB,IAAW,GAAa,EACxB,EAAE,cAAW,QAAQ,GAAY,EACjC,EAAE,QAAK,OAAO,GAAW,EACzB,EAAE,YAAS,E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O,GAAG,EAAK,SAAS,GAAG,OAAO,EAAK,MAAM,CAAC,QAAQ,EAAE;SACxD,CAAA;QACC;SACK;SACZ,kBAAC,GAAD;MAAa,OAAO,EAAE,2BAA2B,aAAa;gBAC5D,kBAAC,MAAD;OAAI,WAAU;kBACV,EAAK,cAAc,EAAE,EAAE,KAAK,MAC5B,kBAAC,MAAD;QAAoB,WAAU;kBAA9B,CACE,kBAAC,GAAD;SACE,WAAU;SACV,eAAY;SACZ,CAAA,EACD,EACE;UANI,EAMJ,CACL;OACC,CAAA;MACO,CAAA,CACV;QACN,kBAAC,OAAD,EAAA,UACE,kBAAC,GAAD;KACE,aAAY;KACZ,QAAQ,EAAK,MAAM;KACnB,UAAU,EAAK;KACf,WAAW,EAAK,SAAS;KACzB,UAAU,EAAK,YAAY;KAC3B,CAAA,EACE,CAAA,CACF;;GACL,EAAA,CAAA,GAhFH,kBAAC,GAAD;GACE,cAAa;GACb,OAAO,EAAE,8BAA8B,gBAAgB;GACvD,aAAa,EACX,oCACA,qDACD;GACD,CAAA;EA2EM,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TourismPage.js","names":[],"sources":["../../../src/ggnomad/pages/TourismPage.tsx"],"sourcesContent":["import { useState } from 'react';\nimport { useQuery } from '@apollo/client/react';\nimport type { TypedDocumentNode } from '@apollo/client';\nimport { useI18n } from '@burdenoff/fe-libs/shared/providers/shell/I18nProvider';\nimport { Compass } from 'lucide-react';\nimport { EmphasisPanel, IllustratedEmptyState, PagePurpose } from '@burdenoff/fe-libs/ui';\n\nimport { GGNOMAD_ACTIVITIES_QUERY, GGNOMAD_TOURS_QUERY } from '../graphql';\nimport { PageShell } from './PageShell';\nimport { EntityCard, SectionCard, LoadMoreButton } from '../components';\n\ntype TourismItem = {\n id: string;\n name: string;\n duration: string;\n price: number;\n currency: string;\n};\n\nexport function TourismPage() {\n const { t } = useI18n();\n const [tourLimit, setTourLimit] = useState(12);\n const [activityLimit, setActivityLimit] = useState(12);\n const { data: toursData } = useQuery(\n GGNOMAD_TOURS_QUERY as TypedDocumentNode<\n { ggnomadTours: TourismItem[] },\n { first: number; skip: number }\n >,\n {\n variables: { first: tourLimit, skip: 0 },\n }\n );\n const { data: activitiesData } = useQuery(\n GGNOMAD_ACTIVITIES_QUERY as TypedDocumentNode<\n { ggnomadActivities: TourismItem[] },\n { first: number; skip: number }\n >,\n { variables: { first: activityLimit, skip: 0 } }\n );\n const tours = toursData?.ggnomadTours ?? [];\n const activities = activitiesData?.ggnomadActivities ?? [];\n\n const renderList = (items: TourismItem[], basePath: string, emptyLabel: string) => {\n if (items.length === 0) {\n return (\n <IllustratedEmptyState\n illustration=\"empty-data\"\n title={emptyLabel}\n description={t(\n 'ggnomad.tourism.emptyDescription',\n 'Curated experiences will appear here once published.'\n )}\n />\n );\n }\n return (\n <div className=\"grid gap-3\">\n {items.map((item) => (\n <EntityCard\n key={item.id}\n to={`${basePath}/${item.id}`}\n title={item.name}\n meta={item.duration}\n price={`${item.currency} ${Number(item.price).toFixed(2)}`}\n />\n ))}\n </div>\n );\n };\n\n return (\n <PageShell\n title={t('ggnomad.tourism.title', 'Tourism')}\n titleAccent={t('ggnomad.tourism.title.accent', 'Tourism')}\n subtitle={t('ggnomad.tourism.subtitle', 'Tours and curated activity experiences')}\n >\n <PagePurpose icon={<Compass className=\"size-4\" />}>\n {t(\n 'ggnomad.tourism.purpose',\n 'Plan what you’ll actually do at a destination — guided tours and bookable activities curated by local operators. Open any experience to review duration, price and what’s included, then add it to a booking.'\n )}\n </PagePurpose>\n\n <EmphasisPanel>\n <div className=\"grid gap-4 sm:grid-cols-2\">\n <div>\n <p className=\"text-sm text-text-secondary\">{t('ggnomad.tourism.tours', 'Tours')}</p>\n <p className=\"mt-1 text-2xl font-semibold tabular-nums text-text-primary\">\n {tours.length}\n </p>\n </div>\n <div>\n <p className=\"text-sm text-text-secondary\">\n {t('ggnomad.tourism.activities', 'Activities')}\n </p>\n <p className=\"mt-1 text-2xl font-semibold tabular-nums text-text-primary\">\n {activities.length}\n </p>\n </div>\n </div>\n <p className=\"mt-4 text-sm text-text-secondary\">\n {t(\n 'ggnomad.tourism.emphasisNote',\n 'Curated, bookable experiences across your destinations — pick a tour or activity below to see full details.'\n )}\n </p>\n </EmphasisPanel>\n\n <div className=\"grid gap-6 lg:grid-cols-2\">\n <SectionCard title={t('ggnomad.tourism.tours', 'Tours')}>\n {renderList(tours, 'tours', t('ggnomad.tourism.toursEmpty', 'No tours yet'))}\n <LoadMoreButton
|
|
1
|
+
{"version":3,"file":"TourismPage.js","names":[],"sources":["../../../src/ggnomad/pages/TourismPage.tsx"],"sourcesContent":["import { useState } from 'react';\nimport { useQuery } from '@apollo/client/react';\nimport type { TypedDocumentNode } from '@apollo/client';\nimport { useI18n } from '@burdenoff/fe-libs/shared/providers/shell/I18nProvider';\nimport { Compass } from 'lucide-react';\nimport { EmphasisPanel, IllustratedEmptyState, PagePurpose } from '@burdenoff/fe-libs/ui';\n\nimport { GGNOMAD_ACTIVITIES_QUERY, GGNOMAD_TOURS_QUERY } from '../graphql';\nimport { PageShell } from './PageShell';\nimport { EntityCard, SectionCard, LoadMoreButton } from '../components';\n\ntype TourismItem = {\n images?: string[];\n id: string;\n name: string;\n duration: string;\n price: number;\n currency: string;\n};\n\nexport function TourismPage() {\n const { t } = useI18n();\n const [tourLimit, setTourLimit] = useState(12);\n const [activityLimit, setActivityLimit] = useState(12);\n const { data: toursData } = useQuery(\n GGNOMAD_TOURS_QUERY as TypedDocumentNode<\n { ggnomadTours: TourismItem[] },\n { first: number; skip: number }\n >,\n {\n variables: { first: tourLimit, skip: 0 },\n }\n );\n const { data: activitiesData } = useQuery(\n GGNOMAD_ACTIVITIES_QUERY as TypedDocumentNode<\n { ggnomadActivities: TourismItem[] },\n { first: number; skip: number }\n >,\n { variables: { first: activityLimit, skip: 0 } }\n );\n const tours = toursData?.ggnomadTours ?? [];\n const activities = activitiesData?.ggnomadActivities ?? [];\n\n const renderList = (items: TourismItem[], basePath: string, emptyLabel: string) => {\n if (items.length === 0) {\n return (\n <IllustratedEmptyState\n illustration=\"empty-data\"\n title={emptyLabel}\n description={t(\n 'ggnomad.tourism.emptyDescription',\n 'Curated experiences will appear here once published.'\n )}\n />\n );\n }\n return (\n <div className=\"grid gap-3\">\n {items.map((item) => (\n <EntityCard\n key={item.id}\n to={`${basePath}/${item.id}`}\n image={item.images?.[0]}\n imageAlt={item.name}\n title={item.name}\n meta={item.duration}\n price={`${item.currency} ${Number(item.price).toFixed(2)}`}\n />\n ))}\n </div>\n );\n };\n\n return (\n <PageShell\n title={t('ggnomad.tourism.title', 'Tourism')}\n titleAccent={t('ggnomad.tourism.title.accent', 'Tourism')}\n subtitle={t('ggnomad.tourism.subtitle', 'Tours and curated activity experiences')}\n >\n <PagePurpose icon={<Compass className=\"size-4\" />}>\n {t(\n 'ggnomad.tourism.purpose',\n 'Plan what you’ll actually do at a destination — guided tours and bookable activities curated by local operators. Open any experience to review duration, price and what’s included, then add it to a booking.'\n )}\n </PagePurpose>\n\n <EmphasisPanel>\n <div className=\"grid gap-4 sm:grid-cols-2\">\n <div>\n <p className=\"text-sm text-text-secondary\">{t('ggnomad.tourism.tours', 'Tours')}</p>\n <p className=\"mt-1 text-2xl font-semibold tabular-nums text-text-primary\">\n {tours.length}\n </p>\n </div>\n <div>\n <p className=\"text-sm text-text-secondary\">\n {t('ggnomad.tourism.activities', 'Activities')}\n </p>\n <p className=\"mt-1 text-2xl font-semibold tabular-nums text-text-primary\">\n {activities.length}\n </p>\n </div>\n </div>\n <p className=\"mt-4 text-sm text-text-secondary\">\n {t(\n 'ggnomad.tourism.emphasisNote',\n 'Curated, bookable experiences across your destinations — pick a tour or activity below to see full details.'\n )}\n </p>\n </EmphasisPanel>\n\n <div className=\"grid gap-6 lg:grid-cols-2\">\n <SectionCard title={t('ggnomad.tourism.tours', 'Tours')}>\n {renderList(tours, 'tours', t('ggnomad.tourism.toursEmpty', 'No tours yet'))}\n <LoadMoreButton\n visible={tours.length >= tourLimit}\n onLoadMore={() => setTourLimit((l) => l + 12)}\n />\n </SectionCard>\n <SectionCard title={t('ggnomad.tourism.activities', 'Activities')}>\n {renderList(\n activities,\n 'activities',\n t('ggnomad.tourism.activitiesEmpty', 'No activities yet')\n )}\n <LoadMoreButton\n visible={activities.length >= activityLimit}\n onLoadMore={() => setActivityLimit((l) => l + 12)}\n />\n </SectionCard>\n </div>\n </PageShell>\n );\n}\n"],"mappings":";;;;;;;;;;;;;AAoBA,SAAgB,IAAc;CAC5B,IAAM,EAAE,SAAM,GAAS,EACjB,CAAC,GAAW,KAAgB,EAAS,GAAG,EACxC,CAAC,GAAe,KAAoB,EAAS,GAAG,EAChD,EAAE,MAAM,MAAc,EAC1B,GAIA,EACE,WAAW;EAAE,OAAO;EAAW,MAAM;EAAG,EACzC,CACF,EACK,EAAE,MAAM,MAAmB,EAC/B,GAIA,EAAE,WAAW;EAAE,OAAO;EAAe,MAAM;EAAG,EAAE,CACjD,EACK,IAAQ,GAAW,gBAAgB,EAAE,EACrC,IAAa,GAAgB,qBAAqB,EAAE,EAEpD,KAAc,GAAsB,GAAkB,MACtD,EAAM,WAAW,IAEjB,kBAAC,GAAD;EACE,cAAa;EACb,OAAO;EACP,aAAa,EACX,oCACA,uDACD;EACD,CAAA,GAIJ,kBAAC,OAAD;EAAK,WAAU;YACZ,EAAM,KAAK,MACV,kBAAC,GAAD;GAEE,IAAI,GAAG,EAAS,GAAG,EAAK;GACxB,OAAO,EAAK,SAAS;GACrB,UAAU,EAAK;GACf,OAAO,EAAK;GACZ,MAAM,EAAK;GACX,OAAO,GAAG,EAAK,SAAS,GAAG,OAAO,EAAK,MAAM,CAAC,QAAQ,EAAE;GACxD,EAPK,EAAK,GAOV,CACF;EACE,CAAA;AAIV,QACE,kBAAC,GAAD;EACE,OAAO,EAAE,yBAAyB,UAAU;EAC5C,aAAa,EAAE,gCAAgC,UAAU;EACzD,UAAU,EAAE,4BAA4B,yCAAyC;YAHnF;GAKE,kBA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