@everymatrix/casino-tournaments-list-controller 1.67.0 → 1.68.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 (31) hide show
  1. package/components/{CasinoTournamentsListController-DySbk5VW.js → CasinoTournamentsListController-916JL4F7.js} +1150 -1122
  2. package/components/CasinoTournamentsListController-CLH2CE8z.cjs +15 -0
  3. package/components/{CasinoTournamentsListController-C4mihNnj.js → CasinoTournamentsListController-DZAcldSI.js} +1227 -1199
  4. package/components/{CasinoTournamentsThumbnail-BGguyWao.js → CasinoTournamentsThumbnail-CO-eYscS.js} +182 -190
  5. package/components/{CasinoTournamentsThumbnail-Dm47dnjW.cjs → CasinoTournamentsThumbnail-CPbOt4AY.cjs} +2 -2
  6. package/components/{CasinoTournamentsThumbnail-Yl8kaw-d.js → CasinoTournamentsThumbnail-nwxK7LAX.js} +182 -190
  7. package/components/CasinoTournamentsThumbnailController-A_BKNTJR.cjs +16 -0
  8. package/components/{CasinoTournamentsThumbnailController-gMjU8WUF.js → CasinoTournamentsThumbnailController-Bq1AssJj.js} +729 -693
  9. package/components/{CasinoTournamentsThumbnailController-D4fh4BOQ.js → CasinoTournamentsThumbnailController-CKIWWza3.js} +697 -661
  10. package/components/{CasinoTournamentsThumbnailDuration-CM4PmXyz.js → CasinoTournamentsThumbnailDuration-CoD7UhLT.js} +148 -154
  11. package/components/{CasinoTournamentsThumbnailDuration-VhRuoa0C.js → CasinoTournamentsThumbnailDuration-Cs4yX-Vh.js} +148 -154
  12. package/components/CasinoTournamentsThumbnailDuration-D96wnUeF.cjs +1 -0
  13. package/components/CasinoTournamentsThumbnailGamesSlider-BsYSU3V2.cjs +1 -0
  14. package/components/CasinoTournamentsThumbnailGamesSlider-DeZzlvbO.js +435 -0
  15. package/components/CasinoTournamentsThumbnailGamesSlider-DyvJUNdJ.js +435 -0
  16. package/components/CasinoTournamentsThumbnailPrizes-8tONX9SA.cjs +1 -0
  17. package/components/CasinoTournamentsThumbnailPrizes-BJHbDTCY.js +307 -0
  18. package/components/CasinoTournamentsThumbnailPrizes-CuVL_zHr.js +307 -0
  19. package/es2015/casino-tournaments-list-controller.cjs +1 -1
  20. package/es2015/casino-tournaments-list-controller.js +1 -1
  21. package/esnext/casino-tournaments-list-controller.js +1 -1
  22. package/package.json +1 -1
  23. package/components/CasinoTournamentsListController-BNVcBVyF.cjs +0 -15
  24. package/components/CasinoTournamentsThumbnailController-DSTK12aD.cjs +0 -16
  25. package/components/CasinoTournamentsThumbnailDuration-DotSLQks.cjs +0 -1
  26. package/components/CasinoTournamentsThumbnailGamesSlider-DPfGI_tX.js +0 -443
  27. package/components/CasinoTournamentsThumbnailGamesSlider-DelsM0V9.js +0 -443
  28. package/components/CasinoTournamentsThumbnailGamesSlider-QjFgAppB.cjs +0 -1
  29. package/components/CasinoTournamentsThumbnailPrizes-C4W8HVKg.js +0 -315
  30. package/components/CasinoTournamentsThumbnailPrizes-CMxv0Giw.cjs +0 -1
  31. package/components/CasinoTournamentsThumbnailPrizes-qFFMpsOU.js +0 -315
