@everymatrix/tournament-details-page 0.2.2 → 0.2.4

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 (102) hide show
  1. package/components/{ChartIcon-BOJYO_mg.cjs → ChartIcon-Befgjhbq.cjs} +1 -1
  2. package/components/{ChartIcon-BnuWrPCu.js → ChartIcon-Cijyoj4D.js} +1 -1
  3. package/components/{ChartIcon-RZGJve9X.cjs → ChartIcon-DHA4OiwS.cjs} +1 -1
  4. package/components/{ChartIcon-DpI8g8MS.js → ChartIcon-R4lVwti5.js} +1 -1
  5. package/components/{CoinStackIcon-DFr0r7ql.cjs → CoinStackIcon-BJ5Cza44.cjs} +1 -1
  6. package/components/{CoinStackIcon-JPra1r-T.js → CoinStackIcon-C1F7M7aX.js} +1 -1
  7. package/components/{CoinStackIcon-D7VDNLPL.js → CoinStackIcon-D3SYgfiW.js} +1 -1
  8. package/components/{CoinStackIcon-D9m5o_fi.cjs → CoinStackIcon-DaTufppr.cjs} +1 -1
  9. package/components/{DocumentsIcon-CbpU2Gyn.js → DocumentsIcon-B8czAvSb.js} +1 -1
  10. package/components/{DocumentsIcon-BMHGy7l5.cjs → DocumentsIcon-C-xeVT_v.cjs} +1 -1
  11. package/components/{DocumentsIcon-DFbkU_nq.js → DocumentsIcon-DNlyMYIU.js} +1 -1
  12. package/components/{DocumentsIcon-BGDIx1Br.cjs → DocumentsIcon-SuePRQNo.cjs} +1 -1
  13. package/components/{FootballIcon-Ba3k9QwJ.cjs → FootballIcon-B8X-AjbG.cjs} +1 -1
  14. package/components/{FootballIcon-Dh004HAn.cjs → FootballIcon-C4eNGKY4.cjs} +1 -1
  15. package/components/{FootballIcon-t-RiDqHO.js → FootballIcon-DVZ96gIt.js} +1 -1
  16. package/components/{FootballIcon-BXfYxMAS.js → FootballIcon-u7l6pKui.js} +1 -1
  17. package/components/{PeopleIcon-Bi5uKQ9t.cjs → PeopleIcon-BflWZAxo.cjs} +1 -1
  18. package/components/{PeopleIcon-2b-6fziq.js → PeopleIcon-DLW94oOG.js} +1 -1
  19. package/components/{PeopleIcon-Dij57H9Y.cjs → PeopleIcon-DciAxL_a.cjs} +1 -1
  20. package/components/{PeopleIcon-BL0lywpf.js → PeopleIcon-s7Ccyi1V.js} +1 -1
  21. package/components/{RankArrowIcon-DxqeIh-2.js → RankArrowIcon-97fk5fg5.js} +1 -1
  22. package/components/{RankArrowIcon-BLPI8Ihl.js → RankArrowIcon-FXyB2gGq.js} +1 -1
  23. package/components/{RankArrowIcon-D9MUkVQC.cjs → RankArrowIcon-SoYkNu_W.cjs} +1 -1
  24. package/components/{RankArrowIcon-C1FqD2OV.cjs → RankArrowIcon-hrpZ9ET-.cjs} +1 -1
  25. package/components/{SlotMachineIcon-rm59GZar.js → SlotMachineIcon-BNa44gB0.js} +1 -1
  26. package/components/{SlotMachineIcon-_w58r-b5.cjs → SlotMachineIcon-CaTi0xrT.cjs} +1 -1
  27. package/components/{SlotMachineIcon-DbLnS5Dy.js → SlotMachineIcon-CpTV5Gjw.js} +1 -1
  28. package/components/{SlotMachineIcon-Cuv-0tTj.cjs → SlotMachineIcon-DyoJSpjm.cjs} +1 -1
  29. package/components/{StatusBadge-94g1_G1j.js → StatusBadge-1cAE-BMW.js} +1801 -1768
  30. package/components/StatusBadge-CMV-2nkA.cjs +11 -0
  31. package/components/StatusBadge-DYQwo1l2.cjs +11 -0
  32. package/components/{StatusBadge-DuF7NK69.js → StatusBadge-Dz7gL5NT.js} +1415 -1382
  33. package/components/TournamentActions-B4XIKdGS.js +110 -0
  34. package/components/TournamentActions-CIe9g5tR.js +108 -0
  35. package/components/TournamentActions-D0kIKeFb.cjs +18 -0
  36. package/components/TournamentActions-DHAVf_xi.cjs +18 -0
  37. package/components/{TournamentDetailsPage-DKQGDSr1.cjs → TournamentDetailsPage-5vGjPG32.cjs} +4 -4
  38. package/components/{TournamentDetailsPage-BknZ3XLG.js → TournamentDetailsPage-CQdLNEwc.js} +291 -207
  39. package/components/TournamentDetailsPage-CdsWSXuQ.cjs +27 -0
  40. package/components/{TournamentDetailsPage-AkoBgtU-.js → TournamentDetailsPage-DdXVtbXN.js} +342 -258
  41. package/components/{TournamentDetailsSkeleton-BTCHrmxN.cjs → TournamentDetailsSkeleton-Ck8yL46X.cjs} +3 -3
  42. package/components/{TournamentDetailsSkeleton-D0L8P1tb.js → TournamentDetailsSkeleton-DA318hry.js} +19 -19
  43. package/components/{TournamentDetailsSkeleton-Dtd2H__T.cjs → TournamentDetailsSkeleton-DYzVvOUN.cjs} +3 -3
  44. package/components/{TournamentDetailsSkeleton-CmKNNW5d.js → TournamentDetailsSkeleton-DthtZKyT.js} +19 -19
  45. package/components/TournamentGames-CM0_tj8g.cjs +19 -0
  46. package/components/TournamentGames-D4b31JLG.cjs +19 -0
  47. package/components/TournamentGames-VQKGwemr.js +325 -0
  48. package/components/TournamentGames-n4c8SvY_.js +303 -0
  49. package/components/{TournamentImage-BFh29Z7_.js → TournamentImage-87bhDEnk.js} +61 -51
  50. package/components/{TournamentImage-Hm-i2BLZ.js → TournamentImage-D0na0-p6.js} +59 -49
  51. package/components/{TournamentImage-D26UWHyP.cjs → TournamentImage-D6eLaW4m.cjs} +2 -2
  52. package/components/{TournamentImage-CxfcEUy6.cjs → TournamentImage-DK1HgudW.cjs} +2 -2
  53. package/components/TournamentLeaderboard-C3iblI14.cjs +44 -0
  54. package/components/TournamentLeaderboard-Cc-xMiwP.js +1500 -0
  55. package/components/TournamentLeaderboard-DvvnA47t.js +1561 -0
  56. package/components/TournamentLeaderboard-NEJ1wTBv.cjs +44 -0
  57. package/components/TournamentRules-CyqSU5RQ.js +147 -0
  58. package/components/TournamentRules-D9R2cmXK.js +152 -0
  59. package/components/TournamentRules-DDlD1tXH.cjs +6 -0
  60. package/components/TournamentRules-OGoN3OYX.cjs +6 -0
  61. package/components/TournamentSummary-BY9YlM53.cjs +3 -0
  62. package/components/TournamentSummary-CewShnfd.js +150 -0
  63. package/components/TournamentSummary-D_DLGxO7.js +145 -0
  64. package/components/TournamentSummary-Dy6cHmly.cjs +3 -0
  65. package/components/{TournamentTabs-BVEr7PbQ.cjs → TournamentTabs-3OdZuIOf.cjs} +1 -1
  66. package/components/{TournamentTabs-ryceiGS3.cjs → TournamentTabs-BDsQomg2.cjs} +1 -1
  67. package/components/{TournamentTabs-B5Hc7DnJ.js → TournamentTabs-mlb4UDEZ.js} +18 -18
  68. package/components/{TournamentTabs-DHZPrDgf.js → TournamentTabs-yOsQleAI.js} +14 -14
  69. package/components/{TrophyIcon-DddCZpjC.cjs → TrophyIcon-CUdep5Qu.cjs} +1 -1
  70. package/components/{TrophyIcon-DJyC3k-2.js → TrophyIcon-D6xEdEIW.js} +4 -4
  71. package/components/{TrophyIcon-eLIudkPn.cjs → TrophyIcon-DJDEDfa7.cjs} +1 -1
  72. package/components/{TrophyIcon-DbEHhyTe.js → TrophyIcon-rK1Ad8lv.js} +4 -4
  73. package/components/translations-B2zzqYUc.cjs +1 -0
  74. package/components/{translations-DPzojb4V.js → translations-BPv4iAvC.js} +42 -7
  75. package/components/{translations-BQS5XycD.js → translations-BY4crXAR.js} +42 -7
  76. package/components/translations-CmWDttoq.cjs +1 -0
  77. package/es2015/tournament-details-page.cjs +1 -1
  78. package/es2015/tournament-details-page.js +2 -2
  79. package/esnext/tournament-details-page.cjs +1 -1
  80. package/esnext/tournament-details-page.js +2 -2
  81. package/package.json +1 -1
  82. package/components/StatusBadge-Bdc22cMY.cjs +0 -8
  83. package/components/StatusBadge-BsjzjNer.cjs +0 -8
  84. package/components/TournamentDetailsPage-DbL7sBZM.cjs +0 -27
  85. package/components/TournamentGames-BGr8V4Dd.js +0 -306
  86. package/components/TournamentGames-BhXlS-fA.js +0 -284
  87. package/components/TournamentGames-Ch4ODv3u.cjs +0 -19
  88. package/components/TournamentGames-D8h0gDfK.cjs +0 -19
  89. package/components/TournamentLeaderboard-1i-FoUCN.cjs +0 -38
  90. package/components/TournamentLeaderboard-B6IMbAZ_.cjs +0 -38
  91. package/components/TournamentLeaderboard-BJ0mlW5c.js +0 -1384
  92. package/components/TournamentLeaderboard-BM3HZ0jQ.js +0 -1441
  93. package/components/TournamentRules-Bu4jfxhb.cjs +0 -6
  94. package/components/TournamentRules-DwcmzDOu.js +0 -138
  95. package/components/TournamentRules-Dxup5GZ2.js +0 -143
  96. package/components/TournamentRules-iglqjP1P.cjs +0 -6
  97. package/components/TournamentSummary-B7I6gN81.js +0 -145
  98. package/components/TournamentSummary-C24QhbUw.cjs +0 -3
  99. package/components/TournamentSummary-HgOjtkW2.cjs +0 -3
  100. package/components/TournamentSummary-ozfHjUkk.js +0 -150
  101. package/components/translations-BSe2qToO.cjs +0 -1
  102. package/components/translations-FufS-X5l.cjs +0 -1
