@everymatrix/casino-header-controller 1.86.2 → 1.86.3

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 (63) hide show
  1. package/components/{CasinoHamburgerMenu-jm6p2zbt.js → CasinoHamburgerMenu-C3Q3P860.js} +855 -876
  2. package/components/CasinoHamburgerMenu-D50c8Isd.cjs +21 -0
  3. package/components/{CasinoHamburgerMenu-CFma234b.js → CasinoHamburgerMenu-DHSHA1Yh.js} +907 -928
  4. package/components/{CasinoHeaderController-D87b2QIU.js → CasinoHeaderController-BC4pg0wa.js} +72 -72
  5. package/components/{CasinoHeaderController-DTkNzQTU.cjs → CasinoHeaderController-XaQHNwIx.cjs} +1 -1
  6. package/components/{CasinoHeaderController-CnTiP2m7.js → CasinoHeaderController-npT36DZZ.js} +74 -74
  7. package/components/{CasinoSlider-D4oZEnaE.cjs → CasinoSlider-B6CpCCrr.cjs} +1 -1
  8. package/components/{CasinoSlider-BOtMd_ds.js → CasinoSlider-D20g_XEJ.js} +40 -40
  9. package/components/{CasinoSlider-Ds-P1ggH.js → CasinoSlider-DW_dAUzC.js} +41 -41
  10. package/components/PlayerAccountBalanceModal-BS5HmEVv.cjs +7 -0
  11. package/components/PlayerAccountBalanceModal-BuQWJhdA.js +1386 -0
  12. package/components/PlayerAccountBalanceModal-DYHzfxVS.js +1415 -0
  13. package/components/PlayerDeposit-BdRpo9MQ.cjs +1 -0
  14. package/components/{PlayerDeposit-BUzvurYm.js → PlayerDeposit-Cvz-_V5x.js} +73 -73
  15. package/components/{PlayerDeposit-Dv-1Bd7h.js → PlayerDeposit-DpsFs1pt.js} +73 -73
  16. package/es2015/casino-header-controller.cjs +1 -1
  17. package/es2015/casino-header-controller.js +1 -1
  18. package/esnext/casino-header-controller.js +1 -1
  19. package/package.json +1 -1
  20. package/stencil/{gamification-dropdown-92e6c856-BwcHpwXk.js → gamification-dropdown-92e6c856-9FlDdaXZ.js} +1 -1
  21. package/stencil/{gamification-dropdown-92e6c856-CcR-AkP6.cjs → gamification-dropdown-92e6c856-B4d2MW-Q.cjs} +1 -1
  22. package/stencil/{gamification-dropdown-92e6c856-BmiILCYq.js → gamification-dropdown-92e6c856-tn-Yq7Bs.js} +1 -1
  23. package/stencil/{gamification-dropdown-BWUJm0Gz.js → gamification-dropdown-BSkZ_2yT.js} +1 -1
  24. package/stencil/{gamification-dropdown-DN35_AFp.js → gamification-dropdown-BxHnff9C.js} +1 -1
  25. package/stencil/{gamification-dropdown-SaxnCWwP.cjs → gamification-dropdown-U_EjgaPG.cjs} +1 -1
  26. package/stencil/{gamification-dropdown_4-BZoM-TMQ.js → gamification-dropdown_4-Bg5WE-A_.js} +6 -6
  27. package/stencil/gamification-dropdown_4-CbIvYc1U.cjs +192 -0
  28. package/stencil/{gamification-dropdown_4-DAq1Ngf2.js → gamification-dropdown_4-V2UHFMt4.js} +6 -6
  29. package/stencil/index-1ef3a64c-Ci8o67pH.js +572 -0
  30. package/stencil/index-1ef3a64c-DO6t45b-.js +556 -0
  31. package/stencil/index-1ef3a64c-a0Pl-Mcu.cjs +1 -0
  32. package/stencil/{index-71b1bdfa-C3LPeshI.js → index-71b1bdfa-C-_4EE2K.js} +268 -264
  33. package/stencil/index-71b1bdfa-DYVZrUJ1.js +757 -0
  34. package/stencil/index-71b1bdfa-MN8Gitz4.cjs +1 -0
  35. package/stencil/{locale-TxlOHoKi.js → locale-CIZHVMDe.js} +28 -22
  36. package/stencil/{locale-B_6Rn5-v.cjs → locale-m6IHPAzW.cjs} +1 -1
  37. package/stencil/{player-elevate-card-CCx_1K_i.cjs → player-elevate-card-B7B_qdQq.cjs} +1 -1
  38. package/stencil/{player-elevate-card-CMErkb0_.js → player-elevate-card-CG1qDuSC.js} +3 -3
  39. package/stencil/{player-elevate-card-BrvL7Exg.js → player-elevate-card-IuaDUXn5.js} +3 -3
  40. package/stencil/{player-elevate-card-items-08c6fbd8-CG4FljvZ.js → player-elevate-card-items-b4571def-88tr4lyO.js} +238 -236
  41. package/stencil/player-elevate-card-items-b4571def-CEK5lBFb.cjs +102 -0
  42. package/stencil/{player-elevate-card-items-08c6fbd8-vLym6drf.js → player-elevate-card-items-b4571def-v_JqIkab.js} +238 -236
  43. package/stencil/{player-elevate-pointcard-DSlBgypN.cjs → player-elevate-pointcard-BwOGuBLd.cjs} +1 -1
  44. package/stencil/{player-elevate-pointcard-hPNPduwJ.js → player-elevate-pointcard-DLe9wfqh.js} +3 -3
  45. package/stencil/{player-elevate-pointcard-VstFZu9B.js → player-elevate-pointcard-DqpHUWpL.js} +3 -3
  46. package/stencil/{player-rakeback-card-BK33WnFy.js → player-rakeback-card-BqOd_dVA.js} +2 -2
  47. package/stencil/{player-rakeback-card-UYiRqSHE.js → player-rakeback-card-D3lBTlIQ.js} +2 -2
  48. package/stencil/{player-rakeback-card-DHSkpu_S.cjs → player-rakeback-card-XgPp7n9o.cjs} +1 -1
  49. package/stencil/{user-deposit-withdrawal-BMkFnv_T.js → user-deposit-withdrawal-BO7iiwsU.js} +147 -147
  50. package/stencil/{user-deposit-withdrawal-BWwJVuYm.cjs → user-deposit-withdrawal-C8FrBoKf.cjs} +2 -2
  51. package/stencil/{user-deposit-withdrawal-DTYylnXa.js → user-deposit-withdrawal-DLaRrJTr.js} +135 -135
  52. package/components/CasinoHamburgerMenu-fvf5EluO.cjs +0 -21
  53. package/components/PlayerAccountBalanceModal-D7fiFhUw.js +0 -1415
  54. package/components/PlayerAccountBalanceModal-ieK7z017.cjs +0 -7
  55. package/components/PlayerAccountBalanceModal-qtxu403d.js +0 -1386
  56. package/components/PlayerDeposit-Cw5oQd7g.cjs +0 -1
  57. package/stencil/gamification-dropdown_4-Tgq-7xGt.cjs +0 -192
  58. package/stencil/index-1ef3a64c-Bry_KvsO.js +0 -572
  59. package/stencil/index-1ef3a64c-Bx1m17XN.js +0 -556
  60. package/stencil/index-1ef3a64c-C47cYPkT.cjs +0 -1
  61. package/stencil/index-71b1bdfa-BidbC5KM.cjs +0 -1
  62. package/stencil/index-71b1bdfa-BvAlSNDj.js +0 -753
  63. package/stencil/player-elevate-card-items-08c6fbd8-gIVq-Jqp.cjs +0 -102
