@getmicdrop/venue-calendar 4.3.34 → 4.3.35

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (128) hide show
  1. package/dist/{ArrowLeftIcon-C5NUNFeL.js → ArrowLeftIcon-bH5d6LQO.js} +1 -1
  2. package/dist/{BlockPlaceholder-BFgIxUDA.js → BlockPlaceholder-yXhu9HrQ.js} +1 -1
  3. package/dist/{Calendar-Cbg9VnYr.js → Calendar-BjE02HrG.js} +5 -5
  4. package/dist/{CalendarFoundryView-DcjrxbP1.js → CalendarFoundryView-BytAeaqk.js} +70 -65
  5. package/dist/{CalendarIcon-jP9rYFKk.js → CalendarIcon-Cg9UUTeu.js} +1 -1
  6. package/dist/{CartView-BVaW78NV.js → CartView-BVAj8ns8.js} +138 -138
  7. package/dist/{Checkout-DNs1cjbB.js → Checkout-Cw_mvXUd.js} +16 -16
  8. package/dist/{Checkout-BnfAQRI6.js → Checkout-DFoOLl6K.js} +27 -28
  9. package/dist/{CheckoutTimer-Cwt4Ftza.js → CheckoutTimer-BDxy_Fou.js} +3 -3
  10. package/dist/{ChevronDownIcon-CsKZMqNH.js → ChevronDownIcon-BA40Kl0C.js} +1 -1
  11. package/dist/{ClockIcon-HiO23hRG.js → ClockIcon-DjC-doTv.js} +1 -1
  12. package/dist/{CloseIcon-B8Sm_5ym.js → CloseIcon-BdwmaxDK.js} +1 -1
  13. package/dist/{CollectionView-BK1iSWcA.js → CollectionView-BRJKmgmu.js} +13 -13
  14. package/dist/{CropImage-B9d215n1.js → CropImage-Ct6MRg_a.js} +3 -3
  15. package/dist/{Event-AfkOD3uO.js → Event-CJZetg3I.js} +24 -25
  16. package/dist/{EventPage-Cdt0a5QJ.js → EventPage-Bt5872Cp.js} +111 -111
  17. package/dist/{Input-BLMJJJfH.js → Input-o-1w57H2.js} +2 -2
  18. package/dist/{MailIcon-KYN2vf3S.js → MailIcon-DCMMhuHr.js} +1 -1
  19. package/dist/{Modal-gEHiBqWZ.js → Modal-DZ8fudB4.js} +2 -2
  20. package/dist/{ModalFooter-D21lJobf.js → ModalFooter-T1gpnywp.js} +1 -1
  21. package/dist/{ModalHeader-fa2P2o57.js → ModalHeader-DkKpWKcG.js} +1 -1
  22. package/dist/{PasswordInput-D4q7ha7D.js → PasswordInput-zX7J--jb.js} +2 -2
  23. package/dist/{RecommendationsRail-BZf1DOmo.js → RecommendationsRail-DcIHxWHf.js} +7 -7
  24. package/dist/{ScarcityBadge-AHlWKMNd.js → ScarcityBadge-CwYWJOsJ.js} +4 -4
  25. package/dist/{SeriesPage-Dl6PBlrN.js → SeriesPage-ByxpytgT.js} +4 -4
  26. package/dist/Success-CFbOlDG7.js +887 -0
  27. package/dist/{TagIcon-DoPOkfiA.js → TagIcon-CkfQvNGi.js} +1 -1
  28. package/dist/Textarea-D24kYZAW.js +63 -0
  29. package/dist/{ViewTicketsEmbed-kOPSXNDx.js → ViewTicketsEmbed-KbA05I2k.js} +236 -298
  30. package/dist/{WarningCircleIcon-CFfLr8KS.js → WarningCircleIcon-Iq24pJJf.js} +1 -1
  31. package/dist/{WarningTriIcon-DNmtiOjd.js → WarningTriIcon-Dw5GnHpq.js} +1 -1
  32. package/dist/__SKIP_PATHS__-C0ixDSSm.js +6 -0
  33. package/dist/api/api.cjs +1 -1
  34. package/dist/api/api.mjs +264 -242
  35. package/dist/api/index.d.ts +1 -1
  36. package/dist/api/venues.d.ts +7 -0
  37. package/dist/{api-CEmt-15i.js → api-DRQ3j7AT.js} +171 -119
  38. package/dist/{browser-B_8qS4Bh.js → browser-DxdP6IWt.js} +169 -231
  39. package/dist/{constants-DZLNBlGm.js → constants-YYsgll7v.js} +8 -7
  40. package/dist/{copyToClipboard-ajE-WfxH.js → copyToClipboard-C3IBl2Z1.js} +1 -1
  41. package/dist/{de-C4OeiQ3V.js → de-BY5vJUGN.js} +1 -1
  42. package/dist/{de-CrMbvuuV.js → de-CFh1o4IO.js} +1 -0
  43. package/dist/{defaultLabels-OQGIv2n1.js → defaultLabels-Zp9QbN37.js} +1 -1
  44. package/dist/defaults-BMbXcKP9.js +67 -0
  45. package/dist/{es-CmbcTI7U.js → es-By1tBWcL.js} +1 -0
  46. package/dist/{es-CW2TmxIh.js → es-jUq9nrJk.js} +1 -1
  47. package/dist/{navigation-BHE6fobo.js → event-c9mHeEJz.js} +24 -57
  48. package/dist/{event-transform-Biw1swA_.js → event-transform-BchpSia3.js} +25 -25
  49. package/dist/{eventStatusStream-lf8vfXK6.js → eventStatusStream-dDHNTEOf.js} +1 -1
  50. package/dist/{fr-CAQjiRpV.js → fr-BF6a7cw7.js} +1 -0
  51. package/dist/{fr-C7djAcvW.js → fr-BhVwmvlV.js} +1 -1
  52. package/dist/{href-CPeCYE4T.js → href-1o0O9xTA.js} +2 -2
  53. package/dist/{i18n-Bmvq2TcR.js → i18n-1R1ah9KT.js} +18 -18
  54. package/dist/i18n-i-1mHdch.js +28 -0
  55. package/dist/{id-CN96JRiT.js → id-CWU5ZvLv.js} +1 -1
  56. package/dist/{id-Bz5RjCc1.js → id-Lo_q281j.js} +1 -0
  57. package/dist/{imageOptimizer-CXtAyNGI.js → imageOptimizer-DkJp4tei.js} +2 -2
  58. package/dist/{it-wMX0iXW-.js → it-CB7RtPbU.js} +1 -0
  59. package/dist/{it-DFWEl9q6.js → it-wlDmN3hH.js} +1 -1
  60. package/dist/{ja-BHzUvYMy.js → ja-DOzvvYpK.js} +1 -0
  61. package/dist/{ja-CMVyfs3-.js → ja-DpA7hJaC.js} +1 -1
  62. package/dist/{ko-zuSw9I4o.js → ko-DdWLaFvo.js} +1 -1
  63. package/dist/{ko-hy8WDqbp.js → ko-b-vWxFpt.js} +1 -0
  64. package/dist/{__SKIP_PATHS__-BQgiZG5h.js → liveAnnouncer-D3xVL7qA.js} +1 -6
  65. package/dist/locales/{4.3.34 → 4.3.35}/flow/de.js +1 -1
  66. package/dist/locales/{4.3.34 → 4.3.35}/flow/es.js +1 -1
  67. package/dist/locales/{4.3.34 → 4.3.35}/flow/fr.js +1 -1
  68. package/dist/locales/{4.3.34 → 4.3.35}/flow/id.js +1 -1
  69. package/dist/locales/{4.3.34 → 4.3.35}/flow/it.js +1 -1
  70. package/dist/locales/{4.3.34 → 4.3.35}/flow/ja.js +1 -1
  71. package/dist/locales/{4.3.34 → 4.3.35}/flow/ko.js +1 -1
  72. package/dist/locales/{4.3.34 → 4.3.35}/flow/nl.js +1 -1
  73. package/dist/locales/{4.3.34 → 4.3.35}/flow/pl.js +1 -1
  74. package/dist/locales/{4.3.34 → 4.3.35}/flow/pt-br.js +1 -1
  75. package/dist/locales/{4.3.34 → 4.3.35}/flow/tr.js +1 -1
  76. package/dist/locales/{4.3.34 → 4.3.35}/flow/zh.js +1 -1
  77. package/dist/locales/4.3.35/main/de.js +1 -0
  78. package/dist/locales/4.3.35/main/es.js +1 -0
  79. package/dist/locales/4.3.35/main/fr.js +1 -0
  80. package/dist/locales/4.3.35/main/id.js +1 -0
  81. package/dist/locales/4.3.35/main/it.js +1 -0
  82. package/dist/locales/4.3.35/main/ja.js +1 -0
  83. package/dist/locales/4.3.35/main/ko.js +1 -0
  84. package/dist/locales/4.3.35/main/nl.js +1 -0
  85. package/dist/locales/4.3.35/main/pl.js +1 -0
  86. package/dist/locales/4.3.35/main/pt-br.js +1 -0
  87. package/dist/locales/4.3.35/main/tr.js +1 -0
  88. package/dist/locales/4.3.35/main/zh.js +1 -0
  89. package/dist/{nl-CkQAHeS-.js → nl-BwxAfMRa.js} +1 -1
  90. package/dist/{nl-a59DlSFb.js → nl-Dazc9kaV.js} +1 -0
  91. package/dist/{order-totals-yAfj2LIo.js → order-totals-BEUOdkCb.js} +3 -3
  92. package/dist/{orders-Cp6dGII_.js → orders-jQz7QFjK.js} +1 -1
  93. package/dist/{phoneUtils-CFZyDPA3.js → phoneUtils-CbiDWdEC.js} +1 -1
  94. package/dist/{pixels-Tg_bLOjd.js → pixels-DnbRn43e.js} +2 -2
  95. package/dist/{pl-DuIttORH.js → pl-CuRdwJXc.js} +1 -1
  96. package/dist/{pl-Dmn5DPMF.js → pl-tSyy-lx_.js} +1 -0
  97. package/dist/{promo-RdgJBu-u.js → promo-BrstveEs.js} +1 -1
  98. package/dist/{pt-br-DkLlN_4i.js → pt-br-BUWJLxKf.js} +1 -1
  99. package/dist/{pt-br-DA_CwwjY.js → pt-br-BxzrK97M.js} +1 -0
  100. package/dist/{scarcity-CgNGIioR.js → scarcity-CwnIxi1J.js} +1 -1
  101. package/dist/{serverTotals-PF6gaenQ.js → serverTotals-D2-FzkdS.js} +1 -1
  102. package/dist/{showcase-state-options-C4_hcf2M.js → showcase-state-options-CDOHpho6.js} +1 -1
  103. package/dist/{to-event-card-props-CWfWAJWW.js → to-event-card-props-ChcFQ_rl.js} +2 -2
  104. package/dist/{tr-BE24jHAY.js → tr-DTe5Urub.js} +1 -1
  105. package/dist/{tr-DM96GLXF.js → tr-DhAMB3UQ.js} +1 -0
  106. package/dist/{utils-DlVakPI5.js → utils-DvGzK5Cl.js} +2 -2
  107. package/dist/venue-calendar.css +1 -1
  108. package/dist/venue-calendar.es.js +894 -892
  109. package/dist/venue-calendar.iife.js +52 -52
  110. package/dist/venue-calendar.umd.js +53 -53
  111. package/dist/{z-index-BgKs9X9U.js → z-index-Bo0dqmiq.js} +1 -1
  112. package/dist/{zh-cUmo9Rzd.js → zh-BnBN3ggx.js} +1 -1
  113. package/dist/{zh-CdWAelYB.js → zh-C2-VLP_R.js} +1 -0
  114. package/package.json +2 -2
  115. package/dist/Success-DDE54FBH.js +0 -863
  116. package/dist/i18n-Lx3QVVPj.js +0 -28
  117. package/dist/locales/4.3.34/main/de.js +0 -1
  118. package/dist/locales/4.3.34/main/es.js +0 -1
  119. package/dist/locales/4.3.34/main/fr.js +0 -1
  120. package/dist/locales/4.3.34/main/id.js +0 -1
  121. package/dist/locales/4.3.34/main/it.js +0 -1
  122. package/dist/locales/4.3.34/main/ja.js +0 -1
  123. package/dist/locales/4.3.34/main/ko.js +0 -1
  124. package/dist/locales/4.3.34/main/nl.js +0 -1
  125. package/dist/locales/4.3.34/main/pl.js +0 -1
  126. package/dist/locales/4.3.34/main/pt-br.js +0 -1
  127. package/dist/locales/4.3.34/main/tr.js +0 -1
  128. package/dist/locales/4.3.34/main/zh.js +0 -1