@@ -1,443 +0,0 @@
1
- import { b as be, S as ve, i as ke, s as Ne, f as M, c as Se, n as x, d as G, g as I, j as S, l as Te, o as Fe, D as J, E as Me, u as te, F as C, C as Y, h as v, G as Ee, v as L, k as z, e as c, H as Pe, p as D, m as Be, w as Z, t as Le, z as He, A as je } from "./CasinoTournamentsListController-C4mihNnj.js";
2
- import { g as Ce } from "./CasinoTournamentsThumbnailController-D4fh4BOQ.js";
3
- function K(e, l) {
4
- be(e, l);
5
- }
6
- const Q = {
7
- en: {
8
- playNow: "Play now"
9
- },
10
- hr: {
11
- playNow: "Započni sada"
12
- },
13
- "zh-hk": {
14
- playNow: "现在播放"
15
- },
16
- fr: {
17
- playNow: "Joue maintenant"
18
- },
19
- ro: {
20
- playNow: "Joaca acum"
21
- },
22
- tr: {
23
- playNow: "Şimdi oyna"
24
- },
25
- el: {
26
- playNow: "Παίξε τώρα"
27
- },
28
- es: {
29
- playNow: "Jugar Ya"
30
- },
31
- pt: {
32
- playNow: "Jogue agora"
33
- },
34
- "en-us": {
35
- playNow: "Play now"
36
- }
37
- };
38
- function ze(e) {
39
- Se(e, "svelte-xgd67c", "*,*::before,*::after{margin:0;padding:0;list-style:none;text-decoration:none;outline:none;box-sizing:border-box}.TournamentsGamesSlider{background:var(--emw--color-contrast, #07072A);color:var(--emw--color-white, #FFFFFF);display:flex;justify-content:center}.disabled{color:var(--emw--color-contrast, #07072A)}.SliderNavButton{background:var(--emw--color-contrast, #07072A);border:0px;width:25px;display:flex;align-items:center;justify-content:center}.SliderNavButton svg{width:20px}.NavButton{background:var(--emw--color-contrast, #07072A);border:0px;width:25px;display:flex;align-items:center;justify-content:center}main{width:95%;overflow:hidden}.items{display:flex;transition:transform 0.4s ease-in-out;transform:translateX(0px)}.item{min-width:119px;height:96px;margin:0 4px;background-color:var(--emw--color-secondary, #FD2839);color:white;display:flex;justify-content:center;align-items:center;font-weight:bold;font-size:10rem;user-select:none;overflow:hidden}.PlayNowButton{position:absolute;background:var(--emw--color-green, #48952a);display:block;box-sizing:border-box;padding:0.8rem 0.5rem;color:var(--emw--color-white, #FFFFFF);text-transform:uppercase;text-align:center;font-weight:600;font-size:0.7rem;cursor:pointer;transition:opacity 0.4s linear;opacity:0;text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.itemHover{opacity:1}.items .item:first-child{margin-left:0}.items .item:last-child{margin-right:0}");
40
- }
41
- function V(e, l, t) {
42
- const a = e.slice();
43
- return a[50] = l[t], a[52] = t, a;
44
- }
45
- function $(e) {
46
- let l, t, a, m, d, p, y, r, w, _, f = J(
47
- /*games*/
48
- e[1]
49
- ), o = [];
50
- for (let s = 0; s < f.length; s += 1)
51
- o[s] = ee(V(e, f, s));
52
- return {
53
- c() {
54
- l = S("div"), t = S("div"), t.innerHTML = '<svg fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M15 19l-7-7 7-7"></path></svg>', a = z(), m = S("main"), d = S("div");
55
- for (let s = 0; s < o.length; s += 1)
56
- o[s].c();
57
- y = z(), r = S("div"), r.innerHTML = '<svg fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M9 5l7 7-7 7"></path></svg>', c(t, "class", "SliderNavButton"), c(t, "part", "SliderNavButton"), C(
58
- t,
59
- "disabled",
60
- /*atStart*/
61
- e[8]
62
- ), c(d, "class", "items"), c(d, "part", "items"), Y(d, "transform", "translateX(" + /*offset*/
63
- e[2] + "px)"), Pe(() => (
64
- /*main_elementresize_handler*/
65
- e[28].call(m)
66
- )), c(r, "class", "SliderNavButton"), c(r, "part", "SliderNavButton"), C(
67
- r,
68
- "disabled",
69
- /*atEnd*/
70
- e[9]
71
- ), c(l, "class", "TournamentsGamesSlider"), c(l, "part", "TournamentsGamesSlider");
72
- },
73
- m(s, b) {
74
- I(s, l, b), v(l, t), v(l, a), v(l, m), v(m, d);
75
- for (let i = 0; i < o.length; i += 1)
76
- o[i] && o[i].m(d, null);
77
- e[27](d), p = Ee(
78
- m,
79
- /*main_elementresize_handler*/
80
- e[28].bind(m)
81
- ), v(l, y), v(l, r), e[30](l), w || (_ = [
82
- L(
83
- t,
84
- "click",
85
- /*click_handler*/
86
- e[23]
87
- ),
88
- L(
89
- r,
90
- "click",
91
- /*click_handler_2*/
92
- e[29]
93
- )
94
- ], w = !0);
95
- },
96
- p(s, b) {
97
- if (b[0] & /*atStart*/
98
- 256 && C(
99
- t,
100
- "disabled",
101
- /*atStart*/
102
- s[8]
103
- ), b[0] & /*gameClicked, games, enter, leave, hover, hoverIndex, $_*/
104
- 23650) {
105
- f = J(
106
- /*games*/
107
- s[1]
108
- );
109
- let i;
110
- for (i = 0; i < f.length; i += 1) {
111
- const k = V(s, f, i);
112
- o[i] ? o[i].p(k, b) : (o[i] = ee(k), o[i].c(), o[i].m(d, null));
113
- }
114
- for (; i < o.length; i += 1)
115
- o[i].d(1);
116
- o.length = f.length;
117
- }
118
- b[0] & /*offset*/
119
- 4 && Y(d, "transform", "translateX(" + /*offset*/
120
- s[2] + "px)"), b[0] & /*atEnd*/
121
- 512 && C(
122
- r,
123
- "disabled",
124
- /*atEnd*/
125
- s[9]
126
- );
127
- },
128
- d(s) {
129
- s && G(l), Me(o, s), e[27](null), p(), e[30](null), w = !1, te(_);
130
- }
131
- };
132
- }
133
- function ee(e) {
134
- let l, t, a = (
135
- /*$_*/
136
- e[10]("playNow") + ""
137
- ), m, d, p, y, r, w, _, f, o, s, b;
138
- function i() {
139
- return (
140
- /*click_handler_1*/
141
- e[24](
142
- /*game*/
143
- e[50]
144
- )
145
- );
146
- }
147
- function k() {
148
- return (
149
- /*mouseenter_handler*/
150
- e[25](
151
- /*i*/
152
- e[52]
153
- )
154
- );
155
- }
156
- return {
157
- c() {
158
- l = S("div"), t = S("span"), m = Le(a), y = z(), r = S("img"), o = z(), c(t, "class", d = "PlayNowButton " + /*hover*/
159
- (e[5] && /*hoverIndex*/
160
- e[6] == /*i*/
161
- e[52] ? "itemHover" : "")), c(t, "part", p = "PlayNowButton " + /*hover*/
162
- (e[5] && /*hoverIndex*/
163
- e[6] == /*i*/
164
- e[52] ? "itemHover" : "")), Z(r.src, w = /*game*/
165
- e[50].thumbnail) || c(r, "src", w), c(r, "width", "132px"), c(r, "height", "100px"), c(r, "alt", _ = /*game*/
166
- e[50].name), c(r, "title", f = /*game*/
167
- e[50].name), c(l, "class", "item"), c(l, "part", "item");
168
- },
169
- m(u, h) {
170
- I(u, l, h), v(l, t), v(t, m), v(l, y), v(l, r), v(l, o), s || (b = [
171
- L(l, "click", i),
172
- L(l, "mouseenter", k),
173
- L(
174
- l,
175
- "mouseleave",
176
- /*mouseleave_handler*/
177
- e[26]
178
- )
179
- ], s = !0);
180
- },
181
- p(u, h) {
182
- e = u, h[0] & /*$_*/
183
- 1024 && a !== (a = /*$_*/
184
- e[10]("playNow") + "") && Be(m, a), h[0] & /*hover, hoverIndex*/
185
- 96 && d !== (d = "PlayNowButton " + /*hover*/
186
- (e[5] && /*hoverIndex*/
187
- e[6] == /*i*/
188
- e[52] ? "itemHover" : "")) && c(t, "class", d), h[0] & /*hover, hoverIndex*/
189
- 96 && p !== (p = "PlayNowButton " + /*hover*/
190
- (e[5] && /*hoverIndex*/
191
- e[6] == /*i*/
192
- e[52] ? "itemHover" : "")) && c(t, "part", p), h[0] & /*games*/
193
- 2 && !Z(r.src, w = /*game*/
194
- e[50].thumbnail) && c(r, "src", w), h[0] & /*games*/
195
- 2 && _ !== (_ = /*game*/
196
- e[50].name) && c(r, "alt", _), h[0] & /*games*/
197
- 2 && f !== (f = /*game*/
198
- e[50].name) && c(r, "title", f);
199
- },
200
- d(u) {
201
- u && G(l), s = !1, te(b);
202
- }
203
- };
204
- }
205
- function Ae(e) {
206
- let l, t = (
207
- /*games*/
208
- e[1] && /*games*/
209
- e[1].length > 0 && $(e)
210
- );
211
- return {
212
- c() {
213
- l = S("div"), t && t.c();
214
- },
215
- m(a, m) {
216
- I(a, l, m), t && t.m(l, null), e[31](l);
217
- },
218
- p(a, m) {
219
- /*games*/
220
- a[1] && /*games*/
221
- a[1].length > 0 ? t ? t.p(a, m) : (t = $(a), t.c(), t.m(l, null)) : t && (t.d(1), t = null);
222
- },
223
- i: x,
224
- o: x,
225
- d(a) {
226
- a && G(l), t && t.d(), e[31](null);
227
- }
228
- };
229
- }
230
- let Ue = 30;
231
- function De(e, l, t) {
232
- let a, m, d;
233
- Te(e, je, (n) => t(10, d = n));
234
- let { tournamenturl: p = "" } = l, { scrollby: y = "3" } = l, { pagfactor: r = "175" } = l, { lang: w = "" } = l, { translationurl: _ = "" } = l, { clientstyling: f = "" } = l, { clientstylingurl: o = "" } = l, s, b = window.navigator.userAgent, i, k = [], u = 0, h, H = null, j = null, A = !1, U, E, P = 0, T;
235
- const ne = () => {
236
- fetch(_).then((g) => g.json()).then((g) => {
237
- Object.keys(g).forEach((N) => {
238
- K(N, g[N]);
239
- });
240
- }).catch((g) => {
241
- console.log(g);
242
- });
243
- };
244
- Object.keys(Q).forEach((n) => {
245
- K(n, Q[n]);
246
- });
247
- const W = (n) => {
248
- t(5, A = !0), t(6, U = n);
249
- }, q = () => {
250
- t(5, A = !1), t(6, U = -1);
251
- }, le = (n) => n.touches || n.originalEvent.touches, O = (n) => {
252
- const g = le(n)[0];
253
- H = g.clientX, j = g.clientY;
254
- }, R = (n) => {
255
- if (!H || !j)
256
- return;
257
- let g = n.touches[0].clientX, N = n.touches[0].clientY, F = H - g, _e = j - N;
258
- Math.abs(F) > Math.abs(_e) && (F > 0 ? B(1) : B(-1)), H = null, j = null;
259
- }, B = (n) => {
260
- n > 0 && !m ? (t(2, u -= i), t(2, u = u < P ? P : u)) : n < 0 && !a && (t(2, u += i), t(2, u = u > 0 ? 0 : u));
261
- }, X = (n) => {
262
- window.postMessage(
263
- {
264
- type: "TournamentGameAction",
265
- gameId: n.id,
266
- name: n.name,
267
- launchUrl: n.launchUrl
268
- },
269
- window.location.href
270
- );
271
- }, se = () => {
272
- let n = new URL(p), g = new Headers();
273
- n.searchParams.append("expand", "games"), n.searchParams.append("pagination", `games(limit=${Ue},offset=${u})`), n.searchParams.append("fields", "games(id,name,thumbnail,launchUrl)"), n.searchParams.append("language", w), n.searchParams.append("platform", Ce(b)), fetch(n, { method: "GET", headers: g }).then((F) => F.json()).then((F) => {
274
- t(1, k = F.item.games.items), F.item.games.total;
275
- });
276
- }, re = () => {
277
- h.addEventListener("touchstart", O, { passive: !0 }), h.addEventListener("touchmove", R, { passive: !0 });
278
- }, ae = () => {
279
- setTimeout(
280
- () => {
281
- t(22, P = (E.scrollWidth - E.clientWidth) * -1), t(16, r = new String(E.scrollWidth / k.length)), i = parseInt(y, 10) * parseFloat(r, 2).toFixed(2);
282
- },
283
- 1e3
284
- );
285
- }, ie = () => {
286
- let n = document.createElement("style");
287
- n.innerHTML = f, s.appendChild(n);
288
- }, oe = () => {
289
- let n = new URL(o), g = document.createElement("style");
290
- fetch(n.href).then((N) => N.text()).then((N) => {
291
- g.innerHTML = N, setTimeout(
292
- () => {
293
- s.appendChild(g);
294
- },
295
- 1
296
- ), setTimeout(
297
- () => {
298
- },
299
- 500
300
- );
301
- });
302
- }, ce = () => {
303
- T > 0 && T < Math.floor((parseInt(y) + 1) * r) && t(15, y = Math.ceil(T / r).toString());
304
- };
305
- Fe(() => (i = parseInt(y, 10) * parseInt(r, 10), () => {
306
- h.removeEventListener("touchstart", O), h.removeEventListener("touchmove", R);
307
- }));
308
- const ue = () => B(-1), me = (n) => X(n), de = (n) => W(n), he = () => q();
309
- function fe(n) {
310
- D[n ? "unshift" : "push"](() => {
311
- E = n, t(7, E);
312
- });
313
- }
314
- function ge() {
315
- T = this.clientWidth, t(4, T);
316
- }
317
- const pe = () => B(1);
318
- function ye(n) {
319
- D[n ? "unshift" : "push"](() => {
320
- h = n, t(3, h);
321
- });
322
- }
323
- function we(n) {
324
- D[n ? "unshift" : "push"](() => {
325
- s = n, t(0, s);
326
- });
327
- }
328
- return e.$$set = (n) => {
329
- "tournamenturl" in n && t(17, p = n.tournamenturl), "scrollby" in n && t(15, y = n.scrollby), "pagfactor" in n && t(16, r = n.pagfactor), "lang" in n && t(18, w = n.lang), "translationurl" in n && t(19, _ = n.translationurl), "clientstyling" in n && t(20, f = n.clientstyling), "clientstylingurl" in n && t(21, o = n.clientstylingurl);
330
- }, e.$$.update = () => {
331
- e.$$.dirty[0] & /*offset*/
332
- 4 && t(8, a = u === 0), e.$$.dirty[0] & /*offset, gamesElementWidth*/
333
- 4194308 && t(9, m = u <= P), e.$$.dirty[0] & /*sliderMainWidth*/
334
- 16 && T && ce(), e.$$.dirty[0] & /*tournamenturl*/
335
- 131072 && p && se(), e.$$.dirty[0] & /*slider*/
336
- 8 && h && re(), e.$$.dirty[0] & /*translationurl*/
337
- 524288 && _ && ne(), e.$$.dirty[0] & /*games*/
338
- 2 && k.length && ae(), e.$$.dirty[0] & /*clientstyling, customStylingContainer*/
339
- 1048577 && f && s && ie(), e.$$.dirty[0] & /*clientstylingurl, customStylingContainer*/
340
- 2097153 && o && s && oe();
341
- }, t(2, u = 0), [
342
- s,
343
- k,
344
- u,
345
- h,
346
- T,
347
- A,
348
- U,
349
- E,
350
- a,
351
- m,
352
- d,
353
- W,
354
- q,
355
- B,
356
- X,
357
- y,
358
- r,
359
- p,
360
- w,
361
- _,
362
- f,
363
- o,
364
- P,
365
- ue,
366
- me,
367
- de,
368
- he,
369
- fe,
370
- ge,
371
- pe,
372
- ye,
373
- we
374
- ];
375
- }
376
- class Ge extends ve {
377
- constructor(l) {
378
- super(), ke(
379
- this,
380
- l,
381
- De,
382
- Ae,
383
- Ne,
384
- {
385
- tournamenturl: 17,
386
- scrollby: 15,
387
- pagfactor: 16,
388
- lang: 18,
389
- translationurl: 19,
390
- clientstyling: 20,
391
- clientstylingurl: 21
392
- },
393
- ze,
394
- [-1, -1]
395
- );
396
- }
397
- get tournamenturl() {
398
- return this.$$.ctx[17];
399
- }
400
- set tournamenturl(l) {
401
- this.$$set({ tournamenturl: l }), M();
402
- }
403
- get scrollby() {
404
- return this.$$.ctx[15];
405
- }
406
- set scrollby(l) {
407
- this.$$set({ scrollby: l }), M();
408
- }
409
- get pagfactor() {
410
- return this.$$.ctx[16];
411
- }
412
- set pagfactor(l) {
413
- this.$$set({ pagfactor: l }), M();
414
- }
415
- get lang() {
416
- return this.$$.ctx[18];
417
- }
418
- set lang(l) {
419
- this.$$set({ lang: l }), M();
420
- }
421
- get translationurl() {
422
- return this.$$.ctx[19];
423
- }
424
- set translationurl(l) {
425
- this.$$set({ translationurl: l }), M();
426
- }
427
- get clientstyling() {
428
- return this.$$.ctx[20];
429
- }
430
- set clientstyling(l) {
431
- this.$$set({ clientstyling: l }), M();
432
- }
433
- get clientstylingurl() {
434
- return this.$$.ctx[21];
435
- }
436
- set clientstylingurl(l) {
437
- this.$$set({ clientstylingurl: l }), M();
438
- }
439
- }
440
- He(Ge, { tournamenturl: {}, scrollby: {}, pagfactor: {}, lang: {}, translationurl: {}, clientstyling: {}, clientstylingurl: {} }, [], [], !0);
441
- export {
442
- Ge as default
443
- };