@everymatrix/casino-header-controller 1.71.1 → 1.72.0

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