@everymatrix/casino-tournaments-controller 1.0.69 → 1.0.71

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.
@@ -0,0 +1,549 @@
1
+ import { a as X, S as Y, i as x, f as z, c as $, s as ee, b as le, e as E, d as u, g as _, h as k, n as L, j as T, k as te, l as I, t as S, m as N, o as F, p as B, q as ne, r as ie, u as se, v as P, $ as oe } from "./CasinoTournamentsController-o9ci4V-7.js";
2
+ function U(e, l) {
3
+ X(e, l);
4
+ }
5
+ const H = {
6
+ en: {
7
+ tournamentsFilter: {
8
+ tournaments: "Tournaments",
9
+ all: "All",
10
+ scheduled: "Scheduled",
11
+ ongoing: "Ongoing",
12
+ finished: "Finished"
13
+ }
14
+ },
15
+ hr: {
16
+ tournamentsFilter: {
17
+ tournaments: "Turniri",
18
+ all: "Svi",
19
+ scheduled: "Planirani",
20
+ ongoing: "U tijeku",
21
+ finished: "Završeni"
22
+ }
23
+ },
24
+ "zh-hk": {
25
+ tournamentsFilter: {
26
+ tournaments: "錦標賽",
27
+ all: "全部",
28
+ scheduled: "預定的",
29
+ ongoing: "進行中",
30
+ finished: "完成的"
31
+ }
32
+ },
33
+ fr: {
34
+ tournamentsFilter: {
35
+ tournaments: "Tournois",
36
+ all: "Tous",
37
+ scheduled: "Programmé",
38
+ ongoing: "En cours",
39
+ finished: "Fini"
40
+ }
41
+ },
42
+ ro: {
43
+ tournamentsFilter: {
44
+ tournaments: "Turnee",
45
+ all: "Toate",
46
+ scheduled: "Programate",
47
+ ongoing: "În curs",
48
+ finished: "Finalizat"
49
+ }
50
+ },
51
+ tr: {
52
+ tournamentsFilter: {
53
+ tournaments: "Turnuvalar",
54
+ all: "Hepsi",
55
+ scheduled: "Planlanmış",
56
+ ongoing: "Devam ediyor",
57
+ finished: "Tamamlanmış"
58
+ }
59
+ },
60
+ el: {
61
+ tournamentsFilter: {
62
+ tournaments: "Τουρνουά",
63
+ all: "Όλα",
64
+ scheduled: "Προγραμματισμένα",
65
+ ongoing: "Τρέχοντα",
66
+ finished: "Ολοκληρωμένα"
67
+ }
68
+ },
69
+ es: {
70
+ tournamentsFilter: {
71
+ tournaments: "Torneos",
72
+ all: "Todos",
73
+ scheduled: "Programado",
74
+ ongoing: "En vivo",
75
+ finished: "Finalizado"
76
+ }
77
+ },
78
+ hu: {
79
+ tournamentsFilter: {
80
+ tournaments: "Versenyek",
81
+ all: "Mind",
82
+ scheduled: "Ütemezés",
83
+ ongoing: "Folyamatban",
84
+ finished: "Befejezett"
85
+ }
86
+ },
87
+ pt: {
88
+ tournamentsFilter: {
89
+ tournaments: "Torneios",
90
+ all: "Tudo",
91
+ scheduled: "Agendado",
92
+ ongoing: "Em progresso",
93
+ finished: "Finalizado"
94
+ }
95
+ }
96
+ };
97
+ function re(e) {
98
+ le(e, "svelte-1ne2lwv", ".svelte-1ne2lwv.svelte-1ne2lwv,.svelte-1ne2lwv.svelte-1ne2lwv::before,.svelte-1ne2lwv.svelte-1ne2lwv::after{margin:0;padding:0;list-style:none;text-decoration:none;outline:none;box-sizing:border-box}ul.svelte-1ne2lwv.svelte-1ne2lwv{display:flex;gap:10px;overflow-x:auto}ul.MobileClass.svelte-1ne2lwv.svelte-1ne2lwv{padding-top:21px}li.svelte-1ne2lwv.svelte-1ne2lwv:first-child{height:100%;position:realtive;padding:1em 0;margin:0;font-size:14px;text-align:center;letter-spacing:0px;color:var(--emfe-w-color-white, #FFFFFF);opacity:1}li.MobileClass.svelte-1ne2lwv.svelte-1ne2lwv{position:absolute;left:10px;top:-15px;font-size:14px;height:auto}button.svelte-1ne2lwv.svelte-1ne2lwv{display:flex;align-items:center;background-color:transparent;justify-content:center;padding:10px;height:40px;border:1px solid var(--emfe-w-color-white, #FFFFFF);min-width:40px;text-align:center;color:var(--emfe-w-color-white, #FFFFFF)}button.MobileClass.svelte-1ne2lwv.svelte-1ne2lwv{height:30px}button.svelte-1ne2lwv.svelte-1ne2lwv:hover{background-color:var(--emfe-w-color-gray-100, #E6E6E6);border:1px solid var(--emfe-w-color-gray-100, #E6E6E6);color:var(--emfe-w-color-black, #000000);cursor:pointer}.FiltersController.svelte-1ne2lwv.svelte-1ne2lwv{color:var(--emfe-w-color-white, #FFFFFF);display:flex;justify-content:flex-end;margin-bottom:20px}.FiltersController.MobileClass.svelte-1ne2lwv.svelte-1ne2lwv{justify-content:flex-start;margin-bottom:10px}.FiltersController.svelte-1ne2lwv .FilterButton.svelte-1ne2lwv{font-size:14px;letter-spacing:0px;opacity:1;text-transform:uppercase}.FiltersController.svelte-1ne2lwv .FilterButton.MobileClass.svelte-1ne2lwv{font-size:10px}.FiltersController.svelte-1ne2lwv .Active.svelte-1ne2lwv{background-color:var(--emfe-w-color-gray-300, #58586B);border:1px solid var(--emfe-w-color-gray-300, #58586B)}.FiltersController.svelte-1ne2lwv .Active.svelte-1ne2lwv:hover{background-color:var(--emfe-w-color-gray-300, #58586B);border:1px solid var(--emfe-w-color-gray-300, #58586B)}");
99
+ }
100
+ function R(e, l, t) {
101
+ const n = e.slice();
102
+ return n[22] = l[t], n[24] = t, n;
103
+ }
104
+ function q(e) {
105
+ let l, t, n = (
106
+ /*$_*/
107
+ e[4]("tournamentsFilter.tournaments") + ""
108
+ ), i, y, C, w = I(
109
+ /*filterItems*/
110
+ e[1]
111
+ ), r = [];
112
+ for (let s = 0; s < w.length; s += 1)
113
+ r[s] = K(R(e, w, s));
114
+ return {
115
+ c() {
116
+ l = E("ul"), t = E("li"), i = S(n), y = S(":"), C = N();
117
+ for (let s = 0; s < r.length; s += 1)
118
+ r[s].c();
119
+ u(t, "class", "FiltersTitle " + (_(
120
+ /*userAgent*/
121
+ e[5]
122
+ ) ? "MobileClass" : "Non-MobileClass/empty") + " svelte-1ne2lwv"), u(t, "part", "FiltersTitle " + (_(
123
+ /*userAgent*/
124
+ e[5]
125
+ ) ? "MobileClass" : "Non-MobileClass/empty")), u(l, "class", "FiltersList " + (_(
126
+ /*userAgent*/
127
+ e[5]
128
+ ) ? "MobileClass" : "Non-MobileClass/empty") + " svelte-1ne2lwv"), u(l, "part", "FiltersList " + (_(
129
+ /*userAgent*/
130
+ e[5]
131
+ ) ? "MobileClass" : "Non-MobileClass/empty"));
132
+ },
133
+ m(s, p) {
134
+ k(s, l, p), F(l, t), F(t, i), F(t, y), F(l, C);
135
+ for (let a = 0; a < r.length; a += 1)
136
+ r[a] && r[a].m(l, null);
137
+ },
138
+ p(s, p) {
139
+ if (p & /*$_*/
140
+ 16 && n !== (n = /*$_*/
141
+ s[4]("tournamentsFilter.tournaments") + "") && B(i, n), p & /*makeButtonActive, filterItems, activeIndexes, allActive, userAgent, $_*/
142
+ 126) {
143
+ w = I(
144
+ /*filterItems*/
145
+ s[1]
146
+ );
147
+ let a;
148
+ for (a = 0; a < w.length; a += 1) {
149
+ const c = R(s, w, a);
150
+ r[a] ? r[a].p(c, p) : (r[a] = K(c), r[a].c(), r[a].m(l, null));
151
+ }
152
+ for (; a < r.length; a += 1)
153
+ r[a].d(1);
154
+ r.length = w.length;
155
+ }
156
+ },
157
+ d(s) {
158
+ s && T(l), ne(r, s);
159
+ }
160
+ };
161
+ }
162
+ function D(e) {
163
+ let l, t;
164
+ return {
165
+ c() {
166
+ l = P("svg"), t = P("path"), u(t, "d", "M10.97 4.97a.75.75 0 0 1 1.07 1.05l-3.99 4.99a.75.75 0 0 1-1.08.02L4.324 8.384a.75.75 0 1 1 1.06-1.06l2.094 2.093 3.473-4.425a.267.267 0 0 1 .02-.022z"), u(t, "class", "svelte-1ne2lwv"), u(l, "xmlns", "http://www.w3.org/2000/svg"), u(l, "width", "16"), u(l, "height", "16"), u(l, "fill", "currentColor"), u(l, "class", "bi bi-check svelte-1ne2lwv"), u(l, "part", "bi bi-check"), u(l, "viewBox", "0 0 16 16");
167
+ },
168
+ m(n, i) {
169
+ k(n, l, i), F(l, t);
170
+ },
171
+ d(n) {
172
+ n && T(l);
173
+ }
174
+ };
175
+ }
176
+ function V(e) {
177
+ let l = (
178
+ /*$_*/
179
+ e[4]("tournamentsFilter.scheduled") + ""
180
+ ), t;
181
+ return {
182
+ c() {
183
+ t = S(l);
184
+ },
185
+ m(n, i) {
186
+ k(n, t, i);
187
+ },
188
+ p(n, i) {
189
+ i & /*$_*/
190
+ 16 && l !== (l = /*$_*/
191
+ n[4]("tournamentsFilter.scheduled") + "") && B(t, l);
192
+ },
193
+ d(n) {
194
+ n && T(t);
195
+ }
196
+ };
197
+ }
198
+ function Z(e) {
199
+ let l = (
200
+ /*$_*/
201
+ e[4]("tournamentsFilter.ongoing") + ""
202
+ ), t;
203
+ return {
204
+ c() {
205
+ t = S(l);
206
+ },
207
+ m(n, i) {
208
+ k(n, t, i);
209
+ },
210
+ p(n, i) {
211
+ i & /*$_*/
212
+ 16 && l !== (l = /*$_*/
213
+ n[4]("tournamentsFilter.ongoing") + "") && B(t, l);
214
+ },
215
+ d(n) {
216
+ n && T(t);
217
+ }
218
+ };
219
+ }
220
+ function G(e) {
221
+ let l = (
222
+ /*$_*/
223
+ e[4]("tournamentsFilter.finished") + ""
224
+ ), t;
225
+ return {
226
+ c() {
227
+ t = S(l);
228
+ },
229
+ m(n, i) {
230
+ k(n, t, i);
231
+ },
232
+ p(n, i) {
233
+ i & /*$_*/
234
+ 16 && l !== (l = /*$_*/
235
+ n[4]("tournamentsFilter.finished") + "") && B(t, l);
236
+ },
237
+ d(n) {
238
+ n && T(t);
239
+ }
240
+ };
241
+ }
242
+ function J(e) {
243
+ let l = (
244
+ /*$_*/
245
+ e[4]("tournamentsFilter.all") + ""
246
+ ), t;
247
+ return {
248
+ c() {
249
+ t = S(l);
250
+ },
251
+ m(n, i) {
252
+ k(n, t, i);
253
+ },
254
+ p(n, i) {
255
+ i & /*$_*/
256
+ 16 && l !== (l = /*$_*/
257
+ n[4]("tournamentsFilter.all") + "") && B(t, l);
258
+ },
259
+ d(n) {
260
+ n && T(t);
261
+ }
262
+ };
263
+ }
264
+ function K(e) {
265
+ let l, t, n, i, y, C, w, r, s, p, a, c, f = (
266
+ /*activeIndexes*/
267
+ (e[2][
268
+ /*index*/
269
+ e[24]
270
+ ] == 1 || /*allActive*/
271
+ e[3] && /*index*/
272
+ e[24] == 0) && D()
273
+ ), v = (
274
+ /*filter*/
275
+ e[22] == "Scheduled" && V(e)
276
+ ), g = (
277
+ /*filter*/
278
+ e[22] == "Ongoing" && Z(e)
279
+ ), m = (
280
+ /*filter*/
281
+ e[22] == "Finished" && G(e)
282
+ ), h = (
283
+ /*filter*/
284
+ e[22] == "All" && J(e)
285
+ );
286
+ function j() {
287
+ return (
288
+ /*click_handler*/
289
+ e[12](
290
+ /*filter*/
291
+ e[22],
292
+ /*index*/
293
+ e[24]
294
+ )
295
+ );
296
+ }
297
+ return {
298
+ c() {
299
+ l = E("li"), t = E("button"), f && f.c(), n = N(), i = E("div"), v && v.c(), y = N(), g && g.c(), C = N(), m && m.c(), w = N(), h && h.c(), p = N(), u(i, "class", "FilterButton " + (_(
300
+ /*userAgent*/
301
+ e[5]
302
+ ) ? "MobileClass" : "Non-MobileClass/empty") + " svelte-1ne2lwv"), u(i, "part", "FilterButton " + (_(
303
+ /*userAgent*/
304
+ e[5]
305
+ ) ? "MobileClass" : "Non-MobileClass/empty")), u(t, "class", r = /*activeIndexes*/
306
+ (e[2][
307
+ /*index*/
308
+ e[24]
309
+ ] == 1 || /*allActive*/
310
+ e[3] && /*index*/
311
+ e[24] == 0 ? "Active" : "") + " " + (_(
312
+ /*userAgent*/
313
+ e[5]
314
+ ) ? "MobileClass" : "Non-MobileClass/empty") + " svelte-1ne2lwv"), u(t, "part", s = /*activeIndexes*/
315
+ (e[2][
316
+ /*index*/
317
+ e[24]
318
+ ] == 1 || /*allActive*/
319
+ e[3] && /*index*/
320
+ e[24] == 0 ? "Active" : "") + " " + (_(
321
+ /*userAgent*/
322
+ e[5]
323
+ ) ? "MobileClass" : "Non-MobileClass/empty")), u(l, "class", "FiltersItem svelte-1ne2lwv"), u(l, "part", "FiltersItem");
324
+ },
325
+ m(A, M) {
326
+ k(A, l, M), F(l, t), f && f.m(t, null), F(t, n), F(t, i), v && v.m(i, null), F(i, y), g && g.m(i, null), F(i, C), m && m.m(i, null), F(i, w), h && h.m(i, null), F(l, p), a || (c = ie(l, "click", j), a = !0);
327
+ },
328
+ p(A, M) {
329
+ e = A, /*activeIndexes*/
330
+ e[2][
331
+ /*index*/
332
+ e[24]
333
+ ] == 1 || /*allActive*/
334
+ e[3] && /*index*/
335
+ e[24] == 0 ? f || (f = D(), f.c(), f.m(t, n)) : f && (f.d(1), f = null), /*filter*/
336
+ e[22] == "Scheduled" ? v ? v.p(e, M) : (v = V(e), v.c(), v.m(i, y)) : v && (v.d(1), v = null), /*filter*/
337
+ e[22] == "Ongoing" ? g ? g.p(e, M) : (g = Z(e), g.c(), g.m(i, C)) : g && (g.d(1), g = null), /*filter*/
338
+ e[22] == "Finished" ? m ? m.p(e, M) : (m = G(e), m.c(), m.m(i, w)) : m && (m.d(1), m = null), /*filter*/
339
+ e[22] == "All" ? h ? h.p(e, M) : (h = J(e), h.c(), h.m(i, null)) : h && (h.d(1), h = null), M & /*activeIndexes, allActive*/
340
+ 12 && r !== (r = /*activeIndexes*/
341
+ (e[2][
342
+ /*index*/
343
+ e[24]
344
+ ] == 1 || /*allActive*/
345
+ e[3] && /*index*/
346
+ e[24] == 0 ? "Active" : "") + " " + (_(
347
+ /*userAgent*/
348
+ e[5]
349
+ ) ? "MobileClass" : "Non-MobileClass/empty") + " svelte-1ne2lwv") && u(t, "class", r), M & /*activeIndexes, allActive*/
350
+ 12 && s !== (s = /*activeIndexes*/
351
+ (e[2][
352
+ /*index*/
353
+ e[24]
354
+ ] == 1 || /*allActive*/
355
+ e[3] && /*index*/
356
+ e[24] == 0 ? "Active" : "") + " " + (_(
357
+ /*userAgent*/
358
+ e[5]
359
+ ) ? "MobileClass" : "Non-MobileClass/empty")) && u(t, "part", s);
360
+ },
361
+ d(A) {
362
+ A && T(l), f && f.d(), v && v.d(), g && g.d(), m && m.d(), h && h.d(), a = !1, c();
363
+ }
364
+ };
365
+ }
366
+ function ae(e) {
367
+ let l, t = (
368
+ /*filterItems*/
369
+ e[1].length > 0 && q(e)
370
+ );
371
+ return {
372
+ c() {
373
+ l = E("div"), t && t.c(), u(l, "class", "FiltersController " + (_(
374
+ /*userAgent*/
375
+ e[5]
376
+ ) ? "MobileClass" : "Non-MobileClass/empty") + " svelte-1ne2lwv"), u(l, "part", "FiltersController " + (_(
377
+ /*userAgent*/
378
+ e[5]
379
+ ) ? "MobileClass" : "Non-MobileClass/empty"));
380
+ },
381
+ m(n, i) {
382
+ k(n, l, i), t && t.m(l, null), e[13](l);
383
+ },
384
+ p(n, [i]) {
385
+ /*filterItems*/
386
+ n[1].length > 0 ? t ? t.p(n, i) : (t = q(n), t.c(), t.m(l, null)) : t && (t.d(1), t = null);
387
+ },
388
+ i: L,
389
+ o: L,
390
+ d(n) {
391
+ n && T(l), t && t.d(), e[13](null);
392
+ }
393
+ };
394
+ }
395
+ function ue(e, l, t) {
396
+ let n;
397
+ te(e, oe, (o) => t(4, n = o));
398
+ let { filters: i = "" } = l, { activefilters: y = "" } = l, { translationurl: C = "" } = l, { clientstyling: w = "" } = l, { clientstylingurl: r = "" } = l, s, p = [], a = 0, c = new Array(100), f = !0, v = window.navigator.userAgent;
399
+ const g = () => {
400
+ fetch(C).then((d) => d.json()).then((d) => {
401
+ Object.keys(d).forEach((b) => {
402
+ U(b, d[b]);
403
+ });
404
+ }).catch((d) => {
405
+ console.log(d);
406
+ });
407
+ };
408
+ Object.keys(H).forEach((o) => {
409
+ U(o, H[o]);
410
+ });
411
+ const m = (o, d) => {
412
+ if (d == 0)
413
+ t(3, f = !0), t(2, c = new Array(a)), window.postMessage(
414
+ {
415
+ type: "TournamentsFiltersSelected",
416
+ filters: ["All"]
417
+ },
418
+ window.location.href
419
+ );
420
+ else if (t(3, f = !1), c[d] == 1 ? (t(2, c[d] = 0, c), c.indexOf(1) == -1 && t(3, f = !0)) : t(2, c[d] = 1, c), c.indexOf(1) == -1)
421
+ window.postMessage(
422
+ {
423
+ type: "TournamentsFiltersSelected",
424
+ filters: ["All"]
425
+ },
426
+ window.location.href
427
+ );
428
+ else {
429
+ let b = [];
430
+ for (let O = 0; O < p.length; O++)
431
+ c[O] == 1 && b.push(p[O]);
432
+ window.postMessage(
433
+ {
434
+ type: "TournamentsFiltersSelected",
435
+ filters: b
436
+ },
437
+ window.location.href
438
+ );
439
+ }
440
+ }, h = () => {
441
+ t(1, p = i.split(",")), a = p.length;
442
+ }, j = () => {
443
+ let o = y.split(",");
444
+ t(2, c = new Array(a)), o.indexOf("All") != -1 ? t(3, f = !0) : (t(3, f = !1), o.forEach((d) => {
445
+ let b = p.indexOf(d);
446
+ b > 0 && t(2, c[b] = 1, c);
447
+ }));
448
+ }, A = () => {
449
+ let o = document.createElement("style");
450
+ o.innerHTML = w, s.appendChild(o);
451
+ }, M = () => {
452
+ let o = new URL(r), d = document.createElement("style");
453
+ fetch(o.href).then((b) => b.text()).then((b) => {
454
+ d.innerHTML = b, setTimeout(
455
+ () => {
456
+ s.appendChild(d);
457
+ },
458
+ 1
459
+ ), setTimeout(
460
+ () => {
461
+ },
462
+ 500
463
+ );
464
+ });
465
+ }, Q = (o, d) => m(o, d);
466
+ function W(o) {
467
+ se[o ? "unshift" : "push"](() => {
468
+ s = o, t(0, s);
469
+ });
470
+ }
471
+ return e.$$set = (o) => {
472
+ "filters" in o && t(7, i = o.filters), "activefilters" in o && t(8, y = o.activefilters), "translationurl" in o && t(9, C = o.translationurl), "clientstyling" in o && t(10, w = o.clientstyling), "clientstylingurl" in o && t(11, r = o.clientstylingurl);
473
+ }, e.$$.update = () => {
474
+ e.$$.dirty & /*customStylingContainer, clientstyling*/
475
+ 1025 && s && w && A(), e.$$.dirty & /*customStylingContainer, clientstylingurl*/
476
+ 2049 && s && r && M(), e.$$.dirty & /*translationurl*/
477
+ 512 && C && g(), e.$$.dirty & /*filters*/
478
+ 128 && i && h(), e.$$.dirty & /*activefilters*/
479
+ 256 && y && j();
480
+ }, [
481
+ s,
482
+ p,
483
+ c,
484
+ f,
485
+ n,
486
+ v,
487
+ m,
488
+ i,
489
+ y,
490
+ C,
491
+ w,
492
+ r,
493
+ Q,
494
+ W
495
+ ];
496
+ }
497
+ class fe extends Y {
498
+ constructor(l) {
499
+ super(), x(
500
+ this,
501
+ l,
502
+ ue,
503
+ ae,
504
+ ee,
505
+ {
506
+ filters: 7,
507
+ activefilters: 8,
508
+ translationurl: 9,
509
+ clientstyling: 10,
510
+ clientstylingurl: 11
511
+ },
512
+ re
513
+ );
514
+ }
515
+ get filters() {
516
+ return this.$$.ctx[7];
517
+ }
518
+ set filters(l) {
519
+ this.$$set({ filters: l }), z();
520
+ }
521
+ get activefilters() {
522
+ return this.$$.ctx[8];
523
+ }
524
+ set activefilters(l) {
525
+ this.$$set({ activefilters: l }), z();
526
+ }
527
+ get translationurl() {
528
+ return this.$$.ctx[9];
529
+ }
530
+ set translationurl(l) {
531
+ this.$$set({ translationurl: l }), z();
532
+ }
533
+ get clientstyling() {
534
+ return this.$$.ctx[10];
535
+ }
536
+ set clientstyling(l) {
537
+ this.$$set({ clientstyling: l }), z();
538
+ }
539
+ get clientstylingurl() {
540
+ return this.$$.ctx[11];
541
+ }
542
+ set clientstylingurl(l) {
543
+ this.$$set({ clientstylingurl: l }), z();
544
+ }
545
+ }
546
+ $(fe, { filters: {}, activefilters: {}, translationurl: {}, clientstyling: {}, clientstylingurl: {} }, [], [], !0);
547
+ export {
548
+ fe as default
549
+ };
@@ -0,0 +1 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./CasinoTournamentsController-DZ0LEvCR.cjs");function T(t,l){e.addMessages(t,l)}const A={en:{tournamentsFilter:{tournaments:"Tournaments",all:"All",scheduled:"Scheduled",ongoing:"Ongoing",finished:"Finished"}},hr:{tournamentsFilter:{tournaments:"Turniri",all:"Svi",scheduled:"Planirani",ongoing:"U tijeku",finished:"Završeni"}},"zh-hk":{tournamentsFilter:{tournaments:"錦標賽",all:"全部",scheduled:"預定的",ongoing:"進行中",finished:"完成的"}},fr:{tournamentsFilter:{tournaments:"Tournois",all:"Tous",scheduled:"Programmé",ongoing:"En cours",finished:"Fini"}},ro:{tournamentsFilter:{tournaments:"Turnee",all:"Toate",scheduled:"Programate",ongoing:"În curs",finished:"Finalizat"}},tr:{tournamentsFilter:{tournaments:"Turnuvalar",all:"Hepsi",scheduled:"Planlanmış",ongoing:"Devam ediyor",finished:"Tamamlanmış"}},el:{tournamentsFilter:{tournaments:"Τουρνουά",all:"Όλα",scheduled:"Προγραμματισμένα",ongoing:"Τρέχοντα",finished:"Ολοκληρωμένα"}},es:{tournamentsFilter:{tournaments:"Torneos",all:"Todos",scheduled:"Programado",ongoing:"En vivo",finished:"Finalizado"}},hu:{tournamentsFilter:{tournaments:"Versenyek",all:"Mind",scheduled:"Ütemezés",ongoing:"Folyamatban",finished:"Befejezett"}},pt:{tournamentsFilter:{tournaments:"Torneios",all:"Tudo",scheduled:"Agendado",ongoing:"Em progresso",finished:"Finalizado"}}};function H(t){e.append_styles(t,"svelte-1ne2lwv",".svelte-1ne2lwv.svelte-1ne2lwv,.svelte-1ne2lwv.svelte-1ne2lwv::before,.svelte-1ne2lwv.svelte-1ne2lwv::after{margin:0;padding:0;list-style:none;text-decoration:none;outline:none;box-sizing:border-box}ul.svelte-1ne2lwv.svelte-1ne2lwv{display:flex;gap:10px;overflow-x:auto}ul.MobileClass.svelte-1ne2lwv.svelte-1ne2lwv{padding-top:21px}li.svelte-1ne2lwv.svelte-1ne2lwv:first-child{height:100%;position:realtive;padding:1em 0;margin:0;font-size:14px;text-align:center;letter-spacing:0px;color:var(--emfe-w-color-white, #FFFFFF);opacity:1}li.MobileClass.svelte-1ne2lwv.svelte-1ne2lwv{position:absolute;left:10px;top:-15px;font-size:14px;height:auto}button.svelte-1ne2lwv.svelte-1ne2lwv{display:flex;align-items:center;background-color:transparent;justify-content:center;padding:10px;height:40px;border:1px solid var(--emfe-w-color-white, #FFFFFF);min-width:40px;text-align:center;color:var(--emfe-w-color-white, #FFFFFF)}button.MobileClass.svelte-1ne2lwv.svelte-1ne2lwv{height:30px}button.svelte-1ne2lwv.svelte-1ne2lwv:hover{background-color:var(--emfe-w-color-gray-100, #E6E6E6);border:1px solid var(--emfe-w-color-gray-100, #E6E6E6);color:var(--emfe-w-color-black, #000000);cursor:pointer}.FiltersController.svelte-1ne2lwv.svelte-1ne2lwv{color:var(--emfe-w-color-white, #FFFFFF);display:flex;justify-content:flex-end;margin-bottom:20px}.FiltersController.MobileClass.svelte-1ne2lwv.svelte-1ne2lwv{justify-content:flex-start;margin-bottom:10px}.FiltersController.svelte-1ne2lwv .FilterButton.svelte-1ne2lwv{font-size:14px;letter-spacing:0px;opacity:1;text-transform:uppercase}.FiltersController.svelte-1ne2lwv .FilterButton.MobileClass.svelte-1ne2lwv{font-size:10px}.FiltersController.svelte-1ne2lwv .Active.svelte-1ne2lwv{background-color:var(--emfe-w-color-gray-300, #58586B);border:1px solid var(--emfe-w-color-gray-300, #58586B)}.FiltersController.svelte-1ne2lwv .Active.svelte-1ne2lwv:hover{background-color:var(--emfe-w-color-gray-300, #58586B);border:1px solid var(--emfe-w-color-gray-300, #58586B)}")}function N(t,l,n){const i=t.slice();return i[22]=l[n],i[24]=n,i}function S(t){let l,n,i=t[4]("tournamentsFilter.tournaments")+"",s,F,_,p=e.ensure_array_like(t[1]),a=[];for(let r=0;r<p.length;r+=1)a[r]=L(N(t,p,r));return{c(){l=e.element("ul"),n=e.element("li"),s=e.text(i),F=e.text(":"),_=e.space();for(let r=0;r<a.length;r+=1)a[r].c();e.attr(n,"class","FiltersTitle "+(e.isMobile(t[5])?"MobileClass":"Non-MobileClass/empty")+" svelte-1ne2lwv"),e.attr(n,"part","FiltersTitle "+(e.isMobile(t[5])?"MobileClass":"Non-MobileClass/empty")),e.attr(l,"class","FiltersList "+(e.isMobile(t[5])?"MobileClass":"Non-MobileClass/empty")+" svelte-1ne2lwv"),e.attr(l,"part","FiltersList "+(e.isMobile(t[5])?"MobileClass":"Non-MobileClass/empty"))},m(r,b){e.insert(r,l,b),e.append(l,n),e.append(n,s),e.append(n,F),e.append(l,_);for(let u=0;u<a.length;u+=1)a[u]&&a[u].m(l,null)},p(r,b){if(b&16&&i!==(i=r[4]("tournamentsFilter.tournaments")+"")&&e.set_data(s,i),b&126){p=e.ensure_array_like(r[1]);let u;for(u=0;u<p.length;u+=1){const c=N(r,p,u);a[u]?a[u].p(c,b):(a[u]=L(c),a[u].c(),a[u].m(l,null))}for(;u<a.length;u+=1)a[u].d(1);a.length=p.length}},d(r){r&&e.detach(l),e.destroy_each(a,r)}}}function E(t){let l,n;return{c(){l=e.svg_element("svg"),n=e.svg_element("path"),e.attr(n,"d","M10.97 4.97a.75.75 0 0 1 1.07 1.05l-3.99 4.99a.75.75 0 0 1-1.08.02L4.324 8.384a.75.75 0 1 1 1.06-1.06l2.094 2.093 3.473-4.425a.267.267 0 0 1 .02-.022z"),e.attr(n,"class","svelte-1ne2lwv"),e.attr(l,"xmlns","http://www.w3.org/2000/svg"),e.attr(l,"width","16"),e.attr(l,"height","16"),e.attr(l,"fill","currentColor"),e.attr(l,"class","bi bi-check svelte-1ne2lwv"),e.attr(l,"part","bi bi-check"),e.attr(l,"viewBox","0 0 16 16")},m(i,s){e.insert(i,l,s),e.append(l,n)},d(i){i&&e.detach(l)}}}function z(t){let l=t[4]("tournamentsFilter.scheduled")+"",n;return{c(){n=e.text(l)},m(i,s){e.insert(i,n,s)},p(i,s){s&16&&l!==(l=i[4]("tournamentsFilter.scheduled")+"")&&e.set_data(n,l)},d(i){i&&e.detach(n)}}}function B(t){let l=t[4]("tournamentsFilter.ongoing")+"",n;return{c(){n=e.text(l)},m(i,s){e.insert(i,n,s)},p(i,s){s&16&&l!==(l=i[4]("tournamentsFilter.ongoing")+"")&&e.set_data(n,l)},d(i){i&&e.detach(n)}}}function O(t){let l=t[4]("tournamentsFilter.finished")+"",n;return{c(){n=e.text(l)},m(i,s){e.insert(i,n,s)},p(i,s){s&16&&l!==(l=i[4]("tournamentsFilter.finished")+"")&&e.set_data(n,l)},d(i){i&&e.detach(n)}}}function j(t){let l=t[4]("tournamentsFilter.all")+"",n;return{c(){n=e.text(l)},m(i,s){e.insert(i,n,s)},p(i,s){s&16&&l!==(l=i[4]("tournamentsFilter.all")+"")&&e.set_data(n,l)},d(i){i&&e.detach(n)}}}function L(t){let l,n,i,s,F,_,p,a,r,b,u,c,f=(t[2][t[24]]==1||t[3]&&t[24]==0)&&E(),v=t[22]=="Scheduled"&&z(t),h=t[22]=="Ongoing"&&B(t),m=t[22]=="Finished"&&O(t),g=t[22]=="All"&&j(t);function k(){return t[12](t[22],t[24])}return{c(){l=e.element("li"),n=e.element("button"),f&&f.c(),i=e.space(),s=e.element("div"),v&&v.c(),F=e.space(),h&&h.c(),_=e.space(),m&&m.c(),p=e.space(),g&&g.c(),b=e.space(),e.attr(s,"class","FilterButton "+(e.isMobile(t[5])?"MobileClass":"Non-MobileClass/empty")+" svelte-1ne2lwv"),e.attr(s,"part","FilterButton "+(e.isMobile(t[5])?"MobileClass":"Non-MobileClass/empty")),e.attr(n,"class",a=(t[2][t[24]]==1||t[3]&&t[24]==0?"Active":"")+" "+(e.isMobile(t[5])?"MobileClass":"Non-MobileClass/empty")+" svelte-1ne2lwv"),e.attr(n,"part",r=(t[2][t[24]]==1||t[3]&&t[24]==0?"Active":"")+" "+(e.isMobile(t[5])?"MobileClass":"Non-MobileClass/empty")),e.attr(l,"class","FiltersItem svelte-1ne2lwv"),e.attr(l,"part","FiltersItem")},m(M,y){e.insert(M,l,y),e.append(l,n),f&&f.m(n,null),e.append(n,i),e.append(n,s),v&&v.m(s,null),e.append(s,F),h&&h.m(s,null),e.append(s,_),m&&m.m(s,null),e.append(s,p),g&&g.m(s,null),e.append(l,b),u||(c=e.listen(l,"click",k),u=!0)},p(M,y){t=M,t[2][t[24]]==1||t[3]&&t[24]==0?f||(f=E(),f.c(),f.m(n,i)):f&&(f.d(1),f=null),t[22]=="Scheduled"?v?v.p(t,y):(v=z(t),v.c(),v.m(s,F)):v&&(v.d(1),v=null),t[22]=="Ongoing"?h?h.p(t,y):(h=B(t),h.c(),h.m(s,_)):h&&(h.d(1),h=null),t[22]=="Finished"?m?m.p(t,y):(m=O(t),m.c(),m.m(s,p)):m&&(m.d(1),m=null),t[22]=="All"?g?g.p(t,y):(g=j(t),g.c(),g.m(s,null)):g&&(g.d(1),g=null),y&12&&a!==(a=(t[2][t[24]]==1||t[3]&&t[24]==0?"Active":"")+" "+(e.isMobile(t[5])?"MobileClass":"Non-MobileClass/empty")+" svelte-1ne2lwv")&&e.attr(n,"class",a),y&12&&r!==(r=(t[2][t[24]]==1||t[3]&&t[24]==0?"Active":"")+" "+(e.isMobile(t[5])?"MobileClass":"Non-MobileClass/empty"))&&e.attr(n,"part",r)},d(M){M&&e.detach(l),f&&f.d(),v&&v.d(),h&&h.d(),m&&m.d(),g&&g.d(),u=!1,c()}}}function R(t){let l,n=t[1].length>0&&S(t);return{c(){l=e.element("div"),n&&n.c(),e.attr(l,"class","FiltersController "+(e.isMobile(t[5])?"MobileClass":"Non-MobileClass/empty")+" svelte-1ne2lwv"),e.attr(l,"part","FiltersController "+(e.isMobile(t[5])?"MobileClass":"Non-MobileClass/empty"))},m(i,s){e.insert(i,l,s),n&&n.m(l,null),t[13](l)},p(i,[s]){i[1].length>0?n?n.p(i,s):(n=S(i),n.c(),n.m(l,null)):n&&(n.d(1),n=null)},i:e.noop,o:e.noop,d(i){i&&e.detach(l),n&&n.d(),t[13](null)}}}function q(t,l,n){let i;e.component_subscribe(t,e.$format,o=>n(4,i=o));let{filters:s=""}=l,{activefilters:F=""}=l,{translationurl:_=""}=l,{clientstyling:p=""}=l,{clientstylingurl:a=""}=l,r,b=[],u=0,c=new Array(100),f=!0,v=window.navigator.userAgent;const h=()=>{fetch(_).then(d=>d.json()).then(d=>{Object.keys(d).forEach(w=>{T(w,d[w])})}).catch(d=>{console.log(d)})};Object.keys(A).forEach(o=>{T(o,A[o])});const m=(o,d)=>{if(d==0)n(3,f=!0),n(2,c=new Array(u)),window.postMessage({type:"TournamentsFiltersSelected",filters:["All"]},window.location.href);else if(n(3,f=!1),c[d]==1?(n(2,c[d]=0,c),c.indexOf(1)==-1&&n(3,f=!0)):n(2,c[d]=1,c),c.indexOf(1)==-1)window.postMessage({type:"TournamentsFiltersSelected",filters:["All"]},window.location.href);else{let w=[];for(let C=0;C<b.length;C++)c[C]==1&&w.push(b[C]);window.postMessage({type:"TournamentsFiltersSelected",filters:w},window.location.href)}},g=()=>{n(1,b=s.split(",")),u=b.length},k=()=>{let o=F.split(",");n(2,c=new Array(u)),o.indexOf("All")!=-1?n(3,f=!0):(n(3,f=!1),o.forEach(d=>{let w=b.indexOf(d);w>0&&n(2,c[w]=1,c)}))},M=()=>{let o=document.createElement("style");o.innerHTML=p,r.appendChild(o)},y=()=>{let o=new URL(a),d=document.createElement("style");fetch(o.href).then(w=>w.text()).then(w=>{d.innerHTML=w,setTimeout(()=>{r.appendChild(d)},1),setTimeout(()=>{},500)})},I=(o,d)=>m(o,d);function U(o){e.binding_callbacks[o?"unshift":"push"](()=>{r=o,n(0,r)})}return t.$$set=o=>{"filters"in o&&n(7,s=o.filters),"activefilters"in o&&n(8,F=o.activefilters),"translationurl"in o&&n(9,_=o.translationurl),"clientstyling"in o&&n(10,p=o.clientstyling),"clientstylingurl"in o&&n(11,a=o.clientstylingurl)},t.$$.update=()=>{t.$$.dirty&1025&&r&&p&&M(),t.$$.dirty&2049&&r&&a&&y(),t.$$.dirty&512&&_&&h(),t.$$.dirty&128&&s&&g(),t.$$.dirty&256&&F&&k()},[r,b,c,f,i,v,m,s,F,_,p,a,I,U]}class P extends e.SvelteComponent{constructor(l){super(),e.init(this,l,q,R,e.safe_not_equal,{filters:7,activefilters:8,translationurl:9,clientstyling:10,clientstylingurl:11},H)}get filters(){return this.$$.ctx[7]}set filters(l){this.$$set({filters:l}),e.flush()}get activefilters(){return this.$$.ctx[8]}set activefilters(l){this.$$set({activefilters:l}),e.flush()}get translationurl(){return this.$$.ctx[9]}set translationurl(l){this.$$set({translationurl:l}),e.flush()}get clientstyling(){return this.$$.ctx[10]}set clientstyling(l){this.$$set({clientstyling:l}),e.flush()}get clientstylingurl(){return this.$$.ctx[11]}set clientstylingurl(l){this.$$set({clientstylingurl:l}),e.flush()}}e.create_custom_element(P,{filters:{},activefilters:{},translationurl:{},clientstyling:{},clientstylingurl:{}},[],[],!0);exports.default=P;