@getmicdrop/venue-calendar 4.3.119 → 4.3.121
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +818 -818
- package/dist/{AddOnCard-BGFpF6uw.js → AddOnCard-jj59e855.js} +5 -5
- package/dist/{ArrowLeftIcon-pPaJkbnp.js → ArrowLeftIcon-t-CY0sbi.js} +1 -1
- package/dist/{BlockPlaceholder-BgLtwJnm.js → BlockPlaceholder-BmEZ68_q.js} +1 -1
- package/dist/Calendar-hxcQBkTF.js +463 -0
- package/dist/{CalendarFoundryView-CZ36wO24.js → CalendarFoundryView-CSAKDe-F.js} +19 -19
- package/dist/{CalendarIcon-C_6MSRyE.js → CalendarIcon-B5JWs0gm.js} +1 -1
- package/dist/{CartView-9YSoRvTw.js → CartView-CF2y1JDa.js} +719 -716
- package/dist/{CheckIcon-sr8D0z-b.js → CheckIcon-BSwoGox7.js} +1 -1
- package/dist/{Checkout-BLkYIKoR.js → Checkout-2h2K3-bE.js} +378 -378
- package/dist/{Checkout-BS3r4Qii.js → Checkout-BFu5dTw_.js} +328 -328
- package/dist/{CheckoutTimer-DY1NKJXP.js → CheckoutTimer-Bpt5gPyA.js} +2 -2
- package/dist/{ChevronDownIcon-Co6rRQp-.js → ChevronDownIcon-CVZ0usBx.js} +1 -1
- package/dist/{CloseIcon-DpRE5O8y.js → CloseIcon-DUnvWXUY.js} +1 -1
- package/dist/CollectionView-XdNMvMtn.js +141 -0
- package/dist/{Event-DUq4tYBE.js → Event-B_9T21du.js} +684 -680
- package/dist/EventPage-BMnKpciU.js +1201 -0
- package/dist/{Input-CsHb9Z8e.js → Input-BXZmvQ0p.js} +1 -1
- package/dist/{LocationIcon-Dxk7snUC.js → LocationIcon-E-7CQh4E.js} +1 -1
- package/dist/{PasswordInput-BlL0w_yr.js → PasswordInput-DzXNIwRc.js} +1 -1
- package/dist/{RecommendationsRail-Dq9t0T02.js → RecommendationsRail-DrzM8h2r.js} +124 -124
- package/dist/{ScarcityBadge-Bj_YMxz4.js → ScarcityBadge-DjzrzvId.js} +4 -4
- package/dist/{SeriesPage-CaPTQRSo.js → SeriesPage-Ds_FEEZW.js} +2 -2
- package/dist/{Spinner-BgdjQygI.js → Spinner-B2rdbspc.js} +1 -1
- package/dist/{Success-tXgS0BXp.js → Success-Dkak0iM9.js} +201 -201
- package/dist/{TagIcon-Kq7_bapx.js → TagIcon-BY8tK_qA.js} +1 -1
- package/dist/ViewTicketsEmbed-B_fqalQh.js +660 -0
- package/dist/{WarningCircleIcon-BdbAYYi4.js → WarningCircleIcon-C5Lc7qkF.js} +1 -1
- package/dist/{WarningTriIcon-D8otatZe.js → WarningTriIcon-BM8qc9xx.js} +1 -1
- package/dist/api/api.cjs +1 -1
- package/dist/api/api.mjs +258 -252
- package/dist/api/cart-addons.d.ts +2 -1
- package/dist/api/checkout-availability.d.ts +2 -25
- package/dist/api/client.d.ts +4 -7
- package/dist/api/events.d.ts +23 -22
- package/dist/api/gift-cards.d.ts +7 -6
- package/dist/api/orders.d.ts +13 -12
- package/dist/api/promo.d.ts +5 -4
- package/dist/api/surge-queue.d.ts +5 -34
- package/dist/api/venues.d.ts +5 -4
- package/dist/api/waitlist.d.ts +5 -9
- package/dist/{api-DG7ztpYi.js → api-BEYkGabB.js} +174 -169
- package/dist/{copyToClipboard-DSangJpP.js → copyToClipboard-F-akSgaF.js} +1 -1
- package/dist/{createErrorGate.svelte-CEBpRAmr.js → createErrorGate.svelte-CEGaIQeI.js} +1 -1
- package/dist/{datetime-YTw6PkGP.js → datetime-BnKG6Hjm.js} +1 -1
- package/dist/{de-CbwqVvg6.js → de-BHcAXwnM.js} +0 -1
- package/dist/{defaultLabels-CsRGNP7f.js → defaultLabels-BbNEEsF7.js} +0 -1
- package/dist/{defaults-UDvnrGu0.js → defaults-CgsFJvJ2.js} +2 -2
- package/dist/{es-Dxqulvec.js → es-DZ3yceh-.js} +0 -1
- package/dist/{event-CW18bU9h.js → event-DfqUhl5j.js} +1 -1
- package/dist/{event-transform-CyRMeKW_.js → event-transform-Bk1IoYh5.js} +4 -4
- package/dist/{eventStatusStream-Cf7PaLka.js → eventStatusStream-CE0PwO0c.js} +9 -9
- package/dist/{fr-0aCE52FE.js → fr-Dyi163Vk.js} +0 -1
- package/dist/{href-yqxAPbkW.js → href-CfWGAmkP.js} +3 -3
- package/dist/i18n-B705OXZp.js +28 -0
- package/dist/{i18n-MF3q-UBI.js → i18n-BoMUWcCq.js} +4 -4
- package/dist/{id-7ClY2Dwb.js → id-DvFRZVAm.js} +0 -1
- package/dist/{it-z-heX6Hy.js → it-Bh05tcLv.js} +0 -1
- package/dist/{ja-ecBzr5l9.js → ja-CU4PQS4j.js} +0 -1
- package/dist/{ko-Blnq1Wc_.js → ko-DDk6EdWm.js} +0 -1
- package/dist/locales/4.3.121/main/de.js +1 -0
- package/dist/locales/4.3.121/main/es.js +1 -0
- package/dist/locales/4.3.121/main/fr.js +1 -0
- package/dist/locales/4.3.121/main/id.js +1 -0
- package/dist/locales/4.3.121/main/it.js +1 -0
- package/dist/locales/4.3.121/main/ja.js +1 -0
- package/dist/locales/4.3.121/main/ko.js +1 -0
- package/dist/locales/4.3.121/main/nl.js +1 -0
- package/dist/locales/4.3.121/main/pl.js +1 -0
- package/dist/locales/4.3.121/main/pt-br.js +1 -0
- package/dist/locales/4.3.121/main/tr.js +1 -0
- package/dist/locales/4.3.121/main/zh.js +1 -0
- package/dist/{nl-Bm2Lee3j.js → nl-DOSKYHSx.js} +0 -1
- package/dist/{pixels-BAPQbj_Y.js → pixels-Bu5-BISs.js} +8 -8
- package/dist/{pl-DIp-gYhF.js → pl-CkLEymA2.js} +0 -1
- package/dist/{pt-br-BmcVsgbQ.js → pt-br-BHuCQSM-.js} +0 -1
- package/dist/{serverTotals-D57U4Nju.js → serverTotals-B8SJCzxE.js} +1 -1
- package/dist/{showcase-state-options-zfQoPg37.js → showcase-state-options-KO_TYk3I.js} +1 -1
- package/dist/{to-event-card-props-Dn1eDOiJ.js → to-event-card-props-DYIfPN8e.js} +9 -13
- package/dist/{tr-BshxS2DN.js → tr-Bvc34ODh.js} +0 -1
- package/dist/{utils-CdNe7KGe.js → utils-NMx3aPDk.js} +82 -78
- package/dist/venue-calendar.css +1 -1
- package/dist/venue-calendar.es.js +1445 -1445
- package/dist/venue-calendar.iife.js +31 -31
- package/dist/venue-calendar.umd.js +52 -52
- package/dist/{orders-BWVwv3P0.js → widget-key-context-D2zj4sp5.js} +221 -213
- package/dist/{zh-B06ZsUNX.js → zh-K0hOzZ3G.js} +0 -1
- package/package.json +1 -1
- package/src/lib/theme.js +222 -222
- package/dist/Calendar-S2Es6EKK.js +0 -486
- package/dist/CollectionView-DyFDlCmo.js +0 -138
- package/dist/EventPage-m5SlifRu.js +0 -1200
- package/dist/ViewTicketsEmbed-BnuypZ1H.js +0 -660
- package/dist/i18n-B-AwhAMH.js +0 -28
- package/dist/locales/4.3.119/main/de.js +0 -1
- package/dist/locales/4.3.119/main/es.js +0 -1
- package/dist/locales/4.3.119/main/fr.js +0 -1
- package/dist/locales/4.3.119/main/id.js +0 -1
- package/dist/locales/4.3.119/main/it.js +0 -1
- package/dist/locales/4.3.119/main/ja.js +0 -1
- package/dist/locales/4.3.119/main/ko.js +0 -1
- package/dist/locales/4.3.119/main/nl.js +0 -1
- package/dist/locales/4.3.119/main/pl.js +0 -1
- package/dist/locales/4.3.119/main/pt-br.js +0 -1
- package/dist/locales/4.3.119/main/tr.js +0 -1
- package/dist/locales/4.3.119/main/zh.js +0 -1
- /package/dist/locales/{4.3.119 → 4.3.121}/flow/de.js +0 -0
- /package/dist/locales/{4.3.119 → 4.3.121}/flow/es.js +0 -0
- /package/dist/locales/{4.3.119 → 4.3.121}/flow/fr.js +0 -0
- /package/dist/locales/{4.3.119 → 4.3.121}/flow/id.js +0 -0
- /package/dist/locales/{4.3.119 → 4.3.121}/flow/it.js +0 -0
- /package/dist/locales/{4.3.119 → 4.3.121}/flow/ja.js +0 -0
- /package/dist/locales/{4.3.119 → 4.3.121}/flow/ko.js +0 -0
- /package/dist/locales/{4.3.119 → 4.3.121}/flow/nl.js +0 -0
- /package/dist/locales/{4.3.119 → 4.3.121}/flow/pl.js +0 -0
- /package/dist/locales/{4.3.119 → 4.3.121}/flow/pt-br.js +0 -0
- /package/dist/locales/{4.3.119 → 4.3.121}/flow/tr.js +0 -0
- /package/dist/locales/{4.3.119 → 4.3.121}/flow/zh.js +0 -0
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { g as e } from "./sizing-B7ixYndz.js";
|
|
2
|
-
import { D as t, y as n } from "./datetime-
|
|
3
|
-
import { A as r, L as i, _ as a, c as o, g as s, l as c, v as l, x as u } from "./defaultLabels-
|
|
2
|
+
import { D as t, y as n } from "./datetime-BnKG6Hjm.js";
|
|
3
|
+
import { A as r, L as i, _ as a, c as o, g as s, l as c, v as l, x as u } from "./defaultLabels-BbNEEsF7.js";
|
|
4
4
|
import { n as d, r as f } from "./Button-VUB2WJ88.js";
|
|
5
|
-
import {
|
|
5
|
+
import { B as p, C as ee, F as m, G as h, I as g, L as _, U as v, V as y, d as te, q as b } from "./widget-key-context-D2zj4sp5.js";
|
|
6
6
|
//#region node_modules/@getmicdrop/svelte-components/dist/utils/liveAnnouncer.js
|
|
7
|
-
var
|
|
8
|
-
function
|
|
9
|
-
return
|
|
7
|
+
var x = null;
|
|
8
|
+
function S() {
|
|
9
|
+
return x && document.body.contains(x) ? x : (x = document.createElement("div"), x.id = "a11y-live-region", x.setAttribute("role", "status"), x.setAttribute("aria-live", "polite"), x.setAttribute("aria-atomic", "true"), x.className = "sr-only", Object.assign(x.style, {
|
|
10
10
|
position: "absolute",
|
|
11
11
|
width: "1px",
|
|
12
12
|
height: "1px",
|
|
@@ -16,54 +16,54 @@ function re() {
|
|
|
16
16
|
clip: "rect(0, 0, 0, 0)",
|
|
17
17
|
whiteSpace: "nowrap",
|
|
18
18
|
border: "0"
|
|
19
|
-
}), document.body.appendChild(
|
|
19
|
+
}), document.body.appendChild(x), x);
|
|
20
20
|
}
|
|
21
|
-
function
|
|
21
|
+
function C(e, t = {}) {
|
|
22
22
|
if (typeof document > "u") return;
|
|
23
|
-
let { politeness: n = "polite", atomic: r = !0, delay: i = 100 } = t, a =
|
|
23
|
+
let { politeness: n = "polite", atomic: r = !0, delay: i = 100 } = t, a = S();
|
|
24
24
|
a.setAttribute("aria-live", n), a.setAttribute("aria-atomic", String(r)), a.textContent = "", setTimeout(() => {
|
|
25
25
|
typeof document > "u" || !a.isConnected || (a.textContent = e);
|
|
26
26
|
}, i);
|
|
27
27
|
}
|
|
28
|
-
function
|
|
28
|
+
function ne(e = 500) {
|
|
29
29
|
let t = null;
|
|
30
30
|
return (n, r) => {
|
|
31
31
|
t && clearTimeout(t), t = setTimeout(() => {
|
|
32
|
-
|
|
32
|
+
C(n, r), t = null;
|
|
33
33
|
}, e);
|
|
34
34
|
};
|
|
35
35
|
}
|
|
36
36
|
//#endregion
|
|
37
37
|
//#region node_modules/@getmicdrop/svelte-components/dist/transforms/ticket.js
|
|
38
|
-
var
|
|
38
|
+
var w = {
|
|
39
39
|
EVERYWHERE: 0,
|
|
40
40
|
ONLINE_ONLY: 1,
|
|
41
41
|
BOX_OFFICE_ONLY: 2
|
|
42
|
-
},
|
|
42
|
+
}, T = {
|
|
43
43
|
VISIBLE: 0,
|
|
44
44
|
HIDDEN: 1,
|
|
45
45
|
PROMO_ONLY: 2
|
|
46
46
|
};
|
|
47
|
-
function
|
|
47
|
+
function E(e) {
|
|
48
48
|
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;
|
|
49
49
|
}
|
|
50
|
-
function
|
|
50
|
+
function D(e, t) {
|
|
51
51
|
return e.totalCapacity ?? e.quantity ?? t;
|
|
52
52
|
}
|
|
53
|
-
function
|
|
53
|
+
function re(e) {
|
|
54
54
|
let t = f(), n = a(e.effectiveSalesBegin, e.salesBegin, e.saleStartDate) ?? null, r = a(e.effectiveSalesEnd, e.salesEnd, e.saleEndDate) ?? null, i = u(n), o = u(r);
|
|
55
55
|
if (!l(n) && !i) return "scheduled";
|
|
56
56
|
if (!l(r) && !o) return "sales_ended";
|
|
57
57
|
if (i && s(t, i) < 0) return "scheduled";
|
|
58
58
|
if (o && s(t, o) > 0) return "sales_ended";
|
|
59
59
|
if (e.soldOut === !0) return "sold_out";
|
|
60
|
-
let c =
|
|
60
|
+
let c = E(e), d = D(e, c);
|
|
61
61
|
return c === 0 ? "sold_out" : d > 0 && c / d < .1 ? "low" : "on_sale";
|
|
62
62
|
}
|
|
63
63
|
function ie(e, t = {}) {
|
|
64
64
|
if (!Array.isArray(e)) return [];
|
|
65
65
|
let n = e;
|
|
66
|
-
return t.excludeDoorOnly && (n = n.filter((e) => e.salesChannel !==
|
|
66
|
+
return t.excludeDoorOnly && (n = n.filter((e) => e.salesChannel !== w.BOX_OFFICE_ONLY)), t.publicOnly && (n = n.filter((e) => e.visibility === T.VISIBLE)), n;
|
|
67
67
|
}
|
|
68
68
|
function ae(e) {
|
|
69
69
|
if (!Array.isArray(e) || e.length === 0) return {
|
|
@@ -73,8 +73,8 @@ function ae(e) {
|
|
|
73
73
|
};
|
|
74
74
|
let t = 0, n = 0;
|
|
75
75
|
for (let r of e) {
|
|
76
|
-
let e =
|
|
77
|
-
t += e, n +=
|
|
76
|
+
let e = E(r);
|
|
77
|
+
t += e, n += D(r, e);
|
|
78
78
|
}
|
|
79
79
|
return {
|
|
80
80
|
totalRemaining: t,
|
|
@@ -93,7 +93,7 @@ function se(e) {
|
|
|
93
93
|
return e.availableTickets || e.available_tickets || e.tickets || [];
|
|
94
94
|
}
|
|
95
95
|
function O(e) {
|
|
96
|
-
if (!e || !(e.isHidden === !0 || typeof e.visibility == "number" && e.visibility >=
|
|
96
|
+
if (!e || !(e.isHidden === !0 || typeof e.visibility == "number" && e.visibility >= T.HIDDEN) || e.salesChannel === w.BOX_OFFICE_ONLY) return !1;
|
|
97
97
|
let t = f(), n = a(e.effectiveSalesBegin, e.salesBegin, e.salesStart, e.saleBegin, e.onSaleStart, e.saleStartDate), r = a(e.effectiveSalesEnd, e.salesEnd, e.saleEnd, e.onSaleEnd, e.saleEndDate), i = u(n), o = u(r);
|
|
98
98
|
if (!l(n) && !i || !l(r) && !o || i && s(i, t) > 0 || o && s(o, t) < 0) return !1;
|
|
99
99
|
let c = e.remainingCapacity ?? e.quantityRemaining ?? e.quantity;
|
|
@@ -175,28 +175,28 @@ function ue(e, t) {
|
|
|
175
175
|
let n = (t ?? "").toLowerCase();
|
|
176
176
|
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";
|
|
177
177
|
}
|
|
178
|
-
async function de(e, t) {
|
|
178
|
+
async function de(e, t, n) {
|
|
179
179
|
try {
|
|
180
180
|
if (!t || !t.trim()) return {
|
|
181
181
|
valid: !1,
|
|
182
182
|
error: "Promo code is required"
|
|
183
183
|
};
|
|
184
|
-
let
|
|
185
|
-
if (!
|
|
184
|
+
let r = encodeURIComponent(t.trim()), i = await g(`/promo-codes/validate/${e}/${r}`, { widgetKey: n?.widgetKey });
|
|
185
|
+
if (!i.success) return {
|
|
186
186
|
valid: !1,
|
|
187
|
-
error: ue(
|
|
187
|
+
error: ue(i.statusCode, i.error)
|
|
188
188
|
};
|
|
189
|
-
let
|
|
189
|
+
let a = i.data;
|
|
190
190
|
return {
|
|
191
|
-
valid:
|
|
192
|
-
revealHiddenTickets:
|
|
193
|
-
revealTicketIds:
|
|
194
|
-
provideDiscount:
|
|
195
|
-
discountType:
|
|
196
|
-
amount:
|
|
197
|
-
code:
|
|
198
|
-
appliesToAllTickets:
|
|
199
|
-
applyToTicketIds:
|
|
191
|
+
valid: a.valid ?? !0,
|
|
192
|
+
revealHiddenTickets: a.revealHiddenTickets,
|
|
193
|
+
revealTicketIds: a.revealTicketIds,
|
|
194
|
+
provideDiscount: a.provideDiscount,
|
|
195
|
+
discountType: a.discountType,
|
|
196
|
+
amount: a.discount ?? a.amount,
|
|
197
|
+
code: a.name || a.code || t,
|
|
198
|
+
appliesToAllTickets: a.appliesToAllTickets,
|
|
199
|
+
applyToTicketIds: a.applyToTicketIds
|
|
200
200
|
};
|
|
201
201
|
} catch (e) {
|
|
202
202
|
return M.error("Error validating promo code:", e), {
|
|
@@ -205,22 +205,22 @@ async function de(e, t) {
|
|
|
205
205
|
};
|
|
206
206
|
}
|
|
207
207
|
}
|
|
208
|
-
async function fe(e) {
|
|
208
|
+
async function fe(e, t) {
|
|
209
209
|
try {
|
|
210
|
-
let
|
|
211
|
-
return !
|
|
210
|
+
let n = await g(`/promo-codes/check/${e}`, { widgetKey: t?.widgetKey });
|
|
211
|
+
return !n.success || n.data.hasPromoCodes === !0;
|
|
212
212
|
} catch (e) {
|
|
213
213
|
return M.error("Error checking promo codes availability:", e), !0;
|
|
214
214
|
}
|
|
215
215
|
}
|
|
216
|
-
async function pe(e, t, n) {
|
|
216
|
+
async function pe(e, t, n, r) {
|
|
217
217
|
try {
|
|
218
|
-
let
|
|
219
|
-
n && Object.keys(n).length > 0 && (
|
|
220
|
-
let
|
|
221
|
-
return
|
|
218
|
+
let i = { promoCode: t };
|
|
219
|
+
n && Object.keys(n).length > 0 && (i.productQuantities = n);
|
|
220
|
+
let a = await _(`${p()}/cart/${e}/apply-promo`, i, { widgetKey: r?.widgetKey });
|
|
221
|
+
return a.success ? { success: !0 } : {
|
|
222
222
|
success: !1,
|
|
223
|
-
error:
|
|
223
|
+
error: a.error || "Failed to apply promo code"
|
|
224
224
|
};
|
|
225
225
|
} catch (e) {
|
|
226
226
|
return M.error("Error applying promo code:", e), {
|
|
@@ -260,34 +260,34 @@ var L = "/api/v2/public", R = "/api/orders/v2/public", z = "/api/orders/v2", B =
|
|
|
260
260
|
//#endregion
|
|
261
261
|
//#region src/lib/api/events.ts
|
|
262
262
|
var V = e("VC"), H = /* @__PURE__ */ new Map();
|
|
263
|
-
async function me(e, t = fetch, n) {
|
|
264
|
-
let
|
|
263
|
+
async function me(e, t = fetch, n, r) {
|
|
264
|
+
let i = n ? `${e}:pw` : String(e), a = `${r?.widgetKey ?? ""}|${i}`;
|
|
265
265
|
if (t === fetch) {
|
|
266
|
-
let e = H.get(
|
|
266
|
+
let e = H.get(a);
|
|
267
267
|
if (e) return e;
|
|
268
268
|
}
|
|
269
|
-
let
|
|
269
|
+
let o = (async () => {
|
|
270
270
|
try {
|
|
271
|
-
let
|
|
272
|
-
if (!
|
|
273
|
-
let
|
|
274
|
-
return
|
|
271
|
+
let i = await t(n ? `${y()}/events/${e}?password=${encodeURIComponent(n)}` : `${y()}/events/${e}`, { headers: h(void 0, r?.widgetKey) });
|
|
272
|
+
if (!i.ok) return i.status === 404 ? F("event_not_found") : (V.error(`Failed to fetch event details: ${i.status}`), P("event_fetch_failed"));
|
|
273
|
+
let a = await i.json();
|
|
274
|
+
return a ? N(a) : F("event_not_found");
|
|
275
275
|
} catch (e) {
|
|
276
276
|
return V.error("Error fetching event details:", e), P("event_fetch_failed");
|
|
277
277
|
}
|
|
278
278
|
})();
|
|
279
|
-
return t === fetch && (H.set(
|
|
280
|
-
H.get(
|
|
281
|
-
})),
|
|
279
|
+
return t === fetch && (H.set(a, o), o.finally(() => {
|
|
280
|
+
H.get(a) === o && H.delete(a);
|
|
281
|
+
})), o;
|
|
282
282
|
}
|
|
283
|
-
async function he(e, t = fetch, n) {
|
|
284
|
-
let
|
|
285
|
-
return
|
|
283
|
+
async function he(e, t = fetch, n, r) {
|
|
284
|
+
let i = await me(e, t, n, r);
|
|
285
|
+
return i.ok ? i.data : null;
|
|
286
286
|
}
|
|
287
|
-
async function U(e, t, n = (e) => e) {
|
|
287
|
+
async function U(e, t, n = (e) => e, r) {
|
|
288
288
|
try {
|
|
289
|
-
let
|
|
290
|
-
return
|
|
289
|
+
let i = await v(e, { widgetKey: r?.widgetKey });
|
|
290
|
+
return i ? N(n(i)) : (V.error(`Failed to load (${t}): network or server error`), P(t));
|
|
291
291
|
} catch (e) {
|
|
292
292
|
return V.error(`Error loading (${t}):`, e), P(t);
|
|
293
293
|
}
|
|
@@ -295,72 +295,74 @@ async function U(e, t, n = (e) => e) {
|
|
|
295
295
|
function W(e) {
|
|
296
296
|
return Array.isArray(e) ? e : [];
|
|
297
297
|
}
|
|
298
|
-
async function G(e, t) {
|
|
299
|
-
let
|
|
300
|
-
return U(`${y()}/tickets/event/${e}${
|
|
298
|
+
async function G(e, t, n) {
|
|
299
|
+
let r = t?.trim(), i = r ? `?promoCode=${encodeURIComponent(r)}` : "";
|
|
300
|
+
return U(`${y()}/tickets/event/${e}${i}`, "tickets_fetch_failed", W, n);
|
|
301
301
|
}
|
|
302
|
-
async function ge(e, t) {
|
|
303
|
-
return I(await G(e, t), []);
|
|
302
|
+
async function ge(e, t, n) {
|
|
303
|
+
return I(await G(e, t, n), []);
|
|
304
304
|
}
|
|
305
|
-
async function _e(e) {
|
|
306
|
-
return e ? U(`${y()}/venues/organization/${e}`, "venues_fetch_failed", W) : (V.warn("fetchAllVenues called without orgId"), P("venues_missing_org_id"));
|
|
305
|
+
async function _e(e, t) {
|
|
306
|
+
return e ? U(`${y()}/venues/organization/${e}`, "venues_fetch_failed", W, t) : (V.warn("fetchAllVenues called without orgId"), P("venues_missing_org_id"));
|
|
307
307
|
}
|
|
308
|
-
async function ve(e) {
|
|
309
|
-
return I(await _e(e), []);
|
|
308
|
+
async function ve(e, t) {
|
|
309
|
+
return I(await _e(e, t), []);
|
|
310
310
|
}
|
|
311
311
|
function ye(e) {
|
|
312
312
|
return Array.isArray(e) ? e : Array.isArray(e.events) ? e.events : [];
|
|
313
313
|
}
|
|
314
314
|
var K = /* @__PURE__ */ new Map();
|
|
315
|
-
function q(e, t, n) {
|
|
315
|
+
function q(e, t, n, r) {
|
|
316
|
+
let i = `${r?.widgetKey ?? ""}|${e}`;
|
|
316
317
|
if (!n?.fresh) {
|
|
317
|
-
let
|
|
318
|
-
if (
|
|
318
|
+
let e = K.get(i);
|
|
319
|
+
if (e) return e;
|
|
319
320
|
}
|
|
320
|
-
let
|
|
321
|
-
return K.set(
|
|
322
|
-
K.get(
|
|
323
|
-
}),
|
|
321
|
+
let a = U(e, t, (e) => ye(e), r);
|
|
322
|
+
return K.set(i, a), a.finally(() => {
|
|
323
|
+
K.get(i) === a && K.delete(i);
|
|
324
|
+
}), a;
|
|
324
325
|
}
|
|
325
|
-
async function be(e, t, n, r) {
|
|
326
|
-
return q(`${y()}/events/venue/${e}/month/${t}/${n}`, "month_events_fetch_failed", r);
|
|
326
|
+
async function be(e, t, n, r, i) {
|
|
327
|
+
return q(`${y()}/events/venue/${e}/month/${t}/${n}`, "month_events_fetch_failed", r, i);
|
|
327
328
|
}
|
|
328
|
-
async function xe(e, t, n, r) {
|
|
329
|
-
return q(`${y()}/events/organization/${e}/month/${t}/${n}`, "org_month_events_fetch_failed", r);
|
|
329
|
+
async function xe(e, t, n, r, i) {
|
|
330
|
+
return q(`${y()}/events/organization/${e}/month/${t}/${n}`, "org_month_events_fetch_failed", r, i);
|
|
330
331
|
}
|
|
331
|
-
async function Se(e, t) {
|
|
332
|
-
return U(`${y()}/series/${e}/occurrences?venueId=${t}`, "series_cta_fetch_failed");
|
|
332
|
+
async function Se(e, t, n) {
|
|
333
|
+
return U(`${y()}/series/${e}/occurrences?venueId=${t}`, "series_cta_fetch_failed", void 0, n);
|
|
333
334
|
}
|
|
334
|
-
async function Ce(e, t) {
|
|
335
|
-
let
|
|
336
|
-
return
|
|
335
|
+
async function Ce(e, t, n) {
|
|
336
|
+
let r = await Se(e, t, n);
|
|
337
|
+
return r.ok ? r.data : null;
|
|
337
338
|
}
|
|
338
|
-
async function we(e, t) {
|
|
339
|
+
async function we(e, t, n) {
|
|
339
340
|
try {
|
|
340
|
-
let
|
|
341
|
-
if (!
|
|
342
|
-
return
|
|
341
|
+
let r = t ? `?slug=${encodeURIComponent(t)}` : "", i = await v(`${y()}/resolve/${encodeURIComponent(String(e))}${r}`, { widgetKey: n?.widgetKey });
|
|
342
|
+
if (!i || !i.type) throw new A("entity", String(e));
|
|
343
|
+
return i;
|
|
343
344
|
} catch (e) {
|
|
344
345
|
return V.error("Error resolving public entity:", e), null;
|
|
345
346
|
}
|
|
346
347
|
}
|
|
347
|
-
async function Te(e, t) {
|
|
348
|
+
async function Te(e, t, n) {
|
|
348
349
|
try {
|
|
349
|
-
let
|
|
350
|
-
if (!
|
|
351
|
-
return
|
|
350
|
+
let r = t ? `${y()}/collections/${e}?password=${encodeURIComponent(t)}` : `${y()}/collections/${e}`, i = await v(r, { widgetKey: n?.widgetKey });
|
|
351
|
+
if (!i) throw new A("collection", String(e));
|
|
352
|
+
return i;
|
|
352
353
|
} catch (e) {
|
|
353
354
|
return V.error("Error fetching collection:", e), null;
|
|
354
355
|
}
|
|
355
356
|
}
|
|
356
|
-
async function Ee(e, t) {
|
|
357
|
+
async function Ee(e, t, n) {
|
|
357
358
|
try {
|
|
358
|
-
let
|
|
359
|
+
let r = await v(`${y()}/events/${e}/check-password`, {
|
|
359
360
|
method: "POST",
|
|
360
361
|
headers: { "Content-Type": "application/json" },
|
|
361
|
-
body: JSON.stringify({ password: t })
|
|
362
|
+
body: JSON.stringify({ password: t }),
|
|
363
|
+
widgetKey: n?.widgetKey
|
|
362
364
|
});
|
|
363
|
-
return typeof
|
|
365
|
+
return typeof r == "boolean" ? { valid: r } : { valid: r?.valid === !0 };
|
|
364
366
|
} catch (e) {
|
|
365
367
|
return V.error("Error checking event password:", e), { valid: !1 };
|
|
366
368
|
}
|
|
@@ -373,11 +375,11 @@ function De(e, t) {
|
|
|
373
375
|
let { origin: e, pathname: t, search: r } = window.location;
|
|
374
376
|
return `${e}${t}${r}#${n}`;
|
|
375
377
|
}
|
|
376
|
-
return `${
|
|
378
|
+
return `${b()}/e/${n}`;
|
|
377
379
|
}
|
|
378
380
|
function Oe(e, t, n) {
|
|
379
381
|
let r = n?.toString(), i = t ? `/e/${e}-${t}` : `/e/${e}`;
|
|
380
|
-
return `${
|
|
382
|
+
return `${b()}${i}${r ? `?${r}` : ""}`;
|
|
381
383
|
}
|
|
382
384
|
var ke = "get-micdrop.com";
|
|
383
385
|
function J(e) {
|
|
@@ -396,7 +398,7 @@ function Me(e) {
|
|
|
396
398
|
return `/${e}`;
|
|
397
399
|
}
|
|
398
400
|
function Ne(e) {
|
|
399
|
-
return `${
|
|
401
|
+
return `${b()}/${e}`;
|
|
400
402
|
}
|
|
401
403
|
function Pe(e, t) {
|
|
402
404
|
return `/${e}/${t}/checkout`;
|
|
@@ -412,25 +414,25 @@ function Ie(e) {
|
|
|
412
414
|
}
|
|
413
415
|
function Le(e, t, n = {}) {
|
|
414
416
|
let r = t ? `/e/${e}-${t}` : `/e/${e}`;
|
|
415
|
-
return `${
|
|
417
|
+
return `${b()}${r}/tickets/checkout/success${Ie(n)}`;
|
|
416
418
|
}
|
|
417
419
|
//#endregion
|
|
418
420
|
//#region src/lib/api/venues.ts
|
|
419
421
|
var Y = e("VC");
|
|
420
|
-
async function Re(e) {
|
|
422
|
+
async function Re(e, t) {
|
|
421
423
|
try {
|
|
422
424
|
if (!e) return Y.warn("getVenue called without venueId"), null;
|
|
423
|
-
let
|
|
424
|
-
return
|
|
425
|
+
let n = await g(`/venues/${e}`, { widgetKey: t?.widgetKey });
|
|
426
|
+
return n.success ? n.data ?? null : (Y.error(`Failed to fetch venue: ${n.statusCode}`), null);
|
|
425
427
|
} catch (e) {
|
|
426
428
|
return Y.error("Error fetching venue:", e), null;
|
|
427
429
|
}
|
|
428
430
|
}
|
|
429
|
-
async function ze(e) {
|
|
430
|
-
let
|
|
431
|
-
if (!
|
|
431
|
+
async function ze(e, t) {
|
|
432
|
+
let n = J(e);
|
|
433
|
+
if (!n) return !1;
|
|
432
434
|
try {
|
|
433
|
-
let e = await g(`/sites/by-host/${encodeURIComponent(new URL(
|
|
435
|
+
let e = await g(`/sites/by-host/${encodeURIComponent(new URL(n).host)}`, { widgetKey: t?.widgetKey });
|
|
434
436
|
return !!(e.success && e.data);
|
|
435
437
|
} catch (e) {
|
|
436
438
|
return Y.warn("hasPublishedSite failed:", e), !1;
|
|
@@ -467,18 +469,18 @@ function He(e) {
|
|
|
467
469
|
//#endregion
|
|
468
470
|
//#region src/lib/api/gift-cards.ts
|
|
469
471
|
var Z = e("VC");
|
|
470
|
-
async function Ue(e, t) {
|
|
472
|
+
async function Ue(e, t, n) {
|
|
471
473
|
try {
|
|
472
|
-
let
|
|
473
|
-
if (!
|
|
474
|
+
let r = await _(`${p()}/cart/${e}/apply-gift-card`, { giftCardCode: t }, { widgetKey: n?.widgetKey });
|
|
475
|
+
if (!r.success) return r.statusCode === 429 ? {
|
|
474
476
|
valid: !1,
|
|
475
477
|
error: "Too many attempts. Please wait a moment and try again."
|
|
476
|
-
} : (Z.error("Apply gift card failed:",
|
|
478
|
+
} : (Z.error("Apply gift card failed:", r.error), {
|
|
477
479
|
valid: !1,
|
|
478
|
-
error:
|
|
480
|
+
error: r.error || "Invalid gift card code"
|
|
479
481
|
});
|
|
480
|
-
let
|
|
481
|
-
return
|
|
482
|
+
let i = He(r.data);
|
|
483
|
+
return i.valid || Z.error("Apply gift card returned an unusable payload:", r.data), i;
|
|
482
484
|
} catch (e) {
|
|
483
485
|
return Z.error("applyGiftCard error:", e), {
|
|
484
486
|
valid: !1,
|
|
@@ -486,17 +488,20 @@ async function Ue(e, t) {
|
|
|
486
488
|
};
|
|
487
489
|
}
|
|
488
490
|
}
|
|
489
|
-
async function Q(e, t) {
|
|
491
|
+
async function Q(e, t, n) {
|
|
490
492
|
try {
|
|
491
|
-
let
|
|
492
|
-
|
|
493
|
+
let r = t?.giftCardId ? { giftCardId: t.giftCardId } : t?.code ? { giftCardCode: t.code } : null, i = await m(`${p()}/cart/${e}/gift-card`, r ? {
|
|
494
|
+
body: JSON.stringify(r),
|
|
495
|
+
widgetKey: n?.widgetKey
|
|
496
|
+
} : { widgetKey: n?.widgetKey });
|
|
497
|
+
if (!i.success) return Z.error("Remove gift card failed:", i.error), {
|
|
493
498
|
success: !1,
|
|
494
|
-
error:
|
|
499
|
+
error: i.error || "Failed to remove gift card"
|
|
495
500
|
};
|
|
496
|
-
let
|
|
501
|
+
let a = i.data ?? {}, o = a.newTotal ?? a.NewTotal;
|
|
497
502
|
return {
|
|
498
503
|
success: !0,
|
|
499
|
-
...typeof
|
|
504
|
+
...typeof o == "number" ? { remainingTotal: o } : {}
|
|
500
505
|
};
|
|
501
506
|
} catch (e) {
|
|
502
507
|
return Z.error("removeGiftCard error:", e), {
|
|
@@ -505,10 +510,10 @@ async function Q(e, t) {
|
|
|
505
510
|
};
|
|
506
511
|
}
|
|
507
512
|
}
|
|
508
|
-
async function We(e, n, r) {
|
|
509
|
-
let
|
|
513
|
+
async function We(e, n, r, i) {
|
|
514
|
+
let a = te(r);
|
|
510
515
|
try {
|
|
511
|
-
let r = await
|
|
516
|
+
let r = await _(`${p()}/cart/${e}/complete-gift-card-payment`, {
|
|
512
517
|
customerName: t(n.firstName, n.lastName),
|
|
513
518
|
customerEmail: n.email,
|
|
514
519
|
firstName: n.firstName,
|
|
@@ -517,9 +522,9 @@ async function We(e, n, r) {
|
|
|
517
522
|
phoneNumber: n.phoneNumber || null,
|
|
518
523
|
questionAnswer: n.questionAnswer || "",
|
|
519
524
|
mailingList: n.mailingList || !1,
|
|
520
|
-
attribution:
|
|
521
|
-
...
|
|
522
|
-
});
|
|
525
|
+
attribution: ee(),
|
|
526
|
+
...a ? { locale: a } : {}
|
|
527
|
+
}, { widgetKey: i?.widgetKey });
|
|
523
528
|
return r.success ? {
|
|
524
529
|
success: !0,
|
|
525
530
|
orderId: r.data?.orderId,
|
|
@@ -538,50 +543,50 @@ async function We(e, n, r) {
|
|
|
538
543
|
//#endregion
|
|
539
544
|
//#region src/lib/api/cart-addons.ts
|
|
540
545
|
var Ge = e("VC");
|
|
541
|
-
async function Ke(e, t) {
|
|
542
|
-
let
|
|
546
|
+
async function Ke(e, t, n) {
|
|
547
|
+
let r = (e) => ({
|
|
543
548
|
success: !1,
|
|
544
549
|
error: e,
|
|
545
550
|
lines: [],
|
|
546
551
|
addOnQuantity: 0,
|
|
547
552
|
repriced: !1
|
|
548
553
|
});
|
|
549
|
-
if (!e) return
|
|
550
|
-
let
|
|
554
|
+
if (!e) return r(null);
|
|
555
|
+
let i = {};
|
|
551
556
|
for (let [e, n] of Object.entries(t)) {
|
|
552
557
|
let t = typeof e == "number" ? e : parseInt(e, 10);
|
|
553
|
-
!Number.isNaN(t) && n > 0 && (
|
|
558
|
+
!Number.isNaN(t) && n > 0 && (i[t] = n);
|
|
554
559
|
}
|
|
555
560
|
try {
|
|
556
|
-
let t = await
|
|
557
|
-
if (!t.success) return
|
|
558
|
-
let
|
|
561
|
+
let t = await _(`${p()}/cart/${e}/add-ons`, { addOnQuantities: i }, { widgetKey: n?.widgetKey });
|
|
562
|
+
if (!t.success) return r(t.error || null);
|
|
563
|
+
let a = t.data || {};
|
|
559
564
|
return {
|
|
560
565
|
success: !0,
|
|
561
566
|
error: null,
|
|
562
|
-
lines:
|
|
563
|
-
addOnQuantity:
|
|
564
|
-
repriced:
|
|
567
|
+
lines: a.addOns || [],
|
|
568
|
+
addOnQuantity: a.addOnQuantity || 0,
|
|
569
|
+
repriced: a.repriced === !0
|
|
565
570
|
};
|
|
566
571
|
} catch (e) {
|
|
567
|
-
return Ge.error("updateCartAddOns error:", e),
|
|
572
|
+
return Ge.error("updateCartAddOns error:", e), r(null);
|
|
568
573
|
}
|
|
569
574
|
}
|
|
570
575
|
//#endregion
|
|
571
576
|
//#region src/lib/api/waitlist.ts
|
|
572
577
|
var $ = e("VC");
|
|
573
|
-
async function qe(e, t, n = null, r = !1) {
|
|
578
|
+
async function qe(e, t, n = null, r = !1, i) {
|
|
574
579
|
try {
|
|
575
|
-
let
|
|
576
|
-
n && r && (
|
|
577
|
-
let
|
|
578
|
-
return
|
|
580
|
+
let a = { email: t };
|
|
581
|
+
n && r && (a.phone = n, a.smsOptIn = !0);
|
|
582
|
+
let o = await _(`/events/${e}/waitlist`, a, { widgetKey: i?.widgetKey });
|
|
583
|
+
return o.success ? {
|
|
579
584
|
success: !0,
|
|
580
|
-
updated:
|
|
581
|
-
position:
|
|
582
|
-
} : ($.error("Join waitlist failed:",
|
|
585
|
+
updated: o.data?.updated,
|
|
586
|
+
position: o.data?.position
|
|
587
|
+
} : ($.error("Join waitlist failed:", o.error), {
|
|
583
588
|
success: !1,
|
|
584
|
-
errorCode:
|
|
589
|
+
errorCode: o.error || "join_failed"
|
|
585
590
|
});
|
|
586
591
|
} catch (e) {
|
|
587
592
|
return $.error("joinWaitlist error:", e), {
|
|
@@ -590,17 +595,17 @@ async function qe(e, t, n = null, r = !1) {
|
|
|
590
595
|
};
|
|
591
596
|
}
|
|
592
597
|
}
|
|
593
|
-
async function Je(e, t) {
|
|
598
|
+
async function Je(e, t, n) {
|
|
594
599
|
try {
|
|
595
|
-
let
|
|
596
|
-
return
|
|
600
|
+
let r = await _(`/checkout/validate-token/${e}`, { email: t }, { widgetKey: n?.widgetKey });
|
|
601
|
+
return r.success ? {
|
|
597
602
|
valid: !0,
|
|
598
|
-
eventId:
|
|
599
|
-
expiresAt:
|
|
603
|
+
eventId: r.data?.eventId ?? 0,
|
|
604
|
+
expiresAt: r.data?.expiresAt
|
|
600
605
|
} : {
|
|
601
606
|
valid: !1,
|
|
602
607
|
eventId: 0,
|
|
603
|
-
errorCode:
|
|
608
|
+
errorCode: r.error
|
|
604
609
|
};
|
|
605
610
|
} catch (e) {
|
|
606
611
|
return $.error("validateWaitlistToken error:", e), {
|
|
@@ -610,12 +615,12 @@ async function Je(e, t) {
|
|
|
610
615
|
};
|
|
611
616
|
}
|
|
612
617
|
}
|
|
613
|
-
async function Ye(e, t) {
|
|
618
|
+
async function Ye(e, t, n) {
|
|
614
619
|
try {
|
|
615
|
-
let
|
|
616
|
-
return
|
|
620
|
+
let r = await _(`/waitlist/requeue/${e}`, { email: t }, { widgetKey: n?.widgetKey });
|
|
621
|
+
return r.success ? { success: !0 } : {
|
|
617
622
|
success: !1,
|
|
618
|
-
errorCode:
|
|
623
|
+
errorCode: r.error
|
|
619
624
|
};
|
|
620
625
|
} catch (e) {
|
|
621
626
|
return $.error("requeueWaitlistToFront error:", e), {
|
|
@@ -624,21 +629,21 @@ async function Ye(e, t) {
|
|
|
624
629
|
};
|
|
625
630
|
}
|
|
626
631
|
}
|
|
627
|
-
async function Xe(e) {
|
|
628
|
-
let
|
|
632
|
+
async function Xe(e, t) {
|
|
633
|
+
let n = {
|
|
629
634
|
waitlistEnabled: !1,
|
|
630
635
|
soldOut: !1,
|
|
631
636
|
gated: !1
|
|
632
637
|
};
|
|
633
638
|
try {
|
|
634
|
-
let
|
|
635
|
-
return
|
|
636
|
-
waitlistEnabled: !!
|
|
637
|
-
soldOut: !!
|
|
638
|
-
gated: !!
|
|
639
|
-
} :
|
|
639
|
+
let r = await g(`/events/${e}/waitlist/status`, { widgetKey: t?.widgetKey });
|
|
640
|
+
return r.success ? {
|
|
641
|
+
waitlistEnabled: !!r.data?.waitlistEnabled,
|
|
642
|
+
soldOut: !!r.data?.soldOut,
|
|
643
|
+
gated: !!r.data?.gated
|
|
644
|
+
} : n;
|
|
640
645
|
} catch (e) {
|
|
641
|
-
return $.error("getWaitlistStatus error:", e),
|
|
646
|
+
return $.error("getWaitlistStatus error:", e), n;
|
|
642
647
|
}
|
|
643
648
|
}
|
|
644
649
|
function Ze(e) {
|
|
@@ -646,4 +651,4 @@ function Ze(e) {
|
|
|
646
651
|
return e >= 3600 ? `${Math.floor(e / 3600)}:${String(Math.floor(e % 3600 / 60)).padStart(2, "0")}:${t}` : `${Math.floor(e / 60)}:${t}`;
|
|
647
652
|
}
|
|
648
653
|
//#endregion
|
|
649
|
-
export { we as A, ie as B, he as C, Ce as D, Te as E, k as F,
|
|
654
|
+
export { we as A, ie as B, he as C, Ce as D, Te as E, k as F, C as H, O as I, T as L, fe as M, de as N, be as O, le as P, ae as R, ve as S, G as T, ne as U, oe as V, je as _, Je as a, Fe as b, We as c, ze as d, Pe as f, De as g, Oe as h, Ye as i, pe as j, xe as k, Q as l, Me as m, Xe as n, Ke as o, Ne as p, qe as r, Ue as s, Ze as t, Re as u, Ae as v, ge as w, Ee as x, Le as y, re as z };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { X as e } from "./datetime-
|
|
1
|
+
import { X as e } from "./datetime-BnKG6Hjm.js";
|
|
2
2
|
import "svelte/internal/disclose-version";
|
|
3
3
|
import * as t from "svelte/internal/client";
|
|
4
4
|
//#region node_modules/@getmicdrop/svelte-components/dist/primitives/Icons/phosphor/MailIcon.svelte
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { D as e, E as t, O as n, R as r, T as i, g as a, h as o, m as s, r as c, t as l, x as u } from "./defaultLabels-
|
|
1
|
+
import { D as e, E as t, O as n, R as r, T as i, g as a, h as o, m as s, r as c, t as l, x as u } from "./defaultLabels-BbNEEsF7.js";
|
|
2
2
|
import { r as d } from "./Button-VUB2WJ88.js";
|
|
3
3
|
import { getContext as f, setContext as p } from "svelte";
|
|
4
4
|
//#region node_modules/@getmicdrop/svelte-components/dist/primitives/Icons/phosphor/iconWeight.js
|