@@ -1,863 +0,0 @@
1
- import { E as e } from "./Button-klwKgfhG.js";
2
- import { l as t, q as n, r } from "./scarcity-CgNGIioR.js";
3
- import { t as i } from "./ArrowLeftIcon-C5NUNFeL.js";
4
- import { t as a } from "./CalendarIcon-jP9rYFKk.js";
5
- import { t as o } from "./ChevronDownIcon-CsKZMqNH.js";
6
- import { n as s, t as c } from "./MailIcon-KYN2vf3S.js";
7
- import { n as l, o as u, r as d, t as f } from "./RecommendationsRail-BZf1DOmo.js";
8
- import { n as p } from "./copyToClipboard-ajE-WfxH.js";
9
- import { U as m, V as h, i as g } from "./defaultLabels-OQGIv2n1.js";
10
- import { $ as _, V as v, Y as y, Z as b, g as x, s as S } from "./orders-Cp6dGII_.js";
11
- import { n as C, t as w } from "./__SKIP_PATHS__-BQgiZG5h.js";
12
- import { n as T, t as E } from "./Heading-D6bWtGZA.js";
13
- import { t as D } from "./Text-CqjLjIF8.js";
14
- import { a as O, o as k } from "./navigation-BHE6fobo.js";
15
- import "./api-CEmt-15i.js";
16
- import { c as A, r as j } from "./pixels-Tg_bLOjd.js";
17
- import { i as M, n as N, t as P } from "./i18n-Bmvq2TcR.js";
18
- import { n as ee, t as F } from "./i18n-Lx3QVVPj.js";
19
- import { C as I, d as L, l as R, n as z } from "./utils-DlVakPI5.js";
20
- import { n as B, t as te } from "./constants-DZLNBlGm.js";
21
- import { a as V, i as H, n as ne, o as re, r as U, s as W } from "./showcase-state-options-C4_hcf2M.js";
22
- import { n as ie, t as ae } from "./buyerEmail-BfCq-gDt.js";
23
- import "svelte/internal/disclose-version";
24
- import * as G from "svelte/internal/client";
25
- import { SvelteMap as K } from "svelte/reactivity";
26
- import { onDestroy as q, onMount as J } from "svelte";
27
- //#region node_modules/@getmicdrop/svelte-components/dist/primitives/Icons/phosphor/HelpIcon.svelte
28
- var oe = G.from_svg("<path d=\"M128,24A104,104,0,1,0,232,128,104.11,104.11,0,0,0,128,24Zm0,168a12,12,0,1,1,12-12A12,12,0,0,1,128,192Zm8-48.72V144a8,8,0,0,1-16,0v-8a8,8,0,0,1,8-8c13.23,0,24-9,24-20s-10.77-20-24-20-24,9-24,20v4a8,8,0,0,1-16,0v-4c0-19.85,17.94-36,40-36s40,16.15,40,36C168,125.38,154.24,139.93,136,143.28Z\"></path>"), se = G.from_svg("<circle cx=\"128\" cy=\"180\" r=\"12\"></circle><path d=\"M128,144v-8c17.67,0,32-12.54,32-28s-14.33-28-32-28S96,92.54,96,108v4\" fill=\"none\" stroke=\"currentColor\" stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"16\"></path><circle cx=\"128\" cy=\"128\" r=\"96\" fill=\"none\" stroke=\"currentColor\" stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"16\"></circle>", 1), ce = G.from_svg("<svg aria-hidden=\"true\" viewBox=\"0 0 256 256\" fill=\"currentColor\" xmlns=\"http://www.w3.org/2000/svg\"><!></svg>");
29
- function le(e, t) {
30
- G.push(t, !0);
31
- let r = G.prop(t, "size", 3, "24"), i = G.prop(t, "color", 3, "currentColor"), a = G.prop(t, "class", 3, ""), o = n(), s = G.derived(() => t.weight ?? o?.weight ?? "regular");
32
- var c = ce();
33
- let l;
34
- var u = G.child(c), d = (e) => {
35
- var t = oe();
36
- G.append(e, t);
37
- }, f = (e) => {
38
- var t = se();
39
- G.next(2), G.append(e, t);
40
- };
41
- G.if(u, (e) => {
42
- G.get(s) === "fill" ? e(d) : e(f, -1);
43
- }), G.reset(c), G.template_effect(() => {
44
- G.set_class(c, 0, G.clsx(a())), G.set_attribute(c, "width", r()), G.set_attribute(c, "height", r()), l = G.set_style(c, "", l, { color: i() === "currentColor" ? void 0 : i() });
45
- }), G.append(e, c), G.pop();
46
- }
47
- //#endregion
48
- //#region src/lib/public-calendar-flow/pendingValidation.ts
49
- var Y = (e) => `micdrop_pending_validate_${e}`;
50
- function X(e) {
51
- return e ? y(Y(e), null) : null;
52
- }
53
- function Z(e) {
54
- e && b(Y(e));
55
- }
56
- //#endregion
57
- //#region src/lib/public-calendar-flow/SuccessTicket.svelte
58
- var ue = G.from_html("<div class=\"p-3 rounded-lg bg-surface-secondary mb-6\"><!> <!></div>"), de = G.from_html("<div class=\"flex items-center justify-center gap-2 p-3 rounded-lg bg-surface-secondary mt-4\"><!> <!></div>"), fe = G.from_html("<div class=\"p-6 md:p-8\"><div class=\"flex justify-center mb-6\"><div class=\"indicator-container svelte-667vry\"><div></div> <svg viewBox=\"0 0 52 52\" aria-hidden=\"true\"><circle cx=\"26\" cy=\"26\" r=\"24\" class=\"checkmark-circle svelte-667vry\"></circle><circle cx=\"26\" cy=\"26\" r=\"24\" class=\"checkmark-fill svelte-667vry\"></circle><path d=\"M14 27l7 7 17-17\" class=\"checkmark-check svelte-667vry\"></path></svg></div></div> <div><div class=\"flex flex-col gap-3 text-center mb-6\"><!> <!> <!></div> <!> <div class=\"mb-6\"><!></div> <div class=\"flex justify-between items-center py-3 border-t border-default\"><!></div> <!></div></div>");
59
- function pe(e, t) {
60
- G.push(t, !0);
61
- let n = G.prop(t, "labels", 3, B), r = G.derived(() => t.orderTotals.lines.reduce((e, t) => e + t.quantity, 0)), i = G.derived(() => t.event.isRegistrationEvent ? n().youreRegistered || "You're registered" : n().youreIn || "You're in");
62
- T(e, {
63
- border: !0,
64
- padding: !1,
65
- class: "rounded-xl shadow-lg overflow-hidden bg-surface-primary",
66
- children: (e, a) => {
67
- var o = fe(), s = G.child(o), l = G.child(s), u = G.child(l);
68
- let d;
69
- var f = G.sibling(u, 2);
70
- let p;
71
- G.reset(l), G.reset(s);
72
- var m = G.sibling(s, 2);
73
- let h;
74
- var g = G.child(m), _ = G.child(g);
75
- E(_, {
76
- level: 1,
77
- size: "xl",
78
- weight: "bold",
79
- children: (e, t) => {
80
- G.next();
81
- var n = G.text();
82
- G.template_effect(() => G.set_text(n, G.get(i))), G.append(e, n);
83
- },
84
- $$slots: { default: !0 }
85
- });
86
- var v = G.sibling(_, 2);
87
- D(v, {
88
- size: "lg",
89
- weight: "semibold",
90
- class: "block",
91
- children: (e, n) => {
92
- G.next();
93
- var r = G.text();
94
- G.template_effect(() => G.set_text(r, t.event.title)), G.append(e, r);
95
- },
96
- $$slots: { default: !0 }
97
- });
98
- var y = G.sibling(v, 2);
99
- D(y, {
100
- size: "sm",
101
- color: "secondary",
102
- class: "block",
103
- children: (e, t) => {
104
- G.next();
105
- var i = G.text();
106
- G.template_effect(() => G.set_text(i, `${G.get(r) ?? ""}
107
- ${(G.get(r) === 1 ? n().ticket || "ticket" : n().tickets || "tickets") ?? ""} confirmed`)), G.append(e, i);
108
- },
109
- $$slots: { default: !0 }
110
- }), G.reset(g);
111
- var b = G.sibling(g, 2), x = (e) => {
112
- var r = ue(), i = G.child(r);
113
- D(i, {
114
- size: "xs",
115
- weight: "semibold",
116
- color: "secondary",
117
- class: "block",
118
- children: (e, t) => {
119
- G.next();
120
- var r = G.text();
121
- G.template_effect(() => G.set_text(r, n().messageFromOrganizer || "A note from the organizer")), G.append(e, r);
122
- },
123
- $$slots: { default: !0 }
124
- });
125
- var a = G.sibling(i, 2);
126
- D(a, {
127
- size: "sm",
128
- class: "block whitespace-pre-line",
129
- children: (e, n) => {
130
- G.next();
131
- var r = G.text();
132
- G.template_effect(() => G.set_text(r, t.event.postSalesMessage)), G.append(e, r);
133
- },
134
- $$slots: { default: !0 }
135
- }), G.reset(r), G.append(e, r);
136
- };
137
- G.if(b, (e) => {
138
- t.event.postSalesMessage && e(x);
139
- });
140
- var S = G.sibling(b, 2), C = G.child(S);
141
- N(C, {
142
- get orderTotals() {
143
- return t.orderTotals;
144
- },
145
- get labels() {
146
- return n();
147
- }
148
- }), G.reset(S);
149
- var w = G.sibling(S, 2), T = G.child(w);
150
- D(T, {
151
- size: "sm",
152
- weight: "semibold",
153
- class: "font-mono",
154
- children: (e, n) => {
155
- G.next();
156
- var r = G.text();
157
- G.template_effect(() => G.set_text(r, `#${t.orderId ?? ""}`)), G.append(e, r);
158
- },
159
- $$slots: { default: !0 }
160
- }), G.reset(w);
161
- var O = G.sibling(w, 2), k = (e) => {
162
- var r = de(), i = G.child(r);
163
- c(i, {
164
- size: "16",
165
- class: "shrink-0 text-color-muted"
166
- });
167
- var a = G.sibling(i, 2);
168
- D(a, {
169
- size: "xs",
170
- color: "secondary",
171
- children: (e, r) => {
172
- G.next();
173
- var i = G.text();
174
- G.template_effect(() => G.set_text(i, `${(n().confirmationSentTo || "Confirmation sent to") ?? ""}
175
- ${t.customerEmail ?? ""}`)), G.append(e, i);
176
- },
177
- $$slots: { default: !0 }
178
- }), G.reset(r), G.append(e, r);
179
- };
180
- G.if(O, (e) => {
181
- t.customerEmail && e(k);
182
- }), G.reset(m), G.reset(o), G.template_effect(() => {
183
- d = G.set_class(u, 1, "processing-spinner svelte-667vry", null, d, { "fade-out": t.showCheckmark }), p = G.set_class(f, 0, "checkmark-svg svelte-667vry", null, p, { active: t.showCheckmark }), h = G.set_class(m, 1, "content-section svelte-667vry", null, h, { visible: t.showContent });
184
- }), G.append(e, o);
185
- },
186
- $$slots: { default: !0 }
187
- }), G.pop();
188
- }
189
- var Q = {
190
- blue: "#4285f4",
191
- green: "#34a853",
192
- yellow: "#fbbc05",
193
- red: "#ea4335"
194
- }, me = G.from_html(" <!>", 1), he = G.from_html("<p class=\"wallet-note caption svelte-4szgdz\"> </p>"), ge = G.from_html("<!> <!>", 1), _e = G.from_html("<div class=\"dropdown-menu bg-surface-primary border-default svelte-4szgdz\"><a rel=\"external noopener noreferrer\" class=\"dropdown-item type-body text-color-primary hover:bg-surface-secondary svelte-4szgdz\"><svg aria-hidden=\"true\" class=\"shrink-0\" width=\"16\" height=\"16\" viewBox=\"0 0 24 24\" fill=\"none\"><path d=\"M22.56 12.25c0-.78-.07-1.53-.2-2.25H12v4.26h5.92a5.06 5.06 0 0 1-2.2 3.32v2.77h3.57c2.08-1.92 3.28-4.74 3.28-8.1z\"></path><path d=\"M12 23c2.97 0 5.46-.98 7.28-2.66l-3.57-2.77c-.98.66-2.23 1.06-3.71 1.06-2.86 0-5.29-1.93-6.16-4.53H2.18v2.84C3.99 20.53 7.7 23 12 23z\"></path><path d=\"M5.84 14.09c-.22-.66-.35-1.36-.35-2.09s.13-1.43.35-2.09V7.07H2.18A10.96 10.96 0 0 0 1 12c0 1.77.42 3.45 1.18 4.93l3.66-2.84z\"></path><path d=\"M12 5.38c1.62 0 3.06.56 4.21 1.64l3.15-3.15C17.45 2.09 14.97 1 12 1 7.7 1 3.99 3.47 2.18 7.07l3.66 2.84c.87-2.6 3.3-4.53 6.16-4.53z\"></path></svg> </a> <button type=\"button\" class=\"dropdown-item type-body text-color-primary hover:bg-surface-secondary svelte-4szgdz\"><!> </button></div>"), ve = G.from_html("<!> ", 1), ye = G.from_html("<p class=\"copy-fallback caption svelte-4szgdz\">Copy failed — select to copy: <span class=\"copy-url svelte-4szgdz\"> </span></p>"), be = G.from_html("<span class=\"text-color-muted\">·</span> <a class=\"text-link type-caption text-color-muted hover:text-color-secondary svelte-4szgdz\"><!> </a>", 1), xe = G.from_html("<div class=\"rounded-t-xl overflow-hidden bg-surface-tertiary\"><!></div> <div class=\"p-5 space-y-4\"><div><!> <div class=\"flex items-center gap-1.5 mt-1.5\"><!> <!></div> <div class=\"mt-0.5\"><!></div></div> <div class=\"flex flex-col items-center gap-3\"><button type=\"button\" class=\"wallet-badge-btn svelte-4szgdz\"><img src=\"/wallet-badges/apple-wallet.svg\" class=\"wallet-badge-img svelte-4szgdz\"/></button> <button type=\"button\" class=\"wallet-badge-btn svelte-4szgdz\"><img src=\"/wallet-badges/google-wallet-dark.svg\" class=\"wallet-badge-img google-dark svelte-4szgdz\"/> <img src=\"/wallet-badges/google-wallet-light.svg\" class=\"wallet-badge-img google-light svelte-4szgdz\"/></button> <!></div> <div class=\"divider\"></div> <div class=\"calendar-dropdown relative\"><!> <!></div> <div class=\"flex gap-2\"><!> <!></div> <!> <div class=\"flex items-center justify-center gap-4 pt-1\"><button type=\"button\" class=\"text-link type-caption text-color-muted hover:text-color-secondary svelte-4szgdz\"><!> </button> <!></div></div>", 1), Se = G.from_html("<div><!></div>");
195
- function Ce(e, n) {
196
- G.push(n, !0);
197
- let c = G.prop(n, "backHref", 3, void 0), d = G.prop(n, "labels", 3, B), f = G.prop(n, "locale", 3, void 0), h = G.derived(() => c() || n.eventUrl), _ = G.state(!1), v = l(), y = G.state("");
198
- G.user_effect(() => {
199
- G.get(y) && C(G.get(y), { politeness: "polite" });
200
- }), G.user_effect(() => {
201
- v.copyState === "failed" && C(`Copy failed — select to copy: ${v.copyFailedUrl}`, { politeness: "assertive" });
202
- });
203
- function b() {
204
- G.set(_, !G.get(_));
205
- }
206
- J(() => {
207
- function e(e) {
208
- e.target.closest(".calendar-dropdown") || G.set(_, !1);
209
- }
210
- return document.addEventListener("click", e), () => document.removeEventListener("click", e);
211
- });
212
- let x = G.derived(() => (() => {
213
- let e = new Date(n.event.startDateTime), t = n.event.endDateTime ? new Date(n.event.endDateTime) : new Date(e.getTime() + 72e5), r = (e) => e.toISOString().replace(/[-:]/g, "").replace(/\.\d{3}/, ""), i = [n.event.venue.name, n.event.venue.address].filter(Boolean).join(", ");
214
- return `https://calendar.google.com/calendar/render?${new URLSearchParams({
215
- action: "TEMPLATE",
216
- text: n.event.title,
217
- dates: `${r(e)}/${r(t)}`,
218
- location: i,
219
- details: `Event: ${n.eventUrl}\n\nTicket confirmation #${n.orderId}`
220
- }).toString()}`;
221
- })());
222
- function S() {
223
- let e = new Date(n.event.startDateTime), t = n.event.endDateTime ? new Date(n.event.endDateTime) : new Date(e.getTime() + 72e5), r = (e) => e.toISOString().replace(/[-:]/g, "").replace(/\.\d{3}/, ""), i = `order-${n.orderId}-event-${n.event.id}@micdrop.com`, a = r(/* @__PURE__ */ new Date()), o = [n.event.venue.name, n.event.venue.address].filter(Boolean).join(", "), s = (e) => e ? e.replace(/\\/g, "\\\\").replace(/;/g, "\\;").replace(/,/g, "\\,").replace(/\n/g, "\\n") : "", c = `BEGIN:VCALENDAR
224
- VERSION:2.0
225
- PRODID:-//MicDrop//Ticket Confirmation//EN
226
- CALSCALE:GREGORIAN
227
- METHOD:PUBLISH
228
- BEGIN:VEVENT
229
- UID:${i}
230
- DTSTAMP:${a}
231
- DTSTART:${r(e)}
232
- DTEND:${r(t)}
233
- SUMMARY:${s(n.event.title)}
234
- LOCATION:${s(o)}
235
- DESCRIPTION:${s(`Order #${n.orderId}\n\nView event: ${n.eventUrl}`)}
236
- URL:${n.eventUrl}
237
- STATUS:CONFIRMED
238
- END:VEVENT
239
- END:VCALENDAR`, l = new Blob([c], { type: "text/calendar;charset=utf-8" }), u = URL.createObjectURL(l);
240
- try {
241
- let e = document.createElement("a");
242
- e.href = u, e.download = `${(n.event.title || "event").replace(/[^a-zA-Z0-9\s-]/g, "").replace(/\s+/g, "-")}.ics`, document.body.appendChild(e), e.click(), e.remove();
243
- } finally {
244
- URL.revokeObjectURL(u);
245
- }
246
- G.set(_, !1);
247
- }
248
- function w() {
249
- G.set(_, !1);
250
- }
251
- function E() {
252
- v.share(n.eventUrl);
253
- }
254
- function O() {
255
- G.set(y, d().walletComingSoon || "Wallet passes are coming soon. Your ticket is confirmed — check your email", !0);
256
- }
257
- q(v.dispose);
258
- let k = G.derived(() => (() => {
259
- let e = [n.event.venue.name, n.event.venue.address].filter(Boolean);
260
- return `https://www.google.com/maps/search/?api=1&query=${encodeURIComponent(e.join(", "))}`;
261
- })());
262
- function A() {
263
- window.location.href = G.get(h);
264
- }
265
- var j = Se();
266
- let M;
267
- var N = G.child(j);
268
- T(N, {
269
- border: !0,
270
- padding: !1,
271
- class: "rounded-xl shadow-lg overflow-hidden bg-surface-secondary",
272
- children: (e, c) => {
273
- var l = xe(), h = G.first_child(l), C = G.child(h);
274
- m(C, {
275
- get src() {
276
- return n.event.imageUrl;
277
- },
278
- get alt() {
279
- return n.event.title;
280
- },
281
- get fallback() {
282
- return te;
283
- },
284
- fit: "contain",
285
- class: "w-full max-h-60 min-h-24"
286
- }), G.reset(h);
287
- var T = G.sibling(h, 2), j = G.child(T), M = G.child(j);
288
- D(M, {
289
- size: "sm",
290
- weight: "semibold",
291
- leading: "tight",
292
- class: "block",
293
- children: (e, t) => {
294
- G.next();
295
- var r = G.text();
296
- G.template_effect(() => G.set_text(r, n.event.title)), G.append(e, r);
297
- },
298
- $$slots: { default: !0 }
299
- });
300
- var N = G.sibling(M, 2), P = G.child(N);
301
- a(P, {
302
- size: "16",
303
- class: "shrink-0 icon-muted"
304
- });
305
- var ee = G.sibling(P, 2);
306
- D(ee, {
307
- size: "xs",
308
- color: "muted",
309
- children: (e, i) => {
310
- G.next();
311
- var a = me(), o = G.first_child(a), s = G.sibling(o), c = (e) => {
312
- var r = G.text();
313
- G.template_effect((e) => G.set_text(r, `· ${e ?? ""}`), [() => t(n.event.startDateTime, n.event.timezone, f())]), G.append(e, r);
314
- };
315
- G.if(s, (e) => {
316
- n.event.displayStartTime !== !1 && e(c);
317
- }), G.template_effect((e) => G.set_text(o, `${e ?? ""} `), [() => r(n.event.startDateTime, n.event.timezone, f())]), G.append(e, a);
318
- },
319
- $$slots: { default: !0 }
320
- }), G.reset(N);
321
- var F = G.sibling(N, 2), I = G.child(F);
322
- D(I, {
323
- size: "xs",
324
- color: "muted",
325
- class: "block",
326
- children: (e, t) => {
327
- G.next();
328
- var r = G.text();
329
- G.template_effect(() => G.set_text(r, n.event.venue.name)), G.append(e, r);
330
- },
331
- $$slots: { default: !0 }
332
- }), G.reset(F), G.reset(j);
333
- var L = G.sibling(j, 2), R = G.child(L), z = G.child(R);
334
- G.reset(R);
335
- var B = G.sibling(R, 2), V = G.child(B), H = G.sibling(V, 2);
336
- G.reset(B);
337
- var ne = G.sibling(B, 2), re = (e) => {
338
- var t = he(), n = G.child(t, !0);
339
- G.reset(t), G.template_effect(() => G.set_text(n, G.get(y))), G.append(e, t);
340
- };
341
- G.if(ne, (e) => {
342
- G.get(y) && e(re);
343
- }), G.reset(L);
344
- var U = G.sibling(L, 4), W = G.child(U);
345
- g(W, {
346
- variant: "default",
347
- size: "md",
348
- class: "w-full",
349
- onclick: b,
350
- children: (e, t) => {
351
- var n = ge(), r = G.first_child(n);
352
- a(r, { size: "16" });
353
- var i = G.sibling(r), s = G.sibling(i);
354
- {
355
- let e = G.derived(() => G.get(_) ? "rotate-180" : "");
356
- o(s, {
357
- size: "16",
358
- get class() {
359
- return `ml-auto transition-transform ${G.get(e) ?? ""}`;
360
- }
361
- });
362
- }
363
- G.template_effect(() => G.set_text(i, ` ${(d().addToCalendar || "Add to calendar") ?? ""} `)), G.append(e, n);
364
- },
365
- $$slots: { default: !0 }
366
- });
367
- var ie = G.sibling(W, 2), ae = (e) => {
368
- var t = _e(), n = G.child(t), r = G.child(n), i = G.child(r), a = G.sibling(i), o = G.sibling(a), c = G.sibling(o);
369
- G.reset(r);
370
- var l = G.sibling(r);
371
- G.reset(n);
372
- var u = G.sibling(n, 2), f = G.child(u);
373
- s(f, {
374
- size: "16",
375
- class: "shrink-0"
376
- });
377
- var p = G.sibling(f);
378
- G.reset(u), G.reset(t), G.template_effect(() => {
379
- G.set_attribute(n, "href", G.get(x)), G.set_attribute(i, "fill", Q.blue), G.set_attribute(a, "fill", Q.green), G.set_attribute(o, "fill", Q.yellow), G.set_attribute(c, "fill", Q.red), G.set_text(l, ` ${(d().googleCalendar || "Google Calendar") ?? ""}`), G.set_text(p, ` ${(d().appleCalendar || "Apple Calendar (.ics)") ?? ""}`);
380
- }), G.delegated("click", n, w), G.delegated("click", u, S), G.append(e, t);
381
- };
382
- G.if(ie, (e) => {
383
- G.get(_) && e(ae);
384
- }), G.reset(U);
385
- var K = G.sibling(U, 2), q = G.child(K);
386
- g(q, {
387
- variant: "default",
388
- size: "md",
389
- class: "flex-1",
390
- onclick: E,
391
- children: (e, t) => {
392
- var n = ve(), r = G.first_child(n);
393
- u(r, { size: "16" });
394
- var i = G.sibling(r);
395
- G.template_effect(() => G.set_text(i, ` ${(v.copyState === "copied" ? "Link copied" : d().share || "Share") ?? ""}`)), G.append(e, n);
396
- },
397
- $$slots: { default: !0 }
398
- });
399
- var J = G.sibling(q, 2), oe = (e) => {
400
- g(e, {
401
- variant: "default",
402
- size: "md",
403
- class: "flex-1",
404
- get href() {
405
- return G.get(k);
406
- },
407
- children: (e, t) => {
408
- var n = ve(), r = G.first_child(n);
409
- p(r, { size: "16" });
410
- var i = G.sibling(r);
411
- G.template_effect(() => G.set_text(i, ` ${(d().map || "Map") ?? ""}`)), G.append(e, n);
412
- },
413
- $$slots: { default: !0 }
414
- });
415
- };
416
- G.if(J, (e) => {
417
- n.event.venue.address && e(oe);
418
- }), G.reset(K);
419
- var se = G.sibling(K, 2), ce = (e) => {
420
- var t = ye(), n = G.sibling(G.child(t)), r = G.child(n, !0);
421
- G.reset(n), G.reset(t), G.template_effect(() => G.set_text(r, v.copyFailedUrl)), G.append(e, t);
422
- };
423
- G.if(se, (e) => {
424
- v.copyState === "failed" && e(ce);
425
- });
426
- var Y = G.sibling(se, 2), X = G.child(Y), Z = G.child(X);
427
- i(Z, {
428
- size: "16",
429
- class: "shrink-0"
430
- });
431
- var ue = G.sibling(Z);
432
- G.reset(X);
433
- var de = G.sibling(X, 2), fe = (e) => {
434
- var t = be(), r = G.sibling(G.first_child(t), 2), i = G.child(r);
435
- le(i, {
436
- size: "16",
437
- class: "shrink-0"
438
- });
439
- var a = G.sibling(i);
440
- G.reset(r), G.template_effect(() => {
441
- G.set_attribute(r, "href", `mailto:${n.event.venue.contactEmail ?? ""}?subject=Help with Order ${n.orderId ?? ""}`), G.set_text(a, ` ${(d().needHelp || "Need help?") ?? ""}`);
442
- }), G.append(e, t);
443
- };
444
- G.if(de, (e) => {
445
- n.event.venue.contactEmail && e(fe);
446
- }), G.reset(Y), G.reset(T), G.template_effect(() => {
447
- G.set_attribute(z, "alt", d().addToAppleWallet || "Add to Apple Wallet"), G.set_attribute(V, "alt", d().saveToGoogleWallet || "Save to Google Wallet"), G.set_attribute(H, "alt", d().saveToGoogleWallet || "Save to Google Wallet"), G.set_text(ue, ` ${(d().backToEvent || "Back to event") ?? ""}`);
448
- }), G.delegated("click", R, O), G.delegated("click", B, O), G.delegated("click", X, A), G.append(e, l);
449
- },
450
- $$slots: { default: !0 }
451
- }), G.reset(j), G.template_effect(() => M = G.set_class(j, 1, "actions-wrapper svelte-4szgdz", null, M, { visible: n.showContent })), G.append(e, j), G.pop();
452
- }
453
- G.delegate(["click"]);
454
- //#endregion
455
- //#region src/lib/public-calendar-flow/Success.svelte
456
- var we = G.from_html("<div class=\"w-full min-h-screen bg-surface-primary text-color-primary\"><div class=\"max-w-6xl mx-auto px-4 py-6 md:px-6 md:py-8\"><div class=\"vc-box-desktop-grid grid-cols-booking-split gap-8 items-start\"><!> <!> <div class=\"sticky top-6\"><!></div></div> <div class=\"vc-box-mobile space-y-6\"><!> <!> <!></div></div></div>");
457
- function Te(e, t) {
458
- G.push(t, !0);
459
- let n = ne(), r = G.derived(() => U.current), i = G.prop(t, "data", 3, void 0), a = G.prop(t, "eventUrl", 3, void 0), o = G.prop(t, "backHref", 3, void 0), s = G.prop(t, "labels", 19, () => ({})), c = G.prop(t, "locale", 3, void 0), l = G.derived(() => P(c(), s())), u = G.derived(() => !i());
460
- G.user_effect(() => {
461
- if (G.get(u)) return U.options = n, U.current = "default", U.isActive = !0, () => {
462
- U.isActive = !1, U.options = [];
463
- };
464
- });
465
- let d = {
466
- default: {
467
- event: V,
468
- orderId: "12847",
469
- lines: [{
470
- ticketId: h(101),
471
- ticketName: "General Admission",
472
- quantity: 2,
473
- unitPrice: 25,
474
- fee: 2.5,
475
- subtotal: 50
476
- }, {
477
- ticketId: h(102),
478
- ticketName: "VIP Front Row",
479
- quantity: 1,
480
- unitPrice: 55,
481
- fee: 5.5,
482
- subtotal: 55
483
- }],
484
- customerEmail: "customer@example.com"
485
- },
486
- free: {
487
- event: re,
488
- orderId: "12848",
489
- lines: [{
490
- ticketId: h(201),
491
- ticketName: "Free Entry",
492
- quantity: 2,
493
- unitPrice: 0,
494
- fee: 0,
495
- subtotal: 0
496
- }],
497
- customerEmail: "comedy.fan@gmail.com"
498
- },
499
- registration: {
500
- event: W,
501
- orderId: "12849",
502
- lines: [{
503
- ticketId: h(301),
504
- ticketName: "Workshop Seat",
505
- quantity: 1,
506
- unitPrice: 75,
507
- fee: 7.5,
508
- subtotal: 75
509
- }],
510
- customerEmail: "learner@example.com"
511
- },
512
- donation: {
513
- event: H,
514
- orderId: "12850",
515
- lines: [{
516
- ticketId: h(401),
517
- ticketName: "Donation",
518
- quantity: 1,
519
- unitPrice: 25,
520
- fee: 0,
521
- subtotal: 25
522
- }, {
523
- ticketId: h(402),
524
- ticketName: "Standard Admission",
525
- quantity: 1,
526
- unitPrice: 30,
527
- fee: 3,
528
- subtotal: 30
529
- }],
530
- customerEmail: "generous@example.com"
531
- }
532
- }, p = G.derived(() => G.get(u) ? d[G.get(r)] : i()), m = G.derived(() => (() => {
533
- let e = G.get(p).lines;
534
- if (G.get(p).serverTotals) return {
535
- lines: e,
536
- subtotal: G.get(p).serverTotals.subtotal,
537
- fees: G.get(p).serverTotals.fees,
538
- taxes: G.get(p).serverTotals.taxes,
539
- total: G.get(p).serverTotals.total,
540
- promoDiscount: G.get(p).serverTotals.promoDiscount,
541
- giftCardAmount: G.get(p).serverTotals.giftCardAmount
542
- };
543
- let t = e.reduce((e, t) => e + t.subtotal, 0), n = e.reduce((e, t) => e + t.fee * t.quantity, 0), r = M(t + n, G.get(p).event.venue.taxPercentage);
544
- return {
545
- lines: e,
546
- subtotal: t,
547
- fees: n,
548
- taxes: r,
549
- total: t + n + r,
550
- promoDiscount: 0,
551
- giftCardAmount: 0
552
- };
553
- })()), g = G.derived(() => G.get(u) ? k(G.get(p).event.id, G.get(p).event.slug) : a() || "#"), _ = G.state(!1), v = G.state(!1), y = G.state(!1);
554
- function b(e) {
555
- window.location.assign(O(e.eventID, e.slug ?? null));
556
- }
557
- function x() {
558
- if (G.get(y)) {
559
- G.set(_, !0), G.set(v, !0);
560
- return;
561
- }
562
- G.set(_, !1), G.set(v, !1), setTimeout(() => {
563
- G.set(_, !0);
564
- }, 800), setTimeout(() => {
565
- G.set(v, !0);
566
- }, 1600);
567
- }
568
- G.user_effect(() => {
569
- G.get(u) && (G.get(r), x());
570
- }), J(() => {
571
- G.set(y, window.matchMedia("(prefers-reduced-motion: reduce)").matches, !0), x();
572
- });
573
- var S = we(), C = G.child(S), w = G.child(C), T = G.child(w);
574
- pe(T, {
575
- get event() {
576
- return G.get(p).event;
577
- },
578
- get orderId() {
579
- return G.get(p).orderId;
580
- },
581
- get orderTotals() {
582
- return G.get(m);
583
- },
584
- get customerEmail() {
585
- return G.get(p).customerEmail;
586
- },
587
- get showCheckmark() {
588
- return G.get(_);
589
- },
590
- get showContent() {
591
- return G.get(v);
592
- },
593
- get labels() {
594
- return G.get(l);
595
- }
596
- });
597
- var E = G.sibling(T, 2);
598
- f(E, {
599
- get eventId() {
600
- return G.get(p).event.id;
601
- },
602
- surface: "success",
603
- get labels() {
604
- return G.get(l);
605
- },
606
- get locale() {
607
- return c();
608
- },
609
- onselect: b
610
- });
611
- var D = G.sibling(E, 2);
612
- Ce(G.child(D), {
613
- get event() {
614
- return G.get(p).event;
615
- },
616
- get orderId() {
617
- return G.get(p).orderId;
618
- },
619
- get eventUrl() {
620
- return G.get(g);
621
- },
622
- get backHref() {
623
- return o();
624
- },
625
- get showContent() {
626
- return G.get(v);
627
- },
628
- get labels() {
629
- return G.get(l);
630
- },
631
- get locale() {
632
- return c();
633
- }
634
- }), G.reset(D), G.reset(w);
635
- var A = G.sibling(w, 2), j = G.child(A);
636
- pe(j, {
637
- get event() {
638
- return G.get(p).event;
639
- },
640
- get orderId() {
641
- return G.get(p).orderId;
642
- },
643
- get orderTotals() {
644
- return G.get(m);
645
- },
646
- get customerEmail() {
647
- return G.get(p).customerEmail;
648
- },
649
- get showCheckmark() {
650
- return G.get(_);
651
- },
652
- get showContent() {
653
- return G.get(v);
654
- },
655
- get labels() {
656
- return G.get(l);
657
- }
658
- });
659
- var N = G.sibling(j, 2);
660
- Ce(N, {
661
- get event() {
662
- return G.get(p).event;
663
- },
664
- get orderId() {
665
- return G.get(p).orderId;
666
- },
667
- get eventUrl() {
668
- return G.get(g);
669
- },
670
- get backHref() {
671
- return o();
672
- },
673
- get showContent() {
674
- return G.get(v);
675
- },
676
- get labels() {
677
- return G.get(l);
678
- },
679
- get locale() {
680
- return c();
681
- }
682
- });
683
- var ee = G.sibling(N, 2);
684
- f(ee, {
685
- get eventId() {
686
- return G.get(p).event.id;
687
- },
688
- surface: "success",
689
- get labels() {
690
- return G.get(l);
691
- },
692
- get locale() {
693
- return c();
694
- },
695
- onselect: b
696
- }), G.reset(A), G.reset(C), G.reset(S), G.append(e, S), G.pop();
697
- }
698
- //#endregion
699
- //#region src/components/Views/Success.svelte
700
- var $ = e("Success"), Ee = G.from_html("<p class=\"payment-failed-title svelte-1mm1psu\"> </p> <p class=\"payment-failed-message svelte-1mm1psu\"> </p>", 1), De = G.from_html("<p class=\"payment-failed-title svelte-1mm1psu\"> </p> <p class=\"payment-failed-message svelte-1mm1psu\"> </p> <a class=\"payment-failed-retry svelte-1mm1psu\"> </a>", 1), Oe = G.from_html("<div class=\"flex flex-col items-center justify-center py-24 text-center gap-4 payment-failed-container\"><!></div>"), ke = G.from_html("<div class=\"flex flex-col items-center justify-center py-24 text-center gap-4 error-container svelte-1mm1psu\"><p class=\"svelte-1mm1psu\"> </p></div>"), Ae = G.from_html("<div class=\"flex items-center justify-center py-24 text-center loading-container svelte-1mm1psu\"><p> </p></div>");
701
- function je(e, t) {
702
- G.push(t, !0);
703
- let n = G.prop(t, "data", 19, () => ({})), r = G.prop(t, "browseUrl", 3, "/"), i = G.prop(t, "backHref", 3, void 0), a = G.prop(t, "eventUrl", 3, void 0), o = G.prop(t, "widgetId", 3, null), s = G.prop(t, "venueId", 3, null), c = G.prop(t, "labels", 19, () => ({})), l = G.prop(t, "locale", 3, void 0), u = G.derived(() => F(l(), c())), f = G.derived(() => G.get(u).ticketFallbackName), p = G.derived(() => i() || (n()?.id && n()?.slug ? O(String(n().id), String(n().slug)) : w(r(), {}))), m = G.state(null), h = G.state(""), g = G.state(null), b = G.state(!0), C = G.derived(() => String(n()?.redirectStatus || "")), T = G.derived(() => G.get(C) !== "" && G.get(C) !== "succeeded"), E = G.derived(() => G.get(C) === "pending" || G.get(C) === "processing"), D = G.state(!1), k = G.state(!1);
704
- async function M(e, t) {
705
- if (!e) return "unconfirmed";
706
- let n = X(e);
707
- if (n && t) {
708
- ie(e, n.email);
709
- let r = await S(e, {
710
- ...n,
711
- id: e,
712
- paymentIntentId: t
713
- }, l());
714
- if (r?.success) return Z(e), "ok";
715
- if (r && (r.eventCanceled || r.eventPostponed)) return Z(e), "no-charge";
716
- }
717
- try {
718
- let t = (await z(e))?.purchasedTickets;
719
- return Array.isArray(t) && t.length > 0 ? "ok" : "unconfirmed";
720
- } catch (e) {
721
- return $.warn("Success: redirect-return order check failed:", e), "unconfirmed";
722
- }
723
- }
724
- J(async () => {
725
- if (G.get(T)) {
726
- G.set(b, !1);
727
- return;
728
- }
729
- if (G.get(C) === "succeeded") {
730
- let e = await M(String(n()?.orderId || n()?.orderUuid || ""), String(n()?.paymentIntentId || ""));
731
- if (e !== "ok") {
732
- e === "no-charge" ? G.set(k, !0) : G.set(D, !0), G.set(b, !1);
733
- return;
734
- }
735
- }
736
- let { id: e, slug: t, event: r, orderId: i, orderUuid: c, customerEmail: p, ticketCount: S, value: w, currency: E } = n() || {};
737
- {
738
- let { postMessageOnSuccess: t, postMessageTargetOrigin: a } = v();
739
- if (t) {
740
- let t = {
741
- orderId: String(i || c || ""),
742
- eventId: e ?? n()?.eventId ?? r?.id ?? null
743
- };
744
- typeof w == "number" && Number.isFinite(w) && (t.value = w, t.currency = E || "USD"), A(t, a);
745
- }
746
- }
747
- {
748
- let t = e ?? n()?.eventId ?? r?.id ?? null, a = String(i || c || ""), l = "micdrop_purchased_orders", u = y(l, []) ?? [], d = !!a && u.includes(a);
749
- t != null && !d && (x(t, o(), s() || r?.venueID || r?.venueId || null), j({
750
- eventId: t,
751
- orderId: a,
752
- value: typeof w == "number" ? w : null,
753
- currency: E,
754
- contentName: r?.name || r?.title || ""
755
- }), a && _(l, [...u, a]));
756
- }
757
- G.set(h, a() || `${window.location.origin}/e/${e}-${t}`, !0);
758
- let O;
759
- try {
760
- O = d(r);
761
- } catch (e) {
762
- $.warn("Success: transformApiEvent failed:", e), G.set(g, G.get(u).failedToLoadEventData || "Failed to load event data", !0), G.set(b, !1);
763
- return;
764
- }
765
- let N = i || "", P = p || ae(N), F = [], B = null;
766
- if (await ee(l()).catch((e) => {
767
- $.warn("Success: locale bundle unavailable, receipt stays English:", e);
768
- }), N) try {
769
- let e = await z(N);
770
- if (e) {
771
- P = e.customerEmail || P;
772
- let t = e.purchasedTickets || e.tickets || [], n = new K();
773
- for (let e of t) {
774
- let t = `${e.ticketTypeId || e.ticketId || 0}-${e.ticketName || e.name || ""}`, r = n.get(t);
775
- r ? (r.quantity += 1, r.subtotal += e.purchasePrice || e.price || 0) : n.set(t, {
776
- ticketId: e.ticketTypeId || e.ticketId || 0,
777
- ticketName: e.ticketName || e.name || G.get(f),
778
- quantity: 1,
779
- unitPrice: e.purchasePrice || e.price || 0,
780
- fee: 0,
781
- subtotal: e.purchasePrice || e.price || 0
782
- });
783
- }
784
- if (F = Array.from(n.values()), typeof e.totalPrice == "number") {
785
- let t = Number(e.giftCardAmount ?? 0), n = Number(e.totalPrice) - t;
786
- B = {
787
- subtotal: e.basePrice ?? 0,
788
- fees: Number(e.surcharge ?? 0) + Number(e.cardProcessing ?? 0) + Number(e.venueKickback ?? 0),
789
- taxes: e.tax == null ? 0 : e.tax,
790
- total: n,
791
- promoDiscount: e.promoCodeStoredDiscountAmount ?? 0,
792
- giftCardAmount: t,
793
- stripeAmount: n
794
- };
795
- }
796
- }
797
- } catch (e) {
798
- $.warn("Success: getOrder failed, using route params:", e);
799
- }
800
- F.length === 0 && S > 0 && (F = [{
801
- ticketId: 0,
802
- ticketName: G.get(f),
803
- quantity: S,
804
- unitPrice: 0,
805
- fee: 0,
806
- subtotal: 0
807
- }]), G.set(m, {
808
- event: O,
809
- orderId: String(N),
810
- lines: F,
811
- customerEmail: P,
812
- ...B ? { serverTotals: B } : {}
813
- }, !0), L(String(e)), I("checkout-cartid"), I(R), G.set(b, !1);
814
- });
815
- var N = G.comment(), P = G.first_child(N), B = (e) => {
816
- var t = Oe(), n = G.child(t), r = (e) => {
817
- var t = Ee(), n = G.first_child(t), r = G.child(n, !0);
818
- G.reset(n);
819
- var i = G.sibling(n, 2), a = G.child(i, !0);
820
- G.reset(i), G.template_effect(() => {
821
- G.set_text(r, G.get(u).paymentNotConfirmedTitle || "Payment not confirmed"), G.set_text(a, G.get(u).paymentNotConfirmedMessage || "We couldn't confirm this payment yet. If it completes, a confirmation email will arrive shortly — please don't try again until then");
822
- }), G.append(e, t);
823
- }, i = (e) => {
824
- var t = De(), n = G.first_child(t), r = G.child(n, !0);
825
- G.reset(n);
826
- var i = G.sibling(n, 2), a = G.child(i, !0);
827
- G.reset(i);
828
- var o = G.sibling(i, 2), s = G.child(o, !0);
829
- G.reset(o), G.template_effect(() => {
830
- G.set_text(r, G.get(u).paymentNotCompletedTitle || "Payment wasn't completed"), G.set_text(a, G.get(u).paymentNotCompletedMessage || "The payment didn't go through, so no tickets were issued. You can head back to the event and try again"), G.set_attribute(o, "href", G.get(p)), G.set_text(s, G.get(u).backToEvent || "Back to event");
831
- }), G.append(e, t);
832
- };
833
- G.if(n, (e) => {
834
- G.get(E) || G.get(D) ? e(r) : e(i, -1);
835
- }), G.reset(t), G.append(e, t);
836
- }, te = (e) => {
837
- var t = ke(), n = G.child(t), r = G.child(n, !0);
838
- G.reset(n), G.reset(t), G.template_effect(() => G.set_text(r, G.get(g))), G.append(e, t);
839
- }, V = (e) => {
840
- var t = Ae(), n = G.child(t), r = G.child(n, !0);
841
- G.reset(n), G.reset(t), G.template_effect(() => G.set_text(r, G.get(u).loadingYourOrder || "Loading your order...")), G.append(e, t);
842
- }, H = (e) => {
843
- Te(e, {
844
- get data() {
845
- return G.get(m);
846
- },
847
- get eventUrl() {
848
- return G.get(h);
849
- },
850
- get labels() {
851
- return G.get(u);
852
- },
853
- get locale() {
854
- return l();
855
- }
856
- });
857
- };
858
- G.if(P, (e) => {
859
- G.get(T) || G.get(k) || G.get(D) ? e(B) : G.get(g) ? e(te, 1) : G.get(b) || !G.get(m) ? e(V, 2) : e(H, -1);
860
- }), G.append(e, N), G.pop();
861
- }
862
- //#endregion
863
- export { je as default };