@getmicdrop/venue-calendar 4.2.10 → 4.2.11

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.
Files changed (53) hide show
  1. package/dist/{CartView-Bka7Ouuf.js → CartView-DKEYzXBY.js} +11 -11
  2. package/dist/{Checkout-DH268Kso.js → Checkout-ClTYS0Sk.js} +12 -12
  3. package/dist/{Checkout-LkiR2I6U.js → Checkout-W22fMD3O.js} +264 -243
  4. package/dist/{CheckoutTimer-C4SBpf38.js → CheckoutTimer-C9tJJZC8.js} +1 -1
  5. package/dist/{CollectionView-CQ6BKmpp.js → CollectionView-CrbFmrTG.js} +4 -4
  6. package/dist/{Event-Dt-7Pau8.js → Event-BDXfT25f.js} +7 -7
  7. package/dist/{EventPage-CkziHztQ.js → EventPage-ZaARiPwa.js} +10 -10
  8. package/dist/{ScarcityBadge-hVqsuotm.js → ScarcityBadge-R32tzjFi.js} +1 -1
  9. package/dist/{SeriesPage-CtVo7ltY.js → SeriesPage-D06QOPK7.js} +3 -3
  10. package/dist/{Success-CgLRsVYC.js → Success-CvoORmAN.js} +15 -15
  11. package/dist/{ViewTicketsEmbed-CKucKt-W.js → ViewTicketsEmbed-C0QPIbpw.js} +6 -6
  12. package/dist/{__SKIP_PATHS__-BTbGfN80.js → __SKIP_PATHS__-DmdRxELE.js} +1 -1
  13. package/dist/api/api.cjs +1 -1
  14. package/dist/api/api.mjs +267 -252
  15. package/dist/api/gift-cards.d.ts +13 -3
  16. package/dist/api/orders.d.ts +12 -0
  17. package/dist/api/transformers/cart.d.ts +16 -1
  18. package/dist/{colors-fhDq0k7I.js → colors-Dk53YuNz.js} +80 -75
  19. package/dist/{event-transform-eNiddvbF.js → event-transform-DUqXNcXz.js} +1 -1
  20. package/dist/{eventStatusStream-sq6uPnMe.js → eventStatusStream-C5KadkMh.js} +1 -1
  21. package/dist/{i18n-Bk8x-2nR.js → i18n-nPKgIP_8.js} +2 -2
  22. package/dist/{labels-Djxn2Lvi.js → labels-YAwDbsF8.js} +1 -1
  23. package/dist/{orders-NZP81zYT.js → orders-xGH8-IQn.js} +264 -216
  24. package/dist/{pixels-BBruZizp.js → pixels-Hb-kLRzV.js} +8 -8
  25. package/dist/{utils-CAxbM_uh.js → utils-CcxQIxOO.js} +49 -49
  26. package/dist/venue-calendar.es.js +740 -740
  27. package/dist/venue-calendar.iife.js +57 -57
  28. package/dist/venue-calendar.umd.js +47 -47
  29. package/package.json +1 -1
  30. /package/dist/locales/{4.2.10 → 4.2.11}/flow/de.js +0 -0
  31. /package/dist/locales/{4.2.10 → 4.2.11}/flow/es.js +0 -0
  32. /package/dist/locales/{4.2.10 → 4.2.11}/flow/fr.js +0 -0
  33. /package/dist/locales/{4.2.10 → 4.2.11}/flow/id.js +0 -0
  34. /package/dist/locales/{4.2.10 → 4.2.11}/flow/it.js +0 -0
  35. /package/dist/locales/{4.2.10 → 4.2.11}/flow/ja.js +0 -0
  36. /package/dist/locales/{4.2.10 → 4.2.11}/flow/ko.js +0 -0
  37. /package/dist/locales/{4.2.10 → 4.2.11}/flow/nl.js +0 -0
  38. /package/dist/locales/{4.2.10 → 4.2.11}/flow/pl.js +0 -0
  39. /package/dist/locales/{4.2.10 → 4.2.11}/flow/pt-br.js +0 -0
  40. /package/dist/locales/{4.2.10 → 4.2.11}/flow/tr.js +0 -0
  41. /package/dist/locales/{4.2.10 → 4.2.11}/flow/zh.js +0 -0
  42. /package/dist/locales/{4.2.10 → 4.2.11}/main/de.js +0 -0
  43. /package/dist/locales/{4.2.10 → 4.2.11}/main/es.js +0 -0
  44. /package/dist/locales/{4.2.10 → 4.2.11}/main/fr.js +0 -0
  45. /package/dist/locales/{4.2.10 → 4.2.11}/main/id.js +0 -0
  46. /package/dist/locales/{4.2.10 → 4.2.11}/main/it.js +0 -0
  47. /package/dist/locales/{4.2.10 → 4.2.11}/main/ja.js +0 -0
  48. /package/dist/locales/{4.2.10 → 4.2.11}/main/ko.js +0 -0
  49. /package/dist/locales/{4.2.10 → 4.2.11}/main/nl.js +0 -0
  50. /package/dist/locales/{4.2.10 → 4.2.11}/main/pl.js +0 -0
  51. /package/dist/locales/{4.2.10 → 4.2.11}/main/pt-br.js +0 -0
  52. /package/dist/locales/{4.2.10 → 4.2.11}/main/tr.js +0 -0
  53. /package/dist/locales/{4.2.10 → 4.2.11}/main/zh.js +0 -0
