@getmicdrop/venue-calendar 4.0.96 → 4.0.98

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 (80) hide show
  1. package/README.md +740 -740
  2. package/dist/CartView-inr4N-_2.js +2360 -0
  3. package/dist/CartView-inr4N-_2.js.map +1 -0
  4. package/dist/{Checkout-DFEzsNwm.js → Checkout-BILhpPY7.js} +3 -3
  5. package/dist/Checkout-BILhpPY7.js.map +1 -0
  6. package/dist/{Checkout-SGb68I5A.js → Checkout-CssZ6V2A.js} +337 -337
  7. package/dist/Checkout-CssZ6V2A.js.map +1 -0
  8. package/dist/{CheckoutTimer-BUlr4C7O.js → CheckoutTimer-CKd1wmyV.js} +5 -5
  9. package/dist/CheckoutTimer-CKd1wmyV.js.map +1 -0
  10. package/dist/{ClockIcon-CI96OiJj.js → ClockIcon-DTUfaeDB.js} +2 -2
  11. package/dist/ClockIcon-DTUfaeDB.js.map +1 -0
  12. package/dist/{CollectionView-kDS8R_bu.js → CollectionView-eLbVZUv0.js} +40 -40
  13. package/dist/CollectionView-eLbVZUv0.js.map +1 -0
  14. package/dist/{Event-DUViqNEG.js → Event-DLA5gaig.js} +15 -11
  15. package/dist/Event-DLA5gaig.js.map +1 -0
  16. package/dist/EventPage-LK1nOFoA.js +566 -0
  17. package/dist/EventPage-LK1nOFoA.js.map +1 -0
  18. package/dist/{Heading-DtOhaDMn.js → Heading-CYIcD7lJ.js} +2 -2
  19. package/dist/Heading-CYIcD7lJ.js.map +1 -0
  20. package/dist/ScarcityBadge-CB8Wv6_P.js +165 -0
  21. package/dist/ScarcityBadge-CB8Wv6_P.js.map +1 -0
  22. package/dist/{SeriesPage-BPDSiLWH.js → SeriesPage-BhwhYFnc.js} +7 -7
  23. package/dist/SeriesPage-BhwhYFnc.js.map +1 -0
  24. package/dist/{Spinner-BUWcjtbI.js → Spinner-DllDTBA9.js} +2 -2
  25. package/dist/Spinner-DllDTBA9.js.map +1 -0
  26. package/dist/{Success-6kCesfnC.js → Success-CjemAJNU.js} +11 -7
  27. package/dist/Success-CjemAJNU.js.map +1 -0
  28. package/dist/{Text-B5MZ6L1O.js → Text-BM11r41a.js} +2 -2
  29. package/dist/Text-BM11r41a.js.map +1 -0
  30. package/dist/{VenueCalendar-BRTDpyWV.js → VenueCalendar-DDEZQUrA.js} +2134 -2103
  31. package/dist/VenueCalendar-DDEZQUrA.js.map +1 -0
  32. package/dist/{ViewTicketsEmbed-BgIXGtz6.js → ViewTicketsEmbed-BIFKEUos.js} +80 -80
  33. package/dist/ViewTicketsEmbed-BIFKEUos.js.map +1 -0
  34. package/dist/api/api.cjs +1 -1
  35. package/dist/api/api.cjs.map +1 -1
  36. package/dist/api/api.mjs +112 -106
  37. package/dist/api/api.mjs.map +1 -1
  38. package/dist/api/types.d.ts +447 -447
  39. package/dist/{data-toggle-store.svelte-D3w7V3t9.js → data-toggle-store.svelte-B6_uWGtS.js} +2 -2
  40. package/dist/data-toggle-store.svelte-B6_uWGtS.js.map +1 -0
  41. package/dist/{labels-wyDolzF_.js → labels-DmANUTR_.js} +48 -58
  42. package/dist/labels-DmANUTR_.js.map +1 -0
  43. package/dist/{modalManager.svelte-DBBSS3Zi.js → modalManager.svelte-CT1YXxAF.js} +2 -2
  44. package/dist/modalManager.svelte-CT1YXxAF.js.map +1 -0
  45. package/dist/seo/seo.cjs.map +1 -1
  46. package/dist/seo/seo.mjs.map +1 -1
  47. package/dist/{transform-Bcl3riJb.js → transform-RsoCHJIj.js} +2 -2
  48. package/dist/transform-RsoCHJIj.js.map +1 -0
  49. package/dist/types/index.d.ts +454 -454
  50. package/dist/venue-calendar.css +1 -1
  51. package/dist/venue-calendar.es.js +10 -10
  52. package/dist/venue-calendar.iife.js +39 -39
  53. package/dist/venue-calendar.iife.js.map +1 -1
  54. package/dist/venue-calendar.umd.js +34 -34
  55. package/dist/venue-calendar.umd.js.map +1 -1
  56. package/package.json +179 -176
  57. package/src/lib/theme.js +222 -222
  58. package/dist/CartView-DC-YjxhJ.js +0 -2380
  59. package/dist/CartView-DC-YjxhJ.js.map +0 -1
  60. package/dist/Checkout-DFEzsNwm.js.map +0 -1
  61. package/dist/Checkout-SGb68I5A.js.map +0 -1
  62. package/dist/CheckoutTimer-BUlr4C7O.js.map +0 -1
  63. package/dist/ClockIcon-CI96OiJj.js.map +0 -1
  64. package/dist/CollectionView-kDS8R_bu.js.map +0 -1
  65. package/dist/Event-DUViqNEG.js.map +0 -1
  66. package/dist/EventPage-CbYWOehC.js +0 -575
  67. package/dist/EventPage-CbYWOehC.js.map +0 -1
  68. package/dist/Heading-DtOhaDMn.js.map +0 -1
  69. package/dist/ScarcityBadge-CBKc57di.js +0 -167
  70. package/dist/ScarcityBadge-CBKc57di.js.map +0 -1
  71. package/dist/SeriesPage-BPDSiLWH.js.map +0 -1
  72. package/dist/Spinner-BUWcjtbI.js.map +0 -1
  73. package/dist/Success-6kCesfnC.js.map +0 -1
  74. package/dist/Text-B5MZ6L1O.js.map +0 -1
  75. package/dist/VenueCalendar-BRTDpyWV.js.map +0 -1
  76. package/dist/ViewTicketsEmbed-BgIXGtz6.js.map +0 -1
  77. package/dist/data-toggle-store.svelte-D3w7V3t9.js.map +0 -1
  78. package/dist/labels-wyDolzF_.js.map +0 -1
  79. package/dist/modalManager.svelte-DBBSS3Zi.js.map +0 -1
  80. package/dist/transform-Bcl3riJb.js.map +0 -1
