@loczer/storefront-sdk 0.208.0 → 0.210.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/StorefrontContext.d.ts +89 -0
- package/dist/StorefrontContext.d.ts.map +1 -1
- package/dist/StorefrontContext.js +8 -1
- package/dist/StorefrontProvider.d.ts +84 -0
- package/dist/StorefrontProvider.d.ts.map +1 -1
- package/dist/StorefrontProvider.js +55 -41
- package/dist/chunks/pkg/booking-engine/dist/node_modules/@date-fns/tz/date/index-DAbcklF5.js +1 -0
- package/dist/chunks/pkg/booking-engine/dist/node_modules/@date-fns/tz/date/mini-CSEBo1ZP.js +60 -0
- package/dist/chunks/pkg/booking-engine/dist/node_modules/@date-fns/tz/index--u3Qf-qy.js +4 -0
- package/dist/chunks/pkg/booking-engine/dist/node_modules/@date-fns/tz/tz/index-CEcibV-H.js +1 -0
- package/dist/chunks/pkg/booking-engine/dist/node_modules/@date-fns/tz/tzOffset/index-COlDDdap.js +22 -0
- package/dist/chunks/pkg/booking-engine/dist/pricing-BJaynUu_.js +3 -0
- package/dist/chunks/pkg/booking-engine/dist/utils/schedule-ssRov9xe.js +39 -0
- package/dist/chunks/pkg/booking-engine/dist/utils/timezone-B6XIbBPz.js +79 -0
- package/dist/chunks/pkg/ui/dist/Map/{MapContent-CDeWtwKa.js → MapContent-TzYCv8ji.js} +109 -108
- package/dist/chunks/pkg/ui/dist/Map/constants-dF2KdJZy.js +8 -0
- package/dist/chunks/pkg/ui/dist/{Map-Cs7wgtH9.js → Map-ZM-ZOU9P.js} +1 -1
- package/dist/components/BookingBikeVariantDialog/index.js +15 -15
- package/dist/components/ContactSection/index.js +9 -9
- package/dist/components/Header/index.d.ts.map +1 -1
- package/dist/components/Header/index.js +72 -66
- package/dist/components/Itineraries/ItinerariesSection.d.ts +2 -0
- package/dist/components/Itineraries/ItinerariesSection.d.ts.map +1 -0
- package/dist/components/Itineraries/ItinerariesSection.js +81 -0
- package/dist/components/Itineraries/ItineraryListItem.d.ts +9 -0
- package/dist/components/Itineraries/ItineraryListItem.d.ts.map +1 -0
- package/dist/components/Itineraries/ItineraryListItem.js +100 -0
- package/dist/components/Itineraries/ItineraryRouteMap.d.ts +10 -0
- package/dist/components/Itineraries/ItineraryRouteMap.d.ts.map +1 -0
- package/dist/components/Itineraries/ItineraryRouteMap.js +67 -0
- package/dist/components/Itineraries/index.d.ts +4 -0
- package/dist/components/Itineraries/index.d.ts.map +1 -0
- package/dist/components/Itineraries/index.js +4 -0
- package/dist/components/Map/index.d.ts +12 -0
- package/dist/components/Map/index.d.ts.map +1 -1
- package/dist/components/Map/index.js +1 -1
- package/dist/components/ProductPriceBadge/index.d.ts.map +1 -1
- package/dist/components/ProductPriceBadge/index.js +86 -80
- package/dist/components/StorefrontCartPanel/index.d.ts +4 -4
- package/dist/components/StorefrontCartPanel/index.d.ts.map +1 -1
- package/dist/components/StorefrontCartPanel/index.js +10 -9
- package/dist/i18n/en.d.ts +42 -6
- package/dist/i18n/en.d.ts.map +1 -1
- package/dist/i18n/en.js +44 -8
- package/dist/i18n/fr.d.ts +42 -6
- package/dist/i18n/fr.d.ts.map +1 -1
- package/dist/i18n/fr.js +44 -8
- package/dist/index.d.ts +817 -36
- package/dist/index.js +67 -60
- package/dist/lib/booking.d.ts +0 -6
- package/dist/lib/booking.d.ts.map +1 -1
- package/dist/lib/booking.js +51 -65
- package/dist/lib/cartSummary.d.ts +5 -3
- package/dist/lib/cartSummary.d.ts.map +1 -1
- package/dist/lib/cartSummary.js +7 -7
- package/dist/lib/itineraryPresentation.d.ts +14 -0
- package/dist/lib/itineraryPresentation.d.ts.map +1 -0
- package/dist/lib/itineraryPresentation.js +26 -0
- package/dist/lib/pricing.d.ts +18 -6
- package/dist/lib/pricing.d.ts.map +1 -1
- package/dist/lib/pricing.js +45 -29
- package/dist/lib/storefrontItineraries.d.ts +418 -0
- package/dist/lib/storefrontItineraries.d.ts.map +1 -0
- package/dist/lib/storefrontItineraries.js +81 -0
- package/dist/pages/BookingPage.d.ts.map +1 -1
- package/dist/pages/BookingPage.js +205 -201
- package/dist/pages/CheckoutPage.d.ts.map +1 -1
- package/dist/pages/CheckoutPage.js +276 -273
- package/dist/pages/HomePage.d.ts.map +1 -1
- package/dist/pages/HomePage.js +111 -108
- package/dist/pages/ItinerariesPage.d.ts +2 -0
- package/dist/pages/ItinerariesPage.d.ts.map +1 -0
- package/dist/pages/ItinerariesPage.js +76 -0
- package/dist/pages/ItineraryDetailsPage.d.ts +66 -0
- package/dist/pages/ItineraryDetailsPage.d.ts.map +1 -0
- package/dist/pages/ItineraryDetailsPage.js +223 -0
- package/dist/pages/ProductPage.js +6 -6
- package/dist/pages/checkout/components/CheckoutSummaryColumn.d.ts +2 -2
- package/dist/pages/checkout/components/CheckoutSummaryColumn.d.ts.map +1 -1
- package/dist/pages/checkout/components/CheckoutSummaryColumn.js +4 -4
- package/dist/pages/itineraries/ElevationProfile.d.ts +5 -0
- package/dist/pages/itineraries/ElevationProfile.d.ts.map +1 -0
- package/dist/pages/itineraries/ElevationProfile.js +59 -0
- package/dist/routes.d.ts.map +1 -1
- package/dist/routes.js +18 -10
- package/dist/storefront.css +1 -1
- package/package.json +1 -1
- package/dist/chunks/pkg/ui/dist/Map/constants-BNmiJXfg.js +0 -4
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pricing.d.ts","sourceRoot":"","sources":["../../src/lib/pricing.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,SAAS,CAAA;
|
|
1
|
+
{"version":3,"file":"pricing.d.ts","sourceRoot":"","sources":["../../src/lib/pricing.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,SAAS,CAAA;AAOxC,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,sBAAsB,CAAA;AACnE,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,WAAW,CAAA;AACxD,OAAO,KAAK,EAAE,4BAA4B,EAAE,MAAM,sBAAsB,CAAA;AAQxE,KAAK,SAAS,GAAG,4BAA4B,CAAC,MAAM,CAAC,CAAA;AACrD,KAAK,oBAAoB,GAAG,uBAAuB,CAAC,eAAe,CAAC,CAAC,SAAS,CAAC,CAAA;AAE/E,MAAM,MAAM,cAAc,GAAG;IAC3B,SAAS,EAAE,MAAM,CAAA;IACjB,eAAe,EAAE,MAAM,CAAA;IACvB,iBAAiB,EAAE,MAAM,CAAA;CAC1B,CAAA;AAoBD,eAAO,MAAM,0BAA0B,GACrC,YAAY,MAAM,EAClB,QAAQ,MAAM,EACd,eAAiC;IAAE,QAAQ,CAAC,EAAE,MAAM,CAAA;CAAO,WAKzD,CAAA;AAkBJ,wBAAgB,mBAAmB,CACjC,SAAS,EAAE,SAAS,EACpB,CAAC,EAAE,SAAS,EACZ,KAAK,SAAI,GACR,MAAM,CAER;AAED,wBAAgB,wBAAwB,CACtC,QAAQ,EAAE,MAAM,EAChB,SAAS,EAAE,SAAS,EACpB,MAAM,EAAE,MAAM,EACd,CAAC,EAAE,SAAS,GACX,MAAM,CAER;AAED,MAAM,MAAM,wBAAwB,GAAG;IACrC,SAAS,EAAE,SAAS,CAAA;IACpB,iBAAiB,EAAE,MAAM,CAAA;CAC1B,CAAA;AAED,wBAAgB,iCAAiC,CAC/C,OAAO,EAAE,uBAAuB,EAChC,OAAO,EAAE,oBAAoB,EAC7B,QAAQ,SAAQ,GACf,wBAAwB,GAAG,IAAI,CAcjC;AAED,wBAAgB,+BAA+B,CAC7C,MAAM,EAAE,4BAA4B,EAAE,GAAG,SAAS,EAClD,SAAS,EAAE,MAAM,EACjB,SAAS,GAAE,SAA8B,GACxC,MAAM,GAAG,IAAI,CAYf;AAED,wBAAgB,oBAAoB,CAClC,MAAM,EAAE,4BAA4B,EAAE,GAAG,SAAS,EAClD,MAAM,EAAE,MAAM,EACd,SAAS,GAAE,SAA8B,GACxC,cAAc,EAAE,CAiBlB;AAED,wBAAgB,oBAAoB,CAClC,MAAM,EAAE,4BAA4B,EAAE,GAAG,SAAS,EAClD,MAAM,EAAE,MAAM,EACd,CAAC,EAAE,SAAS,EACZ,SAAS,GAAE,SAA8B,GACxC,MAAM,EAAE,CAiBV"}
|
package/dist/lib/pricing.js
CHANGED
|
@@ -1,45 +1,61 @@
|
|
|
1
1
|
import { calculatePriceForQuantity as e } from "../chunks/pkg/booking-engine/dist/utils/pricing-CqXJ5fMP.js";
|
|
2
|
-
import {
|
|
2
|
+
import { calculateRentalQuantity as t, combineDateAndTime as n } from "../chunks/pkg/booking-engine/dist/utils/schedule-ssRov9xe.js";
|
|
3
|
+
import "../chunks/pkg/booking-engine/dist/pricing-BJaynUu_.js";
|
|
4
|
+
import { formatPriceMinor as r } from "./utils.js";
|
|
3
5
|
//#region src/lib/pricing.ts
|
|
4
|
-
var
|
|
6
|
+
var i = "EUR", a = "day", o = 8, s = (e) => [...e].sort((e, t) => e.quantity - t.quantity), c = (e) => e.find((e) => e.currency?.trim())?.currency?.trim() || i, l = (e) => Math.abs(e) % 100 == 0 ? {
|
|
5
7
|
minimumFractionDigits: 0,
|
|
6
8
|
maximumFractionDigits: 0
|
|
7
|
-
} : {},
|
|
8
|
-
currency:
|
|
9
|
-
...
|
|
10
|
-
}),
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
}
|
|
14
|
-
function
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
9
|
+
} : {}, u = (e, t, { currency: n = i } = {}) => r(e, t, {
|
|
10
|
+
currency: n,
|
|
11
|
+
...l(e)
|
|
12
|
+
}), d = (e, t) => s((e ?? []).filter((e) => e.unit === t && e.quantity > 0)), f = (e, t) => new Intl.NumberFormat(t, { maximumFractionDigits: 3 }).format(e);
|
|
13
|
+
function p(e, t, n = 1) {
|
|
14
|
+
return t(`price_unit_${e}`, { count: n });
|
|
15
|
+
}
|
|
16
|
+
function m(e, t, n, r) {
|
|
17
|
+
return `${f(e, n)} ${p(t, r, e)}`;
|
|
18
|
+
}
|
|
19
|
+
function h(e, r, i = "UTC") {
|
|
20
|
+
try {
|
|
21
|
+
let a = n(e.start_date, e.start_time, i), o = n(e.end_date, e.end_time, i);
|
|
22
|
+
return o.getTime() <= a.getTime() ? null : {
|
|
23
|
+
priceUnit: r.baseUnit,
|
|
24
|
+
billableUnitCount: t(a, o, r, i)
|
|
25
|
+
};
|
|
26
|
+
} catch {
|
|
27
|
+
return null;
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
function g(t, n, r = a) {
|
|
31
|
+
if (!Number.isFinite(n) || n <= 0) return null;
|
|
32
|
+
let i = d(t, r);
|
|
33
|
+
if (i.length === 0) return null;
|
|
18
34
|
try {
|
|
19
|
-
return e(
|
|
35
|
+
return e(i, n, r);
|
|
20
36
|
} catch {
|
|
21
37
|
return null;
|
|
22
38
|
}
|
|
23
39
|
}
|
|
24
|
-
function
|
|
25
|
-
let
|
|
26
|
-
if (
|
|
27
|
-
let i =
|
|
28
|
-
return Array.from({ length:
|
|
29
|
-
let
|
|
40
|
+
function _(e, t, n = a) {
|
|
41
|
+
let r = d(e, n);
|
|
42
|
+
if (r.length === 0) return [];
|
|
43
|
+
let i = c(r);
|
|
44
|
+
return Array.from({ length: o }, (e, a) => {
|
|
45
|
+
let o = a + 1, s = g(r, o, n) ?? 0, c = Math.ceil(s / o / 10) * 10;
|
|
30
46
|
return {
|
|
31
|
-
|
|
32
|
-
totalPriceLabel: s
|
|
33
|
-
|
|
47
|
+
unitCount: o,
|
|
48
|
+
totalPriceLabel: u(s, t, { currency: i }),
|
|
49
|
+
perUnitPriceLabel: u(c, t, { currency: i })
|
|
34
50
|
};
|
|
35
51
|
});
|
|
36
52
|
}
|
|
37
|
-
function
|
|
38
|
-
let
|
|
39
|
-
return
|
|
40
|
-
let
|
|
41
|
-
return d <= 0 || f < 0 ?
|
|
53
|
+
function v(e, t, n, r = a) {
|
|
54
|
+
let i = d(e, r), o = c(i);
|
|
55
|
+
return i.map((e, a) => {
|
|
56
|
+
let s = a > 0 ? i[a - 1] : void 0, c = s?.quantity ?? 0, l = s?.value ?? 0, d = e.quantity - c, f = e.value - l;
|
|
57
|
+
return d <= 0 || f < 0 ? u(e.value, t, { currency: o }) : `${u(f, t, { currency: o })} / ${m(d, r, t, n)}`;
|
|
42
58
|
});
|
|
43
59
|
}
|
|
44
60
|
//#endregion
|
|
45
|
-
export {
|
|
61
|
+
export { v as buildPriceTierLabels, _ as buildRentalPriceRows, h as calculateBookingRentalUnitSummary, g as calculateRentalPriceForQuantity, m as formatRentalUnitQuantity, u as formatStorefrontPriceMinor, p as getPricingUnitLabel };
|
|
@@ -0,0 +1,418 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
export declare const storefrontItineraryLocalizedStringSchema: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
3
|
+
value: z.ZodString;
|
|
4
|
+
updatedAt: z.ZodCoercedDate<unknown>;
|
|
5
|
+
autoTranslated: z.ZodOptional<z.ZodBoolean>;
|
|
6
|
+
}, z.core.$loose>>;
|
|
7
|
+
export declare const storefrontItineraryDifficultySchema: z.ZodEnum<{
|
|
8
|
+
easy: "easy";
|
|
9
|
+
moderate: "moderate";
|
|
10
|
+
challenging: "challenging";
|
|
11
|
+
}>;
|
|
12
|
+
export declare const storefrontItineraryTripTypeSchema: z.ZodEnum<{
|
|
13
|
+
one_way: "one_way";
|
|
14
|
+
out_and_back: "out_and_back";
|
|
15
|
+
loop: "loop";
|
|
16
|
+
}>;
|
|
17
|
+
export declare const storefrontItineraryMetricsSchema: z.ZodObject<{
|
|
18
|
+
distanceMeters: z.ZodNumber;
|
|
19
|
+
durationSeconds: z.ZodNumber;
|
|
20
|
+
elevationGainMeters: z.ZodNumber;
|
|
21
|
+
elevationLossMeters: z.ZodNumber;
|
|
22
|
+
}, z.core.$strip>;
|
|
23
|
+
export declare const storefrontItineraryBoundsSchema: z.ZodObject<{
|
|
24
|
+
west: z.ZodNumber;
|
|
25
|
+
south: z.ZodNumber;
|
|
26
|
+
east: z.ZodNumber;
|
|
27
|
+
north: z.ZodNumber;
|
|
28
|
+
}, z.core.$strip>;
|
|
29
|
+
export declare const storefrontItineraryCoordinateSchema: z.ZodUnion<readonly [z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>, z.ZodTuple<[z.ZodNumber, z.ZodNumber, z.ZodNumber], null>]>;
|
|
30
|
+
export declare const storefrontItinerarySummarySchema: z.ZodObject<{
|
|
31
|
+
slug: z.ZodString;
|
|
32
|
+
title: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
33
|
+
value: z.ZodString;
|
|
34
|
+
updatedAt: z.ZodCoercedDate<unknown>;
|
|
35
|
+
autoTranslated: z.ZodOptional<z.ZodBoolean>;
|
|
36
|
+
}, z.core.$loose>>;
|
|
37
|
+
introduction: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
38
|
+
value: z.ZodString;
|
|
39
|
+
updatedAt: z.ZodCoercedDate<unknown>;
|
|
40
|
+
autoTranslated: z.ZodOptional<z.ZodBoolean>;
|
|
41
|
+
}, z.core.$loose>>;
|
|
42
|
+
tags: z.ZodArray<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
43
|
+
value: z.ZodString;
|
|
44
|
+
updatedAt: z.ZodCoercedDate<unknown>;
|
|
45
|
+
autoTranslated: z.ZodOptional<z.ZodBoolean>;
|
|
46
|
+
}, z.core.$loose>>>;
|
|
47
|
+
coverImageId: z.ZodNullable<z.ZodString>;
|
|
48
|
+
difficulty: z.ZodEnum<{
|
|
49
|
+
easy: "easy";
|
|
50
|
+
moderate: "moderate";
|
|
51
|
+
challenging: "challenging";
|
|
52
|
+
}>;
|
|
53
|
+
tripType: z.ZodEnum<{
|
|
54
|
+
one_way: "one_way";
|
|
55
|
+
out_and_back: "out_and_back";
|
|
56
|
+
loop: "loop";
|
|
57
|
+
}>;
|
|
58
|
+
metrics: z.ZodObject<{
|
|
59
|
+
distanceMeters: z.ZodNumber;
|
|
60
|
+
durationSeconds: z.ZodNumber;
|
|
61
|
+
elevationGainMeters: z.ZodNumber;
|
|
62
|
+
elevationLossMeters: z.ZodNumber;
|
|
63
|
+
}, z.core.$strip>;
|
|
64
|
+
}, z.core.$strip>;
|
|
65
|
+
export declare const storefrontItineraryStepSchema: z.ZodObject<{
|
|
66
|
+
id: z.ZodString;
|
|
67
|
+
label: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
68
|
+
value: z.ZodString;
|
|
69
|
+
updatedAt: z.ZodCoercedDate<unknown>;
|
|
70
|
+
autoTranslated: z.ZodOptional<z.ZodBoolean>;
|
|
71
|
+
}, z.core.$loose>>;
|
|
72
|
+
description: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
73
|
+
value: z.ZodString;
|
|
74
|
+
updatedAt: z.ZodCoercedDate<unknown>;
|
|
75
|
+
autoTranslated: z.ZodOptional<z.ZodBoolean>;
|
|
76
|
+
}, z.core.$loose>>;
|
|
77
|
+
category: z.ZodOptional<z.ZodString>;
|
|
78
|
+
role: z.ZodEnum<{
|
|
79
|
+
shaping: "shaping";
|
|
80
|
+
stop: "stop";
|
|
81
|
+
detached: "detached";
|
|
82
|
+
}>;
|
|
83
|
+
point: z.ZodObject<{
|
|
84
|
+
lng: z.ZodNumber;
|
|
85
|
+
lat: z.ZodNumber;
|
|
86
|
+
ele: z.ZodOptional<z.ZodNumber>;
|
|
87
|
+
}, z.core.$strip>;
|
|
88
|
+
imageIds: z.ZodArray<z.ZodString>;
|
|
89
|
+
}, z.core.$strip>;
|
|
90
|
+
export declare const storefrontItineraryPreviewSchema: z.ZodObject<{
|
|
91
|
+
slug: z.ZodString;
|
|
92
|
+
title: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
93
|
+
value: z.ZodString;
|
|
94
|
+
updatedAt: z.ZodCoercedDate<unknown>;
|
|
95
|
+
autoTranslated: z.ZodOptional<z.ZodBoolean>;
|
|
96
|
+
}, z.core.$loose>>;
|
|
97
|
+
introduction: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
98
|
+
value: z.ZodString;
|
|
99
|
+
updatedAt: z.ZodCoercedDate<unknown>;
|
|
100
|
+
autoTranslated: z.ZodOptional<z.ZodBoolean>;
|
|
101
|
+
}, z.core.$loose>>;
|
|
102
|
+
tags: z.ZodArray<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
103
|
+
value: z.ZodString;
|
|
104
|
+
updatedAt: z.ZodCoercedDate<unknown>;
|
|
105
|
+
autoTranslated: z.ZodOptional<z.ZodBoolean>;
|
|
106
|
+
}, z.core.$loose>>>;
|
|
107
|
+
coverImageId: z.ZodNullable<z.ZodString>;
|
|
108
|
+
difficulty: z.ZodEnum<{
|
|
109
|
+
easy: "easy";
|
|
110
|
+
moderate: "moderate";
|
|
111
|
+
challenging: "challenging";
|
|
112
|
+
}>;
|
|
113
|
+
tripType: z.ZodEnum<{
|
|
114
|
+
one_way: "one_way";
|
|
115
|
+
out_and_back: "out_and_back";
|
|
116
|
+
loop: "loop";
|
|
117
|
+
}>;
|
|
118
|
+
metrics: z.ZodObject<{
|
|
119
|
+
distanceMeters: z.ZodNumber;
|
|
120
|
+
durationSeconds: z.ZodNumber;
|
|
121
|
+
elevationGainMeters: z.ZodNumber;
|
|
122
|
+
elevationLossMeters: z.ZodNumber;
|
|
123
|
+
}, z.core.$strip>;
|
|
124
|
+
previewCoordinates: z.ZodArray<z.ZodUnion<readonly [z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>, z.ZodTuple<[z.ZodNumber, z.ZodNumber, z.ZodNumber], null>]>>;
|
|
125
|
+
steps: z.ZodArray<z.ZodObject<{
|
|
126
|
+
id: z.ZodString;
|
|
127
|
+
label: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
128
|
+
value: z.ZodString;
|
|
129
|
+
updatedAt: z.ZodCoercedDate<unknown>;
|
|
130
|
+
autoTranslated: z.ZodOptional<z.ZodBoolean>;
|
|
131
|
+
}, z.core.$loose>>;
|
|
132
|
+
description: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
133
|
+
value: z.ZodString;
|
|
134
|
+
updatedAt: z.ZodCoercedDate<unknown>;
|
|
135
|
+
autoTranslated: z.ZodOptional<z.ZodBoolean>;
|
|
136
|
+
}, z.core.$loose>>;
|
|
137
|
+
category: z.ZodOptional<z.ZodString>;
|
|
138
|
+
role: z.ZodEnum<{
|
|
139
|
+
shaping: "shaping";
|
|
140
|
+
stop: "stop";
|
|
141
|
+
detached: "detached";
|
|
142
|
+
}>;
|
|
143
|
+
point: z.ZodObject<{
|
|
144
|
+
lng: z.ZodNumber;
|
|
145
|
+
lat: z.ZodNumber;
|
|
146
|
+
ele: z.ZodOptional<z.ZodNumber>;
|
|
147
|
+
}, z.core.$strip>;
|
|
148
|
+
imageIds: z.ZodArray<z.ZodString>;
|
|
149
|
+
}, z.core.$strip>>;
|
|
150
|
+
}, z.core.$strip>;
|
|
151
|
+
export declare const storefrontItineraryDetailSchema: z.ZodObject<{
|
|
152
|
+
slug: z.ZodString;
|
|
153
|
+
title: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
154
|
+
value: z.ZodString;
|
|
155
|
+
updatedAt: z.ZodCoercedDate<unknown>;
|
|
156
|
+
autoTranslated: z.ZodOptional<z.ZodBoolean>;
|
|
157
|
+
}, z.core.$loose>>;
|
|
158
|
+
introduction: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
159
|
+
value: z.ZodString;
|
|
160
|
+
updatedAt: z.ZodCoercedDate<unknown>;
|
|
161
|
+
autoTranslated: z.ZodOptional<z.ZodBoolean>;
|
|
162
|
+
}, z.core.$loose>>;
|
|
163
|
+
tags: z.ZodArray<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
164
|
+
value: z.ZodString;
|
|
165
|
+
updatedAt: z.ZodCoercedDate<unknown>;
|
|
166
|
+
autoTranslated: z.ZodOptional<z.ZodBoolean>;
|
|
167
|
+
}, z.core.$loose>>>;
|
|
168
|
+
coverImageId: z.ZodNullable<z.ZodString>;
|
|
169
|
+
difficulty: z.ZodEnum<{
|
|
170
|
+
easy: "easy";
|
|
171
|
+
moderate: "moderate";
|
|
172
|
+
challenging: "challenging";
|
|
173
|
+
}>;
|
|
174
|
+
tripType: z.ZodEnum<{
|
|
175
|
+
one_way: "one_way";
|
|
176
|
+
out_and_back: "out_and_back";
|
|
177
|
+
loop: "loop";
|
|
178
|
+
}>;
|
|
179
|
+
metrics: z.ZodObject<{
|
|
180
|
+
distanceMeters: z.ZodNumber;
|
|
181
|
+
durationSeconds: z.ZodNumber;
|
|
182
|
+
elevationGainMeters: z.ZodNumber;
|
|
183
|
+
elevationLossMeters: z.ZodNumber;
|
|
184
|
+
}, z.core.$strip>;
|
|
185
|
+
geometry: z.ZodObject<{
|
|
186
|
+
type: z.ZodLiteral<"LineString">;
|
|
187
|
+
coordinates: z.ZodArray<z.ZodUnion<readonly [z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>, z.ZodTuple<[z.ZodNumber, z.ZodNumber, z.ZodNumber], null>]>>;
|
|
188
|
+
}, z.core.$strip>;
|
|
189
|
+
bounds: z.ZodNullable<z.ZodObject<{
|
|
190
|
+
west: z.ZodNumber;
|
|
191
|
+
south: z.ZodNumber;
|
|
192
|
+
east: z.ZodNumber;
|
|
193
|
+
north: z.ZodNumber;
|
|
194
|
+
}, z.core.$strip>>;
|
|
195
|
+
steps: z.ZodArray<z.ZodObject<{
|
|
196
|
+
id: z.ZodString;
|
|
197
|
+
label: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
198
|
+
value: z.ZodString;
|
|
199
|
+
updatedAt: z.ZodCoercedDate<unknown>;
|
|
200
|
+
autoTranslated: z.ZodOptional<z.ZodBoolean>;
|
|
201
|
+
}, z.core.$loose>>;
|
|
202
|
+
description: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
203
|
+
value: z.ZodString;
|
|
204
|
+
updatedAt: z.ZodCoercedDate<unknown>;
|
|
205
|
+
autoTranslated: z.ZodOptional<z.ZodBoolean>;
|
|
206
|
+
}, z.core.$loose>>;
|
|
207
|
+
category: z.ZodOptional<z.ZodString>;
|
|
208
|
+
role: z.ZodEnum<{
|
|
209
|
+
shaping: "shaping";
|
|
210
|
+
stop: "stop";
|
|
211
|
+
detached: "detached";
|
|
212
|
+
}>;
|
|
213
|
+
point: z.ZodObject<{
|
|
214
|
+
lng: z.ZodNumber;
|
|
215
|
+
lat: z.ZodNumber;
|
|
216
|
+
ele: z.ZodOptional<z.ZodNumber>;
|
|
217
|
+
}, z.core.$strip>;
|
|
218
|
+
imageIds: z.ZodArray<z.ZodString>;
|
|
219
|
+
}, z.core.$strip>>;
|
|
220
|
+
}, z.core.$strip>;
|
|
221
|
+
export declare const STOREFRONT_ITINERARIES_LIST_ROUTE = "/api/public/storefront/itineraries/list";
|
|
222
|
+
export declare const STOREFRONT_ITINERARIES_FEATURED_ROUTE = "/api/public/storefront/itineraries/featured";
|
|
223
|
+
export declare const STOREFRONT_ITINERARY_DETAIL_ROUTE = "/api/public/storefront/itineraries/get";
|
|
224
|
+
export declare const storefrontItinerariesListRequestSchema: z.ZodObject<{
|
|
225
|
+
storeSlug: z.ZodString;
|
|
226
|
+
}, z.core.$strip>;
|
|
227
|
+
export declare const storefrontItinerariesFeaturedRequestSchema: z.ZodObject<{
|
|
228
|
+
storeSlug: z.ZodString;
|
|
229
|
+
}, z.core.$strip>;
|
|
230
|
+
export declare const storefrontItineraryDetailRequestSchema: z.ZodObject<{
|
|
231
|
+
storeSlug: z.ZodString;
|
|
232
|
+
itinerarySlug: z.ZodString;
|
|
233
|
+
}, z.core.$strip>;
|
|
234
|
+
export declare const storefrontItinerariesListResponseSchema: z.ZodObject<{
|
|
235
|
+
success: z.ZodBoolean;
|
|
236
|
+
message: z.ZodOptional<z.ZodString>;
|
|
237
|
+
itineraries: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
238
|
+
slug: z.ZodString;
|
|
239
|
+
title: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
240
|
+
value: z.ZodString;
|
|
241
|
+
updatedAt: z.ZodCoercedDate<unknown>;
|
|
242
|
+
autoTranslated: z.ZodOptional<z.ZodBoolean>;
|
|
243
|
+
}, z.core.$loose>>;
|
|
244
|
+
introduction: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
245
|
+
value: z.ZodString;
|
|
246
|
+
updatedAt: z.ZodCoercedDate<unknown>;
|
|
247
|
+
autoTranslated: z.ZodOptional<z.ZodBoolean>;
|
|
248
|
+
}, z.core.$loose>>;
|
|
249
|
+
tags: z.ZodArray<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
250
|
+
value: z.ZodString;
|
|
251
|
+
updatedAt: z.ZodCoercedDate<unknown>;
|
|
252
|
+
autoTranslated: z.ZodOptional<z.ZodBoolean>;
|
|
253
|
+
}, z.core.$loose>>>;
|
|
254
|
+
coverImageId: z.ZodNullable<z.ZodString>;
|
|
255
|
+
difficulty: z.ZodEnum<{
|
|
256
|
+
easy: "easy";
|
|
257
|
+
moderate: "moderate";
|
|
258
|
+
challenging: "challenging";
|
|
259
|
+
}>;
|
|
260
|
+
tripType: z.ZodEnum<{
|
|
261
|
+
one_way: "one_way";
|
|
262
|
+
out_and_back: "out_and_back";
|
|
263
|
+
loop: "loop";
|
|
264
|
+
}>;
|
|
265
|
+
metrics: z.ZodObject<{
|
|
266
|
+
distanceMeters: z.ZodNumber;
|
|
267
|
+
durationSeconds: z.ZodNumber;
|
|
268
|
+
elevationGainMeters: z.ZodNumber;
|
|
269
|
+
elevationLossMeters: z.ZodNumber;
|
|
270
|
+
}, z.core.$strip>;
|
|
271
|
+
}, z.core.$strip>>>;
|
|
272
|
+
}, z.core.$strip>;
|
|
273
|
+
export declare const storefrontItinerariesFeaturedResponseSchema: z.ZodObject<{
|
|
274
|
+
success: z.ZodBoolean;
|
|
275
|
+
message: z.ZodOptional<z.ZodString>;
|
|
276
|
+
itineraries: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
277
|
+
slug: z.ZodString;
|
|
278
|
+
title: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
279
|
+
value: z.ZodString;
|
|
280
|
+
updatedAt: z.ZodCoercedDate<unknown>;
|
|
281
|
+
autoTranslated: z.ZodOptional<z.ZodBoolean>;
|
|
282
|
+
}, z.core.$loose>>;
|
|
283
|
+
introduction: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
284
|
+
value: z.ZodString;
|
|
285
|
+
updatedAt: z.ZodCoercedDate<unknown>;
|
|
286
|
+
autoTranslated: z.ZodOptional<z.ZodBoolean>;
|
|
287
|
+
}, z.core.$loose>>;
|
|
288
|
+
tags: z.ZodArray<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
289
|
+
value: z.ZodString;
|
|
290
|
+
updatedAt: z.ZodCoercedDate<unknown>;
|
|
291
|
+
autoTranslated: z.ZodOptional<z.ZodBoolean>;
|
|
292
|
+
}, z.core.$loose>>>;
|
|
293
|
+
coverImageId: z.ZodNullable<z.ZodString>;
|
|
294
|
+
difficulty: z.ZodEnum<{
|
|
295
|
+
easy: "easy";
|
|
296
|
+
moderate: "moderate";
|
|
297
|
+
challenging: "challenging";
|
|
298
|
+
}>;
|
|
299
|
+
tripType: z.ZodEnum<{
|
|
300
|
+
one_way: "one_way";
|
|
301
|
+
out_and_back: "out_and_back";
|
|
302
|
+
loop: "loop";
|
|
303
|
+
}>;
|
|
304
|
+
metrics: z.ZodObject<{
|
|
305
|
+
distanceMeters: z.ZodNumber;
|
|
306
|
+
durationSeconds: z.ZodNumber;
|
|
307
|
+
elevationGainMeters: z.ZodNumber;
|
|
308
|
+
elevationLossMeters: z.ZodNumber;
|
|
309
|
+
}, z.core.$strip>;
|
|
310
|
+
previewCoordinates: z.ZodArray<z.ZodUnion<readonly [z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>, z.ZodTuple<[z.ZodNumber, z.ZodNumber, z.ZodNumber], null>]>>;
|
|
311
|
+
steps: z.ZodArray<z.ZodObject<{
|
|
312
|
+
id: z.ZodString;
|
|
313
|
+
label: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
314
|
+
value: z.ZodString;
|
|
315
|
+
updatedAt: z.ZodCoercedDate<unknown>;
|
|
316
|
+
autoTranslated: z.ZodOptional<z.ZodBoolean>;
|
|
317
|
+
}, z.core.$loose>>;
|
|
318
|
+
description: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
319
|
+
value: z.ZodString;
|
|
320
|
+
updatedAt: z.ZodCoercedDate<unknown>;
|
|
321
|
+
autoTranslated: z.ZodOptional<z.ZodBoolean>;
|
|
322
|
+
}, z.core.$loose>>;
|
|
323
|
+
category: z.ZodOptional<z.ZodString>;
|
|
324
|
+
role: z.ZodEnum<{
|
|
325
|
+
shaping: "shaping";
|
|
326
|
+
stop: "stop";
|
|
327
|
+
detached: "detached";
|
|
328
|
+
}>;
|
|
329
|
+
point: z.ZodObject<{
|
|
330
|
+
lng: z.ZodNumber;
|
|
331
|
+
lat: z.ZodNumber;
|
|
332
|
+
ele: z.ZodOptional<z.ZodNumber>;
|
|
333
|
+
}, z.core.$strip>;
|
|
334
|
+
imageIds: z.ZodArray<z.ZodString>;
|
|
335
|
+
}, z.core.$strip>>;
|
|
336
|
+
}, z.core.$strip>>>;
|
|
337
|
+
}, z.core.$strip>;
|
|
338
|
+
export declare const storefrontItineraryDetailResponseSchema: z.ZodObject<{
|
|
339
|
+
success: z.ZodBoolean;
|
|
340
|
+
message: z.ZodOptional<z.ZodString>;
|
|
341
|
+
itinerary: z.ZodOptional<z.ZodObject<{
|
|
342
|
+
slug: z.ZodString;
|
|
343
|
+
title: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
344
|
+
value: z.ZodString;
|
|
345
|
+
updatedAt: z.ZodCoercedDate<unknown>;
|
|
346
|
+
autoTranslated: z.ZodOptional<z.ZodBoolean>;
|
|
347
|
+
}, z.core.$loose>>;
|
|
348
|
+
introduction: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
349
|
+
value: z.ZodString;
|
|
350
|
+
updatedAt: z.ZodCoercedDate<unknown>;
|
|
351
|
+
autoTranslated: z.ZodOptional<z.ZodBoolean>;
|
|
352
|
+
}, z.core.$loose>>;
|
|
353
|
+
tags: z.ZodArray<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
354
|
+
value: z.ZodString;
|
|
355
|
+
updatedAt: z.ZodCoercedDate<unknown>;
|
|
356
|
+
autoTranslated: z.ZodOptional<z.ZodBoolean>;
|
|
357
|
+
}, z.core.$loose>>>;
|
|
358
|
+
coverImageId: z.ZodNullable<z.ZodString>;
|
|
359
|
+
difficulty: z.ZodEnum<{
|
|
360
|
+
easy: "easy";
|
|
361
|
+
moderate: "moderate";
|
|
362
|
+
challenging: "challenging";
|
|
363
|
+
}>;
|
|
364
|
+
tripType: z.ZodEnum<{
|
|
365
|
+
one_way: "one_way";
|
|
366
|
+
out_and_back: "out_and_back";
|
|
367
|
+
loop: "loop";
|
|
368
|
+
}>;
|
|
369
|
+
metrics: z.ZodObject<{
|
|
370
|
+
distanceMeters: z.ZodNumber;
|
|
371
|
+
durationSeconds: z.ZodNumber;
|
|
372
|
+
elevationGainMeters: z.ZodNumber;
|
|
373
|
+
elevationLossMeters: z.ZodNumber;
|
|
374
|
+
}, z.core.$strip>;
|
|
375
|
+
geometry: z.ZodObject<{
|
|
376
|
+
type: z.ZodLiteral<"LineString">;
|
|
377
|
+
coordinates: z.ZodArray<z.ZodUnion<readonly [z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>, z.ZodTuple<[z.ZodNumber, z.ZodNumber, z.ZodNumber], null>]>>;
|
|
378
|
+
}, z.core.$strip>;
|
|
379
|
+
bounds: z.ZodNullable<z.ZodObject<{
|
|
380
|
+
west: z.ZodNumber;
|
|
381
|
+
south: z.ZodNumber;
|
|
382
|
+
east: z.ZodNumber;
|
|
383
|
+
north: z.ZodNumber;
|
|
384
|
+
}, z.core.$strip>>;
|
|
385
|
+
steps: z.ZodArray<z.ZodObject<{
|
|
386
|
+
id: z.ZodString;
|
|
387
|
+
label: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
388
|
+
value: z.ZodString;
|
|
389
|
+
updatedAt: z.ZodCoercedDate<unknown>;
|
|
390
|
+
autoTranslated: z.ZodOptional<z.ZodBoolean>;
|
|
391
|
+
}, z.core.$loose>>;
|
|
392
|
+
description: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
393
|
+
value: z.ZodString;
|
|
394
|
+
updatedAt: z.ZodCoercedDate<unknown>;
|
|
395
|
+
autoTranslated: z.ZodOptional<z.ZodBoolean>;
|
|
396
|
+
}, z.core.$loose>>;
|
|
397
|
+
category: z.ZodOptional<z.ZodString>;
|
|
398
|
+
role: z.ZodEnum<{
|
|
399
|
+
shaping: "shaping";
|
|
400
|
+
stop: "stop";
|
|
401
|
+
detached: "detached";
|
|
402
|
+
}>;
|
|
403
|
+
point: z.ZodObject<{
|
|
404
|
+
lng: z.ZodNumber;
|
|
405
|
+
lat: z.ZodNumber;
|
|
406
|
+
ele: z.ZodOptional<z.ZodNumber>;
|
|
407
|
+
}, z.core.$strip>;
|
|
408
|
+
imageIds: z.ZodArray<z.ZodString>;
|
|
409
|
+
}, z.core.$strip>>;
|
|
410
|
+
}, z.core.$strip>>;
|
|
411
|
+
}, z.core.$strip>;
|
|
412
|
+
export type StorefrontItineraryLocalizedString = z.infer<typeof storefrontItineraryLocalizedStringSchema>;
|
|
413
|
+
export type StorefrontItineraryCoordinate = z.infer<typeof storefrontItineraryCoordinateSchema>;
|
|
414
|
+
export type StorefrontItinerarySummary = z.infer<typeof storefrontItinerarySummarySchema>;
|
|
415
|
+
export type StorefrontItineraryPreview = z.infer<typeof storefrontItineraryPreviewSchema>;
|
|
416
|
+
export type StorefrontItineraryDetail = z.infer<typeof storefrontItineraryDetailSchema>;
|
|
417
|
+
export type StorefrontItineraryStep = z.infer<typeof storefrontItineraryStepSchema>;
|
|
418
|
+
//# sourceMappingURL=storefrontItineraries.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"storefrontItineraries.d.ts","sourceRoot":"","sources":["../../src/lib/storefrontItineraries.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAYvB,eAAO,MAAM,wCAAwC;;;;kBAAoD,CAAA;AACzG,eAAO,MAAM,mCAAmC;;;;EAA8C,CAAA;AAC9F,eAAO,MAAM,iCAAiC;;;;EAA8C,CAAA;AAE5F,eAAO,MAAM,gCAAgC;;;;;iBAK3C,CAAA;AAEF,eAAO,MAAM,+BAA+B;;;;;iBAK1C,CAAA;AAEF,eAAO,MAAM,mCAAmC,gIAG9C,CAAA;AAEF,eAAO,MAAM,gCAAgC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAS3C,CAAA;AAEF,eAAO,MAAM,6BAA6B;;;;;;;;;;;;;;;;;;;;;;;;iBAYxC,CAAA;AAEF,eAAO,MAAM,gCAAgC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAG3C,CAAA;AAEF,eAAO,MAAM,+BAA+B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAO1C,CAAA;AAEF,eAAO,MAAM,iCAAiC,4CAA4C,CAAA;AAC1F,eAAO,MAAM,qCAAqC,gDAAgD,CAAA;AAClG,eAAO,MAAM,iCAAiC,2CAA2C,CAAA;AAEzF,eAAO,MAAM,sCAAsC;;iBAA2C,CAAA;AAC9F,eAAO,MAAM,0CAA0C;;iBAA2C,CAAA;AAClG,eAAO,MAAM,sCAAsC;;;iBAGjD,CAAA;AAEF,eAAO,MAAM,uCAAuC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAIlD,CAAA;AACF,eAAO,MAAM,2CAA2C;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAItD,CAAA;AACF,eAAO,MAAM,uCAAuC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAIlD,CAAA;AAEF,MAAM,MAAM,kCAAkC,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,wCAAwC,CAAC,CAAA;AACzG,MAAM,MAAM,6BAA6B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mCAAmC,CAAC,CAAA;AAC/F,MAAM,MAAM,0BAA0B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gCAAgC,CAAC,CAAA;AACzF,MAAM,MAAM,0BAA0B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gCAAgC,CAAC,CAAA;AACzF,MAAM,MAAM,yBAAyB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,+BAA+B,CAAC,CAAA;AACvF,MAAM,MAAM,uBAAuB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,6BAA6B,CAAC,CAAA"}
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
import { z as e } from "zod";
|
|
2
|
+
//#region src/lib/storefrontItineraries.ts
|
|
3
|
+
var t = e.string().trim().regex(/^[a-f0-9]{24}$/i), n = e.string().trim().min(1).toLowerCase(), r = e.string().trim().min(1).max(160).regex(/^[a-z0-9]+(?:-[a-z0-9]+)*$/).toLowerCase(), i = e.object({
|
|
4
|
+
value: e.string(),
|
|
5
|
+
updatedAt: e.coerce.date(),
|
|
6
|
+
autoTranslated: e.boolean().optional()
|
|
7
|
+
}).passthrough(), a = e.record(e.string().min(2), i), o = e.enum([
|
|
8
|
+
"easy",
|
|
9
|
+
"moderate",
|
|
10
|
+
"challenging"
|
|
11
|
+
]), s = e.enum([
|
|
12
|
+
"one_way",
|
|
13
|
+
"out_and_back",
|
|
14
|
+
"loop"
|
|
15
|
+
]), c = e.object({
|
|
16
|
+
distanceMeters: e.number().finite().min(0),
|
|
17
|
+
durationSeconds: e.number().finite().min(0),
|
|
18
|
+
elevationGainMeters: e.number().finite().min(0),
|
|
19
|
+
elevationLossMeters: e.number().finite().min(0)
|
|
20
|
+
}), l = e.object({
|
|
21
|
+
west: e.number().finite().min(-180).max(180),
|
|
22
|
+
south: e.number().finite().min(-90).max(90),
|
|
23
|
+
east: e.number().finite().min(-180).max(180),
|
|
24
|
+
north: e.number().finite().min(-90).max(90)
|
|
25
|
+
}), u = e.union([e.tuple([e.number().finite(), e.number().finite()]), e.tuple([
|
|
26
|
+
e.number().finite(),
|
|
27
|
+
e.number().finite(),
|
|
28
|
+
e.number().finite()
|
|
29
|
+
])]), d = e.object({
|
|
30
|
+
slug: r,
|
|
31
|
+
title: a,
|
|
32
|
+
introduction: a,
|
|
33
|
+
tags: e.array(a),
|
|
34
|
+
coverImageId: t.nullable(),
|
|
35
|
+
difficulty: o,
|
|
36
|
+
tripType: s,
|
|
37
|
+
metrics: c
|
|
38
|
+
}), f = e.object({
|
|
39
|
+
id: e.string().min(1),
|
|
40
|
+
label: a,
|
|
41
|
+
description: a,
|
|
42
|
+
category: e.string().optional(),
|
|
43
|
+
role: e.enum([
|
|
44
|
+
"shaping",
|
|
45
|
+
"stop",
|
|
46
|
+
"detached"
|
|
47
|
+
]),
|
|
48
|
+
point: e.object({
|
|
49
|
+
lng: e.number().finite(),
|
|
50
|
+
lat: e.number().finite(),
|
|
51
|
+
ele: e.number().finite().optional()
|
|
52
|
+
}),
|
|
53
|
+
imageIds: e.array(t)
|
|
54
|
+
}), p = d.extend({
|
|
55
|
+
previewCoordinates: e.array(u).min(2),
|
|
56
|
+
steps: e.array(f)
|
|
57
|
+
}), m = d.extend({
|
|
58
|
+
geometry: e.object({
|
|
59
|
+
type: e.literal("LineString"),
|
|
60
|
+
coordinates: e.array(u)
|
|
61
|
+
}),
|
|
62
|
+
bounds: l.nullable(),
|
|
63
|
+
steps: e.array(f)
|
|
64
|
+
}), h = "/api/public/storefront/itineraries/list", g = "/api/public/storefront/itineraries/featured", _ = "/api/public/storefront/itineraries/get", v = e.object({ storeSlug: n }), y = e.object({ storeSlug: n }), b = e.object({
|
|
65
|
+
storeSlug: n,
|
|
66
|
+
itinerarySlug: r
|
|
67
|
+
}), x = e.object({
|
|
68
|
+
success: e.boolean(),
|
|
69
|
+
message: e.string().optional(),
|
|
70
|
+
itineraries: e.array(d).default([])
|
|
71
|
+
}), S = e.object({
|
|
72
|
+
success: e.boolean(),
|
|
73
|
+
message: e.string().optional(),
|
|
74
|
+
itineraries: e.array(p).max(4).default([])
|
|
75
|
+
}), C = e.object({
|
|
76
|
+
success: e.boolean(),
|
|
77
|
+
message: e.string().optional(),
|
|
78
|
+
itinerary: m.optional()
|
|
79
|
+
});
|
|
80
|
+
//#endregion
|
|
81
|
+
export { g as STOREFRONT_ITINERARIES_FEATURED_ROUTE, h as STOREFRONT_ITINERARIES_LIST_ROUTE, _ as STOREFRONT_ITINERARY_DETAIL_ROUTE, y as storefrontItinerariesFeaturedRequestSchema, S as storefrontItinerariesFeaturedResponseSchema, v as storefrontItinerariesListRequestSchema, x as storefrontItinerariesListResponseSchema, l as storefrontItineraryBoundsSchema, u as storefrontItineraryCoordinateSchema, b as storefrontItineraryDetailRequestSchema, C as storefrontItineraryDetailResponseSchema, m as storefrontItineraryDetailSchema, o as storefrontItineraryDifficultySchema, a as storefrontItineraryLocalizedStringSchema, c as storefrontItineraryMetricsSchema, p as storefrontItineraryPreviewSchema, f as storefrontItineraryStepSchema, d as storefrontItinerarySummarySchema, s as storefrontItineraryTripTypeSchema };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BookingPage.d.ts","sourceRoot":"","sources":["../../src/pages/BookingPage.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"BookingPage.d.ts","sourceRoot":"","sources":["../../src/pages/BookingPage.tsx"],"names":[],"mappings":"AAuMA,MAAM,CAAC,OAAO,UAAU,WAAW,4CA2nBlC"}
|