@@ -1,306 +0,0 @@
1
- var ve = (_, o, i) => new Promise((O, q) => {
2
- var S = (g) => {
3
- try {
4
- h(i.next(g));
5
- } catch (b) {
6
- q(b);
7
- }
8
- }, N = (g) => {
9
- try {
10
- h(i.throw(g));
11
- } catch (b) {
12
- q(b);
13
- }
14
- }, h = (g) => g.done ? O(g.value) : Promise.resolve(g.value).then(S, N);
15
- h((i = i.apply(_, o)).next());
16
- });
17
- import { B as He, c as De, g as Fe, a as Je, p as d, C as qe, D as _e, E as Ke, K as Qe, F as Ue, q as P, G as ne, i as H, R as Ve, b as m, d as We, f as v, v as c, J as Ze, h as D, j as t, s as C, r as z, o as F, N as k, t as L, k as xe, l as J, O as M, T as re, V as be, P as oe, L as ie, M as le, m as I, U as Xe, $ as Ye, H as $e, W as et, Q as tt } from "./StatusBadge-94g1_G1j.js";
18
- import { s as at, G as fe, f as st, a as nt } from "./TournamentLeaderboard-BM3HZ0jQ.js";
19
- import { a as rt } from "./translations-DPzojb4V.js";
20
- typeof globalThis.HTMLElement == "undefined" && (globalThis.HTMLElement = class {
21
- }, globalThis.customElements = { define() {
22
- }, get() {
23
- }, whenDefined() {
24
- } });
25
- const ot = (_, o = !1) => {
26
- if (!_)
27
- return;
28
- const i = parseFloat(getComputedStyle(_).scrollMarginTop) || 0;
29
- if (o && _.getBoundingClientRect().top >= i)
30
- return;
31
- const O = window.matchMedia("(prefers-reduced-motion: reduce)").matches;
32
- _.scrollIntoView({ behavior: O ? "auto" : "smooth", block: "start" });
33
- };
34
- var it = v('<div class="tournament-games__tabs svelte-49hxa3" role="tablist"><button type="button" role="tab"> </button> <button type="button" role="tab"> </button></div>'), ye = v('<p class="tournament-games__empty svelte-49hxa3"> </p>'), lt = v('<span class="tournament-games__badge svelte-49hxa3"> </span>'), mt = v('<button type="button" class="tournament-games__game svelte-49hxa3"><img class="tournament-games__image svelte-49hxa3" loading="lazy"/> <span class="tournament-games__play svelte-49hxa3" aria-hidden="true"><span class="tournament-games__play-button svelte-49hxa3"> </span></span> <!></button>'), ut = v('<span class="tournament-games__game tournament-games__game--placeholder svelte-49hxa3" aria-hidden="true"></span>'), gt = v('<div class="tournament-games__sentinel svelte-49hxa3"></div>'), dt = v('<div class="tournament-games__grid svelte-49hxa3"><!> <!></div> <!>', 1), ct = v('<li class="svelte-49hxa3"> </li>'), ht = v('<ul class="tournament-games__events svelte-49hxa3"></ul>'), pt = v('<div class="tournament-games svelte-49hxa3"><!> <!></div>');
35
- const vt = {
36
- hash: "svelte-49hxa3",
37
- code: `.tournament-games.svelte-49hxa3 {scroll-margin-top:80px;display:flex;flex-direction:column;gap:20px;color:var(--text-subtle, rgba(223, 227, 232, 1));.tournament-games__tabs:where(.svelte-49hxa3) {display:flex;border-bottom:1px solid var(--border-default, rgba(251, 251, 251, 0.15));width:max-content;max-width:100%;}.tournament-games__tab:where(.svelte-49hxa3) {position:relative;flex:0 0 auto;height:31px;padding:0 10px;border:0;background:transparent;color:var(--text-subtle, rgba(223, 227, 232, 1));font:inherit;font-size:14px;font-weight:500;cursor:pointer;line-height:145%;min-width:206px;&.active {color:var(--text-brand, rgba(255, 204, 0, 1));font-weight:700;&::after {content:'';position:absolute;left:0;right:0;bottom:-1px;height:2px;background:var(--pagination-bg-selected, rgba(255, 204, 0, 1));}}}.tournament-games__grid:where(.svelte-49hxa3) {display:grid;grid-template-columns:repeat(6, minmax(0, 1fr));gap:8px;}.tournament-games__game:where(.svelte-49hxa3) {position:relative;display:block;width:100%;align-self:start;padding:0;overflow:hidden;border:0;border-radius:6px;background:transparent;line-height:0;cursor:pointer;&:focus-visible {outline:2px solid var(--border-brand, rgba(255, 204, 0, 1));outline-offset:2px;}&:focus-visible .tournament-games__play:where(.svelte-49hxa3) {opacity:1;}
38
-
39
- @media (hover: hover) {&:hover .tournament-games__play:where(.svelte-49hxa3) {opacity:1;}
40
- }}.tournament-games__play:where(.svelte-49hxa3) {position:absolute;inset:0;z-index:2;display:flex;justify-content:center;align-items:center;border-radius:6px;background:rgba(0, 0, 0, 0.6);line-height:1;opacity:0;transition:opacity 0.2s ease;}.tournament-games__play-button:where(.svelte-49hxa3) {display:flex;justify-content:center;align-items:center;min-width:50%;padding:8px 16px;border-radius:6px;background:var(--button-primary-bg-default, #ffcc00);color:var(--button-primary-text-default, rgba(38, 29, 0, 1));font-size:13px;font-weight:600;}.tournament-games__game--placeholder:where(.svelte-49hxa3) {height:120px;background:var(--bg-overlay-neutral-level-1, rgba(251, 251, 251, 0.05));cursor:default;
41
- animation: svelte-49hxa3-tournament-games-pulse 1.2s ease-in-out infinite;}.tournament-games__image:where(.svelte-49hxa3) {display:block;width:100%;height:120px;object-fit:cover;border-radius:6px;}.tournament-games__badge:where(.svelte-49hxa3) {position:absolute;top:10px;left:9.6px;z-index:1;display:flex;justify-content:center;align-items:center;padding:4px 6px;background:var(--bg-overlay-secondary-level-5, rgba(0, 40, 81, 0.35));border:1px solid var(--primary-400, rgba(255, 204, 0, 1));backdrop-filter:blur(10px);box-shadow:0 2px 6px rgba(0, 0, 0, 0.25);border-radius:12px;color:var(--primary-400, rgba(255, 225, 107, 1));font-size:8px;line-height:8px;}.tournament-games__sentinel:where(.svelte-49hxa3) {height:1px;margin-top:-16px;}.tournament-games__events:where(.svelte-49hxa3) {display:flex;flex-direction:column;gap:24px;margin:0;padding:0;font-size:12px;line-height:1.4;list-style:none;font-weight:400;color:var(--text-subtle, rgba(223, 227, 232, 1));}.tournament-games__empty:where(.svelte-49hxa3) {margin:0;padding:32px 0;text-align:center;}}
42
-
43
- @keyframes svelte-49hxa3-tournament-games-pulse {
44
- 50% {
45
- opacity: 0.5;
46
- }
47
- }
48
-
49
- @media (max-width: 767px) {.tournament-games.svelte-49hxa3 {.tournament-games__tabs:where(.svelte-49hxa3) {width:100%;}.tournament-games__tab:where(.svelte-49hxa3) {flex:1;min-width:0;font-size:12px;font-weight:400;}.tournament-games__grid:where(.svelte-49hxa3) {grid-template-columns:repeat(3, minmax(0, 1fr));}.tournament-games__image:where(.svelte-49hxa3),
50
- .tournament-games__game--placeholder:where(.svelte-49hxa3) {height:75px;}.tournament-games__badge:where(.svelte-49hxa3) {top:5px;left:4.67px;}}
51
- }
52
-
53
- @media (prefers-reduced-motion: reduce) {.tournament-games.svelte-49hxa3 .tournament-games__game--placeholder:where(.svelte-49hxa3) {
54
- animation: none;}.tournament-games.svelte-49hxa3 .tournament-games__play:where(.svelte-49hxa3) {transition:none;}
55
- }`
56
- };
57
- function _t(_, o) {
58
- var ce, he;
59
- Fe(o, !0), Je(_, vt);
60
- const i = () => Xe(Ye, "$_", O), [O, q] = Ze(), S = d(o, "initialGames", 7), N = d(o, "endpoint", 7), h = d(o, "language", 7, "en"), g = d(o, "session", 7), b = d(o, "tournamentid", 7), V = d(o, "totalGames", 7), W = d(o, "platform", 7), Z = d(o, "tournamentMetadata", 7), K = d(o, "translationurl", 7), R = d(o, "hasCasino", 7, !0), j = d(o, "hasSports", 7, !1);
61
- qe(rt), _e(h());
62
- const we = () => {
63
- _e(h());
64
- };
65
- Ke(() => {
66
- K() && Qe(K());
67
- }), Ue(() => {
68
- we();
69
- });
70
- let f = P(ne(S() || [])), Q = P(ne((he = V()) != null ? he : ((ce = S()) == null ? void 0 : ce.length) || 0)), X = P(!1), G = P(ne(R() || !j() ? "casino" : "sports")), Y = P(null);
71
- const me = (e) => {
72
- e !== t(G) && (I(G, e, !0), $e().then(() => ot(t(Y), !0)));
73
- }, ue = F(() => R() && j()), Ge = F(() => t(ue) ? t(G) === "casino" : !j() || R()), $ = F(() => t(f).length < t(Q)), Te = F(() => Math.min(Math.max(t(Q) - t(f).length, 0), fe)), ge = F(() => {
74
- var a, s;
75
- const e = (s = (a = Z()) == null ? void 0 : a.sports) == null ? void 0 : s.rules;
76
- if (!e)
77
- return [];
78
- try {
79
- const n = JSON.parse(e);
80
- return n[h()] || n["*"] || [];
81
- } catch (n) {
82
- return console.log(n), [];
83
- }
84
- }), ke = () => ve(this, null, function* () {
85
- var e, a, s, n;
86
- if (!(!t($) || t(X))) {
87
- I(X, !0);
88
- try {
89
- const r = yield st({
90
- endpoint: N(),
91
- language: h(),
92
- platform: W(),
93
- session: g(),
94
- tournamentid: b(),
95
- filterById: !0,
96
- gamesLimit: fe,
97
- gamesOffset: t(f).length
98
- });
99
- I(f, [...t(f), ...(a = (e = r == null ? void 0 : r.games) == null ? void 0 : e.items) != null ? a : []], !0), I(Q, (n = (s = r == null ? void 0 : r.games) == null ? void 0 : s.total) != null ? n : t(Q), !0);
100
- } catch (r) {
101
- console.log(r);
102
- } finally {
103
- I(X, !1);
104
- }
105
- }
106
- }), ee = (e, a) => {
107
- const s = new IntersectionObserver(
108
- (n) => {
109
- n.some((r) => r.isIntersecting) && a();
110
- },
111
- { rootMargin: nt }
112
- );
113
- return s.observe(e), {
114
- destroy() {
115
- s.disconnect();
116
- }
117
- };
118
- }, Me = (e) => {
119
- at(e, b());
120
- };
121
- var Se = {
122
- get initialGames() {
123
- return S();
124
- },
125
- set initialGames(e) {
126
- S(e), c();
127
- },
128
- get endpoint() {
129
- return N();
130
- },
131
- set endpoint(e) {
132
- N(e), c();
133
- },
134
- get language() {
135
- return h();
136
- },
137
- set language(e = "en") {
138
- h(e), c();
139
- },
140
- get session() {
141
- return g();
142
- },
143
- set session(e) {
144
- g(e), c();
145
- },
146
- get tournamentid() {
147
- return b();
148
- },
149
- set tournamentid(e) {
150
- b(e), c();
151
- },
152
- get totalGames() {
153
- return V();
154
- },
155
- set totalGames(e) {
156
- V(e), c();
157
- },
158
- get platform() {
159
- return W();
160
- },
161
- set platform(e) {
162
- W(e), c();
163
- },
164
- get tournamentMetadata() {
165
- return Z();
166
- },
167
- set tournamentMetadata(e) {
168
- Z(e), c();
169
- },
170
- get translationurl() {
171
- return K();
172
- },
173
- set translationurl(e) {
174
- K(e), c();
175
- },
176
- get hasCasino() {
177
- return R();
178
- },
179
- set hasCasino(e = !0) {
180
- R(e), c();
181
- },
182
- get hasSports() {
183
- return j();
184
- },
185
- set hasSports(e = !1) {
186
- j(e), c();
187
- }
188
- }, U = pt(), de = D(U);
189
- {
190
- var Ae = (e) => {
191
- var a = it(), s = D(a);
192
- let n;
193
- var r = k(s, !0), l = C(s, 2);
194
- let u;
195
- var p = k(l, !0);
196
- z(a), L(
197
- (A, te) => {
198
- n = xe(s, 1, "tournament-games__tab svelte-49hxa3", null, n, { active: t(G) === "casino" }), J(s, "aria-selected", t(G) === "casino"), M(r, A), u = xe(l, 1, "tournament-games__tab svelte-49hxa3", null, u, { active: t(G) === "sports" }), J(l, "aria-selected", t(G) === "sports"), M(p, te);
199
- },
200
- [() => i()("casinoTab"), () => i()("sportsTab")]
201
- ), re("click", s, () => me("casino")), re("click", l, () => me("sports")), m(e, a);
202
- };
203
- H(de, (e) => {
204
- t(ue) && e(Ae);
205
- });
206
- }
207
- var Ee = C(de, 2);
208
- {
209
- var Ce = (e) => {
210
- var a = be(), s = oe(a);
211
- {
212
- var n = (l) => {
213
- var u = ye(), p = k(u, !0);
214
- L((A) => M(p, A), [() => i()("noAvailableGames")]), m(l, u);
215
- }, r = (l) => {
216
- var u = dt(), p = oe(u), A = D(p);
217
- ie(A, 17, () => t(f), le, (T, x) => {
218
- var y = mt(), E = D(y), w = C(E, 2), ae = D(w), se = k(ae, !0);
219
- z(w);
220
- var Re = C(w, 2);
221
- {
222
- var je = (B) => {
223
- var pe = lt(), Be = k(pe, !0);
224
- L((Pe) => M(Be, Pe), [() => i()("newBadge")]), m(B, pe);
225
- };
226
- H(Re, (B) => {
227
- t(x).isNew && B(je);
228
- });
229
- }
230
- z(y), L(
231
- (B) => {
232
- J(y, "title", t(x).name), J(E, "src", `https:${t(x).thumbnail}`), J(E, "alt", t(x).name), M(se, B);
233
- },
234
- [() => i()("play")]
235
- ), re("click", y, () => Me(t(x))), m(T, y);
236
- });
237
- var te = C(A, 2);
238
- ie(te, 17, () => Array(t(Te)), le, (T, x, y, E) => {
239
- var w = ut();
240
- m(T, w);
241
- }), z(p);
242
- var Oe = C(p, 2);
243
- {
244
- var Ne = (T) => {
245
- var x = be(), y = oe(x);
246
- et(y, () => t(f).length, (E) => {
247
- var w = gt();
248
- tt(w, (ae, se) => ee == null ? void 0 : ee(ae, se), () => ke), m(E, w);
249
- }), m(T, x);
250
- };
251
- H(Oe, (T) => {
252
- t($) && T(Ne);
253
- });
254
- }
255
- m(l, u);
256
- };
257
- H(s, (l) => {
258
- t(f).length === 0 && !t($) ? l(n) : l(r, -1);
259
- });
260
- }
261
- m(e, a);
262
- }, ze = (e) => {
263
- var a = ye(), s = k(a, !0);
264
- L((n) => M(s, n), [() => i()("noAvailableEvents")]), m(e, a);
265
- }, Le = (e) => {
266
- var a = ht();
267
- ie(a, 21, () => t(ge), le, (s, n) => {
268
- var r = ct(), l = k(r);
269
- L((u) => {
270
- var p;
271
- return M(l, `${(p = t(n).rule) != null ? p : ""} ${u != null ? u : ""}`);
272
- }, [() => i()("contribution")]), m(s, r);
273
- }), z(a), m(e, a);
274
- };
275
- H(Ee, (e) => {
276
- t(Ge) ? e(Ce) : t(ge).length === 0 ? e(ze, 1) : e(Le, -1);
277
- });
278
- }
279
- z(U), Ve(U, (e) => I(Y, e), () => t(Y)), m(_, U);
280
- var Ie = We(Se);
281
- return q(), Ie;
282
- }
283
- He(["click"]);
284
- De(
285
- _t,
286
- {
287
- initialGames: {},
288
- endpoint: {},
289
- language: {},
290
- session: {},
291
- tournamentid: {},
292
- totalGames: {},
293
- platform: {},
294
- tournamentMetadata: {},
295
- translationurl: {},
296
- hasCasino: {},
297
- hasSports: {}
298
- },
299
- [],
300
- [],
301
- { mode: "open" }
302
- );
303
- export {
304
- _t as T,
305
- ot as s
306
- };
@@ -1,284 +0,0 @@
1
- import { B as je, c as Be, g as Pe, a as He, p as i, C as Ve, D as de, E as De, K as Fe, F as Je, q as O, G as ae, i as N, R as qe, b as o, d as Ke, f as g, v as l, J as Qe, h as R, j as t, s as S, r as A, o as j, N as w, t as E, k as ce, l as B, O as G, T as se, V as he, P as ne, L as re, M as oe, m as C, U as Ue, $ as We, H as Ze, W as Xe, Q as Ye } from "./StatusBadge-DuF7NK69.js";
2
- import { s as $e, G as pe, f as et, a as tt } from "./TournamentLeaderboard-BJ0mlW5c.js";
3
- import { a as at } from "./translations-BQS5XycD.js";
4
- typeof globalThis.HTMLElement > "u" && (globalThis.HTMLElement = class {
5
- }, globalThis.customElements = { define() {
6
- }, get() {
7
- }, whenDefined() {
8
- } });
9
- const st = (x, s = !1) => {
10
- if (!x)
11
- return;
12
- const d = parseFloat(getComputedStyle(x).scrollMarginTop) || 0;
13
- if (s && x.getBoundingClientRect().top >= d)
14
- return;
15
- const J = window.matchMedia("(prefers-reduced-motion: reduce)").matches;
16
- x.scrollIntoView({ behavior: J ? "auto" : "smooth", block: "start" });
17
- };
18
- var nt = g('<div class="tournament-games__tabs svelte-49hxa3" role="tablist"><button type="button" role="tab"> </button> <button type="button" role="tab"> </button></div>'), ve = g('<p class="tournament-games__empty svelte-49hxa3"> </p>'), rt = g('<span class="tournament-games__badge svelte-49hxa3"> </span>'), ot = g('<button type="button" class="tournament-games__game svelte-49hxa3"><img class="tournament-games__image svelte-49hxa3" loading="lazy"/> <span class="tournament-games__play svelte-49hxa3" aria-hidden="true"><span class="tournament-games__play-button svelte-49hxa3"> </span></span> <!></button>'), it = g('<span class="tournament-games__game tournament-games__game--placeholder svelte-49hxa3" aria-hidden="true"></span>'), lt = g('<div class="tournament-games__sentinel svelte-49hxa3"></div>'), mt = g('<div class="tournament-games__grid svelte-49hxa3"><!> <!></div> <!>', 1), ut = g('<li class="svelte-49hxa3"> </li>'), gt = g('<ul class="tournament-games__events svelte-49hxa3"></ul>'), dt = g('<div class="tournament-games svelte-49hxa3"><!> <!></div>');
19
- const ct = {
20
- hash: "svelte-49hxa3",
21
- code: `.tournament-games.svelte-49hxa3 {scroll-margin-top:80px;display:flex;flex-direction:column;gap:20px;color:var(--text-subtle, rgba(223, 227, 232, 1));.tournament-games__tabs:where(.svelte-49hxa3) {display:flex;border-bottom:1px solid var(--border-default, rgba(251, 251, 251, 0.15));width:max-content;max-width:100%;}.tournament-games__tab:where(.svelte-49hxa3) {position:relative;flex:0 0 auto;height:31px;padding:0 10px;border:0;background:transparent;color:var(--text-subtle, rgba(223, 227, 232, 1));font:inherit;font-size:14px;font-weight:500;cursor:pointer;line-height:145%;min-width:206px;&.active {color:var(--text-brand, rgba(255, 204, 0, 1));font-weight:700;&::after {content:'';position:absolute;left:0;right:0;bottom:-1px;height:2px;background:var(--pagination-bg-selected, rgba(255, 204, 0, 1));}}}.tournament-games__grid:where(.svelte-49hxa3) {display:grid;grid-template-columns:repeat(6, minmax(0, 1fr));gap:8px;}.tournament-games__game:where(.svelte-49hxa3) {position:relative;display:block;width:100%;align-self:start;padding:0;overflow:hidden;border:0;border-radius:6px;background:transparent;line-height:0;cursor:pointer;&:focus-visible {outline:2px solid var(--border-brand, rgba(255, 204, 0, 1));outline-offset:2px;}&:focus-visible .tournament-games__play:where(.svelte-49hxa3) {opacity:1;}
22
-
23
- @media (hover: hover) {&:hover .tournament-games__play:where(.svelte-49hxa3) {opacity:1;}
24
- }}.tournament-games__play:where(.svelte-49hxa3) {position:absolute;inset:0;z-index:2;display:flex;justify-content:center;align-items:center;border-radius:6px;background:rgba(0, 0, 0, 0.6);line-height:1;opacity:0;transition:opacity 0.2s ease;}.tournament-games__play-button:where(.svelte-49hxa3) {display:flex;justify-content:center;align-items:center;min-width:50%;padding:8px 16px;border-radius:6px;background:var(--button-primary-bg-default, #ffcc00);color:var(--button-primary-text-default, rgba(38, 29, 0, 1));font-size:13px;font-weight:600;}.tournament-games__game--placeholder:where(.svelte-49hxa3) {height:120px;background:var(--bg-overlay-neutral-level-1, rgba(251, 251, 251, 0.05));cursor:default;
25
- animation: svelte-49hxa3-tournament-games-pulse 1.2s ease-in-out infinite;}.tournament-games__image:where(.svelte-49hxa3) {display:block;width:100%;height:120px;object-fit:cover;border-radius:6px;}.tournament-games__badge:where(.svelte-49hxa3) {position:absolute;top:10px;left:9.6px;z-index:1;display:flex;justify-content:center;align-items:center;padding:4px 6px;background:var(--bg-overlay-secondary-level-5, rgba(0, 40, 81, 0.35));border:1px solid var(--primary-400, rgba(255, 204, 0, 1));backdrop-filter:blur(10px);box-shadow:0 2px 6px rgba(0, 0, 0, 0.25);border-radius:12px;color:var(--primary-400, rgba(255, 225, 107, 1));font-size:8px;line-height:8px;}.tournament-games__sentinel:where(.svelte-49hxa3) {height:1px;margin-top:-16px;}.tournament-games__events:where(.svelte-49hxa3) {display:flex;flex-direction:column;gap:24px;margin:0;padding:0;font-size:12px;line-height:1.4;list-style:none;font-weight:400;color:var(--text-subtle, rgba(223, 227, 232, 1));}.tournament-games__empty:where(.svelte-49hxa3) {margin:0;padding:32px 0;text-align:center;}}
26
-
27
- @keyframes svelte-49hxa3-tournament-games-pulse {
28
- 50% {
29
- opacity: 0.5;
30
- }
31
- }
32
-
33
- @media (max-width: 767px) {.tournament-games.svelte-49hxa3 {.tournament-games__tabs:where(.svelte-49hxa3) {width:100%;}.tournament-games__tab:where(.svelte-49hxa3) {flex:1;min-width:0;font-size:12px;font-weight:400;}.tournament-games__grid:where(.svelte-49hxa3) {grid-template-columns:repeat(3, minmax(0, 1fr));}.tournament-games__image:where(.svelte-49hxa3),
34
- .tournament-games__game--placeholder:where(.svelte-49hxa3) {height:75px;}.tournament-games__badge:where(.svelte-49hxa3) {top:5px;left:4.67px;}}
35
- }
36
-
37
- @media (prefers-reduced-motion: reduce) {.tournament-games.svelte-49hxa3 .tournament-games__game--placeholder:where(.svelte-49hxa3) {
38
- animation: none;}.tournament-games.svelte-49hxa3 .tournament-games__play:where(.svelte-49hxa3) {transition:none;}
39
- }`
40
- };
41
- function ht(x, s) {
42
- Pe(s, !0), He(x, ct);
43
- const d = () => Ue(We, "$_", J), [J, _e] = Qe(), P = i(s, "initialGames", 7), q = i(s, "endpoint", 7), T = i(s, "language", 7, "en"), K = i(s, "session", 7), H = i(s, "tournamentid", 7), Q = i(s, "totalGames", 7), U = i(s, "platform", 7), W = i(s, "tournamentMetadata", 7), V = i(s, "translationurl", 7), z = i(s, "hasCasino", 7, !0), L = i(s, "hasSports", 7, !1);
44
- Ve(at), de(T());
45
- const xe = () => {
46
- de(T());
47
- };
48
- De(() => {
49
- V() && Fe(V());
50
- }), Je(() => {
51
- xe();
52
- });
53
- let h = O(ae(P() || [])), D = O(ae(Q() ?? (P()?.length || 0))), Z = O(!1), b = O(ae(z() || !L() ? "casino" : "sports")), X = O(null);
54
- const ie = (e) => {
55
- e !== t(b) && (C(b, e, !0), Ze().then(() => st(t(X), !0)));
56
- }, le = j(() => z() && L()), be = j(() => t(le) ? t(b) === "casino" : !L() || z()), Y = j(() => t(h).length < t(D)), fe = j(() => Math.min(Math.max(t(D) - t(h).length, 0), pe)), me = j(() => {
57
- const e = W()?.sports?.rules;
58
- if (!e)
59
- return [];
60
- try {
61
- const a = JSON.parse(e);
62
- return a[T()] || a["*"] || [];
63
- } catch (a) {
64
- return console.log(a), [];
65
- }
66
- }), ye = async () => {
67
- if (!(!t(Y) || t(Z))) {
68
- C(Z, !0);
69
- try {
70
- const e = await et({
71
- endpoint: q(),
72
- language: T(),
73
- platform: U(),
74
- session: K(),
75
- tournamentid: H(),
76
- filterById: !0,
77
- gamesLimit: pe,
78
- gamesOffset: t(h).length
79
- });
80
- C(h, [...t(h), ...e?.games?.items ?? []], !0), C(D, e?.games?.total ?? t(D), !0);
81
- } catch (e) {
82
- console.log(e);
83
- } finally {
84
- C(Z, !1);
85
- }
86
- }
87
- }, we = (e, a) => {
88
- const n = new IntersectionObserver(
89
- (m) => {
90
- m.some((p) => p.isIntersecting) && a();
91
- },
92
- { rootMargin: tt }
93
- );
94
- return n.observe(e), {
95
- destroy() {
96
- n.disconnect();
97
- }
98
- };
99
- }, Ge = (e) => {
100
- $e(e, H());
101
- };
102
- var Te = {
103
- get initialGames() {
104
- return P();
105
- },
106
- set initialGames(e) {
107
- P(e), l();
108
- },
109
- get endpoint() {
110
- return q();
111
- },
112
- set endpoint(e) {
113
- q(e), l();
114
- },
115
- get language() {
116
- return T();
117
- },
118
- set language(e = "en") {
119
- T(e), l();
120
- },
121
- get session() {
122
- return K();
123
- },
124
- set session(e) {
125
- K(e), l();
126
- },
127
- get tournamentid() {
128
- return H();
129
- },
130
- set tournamentid(e) {
131
- H(e), l();
132
- },
133
- get totalGames() {
134
- return Q();
135
- },
136
- set totalGames(e) {
137
- Q(e), l();
138
- },
139
- get platform() {
140
- return U();
141
- },
142
- set platform(e) {
143
- U(e), l();
144
- },
145
- get tournamentMetadata() {
146
- return W();
147
- },
148
- set tournamentMetadata(e) {
149
- W(e), l();
150
- },
151
- get translationurl() {
152
- return V();
153
- },
154
- set translationurl(e) {
155
- V(e), l();
156
- },
157
- get hasCasino() {
158
- return z();
159
- },
160
- set hasCasino(e = !0) {
161
- z(e), l();
162
- },
163
- get hasSports() {
164
- return L();
165
- },
166
- set hasSports(e = !1) {
167
- L(e), l();
168
- }
169
- }, F = dt(), ue = R(F);
170
- {
171
- var ke = (e) => {
172
- var a = nt(), n = R(a);
173
- let m;
174
- var p = w(n, !0), r = S(n, 2);
175
- let u;
176
- var f = w(r, !0);
177
- A(a), E(
178
- (k, $) => {
179
- m = ce(n, 1, "tournament-games__tab svelte-49hxa3", null, m, { active: t(b) === "casino" }), B(n, "aria-selected", t(b) === "casino"), G(p, k), u = ce(r, 1, "tournament-games__tab svelte-49hxa3", null, u, { active: t(b) === "sports" }), B(r, "aria-selected", t(b) === "sports"), G(f, $);
180
- },
181
- [() => d()("casinoTab"), () => d()("sportsTab")]
182
- ), se("click", n, () => ie("casino")), se("click", r, () => ie("sports")), o(e, a);
183
- };
184
- N(ue, (e) => {
185
- t(le) && e(ke);
186
- });
187
- }
188
- var Me = S(ue, 2);
189
- {
190
- var Se = (e) => {
191
- var a = he(), n = ne(a);
192
- {
193
- var m = (r) => {
194
- var u = ve(), f = w(u, !0);
195
- E((k) => G(f, k), [() => d()("noAvailableGames")]), o(r, u);
196
- }, p = (r) => {
197
- var u = mt(), f = ne(u), k = R(f);
198
- re(k, 17, () => t(h), oe, (y, c) => {
199
- var v = ot(), M = R(v), _ = S(M, 2), ee = R(_), te = w(ee, !0);
200
- A(_);
201
- var Ie = S(_, 2);
202
- {
203
- var Oe = (I) => {
204
- var ge = rt(), Ne = w(ge, !0);
205
- E((Re) => G(Ne, Re), [() => d()("newBadge")]), o(I, ge);
206
- };
207
- N(Ie, (I) => {
208
- t(c).isNew && I(Oe);
209
- });
210
- }
211
- A(v), E(
212
- (I) => {
213
- B(v, "title", t(c).name), B(M, "src", `https:${t(c).thumbnail}`), B(M, "alt", t(c).name), G(te, I);
214
- },
215
- [() => d()("play")]
216
- ), se("click", v, () => Ge(t(c))), o(y, v);
217
- });
218
- var $ = S(k, 2);
219
- re($, 17, () => Array(t(fe)), oe, (y, c, v, M) => {
220
- var _ = it();
221
- o(y, _);
222
- }), A(f);
223
- var ze = S(f, 2);
224
- {
225
- var Le = (y) => {
226
- var c = he(), v = ne(c);
227
- Xe(v, () => t(h).length, (M) => {
228
- var _ = lt();
229
- Ye(_, (ee, te) => we?.(ee, te), () => ye), o(M, _);
230
- }), o(y, c);
231
- };
232
- N(ze, (y) => {
233
- t(Y) && y(Le);
234
- });
235
- }
236
- o(r, u);
237
- };
238
- N(n, (r) => {
239
- t(h).length === 0 && !t(Y) ? r(m) : r(p, -1);
240
- });
241
- }
242
- o(e, a);
243
- }, Ae = (e) => {
244
- var a = ve(), n = w(a, !0);
245
- E((m) => G(n, m), [() => d()("noAvailableEvents")]), o(e, a);
246
- }, Ee = (e) => {
247
- var a = gt();
248
- re(a, 21, () => t(me), oe, (n, m) => {
249
- var p = ut(), r = w(p);
250
- E((u) => G(r, `${t(m).rule ?? ""} ${u ?? ""}`), [() => d()("contribution")]), o(n, p);
251
- }), A(a), o(e, a);
252
- };
253
- N(Me, (e) => {
254
- t(be) ? e(Se) : t(me).length === 0 ? e(Ae, 1) : e(Ee, -1);
255
- });
256
- }
257
- A(F), qe(F, (e) => C(X, e), () => t(X)), o(x, F);
258
- var Ce = Ke(Te);
259
- return _e(), Ce;
260
- }
261
- je(["click"]);
262
- Be(
263
- ht,
264
- {
265
- initialGames: {},
266
- endpoint: {},
267
- language: {},
268
- session: {},
269
- tournamentid: {},
270
- totalGames: {},
271
- platform: {},
272
- tournamentMetadata: {},
273
- translationurl: {},
274
- hasCasino: {},
275
- hasSports: {}
276
- },
277
- [],
278
- [],
279
- { mode: "open" }
280
- );
281
- export {
282
- ht as T,
283
- st as s
284
- };
@@ -1,19 +0,0 @@
1
- typeof globalThis.HTMLElement>"u"&&(globalThis.HTMLElement=class{},globalThis.customElements={define(){},get(){},whenDefined(){}});const e=require("./StatusBadge-BsjzjNer.cjs"),k=require("./TournamentLeaderboard-B6IMbAZ_.cjs"),_e=require("./translations-BSe2qToO.cjs"),Q=(p,n=!1)=>{if(!p)return;const i=parseFloat(getComputedStyle(p).scrollMarginTop)||0;if(n&&p.getBoundingClientRect().top>=i)return;const L=window.matchMedia("(prefers-reduced-motion: reduce)").matches;p.scrollIntoView({behavior:L?"auto":"smooth",block:"start"})};var ve=e.from_html('<div class="tournament-games__tabs svelte-49hxa3" role="tablist"><button type="button" role="tab"> </button> <button type="button" role="tab"> </button></div>'),K=e.from_html('<p class="tournament-games__empty svelte-49hxa3"> </p>'),fe=e.from_html('<span class="tournament-games__badge svelte-49hxa3"> </span>'),xe=e.from_html('<button type="button" class="tournament-games__game svelte-49hxa3"><img class="tournament-games__image svelte-49hxa3" loading="lazy"/> <span class="tournament-games__play svelte-49hxa3" aria-hidden="true"><span class="tournament-games__play-button svelte-49hxa3"> </span></span> <!></button>'),be=e.from_html('<span class="tournament-games__game tournament-games__game--placeholder svelte-49hxa3" aria-hidden="true"></span>'),ye=e.from_html('<div class="tournament-games__sentinel svelte-49hxa3"></div>'),we=e.from_html('<div class="tournament-games__grid svelte-49hxa3"><!> <!></div> <!>',1),Se=e.from_html('<li class="svelte-49hxa3"> </li>'),ke=e.from_html('<ul class="tournament-games__events svelte-49hxa3"></ul>'),Ge=e.from_html('<div class="tournament-games svelte-49hxa3"><!> <!></div>');const Te={hash:"svelte-49hxa3",code:`.tournament-games.svelte-49hxa3 {scroll-margin-top:80px;display:flex;flex-direction:column;gap:20px;color:var(--text-subtle, rgba(223, 227, 232, 1));.tournament-games__tabs:where(.svelte-49hxa3) {display:flex;border-bottom:1px solid var(--border-default, rgba(251, 251, 251, 0.15));width:max-content;max-width:100%;}.tournament-games__tab:where(.svelte-49hxa3) {position:relative;flex:0 0 auto;height:31px;padding:0 10px;border:0;background:transparent;color:var(--text-subtle, rgba(223, 227, 232, 1));font:inherit;font-size:14px;font-weight:500;cursor:pointer;line-height:145%;min-width:206px;&.active {color:var(--text-brand, rgba(255, 204, 0, 1));font-weight:700;&::after {content:'';position:absolute;left:0;right:0;bottom:-1px;height:2px;background:var(--pagination-bg-selected, rgba(255, 204, 0, 1));}}}.tournament-games__grid:where(.svelte-49hxa3) {display:grid;grid-template-columns:repeat(6, minmax(0, 1fr));gap:8px;}.tournament-games__game:where(.svelte-49hxa3) {position:relative;display:block;width:100%;align-self:start;padding:0;overflow:hidden;border:0;border-radius:6px;background:transparent;line-height:0;cursor:pointer;&:focus-visible {outline:2px solid var(--border-brand, rgba(255, 204, 0, 1));outline-offset:2px;}&:focus-visible .tournament-games__play:where(.svelte-49hxa3) {opacity:1;}
2
-
3
- @media (hover: hover) {&:hover .tournament-games__play:where(.svelte-49hxa3) {opacity:1;}
4
- }}.tournament-games__play:where(.svelte-49hxa3) {position:absolute;inset:0;z-index:2;display:flex;justify-content:center;align-items:center;border-radius:6px;background:rgba(0, 0, 0, 0.6);line-height:1;opacity:0;transition:opacity 0.2s ease;}.tournament-games__play-button:where(.svelte-49hxa3) {display:flex;justify-content:center;align-items:center;min-width:50%;padding:8px 16px;border-radius:6px;background:var(--button-primary-bg-default, #ffcc00);color:var(--button-primary-text-default, rgba(38, 29, 0, 1));font-size:13px;font-weight:600;}.tournament-games__game--placeholder:where(.svelte-49hxa3) {height:120px;background:var(--bg-overlay-neutral-level-1, rgba(251, 251, 251, 0.05));cursor:default;
5
- animation: svelte-49hxa3-tournament-games-pulse 1.2s ease-in-out infinite;}.tournament-games__image:where(.svelte-49hxa3) {display:block;width:100%;height:120px;object-fit:cover;border-radius:6px;}.tournament-games__badge:where(.svelte-49hxa3) {position:absolute;top:10px;left:9.6px;z-index:1;display:flex;justify-content:center;align-items:center;padding:4px 6px;background:var(--bg-overlay-secondary-level-5, rgba(0, 40, 81, 0.35));border:1px solid var(--primary-400, rgba(255, 204, 0, 1));backdrop-filter:blur(10px);box-shadow:0 2px 6px rgba(0, 0, 0, 0.25);border-radius:12px;color:var(--primary-400, rgba(255, 225, 107, 1));font-size:8px;line-height:8px;}.tournament-games__sentinel:where(.svelte-49hxa3) {height:1px;margin-top:-16px;}.tournament-games__events:where(.svelte-49hxa3) {display:flex;flex-direction:column;gap:24px;margin:0;padding:0;font-size:12px;line-height:1.4;list-style:none;font-weight:400;color:var(--text-subtle, rgba(223, 227, 232, 1));}.tournament-games__empty:where(.svelte-49hxa3) {margin:0;padding:32px 0;text-align:center;}}
6
-
7
- @keyframes svelte-49hxa3-tournament-games-pulse {
8
- 50% {
9
- opacity: 0.5;
10
- }
11
- }
12
-
13
- @media (max-width: 767px) {.tournament-games.svelte-49hxa3 {.tournament-games__tabs:where(.svelte-49hxa3) {width:100%;}.tournament-games__tab:where(.svelte-49hxa3) {flex:1;min-width:0;font-size:12px;font-weight:400;}.tournament-games__grid:where(.svelte-49hxa3) {grid-template-columns:repeat(3, minmax(0, 1fr));}.tournament-games__image:where(.svelte-49hxa3),
14
- .tournament-games__game--placeholder:where(.svelte-49hxa3) {height:75px;}.tournament-games__badge:where(.svelte-49hxa3) {top:5px;left:4.67px;}}
15
- }
16
-
17
- @media (prefers-reduced-motion: reduce) {.tournament-games.svelte-49hxa3 .tournament-games__game--placeholder:where(.svelte-49hxa3) {
18
- animation: none;}.tournament-games.svelte-49hxa3 .tournament-games__play:where(.svelte-49hxa3) {transition:none;}
19
- }`};function U(p,n){e.push(n,!0),e.append_styles(p,Te);const i=()=>e.store_get(e.$format,"$_",L),[L,W]=e.setup_stores(),G=e.prop(n,"initialGames",7),z=e.prop(n,"endpoint",7),f=e.prop(n,"language",7,"en"),C=e.prop(n,"session",7),T=e.prop(n,"tournamentid",7),I=e.prop(n,"totalGames",7),O=e.prop(n,"platform",7),N=e.prop(n,"tournamentMetadata",7),M=e.prop(n,"translationurl",7),y=e.prop(n,"hasCasino",7,!0),w=e.prop(n,"hasSports",7,!1);e.registerTranslations(_e.TRANSLATIONS$1),e.setLocale(f());const X=()=>{e.setLocale(f())};e.user_pre_effect(()=>{M()&&e.loadTranslations(M())}),e.user_effect(()=>{X()});let u=e.state(e.proxy(G()||[])),A=e.state(e.proxy(I()??(G()?.length||0))),R=e.state(!1),h=e.state(e.proxy(y()||!w()?"casino":"sports")),j=e.state(null);const V=t=>{t!==e.get(h)&&(e.set(h,t,!0),e.tick().then(()=>Q(e.get(j),!0)))},Z=e.user_derived(()=>y()&&w()),Y=e.user_derived(()=>e.get(Z)?e.get(h)==="casino":!w()||y()),B=e.user_derived(()=>e.get(u).length<e.get(A)),$=e.user_derived(()=>Math.min(Math.max(e.get(A)-e.get(u).length,0),k.GAMES_PAGE_SIZE)),D=e.user_derived(()=>{const t=N()?.sports?.rules;if(!t)return[];try{const a=JSON.parse(t);return a[f()]||a["*"]||[]}catch(a){return console.log(a),[]}}),ee=async()=>{if(!(!e.get(B)||e.get(R))){e.set(R,!0);try{const t=await k.fetchTournament({endpoint:z(),language:f(),platform:O(),session:C(),tournamentid:T(),filterById:!0,gamesLimit:k.GAMES_PAGE_SIZE,gamesOffset:e.get(u).length});e.set(u,[...e.get(u),...t?.games?.items??[]],!0),e.set(A,t?.games?.total??e.get(A),!0)}catch(t){console.log(t)}finally{e.set(R,!1)}}},te=(t,a)=>{const r=new IntersectionObserver(o=>{o.some(g=>g.isIntersecting)&&a()},{rootMargin:k.GAMES_ROOT_MARGIN});return r.observe(t),{destroy(){r.disconnect()}}},ae=t=>{k.sendPlayGame(t,T())};var ne={get initialGames(){return G()},set initialGames(t){G(t),e.flushSync()},get endpoint(){return z()},set endpoint(t){z(t),e.flushSync()},get language(){return f()},set language(t="en"){f(t),e.flushSync()},get session(){return C()},set session(t){C(t),e.flushSync()},get tournamentid(){return T()},set tournamentid(t){T(t),e.flushSync()},get totalGames(){return I()},set totalGames(t){I(t),e.flushSync()},get platform(){return O()},set platform(t){O(t),e.flushSync()},get tournamentMetadata(){return N()},set tournamentMetadata(t){N(t),e.flushSync()},get translationurl(){return M()},set translationurl(t){M(t),e.flushSync()},get hasCasino(){return y()},set hasCasino(t=!0){y(t),e.flushSync()},get hasSports(){return w()},set hasSports(t=!1){w(t),e.flushSync()}},E=Ge(),F=e.child(E);{var re=t=>{var a=ve(),r=e.child(a);let o;var g=e.only_child(r,!0),s=e.sibling(r,2);let l;var _=e.only_child(s,!0);e.reset(a),e.template_effect((x,P)=>{o=e.set_class(r,1,"tournament-games__tab svelte-49hxa3",null,o,{active:e.get(h)==="casino"}),e.set_attribute(r,"aria-selected",e.get(h)==="casino"),e.set_text(g,x),l=e.set_class(s,1,"tournament-games__tab svelte-49hxa3",null,l,{active:e.get(h)==="sports"}),e.set_attribute(s,"aria-selected",e.get(h)==="sports"),e.set_text(_,P)},[()=>i()("casinoTab"),()=>i()("sportsTab")]),e.delegated("click",r,()=>V("casino")),e.delegated("click",s,()=>V("sports")),e.append(t,a)};e.if_block(F,t=>{e.get(Z)&&t(re)})}var se=e.sibling(F,2);{var oe=t=>{var a=e.comment(),r=e.first_child(a);{var o=s=>{var l=K(),_=e.only_child(l,!0);e.template_effect(x=>e.set_text(_,x),[()=>i()("noAvailableGames")]),e.append(s,l)},g=s=>{var l=we(),_=e.first_child(l),x=e.child(_);e.each(x,17,()=>e.get(u),e.index,(v,m)=>{var d=xe(),b=e.child(d),c=e.sibling(b,2),q=e.child(c),H=e.only_child(q,!0);e.reset(c);var de=e.sibling(c,2);{var ce=S=>{var J=fe(),pe=e.only_child(J,!0);e.template_effect(he=>e.set_text(pe,he),[()=>i()("newBadge")]),e.append(S,J)};e.if_block(de,S=>{e.get(m).isNew&&S(ce)})}e.reset(d),e.template_effect(S=>{e.set_attribute(d,"title",e.get(m).name),e.set_attribute(b,"src",`https:${e.get(m).thumbnail}`),e.set_attribute(b,"alt",e.get(m).name),e.set_text(H,S)},[()=>i()("play")]),e.delegated("click",d,()=>ae(e.get(m))),e.append(v,d)});var P=e.sibling(x,2);e.each(P,17,()=>Array(e.get($)),e.index,(v,m,d,b)=>{var c=be();e.append(v,c)}),e.reset(_);var ue=e.sibling(_,2);{var ge=v=>{var m=e.comment(),d=e.first_child(m);e.key(d,()=>e.get(u).length,b=>{var c=ye();e.action(c,(q,H)=>te?.(q,H),()=>ee),e.append(b,c)}),e.append(v,m)};e.if_block(ue,v=>{e.get(B)&&v(ge)})}e.append(s,l)};e.if_block(r,s=>{e.get(u).length===0&&!e.get(B)?s(o):s(g,-1)})}e.append(t,a)},le=t=>{var a=K(),r=e.only_child(a,!0);e.template_effect(o=>e.set_text(r,o),[()=>i()("noAvailableEvents")]),e.append(t,a)},ie=t=>{var a=ke();e.each(a,21,()=>e.get(D),e.index,(r,o)=>{var g=Se(),s=e.only_child(g);e.template_effect(l=>e.set_text(s,`${e.get(o).rule??""} ${l??""}`),[()=>i()("contribution")]),e.append(r,g)}),e.reset(a),e.append(t,a)};e.if_block(se,t=>{e.get(Y)?t(oe):e.get(D).length===0?t(le,1):t(ie,-1)})}e.reset(E),e.bind_this(E,t=>e.set(j,t),()=>e.get(j)),e.append(p,E);var me=e.pop(ne);return W(),me}e.delegate(["click"]);e.create_custom_element(U,{initialGames:{},endpoint:{},language:{},session:{},tournamentid:{},totalGames:{},platform:{},tournamentMetadata:{},translationurl:{},hasCasino:{},hasSports:{}},[],[],{mode:"open"});exports.TournamentGames=U;exports.scrollToSection=Q;