@everymatrix/casino-categories-providers 1.87.26 → 1.87.28

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,507 @@
1
+ import { a as ee, $ as te, S as ae, i as ie, s as oe, f as x, b as se, n as P, d as I, c as K, e as b, g as re, o as le, h as ne, j, k as U, l as D, m as S, p as c, t as E, q as O, r as q, u as L, v as W, w as ge, x as ce, y as ue, z as de, A as he } from "./CasinoCategoriesProviders-BjN4wQLw.js";
2
+ import "../stencil/ui-image-CP8Lp7fB.js";
3
+ function Y(t, e) {
4
+ ee(t, e);
5
+ }
6
+ function fe(t) {
7
+ te.set(t);
8
+ }
9
+ const B = {
10
+ en: {
11
+ topCategories: "Top Categories",
12
+ otherCategories: "Other Categories",
13
+ loading: "Loading, please wait...",
14
+ games: "games"
15
+ },
16
+ "zh-hk": {
17
+ topCategories: "热门类别",
18
+ otherCategories: "其他类别",
19
+ loading: "加载请稍候...",
20
+ games: "游戏"
21
+ },
22
+ de: {
23
+ topCategories: "Top Kategorien",
24
+ otherCategories: "Andere Kategorien",
25
+ loading: "Es lädt, bitte warten...",
26
+ games: "Spiele"
27
+ },
28
+ it: {
29
+ topCategories: "Top Categories",
30
+ otherCategories: "Other Categories",
31
+ loading: "Loading, please wait...",
32
+ games: "games"
33
+ },
34
+ fr: {
35
+ topCategories: "Catégories principales",
36
+ otherCategories: "Autres catégories",
37
+ loading: "Chargement, veuillez patienter...",
38
+ games: "jeux"
39
+ },
40
+ es: {
41
+ topCategories: "Categorias Top",
42
+ otherCategories: "Otras Categorias",
43
+ loading: "Cargando...",
44
+ games: "juegos"
45
+ },
46
+ tr: {
47
+ topCategories: "En İyi Kategoriler",
48
+ otherCategories: "Diğer Kategoriler",
49
+ loading: "Yükleniyor, lütfen bekleyin...",
50
+ games: "oyunlar"
51
+ },
52
+ ru: {
53
+ topCategories: "Top Categories",
54
+ otherCategories: "Other Categories",
55
+ loading: "Loading, please wait...",
56
+ games: "games"
57
+ },
58
+ ro: {
59
+ topCategories: "Categorii de top",
60
+ otherCategories: "Alte categorii",
61
+ loading: "Se incarca, te rugam asteapta…",
62
+ games: "jocuri"
63
+ },
64
+ hr: {
65
+ topCategories: "Najbolje kategorije",
66
+ otherCategories: "Ostale kategorije",
67
+ loading: "Učitavam",
68
+ games: "Igre"
69
+ },
70
+ hu: {
71
+ topCategories: "Top Categories",
72
+ otherCategories: "Other Categories",
73
+ loading: "Loading, please wait...",
74
+ games: "games"
75
+ },
76
+ pl: {
77
+ topCategories: "Top Categories",
78
+ otherCategories: "Other Categories",
79
+ loading: "Loading, please wait...",
80
+ games: "games"
81
+ },
82
+ pt: {
83
+ topCategories: "Top Categories",
84
+ otherCategories: "Other Categories",
85
+ loading: "Loading, please wait...",
86
+ games: "games"
87
+ },
88
+ sl: {
89
+ topCategories: "Top Categories",
90
+ otherCategories: "Other Categories",
91
+ loading: "Loading, please wait...",
92
+ games: "games"
93
+ },
94
+ sr: {
95
+ topCategories: "Top Categories",
96
+ otherCategories: "Other Categories",
97
+ loading: "Loading, please wait...",
98
+ games: "games"
99
+ },
100
+ "pt-br": {
101
+ topCategories: "Categorias Principais",
102
+ otherCategories: "Outras Categorias",
103
+ Loading: "Carregando, por favor espere...",
104
+ games: "jogos"
105
+ },
106
+ "es-mx": {
107
+ topCategories: "Categorias Principales",
108
+ otherCategories: "Otras Categorias",
109
+ Loading: "Cargando, por favor espere...",
110
+ games: "juegos"
111
+ },
112
+ "en-us": {
113
+ topCategories: "Top Categories",
114
+ otherCategories: "Other Categories",
115
+ loading: "Loading, please wait...",
116
+ games: "games"
117
+ }
118
+ };
119
+ function me(t) {
120
+ se(t, "svelte-2l182v", "*,*::before,*::after{margin:0;padding:0;box-sizing:border-box;font-family:inherit}.CasinoCategories{display:flex;flex-direction:column;gap:1rem;padding:10px 60px}.CategoryTitle{font-weight:500;position:relative;right:30px;margin:10px 0;font-size:18px;color:var(--emw--casino-typography, var(--emw--color-white, #FFFFFF))}.Category{border-radius:7px;display:flex;align-items:center;gap:16px;max-width:300px}.Category.Active{box-shadow:15px 15px 30px var(--emw--color-gray-100, #E6E6E6)}.CategoryTextContainer{display:flex;flex-direction:column;justify-content:center;gap:10px;font-size:15px;color:var(--emw--casino-typography, var(--emw--color-white, #FFFFFF))}.CategoryTextContainer p:first-child{font-weight:600;color:var(--emw--casino-typography, var(--emw--color-white, #FFFFFF))}.CategoryTextContainer p:last-child{color:var(--emw--color-gray-150, #828282);font-weight:300}.CategoryImage{border-radius:4px;object-fit:cover;height:64px;width:64px;font-weight:100}.Message{position:absolute;top:50%;left:50%;transform:translate(-50%, -50%);font-weight:600}");
121
+ }
122
+ function H(t, e, a) {
123
+ const r = t.slice();
124
+ return r[23] = e[a], r;
125
+ }
126
+ function J(t, e, a) {
127
+ const r = t.slice();
128
+ return r[23] = e[a], r;
129
+ }
130
+ function Ce(t) {
131
+ let e, a, r = (
132
+ /*$_*/
133
+ t[5]("topCategories") + ""
134
+ ), n, d, g, v, C = (
135
+ /*$_*/
136
+ t[5]("otherCategories") + ""
137
+ ), _, w, h = U(
138
+ /*topCategories*/
139
+ t[3]
140
+ ), l = [];
141
+ for (let o = 0; o < h.length; o += 1)
142
+ l[o] = Q(J(t, h, o));
143
+ let u = U(
144
+ /*otherCategories*/
145
+ t[4]
146
+ ), f = [];
147
+ for (let o = 0; o < u.length; o += 1)
148
+ f[o] = V(H(t, u, o));
149
+ return {
150
+ c() {
151
+ e = b("div"), a = b("h4"), n = E(r), d = O();
152
+ for (let o = 0; o < l.length; o += 1)
153
+ l[o].c();
154
+ g = O(), v = b("h4"), _ = E(C), w = O();
155
+ for (let o = 0; o < f.length; o += 1)
156
+ f[o].c();
157
+ j(a, "class", "CategoryTitle"), j(v, "class", "CategoryTitle"), j(e, "class", "CasinoCategories");
158
+ },
159
+ m(o, m) {
160
+ K(o, e, m), c(e, a), c(a, n), c(e, d);
161
+ for (let i = 0; i < l.length; i += 1)
162
+ l[i] && l[i].m(e, null);
163
+ c(e, g), c(e, v), c(v, _), c(e, w);
164
+ for (let i = 0; i < f.length; i += 1)
165
+ f[i] && f[i].m(e, null);
166
+ },
167
+ p(o, m) {
168
+ if (m & /*$_*/
169
+ 32 && r !== (r = /*$_*/
170
+ o[5]("topCategories") + "") && S(n, r), m & /*activecategory, topCategories, openGameCategory, $_*/
171
+ 105) {
172
+ h = U(
173
+ /*topCategories*/
174
+ o[3]
175
+ );
176
+ let i;
177
+ for (i = 0; i < h.length; i += 1) {
178
+ const p = J(o, h, i);
179
+ l[i] ? l[i].p(p, m) : (l[i] = Q(p), l[i].c(), l[i].m(e, g));
180
+ }
181
+ for (; i < l.length; i += 1)
182
+ l[i].d(1);
183
+ l.length = h.length;
184
+ }
185
+ if (m & /*$_*/
186
+ 32 && C !== (C = /*$_*/
187
+ o[5]("otherCategories") + "") && S(_, C), m & /*activecategory, otherCategories, openGameCategory, $_*/
188
+ 113) {
189
+ u = U(
190
+ /*otherCategories*/
191
+ o[4]
192
+ );
193
+ let i;
194
+ for (i = 0; i < u.length; i += 1) {
195
+ const p = H(o, u, i);
196
+ f[i] ? f[i].p(p, m) : (f[i] = V(p), f[i].c(), f[i].m(e, null));
197
+ }
198
+ for (; i < f.length; i += 1)
199
+ f[i].d(1);
200
+ f.length = u.length;
201
+ }
202
+ },
203
+ d(o) {
204
+ o && I(e), D(l, o), D(f, o);
205
+ }
206
+ };
207
+ }
208
+ function pe(t) {
209
+ let e;
210
+ return {
211
+ c() {
212
+ e = b("p"), e.textContent = "Loading, please wait...", j(e, "class", "Message");
213
+ },
214
+ m(a, r) {
215
+ K(a, e, r);
216
+ },
217
+ p: P,
218
+ d(a) {
219
+ a && I(e);
220
+ }
221
+ };
222
+ }
223
+ function Q(t) {
224
+ let e, a, r, n, d, g, v, C = (
225
+ /*category*/
226
+ t[23].name + ""
227
+ ), _, w, h, l = (
228
+ /*category*/
229
+ t[23].games.count + ""
230
+ ), u, f, o = (
231
+ /*$_*/
232
+ t[5]("games") + ""
233
+ ), m, i, p, A;
234
+ function M() {
235
+ return (
236
+ /*click_handler*/
237
+ t[15](
238
+ /*category*/
239
+ t[23]
240
+ )
241
+ );
242
+ }
243
+ return {
244
+ c() {
245
+ e = b("div"), a = b("ui-image"), d = O(), g = b("div"), v = b("p"), _ = E(C), w = O(), h = b("p"), u = E(l), f = O(), m = E(o), q(a.src, r = /*category*/
246
+ t[23].icon) || L(a, "src", r), L(a, "alt", n = /*category*/
247
+ t[23].name), L(a, "class", "CategoryImage"), j(g, "class", "CategoryTextContainer"), j(e, "class", i = "Category " + /*activecategory*/
248
+ (t[0] === /*category*/
249
+ t[23].id ? "Active" : ""));
250
+ },
251
+ m(k, y) {
252
+ K(k, e, y), c(e, a), c(e, d), c(e, g), c(g, v), c(v, _), c(g, w), c(g, h), c(h, u), c(h, f), c(h, m), p || (A = W(e, "click", M), p = !0);
253
+ },
254
+ p(k, y) {
255
+ t = k, y & /*topCategories*/
256
+ 8 && !q(a.src, r = /*category*/
257
+ t[23].icon) && L(a, "src", r), y & /*topCategories*/
258
+ 8 && n !== (n = /*category*/
259
+ t[23].name) && L(a, "alt", n), y & /*topCategories*/
260
+ 8 && C !== (C = /*category*/
261
+ t[23].name + "") && S(_, C), y & /*topCategories*/
262
+ 8 && l !== (l = /*category*/
263
+ t[23].games.count + "") && S(u, l), y & /*$_*/
264
+ 32 && o !== (o = /*$_*/
265
+ t[5]("games") + "") && S(m, o), y & /*activecategory, topCategories*/
266
+ 9 && i !== (i = "Category " + /*activecategory*/
267
+ (t[0] === /*category*/
268
+ t[23].id ? "Active" : "")) && j(e, "class", i);
269
+ },
270
+ d(k) {
271
+ k && I(e), p = !1, A();
272
+ }
273
+ };
274
+ }
275
+ function V(t) {
276
+ let e, a, r, n, d, g, v, C = (
277
+ /*category*/
278
+ t[23].name + ""
279
+ ), _, w, h, l = (
280
+ /*category*/
281
+ t[23].games.count + ""
282
+ ), u, f, o = (
283
+ /*$_*/
284
+ t[5]("games") + ""
285
+ ), m, i, p, A, M;
286
+ function k() {
287
+ return (
288
+ /*click_handler_1*/
289
+ t[16](
290
+ /*category*/
291
+ t[23]
292
+ )
293
+ );
294
+ }
295
+ return {
296
+ c() {
297
+ e = b("div"), a = b("ui-image"), d = O(), g = b("div"), v = b("p"), _ = E(C), w = O(), h = b("p"), u = E(l), f = O(), m = E(o), i = O(), q(a.src, r = /*category*/
298
+ t[23].icon) || L(a, "src", r), L(a, "alt", n = /*category*/
299
+ t[23].name), L(a, "class", "CategoryImage"), j(g, "class", "CategoryTextContainer"), j(e, "class", p = "Category " + /*activecategory*/
300
+ (t[0] === /*category*/
301
+ t[23].id ? "Active" : ""));
302
+ },
303
+ m(y, T) {
304
+ K(y, e, T), c(e, a), c(e, d), c(e, g), c(g, v), c(v, _), c(g, w), c(g, h), c(h, u), c(h, f), c(h, m), c(e, i), A || (M = W(e, "click", k), A = !0);
305
+ },
306
+ p(y, T) {
307
+ t = y, T & /*otherCategories*/
308
+ 16 && !q(a.src, r = /*category*/
309
+ t[23].icon) && L(a, "src", r), T & /*otherCategories*/
310
+ 16 && n !== (n = /*category*/
311
+ t[23].name) && L(a, "alt", n), T & /*otherCategories*/
312
+ 16 && C !== (C = /*category*/
313
+ t[23].name + "") && S(_, C), T & /*otherCategories*/
314
+ 16 && l !== (l = /*category*/
315
+ t[23].games.count + "") && S(u, l), T & /*$_*/
316
+ 32 && o !== (o = /*$_*/
317
+ t[5]("games") + "") && S(m, o), T & /*activecategory, otherCategories*/
318
+ 17 && p !== (p = "Category " + /*activecategory*/
319
+ (t[0] === /*category*/
320
+ t[23].id ? "Active" : "")) && j(e, "class", p);
321
+ },
322
+ d(y) {
323
+ y && I(e), A = !1, M();
324
+ }
325
+ };
326
+ }
327
+ function _e(t) {
328
+ let e;
329
+ function a(d, g) {
330
+ return (
331
+ /*isLoading*/
332
+ d[2] ? pe : Ce
333
+ );
334
+ }
335
+ let r = a(t), n = r(t);
336
+ return {
337
+ c() {
338
+ e = b("div"), n.c();
339
+ },
340
+ m(d, g) {
341
+ K(d, e, g), n.m(e, null), t[17](e);
342
+ },
343
+ p(d, [g]) {
344
+ r === (r = a(d)) && n ? n.p(d, g) : (n.d(1), n = r(d), n && (n.c(), n.m(e, null)));
345
+ },
346
+ i: P,
347
+ o: P,
348
+ d(d) {
349
+ d && I(e), n.d(), t[17](null);
350
+ }
351
+ };
352
+ }
353
+ function ye(t, e, a) {
354
+ let r;
355
+ re(t, he, (s) => a(5, r = s));
356
+ let { endpoint: n = "" } = e, { datasource: d = "" } = e, { lang: g = "en" } = e, { activecategory: v = "" } = e, { excludedflags: C = "" } = e, { clientstyling: _ = "" } = e, { clientstylingurl: w = "" } = e, { translationurl: h = "" } = e, { mbsource: l } = e, u, f, o = !1;
357
+ const m = [];
358
+ let i = [], p = [];
359
+ Object.keys(B).forEach((s) => {
360
+ Y(s, B[s]);
361
+ });
362
+ const A = () => {
363
+ fetch(h).then((F) => F.json()).then((F) => {
364
+ Object.keys(F).forEach((N) => {
365
+ Y(N, F[N]);
366
+ });
367
+ }).catch((F) => {
368
+ console.log(F);
369
+ });
370
+ }, M = () => {
371
+ a(2, o = !0);
372
+ const s = new URL(`${n}/v1/casino/groups/${d}`);
373
+ s.searchParams.append("language", g), fetch(s).then((F) => F.json()).then((F) => {
374
+ a(2, o = !1);
375
+ const N = C.split(",").map((z) => z.trim());
376
+ m.push(...F.items);
377
+ const R = m.filter((z) => !N.some(($) => {
378
+ var G;
379
+ return ((G = z.flags) == null ? void 0 : G.indexOf($)) >= 0;
380
+ }));
381
+ a(3, i = R.filter((z) => z.isTopCategory === !0)), a(4, p = R.filter((z) => z.isTopCategory === !1));
382
+ });
383
+ }, k = (s) => {
384
+ window.postMessage({ type: "OpenGameCategory", categoryId: s }, window.location.href);
385
+ }, y = () => {
386
+ fe(g);
387
+ };
388
+ le(() => () => {
389
+ });
390
+ const T = (s) => k(s.id), X = (s) => k(s.id);
391
+ function Z(s) {
392
+ ne[s ? "unshift" : "push"](() => {
393
+ u = s, a(1, u);
394
+ });
395
+ }
396
+ return t.$$set = (s) => {
397
+ "endpoint" in s && a(7, n = s.endpoint), "datasource" in s && a(8, d = s.datasource), "lang" in s && a(9, g = s.lang), "activecategory" in s && a(0, v = s.activecategory), "excludedflags" in s && a(10, C = s.excludedflags), "clientstyling" in s && a(11, _ = s.clientstyling), "clientstylingurl" in s && a(12, w = s.clientstylingurl), "translationurl" in s && a(13, h = s.translationurl), "mbsource" in s && a(14, l = s.mbsource);
398
+ }, t.$$.update = () => {
399
+ t.$$.dirty & /*endpoint, datasource*/
400
+ 384 && n && d && M(), t.$$.dirty & /*translationurl*/
401
+ 8192 && h && A(), t.$$.dirty & /*lang*/
402
+ 512 && g && y(), t.$$.dirty & /*clientstyling, customStylingContainer*/
403
+ 2050 && _ && u && ge(u, _), t.$$.dirty & /*clientstylingurl, customStylingContainer*/
404
+ 4098 && w && u && ce(u, w), t.$$.dirty & /*mbsource, customStylingContainer*/
405
+ 16386 && l && u && ue(u, `${l}.Style`, f);
406
+ }, [
407
+ v,
408
+ u,
409
+ o,
410
+ i,
411
+ p,
412
+ r,
413
+ k,
414
+ n,
415
+ d,
416
+ g,
417
+ C,
418
+ _,
419
+ w,
420
+ h,
421
+ l,
422
+ T,
423
+ X,
424
+ Z
425
+ ];
426
+ }
427
+ class ve extends ae {
428
+ constructor(e) {
429
+ super(), ie(
430
+ this,
431
+ e,
432
+ ye,
433
+ _e,
434
+ oe,
435
+ {
436
+ endpoint: 7,
437
+ datasource: 8,
438
+ lang: 9,
439
+ activecategory: 0,
440
+ excludedflags: 10,
441
+ clientstyling: 11,
442
+ clientstylingurl: 12,
443
+ translationurl: 13,
444
+ mbsource: 14
445
+ },
446
+ me
447
+ );
448
+ }
449
+ get endpoint() {
450
+ return this.$$.ctx[7];
451
+ }
452
+ set endpoint(e) {
453
+ this.$$set({ endpoint: e }), x();
454
+ }
455
+ get datasource() {
456
+ return this.$$.ctx[8];
457
+ }
458
+ set datasource(e) {
459
+ this.$$set({ datasource: e }), x();
460
+ }
461
+ get lang() {
462
+ return this.$$.ctx[9];
463
+ }
464
+ set lang(e) {
465
+ this.$$set({ lang: e }), x();
466
+ }
467
+ get activecategory() {
468
+ return this.$$.ctx[0];
469
+ }
470
+ set activecategory(e) {
471
+ this.$$set({ activecategory: e }), x();
472
+ }
473
+ get excludedflags() {
474
+ return this.$$.ctx[10];
475
+ }
476
+ set excludedflags(e) {
477
+ this.$$set({ excludedflags: e }), x();
478
+ }
479
+ get clientstyling() {
480
+ return this.$$.ctx[11];
481
+ }
482
+ set clientstyling(e) {
483
+ this.$$set({ clientstyling: e }), x();
484
+ }
485
+ get clientstylingurl() {
486
+ return this.$$.ctx[12];
487
+ }
488
+ set clientstylingurl(e) {
489
+ this.$$set({ clientstylingurl: e }), x();
490
+ }
491
+ get translationurl() {
492
+ return this.$$.ctx[13];
493
+ }
494
+ set translationurl(e) {
495
+ this.$$set({ translationurl: e }), x();
496
+ }
497
+ get mbsource() {
498
+ return this.$$.ctx[14];
499
+ }
500
+ set mbsource(e) {
501
+ this.$$set({ mbsource: e }), x();
502
+ }
503
+ }
504
+ de(ve, { endpoint: {}, datasource: {}, lang: {}, activecategory: {}, excludedflags: {}, clientstyling: {}, clientstylingurl: {}, translationurl: {}, mbsource: {} }, [], [], !0);
505
+ export {
506
+ ve as default
507
+ };