package/dist/api/api.mjs CHANGED
@@ -1,5 +1,5 @@
1
1
  import { createLogger as $ } from "@getmicdrop/svelte-components/utils/logger";
2
- import { getLocalStorage as ue, setLocalStorage as le, getSessionStorage as Y, setSessionStorage as de, createLogger as fe, AppError as N, formatCurrency as me, asUSD as pe, resolveImageUrl as K } from "@getmicdrop/svelte-components";
2
+ import { getLocalStorage as ue, setLocalStorage as le, getSessionStorage as Y, setSessionStorage as de, createLogger as fe, AppError as D, formatCurrency as me, asUSD as pe, resolveImageUrl as K } from "@getmicdrop/svelte-components";
3
3
  import { formatLocal as L } from "@getmicdrop/svelte-components/datetime";
4
4
  import { isHiddenTicketPurchasable as ye } from "@getmicdrop/svelte-components/transforms";
5
5
  import "@getmicdrop/svelte-components/utils/timezones";
@@ -23,7 +23,7 @@ function c() {
23
23
  function dt() {
24
24
  return `${p.baseUrl}/api/public`;
25
25
  }
26
- function R() {
26
+ function A() {
27
27
  return `${p.baseUrl}/api/orders/v2/public`;
28
28
  }
29
29
  async function ft() {
@@ -34,7 +34,7 @@ async function Z(t, e, r) {
34
34
  const n = (e.method || "GET").toUpperCase(), s = n === "GET" || n === "HEAD" ? r.retries + 1 : 1;
35
35
  let o;
36
36
  for (let i = 1; i <= s; i++) {
37
- const u = new AbortController(), T = setTimeout(() => u.abort(), r.timeout), y = e.signal;
37
+ const u = new AbortController(), P = setTimeout(() => u.abort(), r.timeout), y = e.signal;
38
38
  let k;
39
39
  y && (y.aborted ? u.abort() : (k = () => u.abort(), y.addEventListener("abort", k, { once: !0 })));
40
40
  try {
@@ -46,7 +46,7 @@ async function Z(t, e, r) {
46
46
  } catch (g) {
47
47
  if (o = g, y?.aborted) throw g;
48
48
  } finally {
49
- clearTimeout(T), y && k && y.removeEventListener("abort", k);
49
+ clearTimeout(P), y && k && y.removeEventListener("abort", k);
50
50
  }
51
51
  i < s && await ve(r.retryDelay * Math.pow(2, i - 1));
52
52
  }
@@ -55,7 +55,7 @@ async function Z(t, e, r) {
55
55
  async function C(t, e) {
56
56
  return F("GET", t, void 0, e);
57
57
  }
58
- async function f(t, e, r) {
58
+ async function m(t, e, r) {
59
59
  return F("POST", t, e, r);
60
60
  }
61
61
  async function mt(t, e, r) {
@@ -93,7 +93,7 @@ async function F(t, e, r, n) {
93
93
  ), { success: !1, error: o };
94
94
  }
95
95
  }
96
- async function A(t, e) {
96
+ async function T(t, e) {
97
97
  try {
98
98
  const r = await Z(
99
99
  t,
@@ -195,11 +195,11 @@ function re() {
195
195
  for (let n = 0; n < 16; n++) r.push(e[n].toString(16).padStart(2, "0"));
196
196
  return `${r[0]}${r[1]}${r[2]}${r[3]}-${r[4]}${r[5]}-${r[6]}${r[7]}-${r[8]}${r[9]}-${r[10]}${r[11]}${r[12]}${r[13]}${r[14]}${r[15]}`;
197
197
  }
198
- function De() {
198
+ function Ne() {
199
199
  let t = Y(H);
200
200
  return t || (t = re(), de(H, t)), t;
201
201
  }
202
- function Ne() {
202
+ function De() {
203
203
  if (!Ee()) return null;
204
204
  const t = ue(W);
205
205
  if (Ae(t)) return t;
@@ -214,8 +214,8 @@ function xe() {
214
214
  function U() {
215
215
  const e = xe() ?? Te();
216
216
  return {
217
- sessionId: De(),
218
- visitorId: Ne(),
217
+ sessionId: Ne(),
218
+ visitorId: De(),
219
219
  utmSource: e.utm.utmSource,
220
220
  utmMedium: e.utm.utmMedium,
221
221
  utmCampaign: e.utm.utmCampaign,
@@ -228,8 +228,8 @@ fe("tracking");
228
228
  const d = $("VC");
229
229
  async function pt(t, e, r) {
230
230
  try {
231
- const n = await f(
232
- `${R()}/cart/${t}/payment-intent`,
231
+ const n = await m(
232
+ `${A()}/cart/${t}/payment-intent`,
233
233
  {
234
234
  productQuantities: e,
235
235
  ...r && Object.keys(r).length > 0 ? { donationAmounts: r } : {},
@@ -240,7 +240,7 @@ async function pt(t, e, r) {
240
240
  }
241
241
  );
242
242
  if (!n.success)
243
- throw d.error("Payment intent creation failed:", n.error), new N(
243
+ throw d.error("Payment intent creation failed:", n.error), new D(
244
244
  n.error || "Failed to create payment intent",
245
245
  "lib/api/orders/createPaymentIntent"
246
246
  );
@@ -253,7 +253,7 @@ async function yt(t, e) {
253
253
  if (!t) return null;
254
254
  try {
255
255
  const r = await C(
256
- `${R()}/cart/${t}`
256
+ `${A()}/cart/${t}`
257
257
  );
258
258
  if (!r.success)
259
259
  return null;
@@ -278,7 +278,7 @@ async function gt(t, e, r) {
278
278
  const u = typeof o == "number" ? o : parseInt(o, 10);
279
279
  !Number.isNaN(u) && i > 0 && (a[u] = i);
280
280
  }
281
- const s = await fetch(`${R()}/cart/${t}`, {
281
+ const s = await fetch(`${A()}/cart/${t}`, {
282
282
  method: "PUT",
283
283
  headers: { "Content-Type": "application/json" },
284
284
  credentials: "include",
@@ -298,7 +298,7 @@ async function gt(t, e, r) {
298
298
  }
299
299
  async function vt(t) {
300
300
  try {
301
- const e = await f(
301
+ const e = await m(
302
302
  `${c()}/orders/complete/${t}`
303
303
  );
304
304
  return e.success ? {
@@ -314,7 +314,7 @@ async function vt(t) {
314
314
  }
315
315
  async function ht(t) {
316
316
  try {
317
- const e = await f(
317
+ const e = await m(
318
318
  `${c()}/orders/cancel/${t}`
319
319
  );
320
320
  return e.success ? {
@@ -330,7 +330,7 @@ async function ht(t) {
330
330
  }
331
331
  async function _t(t, e) {
332
332
  try {
333
- const r = await f(
333
+ const r = await m(
334
334
  `${c()}/orders/create`,
335
335
  // attribution (MISSION-TRUTH C2) rides on cart-create additively.
336
336
  { eventID: t, promoCode: e, attribution: U() }
@@ -341,11 +341,11 @@ async function _t(t, e) {
341
341
  }
342
342
  }
343
343
  async function wt(t) {
344
- return A(`${c()}/orders/${t}`);
344
+ return T(`${c()}/orders/${t}`);
345
345
  }
346
346
  async function kt(t, e) {
347
347
  try {
348
- const r = await f(`${R()}/validatePaymentIntent/${t}`, {
348
+ const r = await m(`${A()}/validatePaymentIntent/${t}`, {
349
349
  ...e,
350
350
  attribution: U()
351
351
  });
@@ -372,7 +372,7 @@ async function kt(t, e) {
372
372
  }
373
373
  async function bt(t) {
374
374
  try {
375
- const e = await f(`${c()}/orders/extend-session`, { orderUuid: t });
375
+ const e = await m(`${c()}/orders/extend-session`, { orderUuid: t });
376
376
  if (!e.success)
377
377
  return {
378
378
  success: !1,
@@ -414,7 +414,7 @@ async function $t(t) {
414
414
  }
415
415
  async function Ct(t = { eventID: "" }) {
416
416
  try {
417
- const e = await f(
417
+ const e = await m(
418
418
  `${c()}/orders/create`,
419
419
  // attribution (MISSION-TRUTH C2) rides on cart-create additively.
420
420
  { ...t, attribution: U() }
@@ -435,7 +435,7 @@ async function Tt(t) {
435
435
  d.error("UTM tracking failed:", n);
436
436
  }
437
437
  }
438
- const V = $("VC"), Oe = () => R();
438
+ const V = $("VC"), Oe = () => A();
439
439
  async function Pt(t, e) {
440
440
  try {
441
441
  if (!e || !e.trim())
@@ -471,7 +471,7 @@ async function St(t) {
471
471
  }
472
472
  async function It(t, e) {
473
473
  try {
474
- const r = await f(
474
+ const r = await m(
475
475
  `${Oe()}/cart/${t}/apply-promo`,
476
476
  { promoCode: e }
477
477
  );
@@ -485,7 +485,7 @@ async function It(t, e) {
485
485
  }
486
486
  async function Et(t) {
487
487
  try {
488
- const e = await f(`/orders/${t}/remove-promo`);
488
+ const e = await m(`/orders/${t}/remove-promo`);
489
489
  return e.success ? { success: !0 } : {
490
490
  success: !1,
491
491
  error: e.error || "Failed to remove promo code"
@@ -507,7 +507,7 @@ function ne(t) {
507
507
  function b(t) {
508
508
  return { ok: !1, error: t };
509
509
  }
510
- function Q(t) {
510
+ function J(t) {
511
511
  return { ok: !1, error: t, notFound: !0 };
512
512
  }
513
513
  function Rt(t) {
@@ -516,10 +516,10 @@ function Rt(t) {
516
516
  function At(t) {
517
517
  return !t.ok;
518
518
  }
519
- function D(t, e) {
519
+ function N(t, e) {
520
520
  return t.ok ? t.data : e;
521
521
  }
522
- const m = $("VC"), O = /* @__PURE__ */ new Map();
522
+ const f = $("VC"), O = /* @__PURE__ */ new Map();
523
523
  async function Ve(t, e = fetch, r) {
524
524
  const n = r ? `${t}:pw` : String(t);
525
525
  if (e === fetch) {
@@ -530,27 +530,27 @@ async function Ve(t, e = fetch, r) {
530
530
  try {
531
531
  const s = r ? `${c()}/events/${t}?password=${encodeURIComponent(r)}` : `${c()}/events/${t}`, o = await e(s);
532
532
  if (!o.ok)
533
- return o.status === 404 ? Q("event_not_found") : (m.error(`Failed to fetch event details: ${o.status}`), b("event_fetch_failed"));
533
+ return o.status === 404 ? J("event_not_found") : (f.error(`Failed to fetch event details: ${o.status}`), b("event_fetch_failed"));
534
534
  const i = await o.json();
535
- return i ? ne(i) : Q("event_not_found");
535
+ return i ? ne(i) : J("event_not_found");
536
536
  } catch (s) {
537
- return m.error("Error fetching event details:", s), b("event_fetch_failed");
537
+ return f.error("Error fetching event details:", s), b("event_fetch_failed");
538
538
  }
539
539
  })();
540
540
  return e === fetch && (O.set(n, a), a.finally(() => {
541
541
  O.get(n) === a && O.delete(n);
542
542
  })), a;
543
543
  }
544
- async function Dt(t, e = fetch, r) {
544
+ async function Nt(t, e = fetch, r) {
545
545
  const n = await Ve(t, e, r);
546
546
  return n.ok ? n.data : null;
547
547
  }
548
548
  async function w(t, e, r = (n) => n) {
549
549
  try {
550
- const n = await A(t);
551
- return n ? ne(r(n)) : (m.error(`Failed to load (${e}): network or server error`), b(e));
550
+ const n = await T(t);
551
+ return n ? ne(r(n)) : (f.error(`Failed to load (${e}): network or server error`), b(e));
552
552
  } catch (n) {
553
- return m.error(`Error loading (${e}):`, n), b(e);
553
+ return f.error(`Error loading (${e}):`, n), b(e);
554
554
  }
555
555
  }
556
556
  function G(t) {
@@ -563,18 +563,18 @@ async function Le(t) {
563
563
  G
564
564
  );
565
565
  }
566
- async function Nt(t) {
567
- return D(await Le(t), []);
566
+ async function Dt(t) {
567
+ return N(await Le(t), []);
568
568
  }
569
569
  async function qe(t) {
570
570
  return t ? w(
571
571
  `${c()}/events/${t}/performers`,
572
572
  "performers_fetch_failed",
573
573
  (e) => Fe(e)
574
- ) : (m.warn("fetchEventPerformers called without eventId"), b("performers_missing_event_id"));
574
+ ) : (f.warn("fetchEventPerformers called without eventId"), b("performers_missing_event_id"));
575
575
  }
576
576
  async function Ut(t) {
577
- return D(await qe(t), {
577
+ return N(await qe(t), {
578
578
  performers: [],
579
579
  showPerformers: !1
580
580
  });
@@ -584,20 +584,20 @@ async function Me(t) {
584
584
  `${c()}/venues/organization/${t}`,
585
585
  "venues_fetch_failed",
586
586
  G
587
- ) : (m.warn("fetchAllVenues called without orgId"), b("venues_missing_org_id"));
587
+ ) : (f.warn("fetchAllVenues called without orgId"), b("venues_missing_org_id"));
588
588
  }
589
589
  async function xt(t) {
590
- return D(await Me(t), []);
590
+ return N(await Me(t), []);
591
591
  }
592
592
  async function Ge(t) {
593
593
  return t ? w(
594
594
  `${c()}/events/venue/${t}`,
595
595
  "venue_events_fetch_failed",
596
596
  G
597
- ) : (m.warn("fetchVenueEvents called without venueId"), b("venue_events_missing_venue_id"));
597
+ ) : (f.warn("fetchVenueEvents called without venueId"), b("venue_events_missing_venue_id"));
598
598
  }
599
599
  async function Ot(t) {
600
- return D(await Ge(t), []);
600
+ return N(await Ge(t), []);
601
601
  }
602
602
  function ae(t) {
603
603
  return Array.isArray(t) ? t : Array.isArray(t.events) ? t.events : [];
@@ -610,7 +610,7 @@ async function je(t, e, r) {
610
610
  );
611
611
  }
612
612
  async function Ft(t, e, r) {
613
- return D(await je(t, e, r), []);
613
+ return N(await je(t, e, r), []);
614
614
  }
615
615
  async function ze(t, e, r) {
616
616
  return w(
@@ -620,7 +620,7 @@ async function ze(t, e, r) {
620
620
  );
621
621
  }
622
622
  async function Vt(t, e, r) {
623
- return D(await ze(t, e, r), []);
623
+ return N(await ze(t, e, r), []);
624
624
  }
625
625
  async function Be(t) {
626
626
  return w(
@@ -644,68 +644,74 @@ async function qt(t, e) {
644
644
  }
645
645
  async function Mt(t, e) {
646
646
  try {
647
- const r = e ? `?slug=${encodeURIComponent(e)}` : "", n = await A(
647
+ const r = e ? `?slug=${encodeURIComponent(e)}` : "", n = await T(
648
648
  `${c()}/resolve/${encodeURIComponent(String(t))}${r}`
649
649
  );
650
650
  if (!n || !n.type)
651
- throw new N(
651
+ throw new D(
652
652
  "Failed to resolve entity",
653
653
  "lib/api/events/resolvePublicEntity"
654
654
  );
655
655
  return n;
656
656
  } catch (r) {
657
- return m.error("Error resolving public entity:", r), null;
657
+ return f.error("Error resolving public entity:", r), null;
658
658
  }
659
659
  }
660
660
  async function Gt(t) {
661
661
  try {
662
- const e = await A(
662
+ const e = await T(
663
663
  `${c()}/series/${t}/page`
664
664
  );
665
665
  if (!e)
666
- throw new N(
666
+ throw new D(
667
667
  "Failed to fetch series page",
668
668
  "lib/api/events/fetchSeriesPage"
669
669
  );
670
670
  return e;
671
671
  } catch (e) {
672
- return m.error("Error fetching series page:", e), null;
672
+ return f.error("Error fetching series page:", e), null;
673
673
  }
674
674
  }
675
675
  async function jt(t, e) {
676
676
  try {
677
- const r = e ? `${c()}/collections/${t}?password=${encodeURIComponent(e)}` : `${c()}/collections/${t}`, n = await A(r);
677
+ const r = e ? `${c()}/collections/${t}?password=${encodeURIComponent(e)}` : `${c()}/collections/${t}`, n = await T(r);
678
678
  if (!n)
679
- throw new N(
679
+ throw new D(
680
680
  "Failed to fetch collection",
681
681
  "lib/api/events/fetchPublicCollection"
682
682
  );
683
683
  return n;
684
684
  } catch (r) {
685
- return m.error("Error fetching collection:", r), null;
685
+ return f.error("Error fetching collection:", r), null;
686
686
  }
687
687
  }
688
688
  async function zt(t, e) {
689
689
  try {
690
- const r = encodeURIComponent(e);
691
- return (await A(
692
- `${c()}/collections/${t}/check-password/${r}`
690
+ return (await T(
691
+ `${c()}/collections/${t}/check-password`,
692
+ {
693
+ method: "POST",
694
+ headers: { "Content-Type": "application/json" },
695
+ body: JSON.stringify({ password: e })
696
+ }
693
697
  ))?.valid === !0;
694
698
  } catch (r) {
695
- return m.error("Error checking collection password:", r), !1;
699
+ return f.error("Error checking collection password:", r), !1;
696
700
  }
697
701
  }
698
702
  async function Bt(t, e) {
699
703
  try {
700
- const r = await f(
704
+ const r = await T(
701
705
  `${c()}/events/${t}/check-password`,
702
- { password: e }
706
+ {
707
+ method: "POST",
708
+ headers: { "Content-Type": "application/json" },
709
+ body: JSON.stringify({ password: e })
710
+ }
703
711
  );
704
- if (!r.success) return { valid: !1 };
705
- const n = r.data;
706
- return typeof n == "boolean" ? { valid: n } : { valid: n.valid === !0 };
712
+ return typeof r == "boolean" ? { valid: r } : { valid: r?.valid === !0 };
707
713
  } catch (r) {
708
- return m.error("Error checking event password:", r), { valid: !1 };
714
+ return f.error("Error checking event password:", r), { valid: !1 };
709
715
  }
710
716
  }
711
717
  async function Ht(t, e) {
@@ -715,18 +721,18 @@ async function Ht(t, e) {
715
721
  method: "HEAD"
716
722
  })).ok;
717
723
  } catch (r) {
718
- return m.error("Network connection test failed:", r), !1;
724
+ return f.error("Network connection test failed:", r), !1;
719
725
  }
720
726
  }
721
- const E = $("VC");
727
+ const R = $("VC");
722
728
  async function We(t) {
723
729
  try {
724
730
  if (!t)
725
- return E.warn("getVenue called without venueId"), null;
731
+ return R.warn("getVenue called without venueId"), null;
726
732
  const e = await C(`/venues/${t}`);
727
- return e.success ? e.data ?? null : (E.error(`Failed to fetch venue: ${e.statusCode}`), null);
733
+ return e.success ? e.data ?? null : (R.error(`Failed to fetch venue: ${e.statusCode}`), null);
728
734
  } catch (e) {
729
- return E.error("Error fetching venue:", e), null;
735
+ return R.error("Error fetching venue:", e), null;
730
736
  }
731
737
  }
732
738
  async function Wt(t) {
@@ -737,17 +743,17 @@ async function Wt(t) {
737
743
  taxPercentage: e.taxPercentage ?? 0
738
744
  } : null;
739
745
  }
740
- async function Qt(t) {
746
+ async function Jt(t) {
741
747
  try {
742
748
  if (!t)
743
- return E.warn("getVenueBySlug called without slug"), null;
749
+ return R.warn("getVenueBySlug called without slug"), null;
744
750
  const e = encodeURIComponent(t), r = await C(`/venues/slug/${e}`);
745
- return r.success ? r.data ?? null : (E.error(`Failed to fetch venue by slug: ${r.statusCode}`), null);
751
+ return r.success ? r.data ?? null : (R.error(`Failed to fetch venue by slug: ${r.statusCode}`), null);
746
752
  } catch (e) {
747
- return E.error("Error fetching venue by slug:", e), null;
753
+ return R.error("Error fetching venue by slug:", e), null;
748
754
  }
749
755
  }
750
- function Qe(t) {
756
+ function Je(t) {
751
757
  const e = t ?? {}, r = (e.appliedAmount ?? 0) / 100, n = e.remainingTotal ?? 0, a = e.fullyCoveredByCard ?? n <= 0, s = !a;
752
758
  return {
753
759
  valid: !0,
@@ -760,15 +766,15 @@ function Qe(t) {
760
766
  requiresStripe: s
761
767
  };
762
768
  }
763
- const h = $("VC"), Je = "https://get-micdrop.com", Ye = `${Je}/api/orders/v2`, j = () => R();
764
- async function Jt(t) {
769
+ const h = $("VC"), Qe = "https://get-micdrop.com", Ye = `${Qe}/api/orders/v2`, j = () => A();
770
+ async function Qt(t) {
765
771
  try {
766
- const e = await f(
772
+ const e = await m(
767
773
  `${Ye}/gift-cards`,
768
774
  t
769
775
  );
770
776
  if (!e.success)
771
- throw h.error("Gift card purchase creation failed:", e.error), new N(
777
+ throw h.error("Gift card purchase creation failed:", e.error), new D(
772
778
  e.error || "Failed to create gift card purchase",
773
779
  "lib/api/gift-cards/createGiftCardPurchase"
774
780
  );
@@ -779,11 +785,11 @@ async function Jt(t) {
779
785
  }
780
786
  async function Yt(t, e) {
781
787
  try {
782
- const r = await f(
788
+ const r = await m(
783
789
  `${j()}/cart/${t}/apply-gift-card`,
784
790
  { giftCardCode: e }
785
791
  );
786
- return r.success ? Qe(r.data) : r.statusCode === 429 ? {
792
+ return r.success ? Je(r.data) : r.statusCode === 429 ? {
787
793
  valid: !1,
788
794
  error: "Too many attempts. Please wait a moment and try again."
789
795
  } : (h.error("Apply gift card failed:", r.error), {
@@ -816,7 +822,7 @@ async function Kt(t, e) {
816
822
  }
817
823
  async function Zt(t, e) {
818
824
  try {
819
- const r = await f(`${j()}/cart/${t}/complete-gift-card-payment`, {
825
+ const r = await m(`${j()}/cart/${t}/complete-gift-card-payment`, {
820
826
  firstName: e.firstName,
821
827
  lastName: e.lastName,
822
828
  email: e.email,
@@ -852,7 +858,7 @@ async function Xt(t, e, r = null, n = !1) {
852
858
  try {
853
859
  const a = { email: e };
854
860
  r && n && (a.phone = r, a.smsOptIn = !0);
855
- const s = await f(
861
+ const s = await m(
856
862
  `/events/${t}/waitlist`,
857
863
  a
858
864
  );
@@ -900,10 +906,10 @@ function tr(t, e, r = {}) {
900
906
  const i = t.endDateTime || t.startDateTime;
901
907
  if (i && new Date(i) < o)
902
908
  return { text: "Sales ended", disabled: !0, reason: "event_past" };
903
- const u = t?.hasPurchasableHiddenTickets === !0 || Array.isArray(e) && e.some(ye), T = (e || []).filter(
909
+ const u = t?.hasPurchasableHiddenTickets === !0 || Array.isArray(e) && e.some(ye), P = (e || []).filter(
904
910
  (l) => l.salesChannel !== 2 && !l.isHidden && !(typeof l.visibility == "number" && l.visibility >= 2)
905
911
  );
906
- if (T.length === 0)
912
+ if (P.length === 0)
907
913
  return u ? {
908
914
  text: a ? "Reserve a spot" : "Get tickets",
909
915
  disabled: !1,
@@ -914,10 +920,10 @@ function tr(t, e, r = {}) {
914
920
  reason: "no_tickets"
915
921
  };
916
922
  let y = !1, k = !0, g = !0, v = null;
917
- for (const l of T) {
918
- const P = l.salesBegin || l.salesStart || l.saleBegin || l.onSaleStart, x = l.salesEnd || l.saleEnd || l.onSaleEnd, S = l.remainingCapacity ?? l.quantityRemaining ?? l.quantity, _ = l.soldOut || S != null && S <= 0, I = P ? new Date(P) > o : !1, z = x ? new Date(x) < o : !1;
919
- if (!_ && !I && !z && (y = !0), _ || (k = !1), I || (g = !1), I && P && !_ && !z) {
920
- const B = new Date(P);
923
+ for (const l of P) {
924
+ const S = l.salesBegin || l.salesStart || l.saleBegin || l.onSaleStart, x = l.salesEnd || l.saleEnd || l.onSaleEnd, I = l.remainingCapacity ?? l.quantityRemaining ?? l.quantity, _ = l.soldOut || I != null && I <= 0, E = S ? new Date(S) > o : !1, z = x ? new Date(x) < o : !1;
925
+ if (!_ && !E && !z && (y = !0), _ || (k = !1), E || (g = !1), E && S && !_ && !z) {
926
+ const B = new Date(S);
921
927
  (!v || B < v) && (v = B);
922
928
  }
923
929
  }
@@ -934,13 +940,13 @@ function tr(t, e, r = {}) {
934
940
  disabled: !1,
935
941
  reason: "hidden_only"
936
942
  };
937
- const l = v.getTime() - o.getTime(), P = l / (1e3 * 60 * 60), x = l / (1e3 * 60 * 60 * 24), S = (I) => L(
938
- I,
943
+ const l = v.getTime() - o.getTime(), S = l / (1e3 * 60 * 60), x = l / (1e3 * 60 * 60 * 24), I = (E) => L(
944
+ E,
939
945
  { hour: "numeric", minute: "2-digit", hour12: !0 },
940
946
  "en-US"
941
947
  );
942
948
  let _;
943
- return P < 24 ? _ = S(v) : x <= 7 ? _ = L(
949
+ return S < 24 ? _ = I(v) : x <= 7 ? _ = L(
944
950
  v,
945
951
  { weekday: "short", hour: "numeric", minute: "2-digit", hour12: !0 },
946
952
  "en-US"
@@ -948,7 +954,7 @@ function tr(t, e, r = {}) {
948
954
  v,
949
955
  { month: "short", day: "numeric" },
950
956
  "en-US"
951
- )} ${S(v)}`, {
957
+ )} ${I(v)}`, {
952
958
  text: `On sale ${_}`,
953
959
  disabled: !0,
954
960
  reason: "coming_soon"
@@ -1024,7 +1030,7 @@ function ar(t) {
1024
1030
  function Ze(t) {
1025
1031
  return K(t, { cdn: !0 });
1026
1032
  }
1027
- function J(t) {
1033
+ function Q(t) {
1028
1034
  const e = t.imageUrl || t.imageURL || t.image_url || t.image || "";
1029
1035
  return Ze(e);
1030
1036
  }
@@ -1059,8 +1065,8 @@ function et(t) {
1059
1065
  return n <= 0 ? "sold_out" : "available";
1060
1066
  const a = t.availableTickets || t.available_tickets || t.tickets || [];
1061
1067
  return a.length === 0 ? "coming_soon" : a.reduce((o, i) => {
1062
- const u = i.quantityAvailable ?? i.quantity_available ?? i.quantity ?? 0, T = i.quantitySold ?? i.quantity_sold ?? 0;
1063
- return o + Math.max(0, u - T);
1068
+ const u = i.quantityAvailable ?? i.quantity_available ?? i.quantity ?? 0, P = i.quantitySold ?? i.quantity_sold ?? 0;
1069
+ return o + Math.max(0, u - P);
1064
1070
  }, 0) <= 0 ? "sold_out" : "available";
1065
1071
  }
1066
1072
  function ie(t) {
@@ -1102,8 +1108,8 @@ function ce(t) {
1102
1108
  venueName: e.venueName || e.venue_name,
1103
1109
  venueAddress: e.venueAddress || e.venue_address,
1104
1110
  location: e.location || e.venueAddress || e.venue_address,
1105
- imageUrl: J(e),
1106
- imageURL: J(e),
1111
+ imageUrl: Q(e),
1112
+ imageURL: Q(e),
1107
1113
  status: e.status,
1108
1114
  isPublished: e.isPublished ?? e.is_published,
1109
1115
  isCancelled: e.isCancelled ?? e.is_cancelled,
@@ -1188,7 +1194,7 @@ function lr(t) {
1188
1194
  export {
1189
1195
  he as apiDelete,
1190
1196
  C as apiGet,
1191
- f as apiPost,
1197
+ m as apiPost,
1192
1198
  mt as apiPut,
1193
1199
  Yt as applyGiftCard,
1194
1200
  It as applyPromoCode,
@@ -1200,20 +1206,20 @@ export {
1200
1206
  vt as completeReservation,
1201
1207
  tr as computeCtaState,
1202
1208
  ut as configureApi,
1203
- Jt as createGiftCardPurchase,
1209
+ Qt as createGiftCardPurchase,
1204
1210
  _t as createOrder,
1205
1211
  pt as createPaymentIntent,
1206
1212
  b as err,
1207
- Q as errNotFound,
1213
+ J as errNotFound,
1208
1214
  bt as extendCheckoutSession,
1209
1215
  ur as extractVenueFees,
1210
1216
  xt as fetchAllVenues,
1211
1217
  Me as fetchAllVenuesResult,
1212
- Dt as fetchEventDetails,
1218
+ Nt as fetchEventDetails,
1213
1219
  Ve as fetchEventDetailsResult,
1214
1220
  Ut as fetchEventPerformers,
1215
1221
  qe as fetchEventPerformersResult,
1216
- Nt as fetchEventTickets,
1222
+ Dt as fetchEventTickets,
1217
1223
  Le as fetchEventTicketsResult,
1218
1224
  jt as fetchPublicCollection,
1219
1225
  qt as fetchSeriesOccurrences,
@@ -1226,12 +1232,12 @@ export {
1226
1232
  Ze as getCDNImageUrl,
1227
1233
  yt as getCartByUUID,
1228
1234
  ft as getClientIP,
1229
- J as getEventImageUrl,
1235
+ Q as getEventImageUrl,
1230
1236
  dt as getLegacyPublicUrl,
1231
1237
  Ft as getMonthEvents,
1232
1238
  je as getMonthEventsResult,
1233
1239
  wt as getOrder,
1234
- R as getOrdersV2Url,
1240
+ A as getOrdersV2Url,
1235
1241
  Vt as getOrgMonthEvents,
1236
1242
  ze as getOrgMonthEventsResult,
1237
1243
  c as getPublicBaseUrl,
@@ -1239,7 +1245,7 @@ export {
1239
1245
  Be as getSeriesOccurrencesResult,
1240
1246
  $t as getSessionStatus,
1241
1247
  We as getVenue,
1242
- Qt as getVenueBySlug,
1248
+ Jt as getVenueBySlug,
1243
1249
  Wt as getVenueFees,
1244
1250
  er as getWaitlistStatus,
1245
1251
  St as hasPromoCodes,
@@ -1260,7 +1266,7 @@ export {
1260
1266
  ar as transformOrderForDisplay,
1261
1267
  rr as transformTicket,
1262
1268
  cr as transformVenue,
1263
- D as unwrapOr,
1269
+ N as unwrapOr,
1264
1270
  gt as updateCartQuantities,
1265
1271
  kt as validatePaymentIntent,
1266
1272
  Pt as validatePromoCode