@everymatrix/casino-categories-providers 1.45.0 → 1.45.2

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,485 @@
1
+ import { a as Q, $ as W, S as X, i as Y, f as z, c as Z, s as $, b as ee, e as k, g as v, j as C, n as I, o as O, p as te, q as re, v as N, t as E, d as T, w as le, k as c, m as M, x as R, y as V, l as J, u as ie } from "./CasinoCategories-CwdPhfH2.js";
2
+ const U = {
3
+ en: {
4
+ popularProviders: "Popular Suppliers",
5
+ otherProviders: "Other Suppliers",
6
+ loading: "Loading, please wait...",
7
+ games: "games"
8
+ },
9
+ "zh-hk": {
10
+ popularProviders: "热门供应商",
11
+ otherProviders: "其他供应商",
12
+ loading: "加载请稍候...",
13
+ games: "游戏"
14
+ },
15
+ de: {
16
+ popularProviders: "Beliebte Anbieter",
17
+ otherProviders: "Andere Anbieter",
18
+ loading: "Es lädt, bitte warten...",
19
+ games: "Spiele"
20
+ },
21
+ it: {
22
+ popularProviders: "Popular Suppliers",
23
+ otherProviders: "Other Suppliers",
24
+ loading: "Loading, please wait",
25
+ games: "games"
26
+ },
27
+ fr: {
28
+ popularProviders: "Fournisseurs populaires",
29
+ otherProviders: "Autres fournisseurs",
30
+ loading: "Chargement, veuillez patienter...",
31
+ games: "jeux"
32
+ },
33
+ es: {
34
+ popularProviders: "Proveedores Populares",
35
+ otherProviders: "Otros Proveedores",
36
+ loading: "Cargando",
37
+ games: "juegos"
38
+ },
39
+ tr: {
40
+ popularProviders: "Şimdi Oyna",
41
+ otherProviders: "Rastgele oynanacak oyun yok",
42
+ loading: "Son arama",
43
+ games: "Oyunları Ara"
44
+ },
45
+ ru: {
46
+ popularProviders: "Popular Suppliers",
47
+ otherProviders: "Other Suppliers",
48
+ loading: "Loading, please wait",
49
+ games: "games"
50
+ },
51
+ ro: {
52
+ popularProviders: "Furnizori de top",
53
+ otherProviders: "Alti furnizori",
54
+ loading: "Se incarca, te rugam asteapta…",
55
+ games: "jocuri"
56
+ },
57
+ hr: {
58
+ popularProviders: "Popularni brendovi",
59
+ otherProviders: "Ostali brendovi",
60
+ loading: "Učitavanje",
61
+ games: "Igre"
62
+ },
63
+ hu: {
64
+ popularProviders: "Popular Suppliers",
65
+ otherProviders: "Other Suppliers",
66
+ loading: "Loading, please wait",
67
+ games: "games"
68
+ },
69
+ pl: {
70
+ popularProviders: "Popular Suppliers",
71
+ otherProviders: "Other Suppliers",
72
+ loading: "Loading, please wait",
73
+ games: "games"
74
+ },
75
+ pt: {
76
+ popularProviders: "Popular Suppliers",
77
+ otherProviders: "Other Suppliers",
78
+ loading: "Loading, please wait",
79
+ games: "games"
80
+ },
81
+ sl: {
82
+ popularProviders: "Popular Suppliers",
83
+ otherProviders: "Other Suppliers",
84
+ loading: "Loading, please wait",
85
+ games: "games"
86
+ },
87
+ sr: {
88
+ popularProviders: "Popular Suppliers",
89
+ otherProviders: "Other Suppliers",
90
+ loading: "Loading, please wait",
91
+ games: "games"
92
+ },
93
+ "pt-br": {
94
+ popularProviders: "provedores populares",
95
+ otherProviders: "Outros provedores",
96
+ Loading: "Carregando",
97
+ games: "jogos"
98
+ },
99
+ "es-mx": {
100
+ popularProviders: "Proveedores Populares",
101
+ otherProviders: "Otros proveedores",
102
+ Loading: "Cargando, por favor espere...",
103
+ games: "juegos"
104
+ }
105
+ };
106
+ function q(t, e) {
107
+ Q(t, e);
108
+ }
109
+ function oe(t) {
110
+ W.set(t);
111
+ }
112
+ function se(t) {
113
+ ee(t, "svelte-1gbl7ko", "*,*::before,*::after{margin:0;padding:0;box-sizing:border-box}.CasinoProviders{display:flex;flex-direction:column;gap:1rem;padding:10px 60px}.ProviderTitle{font-weight:500;position:relative;right:30px;margin:10px 0}.Provider{border-radius:7px;display:flex;align-items:center;gap:16px;max-width:300px}.ProviderTextContainer{display:flex;flex-direction:column;justify-content:center;gap:10px;font-size:15px;color:var(--emfe-w-casino-typography, var(--emfe-w-color-white, #FFFFFF))}.ProviderTextContainer p:first-child{font-weight:600;color:var(--emfe-w-casino-typography, var(--emfe-w-color-white, #FFFFFF))}.ProviderTextContainer p:last-child{color:var(--emfe-w-color-gray-150, #828282);font-weight:300}.ProviderImage{border-radius:4px;object-fit:contain;height:64px;width:64px;font-weight:100;border:0.5px solid var(--emfe-w-color-gray-100, #E6E6E6);overflow:hidden;object-fit:contain}.Message{font-weight:600;position:absolute;top:50%;left:50%;transform:translate(-50%, -50%)}");
114
+ }
115
+ function G(t, e, r) {
116
+ const a = t.slice();
117
+ return a[21] = e[r], a;
118
+ }
119
+ function H(t, e, r) {
120
+ const a = t.slice();
121
+ return a[21] = e[r], a;
122
+ }
123
+ function ae(t) {
124
+ let e, r = (
125
+ /*$_*/
126
+ t[4]("popularProviders") + ""
127
+ ), a, s, d, n, P = (
128
+ /*$_*/
129
+ t[4]("otherProviders") + ""
130
+ ), h, _, b, f = N(
131
+ /*topProviders*/
132
+ t[1]
133
+ ), u = [];
134
+ for (let l = 0; l < f.length; l += 1)
135
+ u[l] = B(H(t, f, l));
136
+ let m = N(
137
+ /*otherProviders*/
138
+ t[2]
139
+ ), p = [];
140
+ for (let l = 0; l < m.length; l += 1)
141
+ p[l] = D(G(t, m, l));
142
+ return {
143
+ c() {
144
+ e = k("h4"), a = E(r), s = T();
145
+ for (let l = 0; l < u.length; l += 1)
146
+ u[l].c();
147
+ d = T(), n = k("h4"), h = E(P), _ = T();
148
+ for (let l = 0; l < p.length; l += 1)
149
+ p[l].c();
150
+ b = le(), v(e, "class", "ProviderTitle"), v(n, "class", "ProviderTitle");
151
+ },
152
+ m(l, g) {
153
+ C(l, e, g), c(e, a), C(l, s, g);
154
+ for (let i = 0; i < u.length; i += 1)
155
+ u[i] && u[i].m(l, g);
156
+ C(l, d, g), C(l, n, g), c(n, h), C(l, _, g);
157
+ for (let i = 0; i < p.length; i += 1)
158
+ p[i] && p[i].m(l, g);
159
+ C(l, b, g);
160
+ },
161
+ p(l, g) {
162
+ if (g & /*$_*/
163
+ 16 && r !== (r = /*$_*/
164
+ l[4]("popularProviders") + "") && M(a, r), g & /*openGameProviderPage, topProviders, $_*/
165
+ 50) {
166
+ f = N(
167
+ /*topProviders*/
168
+ l[1]
169
+ );
170
+ let i;
171
+ for (i = 0; i < f.length; i += 1) {
172
+ const S = H(l, f, i);
173
+ u[i] ? u[i].p(S, g) : (u[i] = B(S), u[i].c(), u[i].m(d.parentNode, d));
174
+ }
175
+ for (; i < u.length; i += 1)
176
+ u[i].d(1);
177
+ u.length = f.length;
178
+ }
179
+ if (g & /*$_*/
180
+ 16 && P !== (P = /*$_*/
181
+ l[4]("otherProviders") + "") && M(h, P), g & /*openGameProviderPage, otherProviders, $_*/
182
+ 52) {
183
+ m = N(
184
+ /*otherProviders*/
185
+ l[2]
186
+ );
187
+ let i;
188
+ for (i = 0; i < m.length; i += 1) {
189
+ const S = G(l, m, i);
190
+ p[i] ? p[i].p(S, g) : (p[i] = D(S), p[i].c(), p[i].m(b.parentNode, b));
191
+ }
192
+ for (; i < p.length; i += 1)
193
+ p[i].d(1);
194
+ p.length = m.length;
195
+ }
196
+ },
197
+ d(l) {
198
+ l && (O(e), O(s), O(d), O(n), O(_), O(b)), R(u, l), R(p, l);
199
+ }
200
+ };
201
+ }
202
+ function ne(t) {
203
+ let e, r = (
204
+ /*$_*/
205
+ t[4]("loading") + ""
206
+ ), a;
207
+ return {
208
+ c() {
209
+ e = k("p"), a = E(r), v(e, "class", "Message");
210
+ },
211
+ m(s, d) {
212
+ C(s, e, d), c(e, a);
213
+ },
214
+ p(s, d) {
215
+ d & /*$_*/
216
+ 16 && r !== (r = /*$_*/
217
+ s[4]("loading") + "") && M(a, r);
218
+ },
219
+ d(s) {
220
+ s && O(e);
221
+ }
222
+ };
223
+ }
224
+ function B(t) {
225
+ let e, r, a, s, d, n, P, h = (
226
+ /*provider*/
227
+ t[21].name + ""
228
+ ), _, b, f, u = (
229
+ /*provider*/
230
+ t[21].games.count + ""
231
+ ), m, p, l = (
232
+ /*$_*/
233
+ t[4]("games") + ""
234
+ ), g, i, S;
235
+ function x() {
236
+ return (
237
+ /*click_handler*/
238
+ t[12](
239
+ /*provider*/
240
+ t[21]
241
+ )
242
+ );
243
+ }
244
+ return {
245
+ c() {
246
+ e = k("div"), r = k("img"), d = T(), n = k("div"), P = k("p"), _ = E(h), b = T(), f = k("p"), m = E(u), p = T(), g = E(l), V(r.src, a = /*provider*/
247
+ t[21].logo) || v(r, "src", a), v(r, "alt", s = /*provider*/
248
+ t[21].name), v(r, "class", "ProviderImage"), v(n, "class", "ProviderTextContainer"), v(e, "class", "Provider");
249
+ },
250
+ m(F, y) {
251
+ C(F, e, y), c(e, r), c(e, d), c(e, n), c(n, P), c(P, _), c(n, b), c(n, f), c(f, m), c(f, p), c(f, g), i || (S = J(e, "click", x), i = !0);
252
+ },
253
+ p(F, y) {
254
+ t = F, y & /*topProviders*/
255
+ 2 && !V(r.src, a = /*provider*/
256
+ t[21].logo) && v(r, "src", a), y & /*topProviders*/
257
+ 2 && s !== (s = /*provider*/
258
+ t[21].name) && v(r, "alt", s), y & /*topProviders*/
259
+ 2 && h !== (h = /*provider*/
260
+ t[21].name + "") && M(_, h), y & /*topProviders*/
261
+ 2 && u !== (u = /*provider*/
262
+ t[21].games.count + "") && M(m, u), y & /*$_*/
263
+ 16 && l !== (l = /*$_*/
264
+ t[4]("games") + "") && M(g, l);
265
+ },
266
+ d(F) {
267
+ F && O(e), i = !1, S();
268
+ }
269
+ };
270
+ }
271
+ function D(t) {
272
+ let e, r, a, s, d, n, P, h = (
273
+ /*provider*/
274
+ t[21].name + ""
275
+ ), _, b, f, u = (
276
+ /*provider*/
277
+ t[21].games.count + ""
278
+ ), m, p, l = (
279
+ /*$_*/
280
+ t[4]("games") + ""
281
+ ), g, i, S, x;
282
+ function F() {
283
+ return (
284
+ /*click_handler_1*/
285
+ t[13](
286
+ /*provider*/
287
+ t[21]
288
+ )
289
+ );
290
+ }
291
+ return {
292
+ c() {
293
+ e = k("div"), r = k("img"), d = T(), n = k("div"), P = k("p"), _ = E(h), b = T(), f = k("p"), m = E(u), p = T(), g = E(l), i = T(), V(r.src, a = /*provider*/
294
+ t[21].logo) || v(r, "src", a), v(r, "alt", s = /*provider*/
295
+ t[21].name), v(r, "class", "ProviderImage"), v(n, "class", "ProviderTextContainer"), v(e, "class", "Provider");
296
+ },
297
+ m(y, j) {
298
+ C(y, e, j), c(e, r), c(e, d), c(e, n), c(n, P), c(P, _), c(n, b), c(n, f), c(f, m), c(f, p), c(f, g), c(e, i), S || (x = J(e, "click", F), S = !0);
299
+ },
300
+ p(y, j) {
301
+ t = y, j & /*otherProviders*/
302
+ 4 && !V(r.src, a = /*provider*/
303
+ t[21].logo) && v(r, "src", a), j & /*otherProviders*/
304
+ 4 && s !== (s = /*provider*/
305
+ t[21].name) && v(r, "alt", s), j & /*otherProviders*/
306
+ 4 && h !== (h = /*provider*/
307
+ t[21].name + "") && M(_, h), j & /*otherProviders*/
308
+ 4 && u !== (u = /*provider*/
309
+ t[21].games.count + "") && M(m, u), j & /*$_*/
310
+ 16 && l !== (l = /*$_*/
311
+ t[4]("games") + "") && M(g, l);
312
+ },
313
+ d(y) {
314
+ y && O(e), S = !1, x();
315
+ }
316
+ };
317
+ }
318
+ function de(t) {
319
+ let e;
320
+ function r(d, n) {
321
+ return (
322
+ /*isLoading*/
323
+ d[3] === !0 ? ne : ae
324
+ );
325
+ }
326
+ let a = r(t), s = a(t);
327
+ return {
328
+ c() {
329
+ e = k("div"), s.c(), v(e, "class", "CasinoProviders");
330
+ },
331
+ m(d, n) {
332
+ C(d, e, n), s.m(e, null), t[14](e);
333
+ },
334
+ p(d, [n]) {
335
+ a === (a = r(d)) && s ? s.p(d, n) : (s.d(1), s = a(d), s && (s.c(), s.m(e, null)));
336
+ },
337
+ i: I,
338
+ o: I,
339
+ d(d) {
340
+ d && O(e), s.d(), t[14](null);
341
+ }
342
+ };
343
+ }
344
+ function ue(t, e, r) {
345
+ let a;
346
+ te(t, ie, (o) => r(4, a = o));
347
+ let { endpoint: s = "" } = e, { datasource: d = "" } = e, { lang: n = "en" } = e, { clientstyling: P = "" } = e, { clientstylingurl: h = "" } = e, { translationurl: _ = "" } = e, b = [], f = [], u = [], m = !1, p;
348
+ const l = () => {
349
+ fetch(_).then((w) => w.json()).then((w) => {
350
+ Object.keys(w).forEach((L) => {
351
+ q(L, w[L]);
352
+ });
353
+ }).catch((w) => {
354
+ console.log(w);
355
+ });
356
+ };
357
+ Object.keys(U).forEach((o) => {
358
+ q(o, U[o]);
359
+ });
360
+ const g = () => {
361
+ r(3, m = !0);
362
+ const o = new URL(`${s}/v1/casino/vendors`);
363
+ o.searchParams.append("datasource", d), o.searchParams.append("language", n), o.searchParams.append("fields", "id,name,displayName,subVendors,isTopVendor,logo,games"), fetch(o).then((w) => w.json()).then((w) => {
364
+ r(3, m = !1), b = w.items.map((A) => A), r(1, f = b.filter((A) => A.isTopVendor === !0)), r(2, u = b.filter((A) => A.isTopVendor === !1));
365
+ let L = [];
366
+ L = b.flatMap((A) => A.subVendors), u.push(...L.filter((A) => A.games.count > 0));
367
+ });
368
+ }, i = (o, w, L) => {
369
+ window.postMessage(
370
+ {
371
+ type: "OpenGameProvider",
372
+ providerId: o,
373
+ providerName: w,
374
+ providerLogo: L
375
+ },
376
+ window.location.href
377
+ );
378
+ }, S = () => {
379
+ oe(n);
380
+ }, x = () => {
381
+ let o = document.createElement("style");
382
+ o.innerHTML = P, p.appendChild(o);
383
+ }, F = () => {
384
+ let o = new URL(h), w = document.createElement("style");
385
+ fetch(o.href).then((L) => L.text()).then((L) => {
386
+ w.innerHTML = L, setTimeout(
387
+ () => {
388
+ p.appendChild(w);
389
+ },
390
+ 1
391
+ );
392
+ });
393
+ }, y = (o) => i(o.id, o.name, o.logo), j = (o) => i(o.id, o.name, o.logo);
394
+ function K(o) {
395
+ re[o ? "unshift" : "push"](() => {
396
+ p = o, r(0, p);
397
+ });
398
+ }
399
+ return t.$$set = (o) => {
400
+ "endpoint" in o && r(6, s = o.endpoint), "datasource" in o && r(7, d = o.datasource), "lang" in o && r(8, n = o.lang), "clientstyling" in o && r(9, P = o.clientstyling), "clientstylingurl" in o && r(10, h = o.clientstylingurl), "translationurl" in o && r(11, _ = o.translationurl);
401
+ }, t.$$.update = () => {
402
+ t.$$.dirty & /*endpoint, lang, datasource*/
403
+ 448 && s && n && d && g(), t.$$.dirty & /*lang*/
404
+ 256 && n && S(), t.$$.dirty & /*translationurl*/
405
+ 2048 && _ && l(), t.$$.dirty & /*clientstyling, customStylingContainer*/
406
+ 513 && P && p && x(), t.$$.dirty & /*clientstylingurl, customStylingContainer*/
407
+ 1025 && h && p && F();
408
+ }, [
409
+ p,
410
+ f,
411
+ u,
412
+ m,
413
+ a,
414
+ i,
415
+ s,
416
+ d,
417
+ n,
418
+ P,
419
+ h,
420
+ _,
421
+ y,
422
+ j,
423
+ K
424
+ ];
425
+ }
426
+ class pe extends X {
427
+ constructor(e) {
428
+ super(), Y(
429
+ this,
430
+ e,
431
+ ue,
432
+ de,
433
+ $,
434
+ {
435
+ endpoint: 6,
436
+ datasource: 7,
437
+ lang: 8,
438
+ clientstyling: 9,
439
+ clientstylingurl: 10,
440
+ translationurl: 11
441
+ },
442
+ se
443
+ );
444
+ }
445
+ get endpoint() {
446
+ return this.$$.ctx[6];
447
+ }
448
+ set endpoint(e) {
449
+ this.$$set({ endpoint: e }), z();
450
+ }
451
+ get datasource() {
452
+ return this.$$.ctx[7];
453
+ }
454
+ set datasource(e) {
455
+ this.$$set({ datasource: e }), z();
456
+ }
457
+ get lang() {
458
+ return this.$$.ctx[8];
459
+ }
460
+ set lang(e) {
461
+ this.$$set({ lang: e }), z();
462
+ }
463
+ get clientstyling() {
464
+ return this.$$.ctx[9];
465
+ }
466
+ set clientstyling(e) {
467
+ this.$$set({ clientstyling: e }), z();
468
+ }
469
+ get clientstylingurl() {
470
+ return this.$$.ctx[10];
471
+ }
472
+ set clientstylingurl(e) {
473
+ this.$$set({ clientstylingurl: e }), z();
474
+ }
475
+ get translationurl() {
476
+ return this.$$.ctx[11];
477
+ }
478
+ set translationurl(e) {
479
+ this.$$set({ translationurl: e }), z();
480
+ }
481
+ }
482
+ Z(pe, { endpoint: {}, datasource: {}, lang: {}, clientstyling: {}, clientstylingurl: {}, translationurl: {} }, [], [], !0);
483
+ export {
484
+ pe as default
485
+ };
@@ -1 +1 @@
1
- "use strict";if(typeof window!="undefined"){let s=function(t){return function(...n){try{return t.apply(this,n)}catch(e){if(e instanceof DOMException&&e.message.includes("has already been used with this registry")||e.message.includes("Cannot define multiple custom elements with the same tag name"))return!1;throw e}}};customElements.define=s(customElements.define),Promise.resolve().then(()=>require("../components/CasinoCategoriesProviders-B3uizcLb.cjs")).then(({default:t})=>{!customElements.get("casino-categories-providers")&&customElements.define("casino-categories-providers",t.element)})}
1
+ "use strict";if(typeof window!="undefined"){let s=function(t){return function(...n){try{return t.apply(this,n)}catch(e){if(e instanceof DOMException&&e.message.includes("has already been used with this registry")||e.message.includes("Cannot define multiple custom elements with the same tag name"))return!1;throw e}}};customElements.define=s(customElements.define),Promise.resolve().then(()=>require("../components/CasinoCategoriesProviders-zR-DXryv.cjs")).then(({default:t})=>{!customElements.get("casino-categories-providers")&&customElements.define("casino-categories-providers",t.element)})}
@@ -10,7 +10,7 @@ if (typeof window != "undefined") {
10
10
  }
11
11
  };
12
12
  };
13
- customElements.define = n(customElements.define), import("../components/CasinoCategoriesProviders-Dc9YZZFb.js").then(({ default: t }) => {
13
+ customElements.define = n(customElements.define), import("../components/CasinoCategoriesProviders-Ilq2cPiO.js").then(({ default: t }) => {
14
14
  !customElements.get("casino-categories-providers") && customElements.define("casino-categories-providers", t.element);
15
15
  });
16
16
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@everymatrix/casino-categories-providers",
3
- "version": "1.45.0",
3
+ "version": "1.45.2",
4
4
  "type": "module",
5
5
  "main": "es2015/casino-categories-providers.cjs",
6
6
  "module": "es2015/casino-categories-providers.js",
@@ -11,7 +11,7 @@
11
11
  },
12
12
  "./es2015/casino-categories-providers.cjs": "./es2015/casino-categories-providers.cjs"
13
13
  },
14
- "files": [
14
+ "files": [
15
15
  "es2015/",
16
16
  "components"
17
17
  ],