@@ -1,6 +1,6 @@
1
1
  import { x as e } from "./Button-C4uFgl7L.js";
2
2
  import { E as t } from "./timezones-C5l0SSHK.js";
3
- import { _ as n, v as r, x as i } from "./orders-NZP81zYT.js";
3
+ import { S as n, v as r, y as i } from "./orders-xGH8-IQn.js";
4
4
  //#region src/lib/embed-bridge.js
5
5
  var a = e("embed-bridge"), o = "micdrop-calendar", s = Object.freeze({
6
6
  NAVIGATION: "MICDROP_NAVIGATION",
@@ -85,7 +85,7 @@ function m(e) {
85
85
  //#endregion
86
86
  //#region src/lib/pixels/script.ts
87
87
  function h(e) {
88
- if (typeof document > "u" || !e || r()) return;
88
+ if (typeof document > "u" || !e || i()) return;
89
89
  let t = document.createElement("script");
90
90
  t.async = !0, t.src = e;
91
91
  let n = document.head || document.getElementsByTagName("head")[0];
@@ -214,9 +214,9 @@ function V() {
214
214
  }
215
215
  function H(e) {
216
216
  if (!(!e || typeof e != "object")) {
217
- e.metaPixelId !== void 0 && (I.metaPixelId = B(e.metaPixelId)), e.ga4MeasurementId !== void 0 && (I.ga4MeasurementId = B(e.ga4MeasurementId)), i();
217
+ e.metaPixelId !== void 0 && (I.metaPixelId = B(e.metaPixelId)), e.ga4MeasurementId !== void 0 && (I.ga4MeasurementId = B(e.ga4MeasurementId)), n();
218
218
  try {
219
- V() && !r() && G();
219
+ V() && !i() && G();
220
220
  } catch (e) {
221
221
  M.error("configurePixels load failed:", e);
222
222
  }
@@ -229,7 +229,7 @@ function W() {
229
229
  U(), q(), J();
230
230
  }
231
231
  function G() {
232
- n() ? W() : Y();
232
+ r() ? W() : Y();
233
233
  }
234
234
  function K(e) {
235
235
  U(), I.metaPixelId && w(e), I.ga4MeasurementId && j(e);
@@ -247,12 +247,12 @@ function Y() {
247
247
  if (z !== null || typeof window > "u") return;
248
248
  let e = 0;
249
249
  z = setInterval(() => {
250
- e += 1, n() ? W() : e >= P && J();
250
+ e += 1, r() ? W() : e >= P && J();
251
251
  }, N);
252
252
  }
253
253
  function X(e) {
254
- if (V() && !r()) try {
255
- n() ? (q(), K(e), J()) : (R.push(e), R.length > F && R.shift(), Y());
254
+ if (V() && !i()) try {
255
+ r() ? (q(), K(e), J()) : (R.push(e), R.length > F && R.shift(), Y());
256
256
  } catch (t) {
257
257
  M.error(`Pixel '${e.kind}' failed:`, t);
258
258
  }
@@ -1,6 +1,6 @@
1
1
  import { x as e } from "./Button-C4uFgl7L.js";
2
- import { D as t, G as n, M as r, O as i, T as a, U as o, Y as s, q as c } from "./orders-NZP81zYT.js";
3
- import "./event-transform-eNiddvbF.js";
2
+ import { E as t, J as n, K as r, N as i, O as a, W as o, X as s, k as c } from "./orders-xGH8-IQn.js";
3
+ import "./event-transform-DUqXNcXz.js";
4
4
  //#region node_modules/js-cookie/dist/js.cookie.mjs
5
5
  function l(e) {
6
6
  for (var t = 1; t < arguments.length; t++) {
@@ -79,18 +79,18 @@ function T() {
79
79
  };
80
80
  }
81
81
  function E(e) {
82
- let t = {}, r = {}, i = [], a = "", s = 0;
82
+ let t = {}, i = {}, a = [], s = "", c = 0;
83
83
  if (typeof window > "u") return {
84
84
  quantities: t,
85
- donationAmounts: r,
86
- promocode: a,
87
- promoDiscountAmount: s,
88
- tickets: i
85
+ donationAmounts: i,
86
+ promocode: s,
87
+ promoDiscountAmount: c,
88
+ tickets: a
89
89
  };
90
90
  let l = o(y(e), null);
91
91
  if (!l) {
92
92
  let t = o(b(e), null);
93
- t && (l = t, c(y(e), t), n(b(e)));
93
+ t && (l = t, n(y(e), t), r(b(e)));
94
94
  }
95
95
  if (l) return {
96
96
  quantities: l.quantities || {},
@@ -105,64 +105,64 @@ function E(e) {
105
105
  g.warn("Failed to parse checkout quantities cookie:", e), t = {};
106
106
  }
107
107
  try {
108
- i = JSON.parse(m(`checkout-tickets-${e}`) || "[]");
108
+ a = JSON.parse(m(`checkout-tickets-${e}`) || "[]");
109
109
  } catch (e) {
110
- g.warn("Failed to parse checkout tickets cookie:", e), i = [];
110
+ g.warn("Failed to parse checkout tickets cookie:", e), a = [];
111
111
  }
112
- return a = m(`checkout-promocode-${e}`) || "", s = parseFloat(m(`checkout-promo-discount-${e}`) || "0"), (Object.keys(t).length > 0 || i.length > 0 || a) && (k({
112
+ return s = m(`checkout-promocode-${e}`) || "", c = parseFloat(m(`checkout-promo-discount-${e}`) || "0"), (Object.keys(t).length > 0 || a.length > 0 || s) && (k({
113
113
  eventID: e,
114
114
  quantities: t,
115
- donationAmounts: r,
116
- promocode: a,
117
- promoDiscountAmount: s,
118
- tickets: i
115
+ donationAmounts: i,
116
+ promocode: s,
117
+ promoDiscountAmount: c,
118
+ tickets: a
119
119
  }), D(e)), {
120
120
  quantities: t,
121
- donationAmounts: r,
122
- promocode: a,
123
- promoDiscountAmount: s,
124
- tickets: i
121
+ donationAmounts: i,
122
+ promocode: s,
123
+ promoDiscountAmount: c,
124
+ tickets: a
125
125
  };
126
126
  }
127
127
  function D(e) {
128
128
  h(`checkout-quantities-${e}`), h(`checkout-tickets-${e}`), h(`checkout-promocode-${e}`), h(`checkout-promo-discount-${e}`);
129
129
  }
130
130
  function O(e) {
131
- n(y(e)), n(b(e)), D(e), h(`checkout-promo-discount-type-${e}`), h(`checkout-promo-reveal-${e}`), h(`checkout-promo-reveal-ids-${e}`), h(`checkout-promo-ticket-ids-${e}`);
131
+ r(y(e)), r(b(e)), D(e), h(`checkout-promo-discount-type-${e}`), h(`checkout-promo-reveal-${e}`), h(`checkout-promo-reveal-ids-${e}`), h(`checkout-promo-ticket-ids-${e}`);
132
132
  }
133
- function k({ eventID: e, quantities: t, donationAmounts: n, promocode: r, promoDiscountAmount: i, tickets: a }) {
133
+ function k({ eventID: e, quantities: t, donationAmounts: r, promocode: i, promoDiscountAmount: a, tickets: o }) {
134
134
  if (typeof window > "u") return;
135
- let o = (a || []).map((e) => ({
135
+ let s = (o || []).map((e) => ({
136
136
  ID: e.ID,
137
137
  name: e.name,
138
138
  price: e.price,
139
139
  type: e.type,
140
140
  visibility: e.visibility,
141
141
  salesChannel: e.salesChannel
142
- })), s = {
142
+ })), c = {
143
143
  quantities: t || {},
144
- donationAmounts: n || {},
145
- promocode: r || "",
146
- promoDiscountAmount: i || 0,
147
- tickets: o,
144
+ donationAmounts: r || {},
145
+ promocode: i || "",
146
+ promoDiscountAmount: a || 0,
147
+ tickets: s,
148
148
  updatedAt: Date.now()
149
149
  };
150
- c(y(e), s);
150
+ n(y(e), c);
151
151
  }
152
152
  function A(e) {
153
153
  if (!e) return null;
154
154
  let t = o(x(e), null);
155
155
  if (t != null) return N(t);
156
- let r = o(S(e), null);
157
- if (r == null) return null;
158
- let i = N(r);
159
- return i != null && (c(x(e), i), n(S(e))), i;
156
+ let i = o(S(e), null);
157
+ if (i == null) return null;
158
+ let a = N(i);
159
+ return a != null && (n(x(e), a), r(S(e))), a;
160
160
  }
161
161
  function j(e, t) {
162
- !e || !Number.isFinite(t) || c(x(e), t);
162
+ !e || !Number.isFinite(t) || n(x(e), t);
163
163
  }
164
164
  function M(e) {
165
- e && (n(x(e)), n(S(e)));
165
+ e && (r(x(e)), r(S(e)));
166
166
  }
167
167
  function N(e) {
168
168
  let t = typeof e == "number" ? e : parseInt(e, 10);
@@ -196,25 +196,25 @@ async function R() {
196
196
  }
197
197
  async function z(e) {
198
198
  try {
199
- let n = await t(`/venues/${e}`);
200
- if (!n.success) throw new s(n.error ?? `API error: ${n.statusCode}`, n.statusCode ?? 0, {
199
+ let t = await a(`/venues/${e}`);
200
+ if (!t.success) throw new s(t.error ?? `API error: ${t.statusCode}`, t.statusCode ?? 0, {
201
201
  endpoint: `/venues/${e}`,
202
202
  method: "GET"
203
203
  });
204
- return n.data;
204
+ return t.data;
205
205
  } catch (e) {
206
206
  throw I.error("getVenueDetails error:", e), e;
207
207
  }
208
208
  }
209
209
  async function B(e = {}) {
210
210
  try {
211
- let t = await R(), { eventID: n, quantities: r, donationAmounts: a, ...o } = e, s = r ? Object.fromEntries(Object.entries(r).map(([e, t]) => [parseInt(e, 10), t])) : {}, c = a ? Object.fromEntries(Object.entries(a).filter(([, e]) => parseFloat(String(e)) > 0).map(([e, t]) => [parseInt(e, 10), parseFloat(String(t))])) : void 0, l = {
211
+ let t = await R(), { eventID: n, quantities: r, donationAmounts: i, ...a } = e, o = r ? Object.fromEntries(Object.entries(r).map(([e, t]) => [parseInt(e, 10), t])) : {}, s = i ? Object.fromEntries(Object.entries(i).filter(([, e]) => parseFloat(String(e)) > 0).map(([e, t]) => [parseInt(e, 10), parseFloat(String(t))])) : void 0, l = {
212
212
  purchaserIP: t,
213
213
  eventID: n ? parseInt(String(n), 10) : void 0,
214
- quantities: s,
215
- ...c && Object.keys(c).length > 0 ? { donationAmounts: c } : {},
216
- ...o
217
- }, u = await i("/orders/create", l), d = u.data ?? {};
214
+ quantities: o,
215
+ ...s && Object.keys(s).length > 0 ? { donationAmounts: s } : {},
216
+ ...a
217
+ }, u = await c("/orders/create", l), d = u.data ?? {};
218
218
  if (!u.success || d.error) {
219
219
  let e = L(d.error) || (typeof d.message == "string" ? d.message : "") || u.error || "Order creation failed", t = e.toLowerCase();
220
220
  return {
@@ -240,15 +240,15 @@ async function B(e = {}) {
240
240
  }
241
241
  async function V(e) {
242
242
  try {
243
- let n = await t(`/orders/${e}`);
244
- if (!n.success) {
245
- let t = n.error ?? `Failed to fetch order (${n.statusCode})`;
246
- throw I.error("getOrder error response:", t), new s(t, n.statusCode ?? 0, {
243
+ let t = await a(`/orders/${e}`);
244
+ if (!t.success) {
245
+ let n = t.error ?? `Failed to fetch order (${t.statusCode})`;
246
+ throw I.error("getOrder error response:", n), new s(n, t.statusCode ?? 0, {
247
247
  endpoint: `/orders/${e}`,
248
248
  method: "GET"
249
249
  });
250
250
  }
251
- return n.data;
251
+ return t.data;
252
252
  } catch (e) {
253
253
  throw I.error("getOrder error:", e), e;
254
254
  }
@@ -257,9 +257,9 @@ async function V(e) {
257
257
  //#region src/lib/utils/utm.ts
258
258
  var H = e("utm");
259
259
  async function U(e) {
260
- let t = new URLSearchParams(window.location.search), n = a(t.get("utm_source")) || "direct";
260
+ let n = new URLSearchParams(window.location.search), r = t(n.get("utm_source")) || "direct";
261
261
  try {
262
- await fetch(`${r()}/utm/${e}/${encodeURIComponent(n)}`);
262
+ await fetch(`${i()}/utm/${e}/${encodeURIComponent(r)}`);
263
263
  } catch (e) {
264
264
  H.error("UTM tracking failed:", e);
265
265
  }