@getmicdrop/venue-calendar 4.2.33 → 4.2.34
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 +809 -809
- package/dist/{ArrowLeftIcon-B92-MN6-.js → ArrowLeftIcon-D2dcPIYB.js} +1 -1
- package/dist/{Badge-Bv_MT-Vt.js → Badge-Bk1dnG89.js} +1 -1
- package/dist/{BlockPlaceholder-DuE4xLS_.js → BlockPlaceholder-DJLtnBDw.js} +1 -1
- package/dist/{Calendar-CX3S7j_2.js → Calendar-CzvJjOKf.js} +19 -19
- package/dist/{CalendarFoundryView-CE5VMPRl.js → CalendarFoundryView-DWjYFSEw.js} +947 -947
- package/dist/{CalendarIcon-pJ01x71c.js → CalendarIcon-CkJFNFxp.js} +1 -1
- package/dist/{CartView-BZALykSb.js → CartView-DidUQzO-.js} +532 -532
- package/dist/{Checkout-B6BHEAwF.js → Checkout-1NyqTUI8.js} +129 -129
- package/dist/{Checkout-c6ExwNzk.js → Checkout-eIj6xGgL.js} +173 -173
- package/dist/{CheckoutTimer-Bz-HJhV2.js → CheckoutTimer-DFIHUIZl.js} +5 -5
- package/dist/{ChevronDownIcon-k93EaHQh.js → ChevronDownIcon-rsVUoX0r.js} +1 -1
- package/dist/{ClockIcon-hnrV9bwg.js → ClockIcon-CIwbKXZX.js} +1 -1
- package/dist/{CloseIcon-CdZ5mNTK.js → CloseIcon-B7HoEcON.js} +1 -1
- package/dist/{CollectionView-BMDKM-lg.js → CollectionView-Dt3NmdBh.js} +9 -10
- package/dist/{Event-DvRnmTdU.js → Event-B0hDsxnc.js} +85 -85
- package/dist/{EventPage-CTo8ynx6.js → EventPage-De-7chl3.js} +124 -125
- package/dist/{Heading-Dfo3bjyn.js → Heading-CQlZrwry.js} +1 -1
- package/dist/{Image-B3cEndLZ.js → Image-T6dKIfNx.js} +1 -1
- package/dist/{Input-BntIoPeV.js → Input-8KhoOdg-.js} +1 -1
- package/dist/{MailIcon-CMyjGJ4_.js → MailIcon-CSR5vhKU.js} +1 -1
- package/dist/{Modal-CpMs0l2W.js → Modal-D3Otve45.js} +2 -2
- package/dist/{ModalFooter-Kdyt5XyP.js → ModalFooter-fv8mC75I.js} +2 -2
- package/dist/{PasswordInput-C91gXtFY.js → PasswordInput-B_6cNrlw.js} +1 -1
- package/dist/{ScarcityBadge-C0YeWGkd.js → ScarcityBadge-CtHuWSRt.js} +23 -22
- package/dist/{SeriesPage-DNyhMA_k.js → SeriesPage-BFYmtgoi.js} +4 -4
- package/dist/{Spinner-BwiDys7C.js → Spinner-fFAXvj_B.js} +1 -1
- package/dist/{Success-BxvH6W_x.js → Success-BIVQOUqu.js} +52 -52
- package/dist/{TagIcon-BkPcpKdu.js → TagIcon-Do5sN8xR.js} +1 -1
- package/dist/ViewTicketsEmbed-CbbE-8EX.js +727 -0
- package/dist/{WarningCircleIcon-D78IFaPY.js → WarningCircleIcon-DuqytsVW.js} +1 -1
- package/dist/{WarningTriIcon-6WbGCso4.js → WarningTriIcon-CW-j3Vwq.js} +1 -1
- package/dist/{__SKIP_PATHS__-tAxwP7_6.js → __SKIP_PATHS__-Chv7DW7h.js} +1 -1
- package/dist/api/api.cjs +1 -1
- package/dist/api/api.mjs +299 -209
- package/dist/api/gift-cards.d.ts +1 -1
- package/dist/api/orders.d.ts +2 -2
- package/dist/api/types.d.ts +554 -554
- package/dist/{colors-DbQNhbC_.js → colors-BND7shPA.js} +119 -117
- package/dist/constants-BYtFptYp.js +356 -0
- package/dist/{copyToClipboard-DAGJHhtn.js → copyToClipboard-CcwaUGGt.js} +1 -1
- package/dist/{de-BG-86m10.js → de-8N03rEoe.js} +4 -1
- package/dist/{de-BZpzzwT9.js → de-CgHrjezX.js} +57 -1
- package/dist/{timezones-C5l0SSHK.js → defaultLabels-CGMGBy-u.js} +501 -1
- package/dist/{es-9jwSoUSD.js → es-D6ThNLUc.js} +45 -1
- package/dist/{es-B1RPM3H_.js → es-tRMGbtbB.js} +4 -1
- package/dist/{event-v8d4wRpB.js → event-CbAGNxgd.js} +1 -1
- package/dist/{event-transform-lC22EDSL.js → event-transform-DnvOiDVn.js} +4 -4
- package/dist/{eventStatusStream-CopqZ2oa.js → eventStatusStream-BIn6Dzkw.js} +5 -5
- package/dist/{fr-B6FgrH9s.js → fr-DDnljtQz.js} +4 -1
- package/dist/{fr-fYY2O8Ab.js → fr-W0OOohju.js} +57 -1
- package/dist/{href-BH6l_kZx.js → href-D2-tmkMF.js} +2 -2
- package/dist/{i18n-CIVh_urJ.js → i18n-4k6uF1EX.js} +126 -126
- package/dist/i18n-FnFHQ5QU.js +28 -0
- package/dist/{id-CK7hal8E.js → id-BZshacSm.js} +4 -1
- package/dist/{id-But8qcA2.js → id-xgAFN1EH.js} +57 -1
- package/dist/{it-BdV8d4GZ.js → it-B6Rbpjec.js} +4 -1
- package/dist/{it-Cr9Quauw.js → it-BhuT9BcE.js} +57 -1
- package/dist/{ja-DKVQltc4.js → ja-Bmj-bPuM.js} +4 -1
- package/dist/{ja-CNXwg0_H.js → ja-yca07ASz.js} +57 -1
- package/dist/{ko-DtoIJliT.js → ko-Pfftd2u0.js} +57 -1
- package/dist/{ko-DpIk-4pN.js → ko-r-ecuHZ5.js} +4 -1
- package/dist/{labels-BUH8ouCu.js → labels-Cs7xp4ug.js} +1 -1
- package/dist/locales/{4.2.32 → 4.2.34}/flow/de.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.34}/flow/es.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.34}/flow/fr.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.34}/flow/id.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.34}/flow/it.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.34}/flow/ja.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.34}/flow/ko.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.34}/flow/nl.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.34}/flow/pl.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.34}/flow/pt-br.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.34}/flow/tr.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.34}/flow/zh.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.34}/main/de.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.34}/main/es.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.34}/main/fr.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.34}/main/id.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.34}/main/it.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.34}/main/ja.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.34}/main/ko.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.34}/main/nl.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.34}/main/pl.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.34}/main/pt-br.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.34}/main/tr.js +1 -1
- package/dist/locales/{4.2.32 → 4.2.34}/main/zh.js +1 -1
- package/dist/{modalManager.svelte-C4dWVCst.js → modalManager.svelte-vILq6Thx.js} +2 -2
- package/dist/{nl-Dbs4YQMw.js → nl-CQEhSA2l.js} +57 -1
- package/dist/{nl-C-dVfidI.js → nl-CS1da1Bc.js} +4 -1
- package/dist/{order-totals-CeeD6GjZ.js → order-totals-CSDXY65z.js} +31 -31
- package/dist/{orders-BuGy4vpJ.js → orders-CH2nnS3m.js} +365 -209
- package/dist/{phoneUtils-BDV9Eggn.js → phoneUtils-BtJ3FhMK.js} +1 -1
- package/dist/{pixels-D6vqcuy2.js → pixels-BK7PGnme.js} +11 -11
- package/dist/{pl-CnFcI33y.js → pl-C2bkE2WA.js} +4 -1
- package/dist/{pl-Da6lsZXQ.js → pl-CyWqKYE8.js} +57 -1
- package/dist/{promo-DtLZRskK.js → promo-Cy4LPBAC.js} +3 -3
- package/dist/{pt-br-6QYijxa0.js → pt-br--DIxBDjz.js} +4 -1
- package/dist/{pt-br-D1wHabRR.js → pt-br-BC2I7f8-.js} +57 -1
- package/dist/seo/types.d.ts +156 -156
- package/dist/{serverTotals-t2UmKkhC.js → serverTotals-C3VhWitQ.js} +1 -1
- package/dist/{shareCopyFeedback.svelte-B-M53Wj2.js → shareCopyFeedback.svelte-DTl5jJ2n.js} +55 -55
- package/dist/{showcase-state-options-VZcqIjpF.js → showcase-state-options-CeCdn8_C.js} +1 -1
- package/dist/{to-event-card-props-CpXtfoKx.js → to-event-card-props-BmsDr8T3.js} +31 -31
- package/dist/{tr-Pv_m8usO.js → tr-Bk7x5MW7.js} +4 -1
- package/dist/{tr-CpN50zWw.js → tr-CNjaJc_1.js} +57 -1
- package/dist/types/index.d.ts +509 -509
- package/dist/{utils-CtqaTDLB.js → utils-pF15CnBe.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-DOeb3_A1.js} +57 -1
- package/package.json +1 -1
- package/src/lib/theme.js +222 -222
- package/dist/ViewTicketsEmbed-DVurn8FG.js +0 -690
- package/dist/constants-ENlpIS8i.js +0 -822
- package/dist/createI18n-DBUVdZra.js +0 -75
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import { C as e, S as t, x as n } from "./Button-C4uFgl7L.js";
|
|
2
|
+
import { I as r, T as i, a, k as o, o as s } from "./defaultLabels-CGMGBy-u.js";
|
|
3
|
+
import * as c from "svelte/internal/client";
|
|
3
4
|
//#region node_modules/@getmicdrop/svelte-components/dist/errors/classes/ApiError.js
|
|
4
|
-
var
|
|
5
|
+
var l = class e extends i {
|
|
5
6
|
constructor(e, t, n = {}) {
|
|
6
7
|
super(e, `API_${t}`, {
|
|
7
8
|
status: t,
|
|
@@ -11,7 +12,7 @@ var s = class e extends o {
|
|
|
11
12
|
}), this.name = "ApiError", this.endpoint = n.endpoint, this.method = n.method, this.requestId = n.requestId;
|
|
12
13
|
}
|
|
13
14
|
getUserMessage(e) {
|
|
14
|
-
return
|
|
15
|
+
return s(this.status, this.message, e);
|
|
15
16
|
}
|
|
16
17
|
isRetryable() {
|
|
17
18
|
return this.status >= 500 || this.status === 429;
|
|
@@ -32,7 +33,7 @@ var s = class e extends o {
|
|
|
32
33
|
};
|
|
33
34
|
//#endregion
|
|
34
35
|
//#region node_modules/@getmicdrop/svelte-components/dist/utils/storage/storage.js
|
|
35
|
-
function
|
|
36
|
+
function u(e) {
|
|
36
37
|
if (typeof window > "u") return null;
|
|
37
38
|
try {
|
|
38
39
|
return e === "local" ? window.localStorage : window.sessionStorage;
|
|
@@ -40,7 +41,7 @@ function c(e) {
|
|
|
40
41
|
return null;
|
|
41
42
|
}
|
|
42
43
|
}
|
|
43
|
-
function
|
|
44
|
+
function d(e, t) {
|
|
44
45
|
if (e == null || e === "") return t;
|
|
45
46
|
try {
|
|
46
47
|
return JSON.parse(e);
|
|
@@ -48,7 +49,7 @@ function l(e, t) {
|
|
|
48
49
|
return t;
|
|
49
50
|
}
|
|
50
51
|
}
|
|
51
|
-
function
|
|
52
|
+
function f(e, t, n) {
|
|
52
53
|
if (!e) return n;
|
|
53
54
|
let r;
|
|
54
55
|
try {
|
|
@@ -56,101 +57,101 @@ function ee(e, t, n) {
|
|
|
56
57
|
} catch {
|
|
57
58
|
return n;
|
|
58
59
|
}
|
|
59
|
-
return
|
|
60
|
+
return d(r, n);
|
|
60
61
|
}
|
|
61
|
-
function
|
|
62
|
-
if (!
|
|
62
|
+
function ee(e, n, r) {
|
|
63
|
+
if (!e) return !1;
|
|
63
64
|
try {
|
|
64
|
-
return
|
|
65
|
-
} catch (
|
|
66
|
-
return
|
|
65
|
+
return e.setItem(n, JSON.stringify(r)), !0;
|
|
66
|
+
} catch (e) {
|
|
67
|
+
return t.warn(`storage: failed to write "${n}"`, e), !1;
|
|
67
68
|
}
|
|
68
69
|
}
|
|
69
|
-
function
|
|
70
|
+
function te(e, t) {
|
|
70
71
|
if (e) try {
|
|
71
72
|
e.removeItem(t);
|
|
72
73
|
} catch {}
|
|
73
74
|
}
|
|
74
|
-
function
|
|
75
|
-
return
|
|
75
|
+
function p(e, t, n) {
|
|
76
|
+
return f(u(e), t, n);
|
|
76
77
|
}
|
|
77
|
-
function
|
|
78
|
-
return
|
|
78
|
+
function ne(e, t, n) {
|
|
79
|
+
return ee(u(e), t, n);
|
|
79
80
|
}
|
|
80
|
-
function
|
|
81
|
-
|
|
81
|
+
function re(e, t) {
|
|
82
|
+
te(u(e), t);
|
|
82
83
|
}
|
|
83
|
-
function
|
|
84
|
-
return
|
|
84
|
+
function m(e, t = null) {
|
|
85
|
+
return p("local", e, t);
|
|
85
86
|
}
|
|
86
|
-
function
|
|
87
|
-
return
|
|
87
|
+
function h(e, t) {
|
|
88
|
+
return ne("local", e, t);
|
|
88
89
|
}
|
|
89
90
|
function ie(e) {
|
|
90
|
-
|
|
91
|
+
re("local", e);
|
|
91
92
|
}
|
|
92
|
-
function
|
|
93
|
-
return
|
|
93
|
+
function g(e, t = null) {
|
|
94
|
+
return p("session", e, t);
|
|
94
95
|
}
|
|
95
|
-
function
|
|
96
|
-
return
|
|
96
|
+
function _(e, t) {
|
|
97
|
+
return ne("session", e, t);
|
|
97
98
|
}
|
|
98
99
|
function ae(e) {
|
|
99
|
-
|
|
100
|
+
re("session", e);
|
|
100
101
|
}
|
|
101
102
|
//#endregion
|
|
102
103
|
//#region src/lib/config.js
|
|
103
|
-
var oe =
|
|
104
|
+
var oe = n("VC:config", { enabled: !0 }), v = null;
|
|
104
105
|
function se(e) {
|
|
105
106
|
let t = e || null;
|
|
106
|
-
|
|
107
|
+
v && t && t !== v && oe.warn("[VC] setWidgetKey called again with a DIFFERENT key. The widget key is module-global, so every calendar on this page will now use the last one set — any element configured with the previous key will get 403s on its public reads and render empty. Give each element its own widget-key attribute (threaded per-instance) rather than calling setWidgetKey() more than once."), v = t;
|
|
107
108
|
}
|
|
108
|
-
function
|
|
109
|
-
if (
|
|
109
|
+
function ce() {
|
|
110
|
+
if (v) return v;
|
|
110
111
|
}
|
|
111
|
-
var
|
|
112
|
-
function
|
|
113
|
-
|
|
112
|
+
var le = null;
|
|
113
|
+
function ue(e) {
|
|
114
|
+
le = typeof e == "string" && e.trim() ? e.trim() : null;
|
|
114
115
|
}
|
|
115
|
-
function
|
|
116
|
-
return (
|
|
116
|
+
function de() {
|
|
117
|
+
return (le || w().baseUrl || "").replace(/\/+$/, "");
|
|
117
118
|
}
|
|
118
|
-
function
|
|
119
|
+
function fe(e) {}
|
|
119
120
|
var y = {
|
|
120
121
|
postMessageOnSuccess: !1,
|
|
121
122
|
postMessageTargetOrigin: null
|
|
122
123
|
};
|
|
123
|
-
function
|
|
124
|
+
function pe(e = {}) {
|
|
124
125
|
y = {
|
|
125
126
|
...y,
|
|
126
127
|
...e
|
|
127
128
|
};
|
|
128
129
|
}
|
|
129
|
-
function
|
|
130
|
+
function me() {
|
|
130
131
|
return { ...y };
|
|
131
132
|
}
|
|
132
133
|
//#endregion
|
|
133
134
|
//#region src/lib/api/client.ts
|
|
134
|
-
var b =
|
|
135
|
-
function
|
|
135
|
+
var b = n("VC"), x = /* @__PURE__ */ new Set();
|
|
136
|
+
function he(e) {
|
|
136
137
|
return x.add(e), () => {
|
|
137
138
|
x.delete(e);
|
|
138
139
|
};
|
|
139
140
|
}
|
|
140
|
-
function
|
|
141
|
+
function ge(e) {
|
|
141
142
|
if (e) for (let t of x) try {
|
|
142
143
|
t(e);
|
|
143
144
|
} catch {}
|
|
144
145
|
}
|
|
145
|
-
var
|
|
146
|
+
var _e = "ABORTED";
|
|
146
147
|
function S(e, t) {
|
|
147
|
-
let n = t ||
|
|
148
|
+
let n = t || ce();
|
|
148
149
|
return n ? {
|
|
149
150
|
...e,
|
|
150
151
|
"X-Widget-Key": n
|
|
151
152
|
} : e;
|
|
152
153
|
}
|
|
153
|
-
function
|
|
154
|
+
function ve(e, t) {
|
|
154
155
|
let n = `HTTP ${t}`;
|
|
155
156
|
if (!e || typeof e != "object") return { message: n };
|
|
156
157
|
let r = e, i = r.error && typeof r.error == "object" ? r.error : null, a = typeof r.code == "string" ? r.code : typeof i?.code == "string" ? i.code : void 0;
|
|
@@ -159,7 +160,7 @@ function ge(e, t) {
|
|
|
159
160
|
code: a
|
|
160
161
|
};
|
|
161
162
|
}
|
|
162
|
-
var
|
|
163
|
+
var ye = class extends Error {
|
|
163
164
|
code;
|
|
164
165
|
statusCode;
|
|
165
166
|
constructor(e, t, n) {
|
|
@@ -172,7 +173,7 @@ var _e = class extends Error {
|
|
|
172
173
|
retryDelay: 500,
|
|
173
174
|
onError: (e) => b.error("API Error:", e)
|
|
174
175
|
};
|
|
175
|
-
function
|
|
176
|
+
function be(e) {
|
|
176
177
|
C = {
|
|
177
178
|
...C,
|
|
178
179
|
...e
|
|
@@ -187,8 +188,8 @@ function T() {
|
|
|
187
188
|
function E() {
|
|
188
189
|
return `${C.baseUrl}/api/orders/v2/public`;
|
|
189
190
|
}
|
|
190
|
-
var
|
|
191
|
-
async function
|
|
191
|
+
var xe = (e) => new Promise((t) => setTimeout(t, e));
|
|
192
|
+
async function Se(e, t, n) {
|
|
192
193
|
let r = (t.method || "GET").toUpperCase(), i = r === "GET" || r === "HEAD" ? n.retries + 1 : 1, a;
|
|
193
194
|
for (let r = 1; r <= i; r++) {
|
|
194
195
|
let o = new AbortController(), s = setTimeout(() => o.abort(), n.timeout), c = t.signal, l;
|
|
@@ -205,25 +206,25 @@ async function D(e, t, n) {
|
|
|
205
206
|
} finally {
|
|
206
207
|
clearTimeout(s), c && l && c.removeEventListener("abort", l);
|
|
207
208
|
}
|
|
208
|
-
r < i && await
|
|
209
|
+
r < i && await xe(n.retryDelay * 2 ** (r - 1));
|
|
209
210
|
}
|
|
210
211
|
throw a;
|
|
211
212
|
}
|
|
212
|
-
async function
|
|
213
|
-
return
|
|
213
|
+
async function D(e, t) {
|
|
214
|
+
return k("GET", e, void 0, t);
|
|
214
215
|
}
|
|
215
|
-
async function
|
|
216
|
-
return
|
|
216
|
+
async function O(e, t, n) {
|
|
217
|
+
return k("POST", e, t, n);
|
|
217
218
|
}
|
|
218
|
-
async function
|
|
219
|
-
return
|
|
219
|
+
async function Ce(e, t) {
|
|
220
|
+
return k("DELETE", e, void 0, t);
|
|
220
221
|
}
|
|
221
|
-
async function
|
|
222
|
+
async function k(e, t, n, r) {
|
|
222
223
|
let i = t.startsWith("http") || t.startsWith("/api/") ? t : `${T()}${t}`, { widgetKey: a, suppressOnError: o, headers: s, ...c } = r ?? {}, l = (e) => {
|
|
223
224
|
o || C.onError(e);
|
|
224
225
|
};
|
|
225
226
|
try {
|
|
226
|
-
let t = await
|
|
227
|
+
let t = await Se(i, {
|
|
227
228
|
method: e,
|
|
228
229
|
headers: S({
|
|
229
230
|
"Content-Type": "application/json",
|
|
@@ -233,8 +234,8 @@ async function A(e, t, n, r) {
|
|
|
233
234
|
...c
|
|
234
235
|
}, C);
|
|
235
236
|
if (!t.ok) {
|
|
236
|
-
let { message: e, code: n } =
|
|
237
|
-
return l(new
|
|
237
|
+
let { message: e, code: n } = ve(await t.json().catch(() => ({})), t.status);
|
|
238
|
+
return l(new ye(e, n, t.status)), ge(n), {
|
|
238
239
|
success: !1,
|
|
239
240
|
error: e,
|
|
240
241
|
errorCode: n,
|
|
@@ -250,7 +251,7 @@ async function A(e, t, n, r) {
|
|
|
250
251
|
if (r?.signal?.aborted) return {
|
|
251
252
|
success: !1,
|
|
252
253
|
error: "Request aborted",
|
|
253
|
-
errorCode:
|
|
254
|
+
errorCode: _e,
|
|
254
255
|
aborted: !0
|
|
255
256
|
};
|
|
256
257
|
let t = e instanceof Error ? e.name === "AbortError" ? "Request timed out" : e.message : "Unknown error";
|
|
@@ -260,15 +261,15 @@ async function A(e, t, n, r) {
|
|
|
260
261
|
};
|
|
261
262
|
}
|
|
262
263
|
}
|
|
263
|
-
async function
|
|
264
|
-
return
|
|
264
|
+
async function we(e, t) {
|
|
265
|
+
return O(`${T()}/tax-preview`, e, {
|
|
265
266
|
signal: t?.signal,
|
|
266
267
|
suppressOnError: t?.suppressOnError ?? !0
|
|
267
268
|
});
|
|
268
269
|
}
|
|
269
|
-
async function
|
|
270
|
+
async function Te(e, t) {
|
|
270
271
|
try {
|
|
271
|
-
let n = e.startsWith(C.baseUrl), { widgetKey: r, ...i } = t ?? {}, a = await
|
|
272
|
+
let n = e.startsWith(C.baseUrl), { widgetKey: r, ...i } = t ?? {}, a = await Se(e, {
|
|
272
273
|
...i,
|
|
273
274
|
...n ? { headers: S(i.headers, r) } : {}
|
|
274
275
|
}, C);
|
|
@@ -283,55 +284,55 @@ async function Se(e, t) {
|
|
|
283
284
|
}
|
|
284
285
|
//#endregion
|
|
285
286
|
//#region src/lib/tracking/normalize.ts
|
|
286
|
-
var
|
|
287
|
+
var Ee = [
|
|
287
288
|
"utmSource",
|
|
288
289
|
"utmMedium",
|
|
289
290
|
"utmCampaign",
|
|
290
291
|
"utmContent",
|
|
291
292
|
"utmTerm"
|
|
292
|
-
],
|
|
293
|
+
], De = {
|
|
293
294
|
utmSource: "utm_source",
|
|
294
295
|
utmMedium: "utm_medium",
|
|
295
296
|
utmCampaign: "utm_campaign",
|
|
296
297
|
utmContent: "utm_content",
|
|
297
298
|
utmTerm: "utm_term"
|
|
298
|
-
},
|
|
299
|
-
function
|
|
299
|
+
}, Oe = "direct";
|
|
300
|
+
function ke(e) {
|
|
300
301
|
return e ? e.trim().toLowerCase().replace(/\s+/g, "_") : "";
|
|
301
302
|
}
|
|
302
|
-
function
|
|
303
|
+
function Ae(e) {
|
|
303
304
|
let t = {};
|
|
304
|
-
for (let n of
|
|
305
|
-
return t.utmSource ||=
|
|
305
|
+
for (let n of Ee) t[n] = ke(e[n]);
|
|
306
|
+
return t.utmSource ||= Oe, t;
|
|
306
307
|
}
|
|
307
|
-
function
|
|
308
|
+
function je(e) {
|
|
308
309
|
let t = {};
|
|
309
|
-
for (let n of
|
|
310
|
-
return
|
|
310
|
+
for (let n of Ee) t[n] = e.get(De[n]);
|
|
311
|
+
return Ae(t);
|
|
311
312
|
}
|
|
312
|
-
function
|
|
313
|
+
function Me(e) {
|
|
313
314
|
return !!e.utmSource && e.utmSource !== "direct";
|
|
314
315
|
}
|
|
315
316
|
//#endregion
|
|
316
317
|
//#region src/lib/tracking/context.ts
|
|
317
|
-
var
|
|
318
|
+
var A = null, j = null, M = {
|
|
318
319
|
search: null,
|
|
319
320
|
referrer: null,
|
|
320
321
|
pageUrl: null
|
|
321
322
|
};
|
|
322
|
-
function
|
|
323
|
-
e.widgetId !== void 0 && (
|
|
323
|
+
function Ne(e) {
|
|
324
|
+
e.widgetId !== void 0 && (A = e.widgetId || null), e.venueId !== void 0 && (j = e.venueId ?? null);
|
|
324
325
|
}
|
|
325
|
-
function
|
|
326
|
-
e.search !== void 0 && (
|
|
326
|
+
function Pe(e) {
|
|
327
|
+
e.search !== void 0 && (M.search = e.search === null ? null : e.search instanceof URLSearchParams ? e.search.toString() : e.search), e.referrer !== void 0 && (M.referrer = e.referrer), e.pageUrl !== void 0 && (M.pageUrl = e.pageUrl);
|
|
327
328
|
}
|
|
328
|
-
function
|
|
329
|
-
return
|
|
329
|
+
function Fe() {
|
|
330
|
+
return A;
|
|
330
331
|
}
|
|
331
|
-
function
|
|
332
|
-
return
|
|
332
|
+
function Ie() {
|
|
333
|
+
return j;
|
|
333
334
|
}
|
|
334
|
-
function
|
|
335
|
+
function Le() {
|
|
335
336
|
if (typeof window > "u") return !0;
|
|
336
337
|
try {
|
|
337
338
|
return window.self === window.top;
|
|
@@ -339,57 +340,57 @@ function Me() {
|
|
|
339
340
|
return !1;
|
|
340
341
|
}
|
|
341
342
|
}
|
|
342
|
-
function
|
|
343
|
-
let e = typeof window < "u", t =
|
|
343
|
+
function N() {
|
|
344
|
+
let e = typeof window < "u", t = Le(), n = M.search ?? (e ? window.location.search : ""), r = M.referrer ?? (typeof document < "u" ? document.referrer : "") ?? "", i = M.pageUrl ?? (e && t ? window.location.href : "");
|
|
344
345
|
return {
|
|
345
|
-
utm:
|
|
346
|
+
utm: je(new URLSearchParams(n)),
|
|
346
347
|
referrer: r || "",
|
|
347
348
|
pageUrl: i || ""
|
|
348
349
|
};
|
|
349
350
|
}
|
|
350
|
-
function
|
|
351
|
+
function Re() {
|
|
351
352
|
if (typeof navigator > "u") return "desktop";
|
|
352
353
|
let e = navigator.userAgent.toLowerCase();
|
|
353
354
|
return /ipad|tablet|playbook|silk/.test(e) ? "tablet" : /mobile|iphone|ipod|android.*mobile|windows phone|blackberry/.test(e) ? "mobile" : /android/.test(e) ? "tablet" : "desktop";
|
|
354
355
|
}
|
|
355
356
|
//#endregion
|
|
356
357
|
//#region src/lib/tracking/consent.ts
|
|
357
|
-
var
|
|
358
|
-
function
|
|
359
|
-
|
|
358
|
+
var P = null, F = !1, I = !1, ze = !1;
|
|
359
|
+
function Be(e) {
|
|
360
|
+
P = e;
|
|
360
361
|
}
|
|
361
|
-
function
|
|
362
|
-
|
|
362
|
+
function Ve(e) {
|
|
363
|
+
F = e;
|
|
363
364
|
}
|
|
364
|
-
function
|
|
365
|
-
return
|
|
365
|
+
function L() {
|
|
366
|
+
return ze;
|
|
366
367
|
}
|
|
367
|
-
function
|
|
368
|
+
function R() {
|
|
368
369
|
return typeof window < "u" && typeof window.__tcfapi == "function";
|
|
369
370
|
}
|
|
370
|
-
function
|
|
371
|
+
function z() {
|
|
371
372
|
return typeof navigator < "u" && navigator.globalPrivacyControl === !0;
|
|
372
373
|
}
|
|
373
|
-
function
|
|
374
|
-
return
|
|
374
|
+
function He() {
|
|
375
|
+
return P === null ? R() || z() : P;
|
|
375
376
|
}
|
|
376
|
-
function
|
|
377
|
-
return !
|
|
377
|
+
function B() {
|
|
378
|
+
return !He() || F;
|
|
378
379
|
}
|
|
379
|
-
function
|
|
380
|
-
if (
|
|
381
|
-
|
|
380
|
+
function Ue() {
|
|
381
|
+
if (I || !R()) return;
|
|
382
|
+
I = !0;
|
|
382
383
|
let e = window.__tcfapi;
|
|
383
384
|
try {
|
|
384
385
|
e("addEventListener", 2, (e, t) => {
|
|
385
386
|
if (!(!t || !e)) {
|
|
386
387
|
if (e.gdprApplies === !1) {
|
|
387
|
-
|
|
388
|
+
z() || (F = !0);
|
|
388
389
|
return;
|
|
389
390
|
}
|
|
390
391
|
if (e.eventStatus === "tcloaded" || e.eventStatus === "useractioncomplete") {
|
|
391
392
|
let t = e.purpose?.consents;
|
|
392
|
-
|
|
393
|
+
F = !!t && Object.values(t).some(Boolean);
|
|
393
394
|
}
|
|
394
395
|
}
|
|
395
396
|
});
|
|
@@ -397,11 +398,11 @@ function Re() {
|
|
|
397
398
|
}
|
|
398
399
|
//#endregion
|
|
399
400
|
//#region src/lib/tracking/identity.ts
|
|
400
|
-
var
|
|
401
|
-
function
|
|
402
|
-
return typeof e == "string" &&
|
|
401
|
+
var V = "micdrop_session_id", H = "micdrop_visitor_id", We = /^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i;
|
|
402
|
+
function U(e) {
|
|
403
|
+
return typeof e == "string" && We.test(e);
|
|
403
404
|
}
|
|
404
|
-
function
|
|
405
|
+
function W() {
|
|
405
406
|
let e = typeof crypto < "u" ? crypto : void 0;
|
|
406
407
|
if (e?.randomUUID) return e.randomUUID();
|
|
407
408
|
let t = /* @__PURE__ */ new Uint8Array(16);
|
|
@@ -412,20 +413,20 @@ function q() {
|
|
|
412
413
|
for (let e = 0; e < 16; e++) n.push(t[e].toString(16).padStart(2, "0"));
|
|
413
414
|
return `${n[0]}${n[1]}${n[2]}${n[3]}-${n[4]}${n[5]}-${n[6]}${n[7]}-${n[8]}${n[9]}-${n[10]}${n[11]}${n[12]}${n[13]}${n[14]}${n[15]}`;
|
|
414
415
|
}
|
|
415
|
-
function
|
|
416
|
-
let e =
|
|
417
|
-
return e || (e =
|
|
416
|
+
function G() {
|
|
417
|
+
let e = g(V);
|
|
418
|
+
return e || (e = W(), _(V, e)), e;
|
|
418
419
|
}
|
|
419
|
-
function
|
|
420
|
-
let t =
|
|
421
|
-
if (
|
|
420
|
+
function Ge(e) {
|
|
421
|
+
let t = m(H);
|
|
422
|
+
if (U(t)) return {
|
|
422
423
|
id: t,
|
|
423
424
|
createdAt: e,
|
|
424
425
|
migrated: !0
|
|
425
426
|
};
|
|
426
427
|
if (t && typeof t == "object") {
|
|
427
428
|
let { id: n, createdAt: r } = t;
|
|
428
|
-
if (!
|
|
429
|
+
if (!U(n)) return null;
|
|
429
430
|
let i = typeof r == "number" && Number.isFinite(r), a = i ? Math.min(r, e) : e;
|
|
430
431
|
return {
|
|
431
432
|
id: n,
|
|
@@ -435,23 +436,23 @@ function Be(e) {
|
|
|
435
436
|
}
|
|
436
437
|
return null;
|
|
437
438
|
}
|
|
438
|
-
function
|
|
439
|
-
if (!
|
|
440
|
-
let e = Date.now(), t =
|
|
441
|
-
if (t && e - t.createdAt < 34128e6) return t.migrated &&
|
|
439
|
+
function K() {
|
|
440
|
+
if (!B()) return null;
|
|
441
|
+
let e = Date.now(), t = Ge(e);
|
|
442
|
+
if (t && e - t.createdAt < 34128e6) return t.migrated && h(H, {
|
|
442
443
|
id: t.id,
|
|
443
444
|
createdAt: t.createdAt
|
|
444
445
|
}), t.id;
|
|
445
|
-
let n =
|
|
446
|
-
return
|
|
446
|
+
let n = W();
|
|
447
|
+
return h(H, {
|
|
447
448
|
id: n,
|
|
448
449
|
createdAt: e
|
|
449
450
|
}), n;
|
|
450
451
|
}
|
|
451
452
|
//#endregion
|
|
452
453
|
//#region src/lib/tracking/attribution-store.ts
|
|
453
|
-
var
|
|
454
|
-
function
|
|
454
|
+
var Ke = "micdrop_attribution";
|
|
455
|
+
function qe(e, t) {
|
|
455
456
|
if (!e || !t) return !1;
|
|
456
457
|
try {
|
|
457
458
|
let n = new URL(e).host, r = new URL(t).host;
|
|
@@ -460,26 +461,26 @@ function Ve(e, t) {
|
|
|
460
461
|
return !1;
|
|
461
462
|
}
|
|
462
463
|
}
|
|
463
|
-
function
|
|
464
|
-
return
|
|
464
|
+
function Je(e) {
|
|
465
|
+
return Me(e.utm) || qe(e.referrer, e.pageUrl);
|
|
465
466
|
}
|
|
466
|
-
function
|
|
467
|
-
let e =
|
|
467
|
+
function Ye() {
|
|
468
|
+
let e = g(Ke);
|
|
468
469
|
return !e || !e.utm || typeof e.utm.utmSource != "string" ? null : e;
|
|
469
470
|
}
|
|
470
|
-
function
|
|
471
|
-
let t =
|
|
472
|
-
!t && n ||
|
|
471
|
+
function Xe(e = N()) {
|
|
472
|
+
let t = Je(e), n = Ye();
|
|
473
|
+
!t && n || _(Ke, {
|
|
473
474
|
utm: e.utm,
|
|
474
475
|
referrer: e.referrer,
|
|
475
476
|
marketing: t
|
|
476
477
|
});
|
|
477
478
|
}
|
|
478
|
-
function
|
|
479
|
-
let e =
|
|
479
|
+
function q() {
|
|
480
|
+
let e = Ye() ?? N();
|
|
480
481
|
return {
|
|
481
|
-
sessionId:
|
|
482
|
-
visitorId:
|
|
482
|
+
sessionId: G(),
|
|
483
|
+
visitorId: K(),
|
|
483
484
|
utmSource: e.utm.utmSource,
|
|
484
485
|
utmMedium: e.utm.utmMedium,
|
|
485
486
|
utmCampaign: e.utm.utmCampaign,
|
|
@@ -490,7 +491,7 @@ function Z() {
|
|
|
490
491
|
}
|
|
491
492
|
//#endregion
|
|
492
493
|
//#region src/lib/tracking/beacon.ts
|
|
493
|
-
var
|
|
494
|
+
var Ze = n("tracking"), Qe = /* @__PURE__ */ new Set([
|
|
494
495
|
"chunk_load_error",
|
|
495
496
|
"type_error",
|
|
496
497
|
"reference_error",
|
|
@@ -501,23 +502,23 @@ var Ge = t("tracking"), Ke = /* @__PURE__ */ new Set([
|
|
|
501
502
|
"abort_error",
|
|
502
503
|
"not_supported_error",
|
|
503
504
|
"error"
|
|
504
|
-
]),
|
|
505
|
-
function
|
|
505
|
+
]), $e = "other";
|
|
506
|
+
function et(e) {
|
|
506
507
|
try {
|
|
507
508
|
let t = e instanceof Error || e && typeof e == "object" && "name" in e ? String(e.name ?? "") : "", n = e && typeof e == "object" && "message" in e ? String(e.message ?? "") : "";
|
|
508
509
|
if (t === "ChunkLoadError" || /dynamically imported module/i.test(n)) return "chunk_load_error";
|
|
509
510
|
let r = t.replace(/([a-z0-9])([A-Z])/g, "$1_$2").toLowerCase().replace(/[^a-z0-9_]/g, "");
|
|
510
|
-
return
|
|
511
|
+
return Qe.has(r) ? r : $e;
|
|
511
512
|
} catch {
|
|
512
|
-
return
|
|
513
|
+
return $e;
|
|
513
514
|
}
|
|
514
515
|
}
|
|
515
|
-
var
|
|
516
|
+
var tt = /* @__PURE__ */ new Set([
|
|
516
517
|
"add_to_cart",
|
|
517
518
|
"checkout_started",
|
|
518
519
|
"purchase"
|
|
519
|
-
]),
|
|
520
|
-
function
|
|
520
|
+
]), nt = "micdrop_tracked_beacons", rt = 300;
|
|
521
|
+
function it(e, t, n, r, i, a, o, s = "") {
|
|
521
522
|
let c = n || `url:${o}`, l = [
|
|
522
523
|
e,
|
|
523
524
|
t ?? "",
|
|
@@ -528,27 +529,27 @@ function Qe(e, t, n, r, i, a, o, s = "") {
|
|
|
528
529
|
];
|
|
529
530
|
return s && l.push(s), l.join(":");
|
|
530
531
|
}
|
|
531
|
-
function
|
|
532
|
+
function J(e) {
|
|
532
533
|
if (e == null || e === "") return null;
|
|
533
534
|
let t = Number(e);
|
|
534
535
|
return Number.isFinite(t) ? t : null;
|
|
535
536
|
}
|
|
536
|
-
function
|
|
537
|
-
let t =
|
|
537
|
+
function at(e) {
|
|
538
|
+
let t = g(nt, []) ?? [];
|
|
538
539
|
if (t.includes(e)) return !0;
|
|
539
540
|
let n = [...t, e];
|
|
540
|
-
return
|
|
541
|
-
}
|
|
542
|
-
async function
|
|
543
|
-
if (typeof window > "u" ||
|
|
544
|
-
let a =
|
|
545
|
-
if (
|
|
546
|
-
let o =
|
|
547
|
-
if (!
|
|
548
|
-
let c = r === void 0 ?
|
|
541
|
+
return _(nt, n.length > rt ? n.slice(-300) : n), !1;
|
|
542
|
+
}
|
|
543
|
+
async function Y(e, { eventId: t = null, widgetId: n, venueId: r, error: i } = {}) {
|
|
544
|
+
if (typeof window > "u" || L()) return;
|
|
545
|
+
let a = N();
|
|
546
|
+
if (Xe(a), e === "link_click" && !Me(a.utm)) return;
|
|
547
|
+
let o = G(), s = n === void 0 ? Fe() : n;
|
|
548
|
+
if (!tt.has(e) && at(it(e, t, s, a.utm.utmSource, a.utm.utmCampaign, o, a.pageUrl, i ? `${i.stage}:${i.errName}` : ""))) return;
|
|
549
|
+
let c = r === void 0 ? Ie() : r, l = B(), u = {
|
|
549
550
|
eventType: e,
|
|
550
|
-
eventId:
|
|
551
|
-
venueId:
|
|
551
|
+
eventId: J(t),
|
|
552
|
+
venueId: J(c),
|
|
552
553
|
widgetId: s,
|
|
553
554
|
utmSource: a.utm.utmSource,
|
|
554
555
|
utmMedium: a.utm.utmMedium,
|
|
@@ -556,8 +557,8 @@ async function Q(e, { eventId: t = null, widgetId: n, venueId: r, error: i } = {
|
|
|
556
557
|
utmContent: a.utm.utmContent,
|
|
557
558
|
utmTerm: a.utm.utmTerm,
|
|
558
559
|
sessionId: o,
|
|
559
|
-
visitorId:
|
|
560
|
-
deviceType:
|
|
560
|
+
visitorId: K(),
|
|
561
|
+
deviceType: Re(),
|
|
561
562
|
referrer: l ? a.referrer : "",
|
|
562
563
|
pageUrl: l ? a.pageUrl : "",
|
|
563
564
|
...i ? {
|
|
@@ -569,46 +570,46 @@ async function Q(e, { eventId: t = null, widgetId: n, venueId: r, error: i } = {
|
|
|
569
570
|
await fetch(`${T()}/track/pageview`, {
|
|
570
571
|
method: "POST",
|
|
571
572
|
headers: { "Content-Type": "application/json" },
|
|
572
|
-
body: JSON.stringify(
|
|
573
|
+
body: JSON.stringify(u),
|
|
573
574
|
keepalive: !0
|
|
574
575
|
});
|
|
575
576
|
} catch (t) {
|
|
576
|
-
|
|
577
|
+
Ze.error(`Beacon '${e}' failed:`, t);
|
|
577
578
|
}
|
|
578
579
|
}
|
|
579
|
-
var
|
|
580
|
+
var ot = (e, t) => Y("link_click", {
|
|
580
581
|
widgetId: e,
|
|
581
582
|
venueId: t
|
|
582
|
-
}),
|
|
583
|
+
}), st = (e, t) => Y("widget_load", {
|
|
583
584
|
widgetId: e,
|
|
584
585
|
venueId: t
|
|
585
|
-
}),
|
|
586
|
+
}), ct = (e, t) => Y("list_view", {
|
|
586
587
|
widgetId: e,
|
|
587
588
|
venueId: t
|
|
588
|
-
}),
|
|
589
|
+
}), lt = (e, t, n) => Y("event_view", {
|
|
589
590
|
eventId: e,
|
|
590
591
|
widgetId: t,
|
|
591
592
|
venueId: n
|
|
592
|
-
}),
|
|
593
|
+
}), ut = (e, t, n) => Y("add_to_cart", {
|
|
593
594
|
eventId: e,
|
|
594
595
|
widgetId: t,
|
|
595
596
|
venueId: n
|
|
596
|
-
}),
|
|
597
|
+
}), dt = (e, t, n) => Y("checkout_started", {
|
|
597
598
|
eventId: e,
|
|
598
599
|
widgetId: t,
|
|
599
600
|
venueId: n
|
|
600
|
-
}),
|
|
601
|
+
}), ft = (e, t, n) => Y("purchase", {
|
|
601
602
|
eventId: e,
|
|
602
603
|
widgetId: t,
|
|
603
604
|
venueId: n
|
|
604
605
|
});
|
|
605
|
-
function
|
|
606
|
+
function pt(e, t, n, r) {
|
|
606
607
|
try {
|
|
607
|
-
|
|
608
|
+
Y("widget_error", {
|
|
608
609
|
widgetId: n,
|
|
609
610
|
venueId: r,
|
|
610
611
|
error: {
|
|
611
|
-
errName:
|
|
612
|
+
errName: et(e),
|
|
612
613
|
stage: t
|
|
613
614
|
}
|
|
614
615
|
}).catch(() => {});
|
|
@@ -616,7 +617,7 @@ function ct(e, t, n, r) {
|
|
|
616
617
|
}
|
|
617
618
|
//#endregion
|
|
618
619
|
//#region src/lib/api/transformers/cart.ts
|
|
619
|
-
function
|
|
620
|
+
function mt(e) {
|
|
620
621
|
let t = e ?? {};
|
|
621
622
|
return {
|
|
622
623
|
ticketID: Number(t.TicketID ?? t.ticketID ?? 0),
|
|
@@ -625,31 +626,183 @@ function lt(e) {
|
|
|
625
626
|
status: String(t.Status ?? t.status ?? "")
|
|
626
627
|
};
|
|
627
628
|
}
|
|
628
|
-
function
|
|
629
|
-
let t = e ?? {},
|
|
629
|
+
function ht(e) {
|
|
630
|
+
let t = e ?? {}, n = t.Amount ?? t.amount, i = Number(n);
|
|
630
631
|
return {
|
|
631
632
|
giftCardId: Number(t.GiftCardID ?? t.giftCardId ?? 0),
|
|
632
633
|
maskedCode: String(t.MaskedCode ?? t.maskedCode ?? ""),
|
|
633
|
-
amount:
|
|
634
|
+
amount: n == null || !Number.isFinite(i) ? null : o(r(i))
|
|
634
635
|
};
|
|
635
636
|
}
|
|
636
|
-
function
|
|
637
|
+
function gt(e) {
|
|
637
638
|
let t = e ?? {};
|
|
638
639
|
return {
|
|
639
640
|
uuid: t.UUID ?? t.uuid ?? "",
|
|
640
641
|
eventID: Number(t.EventID ?? t.eventID ?? 0),
|
|
641
642
|
status: t.Status ?? t.status ?? "",
|
|
642
643
|
expiresAt: t.ExpiresAt ?? t.expiresAt ?? "",
|
|
643
|
-
reservations: (t.Reservations ?? t.reservations ?? []).map(
|
|
644
|
-
giftCards: (t.GiftCards ?? t.giftCards ?? []).map(
|
|
644
|
+
reservations: (t.Reservations ?? t.reservations ?? []).map(mt),
|
|
645
|
+
giftCards: (t.GiftCards ?? t.giftCards ?? []).map(ht)
|
|
645
646
|
};
|
|
646
647
|
}
|
|
647
648
|
//#endregion
|
|
649
|
+
//#region src/lib/i18n/localeLoader.svelte.js
|
|
650
|
+
var X = c.state(0);
|
|
651
|
+
function _t() {
|
|
652
|
+
return c.get(X);
|
|
653
|
+
}
|
|
654
|
+
function vt() {
|
|
655
|
+
c.set(X, c.get(X) + 1);
|
|
656
|
+
}
|
|
657
|
+
//#endregion
|
|
658
|
+
//#region src/lib/i18n/createI18n.js
|
|
659
|
+
function Z() {
|
|
660
|
+
return typeof navigator > "u" ? null : navigator.language || navigator.userLanguage || null;
|
|
661
|
+
}
|
|
662
|
+
function yt({ defaults: t, locales: n = {}, loaders: r = {} }) {
|
|
663
|
+
let i = n.en ?? t, a = /* @__PURE__ */ new Map(), o = /* @__PURE__ */ new Map();
|
|
664
|
+
function s(e) {
|
|
665
|
+
return n[e] ? n[e] : a.has(e) ? a.get(e) : null;
|
|
666
|
+
}
|
|
667
|
+
function c(e) {
|
|
668
|
+
let t = s(e);
|
|
669
|
+
if (t) return Promise.resolve(t);
|
|
670
|
+
if (o.has(e)) return o.get(e);
|
|
671
|
+
let n = r[e];
|
|
672
|
+
if (!n) return Promise.resolve(null);
|
|
673
|
+
let i = Promise.resolve().then(n).then((t) => (a.set(e, t), vt(), t));
|
|
674
|
+
return i.catch(() => o.delete(e)), o.set(e, i), i;
|
|
675
|
+
}
|
|
676
|
+
function l(e) {
|
|
677
|
+
if (_t(), !e || typeof e != "string") return {
|
|
678
|
+
labels: i,
|
|
679
|
+
locale: "en"
|
|
680
|
+
};
|
|
681
|
+
let t = e.toLowerCase(), n = s(t);
|
|
682
|
+
if (n) return {
|
|
683
|
+
labels: n,
|
|
684
|
+
locale: t
|
|
685
|
+
};
|
|
686
|
+
if (r[t]) return c(t), {
|
|
687
|
+
labels: i,
|
|
688
|
+
locale: "en"
|
|
689
|
+
};
|
|
690
|
+
let a = t.split("-")[0], o = s(a);
|
|
691
|
+
return o ? {
|
|
692
|
+
labels: o,
|
|
693
|
+
locale: a
|
|
694
|
+
} : (r[a] && c(a), {
|
|
695
|
+
labels: i,
|
|
696
|
+
locale: "en"
|
|
697
|
+
});
|
|
698
|
+
}
|
|
699
|
+
function u(n = void 0, r = {}) {
|
|
700
|
+
let { labels: i } = l(n || Z() || "en");
|
|
701
|
+
return e(e(t, i), r);
|
|
702
|
+
}
|
|
703
|
+
function d(e) {
|
|
704
|
+
if (!e || typeof e != "string") return Promise.resolve(i);
|
|
705
|
+
let t = e.toLowerCase();
|
|
706
|
+
if (s(t) || r[t]) return c(t);
|
|
707
|
+
let n = t.split("-")[0];
|
|
708
|
+
return s(n) || r[n] ? c(n) : Promise.resolve(null);
|
|
709
|
+
}
|
|
710
|
+
function f() {
|
|
711
|
+
return Array.from(/* @__PURE__ */ new Set([...Object.keys(n), ...Object.keys(r)]));
|
|
712
|
+
}
|
|
713
|
+
return {
|
|
714
|
+
resolveLocale: l,
|
|
715
|
+
getLabelsForLocale: u,
|
|
716
|
+
listLocales: f,
|
|
717
|
+
loadLocale: d
|
|
718
|
+
};
|
|
719
|
+
}
|
|
720
|
+
//#endregion
|
|
721
|
+
//#region src/lib/i18n/localeSpec.js
|
|
722
|
+
var bt = [
|
|
723
|
+
[
|
|
724
|
+
"es",
|
|
725
|
+
"es",
|
|
726
|
+
"es"
|
|
727
|
+
],
|
|
728
|
+
[
|
|
729
|
+
"fr",
|
|
730
|
+
"fr",
|
|
731
|
+
"fr"
|
|
732
|
+
],
|
|
733
|
+
[
|
|
734
|
+
"pt-br",
|
|
735
|
+
"pt-br",
|
|
736
|
+
"pt_br"
|
|
737
|
+
],
|
|
738
|
+
[
|
|
739
|
+
"pt",
|
|
740
|
+
"pt-br",
|
|
741
|
+
"pt_br"
|
|
742
|
+
],
|
|
743
|
+
[
|
|
744
|
+
"de",
|
|
745
|
+
"de",
|
|
746
|
+
"de"
|
|
747
|
+
],
|
|
748
|
+
[
|
|
749
|
+
"ja",
|
|
750
|
+
"ja",
|
|
751
|
+
"ja"
|
|
752
|
+
],
|
|
753
|
+
[
|
|
754
|
+
"zh",
|
|
755
|
+
"zh",
|
|
756
|
+
"zh"
|
|
757
|
+
],
|
|
758
|
+
[
|
|
759
|
+
"ko",
|
|
760
|
+
"ko",
|
|
761
|
+
"ko"
|
|
762
|
+
],
|
|
763
|
+
[
|
|
764
|
+
"it",
|
|
765
|
+
"it",
|
|
766
|
+
"it"
|
|
767
|
+
],
|
|
768
|
+
[
|
|
769
|
+
"nl",
|
|
770
|
+
"nl",
|
|
771
|
+
"nl"
|
|
772
|
+
],
|
|
773
|
+
[
|
|
774
|
+
"tr",
|
|
775
|
+
"tr",
|
|
776
|
+
"tr"
|
|
777
|
+
],
|
|
778
|
+
[
|
|
779
|
+
"id",
|
|
780
|
+
"id",
|
|
781
|
+
"id"
|
|
782
|
+
],
|
|
783
|
+
[
|
|
784
|
+
"pl",
|
|
785
|
+
"pl",
|
|
786
|
+
"pl"
|
|
787
|
+
]
|
|
788
|
+
];
|
|
789
|
+
Array.from(new Set(bt.map(([, e]) => e)));
|
|
790
|
+
//#endregion
|
|
791
|
+
//#region src/lib/i18n/buyerLocale.ts
|
|
792
|
+
var xt = new Map([["en", "en"], ...bt.map(([e]) => [e, e === "pt" || e === "pt-br" ? "pt-BR" : e])]);
|
|
793
|
+
function Q(e) {
|
|
794
|
+
let t = e || Z();
|
|
795
|
+
if (!t || typeof t != "string") return;
|
|
796
|
+
let n = t.toLowerCase();
|
|
797
|
+
return xt.get(n) ?? xt.get(n.split("-")[0]);
|
|
798
|
+
}
|
|
799
|
+
//#endregion
|
|
648
800
|
//#region src/lib/api/orders.ts
|
|
649
|
-
var $ =
|
|
650
|
-
async function
|
|
801
|
+
var $ = n("VC");
|
|
802
|
+
async function St(e, t, n, r, i) {
|
|
803
|
+
let a = Q(i);
|
|
651
804
|
try {
|
|
652
|
-
let i = await
|
|
805
|
+
let i = await O(`${E()}/cart/${e}/payment-intent`, {
|
|
653
806
|
productQuantities: t,
|
|
654
807
|
...n && Object.keys(n).length > 0 ? { donationAmounts: n } : {},
|
|
655
808
|
...r ? {
|
|
@@ -660,9 +813,10 @@ async function ft(e, t, n, r) {
|
|
|
660
813
|
questionAnswer: r.questionAnswer ?? "",
|
|
661
814
|
mailingList: r.mailingList ?? !1
|
|
662
815
|
} : {},
|
|
663
|
-
attribution:
|
|
816
|
+
attribution: q(),
|
|
817
|
+
...a ? { locale: a } : {}
|
|
664
818
|
});
|
|
665
|
-
if (!i.success) throw $.error("Payment intent creation failed:", i.error), new
|
|
819
|
+
if (!i.success) throw $.error("Payment intent creation failed:", i.error), new l(i.error || "Failed to create payment intent", i.statusCode ?? 0, {
|
|
666
820
|
endpoint: `${E()}/cart/${e}/payment-intent`,
|
|
667
821
|
method: "POST"
|
|
668
822
|
});
|
|
@@ -671,12 +825,12 @@ async function ft(e, t, n, r) {
|
|
|
671
825
|
return $.error("createPaymentIntent error:", e), null;
|
|
672
826
|
}
|
|
673
827
|
}
|
|
674
|
-
async function
|
|
828
|
+
async function Ct(e, t) {
|
|
675
829
|
if (!e) return null;
|
|
676
830
|
try {
|
|
677
|
-
let n = await
|
|
831
|
+
let n = await D(`${E()}/cart/${e}`);
|
|
678
832
|
if (!n.success) return null;
|
|
679
|
-
let { uuid: r, eventID: i, status: a, expiresAt: o, reservations: s, giftCards: c } =
|
|
833
|
+
let { uuid: r, eventID: i, status: a, expiresAt: o, reservations: s, giftCards: c } = gt(n.data);
|
|
680
834
|
return a !== "reserved" && a !== "active" || t !== void 0 && i !== Number(t) ? null : {
|
|
681
835
|
uuid: r,
|
|
682
836
|
eventID: i,
|
|
@@ -689,7 +843,7 @@ async function pt(e, t) {
|
|
|
689
843
|
return $.error("getCartByUUID error:", e), null;
|
|
690
844
|
}
|
|
691
845
|
}
|
|
692
|
-
async function
|
|
846
|
+
async function wt(e, t, n) {
|
|
693
847
|
try {
|
|
694
848
|
let r = {};
|
|
695
849
|
for (let [e, n] of Object.entries(t)) {
|
|
@@ -718,9 +872,9 @@ async function mt(e, t, n) {
|
|
|
718
872
|
return $.error("updateCartQuantities error:", e), !1;
|
|
719
873
|
}
|
|
720
874
|
}
|
|
721
|
-
async function
|
|
875
|
+
async function Tt(e, t = "") {
|
|
722
876
|
try {
|
|
723
|
-
let n = await
|
|
877
|
+
let n = await O(`${T()}/orders/${e}/refund`, { message: t });
|
|
724
878
|
return n.success ? { success: !0 } : ($.error("Refund request failed:", n.error), {
|
|
725
879
|
success: !1,
|
|
726
880
|
error: n.error || "Failed to submit refund request"
|
|
@@ -732,35 +886,37 @@ async function ht(e, t = "") {
|
|
|
732
886
|
};
|
|
733
887
|
}
|
|
734
888
|
}
|
|
735
|
-
async function
|
|
889
|
+
async function Et(e, t, n) {
|
|
890
|
+
let r = Q(n);
|
|
736
891
|
try {
|
|
737
|
-
let n = await
|
|
892
|
+
let n = await O(`${E()}/validatePaymentIntent/${e}`, {
|
|
738
893
|
...t,
|
|
739
|
-
attribution:
|
|
894
|
+
attribution: q(),
|
|
895
|
+
...r ? { locale: r } : {}
|
|
740
896
|
});
|
|
741
897
|
if (!n.success) return $.error("Payment validation failed:", n.error), {
|
|
742
898
|
success: !1,
|
|
743
899
|
status: "failed",
|
|
744
900
|
error: n.error || "Payment validation failed"
|
|
745
901
|
};
|
|
746
|
-
let
|
|
747
|
-
return
|
|
902
|
+
let i = n.data;
|
|
903
|
+
return i.eventCanceled || i.eventPostponed ? {
|
|
748
904
|
success: !1,
|
|
749
905
|
status: "failed",
|
|
750
|
-
eventCanceled:
|
|
751
|
-
eventPostponed:
|
|
906
|
+
eventCanceled: i.eventCanceled,
|
|
907
|
+
eventPostponed: i.eventPostponed
|
|
752
908
|
} : {
|
|
753
909
|
success: !0,
|
|
754
|
-
status:
|
|
755
|
-
orderUUID:
|
|
910
|
+
status: i.status || "Payment succeeded",
|
|
911
|
+
orderUUID: i.orderUUID || i.uuid
|
|
756
912
|
};
|
|
757
913
|
} catch (e) {
|
|
758
914
|
return $.error("validatePaymentIntent error:", e), null;
|
|
759
915
|
}
|
|
760
916
|
}
|
|
761
|
-
async function
|
|
917
|
+
async function Dt(e) {
|
|
762
918
|
try {
|
|
763
|
-
let t = await
|
|
919
|
+
let t = await O(`${T()}/orders/extend-session`, { orderUuid: e });
|
|
764
920
|
if (!t.success) return {
|
|
765
921
|
success: !1,
|
|
766
922
|
error: t.error || "Failed to extend session",
|
|
@@ -779,9 +935,9 @@ async function _t(e) {
|
|
|
779
935
|
};
|
|
780
936
|
}
|
|
781
937
|
}
|
|
782
|
-
async function
|
|
938
|
+
async function Ot(e) {
|
|
783
939
|
try {
|
|
784
|
-
let t = await
|
|
940
|
+
let t = await D(`${T()}/orders/session/${e}`);
|
|
785
941
|
if (!t.success) return {
|
|
786
942
|
error: t.error || "No active session found",
|
|
787
943
|
notFound: t.statusCode === 404
|
|
@@ -800,4 +956,4 @@ async function vt(e) {
|
|
|
800
956
|
}
|
|
801
957
|
}
|
|
802
958
|
//#endregion
|
|
803
|
-
export {
|
|
959
|
+
export { l as $, Ce as A, me as B, Ve as C, Ne as D, Pe as E, E as F, fe as G, ce as H, T as I, g as J, se as K, he as L, O as M, be as N, Oe as O, w as P, _ as Q, Te as R, L as S, Ue as T, pe as U, de as V, ue as W, ae as X, ie as Y, h as Z, pt as _, Tt as a, K as b, Q as c, ut as d, dt as f, ft as g, ct as h, Ot as i, D as j, ke as k, yt as l, ot as m, Dt as n, wt as o, lt as p, m as q, Ct as r, Et as s, St as t, Z as u, st as v, Be as w, B as x, q as y, we as z };
|