@getmicdrop/venue-calendar 4.2.33 → 4.2.35
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/{ArrowLeftIcon-B92-MN6-.js → ArrowLeftIcon-DS-NEije.js} +1 -1
- package/dist/{Badge-Bv_MT-Vt.js → Badge-DIHnRZlw.js} +1 -1
- package/dist/{BlockPlaceholder-DuE4xLS_.js → BlockPlaceholder-Dy9fStDr.js} +1 -1
- package/dist/{Calendar-CX3S7j_2.js → Calendar-CXwhGAmC.js} +19 -19
- package/dist/{CalendarFoundryView-CE5VMPRl.js → CalendarFoundryView-BRurhscw.js} +950 -950
- package/dist/{CalendarIcon-pJ01x71c.js → CalendarIcon-CvZ-GUH_.js} +1 -1
- package/dist/{CartView-BZALykSb.js → CartView-DT8DlMqQ.js} +532 -532
- package/dist/{Checkout-c6ExwNzk.js → Checkout-D3VqG09o.js} +173 -173
- package/dist/{Checkout-B6BHEAwF.js → Checkout-UU9C7CXV.js} +129 -129
- package/dist/{CheckoutTimer-Bz-HJhV2.js → CheckoutTimer-2WEgppW1.js} +5 -5
- package/dist/{ChevronDownIcon-k93EaHQh.js → ChevronDownIcon-DXbr-7H6.js} +1 -1
- package/dist/{ClockIcon-hnrV9bwg.js → ClockIcon-Dyx1LMo7.js} +1 -1
- package/dist/{CloseIcon-CdZ5mNTK.js → CloseIcon-NMHzwT75.js} +1 -1
- package/dist/{CollectionView-BMDKM-lg.js → CollectionView-DyMB_bPY.js} +9 -10
- package/dist/{Event-DvRnmTdU.js → Event-CXCOnkmi.js} +85 -85
- package/dist/EventPage-HlhaVqRG.js +981 -0
- package/dist/{Heading-Dfo3bjyn.js → Heading-DcZtRBSB.js} +1 -1
- package/dist/{Image-B3cEndLZ.js → Image-BZGbFJLw.js} +1 -1
- package/dist/{Input-BntIoPeV.js → Input-Cgdxdj6y.js} +1 -1
- package/dist/{MailIcon-CMyjGJ4_.js → MailIcon-D34sBBQX.js} +1 -1
- package/dist/{Modal-CpMs0l2W.js → Modal-BvT64ak1.js} +2 -2
- package/dist/{ModalFooter-Kdyt5XyP.js → ModalFooter-DM1dyl4S.js} +2 -2
- package/dist/{PasswordInput-C91gXtFY.js → PasswordInput-BNKrzXNm.js} +1 -1
- package/dist/{ScarcityBadge-C0YeWGkd.js → ScarcityBadge-DmbmsFlY.js} +23 -22
- package/dist/{SeriesPage-DNyhMA_k.js → SeriesPage-BXKz7PJV.js} +4 -4
- package/dist/{Spinner-BwiDys7C.js → Spinner-gpYLD9h6.js} +1 -1
- package/dist/{Success-BxvH6W_x.js → Success-DieJd6sx.js} +52 -52
- package/dist/{TagIcon-BkPcpKdu.js → TagIcon-Q7BC2QeQ.js} +1 -1
- package/dist/ViewTicketsEmbed-DqwHARj0.js +727 -0
- package/dist/{WarningCircleIcon-D78IFaPY.js → WarningCircleIcon-Dxi6_NlN.js} +1 -1
- package/dist/{WarningTriIcon-6WbGCso4.js → WarningTriIcon-BVNO82pk.js} +1 -1
- package/dist/{__SKIP_PATHS__-tAxwP7_6.js → __SKIP_PATHS__-BZ2V4IU4.js} +1 -1
- package/dist/api/api.cjs +1 -1
- package/dist/api/api.mjs +300 -216
- package/dist/api/gift-cards.d.ts +1 -1
- package/dist/api/orders.d.ts +2 -2
- package/dist/api/waitlist.d.ts +6 -1
- package/dist/{colors-DbQNhbC_.js → colors-B3NG0RHG.js} +113 -117
- package/dist/constants-DqKf8bUn.js +356 -0
- package/dist/{copyToClipboard-DAGJHhtn.js → copyToClipboard-CLo_2bfp.js} +1 -1
- package/dist/{de-BG-86m10.js → de-8N03rEoe.js} +4 -1
- package/dist/{de-BZpzzwT9.js → de-tOW1Ez0s.js} +63 -1
- package/dist/{timezones-C5l0SSHK.js → defaultLabels-D_9CneL4.js} +507 -1
- package/dist/{es-9jwSoUSD.js → es-DrYewQpd.js} +51 -1
- package/dist/{es-B1RPM3H_.js → es-tRMGbtbB.js} +4 -1
- package/dist/{event-v8d4wRpB.js → event-CFDG8adb.js} +1 -1
- package/dist/{event-transform-lC22EDSL.js → event-transform-jJPAKgYX.js} +4 -4
- package/dist/{eventStatusStream-CopqZ2oa.js → eventStatusStream-wmEyQSgV.js} +5 -5
- package/dist/{fr-fYY2O8Ab.js → fr-Bs9xnPu6.js} +63 -1
- package/dist/{fr-B6FgrH9s.js → fr-DDnljtQz.js} +4 -1
- package/dist/{href-BH6l_kZx.js → href-BfMcUXhM.js} +2 -2
- package/dist/{i18n-CIVh_urJ.js → i18n-BgkKrB4o.js} +126 -126
- package/dist/i18n-DK3npqzN.js +28 -0
- package/dist/{id-But8qcA2.js → id-BLwvLobz.js} +63 -1
- package/dist/{id-CK7hal8E.js → id-BZshacSm.js} +4 -1
- package/dist/{it-BdV8d4GZ.js → it-B6Rbpjec.js} +4 -1
- package/dist/{it-Cr9Quauw.js → it-CQ_Y8YK3.js} +63 -1
- package/dist/{ja-DKVQltc4.js → ja-Bmj-bPuM.js} +4 -1
- package/dist/{ja-CNXwg0_H.js → ja-CeudRJqE.js} +63 -1
- package/dist/{ko-DtoIJliT.js → ko-DFwVxd-1.js} +63 -1
- package/dist/{ko-DpIk-4pN.js → ko-r-ecuHZ5.js} +4 -1
- package/dist/{labels-BUH8ouCu.js → labels-BHqxbbw9.js} +1 -1
- package/dist/locales/{4.2.32 → 4.2.35}/flow/de.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.35}/flow/es.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.35}/flow/fr.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.35}/flow/id.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.35}/flow/it.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.35}/flow/ja.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.35}/flow/ko.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.35}/flow/nl.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.35}/flow/pl.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.35}/flow/pt-br.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.35}/flow/tr.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.35}/flow/zh.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.35}/main/de.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.35}/main/es.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.35}/main/fr.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.35}/main/id.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.35}/main/it.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.35}/main/ja.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.35}/main/ko.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.35}/main/nl.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.35}/main/pl.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.35}/main/pt-br.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.35}/main/tr.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.35}/main/zh.js +1 -1
- package/dist/{modalManager.svelte-C4dWVCst.js → modalManager.svelte-CrrDshW7.js} +2 -2
- package/dist/{nl-C-dVfidI.js → nl-CS1da1Bc.js} +4 -1
- package/dist/{nl-Dbs4YQMw.js → nl-CYc0p85Y.js} +63 -1
- package/dist/{order-totals-CeeD6GjZ.js → order-totals-D0JKhd70.js} +31 -31
- package/dist/{orders-BuGy4vpJ.js → orders-CCWPQsWb.js} +365 -209
- package/dist/{phoneUtils-BDV9Eggn.js → phoneUtils-aQHGh8C_.js} +1 -1
- package/dist/{pixels-D6vqcuy2.js → pixels-M2q8HRk_.js} +11 -11
- package/dist/{pl-Da6lsZXQ.js → pl-BSqAasUa.js} +63 -1
- package/dist/{pl-CnFcI33y.js → pl-C2bkE2WA.js} +4 -1
- package/dist/{promo-DtLZRskK.js → promo-CKvS9lia.js} +3 -3
- package/dist/{pt-br-6QYijxa0.js → pt-br--DIxBDjz.js} +4 -1
- package/dist/{pt-br-D1wHabRR.js → pt-br-CZs8_gFN.js} +63 -1
- package/dist/{serverTotals-t2UmKkhC.js → serverTotals-DGd3p1s5.js} +1 -1
- package/dist/{shareCopyFeedback.svelte-B-M53Wj2.js → shareCopyFeedback.svelte-DTOJruVM.js} +55 -55
- package/dist/{showcase-state-options-VZcqIjpF.js → showcase-state-options-Da3jPUQb.js} +1 -1
- package/dist/{to-event-card-props-CpXtfoKx.js → to-event-card-props-B5bsYKP4.js} +31 -31
- package/dist/{tr-Pv_m8usO.js → tr-Bk7x5MW7.js} +4 -1
- package/dist/{tr-CpN50zWw.js → tr-O80C2r5C.js} +63 -1
- package/dist/{utils-CtqaTDLB.js → utils-RE2aEa_D.js} +49 -49
- package/dist/venue-calendar.es.js +710 -734
- package/dist/venue-calendar.iife.js +56 -57
- package/dist/venue-calendar.umd.js +54 -55
- package/dist/{zh-CAAnH4T4.js → zh-C8kyVh24.js} +4 -1
- package/dist/{zh-CwlRq_aG.js → zh-ydknixkJ.js} +63 -1
- package/package.json +220 -220
- package/dist/EventPage-CTo8ynx6.js +0 -971
- package/dist/ViewTicketsEmbed-DVurn8FG.js +0 -690
- package/dist/constants-ENlpIS8i.js +0 -822
- package/dist/createI18n-DBUVdZra.js +0 -75
package/dist/api/gift-cards.d.ts
CHANGED
|
@@ -92,7 +92,7 @@ export interface CompleteGiftCardPaymentResult {
|
|
|
92
92
|
/**
|
|
93
93
|
* Complete a gift-card-only payment (no Stripe required when balance >= total).
|
|
94
94
|
*/
|
|
95
|
-
export declare function completeGiftCardPayment(cartId: string, customerDetails: CompleteGiftCardPaymentInput): Promise<CompleteGiftCardPaymentResult>;
|
|
95
|
+
export declare function completeGiftCardPayment(cartId: string, customerDetails: CompleteGiftCardPaymentInput, uiLocale?: string): Promise<CompleteGiftCardPaymentResult>;
|
|
96
96
|
/**
|
|
97
97
|
* Fetch venue information by slug, discriminating a real 404 from a transient
|
|
98
98
|
* failure.
|
package/dist/api/orders.d.ts
CHANGED
|
@@ -25,7 +25,7 @@ export interface FreeOrderBuyer {
|
|
|
25
25
|
questionAnswer?: string;
|
|
26
26
|
mailingList?: boolean;
|
|
27
27
|
}
|
|
28
|
-
export declare function createPaymentIntent(cartId: string, quantities: Record<string | number, number>, donationAmounts?: Record<string | number, number>, buyer?: FreeOrderBuyer): Promise<PaymentIntentResponse | null>;
|
|
28
|
+
export declare function createPaymentIntent(cartId: string, quantities: Record<string | number, number>, donationAmounts?: Record<string | number, number>, buyer?: FreeOrderBuyer, uiLocale?: string): Promise<PaymentIntentResponse | null>;
|
|
29
29
|
/**
|
|
30
30
|
* Fetch an existing cart by UUID (cross-device pre-fill — §1.3).
|
|
31
31
|
*
|
|
@@ -149,7 +149,7 @@ export declare function getOrder(orderId: string): Promise<Order | null>;
|
|
|
149
149
|
* @param payload - Payment validation payload
|
|
150
150
|
* @returns Validation result
|
|
151
151
|
*/
|
|
152
|
-
export declare function validatePaymentIntent(cartId: string, payload: ValidatePaymentRequest): Promise<ValidatePaymentResponse | null>;
|
|
152
|
+
export declare function validatePaymentIntent(cartId: string, payload: ValidatePaymentRequest, uiLocale?: string): Promise<ValidatePaymentResponse | null>;
|
|
153
153
|
/**
|
|
154
154
|
* Extend the checkout session by 15 minutes
|
|
155
155
|
*
|
package/dist/api/waitlist.d.ts
CHANGED
|
@@ -10,7 +10,12 @@ export interface JoinWaitlistResult {
|
|
|
10
10
|
* line moves). Absent/0 when the backend could not compute it. Supersedes
|
|
11
11
|
* decision #2/#20's opacity (2026-09-03). */
|
|
12
12
|
position?: number;
|
|
13
|
-
|
|
13
|
+
/** One of the server's failure enums — waitlist_not_enabled |
|
|
14
|
+
* event_not_found | invalid_phone | already_purchased |
|
|
15
|
+
* phone_already_registered — or this module's own join_failed /
|
|
16
|
+
* network_error. Callers map it to friendly copy through the label
|
|
17
|
+
* catalogue, so the message renders in the buyer's language. */
|
|
18
|
+
errorCode?: string;
|
|
14
19
|
}
|
|
15
20
|
/**
|
|
16
21
|
* Join the waitlist for a sold-out event.
|
|
@@ -1,39 +1,39 @@
|
|
|
1
1
|
import { x as e } from "./Button-C4uFgl7L.js";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
2
|
+
import { D as t, I as n, T as r, _ as i, b as a, c as o, g as s, h as c, k as l, l as u } from "./defaultLabels-D_9CneL4.js";
|
|
3
|
+
import { w as d } from "./constants-DqKf8bUn.js";
|
|
4
|
+
import { A as f, F as p, I as m, M as h, R as g, c as ee, j as _, y as v } from "./orders-CCWPQsWb.js";
|
|
5
5
|
//#region node_modules/@getmicdrop/svelte-components/dist/transforms/ticket.js
|
|
6
|
-
var
|
|
6
|
+
var y = {
|
|
7
7
|
EVERYWHERE: 0,
|
|
8
8
|
ONLINE_ONLY: 1,
|
|
9
9
|
BOX_OFFICE_ONLY: 2
|
|
10
|
-
},
|
|
10
|
+
}, b = {
|
|
11
11
|
VISIBLE: 0,
|
|
12
12
|
HIDDEN: 1,
|
|
13
13
|
PROMO_ONLY: 2
|
|
14
14
|
};
|
|
15
|
-
function
|
|
15
|
+
function x(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 S(e, t) {
|
|
19
19
|
return e.totalCapacity ?? e.quantity ?? t;
|
|
20
20
|
}
|
|
21
|
-
function
|
|
22
|
-
let n = t(), r =
|
|
23
|
-
if (!
|
|
24
|
-
if (!
|
|
25
|
-
if (
|
|
26
|
-
if (
|
|
21
|
+
function C(e) {
|
|
22
|
+
let n = t(), r = s(e.effectiveSalesBegin, e.salesBegin, e.saleStartDate) ?? null, o = s(e.effectiveSalesEnd, e.salesEnd, e.saleEndDate) ?? null, l = a(r), u = a(o);
|
|
23
|
+
if (!i(r) && !l) return "scheduled";
|
|
24
|
+
if (!i(o) && !u) return "sales_ended";
|
|
25
|
+
if (l && c(n, l) < 0) return "scheduled";
|
|
26
|
+
if (u && c(n, u) > 0) return "sales_ended";
|
|
27
27
|
if (e.soldOut === !0) return "sold_out";
|
|
28
|
-
let d =
|
|
28
|
+
let d = x(e), f = S(e, d);
|
|
29
29
|
return d === 0 ? "sold_out" : f > 0 && d / f < .1 ? "low" : "on_sale";
|
|
30
30
|
}
|
|
31
|
-
function
|
|
31
|
+
function te(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 !== y.BOX_OFFICE_ONLY)), t.publicOnly && (n = n.filter((e) => e.visibility === b.VISIBLE)), n;
|
|
35
35
|
}
|
|
36
|
-
function
|
|
36
|
+
function ne(e) {
|
|
37
37
|
if (!Array.isArray(e) || e.length === 0) return {
|
|
38
38
|
totalRemaining: 0,
|
|
39
39
|
totalCapacity: 0,
|
|
@@ -41,8 +41,8 @@ function C(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 = x(r);
|
|
45
|
+
t += e, n += S(r, e);
|
|
46
46
|
}
|
|
47
47
|
return {
|
|
48
48
|
totalRemaining: t,
|
|
@@ -50,29 +50,29 @@ function C(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 >=
|
|
65
|
-
let n = t(), r =
|
|
66
|
-
if (!
|
|
63
|
+
function w(e) {
|
|
64
|
+
if (!e || !(e.isHidden === !0 || typeof e.visibility == "number" && e.visibility >= b.PROMO_ONLY) || e.salesChannel === y.BOX_OFFICE_ONLY) return !1;
|
|
65
|
+
let n = t(), r = s(e.effectiveSalesBegin, e.salesBegin, e.salesStart, e.saleBegin, e.onSaleStart, e.saleStartDate), o = s(e.effectiveSalesEnd, e.salesEnd, e.saleEnd, e.onSaleEnd, e.saleEndDate), l = a(r), u = a(o);
|
|
66
|
+
if (!i(r) && !l || !i(o) && !u || l && c(l, n) > 0 || u && c(u, n) < 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(w) : !1;
|
|
72
72
|
}
|
|
73
73
|
//#endregion
|
|
74
74
|
//#region node_modules/@getmicdrop/svelte-components/dist/errors/classes/NotFoundError.js
|
|
75
|
-
var
|
|
75
|
+
var T = class extends r {
|
|
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", {
|
|
@@ -85,16 +85,16 @@ var D = class extends l {
|
|
|
85
85
|
}), this.name = "NotFoundError", this.resourceType = e, this.resourceId = t;
|
|
86
86
|
}
|
|
87
87
|
getUserMessage(e) {
|
|
88
|
-
return
|
|
88
|
+
return u(e)?.fromCode?.(this.code) || o(this.resourceType.toLowerCase());
|
|
89
89
|
}
|
|
90
|
-
},
|
|
91
|
-
async function
|
|
90
|
+
}, E = e("VC");
|
|
91
|
+
async function D(e, t) {
|
|
92
92
|
try {
|
|
93
93
|
if (!t || !t.trim()) return {
|
|
94
94
|
valid: !1,
|
|
95
95
|
error: "Promo code is required"
|
|
96
96
|
};
|
|
97
|
-
let n = encodeURIComponent(t.trim()), r = await
|
|
97
|
+
let n = encodeURIComponent(t.trim()), r = await _(`/promo-codes/validate/${e}/${n}`);
|
|
98
98
|
if (!r.success) return r.statusCode === 404 ? {
|
|
99
99
|
valid: !1,
|
|
100
100
|
error: "Invalid promo code"
|
|
@@ -115,31 +115,31 @@ async function re(e, t) {
|
|
|
115
115
|
applyToTicketIds: i.applyToTicketIds
|
|
116
116
|
};
|
|
117
117
|
} catch (e) {
|
|
118
|
-
return
|
|
118
|
+
return E.error("Error validating promo code:", e), {
|
|
119
119
|
valid: !1,
|
|
120
120
|
error: "Network error validating code"
|
|
121
121
|
};
|
|
122
122
|
}
|
|
123
123
|
}
|
|
124
|
-
async function
|
|
124
|
+
async function oe(e) {
|
|
125
125
|
try {
|
|
126
|
-
let t = await
|
|
126
|
+
let t = await _(`/promo-codes/check/${e}`);
|
|
127
127
|
return !t.success || t.data.hasPromoCodes === !0;
|
|
128
128
|
} catch (e) {
|
|
129
|
-
return
|
|
129
|
+
return E.error("Error checking promo codes availability:", e), !0;
|
|
130
130
|
}
|
|
131
131
|
}
|
|
132
|
-
async function
|
|
132
|
+
async function O(e, t, n) {
|
|
133
133
|
try {
|
|
134
134
|
let r = { promoCode: t };
|
|
135
135
|
n && Object.keys(n).length > 0 && (r.productQuantities = n);
|
|
136
|
-
let i = await
|
|
136
|
+
let i = await h(`${p()}/cart/${e}/apply-promo`, r);
|
|
137
137
|
return i.success ? { success: !0 } : {
|
|
138
138
|
success: !1,
|
|
139
139
|
error: i.error || "Failed to apply promo code"
|
|
140
140
|
};
|
|
141
141
|
} catch (e) {
|
|
142
|
-
return
|
|
142
|
+
return E.error("Error applying promo code:", e), {
|
|
143
143
|
success: !1,
|
|
144
144
|
error: "Network error applying code"
|
|
145
145
|
};
|
|
@@ -166,7 +166,7 @@ function j(e) {
|
|
|
166
166
|
notFound: !0
|
|
167
167
|
};
|
|
168
168
|
}
|
|
169
|
-
function
|
|
169
|
+
function se(e, t) {
|
|
170
170
|
return e.ok ? e.data : t;
|
|
171
171
|
}
|
|
172
172
|
//#endregion
|
|
@@ -176,7 +176,7 @@ var M = "/api/v2/public", N = "/api/orders/v2/public", P = "/api/orders/v2", F =
|
|
|
176
176
|
//#endregion
|
|
177
177
|
//#region src/lib/api/events.ts
|
|
178
178
|
var I = e("VC"), L = /* @__PURE__ */ new Map();
|
|
179
|
-
async function
|
|
179
|
+
async function ce(e, t = fetch, n) {
|
|
180
180
|
let r = n ? `${e}:pw` : String(e);
|
|
181
181
|
if (t === fetch) {
|
|
182
182
|
let e = L.get(r);
|
|
@@ -184,7 +184,7 @@ async function se(e, t = fetch, n) {
|
|
|
184
184
|
}
|
|
185
185
|
let i = (async () => {
|
|
186
186
|
try {
|
|
187
|
-
let r = await t(n ? `${
|
|
187
|
+
let r = await t(n ? `${m()}/events/${e}?password=${encodeURIComponent(n)}` : `${m()}/events/${e}`);
|
|
188
188
|
if (!r.ok) return r.status === 404 ? j("event_not_found") : (I.error(`Failed to fetch event details: ${r.status}`), A("event_fetch_failed"));
|
|
189
189
|
let i = await r.json();
|
|
190
190
|
return i ? k(i) : j("event_not_found");
|
|
@@ -196,76 +196,76 @@ async function se(e, t = fetch, n) {
|
|
|
196
196
|
L.get(r) === i && L.delete(r);
|
|
197
197
|
})), i;
|
|
198
198
|
}
|
|
199
|
-
async function
|
|
200
|
-
let r = await
|
|
199
|
+
async function R(e, t = fetch, n) {
|
|
200
|
+
let r = await ce(e, t, n);
|
|
201
201
|
return r.ok ? r.data : null;
|
|
202
202
|
}
|
|
203
|
-
async function
|
|
203
|
+
async function z(e, t, n = (e) => e) {
|
|
204
204
|
try {
|
|
205
|
-
let r = await
|
|
205
|
+
let r = await g(e);
|
|
206
206
|
return r ? k(n(r)) : (I.error(`Failed to load (${t}): network or server error`), A(t));
|
|
207
207
|
} catch (e) {
|
|
208
208
|
return I.error(`Error loading (${t}):`, e), A(t);
|
|
209
209
|
}
|
|
210
210
|
}
|
|
211
|
-
function
|
|
211
|
+
function B(e) {
|
|
212
212
|
return Array.isArray(e) ? e : [];
|
|
213
213
|
}
|
|
214
|
-
async function
|
|
214
|
+
async function V(e, t) {
|
|
215
215
|
let n = t?.trim(), r = n ? `?promoCode=${encodeURIComponent(n)}` : "";
|
|
216
|
-
return
|
|
216
|
+
return z(`${m()}/tickets/event/${e}${r}`, "tickets_fetch_failed", B);
|
|
217
217
|
}
|
|
218
|
-
async function
|
|
219
|
-
return
|
|
218
|
+
async function H(e, t) {
|
|
219
|
+
return se(await V(e, t), []);
|
|
220
220
|
}
|
|
221
|
-
function
|
|
221
|
+
function U(e) {
|
|
222
222
|
return Array.isArray(e) ? e : Array.isArray(e.events) ? e.events : [];
|
|
223
223
|
}
|
|
224
|
-
var
|
|
225
|
-
function
|
|
224
|
+
var W = /* @__PURE__ */ new Map();
|
|
225
|
+
function G(e, t, n) {
|
|
226
226
|
if (!n?.fresh) {
|
|
227
|
-
let t =
|
|
227
|
+
let t = W.get(e);
|
|
228
228
|
if (t) return t;
|
|
229
229
|
}
|
|
230
|
-
let r =
|
|
231
|
-
return
|
|
232
|
-
|
|
230
|
+
let r = z(e, t, (e) => U(e));
|
|
231
|
+
return W.set(e, r), r.finally(() => {
|
|
232
|
+
W.get(e) === r && W.delete(e);
|
|
233
233
|
}), r;
|
|
234
234
|
}
|
|
235
|
-
async function G(e, t, n, r) {
|
|
236
|
-
return W(`${h()}/events/venue/${e}/month/${t}/${n}`, "month_events_fetch_failed", r);
|
|
237
|
-
}
|
|
238
235
|
async function le(e, t, n, r) {
|
|
239
|
-
return
|
|
236
|
+
return G(`${m()}/events/venue/${e}/month/${t}/${n}`, "month_events_fetch_failed", r);
|
|
240
237
|
}
|
|
241
|
-
async function ue(e, t) {
|
|
242
|
-
return
|
|
238
|
+
async function ue(e, t, n, r) {
|
|
239
|
+
return G(`${m()}/events/organization/${e}/month/${t}/${n}`, "org_month_events_fetch_failed", r);
|
|
243
240
|
}
|
|
244
241
|
async function de(e, t) {
|
|
245
|
-
|
|
246
|
-
return n.ok ? n.data : null;
|
|
242
|
+
return z(`${m()}/series/${e}/occurrences?venueId=${t}`, "series_cta_fetch_failed");
|
|
247
243
|
}
|
|
248
244
|
async function fe(e, t) {
|
|
245
|
+
let n = await de(e, t);
|
|
246
|
+
return n.ok ? n.data : null;
|
|
247
|
+
}
|
|
248
|
+
async function pe(e, t) {
|
|
249
249
|
try {
|
|
250
|
-
let n = t ? `?slug=${encodeURIComponent(t)}` : "", r = await
|
|
251
|
-
if (!r || !r.type) throw new
|
|
250
|
+
let n = t ? `?slug=${encodeURIComponent(t)}` : "", r = await g(`${m()}/resolve/${encodeURIComponent(String(e))}${n}`);
|
|
251
|
+
if (!r || !r.type) throw new T("entity", String(e));
|
|
252
252
|
return r;
|
|
253
253
|
} catch (e) {
|
|
254
254
|
return I.error("Error resolving public entity:", e), null;
|
|
255
255
|
}
|
|
256
256
|
}
|
|
257
|
-
async function
|
|
257
|
+
async function me(e, t) {
|
|
258
258
|
try {
|
|
259
|
-
let n = t ? `${
|
|
260
|
-
if (!r) throw new
|
|
259
|
+
let n = t ? `${m()}/collections/${e}?password=${encodeURIComponent(t)}` : `${m()}/collections/${e}`, r = await g(n);
|
|
260
|
+
if (!r) throw new T("collection", String(e));
|
|
261
261
|
return r;
|
|
262
262
|
} catch (e) {
|
|
263
263
|
return I.error("Error fetching collection:", e), null;
|
|
264
264
|
}
|
|
265
265
|
}
|
|
266
|
-
async function
|
|
266
|
+
async function he(e, t) {
|
|
267
267
|
try {
|
|
268
|
-
let n = await
|
|
268
|
+
let n = await g(`${m()}/events/${e}/check-password`, {
|
|
269
269
|
method: "POST",
|
|
270
270
|
headers: { "Content-Type": "application/json" },
|
|
271
271
|
body: JSON.stringify({ password: t })
|
|
@@ -278,10 +278,10 @@ async function me(e, t) {
|
|
|
278
278
|
//#endregion
|
|
279
279
|
//#region src/lib/api/venues.ts
|
|
280
280
|
var K = e("VC");
|
|
281
|
-
async function
|
|
281
|
+
async function ge(e) {
|
|
282
282
|
try {
|
|
283
283
|
if (!e) return K.warn("getVenue called without venueId"), null;
|
|
284
|
-
let t = await
|
|
284
|
+
let t = await _(`/venues/${e}`);
|
|
285
285
|
return t.success ? t.data ?? null : (K.error(`Failed to fetch venue: ${t.statusCode}`), null);
|
|
286
286
|
} catch (e) {
|
|
287
287
|
return K.error("Error fetching venue:", e), null;
|
|
@@ -292,35 +292,35 @@ async function he(e) {
|
|
|
292
292
|
function q(e, t) {
|
|
293
293
|
return e == null || t(e);
|
|
294
294
|
}
|
|
295
|
-
function
|
|
295
|
+
function _e(e) {
|
|
296
296
|
if (typeof e != "object" || !e) return !1;
|
|
297
297
|
let t = e;
|
|
298
298
|
return t.valid === !0 && Number.isInteger(t.appliedAmount) && typeof t.remainingTotal == "number" && Number.isFinite(t.remainingTotal) && q(t.giftCardCode, (e) => typeof e == "string") && q(t.giftCardBalance, (e) => typeof e == "number" && Number.isFinite(e)) && q(t.fullyCoveredByCard, (e) => typeof e == "boolean");
|
|
299
299
|
}
|
|
300
|
-
var
|
|
301
|
-
function
|
|
302
|
-
if (!
|
|
300
|
+
var ve = "We couldn't apply that gift card. Please try again.";
|
|
301
|
+
function ye(e) {
|
|
302
|
+
if (!_e(e)) return {
|
|
303
303
|
valid: !1,
|
|
304
|
-
error:
|
|
304
|
+
error: ve
|
|
305
305
|
};
|
|
306
|
-
let t = e,
|
|
306
|
+
let t = e, r = l(n(t.appliedAmount)), i = t.remainingTotal, a = t.fullyCoveredByCard ?? i <= 0, o = !a;
|
|
307
307
|
return {
|
|
308
308
|
valid: !0,
|
|
309
309
|
giftCardCode: t.giftCardCode ?? void 0,
|
|
310
|
-
giftCardAmount:
|
|
310
|
+
giftCardAmount: r,
|
|
311
311
|
giftCardBalance: t.giftCardBalance ?? void 0,
|
|
312
|
-
paymentType:
|
|
313
|
-
stripeAmount:
|
|
314
|
-
orderTotal:
|
|
315
|
-
requiresStripe:
|
|
312
|
+
paymentType: a ? "gift_card_only" : "split",
|
|
313
|
+
stripeAmount: i,
|
|
314
|
+
orderTotal: r + i,
|
|
315
|
+
requiresStripe: o
|
|
316
316
|
};
|
|
317
317
|
}
|
|
318
318
|
//#endregion
|
|
319
319
|
//#region src/lib/api/gift-cards.ts
|
|
320
320
|
var J = e("VC");
|
|
321
|
-
async function
|
|
321
|
+
async function be(e, t) {
|
|
322
322
|
try {
|
|
323
|
-
let n = await
|
|
323
|
+
let n = await h(`${p()}/cart/${e}/apply-gift-card`, { giftCardCode: t });
|
|
324
324
|
if (!n.success) return n.statusCode === 429 ? {
|
|
325
325
|
valid: !1,
|
|
326
326
|
error: "Too many attempts. Please wait a moment and try again."
|
|
@@ -328,7 +328,7 @@ async function ye(e, t) {
|
|
|
328
328
|
valid: !1,
|
|
329
329
|
error: n.error || "Invalid gift card code"
|
|
330
330
|
});
|
|
331
|
-
let r =
|
|
331
|
+
let r = ye(n.data);
|
|
332
332
|
return r.valid || J.error("Apply gift card returned an unusable payload:", n.data), r;
|
|
333
333
|
} catch (e) {
|
|
334
334
|
return J.error("applyGiftCard error:", e), {
|
|
@@ -337,9 +337,9 @@ async function ye(e, t) {
|
|
|
337
337
|
};
|
|
338
338
|
}
|
|
339
339
|
}
|
|
340
|
-
async function
|
|
340
|
+
async function xe(e, t) {
|
|
341
341
|
try {
|
|
342
|
-
let n = t?.giftCardId ? { giftCardId: t.giftCardId } : t?.code ? { giftCardCode: t.code } : null, r = await f(`${
|
|
342
|
+
let n = t?.giftCardId ? { giftCardId: t.giftCardId } : t?.code ? { giftCardCode: t.code } : null, r = await f(`${p()}/cart/${e}/gift-card`, n ? { body: JSON.stringify(n) } : void 0);
|
|
343
343
|
if (!r.success) return J.error("Remove gift card failed:", r.error), {
|
|
344
344
|
success: !1,
|
|
345
345
|
error: r.error || "Failed to remove gift card"
|
|
@@ -356,9 +356,10 @@ async function be(e, t) {
|
|
|
356
356
|
};
|
|
357
357
|
}
|
|
358
358
|
}
|
|
359
|
-
async function
|
|
359
|
+
async function Y(e, t, n) {
|
|
360
|
+
let r = ee(n);
|
|
360
361
|
try {
|
|
361
|
-
let n = await
|
|
362
|
+
let n = await h(`${p()}/cart/${e}/complete-gift-card-payment`, {
|
|
362
363
|
customerName: d(t.firstName, t.lastName),
|
|
363
364
|
customerEmail: t.email,
|
|
364
365
|
firstName: t.firstName,
|
|
@@ -367,7 +368,8 @@ async function xe(e, t) {
|
|
|
367
368
|
phoneNumber: t.phoneNumber || null,
|
|
368
369
|
questionAnswer: t.questionAnswer || "",
|
|
369
370
|
mailingList: t.mailingList || !1,
|
|
370
|
-
attribution:
|
|
371
|
+
attribution: v(),
|
|
372
|
+
...r ? { locale: r } : {}
|
|
371
373
|
});
|
|
372
374
|
return n.success ? {
|
|
373
375
|
success: !0,
|
|
@@ -386,36 +388,30 @@ async function xe(e, t) {
|
|
|
386
388
|
}
|
|
387
389
|
//#endregion
|
|
388
390
|
//#region src/lib/api/waitlist.ts
|
|
389
|
-
var
|
|
390
|
-
|
|
391
|
-
event_not_found: "Event not found",
|
|
392
|
-
invalid_phone: "Please enter a valid phone number",
|
|
393
|
-
already_purchased: "You have already purchased tickets for this event",
|
|
394
|
-
phone_already_registered: "This phone number is already on the waitlist"
|
|
395
|
-
};
|
|
396
|
-
async function Ce(e, t, n = null, r = !1) {
|
|
391
|
+
var X = e("VC");
|
|
392
|
+
async function Se(e, t, n = null, r = !1) {
|
|
397
393
|
try {
|
|
398
394
|
let i = { email: t };
|
|
399
395
|
n && r && (i.phone = n, i.smsOptIn = !0);
|
|
400
|
-
let a = await
|
|
396
|
+
let a = await h(`/events/${e}/waitlist`, i);
|
|
401
397
|
return a.success ? {
|
|
402
398
|
success: !0,
|
|
403
399
|
updated: a.data?.updated,
|
|
404
400
|
position: a.data?.position
|
|
405
|
-
} : (
|
|
401
|
+
} : (X.error("Join waitlist failed:", a.error), {
|
|
406
402
|
success: !1,
|
|
407
|
-
|
|
403
|
+
errorCode: a.error || "join_failed"
|
|
408
404
|
});
|
|
409
405
|
} catch (e) {
|
|
410
|
-
return
|
|
406
|
+
return X.error("joinWaitlist error:", e), {
|
|
411
407
|
success: !1,
|
|
412
|
-
|
|
408
|
+
errorCode: "network_error"
|
|
413
409
|
};
|
|
414
410
|
}
|
|
415
411
|
}
|
|
416
|
-
async function
|
|
412
|
+
async function Ce(e, t) {
|
|
417
413
|
try {
|
|
418
|
-
let n = await
|
|
414
|
+
let n = await h(`/checkout/validate-token/${e}`, { email: t });
|
|
419
415
|
return n.success ? {
|
|
420
416
|
valid: !0,
|
|
421
417
|
eventId: n.data?.eventId ?? 0,
|
|
@@ -426,42 +422,42 @@ async function we(e, t) {
|
|
|
426
422
|
errorCode: n.error
|
|
427
423
|
};
|
|
428
424
|
} catch (e) {
|
|
429
|
-
return
|
|
425
|
+
return X.error("validateWaitlistToken error:", e), {
|
|
430
426
|
valid: !1,
|
|
431
427
|
eventId: 0,
|
|
432
428
|
errorCode: "invalid_token"
|
|
433
429
|
};
|
|
434
430
|
}
|
|
435
431
|
}
|
|
436
|
-
async function
|
|
432
|
+
async function we(e, t) {
|
|
437
433
|
try {
|
|
438
|
-
let n = await
|
|
434
|
+
let n = await h(`/waitlist/requeue/${e}`, { email: t });
|
|
439
435
|
return n.success ? { success: !0 } : {
|
|
440
436
|
success: !1,
|
|
441
437
|
errorCode: n.error
|
|
442
438
|
};
|
|
443
439
|
} catch (e) {
|
|
444
|
-
return
|
|
440
|
+
return X.error("requeueWaitlistToFront error:", e), {
|
|
445
441
|
success: !1,
|
|
446
442
|
errorCode: "internal_error"
|
|
447
443
|
};
|
|
448
444
|
}
|
|
449
445
|
}
|
|
450
|
-
async function
|
|
446
|
+
async function Te(e) {
|
|
451
447
|
let t = {
|
|
452
448
|
waitlistEnabled: !1,
|
|
453
449
|
soldOut: !1,
|
|
454
450
|
gated: !1
|
|
455
451
|
};
|
|
456
452
|
try {
|
|
457
|
-
let n = await
|
|
453
|
+
let n = await _(`/events/${e}/waitlist/status`);
|
|
458
454
|
return n.success ? {
|
|
459
455
|
waitlistEnabled: !!n.data?.waitlistEnabled,
|
|
460
456
|
soldOut: !!n.data?.soldOut,
|
|
461
457
|
gated: !!n.data?.gated
|
|
462
458
|
} : t;
|
|
463
459
|
} catch (e) {
|
|
464
|
-
return
|
|
460
|
+
return X.error("getWaitlistStatus error:", e), t;
|
|
465
461
|
}
|
|
466
462
|
}
|
|
467
463
|
//#endregion
|
|
@@ -571,4 +567,4 @@ var Ee = {
|
|
|
571
567
|
green: $.green[500]
|
|
572
568
|
};
|
|
573
569
|
//#endregion
|
|
574
|
-
export {
|
|
570
|
+
export { te as A, O as C, w as D, ae as E, ne as O, pe as S, D as T, V as _, Oe as a, le as b, we as c, Y as d, xe as f, H as g, R as h, Q as i, re as j, C as k, Ce as l, he as m, De as n, Te as o, ge as p, Z as r, Se as s, $ as t, be as u, me as v, oe as w, ue as x, fe as y };
|