@getmicdrop/venue-calendar 4.3.36 → 4.3.38
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/{CalendarFoundryView-BytAeaqk.js → CalendarFoundryView-BWaOYwqK.js} +2364 -2142
- package/dist/{CartView-BVAj8ns8.js → CartView-YRimdA6F.js} +16 -16
- package/dist/{Checkout-Cw_mvXUd.js → Checkout-djS62Y9-.js} +10 -10
- package/dist/{Checkout-DFoOLl6K.js → Checkout-rsX9zvb7.js} +6 -6
- package/dist/{CheckoutTimer-BDxy_Fou.js → CheckoutTimer-D3XNCZ36.js} +1 -1
- package/dist/{CollectionView-BRJKmgmu.js → CollectionView-DJMd-lQ5.js} +3 -3
- package/dist/{Event-CJZetg3I.js → Event-ETzQP0s-.js} +5 -5
- package/dist/EventPage-BDmpGhgp.js +1184 -0
- package/dist/{RecommendationsRail-DcIHxWHf.js → RecommendationsRail-CKoChbYt.js} +3 -3
- package/dist/{SeriesPage-ByxpytgT.js → SeriesPage-DccLByjM.js} +2 -2
- package/dist/{Success-CFbOlDG7.js → Success-BVYGRvb8.js} +18 -18
- package/dist/{ViewTicketsEmbed-KbA05I2k.js → ViewTicketsEmbed-D6ZLDsJe.js} +3 -3
- package/dist/api/api.cjs +1 -1
- package/dist/api/api.mjs +250 -255
- package/dist/{api-DRQ3j7AT.js → api-LOBSDFGW.js} +118 -119
- package/dist/{constants-YYsgll7v.js → constants-COyf9Cef.js} +1 -1
- package/dist/{defaults-BMbXcKP9.js → defaults-BS-A8oEj.js} +1 -1
- package/dist/{event-transform-BchpSia3.js → event-transform-BR82y7EY.js} +1 -1
- package/dist/{eventStatusStream-dDHNTEOf.js → eventStatusStream-1YtkEBw8.js} +1 -1
- package/dist/{i18n-1R1ah9KT.js → i18n-02Y9QRm0.js} +171 -171
- package/dist/{i18n-i-1mHdch.js → i18n-Dwg2jCJS.js} +1 -1
- package/dist/{orders-jQz7QFjK.js → orders-_DuPjm-g.js} +166 -165
- package/dist/{pixels-DnbRn43e.js → pixels-BXobnFyk.js} +7 -7
- package/dist/{utils-DvGzK5Cl.js → utils-DlMAhsnl.js} +53 -53
- package/dist/venue-calendar.es.js +57 -57
- package/dist/venue-calendar.iife.js +55 -55
- package/dist/venue-calendar.umd.js +25 -25
- package/package.json +2 -2
- package/dist/EventPage-Bt5872Cp.js +0 -1184
- /package/dist/locales/{4.3.36 → 4.3.38}/flow/de.js +0 -0
- /package/dist/locales/{4.3.36 → 4.3.38}/flow/es.js +0 -0
- /package/dist/locales/{4.3.36 → 4.3.38}/flow/fr.js +0 -0
- /package/dist/locales/{4.3.36 → 4.3.38}/flow/id.js +0 -0
- /package/dist/locales/{4.3.36 → 4.3.38}/flow/it.js +0 -0
- /package/dist/locales/{4.3.36 → 4.3.38}/flow/ja.js +0 -0
- /package/dist/locales/{4.3.36 → 4.3.38}/flow/ko.js +0 -0
- /package/dist/locales/{4.3.36 → 4.3.38}/flow/nl.js +0 -0
- /package/dist/locales/{4.3.36 → 4.3.38}/flow/pl.js +0 -0
- /package/dist/locales/{4.3.36 → 4.3.38}/flow/pt-br.js +0 -0
- /package/dist/locales/{4.3.36 → 4.3.38}/flow/tr.js +0 -0
- /package/dist/locales/{4.3.36 → 4.3.38}/flow/zh.js +0 -0
- /package/dist/locales/{4.3.36 → 4.3.38}/main/de.js +0 -0
- /package/dist/locales/{4.3.36 → 4.3.38}/main/es.js +0 -0
- /package/dist/locales/{4.3.36 → 4.3.38}/main/fr.js +0 -0
- /package/dist/locales/{4.3.36 → 4.3.38}/main/id.js +0 -0
- /package/dist/locales/{4.3.36 → 4.3.38}/main/it.js +0 -0
- /package/dist/locales/{4.3.36 → 4.3.38}/main/ja.js +0 -0
- /package/dist/locales/{4.3.36 → 4.3.38}/main/ko.js +0 -0
- /package/dist/locales/{4.3.36 → 4.3.38}/main/nl.js +0 -0
- /package/dist/locales/{4.3.36 → 4.3.38}/main/pl.js +0 -0
- /package/dist/locales/{4.3.36 → 4.3.38}/main/pt-br.js +0 -0
- /package/dist/locales/{4.3.36 → 4.3.38}/main/tr.js +0 -0
- /package/dist/locales/{4.3.36 → 4.3.38}/main/zh.js +0 -0
|
@@ -1,39 +1,39 @@
|
|
|
1
1
|
import { E as e } from "./Button-klwKgfhG.js";
|
|
2
2
|
import { w as t } from "./scarcity-CwnIxi1J.js";
|
|
3
3
|
import { A as n, M as r, O as i, _ as a, c as o, g as s, l as c, v as l, x as u, z as d } from "./defaultLabels-Zp9QbN37.js";
|
|
4
|
-
import {
|
|
4
|
+
import { B as f, L as p, M as ee, N as m, P as h, R as g, U as _, b as te, c as ne } from "./orders-_DuPjm-g.js";
|
|
5
5
|
//#region node_modules/@getmicdrop/svelte-components/dist/transforms/ticket.js
|
|
6
|
-
var
|
|
6
|
+
var v = {
|
|
7
7
|
EVERYWHERE: 0,
|
|
8
8
|
ONLINE_ONLY: 1,
|
|
9
9
|
BOX_OFFICE_ONLY: 2
|
|
10
|
-
},
|
|
10
|
+
}, y = {
|
|
11
11
|
VISIBLE: 0,
|
|
12
12
|
HIDDEN: 1,
|
|
13
13
|
PROMO_ONLY: 2
|
|
14
14
|
};
|
|
15
|
-
function
|
|
15
|
+
function b(e) {
|
|
16
16
|
return e.soldOut === !0 ? 0 : e.remainingCapacity == null ? e.quantityRemaining == null ? e.quantity == null ? e.sold != null && e.totalCapacity != null ? Math.max(0, e.totalCapacity - e.sold) : 0 : e.quantity : e.quantityRemaining : e.remainingCapacity;
|
|
17
17
|
}
|
|
18
|
-
function
|
|
18
|
+
function x(e, t) {
|
|
19
19
|
return e.totalCapacity ?? e.quantity ?? t;
|
|
20
20
|
}
|
|
21
|
-
function
|
|
21
|
+
function S(e) {
|
|
22
22
|
let t = n(), r = a(e.effectiveSalesBegin, e.salesBegin, e.saleStartDate) ?? null, i = a(e.effectiveSalesEnd, e.salesEnd, e.saleEndDate) ?? null, o = u(r), c = u(i);
|
|
23
23
|
if (!l(r) && !o) return "scheduled";
|
|
24
24
|
if (!l(i) && !c) return "sales_ended";
|
|
25
25
|
if (o && s(t, o) < 0) return "scheduled";
|
|
26
26
|
if (c && s(t, c) > 0) return "sales_ended";
|
|
27
27
|
if (e.soldOut === !0) return "sold_out";
|
|
28
|
-
let d =
|
|
28
|
+
let d = b(e), f = x(e, d);
|
|
29
29
|
return d === 0 ? "sold_out" : f > 0 && d / f < .1 ? "low" : "on_sale";
|
|
30
30
|
}
|
|
31
|
-
function
|
|
31
|
+
function C(e, t = {}) {
|
|
32
32
|
if (!Array.isArray(e)) return [];
|
|
33
33
|
let n = e;
|
|
34
|
-
return t.excludeDoorOnly && (n = n.filter((e) => e.salesChannel !==
|
|
34
|
+
return t.excludeDoorOnly && (n = n.filter((e) => e.salesChannel !== v.BOX_OFFICE_ONLY)), t.publicOnly && (n = n.filter((e) => e.visibility === y.VISIBLE)), n;
|
|
35
35
|
}
|
|
36
|
-
function
|
|
36
|
+
function w(e) {
|
|
37
37
|
if (!Array.isArray(e) || e.length === 0) return {
|
|
38
38
|
totalRemaining: 0,
|
|
39
39
|
totalCapacity: 0,
|
|
@@ -41,8 +41,8 @@ function re(e) {
|
|
|
41
41
|
};
|
|
42
42
|
let t = 0, n = 0;
|
|
43
43
|
for (let r of e) {
|
|
44
|
-
let e =
|
|
45
|
-
t += e, n +=
|
|
44
|
+
let e = b(r);
|
|
45
|
+
t += e, n += x(r, e);
|
|
46
46
|
}
|
|
47
47
|
return {
|
|
48
48
|
totalRemaining: t,
|
|
@@ -50,29 +50,29 @@ function re(e) {
|
|
|
50
50
|
isSoldOut: t === 0
|
|
51
51
|
};
|
|
52
52
|
}
|
|
53
|
-
function
|
|
53
|
+
function re(e) {
|
|
54
54
|
if (!Array.isArray(e) || e.length === 0) return 0;
|
|
55
55
|
let t = e.map((e) => Number(e.price ?? e.ticketPrice)).filter((e) => Number.isFinite(e) && e > 0);
|
|
56
56
|
return t.length > 0 ? Math.min(...t) : 0;
|
|
57
57
|
}
|
|
58
58
|
//#endregion
|
|
59
59
|
//#region node_modules/@getmicdrop/svelte-components/dist/transforms/event.js
|
|
60
|
-
function
|
|
60
|
+
function ie(e) {
|
|
61
61
|
return e.availableTickets || e.available_tickets || e.tickets || [];
|
|
62
62
|
}
|
|
63
|
-
function
|
|
64
|
-
if (!e || !(e.isHidden === !0 || typeof e.visibility == "number" && e.visibility >=
|
|
63
|
+
function T(e) {
|
|
64
|
+
if (!e || !(e.isHidden === !0 || typeof e.visibility == "number" && e.visibility >= y.HIDDEN) || e.salesChannel === v.BOX_OFFICE_ONLY) return !1;
|
|
65
65
|
let t = n(), r = a(e.effectiveSalesBegin, e.salesBegin, e.salesStart, e.saleBegin, e.onSaleStart, e.saleStartDate), i = a(e.effectiveSalesEnd, e.salesEnd, e.saleEnd, e.onSaleEnd, e.saleEndDate), o = u(r), c = u(i);
|
|
66
66
|
if (!l(r) && !o || !l(i) && !c || o && s(o, t) > 0 || c && s(c, t) < 0) return !1;
|
|
67
67
|
let d = e.remainingCapacity ?? e.quantityRemaining ?? e.quantity;
|
|
68
68
|
return !(e.soldOut || d != null && d <= 0);
|
|
69
69
|
}
|
|
70
|
-
function
|
|
71
|
-
return e ? e.hasHiddenTickets === !0 ||
|
|
70
|
+
function ae(e) {
|
|
71
|
+
return e ? e.hasHiddenTickets === !0 || ie(e).some(T) : !1;
|
|
72
72
|
}
|
|
73
73
|
//#endregion
|
|
74
74
|
//#region node_modules/@getmicdrop/svelte-components/dist/errors/classes/NotFoundError.js
|
|
75
|
-
var
|
|
75
|
+
var E = class extends i {
|
|
76
76
|
constructor(e, t) {
|
|
77
77
|
let n = t ? `${e} with ID ${t} not found` : `${e} not found`;
|
|
78
78
|
super(n, "NOT_FOUND", {
|
|
@@ -87,11 +87,11 @@ var T = class extends i {
|
|
|
87
87
|
getUserMessage(e) {
|
|
88
88
|
return c(e)?.fromCode?.(this.code) || o(this.resourceType.toLowerCase());
|
|
89
89
|
}
|
|
90
|
-
},
|
|
90
|
+
}, D = {
|
|
91
91
|
primary: "#0284fe",
|
|
92
92
|
secondary: "#1d4ed8",
|
|
93
93
|
tertiary: "#2563eb"
|
|
94
|
-
},
|
|
94
|
+
}, O = {
|
|
95
95
|
50: "#f9fafb",
|
|
96
96
|
100: "#f3f4f6",
|
|
97
97
|
200: "#e5e7eb",
|
|
@@ -102,31 +102,31 @@ var T = class extends i {
|
|
|
102
102
|
700: "#374151",
|
|
103
103
|
800: "#1f2937",
|
|
104
104
|
900: "#111827"
|
|
105
|
-
},
|
|
105
|
+
}, k = {
|
|
106
106
|
text: {
|
|
107
|
-
primary:
|
|
108
|
-
secondary:
|
|
109
|
-
muted:
|
|
107
|
+
primary: O[900],
|
|
108
|
+
secondary: O[500],
|
|
109
|
+
muted: O[400],
|
|
110
110
|
inverted: "#ffffff"
|
|
111
111
|
},
|
|
112
112
|
background: {
|
|
113
113
|
primary: "#ffffff",
|
|
114
|
-
secondary:
|
|
115
|
-
tertiary:
|
|
116
|
-
dark:
|
|
117
|
-
darker:
|
|
114
|
+
secondary: O[50],
|
|
115
|
+
tertiary: O[100],
|
|
116
|
+
dark: O[800],
|
|
117
|
+
darker: O[900]
|
|
118
118
|
},
|
|
119
119
|
border: {
|
|
120
|
-
default:
|
|
121
|
-
strong:
|
|
122
|
-
muted:
|
|
120
|
+
default: O[200],
|
|
121
|
+
strong: O[300],
|
|
122
|
+
muted: O[100],
|
|
123
123
|
light: "#e0e0e0"
|
|
124
124
|
},
|
|
125
125
|
success: "#16a34a",
|
|
126
126
|
error: "#ef4444",
|
|
127
127
|
warning: "#f59e0b",
|
|
128
128
|
info: "#3b82f6"
|
|
129
|
-
},
|
|
129
|
+
}, A = {
|
|
130
130
|
blue: {
|
|
131
131
|
200: "#bfdbfe",
|
|
132
132
|
500: "#3b82f6",
|
|
@@ -177,35 +177,35 @@ var T = class extends i {
|
|
|
177
177
|
300: "#ffeaa7"
|
|
178
178
|
},
|
|
179
179
|
coral: "#ff6b6b"
|
|
180
|
-
},
|
|
181
|
-
blue:
|
|
180
|
+
}, j = { defaultThemePrimary: "#7c3aed" }, oe = {
|
|
181
|
+
blue: D.tertiary,
|
|
182
182
|
black: "#000000",
|
|
183
|
-
darkGray:
|
|
183
|
+
darkGray: O[700],
|
|
184
184
|
gray: "#666666",
|
|
185
|
-
lightGray:
|
|
186
|
-
white:
|
|
185
|
+
lightGray: O[400],
|
|
186
|
+
white: k.background.primary,
|
|
187
187
|
offWhite: "#fafafa",
|
|
188
|
-
lightBorder:
|
|
188
|
+
lightBorder: O[200],
|
|
189
189
|
border: "#cccccc",
|
|
190
|
-
orange:
|
|
191
|
-
red:
|
|
192
|
-
green:
|
|
193
|
-
},
|
|
194
|
-
function
|
|
190
|
+
orange: k.warning,
|
|
191
|
+
red: k.error,
|
|
192
|
+
green: A.green[500]
|
|
193
|
+
}, M = e("VC");
|
|
194
|
+
function se(e, t) {
|
|
195
195
|
if (e === 404) return "Promo code isn't valid.";
|
|
196
196
|
let n = (t ?? "").toLowerCase();
|
|
197
197
|
return e === 400 ? n.includes("not yet active") ? "Promo code doesn't apply." : n.includes("expired") ? "Promo code expired." : n.includes("limit") ? "Promo code has reached its limit." : "Promo code isn't valid." : "Failed to validate code";
|
|
198
198
|
}
|
|
199
|
-
async function
|
|
199
|
+
async function ce(e, t) {
|
|
200
200
|
try {
|
|
201
201
|
if (!t || !t.trim()) return {
|
|
202
202
|
valid: !1,
|
|
203
203
|
error: "Promo code is required"
|
|
204
204
|
};
|
|
205
|
-
let n = encodeURIComponent(t.trim()), r = await
|
|
205
|
+
let n = encodeURIComponent(t.trim()), r = await m(`/promo-codes/validate/${e}/${n}`);
|
|
206
206
|
if (!r.success) return {
|
|
207
207
|
valid: !1,
|
|
208
|
-
error:
|
|
208
|
+
error: se(r.statusCode, r.error)
|
|
209
209
|
};
|
|
210
210
|
let i = r.data;
|
|
211
211
|
return {
|
|
@@ -220,7 +220,7 @@ async function M(e, t) {
|
|
|
220
220
|
applyToTicketIds: i.applyToTicketIds
|
|
221
221
|
};
|
|
222
222
|
} catch (e) {
|
|
223
|
-
return
|
|
223
|
+
return M.error("Error validating promo code:", e), {
|
|
224
224
|
valid: !1,
|
|
225
225
|
error: "Network error validating code"
|
|
226
226
|
};
|
|
@@ -228,23 +228,23 @@ async function M(e, t) {
|
|
|
228
228
|
}
|
|
229
229
|
async function le(e) {
|
|
230
230
|
try {
|
|
231
|
-
let t = await
|
|
231
|
+
let t = await m(`/promo-codes/check/${e}`);
|
|
232
232
|
return !t.success || t.data.hasPromoCodes === !0;
|
|
233
233
|
} catch (e) {
|
|
234
|
-
return
|
|
234
|
+
return M.error("Error checking promo codes availability:", e), !0;
|
|
235
235
|
}
|
|
236
236
|
}
|
|
237
237
|
async function ue(e, t, n) {
|
|
238
238
|
try {
|
|
239
239
|
let r = { promoCode: t };
|
|
240
240
|
n && Object.keys(n).length > 0 && (r.productQuantities = n);
|
|
241
|
-
let i = await
|
|
241
|
+
let i = await h(`${p()}/cart/${e}/apply-promo`, r);
|
|
242
242
|
return i.success ? { success: !0 } : {
|
|
243
243
|
success: !1,
|
|
244
244
|
error: i.error || "Failed to apply promo code"
|
|
245
245
|
};
|
|
246
246
|
} catch (e) {
|
|
247
|
-
return
|
|
247
|
+
return M.error("Error applying promo code:", e), {
|
|
248
248
|
success: !1,
|
|
249
249
|
error: "Network error applying code"
|
|
250
250
|
};
|
|
@@ -289,7 +289,7 @@ async function H(e, t = fetch, n) {
|
|
|
289
289
|
}
|
|
290
290
|
let i = (async () => {
|
|
291
291
|
try {
|
|
292
|
-
let r = await t(n ? `${
|
|
292
|
+
let r = await t(n ? `${g()}/events/${e}?password=${encodeURIComponent(n)}` : `${g()}/events/${e}`);
|
|
293
293
|
if (!r.ok) return r.status === 404 ? F("event_not_found") : (B.error(`Failed to fetch event details: ${r.status}`), P("event_fetch_failed"));
|
|
294
294
|
let i = await r.json();
|
|
295
295
|
return i ? N(i) : F("event_not_found");
|
|
@@ -307,7 +307,7 @@ async function fe(e, t = fetch, n) {
|
|
|
307
307
|
}
|
|
308
308
|
async function U(e, t, n = (e) => e) {
|
|
309
309
|
try {
|
|
310
|
-
let r = await
|
|
310
|
+
let r = await f(e);
|
|
311
311
|
return r ? N(n(r)) : (B.error(`Failed to load (${t}): network or server error`), P(t));
|
|
312
312
|
} catch (e) {
|
|
313
313
|
return B.error(`Error loading (${t}):`, e), P(t);
|
|
@@ -318,7 +318,7 @@ function pe(e) {
|
|
|
318
318
|
}
|
|
319
319
|
async function W(e, t) {
|
|
320
320
|
let n = t?.trim(), r = n ? `?promoCode=${encodeURIComponent(n)}` : "";
|
|
321
|
-
return U(`${
|
|
321
|
+
return U(`${g()}/tickets/event/${e}${r}`, "tickets_fetch_failed", pe);
|
|
322
322
|
}
|
|
323
323
|
async function me(e, t) {
|
|
324
324
|
return de(await W(e, t), []);
|
|
@@ -338,39 +338,39 @@ function K(e, t, n) {
|
|
|
338
338
|
}), r;
|
|
339
339
|
}
|
|
340
340
|
async function ge(e, t, n, r) {
|
|
341
|
-
return K(`${
|
|
341
|
+
return K(`${g()}/events/venue/${e}/month/${t}/${n}`, "month_events_fetch_failed", r);
|
|
342
342
|
}
|
|
343
343
|
async function _e(e, t, n, r) {
|
|
344
|
-
return K(`${
|
|
344
|
+
return K(`${g()}/events/organization/${e}/month/${t}/${n}`, "org_month_events_fetch_failed", r);
|
|
345
345
|
}
|
|
346
346
|
async function ve(e, t) {
|
|
347
|
-
return U(`${
|
|
347
|
+
return U(`${g()}/series/${e}/occurrences?venueId=${t}`, "series_cta_fetch_failed");
|
|
348
348
|
}
|
|
349
349
|
async function ye(e, t) {
|
|
350
350
|
let n = await ve(e, t);
|
|
351
351
|
return n.ok ? n.data : null;
|
|
352
352
|
}
|
|
353
|
-
async function
|
|
353
|
+
async function be(e, t) {
|
|
354
354
|
try {
|
|
355
|
-
let n = t ? `?slug=${encodeURIComponent(t)}` : "", r = await
|
|
356
|
-
if (!r || !r.type) throw new
|
|
355
|
+
let n = t ? `?slug=${encodeURIComponent(t)}` : "", r = await f(`${g()}/resolve/${encodeURIComponent(String(e))}${n}`);
|
|
356
|
+
if (!r || !r.type) throw new E("entity", String(e));
|
|
357
357
|
return r;
|
|
358
358
|
} catch (e) {
|
|
359
359
|
return B.error("Error resolving public entity:", e), null;
|
|
360
360
|
}
|
|
361
361
|
}
|
|
362
|
-
async function
|
|
362
|
+
async function xe(e, t) {
|
|
363
363
|
try {
|
|
364
|
-
let n = t ? `${
|
|
365
|
-
if (!r) throw new
|
|
364
|
+
let n = t ? `${g()}/collections/${e}?password=${encodeURIComponent(t)}` : `${g()}/collections/${e}`, r = await f(n);
|
|
365
|
+
if (!r) throw new E("collection", String(e));
|
|
366
366
|
return r;
|
|
367
367
|
} catch (e) {
|
|
368
368
|
return B.error("Error fetching collection:", e), null;
|
|
369
369
|
}
|
|
370
370
|
}
|
|
371
|
-
async function
|
|
371
|
+
async function Se(e, t) {
|
|
372
372
|
try {
|
|
373
|
-
let n = await
|
|
373
|
+
let n = await f(`${g()}/events/${e}/check-password`, {
|
|
374
374
|
method: "POST",
|
|
375
375
|
headers: { "Content-Type": "application/json" },
|
|
376
376
|
body: JSON.stringify({ password: t })
|
|
@@ -382,83 +382,82 @@ async function xe(e, t) {
|
|
|
382
382
|
}
|
|
383
383
|
//#endregion
|
|
384
384
|
//#region src/lib/navigation.ts
|
|
385
|
-
function
|
|
386
|
-
let n =
|
|
385
|
+
function Ce(e, t) {
|
|
386
|
+
let n = _();
|
|
387
387
|
return t ? `${n}/e/${e}-${t}` : `${n}/e/${e}`;
|
|
388
388
|
}
|
|
389
|
-
function
|
|
389
|
+
function we(e, t, n) {
|
|
390
390
|
let r = n?.toString(), i = t ? `/e/${e}-${t}` : `/e/${e}`;
|
|
391
|
-
return `${
|
|
391
|
+
return `${_()}${i}${r ? `?${r}` : ""}`;
|
|
392
392
|
}
|
|
393
|
-
|
|
393
|
+
var Te = "get-micdrop.com";
|
|
394
|
+
function q(e) {
|
|
394
395
|
let t = typeof e == "string" ? e.trim() : "";
|
|
395
|
-
|
|
396
|
-
let n = new URL(f());
|
|
397
|
-
return `${n.protocol}//${encodeURIComponent(t)}.${n.hostname.replace(/^www\./, "")}`;
|
|
396
|
+
return t ? `https://${encodeURIComponent(t)}.${Te}` : "";
|
|
398
397
|
}
|
|
399
|
-
function
|
|
400
|
-
let t =
|
|
398
|
+
function Ee(e) {
|
|
399
|
+
let t = q(e);
|
|
401
400
|
return t ? `${t}/gift-cards/buy` : "";
|
|
402
401
|
}
|
|
403
|
-
function
|
|
402
|
+
function De(e, t, n) {
|
|
404
403
|
let r = n?.toString();
|
|
405
404
|
return `/${e}/${t}${r ? `?${r}` : ""}`;
|
|
406
405
|
}
|
|
407
|
-
function
|
|
406
|
+
function Oe(e) {
|
|
408
407
|
return `/${e}`;
|
|
409
408
|
}
|
|
410
|
-
function
|
|
411
|
-
return `${
|
|
409
|
+
function ke(e) {
|
|
410
|
+
return `${_()}/${e}`;
|
|
412
411
|
}
|
|
413
|
-
function
|
|
412
|
+
function J(e, t) {
|
|
414
413
|
return `/${e}/${t}/checkout`;
|
|
415
414
|
}
|
|
416
|
-
function
|
|
415
|
+
function Ae(e) {
|
|
417
416
|
return `/?${e.toString()}`;
|
|
418
417
|
}
|
|
419
|
-
function
|
|
420
|
-
let r = `${
|
|
418
|
+
function je(e, t, n = {}) {
|
|
419
|
+
let r = `${J(e, t)}/success`, i = new URLSearchParams();
|
|
421
420
|
n.orderId && i.set("orderId", n.orderId), n.ticketCount && n.ticketCount > 0 && i.set("tickets", String(n.ticketCount));
|
|
422
421
|
let a = i.toString();
|
|
423
422
|
return a ? `${r}?${a}` : r;
|
|
424
423
|
}
|
|
425
424
|
//#endregion
|
|
426
425
|
//#region src/lib/api/venues.ts
|
|
427
|
-
var
|
|
428
|
-
async function
|
|
426
|
+
var Y = e("VC");
|
|
427
|
+
async function Me(e) {
|
|
429
428
|
try {
|
|
430
|
-
if (!e) return
|
|
431
|
-
let t = await
|
|
432
|
-
return t.success ? t.data ?? null : (
|
|
429
|
+
if (!e) return Y.warn("getVenue called without venueId"), null;
|
|
430
|
+
let t = await m(`/venues/${e}`);
|
|
431
|
+
return t.success ? t.data ?? null : (Y.error(`Failed to fetch venue: ${t.statusCode}`), null);
|
|
433
432
|
} catch (e) {
|
|
434
|
-
return
|
|
433
|
+
return Y.error("Error fetching venue:", e), null;
|
|
435
434
|
}
|
|
436
435
|
}
|
|
437
|
-
async function
|
|
438
|
-
let t =
|
|
436
|
+
async function Ne(e) {
|
|
437
|
+
let t = q(e);
|
|
439
438
|
if (!t) return !1;
|
|
440
439
|
try {
|
|
441
|
-
let e = await
|
|
440
|
+
let e = await m(`/sites/by-host/${encodeURIComponent(new URL(t).host)}`);
|
|
442
441
|
return !!(e.success && e.data);
|
|
443
442
|
} catch (e) {
|
|
444
|
-
return
|
|
443
|
+
return Y.warn("hasPublishedSite failed:", e), !1;
|
|
445
444
|
}
|
|
446
445
|
}
|
|
447
446
|
//#endregion
|
|
448
447
|
//#region src/lib/api/transformers/giftCard.ts
|
|
449
|
-
function
|
|
448
|
+
function X(e, t) {
|
|
450
449
|
return e == null || t(e);
|
|
451
450
|
}
|
|
452
|
-
function
|
|
451
|
+
function Pe(e) {
|
|
453
452
|
if (typeof e != "object" || !e) return !1;
|
|
454
453
|
let t = e;
|
|
455
|
-
return t.valid === !0 && Number.isInteger(t.appliedAmount) && typeof t.remainingTotal == "number" && Number.isFinite(t.remainingTotal) &&
|
|
454
|
+
return t.valid === !0 && Number.isInteger(t.appliedAmount) && typeof t.remainingTotal == "number" && Number.isFinite(t.remainingTotal) && X(t.giftCardCode, (e) => typeof e == "string") && X(t.giftCardBalance, (e) => typeof e == "number" && Number.isFinite(e)) && X(t.fullyCoveredByCard, (e) => typeof e == "boolean");
|
|
456
455
|
}
|
|
457
|
-
var
|
|
458
|
-
function
|
|
459
|
-
if (!
|
|
456
|
+
var Fe = "We couldn't apply that gift card. Please try again.";
|
|
457
|
+
function Z(e) {
|
|
458
|
+
if (!Pe(e)) return {
|
|
460
459
|
valid: !1,
|
|
461
|
-
error:
|
|
460
|
+
error: Fe
|
|
462
461
|
};
|
|
463
462
|
let t = e, n = r(d(t.appliedAmount)), i = t.remainingTotal, a = t.fullyCoveredByCard ?? i <= 0, o = !a;
|
|
464
463
|
return {
|
|
@@ -475,9 +474,9 @@ function Pe(e) {
|
|
|
475
474
|
//#endregion
|
|
476
475
|
//#region src/lib/api/gift-cards.ts
|
|
477
476
|
var Q = e("VC");
|
|
478
|
-
async function
|
|
477
|
+
async function Ie(e, t) {
|
|
479
478
|
try {
|
|
480
|
-
let n = await
|
|
479
|
+
let n = await h(`${p()}/cart/${e}/apply-gift-card`, { giftCardCode: t });
|
|
481
480
|
if (!n.success) return n.statusCode === 429 ? {
|
|
482
481
|
valid: !1,
|
|
483
482
|
error: "Too many attempts. Please wait a moment and try again."
|
|
@@ -485,7 +484,7 @@ async function Fe(e, t) {
|
|
|
485
484
|
valid: !1,
|
|
486
485
|
error: n.error || "Invalid gift card code"
|
|
487
486
|
});
|
|
488
|
-
let r =
|
|
487
|
+
let r = Z(n.data);
|
|
489
488
|
return r.valid || Q.error("Apply gift card returned an unusable payload:", n.data), r;
|
|
490
489
|
} catch (e) {
|
|
491
490
|
return Q.error("applyGiftCard error:", e), {
|
|
@@ -494,9 +493,9 @@ async function Fe(e, t) {
|
|
|
494
493
|
};
|
|
495
494
|
}
|
|
496
495
|
}
|
|
497
|
-
async function
|
|
496
|
+
async function Le(e, t) {
|
|
498
497
|
try {
|
|
499
|
-
let n = t?.giftCardId ? { giftCardId: t.giftCardId } : t?.code ? { giftCardCode: t.code } : null, r = await
|
|
498
|
+
let n = t?.giftCardId ? { giftCardId: t.giftCardId } : t?.code ? { giftCardCode: t.code } : null, r = await ee(`${p()}/cart/${e}/gift-card`, n ? { body: JSON.stringify(n) } : void 0);
|
|
500
499
|
if (!r.success) return Q.error("Remove gift card failed:", r.error), {
|
|
501
500
|
success: !1,
|
|
502
501
|
error: r.error || "Failed to remove gift card"
|
|
@@ -513,10 +512,10 @@ async function Ie(e, t) {
|
|
|
513
512
|
};
|
|
514
513
|
}
|
|
515
514
|
}
|
|
516
|
-
async function
|
|
517
|
-
let i =
|
|
515
|
+
async function Re(e, n, r) {
|
|
516
|
+
let i = ne(r);
|
|
518
517
|
try {
|
|
519
|
-
let r = await
|
|
518
|
+
let r = await h(`${p()}/cart/${e}/complete-gift-card-payment`, {
|
|
520
519
|
customerName: t(n.firstName, n.lastName),
|
|
521
520
|
customerEmail: n.email,
|
|
522
521
|
firstName: n.firstName,
|
|
@@ -546,11 +545,11 @@ async function Le(e, n, r) {
|
|
|
546
545
|
//#endregion
|
|
547
546
|
//#region src/lib/api/waitlist.ts
|
|
548
547
|
var $ = e("VC");
|
|
549
|
-
async function
|
|
548
|
+
async function ze(e, t, n = null, r = !1) {
|
|
550
549
|
try {
|
|
551
550
|
let i = { email: t };
|
|
552
551
|
n && r && (i.phone = n, i.smsOptIn = !0);
|
|
553
|
-
let a = await
|
|
552
|
+
let a = await h(`/events/${e}/waitlist`, i);
|
|
554
553
|
return a.success ? {
|
|
555
554
|
success: !0,
|
|
556
555
|
updated: a.data?.updated,
|
|
@@ -566,9 +565,9 @@ async function Re(e, t, n = null, r = !1) {
|
|
|
566
565
|
};
|
|
567
566
|
}
|
|
568
567
|
}
|
|
569
|
-
async function
|
|
568
|
+
async function Be(e, t) {
|
|
570
569
|
try {
|
|
571
|
-
let n = await
|
|
570
|
+
let n = await h(`/checkout/validate-token/${e}`, { email: t });
|
|
572
571
|
return n.success ? {
|
|
573
572
|
valid: !0,
|
|
574
573
|
eventId: n.data?.eventId ?? 0,
|
|
@@ -586,9 +585,9 @@ async function ze(e, t) {
|
|
|
586
585
|
};
|
|
587
586
|
}
|
|
588
587
|
}
|
|
589
|
-
async function
|
|
588
|
+
async function Ve(e, t) {
|
|
590
589
|
try {
|
|
591
|
-
let n = await
|
|
590
|
+
let n = await h(`/waitlist/requeue/${e}`, { email: t });
|
|
592
591
|
return n.success ? { success: !0 } : {
|
|
593
592
|
success: !1,
|
|
594
593
|
errorCode: n.error
|
|
@@ -600,14 +599,14 @@ async function Be(e, t) {
|
|
|
600
599
|
};
|
|
601
600
|
}
|
|
602
601
|
}
|
|
603
|
-
async function
|
|
602
|
+
async function He(e) {
|
|
604
603
|
let t = {
|
|
605
604
|
waitlistEnabled: !1,
|
|
606
605
|
soldOut: !1,
|
|
607
606
|
gated: !1
|
|
608
607
|
};
|
|
609
608
|
try {
|
|
610
|
-
let n = await
|
|
609
|
+
let n = await m(`/events/${e}/waitlist/status`);
|
|
611
610
|
return n.success ? {
|
|
612
611
|
waitlistEnabled: !!n.data?.waitlistEnabled,
|
|
613
612
|
soldOut: !!n.data?.soldOut,
|
|
@@ -617,9 +616,9 @@ async function Ve(e) {
|
|
|
617
616
|
return $.error("getWaitlistStatus error:", e), t;
|
|
618
617
|
}
|
|
619
618
|
}
|
|
620
|
-
function
|
|
619
|
+
function Ue(e) {
|
|
621
620
|
let t = String(e % 60).padStart(2, "0");
|
|
622
621
|
return e >= 3600 ? `${Math.floor(e / 3600)}:${String(Math.floor(e % 3600 / 60)).padStart(2, "0")}:${t}` : `${Math.floor(e / 60)}:${t}`;
|
|
623
622
|
}
|
|
624
623
|
//#endregion
|
|
625
|
-
export { le as A,
|
|
624
|
+
export { le as A, w as B, W as C, _e as D, ge as E, k as F, C as H, oe as I, ae as L, A as M, j as N, be as O, O as P, T as R, me as S, ye as T, re as U, S as V, De as _, Be as a, Se as b, Le as c, je as d, J as f, Ce as g, we as h, Ve as i, ce as j, ue as k, Me as l, Oe as m, He as n, Ie as o, ke as p, ze as r, Re as s, Ue as t, Ne as u, Ee as v, xe as w, fe as x, Ae as y, y as z };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { n as e } from "./rolldown-runtime-DtPi1Y-2.js";
|
|
2
2
|
import { C as t, f as n, p as r, u as i } from "./defaultLabels-Zp9QbN37.js";
|
|
3
|
-
import {
|
|
3
|
+
import { R as a } from "./orders-_DuPjm-g.js";
|
|
4
4
|
import { t as o } from "./browser-DxdP6IWt.js";
|
|
5
5
|
//#region src/lib/view-tickets/defaults.ts
|
|
6
6
|
var s = /* @__PURE__ */ e(o(), 1);
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { d as e, f as t, i as n, l as r, s as i } from "./scarcity-CwnIxi1J.js";
|
|
2
2
|
import { C as a } from "./defaultLabels-Zp9QbN37.js";
|
|
3
3
|
import { n as o, t as s } from "./event-c9mHeEJz.js";
|
|
4
|
-
import { B as c, H as l, L as u, P as d, U as f, V as p } from "./api-
|
|
4
|
+
import { B as c, H as l, L as u, P as d, U as f, V as p } from "./api-LOBSDFGW.js";
|
|
5
5
|
//#region src/lib/utils/event-transform.js
|
|
6
6
|
var m = "data:image/svg+xml," + encodeURIComponent(`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 200 300" fill="none">
|
|
7
7
|
<rect width="200" height="300" fill="${d[200]}"/>
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { E as e } from "./Button-klwKgfhG.js";
|
|
2
|
-
import {
|
|
2
|
+
import { R as t, W as n } from "./orders-_DuPjm-g.js";
|
|
3
3
|
//#region src/lib/public-calendar-flow/eventStatusStream.ts
|
|
4
4
|
var r = e("VC"), i = /* @__PURE__ */ new Set([
|
|
5
5
|
"canceled",
|