@@ -0,0 +1,1386 @@
1
+ import { b as rt, $ as it, Q as st, S as lt, i as ct, f as j, c as dt, s as ut, d as ft, g as O, e as le, y as H, j as ce, z as E, n as Xe, k as de, l as pt, o as ht, A as je, p as mt, r as yt, t as gt, u as vt, w as we, F as wt, B as be, v as He, C as nt, D as bt, H as Bt } from "./CasinoHamburgerMenu-C3Q3P860.js";
2
+ function We(p, a) {
3
+ rt(p, a);
4
+ }
5
+ function Tt(p) {
6
+ it.set(p);
7
+ }
8
+ const Ye = {
9
+ en: {
10
+ Title: "Your Balance",
11
+ Total: "Total Balance",
12
+ Real: "Cash Balance",
13
+ Bonus: "Bonus Balance",
14
+ Credit: "Credit Balance",
15
+ Casino: "Casino",
16
+ Sports: "Sports",
17
+ DepositButton: "Deposit",
18
+ Loading: "Loading ..."
19
+ },
20
+ "zh-hk": {
21
+ Title: "您的結餘",
22
+ Total: "總結餘",
23
+ Real: "現金結餘",
24
+ Bonus: "紅利結餘",
25
+ Credit: "信用結餘",
26
+ Casino: "賭場",
27
+ Sports: "體育",
28
+ DepositButton: "存款",
29
+ Loading: "載入中 ..."
30
+ },
31
+ de: {
32
+ Title: "Ihr Guthaben",
33
+ Total: "Gesamtguthaben",
34
+ Real: "Barguthaben",
35
+ Bonus: "Bonusguthaben",
36
+ Credit: "Kreditguthaben",
37
+ Casino: "Casino",
38
+ Sports: "Sport",
39
+ DepositButton: "Einzahlen",
40
+ Loading: "Wird geladen ..."
41
+ },
42
+ it: {
43
+ Title: "Il tuo saldo",
44
+ Total: "Saldo totale",
45
+ Real: "Saldo in contanti",
46
+ Bonus: "Saldo bonus",
47
+ Credit: "Saldo di credito",
48
+ Casino: "Casinò",
49
+ Sports: "Sport",
50
+ DepositButton: "Deposita",
51
+ Loading: "Caricamento ..."
52
+ },
53
+ fr: {
54
+ Title: "Votre solde",
55
+ Total: "Solde total",
56
+ Real: "Solde en espèces",
57
+ Bonus: "Solde bonus",
58
+ Credit: "Solde de crédit",
59
+ Casino: "Casino",
60
+ Sports: "Sports",
61
+ DepositButton: "Dépôt",
62
+ Loading: "Chargement ..."
63
+ },
64
+ es: {
65
+ Title: "Tu saldo",
66
+ Total: "Saldo total",
67
+ Real: "Saldo en efectivo",
68
+ Bonus: "Saldo de bono",
69
+ Credit: "Saldo de crédito",
70
+ Casino: "Casino",
71
+ Sports: "Deportes",
72
+ DepositButton: "Depósito",
73
+ Loading: "Cargando ..."
74
+ },
75
+ tr: {
76
+ Title: "Bakiyeniz",
77
+ Total: "Toplam Bakiye",
78
+ Real: "Nakit Bakiye",
79
+ Bonus: "Bonus Bakiyesi",
80
+ Credit: "Kredi Bakiyesi",
81
+ Casino: "Kumarhane",
82
+ Sports: "Spor",
83
+ DepositButton: "Yatır",
84
+ Loading: "Yükleniyor ..."
85
+ },
86
+ ru: {
87
+ Title: "Ваш баланс",
88
+ Total: "Общий баланс",
89
+ Real: "Денежный баланс",
90
+ Bonus: "Бонусный баланс",
91
+ Credit: "Кредитный баланс",
92
+ Casino: "Казино",
93
+ Sports: "Спорт",
94
+ DepositButton: "Депозит",
95
+ Loading: "Загружается ..."
96
+ },
97
+ ro: {
98
+ Title: "Soldul tău",
99
+ Total: "Sold total",
100
+ Real: "Sold în numerar",
101
+ Bonus: "Sold bonus",
102
+ Credit: "Sold credit",
103
+ Casino: "Cazinou",
104
+ Sports: "Sporturi",
105
+ DepositButton: "Depozit",
106
+ Loading: "Se încarcă ..."
107
+ },
108
+ hr: {
109
+ Title: "Vaš saldo",
110
+ Total: "Ukupni saldo",
111
+ Real: "Gotovinski saldo",
112
+ Bonus: "Bonus saldo",
113
+ Credit: "Kreditni saldo",
114
+ Casino: "Casino",
115
+ Sports: "Sportovi",
116
+ DepositButton: "Depozit",
117
+ Loading: "Učitavanje ..."
118
+ },
119
+ hu: {
120
+ Title: "Az egyenleged",
121
+ Total: "Teljes egyenleg",
122
+ Real: "Készpénz egyenleg",
123
+ Bonus: "Bónusz egyenleg",
124
+ Credit: "Hitel egyenleg",
125
+ Casino: "Kaszinó",
126
+ Sports: "Sport",
127
+ DepositButton: "Befizetés",
128
+ Loading: "Betöltés ..."
129
+ },
130
+ pl: {
131
+ Title: "Twoje saldo",
132
+ Total: "Całkowite saldo",
133
+ Real: "Saldo gotówkowe",
134
+ Bonus: "Saldo bonusowe",
135
+ Credit: "Saldo kredytowe",
136
+ Casino: "Kasyno",
137
+ Sports: "Sport",
138
+ DepositButton: "Wpłać",
139
+ Loading: "Ładowanie ..."
140
+ },
141
+ pt: {
142
+ Title: "Seu Saldo",
143
+ Total: "Saldo Total",
144
+ Real: "Saldo em Dinheiro",
145
+ Bonus: "Saldo de Bônus",
146
+ Credit: "Saldo de Crédito",
147
+ Casino: "Cassino",
148
+ Sports: "Esportes",
149
+ DepositButton: "Depositar",
150
+ Loading: "Carregando ..."
151
+ },
152
+ sl: {
153
+ Title: "Vaš saldo",
154
+ Total: "Skupni saldo",
155
+ Real: "Gotovinski saldo",
156
+ Bonus: "Bonus saldo",
157
+ Credit: "Kreditni saldo",
158
+ Casino: "Kasino",
159
+ Sports: "Šport",
160
+ DepositButton: "Depozit",
161
+ Loading: "Nalaganje ..."
162
+ },
163
+ sr: {
164
+ Title: "Vaš saldo",
165
+ Total: "Ukupan saldo",
166
+ Real: "Gotovinski saldo",
167
+ Bonus: "Bonus saldo",
168
+ Credit: "Kreditni saldo",
169
+ Casino: "Kasino",
170
+ Sports: "Sport",
171
+ DepositButton: "Depozit",
172
+ Loading: "Učitavanje ..."
173
+ },
174
+ "pt-br": {
175
+ Title: "Seu Saldo",
176
+ Total: "Saldo Total",
177
+ Real: "Saldo em Dinheiro",
178
+ Bonus: "Saldo de Bônus",
179
+ Credit: "Saldo de Crédito",
180
+ Casino: "Cassino",
181
+ Sports: "Esportes",
182
+ DepositButton: "Depositar",
183
+ Loading: "Carregando ..."
184
+ },
185
+ "es-mx": {
186
+ Title: "Tu saldo",
187
+ Total: "Saldo total",
188
+ Real: "Saldo en efectivo",
189
+ Bonus: "Saldo de bono",
190
+ Credit: "Saldo de crédito",
191
+ Casino: "Casino",
192
+ Sports: "Deportes",
193
+ DepositButton: "Depósito",
194
+ Loading: "Cargando ..."
195
+ },
196
+ "en-us": {
197
+ Title: "Your Balance",
198
+ Total: "Total Balance",
199
+ Real: "Cash Balance",
200
+ Bonus: "Bonus Balance",
201
+ Credit: "Credit Balance",
202
+ Casino: "Casino",
203
+ Sports: "Sports",
204
+ DepositButton: "Deposit",
205
+ Loading: "Loading ..."
206
+ }
207
+ };
208
+ var Ke = { exports: {} };
209
+ /** @license
210
+ * eventsource.js
211
+ * Available under MIT License (MIT)
212
+ * https://github.com/Yaffle/EventSource/
213
+ */
214
+ (function(p, a) {
215
+ (function(o) {
216
+ var y = o.setTimeout, f = o.clearTimeout, c = o.XMLHttpRequest, w = o.XDomainRequest, h = o.ActiveXObject, b = o.EventSource, _ = o.document, S = o.Promise, C = o.fetch, R = o.Response, x = o.TextDecoder, L = o.TextEncoder, $ = o.AbortController;
217
+ if (typeof window < "u" && typeof _ < "u" && !("readyState" in _) && _.body == null && (_.readyState = "loading", window.addEventListener("load", function(t) {
218
+ _.readyState = "complete";
219
+ }, !1)), c == null && h != null && (c = function() {
220
+ return new h("Microsoft.XMLHTTP");
221
+ }), Object.create == null && (Object.create = function(t) {
222
+ function s() {
223
+ }
224
+ return s.prototype = t, new s();
225
+ }), Date.now || (Date.now = function() {
226
+ return (/* @__PURE__ */ new Date()).getTime();
227
+ }), $ == null) {
228
+ var ne = C;
229
+ C = function(t, s) {
230
+ var e = s.signal;
231
+ return ne(t, { headers: s.headers, credentials: s.credentials, cache: s.cache }).then(function(n) {
232
+ var i = n.body.getReader();
233
+ return e._reader = i, e._aborted && e._reader.cancel(), {
234
+ status: n.status,
235
+ statusText: n.statusText,
236
+ headers: n.headers,
237
+ body: {
238
+ getReader: function() {
239
+ return i;
240
+ }
241
+ }
242
+ };
243
+ });
244
+ }, $ = function() {
245
+ this.signal = {
246
+ _reader: null,
247
+ _aborted: !1
248
+ }, this.abort = function() {
249
+ this.signal._reader != null && this.signal._reader.cancel(), this.signal._aborted = !0;
250
+ };
251
+ };
252
+ }
253
+ function ae() {
254
+ this.bitsNeeded = 0, this.codePoint = 0;
255
+ }
256
+ ae.prototype.decode = function(t) {
257
+ function s(g, B, m) {
258
+ if (m === 1)
259
+ return g >= 128 >> B && g << B <= 2047;
260
+ if (m === 2)
261
+ return g >= 2048 >> B && g << B <= 55295 || g >= 57344 >> B && g << B <= 65535;
262
+ if (m === 3)
263
+ return g >= 65536 >> B && g << B <= 1114111;
264
+ throw new Error();
265
+ }
266
+ function e(g, B) {
267
+ if (g === 6 * 1)
268
+ return B >> 6 > 15 ? 3 : B > 31 ? 2 : 1;
269
+ if (g === 6 * 2)
270
+ return B > 15 ? 3 : 2;
271
+ if (g === 6 * 3)
272
+ return 3;
273
+ throw new Error();
274
+ }
275
+ for (var n = 65533, i = "", r = this.bitsNeeded, u = this.codePoint, v = 0; v < t.length; v += 1) {
276
+ var l = t[v];
277
+ r !== 0 && (l < 128 || l > 191 || !s(u << 6 | l & 63, r - 6, e(r, u))) && (r = 0, u = n, i += String.fromCharCode(u)), r === 0 ? (l >= 0 && l <= 127 ? (r = 0, u = l) : l >= 192 && l <= 223 ? (r = 6 * 1, u = l & 31) : l >= 224 && l <= 239 ? (r = 6 * 2, u = l & 15) : l >= 240 && l <= 247 ? (r = 6 * 3, u = l & 7) : (r = 0, u = n), r !== 0 && !s(u, r, e(r, u)) && (r = 0, u = n)) : (r -= 6, u = u << 6 | l & 63), r === 0 && (u <= 65535 ? i += String.fromCharCode(u) : (i += String.fromCharCode(55296 + (u - 65535 - 1 >> 10)), i += String.fromCharCode(56320 + (u - 65535 - 1 & 1023))));
278
+ }
279
+ return this.bitsNeeded = r, this.codePoint = u, i;
280
+ };
281
+ var X = function() {
282
+ try {
283
+ return new x().decode(new L().encode("test"), { stream: !0 }) === "test";
284
+ } catch (t) {
285
+ console.debug("TextDecoder does not support streaming option. Using polyfill instead: " + t);
286
+ }
287
+ return !1;
288
+ };
289
+ (x == null || L == null || !X()) && (x = ae);
290
+ var T = function() {
291
+ };
292
+ function A(t) {
293
+ this.withCredentials = !1, this.readyState = 0, this.status = 0, this.statusText = "", this.responseText = "", this.onprogress = T, this.onload = T, this.onerror = T, this.onreadystatechange = T, this._contentType = "", this._xhr = t, this._sendTimeout = 0, this._abort = T;
294
+ }
295
+ A.prototype.open = function(t, s) {
296
+ this._abort(!0);
297
+ var e = this, n = this._xhr, i = 1, r = 0;
298
+ this._abort = function(m) {
299
+ e._sendTimeout !== 0 && (f(e._sendTimeout), e._sendTimeout = 0), (i === 1 || i === 2 || i === 3) && (i = 4, n.onload = T, n.onerror = T, n.onabort = T, n.onprogress = T, n.onreadystatechange = T, n.abort(), r !== 0 && (f(r), r = 0), m || (e.readyState = 4, e.onabort(null), e.onreadystatechange())), i = 0;
300
+ };
301
+ var u = function() {
302
+ if (i === 1) {
303
+ var m = 0, D = "", U = void 0;
304
+ if ("contentType" in n)
305
+ m = 200, D = "OK", U = n.contentType;
306
+ else
307
+ try {
308
+ m = n.status, D = n.statusText, U = n.getResponseHeader("Content-Type");
309
+ } catch {
310
+ m = 0, D = "", U = void 0;
311
+ }
312
+ m !== 0 && (i = 2, e.readyState = 2, e.status = m, e.statusText = D, e._contentType = U, e.onreadystatechange());
313
+ }
314
+ }, v = function() {
315
+ if (u(), i === 2 || i === 3) {
316
+ i = 3;
317
+ var m = "";
318
+ try {
319
+ m = n.responseText;
320
+ } catch {
321
+ }
322
+ e.readyState = 3, e.responseText = m, e.onprogress();
323
+ }
324
+ }, l = function(m, D) {
325
+ if ((D == null || D.preventDefault == null) && (D = {
326
+ preventDefault: T
327
+ }), v(), i === 1 || i === 2 || i === 3) {
328
+ if (i = 4, r !== 0 && (f(r), r = 0), e.readyState = 4, m === "load")
329
+ e.onload(D);
330
+ else if (m === "error")
331
+ e.onerror(D);
332
+ else if (m === "abort")
333
+ e.onabort(D);
334
+ else
335
+ throw new TypeError();
336
+ e.onreadystatechange();
337
+ }
338
+ }, g = function(m) {
339
+ n != null && (n.readyState === 4 ? (!("onload" in n) || !("onerror" in n) || !("onabort" in n)) && l(n.responseText === "" ? "error" : "load", m) : n.readyState === 3 ? "onprogress" in n || v() : n.readyState === 2 && u());
340
+ }, B = function() {
341
+ r = y(function() {
342
+ B();
343
+ }, 500), n.readyState === 3 && v();
344
+ };
345
+ "onload" in n && (n.onload = function(m) {
346
+ l("load", m);
347
+ }), "onerror" in n && (n.onerror = function(m) {
348
+ l("error", m);
349
+ }), "onabort" in n && (n.onabort = function(m) {
350
+ l("abort", m);
351
+ }), "onprogress" in n && (n.onprogress = v), "onreadystatechange" in n && (n.onreadystatechange = function(m) {
352
+ g(m);
353
+ }), ("contentType" in n || !("ontimeout" in c.prototype)) && (s += (s.indexOf("?") === -1 ? "?" : "&") + "padding=true"), n.open(t, s, !0), "readyState" in n && (r = y(function() {
354
+ B();
355
+ }, 0));
356
+ }, A.prototype.abort = function() {
357
+ this._abort(!1);
358
+ }, A.prototype.getResponseHeader = function(t) {
359
+ return this._contentType;
360
+ }, A.prototype.setRequestHeader = function(t, s) {
361
+ var e = this._xhr;
362
+ "setRequestHeader" in e && e.setRequestHeader(t, s);
363
+ }, A.prototype.getAllResponseHeaders = function() {
364
+ return this._xhr.getAllResponseHeaders != null && this._xhr.getAllResponseHeaders() || "";
365
+ }, A.prototype.send = function() {
366
+ if ((!("ontimeout" in c.prototype) || !("sendAsBinary" in c.prototype) && !("mozAnon" in c.prototype)) && _ != null && _.readyState != null && _.readyState !== "complete") {
367
+ var t = this;
368
+ t._sendTimeout = y(function() {
369
+ t._sendTimeout = 0, t.send();
370
+ }, 4);
371
+ return;
372
+ }
373
+ var s = this._xhr;
374
+ "withCredentials" in s && (s.withCredentials = this.withCredentials);
375
+ try {
376
+ s.send(void 0);
377
+ } catch (e) {
378
+ throw e;
379
+ }
380
+ };
381
+ function F(t) {
382
+ return t.replace(/[A-Z]/g, function(s) {
383
+ return String.fromCharCode(s.charCodeAt(0) + 32);
384
+ });
385
+ }
386
+ function M(t) {
387
+ for (var s = /* @__PURE__ */ Object.create(null), e = t.split(`\r
388
+ `), n = 0; n < e.length; n += 1) {
389
+ var i = e[n], r = i.split(": "), u = r.shift(), v = r.join(": ");
390
+ s[F(u)] = v;
391
+ }
392
+ this._map = s;
393
+ }
394
+ M.prototype.get = function(t) {
395
+ return this._map[F(t)];
396
+ }, c != null && c.HEADERS_RECEIVED == null && (c.HEADERS_RECEIVED = 2);
397
+ function K() {
398
+ }
399
+ K.prototype.open = function(t, s, e, n, i, r, u) {
400
+ t.open("GET", i);
401
+ var v = 0;
402
+ t.onprogress = function() {
403
+ var g = t.responseText, B = g.slice(v);
404
+ v += B.length, e(B);
405
+ }, t.onerror = function(g) {
406
+ g.preventDefault(), n(new Error("NetworkError"));
407
+ }, t.onload = function() {
408
+ n(null);
409
+ }, t.onabort = function() {
410
+ n(null);
411
+ }, t.onreadystatechange = function() {
412
+ if (t.readyState === c.HEADERS_RECEIVED) {
413
+ var g = t.status, B = t.statusText, m = t.getResponseHeader("Content-Type"), D = t.getAllResponseHeaders();
414
+ s(g, B, m, new M(D));
415
+ }
416
+ }, t.withCredentials = r;
417
+ for (var l in u)
418
+ Object.prototype.hasOwnProperty.call(u, l) && t.setRequestHeader(l, u[l]);
419
+ return t.send(), t;
420
+ };
421
+ function ue(t) {
422
+ this._headers = t;
423
+ }
424
+ ue.prototype.get = function(t) {
425
+ return this._headers.get(t);
426
+ };
427
+ function fe() {
428
+ }
429
+ fe.prototype.open = function(t, s, e, n, i, r, u) {
430
+ var v = null, l = new $(), g = l.signal, B = new x();
431
+ return C(i, {
432
+ headers: u,
433
+ credentials: r ? "include" : "same-origin",
434
+ signal: g,
435
+ cache: "no-store"
436
+ }).then(function(m) {
437
+ return v = m.body.getReader(), s(m.status, m.statusText, m.headers.get("Content-Type"), new ue(m.headers)), new S(function(D, U) {
438
+ var Ee = function() {
439
+ v.read().then(function(W) {
440
+ if (W.done)
441
+ D(void 0);
442
+ else {
443
+ var P = B.decode(W.value, { stream: !0 });
444
+ e(P), Ee();
445
+ }
446
+ }).catch(function(W) {
447
+ U(W);
448
+ });
449
+ };
450
+ Ee();
451
+ });
452
+ }).catch(function(m) {
453
+ if (m.name !== "AbortError")
454
+ return m;
455
+ }).then(function(m) {
456
+ n(m);
457
+ }), {
458
+ abort: function() {
459
+ v?.cancel(), l.abort();
460
+ }
461
+ };
462
+ };
463
+ function Z() {
464
+ this._listeners = /* @__PURE__ */ Object.create(null);
465
+ }
466
+ function oe(t) {
467
+ y(function() {
468
+ throw t;
469
+ }, 0);
470
+ }
471
+ Z.prototype.dispatchEvent = function(t) {
472
+ t.target = this;
473
+ var s = this._listeners[t.type];
474
+ if (s != null)
475
+ for (var e = s.length, n = 0; n < e; n += 1) {
476
+ var i = s[n];
477
+ try {
478
+ typeof i.handleEvent == "function" ? i.handleEvent(t) : i.call(this, t);
479
+ } catch (r) {
480
+ oe(r);
481
+ }
482
+ }
483
+ }, Z.prototype.addEventListener = function(t, s) {
484
+ t = String(t);
485
+ var e = this._listeners, n = e[t];
486
+ n == null && (n = [], e[t] = n);
487
+ for (var i = !1, r = 0; r < n.length; r += 1)
488
+ n[r] === s && (i = !0);
489
+ i || n.push(s);
490
+ }, Z.prototype.removeEventListener = function(t, s) {
491
+ t = String(t);
492
+ var e = this._listeners, n = e[t];
493
+ if (n != null) {
494
+ for (var i = [], r = 0; r < n.length; r += 1)
495
+ n[r] !== s && i.push(n[r]);
496
+ i.length === 0 ? delete e[t] : e[t] = i;
497
+ }
498
+ };
499
+ function z(t) {
500
+ this.type = t, this.target = void 0;
501
+ }
502
+ function pe(t, s) {
503
+ z.call(this, t), this.data = s.data, this.lastEventId = s.lastEventId;
504
+ }
505
+ pe.prototype = Object.create(z.prototype);
506
+ function d(t, s) {
507
+ z.call(this, t), this.status = s.status, this.statusText = s.statusText, this.headers = s.headers;
508
+ }
509
+ d.prototype = Object.create(z.prototype);
510
+ function he(t, s) {
511
+ z.call(this, t), this.error = s.error;
512
+ }
513
+ he.prototype = Object.create(z.prototype);
514
+ var Ce = -1, te = 0, me = 1, ge = 2, Ae = -1, J = 0, Be = 1, Le = 2, _e = 3, Me = /^text\/event\-stream(;.*)?$/i, ze = 1e3, Fe = 18e6, xe = function(t, s) {
515
+ var e = t == null ? s : parseInt(t, 10);
516
+ return e !== e && (e = s), Re(e);
517
+ }, Re = function(t) {
518
+ return Math.min(Math.max(t, ze), Fe);
519
+ }, ye = function(t, s, e) {
520
+ try {
521
+ typeof s == "function" && s.call(t, e);
522
+ } catch (n) {
523
+ oe(n);
524
+ }
525
+ };
526
+ function q(t, s) {
527
+ Z.call(this), s = s || {}, this.onopen = void 0, this.onmessage = void 0, this.onerror = void 0, this.url = void 0, this.readyState = void 0, this.withCredentials = void 0, this.headers = void 0, this._close = void 0, Pe(this, t, s);
528
+ }
529
+ function ke() {
530
+ return c != null && "withCredentials" in c.prototype || w == null ? new c() : new w();
531
+ }
532
+ var Ue = C != null && R != null && "body" in R.prototype;
533
+ function Pe(t, s, e) {
534
+ s = String(s);
535
+ var n = !!e.withCredentials, i = e.lastEventIdQueryParameterName || "lastEventId", r = Re(1e3), u = xe(e.heartbeatTimeout, 45e3), v = "", l = r, g = !1, B = 0, m = e.headers || {}, D = e.Transport, U = Ue && D == null ? void 0 : new A(D != null ? new D() : ke()), Ee = D != null && typeof D != "string" ? new D() : U == null ? new fe() : new K(), W = void 0, P = 0, ee = Ce, Te = "", Ne = "", re = "", Ie = "", V = J, Ve = 0, ve = 0, at = function(N, k, Y, Q) {
536
+ if (ee === te)
537
+ if (N === 200 && Y != null && Me.test(Y)) {
538
+ ee = me, g = Date.now(), l = r, t.readyState = me;
539
+ var G = new d("open", {
540
+ status: N,
541
+ statusText: k,
542
+ headers: Q
543
+ });
544
+ t.dispatchEvent(G), ye(t, t.onopen, G);
545
+ } else {
546
+ var I = "";
547
+ N !== 200 ? (k && (k = k.replace(/\s+/g, " ")), I = "EventSource's response has a status " + N + " " + k + " that is not 200. Aborting the connection.") : I = "EventSource's response has a Content-Type specifying an unsupported type: " + (Y == null ? "-" : Y.replace(/\s+/g, " ")) + ". Aborting the connection.", Ge();
548
+ var G = new d("error", {
549
+ status: N,
550
+ statusText: k,
551
+ headers: Q
552
+ });
553
+ t.dispatchEvent(G), ye(t, t.onerror, G), console.error(I);
554
+ }
555
+ }, ot = function(N) {
556
+ if (ee === me) {
557
+ for (var k = -1, Y = 0; Y < N.length; Y += 1) {
558
+ var Q = N.charCodeAt(Y);
559
+ (Q === 10 || Q === 13) && (k = Y);
560
+ }
561
+ var G = (k !== -1 ? Ie : "") + N.slice(0, k + 1);
562
+ Ie = (k === -1 ? Ie : "") + N.slice(k + 1), N !== "" && (g = Date.now(), B += N.length);
563
+ for (var I = 0; I < G.length; I += 1) {
564
+ var Q = G.charCodeAt(I);
565
+ if (V === Ae && Q === 10)
566
+ V = J;
567
+ else if (V === Ae && (V = J), Q === 13 || Q === 10) {
568
+ if (V !== J) {
569
+ V === Be && (ve = I + 1);
570
+ var ie = G.slice(Ve, ve - 1), se = G.slice(ve + (ve < I && G.charCodeAt(ve) === 32 ? 1 : 0), I);
571
+ ie === "data" ? (Te += `
572
+ `, Te += se) : ie === "id" ? Ne = se : ie === "event" ? re = se : ie === "retry" ? (r = xe(se, r), l = r) : ie === "heartbeatTimeout" && (u = xe(se, u), P !== 0 && (f(P), P = y(function() {
573
+ De();
574
+ }, u)));
575
+ }
576
+ if (V === J) {
577
+ if (Te !== "") {
578
+ v = Ne, re === "" && (re = "message");
579
+ var Se = new pe(re, {
580
+ data: Te.slice(1),
581
+ lastEventId: Ne
582
+ });
583
+ if (t.dispatchEvent(Se), re === "open" ? ye(t, t.onopen, Se) : re === "message" ? ye(t, t.onmessage, Se) : re === "error" && ye(t, t.onerror, Se), ee === ge)
584
+ return;
585
+ }
586
+ Te = "", re = "";
587
+ }
588
+ V = Q === 13 ? Ae : J;
589
+ } else
590
+ V === J && (Ve = I, V = Be), V === Be ? Q === 58 && (ve = I + 1, V = Le) : V === Le && (V = _e);
591
+ }
592
+ }
593
+ }, qe = function(N) {
594
+ if (ee === me || ee === te) {
595
+ ee = Ce, P !== 0 && (f(P), P = 0), P = y(function() {
596
+ De();
597
+ }, l), l = Re(Math.min(r * 16, l * 2)), t.readyState = te;
598
+ var k = new he("error", { error: N });
599
+ t.dispatchEvent(k), ye(t, t.onerror, k), N != null && console.error(N);
600
+ }
601
+ }, Ge = function() {
602
+ ee = ge, W != null && (W.abort(), W = void 0), P !== 0 && (f(P), P = 0), t.readyState = ge;
603
+ }, De = function() {
604
+ if (P = 0, ee !== Ce) {
605
+ if (!g && W != null)
606
+ qe(new Error("No activity within " + u + " milliseconds. " + (ee === te ? "No response received." : B + " chars received.") + " Reconnecting.")), W != null && (W.abort(), W = void 0);
607
+ else {
608
+ var N = Math.max((g || Date.now()) + u - Date.now(), 1);
609
+ g = !1, P = y(function() {
610
+ De();
611
+ }, N);
612
+ }
613
+ return;
614
+ }
615
+ g = !1, B = 0, P = y(function() {
616
+ De();
617
+ }, u), ee = te, Te = "", re = "", Ne = v, Ie = "", Ve = 0, ve = 0, V = J;
618
+ var k = s;
619
+ if (s.slice(0, 5) !== "data:" && s.slice(0, 5) !== "blob:" && v !== "") {
620
+ var Y = s.indexOf("?");
621
+ k = Y === -1 ? s : s.slice(0, Y + 1) + s.slice(Y + 1).replace(/(?:^|&)([^=&]*)(?:=[^&]*)?/g, function(se, Se) {
622
+ return Se === i ? "" : se;
623
+ }), k += (s.indexOf("?") === -1 ? "?" : "&") + i + "=" + encodeURIComponent(v);
624
+ }
625
+ var Q = t.withCredentials, G = {};
626
+ G.Accept = "text/event-stream";
627
+ var I = t.headers;
628
+ if (I != null)
629
+ for (var ie in I)
630
+ Object.prototype.hasOwnProperty.call(I, ie) && (G[ie] = I[ie]);
631
+ try {
632
+ W = Ee.open(U, at, ot, qe, k, Q, G);
633
+ } catch (se) {
634
+ throw Ge(), se;
635
+ }
636
+ };
637
+ t.url = s, t.readyState = te, t.withCredentials = n, t.headers = m, t._close = Ge, De();
638
+ }
639
+ q.prototype = Object.create(Z.prototype), q.prototype.CONNECTING = te, q.prototype.OPEN = me, q.prototype.CLOSED = ge, q.prototype.close = function() {
640
+ this._close();
641
+ }, q.CONNECTING = te, q.OPEN = me, q.CLOSED = ge, q.prototype.withCredentials = void 0;
642
+ var Oe = b;
643
+ c != null && (b == null || !("withCredentials" in b.prototype)) && (Oe = q), function(t) {
644
+ {
645
+ var s = t(a);
646
+ s !== void 0 && (p.exports = s);
647
+ }
648
+ }(function(t) {
649
+ t.EventSourcePolyfill = q, t.NativeEventSource = b, t.EventSource = Oe;
650
+ });
651
+ })(typeof globalThis > "u" ? typeof window < "u" ? window : typeof self < "u" ? self : st : globalThis);
652
+ })(Ke, Ke.exports);
653
+ var St = Ke.exports;
654
+ function Ct(p) {
655
+ ft(p, "svelte-gv6dm2", '*,*::before,*::after{font-family:inherit}:host{font-family:inherit}input,textarea,button{font-family:inherit}p{padding:0;margin:0}.ShowBalance{position:relative}.ShowBalance .Loading{font-size:14px;white-space:nowrap;padding-right:10px}.ShowBalance .BalanceValue{font-size:14px;cursor:pointer;display:flex;flex-wrap:nowrap;white-space:nowrap;background:transparent;border:none;font:inherit;color:inherit}.ShowBalance .BalanceValue svg{width:16px}.ShowBalance .BalanceValue span{padding-left:8px}@media only screen and (max-width: 360px){.ShowBalance .BalanceValue{font-size:12px}.ShowBalance .BalanceValue svg{width:12px}}.BalanceModalWrapper{background-color:var(--emw--color-white, #FFFFFF);position:absolute;top:45px;left:50%;transform:translateX(-60%);padding:10px;box-shadow:0px 30px 30px var(--emw--header-color-primary, var(--emw--color-primary, #22B04E));border-radius:5px;z-index:17;box-shadow:0px 5px 20px 0px #191919}.BalanceModalWrapper:before{content:"";background:var(--emw--color-white, #FFFFFF);clip-path:polygon(50% 0, 0% 100%, 100% 100%);position:absolute;top:-8px;left:60%;width:25px;height:10px;transform:translateX(-50%);z-index:1}.BalanceModalClose{position:absolute;top:5px;right:5px;width:20px;height:20px;z-index:1;cursor:pointer;font:inherit}.BalanceModalClose:before{content:"";background:var(--emw--color-secondary, var(--emw--color-secondary, #FD2839));position:absolute;top:8px;left:0;width:20px;height:2px;transform:rotate(45deg)}.BalanceModalClose:after{content:"";background:var(--emw--color-secondary, var(--emw--color-secondary, #FD2839));position:absolute;top:8px;left:0;width:20px;height:2px;transform:rotate(-45deg)}.BalanceModal{position:relative;width:280px}.BalanceModalHeader{display:flex;align-items:center;justify-content:center;padding:20px 0}.BalanceModalHeader .BalanceModalTitle{font-size:16px;font-weight:bold;color:var(--emw--header-contrast, var(--emw--color-contrast, #07072A))}.BalanceModalRowBoth{display:flex;flex-direction:column;gap:5px;padding:20px 0;border-bottom:1px solid var(--emw--color-gray-100, #E6E6E6)}.BalanceModalRowBoth:last-child{border-bottom:none}.BalanceModalRowBoth .BalanceModalRowLine{display:flex;width:100%;justify-content:space-between}.BalanceModalRowBoth .BalanceModalText{color:var(--emw--header-contrast, var(--emw--color-contrast, #07072A));font-size:14px;text-transform:capitalize}.BalanceModalRowBoth .BalanceModalValue{font-size:14px;font-weight:bold;color:var(--emw--header-contrast, var(--emw--color-contrast, #07072A))}.BalanceModalFooter{display:flex;align-items:center;padding:20px 0 10px}.BalanceModalFooter .BalanceModalAction{background:var(--emw--header-color-primary, var(--emw--color-primary, #22B04E));font-size:12px;color:white;text-transform:uppercase;width:100%;border-radius:5px;border:none;padding:10px 0;cursor:pointer}.BalanceModalFooter .BalanceModalAction:hover,.BalanceModalFooter .BalanceModalActionactive{background:var(--emw--header-contrast, var(--emw--color-background, #07072A))}.ShowBalanceModalOverlay{background-color:rgba(0, 0, 0, 0.7);position:fixed;top:0;bottom:0;left:0;right:0;z-index:16}');
656
+ }
657
+ function Qe(p, a, o) {
658
+ const y = p.slice();
659
+ return y[51] = a[o], y;
660
+ }
661
+ function Ze(p, a, o) {
662
+ const y = p.slice();
663
+ return y[54] = a[o], y;
664
+ }
665
+ function At(p) {
666
+ let a, o = (
667
+ /*balances*/
668
+ (p[3].Total ? (
669
+ /*formatBalance*/
670
+ p[5](
671
+ /*balances*/
672
+ p[3].Total[0].amount
673
+ )
674
+ ) : "0") + ""
675
+ ), y, f, c, w, h, b, _, S = (
676
+ /*isModalDisplayed*/
677
+ p[2] && Je(p)
678
+ );
679
+ return {
680
+ c() {
681
+ a = O("button"), y = we(o), f = le(), c = O("span"), c.innerHTML = '<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 20 11.435"><defs><style>.a{fill:var(--emw--color-white, #FFFFFF);}</style></defs><path class="a" d="M16.191,19.235l7.562-7.568a1.423,1.423,0,0,1,2.019,0,1.441,1.441,0,0,1,0,2.025L17.2,22.265a1.427,1.427,0,0,1-1.971.042L6.6,13.7a1.429,1.429,0,0,1,2.019-2.025Z" transform="translate(-6.188 -11.246)"></path></svg>', w = le(), S && S.c(), h = wt(), H(a, "class", "BalanceValue");
682
+ },
683
+ m(C, R) {
684
+ ce(C, a, R), E(a, y), E(a, f), E(a, c), ce(C, w, R), S && S.m(C, R), ce(C, h, R), b || (_ = je(
685
+ a,
686
+ "click",
687
+ /*click_handler*/
688
+ p[25]
689
+ ), b = !0);
690
+ },
691
+ p(C, R) {
692
+ R[0] & /*balances*/
693
+ 8 && o !== (o = /*balances*/
694
+ (C[3].Total ? (
695
+ /*formatBalance*/
696
+ C[5](
697
+ /*balances*/
698
+ C[3].Total[0].amount
699
+ )
700
+ ) : "0") + "") && be(y, o), /*isModalDisplayed*/
701
+ C[2] ? S ? S.p(C, R) : (S = Je(C), S.c(), S.m(h.parentNode, h)) : S && (S.d(1), S = null);
702
+ },
703
+ d(C) {
704
+ C && (de(a), de(w), de(h)), S && S.d(C), b = !1, _();
705
+ }
706
+ };
707
+ }
708
+ function _t(p) {
709
+ let a, o = (
710
+ /*$_*/
711
+ p[4]("Loading") + ""
712
+ ), y;
713
+ return {
714
+ c() {
715
+ a = O("p"), y = we(o);
716
+ },
717
+ m(f, c) {
718
+ ce(f, a, c), E(a, y);
719
+ },
720
+ p(f, c) {
721
+ c[0] & /*$_*/
722
+ 16 && o !== (o = /*$_*/
723
+ f[4]("Loading") + "") && be(y, o);
724
+ },
725
+ d(f) {
726
+ f && de(a);
727
+ }
728
+ };
729
+ }
730
+ function Je(p) {
731
+ let a, o, y, f, c, w, h = (
732
+ /*$_*/
733
+ p[4]("Title") + ""
734
+ ), b, _, S, C, R, x, L = (
735
+ /*$_*/
736
+ p[4]("DepositButton") + ""
737
+ ), $, ne, ae, X = He(Object.keys(
738
+ /*balances*/
739
+ p[3]
740
+ )), T = [];
741
+ for (let A = 0; A < X.length; A += 1)
742
+ T[A] = et(Qe(p, X, A));
743
+ return {
744
+ c() {
745
+ a = O("div"), o = O("button"), y = le(), f = O("div"), c = O("div"), w = O("p"), b = we(h), _ = le(), S = O("div");
746
+ for (let A = 0; A < T.length; A += 1)
747
+ T[A].c();
748
+ C = le(), R = O("div"), x = O("button"), $ = we(L), H(o, "class", "BalanceModalClose"), H(w, "class", "BalanceModalTitle"), H(c, "class", "BalanceModalHeader"), H(S, "class", "BalanceModalBody"), H(x, "class", "BalanceModalAction"), H(R, "class", "BalanceModalFooter"), H(f, "class", "BalanceModal"), H(a, "class", "BalanceModalWrapper");
749
+ },
750
+ m(A, F) {
751
+ ce(A, a, F), E(a, o), E(a, y), E(a, f), E(f, c), E(c, w), E(w, b), E(f, _), E(f, S);
752
+ for (let M = 0; M < T.length; M += 1)
753
+ T[M] && T[M].m(S, null);
754
+ E(f, C), E(f, R), E(R, x), E(x, $), ne || (ae = [
755
+ je(
756
+ o,
757
+ "click",
758
+ /*click_handler_1*/
759
+ p[26]
760
+ ),
761
+ je(
762
+ x,
763
+ "click",
764
+ /*click_handler_2*/
765
+ p[27]
766
+ )
767
+ ], ne = !0);
768
+ },
769
+ p(A, F) {
770
+ if (F[0] & /*$_*/
771
+ 16 && h !== (h = /*$_*/
772
+ A[4]("Title") + "") && be(b, h), F[0] & /*balances, formatBalance, getProductType, $_*/
773
+ 184) {
774
+ X = He(Object.keys(
775
+ /*balances*/
776
+ A[3]
777
+ ));
778
+ let M;
779
+ for (M = 0; M < X.length; M += 1) {
780
+ const K = Qe(A, X, M);
781
+ T[M] ? T[M].p(K, F) : (T[M] = et(K), T[M].c(), T[M].m(S, null));
782
+ }
783
+ for (; M < T.length; M += 1)
784
+ T[M].d(1);
785
+ T.length = X.length;
786
+ }
787
+ F[0] & /*$_*/
788
+ 16 && L !== (L = /*$_*/
789
+ A[4]("DepositButton") + "") && be($, L);
790
+ },
791
+ d(A) {
792
+ A && de(a), nt(T, A), ne = !1, bt(ae);
793
+ }
794
+ };
795
+ }
796
+ function $e(p) {
797
+ let a, o, y = (
798
+ /*$_*/
799
+ p[4](
800
+ /*k*/
801
+ p[51]
802
+ ) + ""
803
+ ), f, c, w = (
804
+ /*getProductType*/
805
+ p[7](
806
+ /*balance*/
807
+ p[54]
808
+ ) + ""
809
+ ), h, b, _, S, C = (
810
+ /*formatBalance*/
811
+ p[5](
812
+ /*balance*/
813
+ p[54].amount
814
+ ) + ""
815
+ ), R;
816
+ return {
817
+ c() {
818
+ a = O("div"), o = O("p"), f = we(y), c = le(), h = we(w), b = le(), _ = O("p"), S = O("span"), R = we(C), H(o, "class", "BalanceModalText"), H(S, "class", "BalanceModalAmount"), H(_, "class", "BalanceModalValue"), H(a, "class", "BalanceModalRowLine");
819
+ },
820
+ m(x, L) {
821
+ ce(x, a, L), E(a, o), E(o, f), E(o, c), E(o, h), E(a, b), E(a, _), E(_, S), E(S, R);
822
+ },
823
+ p(x, L) {
824
+ L[0] & /*$_, balances*/
825
+ 24 && y !== (y = /*$_*/
826
+ x[4](
827
+ /*k*/
828
+ x[51]
829
+ ) + "") && be(f, y), L[0] & /*balances*/
830
+ 8 && w !== (w = /*getProductType*/
831
+ x[7](
832
+ /*balance*/
833
+ x[54]
834
+ ) + "") && be(h, w), L[0] & /*balances*/
835
+ 8 && C !== (C = /*formatBalance*/
836
+ x[5](
837
+ /*balance*/
838
+ x[54].amount
839
+ ) + "") && be(R, C);
840
+ },
841
+ d(x) {
842
+ x && de(a);
843
+ }
844
+ };
845
+ }
846
+ function et(p) {
847
+ let a, o, y = He(
848
+ /*balances*/
849
+ p[3][
850
+ /*k*/
851
+ p[51]
852
+ ]
853
+ ), f = [];
854
+ for (let c = 0; c < y.length; c += 1)
855
+ f[c] = $e(Ze(p, y, c));
856
+ return {
857
+ c() {
858
+ a = O("div");
859
+ for (let c = 0; c < f.length; c += 1)
860
+ f[c].c();
861
+ o = le(), H(a, "class", "BalanceModalRowBoth");
862
+ },
863
+ m(c, w) {
864
+ ce(c, a, w);
865
+ for (let h = 0; h < f.length; h += 1)
866
+ f[h] && f[h].m(a, null);
867
+ E(a, o);
868
+ },
869
+ p(c, w) {
870
+ if (w[0] & /*formatBalance, balances, getProductType, $_*/
871
+ 184) {
872
+ y = He(
873
+ /*balances*/
874
+ c[3][
875
+ /*k*/
876
+ c[51]
877
+ ]
878
+ );
879
+ let h;
880
+ for (h = 0; h < y.length; h += 1) {
881
+ const b = Ze(c, y, h);
882
+ f[h] ? f[h].p(b, w) : (f[h] = $e(b), f[h].c(), f[h].m(a, o));
883
+ }
884
+ for (; h < f.length; h += 1)
885
+ f[h].d(1);
886
+ f.length = y.length;
887
+ }
888
+ },
889
+ d(c) {
890
+ c && de(a), nt(f, c);
891
+ }
892
+ };
893
+ }
894
+ function tt(p) {
895
+ let a, o, y;
896
+ return {
897
+ c() {
898
+ a = O("button"), H(a, "class", "ShowBalanceModalOverlay");
899
+ },
900
+ m(f, c) {
901
+ ce(f, a, c), o || (y = je(
902
+ a,
903
+ "click",
904
+ /*click_handler_3*/
905
+ p[28]
906
+ ), o = !0);
907
+ },
908
+ p: Xe,
909
+ d(f) {
910
+ f && de(a), o = !1, y();
911
+ }
912
+ };
913
+ }
914
+ function xt(p) {
915
+ let a, o, y;
916
+ function f(b, _) {
917
+ return (
918
+ /*isLoading*/
919
+ b[1] ? _t : At
920
+ );
921
+ }
922
+ let c = f(p), w = c(p), h = (
923
+ /*isModalDisplayed*/
924
+ p[2] && tt(p)
925
+ );
926
+ return {
927
+ c() {
928
+ a = O("div"), o = O("div"), w.c(), y = le(), h && h.c(), H(o, "class", "ShowBalance");
929
+ },
930
+ m(b, _) {
931
+ ce(b, a, _), E(a, o), w.m(o, null), E(a, y), h && h.m(a, null), p[29](a);
932
+ },
933
+ p(b, _) {
934
+ c === (c = f(b)) && w ? w.p(b, _) : (w.d(1), w = c(b), w && (w.c(), w.m(o, null))), /*isModalDisplayed*/
935
+ b[2] ? h ? h.p(b, _) : (h = tt(b), h.c(), h.m(a, null)) : h && (h.d(1), h = null);
936
+ },
937
+ i: Xe,
938
+ o: Xe,
939
+ d(b) {
940
+ b && de(a), w.d(), h && h.d(), p[29](null);
941
+ }
942
+ };
943
+ }
944
+ function Rt(p, a, o) {
945
+ let y;
946
+ pt(p, Bt, (e) => o(4, y = e));
947
+ let { userid: f = "" } = a, { session: c = "" } = a, { endpoint: w = "" } = a, { lang: h = "en" } = a, { mbsource: b = "" } = a, { clientstyling: _ = "" } = a, { clientstylingurl: S = "" } = a, { translationurl: C = "" } = a, { gmversion: R = "gm16" } = a, { displaybalanceoption: x = "All" } = a, { totalcalculationmode: L = "totalCashAmount" } = a, { hideproducttype: $ = "" } = a, { currencylocale: ne = "en" } = a, { currencydisplay: ae = "symbol" } = a, { maximumfractiondigits: X = "2" } = a, { minimumfractiondigits: T = "0" } = a, { customdisplayformat: A = "" } = a, F, M, K = !0, ue = !1, fe = !1, Z, oe = "", z = [], pe;
948
+ const d = {}, he = ["totalCashAmount", "totalRealAmount"], Ce = () => {
949
+ fetch(C).then((e) => e.json()).then((e) => Object.keys(e).forEach((n) => We(n, e[n]))).catch((e) => console.log(e));
950
+ };
951
+ Object.keys(Ye).forEach((e) => We(e, Ye[e]));
952
+ const te = (e) => {
953
+ if (A)
954
+ return me(e);
955
+ const n = ne || h, i = {
956
+ style: "currency",
957
+ currency: oe,
958
+ useGrouping: !0,
959
+ currencyDisplay: ae || "code",
960
+ maximumFractionDigits: X === "" || isNaN(Number(X)) ? 2 : Number(X),
961
+ minimumFractionDigits: T === "" || isNaN(Number(T)) ? 0 : Number(T)
962
+ };
963
+ return new Intl.NumberFormat(n, i).format(e);
964
+ }, me = (e) => {
965
+ const n = [];
966
+ let i = "";
967
+ for (const r of A)
968
+ switch (r) {
969
+ default:
970
+ i += r;
971
+ break;
972
+ case "{":
973
+ i && n.push(i), i = "";
974
+ break;
975
+ case "}":
976
+ const [u, v] = i.split("|");
977
+ if (i = "", u.toLowerCase() === "currency")
978
+ i = oe;
979
+ else if (u.toLowerCase() === "amount") {
980
+ let l = ",", g = ".", B = 2;
981
+ v && (v[0] !== " " && (l = v[0]), v[1] !== " " && (g = v[1]), v[2] !== " " && !isNaN(Number(v[2])) && (B = Number(v[2])));
982
+ let [m, D] = String(Math.floor(e * 10 ** B) / 10 ** B).split(".");
983
+ i += m[0];
984
+ for (let U = 1; U < m.length; ++U)
985
+ (m.length - U) % 3 === 0 ? i += l + m[U] : i += m[U];
986
+ D && (i += g + D);
987
+ }
988
+ i && n.push(i), i = "";
989
+ break;
990
+ }
991
+ return n.push(i), n.join("");
992
+ }, ge = async () => {
993
+ o(1, K = !0);
994
+ const e = new URL(`${w}/v1/player/${f}/account`);
995
+ try {
996
+ const n = await fetch(e, {
997
+ method: "GET",
998
+ headers: { "X-SessionID": c }
999
+ }), i = await n.json();
1000
+ if (n.ok)
1001
+ z = i.items, oe = z.find((r) => r.displayName === "Casino")?.currency, o(3, d.Total = [{ amount: i.totalAmount[oe] }], d), o(
1002
+ 3,
1003
+ d.Real = [
1004
+ {
1005
+ amount: z.find((r) => r.displayName === "Casino")?.balanceAmount
1006
+ }
1007
+ ],
1008
+ d
1009
+ ), o(
1010
+ 3,
1011
+ d.Bonus = [
1012
+ {
1013
+ amount: z.find((r) => r.displayName === "UBS")?.balanceAmount
1014
+ }
1015
+ ],
1016
+ d
1017
+ );
1018
+ else
1019
+ throw new Error("Failed to fetch balance data !");
1020
+ } catch (n) {
1021
+ console.log("Balance error: ", n);
1022
+ } finally {
1023
+ o(1, K = !1);
1024
+ }
1025
+ }, Ae = () => {
1026
+ o(1, K = !0);
1027
+ const e = new URL(`${w}/v2/player/${f}/balance`), n = new Headers();
1028
+ n.append("X-SessionID", c), fetch(e, { method: "GET", headers: n }).then((r) => r.json()).then((r) => {
1029
+ r[L] || o(8, L = he[0]);
1030
+ const u = r.items.find((l) => l.type === "Real" && l.walletAccountType === "Ordinary");
1031
+ if (oe = u.currency, fe = !!u.productType, o(3, d.Total = [{ amount: 0 }], d), o(3, d.Real = [], d), o(3, d.Bonus = [], d), o(3, d.Credit = [], d), !fe) {
1032
+ pe = {
1033
+ lastOrdinaryAfterAmount: 0,
1034
+ showCreditLineAfterAmount: !1
1035
+ }, o(3, d.Total[0].amount = r[L][oe], d);
1036
+ for (const l of r.items)
1037
+ switch (l.type) {
1038
+ case "Bonus":
1039
+ d.Bonus.length === 0 ? d.Bonus.push({ amount: l.amount }) : o(3, d.Bonus[0].amount += l.amount, d);
1040
+ break;
1041
+ case "Real":
1042
+ if (l.creditLine && d.Credit.length === 0 && d.Credit.push({ amount: l.creditLine }), L === "totalRealAmount")
1043
+ continue;
1044
+ d.Real.length === 0 ? d.Real.push({ amount: l.amount }) : o(3, d.Real[0].amount += l.amount, d);
1045
+ break;
1046
+ }
1047
+ for (const [l, g] of Object.entries(d))
1048
+ g.length < 1 && delete d[l];
1049
+ o(1, K = !1);
1050
+ return;
1051
+ }
1052
+ pe = {
1053
+ Casino: {
1054
+ lastOrdinaryAfterAmount: 0,
1055
+ showCreditLineAfterAmount: !1
1056
+ },
1057
+ Sports: {
1058
+ lastOrdinaryAfterAmount: 0,
1059
+ showCreditLineAfterAmount: !1
1060
+ }
1061
+ };
1062
+ let v = r.items;
1063
+ x && x !== "All" && (v = r.items.filter((l) => l.productType === x));
1064
+ for (const l of v) {
1065
+ let g;
1066
+ switch (l.type) {
1067
+ case "Bonus":
1068
+ g = d.Bonus.findIndex((B) => B.productType === l.productType), g > 0 ? o(3, d.Bonus[g].amount += l.amount, d) : d.Bonus.push({
1069
+ amount: l.amount,
1070
+ productType: l.productType
1071
+ });
1072
+ break;
1073
+ case "Real":
1074
+ l.creditLine && d.Credit.push({
1075
+ amount: l.creditLine,
1076
+ productType: l.productType
1077
+ }), g = d.Real.findIndex((B) => B.productType === l.productType), g > 0 ? o(3, d.Real[g].amount += l.amount, d) : d.Real.push({
1078
+ amount: l.amount,
1079
+ productType: l.productType
1080
+ });
1081
+ break;
1082
+ }
1083
+ }
1084
+ Me();
1085
+ for (const [l, g] of Object.entries(d))
1086
+ g.length < 1 && delete d[l];
1087
+ window.postMessage({ type: "playerBalanceInfo", balance: r }, window.location.href), o(1, K = !1);
1088
+ }).catch(() => {
1089
+ throw o(1, K = !1), new Error("Failed to fetch balance data !");
1090
+ });
1091
+ }, J = () => {
1092
+ if (Z && Z.close(), c.length < 1)
1093
+ return;
1094
+ let e, n;
1095
+ switch (R) {
1096
+ case "gm16":
1097
+ e = new URL(`${w}/v2/player/${f}/information/updates`), n = (u) => ze(u);
1098
+ break;
1099
+ case "gmcore":
1100
+ e = new URL(`${w}/v1/player/${f}/balance/updates`), n = (u) => Le(u);
1101
+ break;
1102
+ }
1103
+ const i = {
1104
+ accept: "text/event-stream",
1105
+ "X-SessionId": c
1106
+ }, r = new St.EventSourcePolyfill(e, { headers: i });
1107
+ Z = r, r.addEventListener("message", n);
1108
+ }, Be = (e) => {
1109
+ let n;
1110
+ try {
1111
+ n = JSON.parse(e);
1112
+ } catch (i) {
1113
+ console.log("Balance stream failed: ", i);
1114
+ return;
1115
+ }
1116
+ return n;
1117
+ }, Le = (e) => {
1118
+ const n = Be(e.data);
1119
+ if (!n) {
1120
+ J();
1121
+ return;
1122
+ }
1123
+ let i = "0";
1124
+ const r = n.balanceChange;
1125
+ z = z.map((u) => (r && r[u.id] && (u = {
1126
+ ...u,
1127
+ balanceAmount: r[u.id].afterAmount
1128
+ }), i = (parseFloat(u?.balanceAmount) + parseFloat(i)).toString(), u)), o(3, d.Real = [{ amount: z[0]?.balanceAmount }], d), o(3, d.Bonus = [{ amount: z[1]?.balanceAmount }], d), o(3, d.Total = [{ amount: Number(i) }], d);
1129
+ }, _e = (e, n, i) => {
1130
+ let r = null;
1131
+ switch (i.walletAccountType) {
1132
+ case "Ordinary":
1133
+ (i.afterAmount !== i.affectedAmount || n.lastOrdinaryAfterAmount === 0) && (n.lastOrdinaryAfterAmount = i.afterAmount, n.showCreditLineAfterAmount || (r = i.afterAmount));
1134
+ break;
1135
+ case "CreditLine":
1136
+ i.afterAmount !== 0 ? (r = i.afterAmount, n.showCreditLineAfterAmount = !0) : (r = n.lastOrdinaryAfterAmount, n.showCreditLineAfterAmount = !1);
1137
+ break;
1138
+ default:
1139
+ r = i.afterAmount;
1140
+ }
1141
+ return r === null ? e : r;
1142
+ }, Me = () => {
1143
+ switch (L) {
1144
+ case "totalCashAmount":
1145
+ let e = 0;
1146
+ for (const i of ["Real", "Bonus"])
1147
+ for (const r of d[i])
1148
+ e += Math.max(r.amount, 0);
1149
+ o(3, d.Total[0].amount = e, d);
1150
+ break;
1151
+ case "totalRealAmount":
1152
+ if (!fe)
1153
+ return;
1154
+ let n = 0;
1155
+ for (const i of d.Real)
1156
+ n += i.amount;
1157
+ o(3, d.Total[0].amount = n, d);
1158
+ }
1159
+ }, ze = (e) => {
1160
+ const n = Be(e.data);
1161
+ if (!n) {
1162
+ J();
1163
+ return;
1164
+ }
1165
+ if (xe(n?.type) || n.type !== "BALANCE_UPDATE_V2")
1166
+ return;
1167
+ const i = n.body.balanceChange;
1168
+ for (const [r, u] of Object.entries(i))
1169
+ if (L === "totalRealAmount" && r === "Real" && !fe && o(3, d.Total[0].amount = _e(d.Total[0].amount, pe, u), d), !!d[r])
1170
+ for (const v of d[r]) {
1171
+ if (!fe) {
1172
+ v.amount = r === "Real" ? _e(v.amount, pe, u) : u.afterAmount;
1173
+ continue;
1174
+ }
1175
+ u.productType === v.productType && (v.amount = r === "Real" ? _e(v.amount, pe[v.productType], u) : u.afterAmount);
1176
+ }
1177
+ Me();
1178
+ }, Fe = () => {
1179
+ o(2, ue = !1), window.postMessage({ type: "GoToDeposit" }, window.location.href), typeof gtag == "function" && gtag("event", "GoToDeposit", { context: "PlayerAccountBalanceModal" });
1180
+ }, xe = (e) => e === "SESSION_EXPIRATION" ? (window.postMessage({ type: "SessionExpiration" }, window.location.href), !0) : !1, Re = () => {
1181
+ he.includes(L) || (console.error(`Unsupported value ('${L}') for totalcalculationmode parameter. Only the following values are supported ${he}. Using default value ('${he[0]}').`), o(8, L = he[0]));
1182
+ }, ye = (e) => {
1183
+ const n = $.split(",").map((i) => i.trim());
1184
+ return !e.productType || n.includes(e.productType) ? "" : y(e.productType);
1185
+ }, q = () => {
1186
+ switch (Tt(h), Re(), R) {
1187
+ case "gmcore":
1188
+ ge();
1189
+ break;
1190
+ case "gm16":
1191
+ Ae();
1192
+ break;
1193
+ default:
1194
+ throw Error(`Invalid apiversion attribute: ${R}`);
1195
+ }
1196
+ }, ke = (e) => e.data && e.data.type === "LogoutSuccessfull" && Z.close();
1197
+ ht(() => (window.addEventListener("message", ke, !1), () => {
1198
+ window.emMessageBus && M && M.unsubscribe(), window.removeEventListener("message", ke), Z && Z.close();
1199
+ }));
1200
+ const Ue = () => o(2, ue = !0), Pe = () => o(2, ue = !1), Oe = () => Fe(), t = () => o(2, ue = !1);
1201
+ function s(e) {
1202
+ mt[e ? "unshift" : "push"](() => {
1203
+ F = e, o(0, F);
1204
+ });
1205
+ }
1206
+ return p.$$set = (e) => {
1207
+ "userid" in e && o(9, f = e.userid), "session" in e && o(10, c = e.session), "endpoint" in e && o(11, w = e.endpoint), "lang" in e && o(12, h = e.lang), "mbsource" in e && o(13, b = e.mbsource), "clientstyling" in e && o(14, _ = e.clientstyling), "clientstylingurl" in e && o(15, S = e.clientstylingurl), "translationurl" in e && o(16, C = e.translationurl), "gmversion" in e && o(17, R = e.gmversion), "displaybalanceoption" in e && o(18, x = e.displaybalanceoption), "totalcalculationmode" in e && o(8, L = e.totalcalculationmode), "hideproducttype" in e && o(19, $ = e.hideproducttype), "currencylocale" in e && o(20, ne = e.currencylocale), "currencydisplay" in e && o(21, ae = e.currencydisplay), "maximumfractiondigits" in e && o(22, X = e.maximumfractiondigits), "minimumfractiondigits" in e && o(23, T = e.minimumfractiondigits), "customdisplayformat" in e && o(24, A = e.customdisplayformat);
1208
+ }, p.$$.update = () => {
1209
+ p.$$.dirty[0] & /*endpoint, userid, session, lang, gmversion, displaybalanceoption*/
1210
+ 400896 && w && f && c && h && R && x && q(), p.$$.dirty[0] & /*endpoint, userid, session, gmversion*/
1211
+ 134656 && w && f && c && R && J(), p.$$.dirty[0] & /*clientstyling, customStylingContainer*/
1212
+ 16385 && _ && F && yt(F, _), p.$$.dirty[0] & /*clientstylingurl, customStylingContainer*/
1213
+ 32769 && S && F && gt(F, S), p.$$.dirty[0] & /*customStylingContainer, mbsource*/
1214
+ 8193 && F && vt(F, `${b}.Style`), p.$$.dirty[0] & /*translationurl*/
1215
+ 65536 && C && Ce();
1216
+ }, [
1217
+ F,
1218
+ K,
1219
+ ue,
1220
+ d,
1221
+ y,
1222
+ te,
1223
+ Fe,
1224
+ ye,
1225
+ L,
1226
+ f,
1227
+ c,
1228
+ w,
1229
+ h,
1230
+ b,
1231
+ _,
1232
+ S,
1233
+ C,
1234
+ R,
1235
+ x,
1236
+ $,
1237
+ ne,
1238
+ ae,
1239
+ X,
1240
+ T,
1241
+ A,
1242
+ Ue,
1243
+ Pe,
1244
+ Oe,
1245
+ t,
1246
+ s
1247
+ ];
1248
+ }
1249
+ class Et extends lt {
1250
+ constructor(a) {
1251
+ super(), ct(
1252
+ this,
1253
+ a,
1254
+ Rt,
1255
+ xt,
1256
+ ut,
1257
+ {
1258
+ userid: 9,
1259
+ session: 10,
1260
+ endpoint: 11,
1261
+ lang: 12,
1262
+ mbsource: 13,
1263
+ clientstyling: 14,
1264
+ clientstylingurl: 15,
1265
+ translationurl: 16,
1266
+ gmversion: 17,
1267
+ displaybalanceoption: 18,
1268
+ totalcalculationmode: 8,
1269
+ hideproducttype: 19,
1270
+ currencylocale: 20,
1271
+ currencydisplay: 21,
1272
+ maximumfractiondigits: 22,
1273
+ minimumfractiondigits: 23,
1274
+ customdisplayformat: 24
1275
+ },
1276
+ Ct,
1277
+ [-1, -1]
1278
+ );
1279
+ }
1280
+ get userid() {
1281
+ return this.$$.ctx[9];
1282
+ }
1283
+ set userid(a) {
1284
+ this.$$set({ userid: a }), j();
1285
+ }
1286
+ get session() {
1287
+ return this.$$.ctx[10];
1288
+ }
1289
+ set session(a) {
1290
+ this.$$set({ session: a }), j();
1291
+ }
1292
+ get endpoint() {
1293
+ return this.$$.ctx[11];
1294
+ }
1295
+ set endpoint(a) {
1296
+ this.$$set({ endpoint: a }), j();
1297
+ }
1298
+ get lang() {
1299
+ return this.$$.ctx[12];
1300
+ }
1301
+ set lang(a) {
1302
+ this.$$set({ lang: a }), j();
1303
+ }
1304
+ get mbsource() {
1305
+ return this.$$.ctx[13];
1306
+ }
1307
+ set mbsource(a) {
1308
+ this.$$set({ mbsource: a }), j();
1309
+ }
1310
+ get clientstyling() {
1311
+ return this.$$.ctx[14];
1312
+ }
1313
+ set clientstyling(a) {
1314
+ this.$$set({ clientstyling: a }), j();
1315
+ }
1316
+ get clientstylingurl() {
1317
+ return this.$$.ctx[15];
1318
+ }
1319
+ set clientstylingurl(a) {
1320
+ this.$$set({ clientstylingurl: a }), j();
1321
+ }
1322
+ get translationurl() {
1323
+ return this.$$.ctx[16];
1324
+ }
1325
+ set translationurl(a) {
1326
+ this.$$set({ translationurl: a }), j();
1327
+ }
1328
+ get gmversion() {
1329
+ return this.$$.ctx[17];
1330
+ }
1331
+ set gmversion(a) {
1332
+ this.$$set({ gmversion: a }), j();
1333
+ }
1334
+ get displaybalanceoption() {
1335
+ return this.$$.ctx[18];
1336
+ }
1337
+ set displaybalanceoption(a) {
1338
+ this.$$set({ displaybalanceoption: a }), j();
1339
+ }
1340
+ get totalcalculationmode() {
1341
+ return this.$$.ctx[8];
1342
+ }
1343
+ set totalcalculationmode(a) {
1344
+ this.$$set({ totalcalculationmode: a }), j();
1345
+ }
1346
+ get hideproducttype() {
1347
+ return this.$$.ctx[19];
1348
+ }
1349
+ set hideproducttype(a) {
1350
+ this.$$set({ hideproducttype: a }), j();
1351
+ }
1352
+ get currencylocale() {
1353
+ return this.$$.ctx[20];
1354
+ }
1355
+ set currencylocale(a) {
1356
+ this.$$set({ currencylocale: a }), j();
1357
+ }
1358
+ get currencydisplay() {
1359
+ return this.$$.ctx[21];
1360
+ }
1361
+ set currencydisplay(a) {
1362
+ this.$$set({ currencydisplay: a }), j();
1363
+ }
1364
+ get maximumfractiondigits() {
1365
+ return this.$$.ctx[22];
1366
+ }
1367
+ set maximumfractiondigits(a) {
1368
+ this.$$set({ maximumfractiondigits: a }), j();
1369
+ }
1370
+ get minimumfractiondigits() {
1371
+ return this.$$.ctx[23];
1372
+ }
1373
+ set minimumfractiondigits(a) {
1374
+ this.$$set({ minimumfractiondigits: a }), j();
1375
+ }
1376
+ get customdisplayformat() {
1377
+ return this.$$.ctx[24];
1378
+ }
1379
+ set customdisplayformat(a) {
1380
+ this.$$set({ customdisplayformat: a }), j();
1381
+ }
1382
+ }
1383
+ dt(Et, { userid: {}, session: {}, endpoint: {}, lang: {}, mbsource: {}, clientstyling: {}, clientstylingurl: {}, translationurl: {}, gmversion: {}, displaybalanceoption: {}, totalcalculationmode: {}, hideproducttype: {}, currencylocale: {}, currencydisplay: {}, maximumfractiondigits: {}, minimumfractiondigits: {}, customdisplayformat: {} }, [], [], !0);
1384
+ export {
1385
+ Et as default
1386
+ };