@everymatrix/casino-tournament-prizes 1.44.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.
Files changed (48) hide show
  1. package/dist/casino-tournament-prizes/casino-tournament-prizes.esm.js +1 -1
  2. package/dist/casino-tournament-prizes/p-52494b9c.js +2 -0
  3. package/dist/casino-tournament-prizes/p-9274e610.entry.js +1 -0
  4. package/dist/casino-tournament-prizes/p-e1255160.js +1 -0
  5. package/dist/cjs/app-globals-3a1e7e63.js +5 -0
  6. package/dist/cjs/casino-tournament-prizes.cjs.entry.js +159 -153
  7. package/dist/cjs/casino-tournament-prizes.cjs.js +16 -10
  8. package/dist/cjs/index-c53c7832.js +1234 -0
  9. package/dist/cjs/loader.cjs.js +6 -12
  10. package/dist/collection/collection-manifest.json +3 -3
  11. package/dist/collection/components/casino-tournament-prizes/casino-tournament-prizes.js +295 -309
  12. package/dist/collection/components/casino-tournament-prizes/index.js +1 -0
  13. package/dist/collection/utils/locale.utils.js +53 -53
  14. package/dist/collection/utils/utils.js +1 -1
  15. package/dist/esm/app-globals-0f993ce5.js +3 -0
  16. package/dist/esm/casino-tournament-prizes.entry.js +159 -153
  17. package/dist/esm/casino-tournament-prizes.js +13 -10
  18. package/dist/esm/index-7e63d638.js +1207 -0
  19. package/dist/esm/loader.js +6 -12
  20. package/dist/stencil.config.dev.js +17 -0
  21. package/dist/stencil.config.js +14 -19
  22. package/dist/types/Users/adrian.pripon/Documents/Work/widgets-monorepo/packages/stencil/casino-tournament-prizes/.stencil/packages/stencil/casino-tournament-prizes/stencil.config.d.ts +2 -0
  23. package/dist/types/Users/adrian.pripon/Documents/Work/widgets-monorepo/packages/stencil/casino-tournament-prizes/.stencil/packages/stencil/casino-tournament-prizes/stencil.config.dev.d.ts +2 -0
  24. package/dist/types/components/casino-tournament-prizes/casino-tournament-prizes.d.ts +22 -22
  25. package/dist/types/components/casino-tournament-prizes/index.d.ts +1 -0
  26. package/dist/types/stencil-public-runtime.d.ts +142 -33
  27. package/loader/cdn.js +1 -3
  28. package/loader/index.cjs.js +1 -3
  29. package/loader/index.d.ts +13 -1
  30. package/loader/index.es2017.js +1 -3
  31. package/loader/index.js +1 -3
  32. package/loader/package.json +1 -0
  33. package/package.json +8 -1
  34. package/dist/casino-tournament-prizes/p-0c9dcd23.entry.js +0 -1
  35. package/dist/casino-tournament-prizes/p-44cdb103.js +0 -1
  36. package/dist/cjs/index-edbd2afe.js +0 -1195
  37. package/dist/components/casino-tournament-prizes.d.ts +0 -11
  38. package/dist/components/casino-tournament-prizes.js +0 -205
  39. package/dist/components/index.d.ts +0 -26
  40. package/dist/components/index.js +0 -1
  41. package/dist/esm/index-fd6b56d4.js +0 -1169
  42. package/dist/esm/polyfills/core-js.js +0 -11
  43. package/dist/esm/polyfills/css-shim.js +0 -1
  44. package/dist/esm/polyfills/dom.js +0 -79
  45. package/dist/esm/polyfills/es5-html-element.js +0 -1
  46. package/dist/esm/polyfills/index.js +0 -34
  47. package/dist/esm/polyfills/system.js +0 -6
  48. package/dist/types/Users/adrian.pripon/Documents/Work/widgets-stencil/packages/casino-tournament-prizes/.stencil/packages/casino-tournament-prizes/stencil.config.d.ts +0 -2
@@ -1,58 +1,58 @@
1
1
  const DEFAULT_LANGUAGE = 'en';
2
2
  const TRANSLATIONS = {
3
- en: {
4
- prizes: 'Prizes',
5
- noprizes: 'No available prizes',
6
- place: 'place',
7
- },
8
- 'zh-hk': {
9
- prizes: '獎品',
10
- noprizes: '沒有可用的獎品',
11
- place: 'place', // need translation
12
- },
13
- fr: {
14
- prizes: 'Prix',
15
- noprizes: 'Aucun prix disponible',
16
- place: 'place', // need translation
17
- },
18
- ro: {
19
- prizes: 'Premii',
20
- noprizes: 'Nu sunt disponibile premii',
21
- place: 'poziție',
22
- },
23
- tr: {
24
- prizes: 'Ödüller',
25
- noprizes: 'Geçerli ödül yok',
26
- place: 'Sıra',
27
- },
28
- el: {
29
- prizes: 'Έπαθλα',
30
- noprizes: 'Μη διαθέσιμα έπαθλα',
31
- place: 'θέση',
32
- },
33
- es: {
34
- prizes: 'Premios',
35
- noprizes: 'No hay premios disponibles',
36
- place: 'posición',
37
- },
38
- hu: {
39
- prizes: 'Nyeremények',
40
- noprizes: 'Nincs elérhető nyeremény',
41
- place: 'helyezés',
42
- },
43
- pt: {
44
- prizes: 'Prêmios',
45
- noprizes: 'Não há prêmios disponíveis',
46
- place: 'place', // need translation
47
- },
48
- hr: {
49
- prizes: 'Nagrade',
50
- noprizes: 'Nema dostupnih nagrada',
51
- place: 'mjesto',
52
- }
3
+ en: {
4
+ prizes: 'Prizes',
5
+ noprizes: 'No available prizes',
6
+ place: 'place',
7
+ },
8
+ 'zh-hk': {
9
+ prizes: '獎品',
10
+ noprizes: '沒有可用的獎品',
11
+ place: 'place', // need translation
12
+ },
13
+ fr: {
14
+ prizes: 'Prix',
15
+ noprizes: 'Aucun prix disponible',
16
+ place: 'place', // need translation
17
+ },
18
+ ro: {
19
+ prizes: 'Premii',
20
+ noprizes: 'Nu sunt disponibile premii',
21
+ place: 'poziție',
22
+ },
23
+ tr: {
24
+ prizes: 'Ödüller',
25
+ noprizes: 'Geçerli ödül yok',
26
+ place: 'Sıra',
27
+ },
28
+ el: {
29
+ prizes: 'Έπαθλα',
30
+ noprizes: 'Μη διαθέσιμα έπαθλα',
31
+ place: 'θέση',
32
+ },
33
+ es: {
34
+ prizes: 'Premios',
35
+ noprizes: 'No hay premios disponibles',
36
+ place: 'posición',
37
+ },
38
+ hu: {
39
+ prizes: 'Nyeremények',
40
+ noprizes: 'Nincs elérhető nyeremény',
41
+ place: 'helyezés',
42
+ },
43
+ pt: {
44
+ prizes: 'Prêmios',
45
+ noprizes: 'Não há prêmios disponíveis',
46
+ place: 'place', // need translation
47
+ },
48
+ hr: {
49
+ prizes: 'Nagrade',
50
+ noprizes: 'Nema dostupnih nagrada',
51
+ place: 'mjesto',
52
+ }
53
53
  };
54
54
  export const translate = (key, customLang) => {
55
- var _a, _b;
56
- const lang = customLang;
57
- return ((_a = TRANSLATIONS[lang]) === null || _a === void 0 ? void 0 : _a[key]) || ((_b = TRANSLATIONS[DEFAULT_LANGUAGE]) === null || _b === void 0 ? void 0 : _b[key]);
55
+ var _a, _b;
56
+ const lang = customLang;
57
+ return ((_a = TRANSLATIONS[lang]) === null || _a === void 0 ? void 0 : _a[key]) || ((_b = TRANSLATIONS[DEFAULT_LANGUAGE]) === null || _b === void 0 ? void 0 : _b[key]);
58
58
  };
@@ -1,3 +1,3 @@
1
1
  export function format(first, middle, last) {
2
- return ((first || '') + (middle ? ` ${middle}` : '') + (last ? ` ${last}` : ''));
2
+ return ((first || '') + (middle ? ` ${middle}` : '') + (last ? ` ${last}` : ''));
3
3
  }
@@ -0,0 +1,3 @@
1
+ const globalScripts = () => {};
2
+
3
+ export { globalScripts as g };
@@ -1,173 +1,179 @@
1
- import { r as registerInstance, h, g as getElement } from './index-fd6b56d4.js';
1
+ import { r as registerInstance, h, g as getElement } from './index-7e63d638.js';
2
2
 
3
3
  const DEFAULT_LANGUAGE = 'en';
4
4
  const TRANSLATIONS = {
5
- en: {
6
- prizes: 'Prizes',
7
- noprizes: 'No available prizes',
8
- place: 'place',
9
- },
10
- 'zh-hk': {
11
- prizes: '獎品',
12
- noprizes: '沒有可用的獎品',
13
- place: 'place', // need translation
14
- },
15
- fr: {
16
- prizes: 'Prix',
17
- noprizes: 'Aucun prix disponible',
18
- place: 'place', // need translation
19
- },
20
- ro: {
21
- prizes: 'Premii',
22
- noprizes: 'Nu sunt disponibile premii',
23
- place: 'poziție',
24
- },
25
- tr: {
26
- prizes: 'Ödüller',
27
- noprizes: 'Geçerli ödül yok',
28
- place: 'Sıra',
29
- },
30
- el: {
31
- prizes: 'Έπαθλα',
32
- noprizes: 'Μη διαθέσιμα έπαθλα',
33
- place: 'θέση',
34
- },
35
- es: {
36
- prizes: 'Premios',
37
- noprizes: 'No hay premios disponibles',
38
- place: 'posición',
39
- },
40
- hu: {
41
- prizes: 'Nyeremények',
42
- noprizes: 'Nincs elérhető nyeremény',
43
- place: 'helyezés',
44
- },
45
- pt: {
46
- prizes: 'Prêmios',
47
- noprizes: 'Não há prêmios disponíveis',
48
- place: 'place', // need translation
49
- },
50
- hr: {
51
- prizes: 'Nagrade',
52
- noprizes: 'Nema dostupnih nagrada',
53
- place: 'mjesto',
54
- }
5
+ en: {
6
+ prizes: 'Prizes',
7
+ noprizes: 'No available prizes',
8
+ place: 'place',
9
+ },
10
+ 'zh-hk': {
11
+ prizes: '獎品',
12
+ noprizes: '沒有可用的獎品',
13
+ place: 'place', // need translation
14
+ },
15
+ fr: {
16
+ prizes: 'Prix',
17
+ noprizes: 'Aucun prix disponible',
18
+ place: 'place', // need translation
19
+ },
20
+ ro: {
21
+ prizes: 'Premii',
22
+ noprizes: 'Nu sunt disponibile premii',
23
+ place: 'poziție',
24
+ },
25
+ tr: {
26
+ prizes: 'Ödüller',
27
+ noprizes: 'Geçerli ödül yok',
28
+ place: 'Sıra',
29
+ },
30
+ el: {
31
+ prizes: 'Έπαθλα',
32
+ noprizes: 'Μη διαθέσιμα έπαθλα',
33
+ place: 'θέση',
34
+ },
35
+ es: {
36
+ prizes: 'Premios',
37
+ noprizes: 'No hay premios disponibles',
38
+ place: 'posición',
39
+ },
40
+ hu: {
41
+ prizes: 'Nyeremények',
42
+ noprizes: 'Nincs elérhető nyeremény',
43
+ place: 'helyezés',
44
+ },
45
+ pt: {
46
+ prizes: 'Prêmios',
47
+ noprizes: 'Não há prêmios disponíveis',
48
+ place: 'place', // need translation
49
+ },
50
+ hr: {
51
+ prizes: 'Nagrade',
52
+ noprizes: 'Nema dostupnih nagrada',
53
+ place: 'mjesto',
54
+ }
55
55
  };
56
56
  const translate = (key, customLang) => {
57
- var _a, _b;
58
- const lang = customLang;
59
- return ((_a = TRANSLATIONS[lang]) === null || _a === void 0 ? void 0 : _a[key]) || ((_b = TRANSLATIONS[DEFAULT_LANGUAGE]) === null || _b === void 0 ? void 0 : _b[key]);
57
+ var _a, _b;
58
+ const lang = customLang;
59
+ return ((_a = TRANSLATIONS[lang]) === null || _a === void 0 ? void 0 : _a[key]) || ((_b = TRANSLATIONS[DEFAULT_LANGUAGE]) === null || _b === void 0 ? void 0 : _b[key]);
60
60
  };
61
61
 
62
62
  const casinoTournamentPrizesCss = ":host{display:block}.PrizeGroups{color:var(--emfe-w-color-white, #FFFFFF);display:flex;gap:20px;font-size:14px}.PrizeGroup{flex:1;background:var(--emfe-w-tournament-color-bg, #153a5c)}.PrizeTitle{text-align:center;width:100%}.GroupPrizeTitle{width:100%;display:flex;padding:8px 6px;gap:8px;justify-content:center}.PrizeView{display:flex;gap:10px;font-size:12px}.PrizeView .PrizeTitle{display:inline-block;width:auto}.PrizeView .PrizeGroups{display:inline-flex}.Title{text-align:center;color:var(--emfe-w-color-white, #FFFFFF)}.PrizeIcon path{fill:var(--emfe-w-color-white, #FFFFFF)}.PrizeRow{padding:8px;border-bottom:1px solid rgba(206, 210, 214, 0.15)}.PrizeItem{display:flex;justify-content:space-between;padding:6px;font-size:12px;border-radius:2px}.Group1 .Rank1{background:#7e6c22}.Group1 .Rank2{background:#666}.Group1 .Rank3{background:#6a5446}.Prizes{padding-left:20px;flex-wrap:wrap;display:flex;gap:20px;width:100%;min-height:50px;padding-top:8px}.Prize{flex-grow:1;color:var(--emfe-w-color-gray-300, #58586B)}.Prize.Prize0 span{color:#FECF00}.Prize.Prize1 span{color:#D9B206}.Prize.Prize2 span{color:#9B8007}.Prize p{color:var(--emfe-w-color-white, #FFFFFF)}";
63
+ const CasinoTournamentPrizesStyle0 = casinoTournamentPrizesCss;
63
64
 
64
65
  const CasinoTournamentPrizes = class {
65
- constructor(hostRef) {
66
- registerInstance(this, hostRef);
67
- this.useGroup = false;
68
- this.useEvent = false;
69
- this.clientStyling = '';
70
- this.clientStylingUrl = '';
71
- this.limitStylingAppends = false;
72
- this.prizes = [];
73
- this.prizeGroups = [];
74
- this.initialLoad = false;
75
- }
76
- infoCompletedHandler(event) {
77
- if (event.detail) {
78
- this.prizes = event.detail.prizes;
79
- this.formatGroup();
80
- this.initialLoad = true;
66
+ constructor(hostRef) {
67
+ registerInstance(this, hostRef);
68
+ this.language = undefined;
69
+ this.useGroup = false;
70
+ this.useEvent = false;
71
+ this.endpoint = undefined;
72
+ this.session = undefined;
73
+ this.rawPrizes = undefined;
74
+ this.tournamentId = undefined;
75
+ this.clientStyling = '';
76
+ this.clientStylingUrl = '';
77
+ this.limitStylingAppends = false;
78
+ this.prizes = [];
79
+ this.prizeGroups = [];
80
+ this.initialLoad = false;
81
81
  }
82
- }
83
- formatGroup() {
84
- const prizes = this.prizes;
85
- prizes.forEach((prize) => {
86
- let array = [];
87
- if (prize.count > 0) {
88
- for (let index = 0; index < prize.count; index++) {
89
- const element = { name: prize.name, rank: prize.rank + index };
90
- array.push(element);
82
+ infoCompletedHandler(event) {
83
+ if (event.detail) {
84
+ this.prizes = event.detail.prizes;
85
+ this.formatGroup();
86
+ this.initialLoad = true;
91
87
  }
92
- }
93
- this.prizeGroups.push(array);
94
- });
95
- }
96
- getTournamentInfo() {
97
- let url = new URL(this.endpoint + `/v1/tournaments/${this.tournamentId}`);
98
- let reqHeaders = new Headers();
99
- url.searchParams.append('expand', 'games');
100
- url.searchParams.append('language', this.language);
101
- url.searchParams.append('fields', 'playerEnrolled,games(id,name,thumbnail)');
102
- if (this.session) {
103
- reqHeaders.append('X-SessionId', this.session);
104
88
  }
105
- let requestOptions = {
106
- method: 'GET',
107
- headers: reqHeaders,
108
- };
109
- fetch(url.href, requestOptions).then((res) => res.json())
110
- .then((res) => {
111
- this.prizes = res.item.prizes;
112
- if (this.useGroup) {
113
- this.formatGroup();
114
- }
115
- this.initialLoad = true;
116
- });
117
- }
118
- componentWillLoad() {
119
- if (!this.useEvent && this.rawPrizes) {
120
- this.prizes = JSON.parse(this.rawPrizes);
121
- if (this.useGroup) {
122
- this.formatGroup();
123
- }
124
- this.initialLoad = true;
89
+ formatGroup() {
90
+ const prizes = this.prizes;
91
+ prizes.forEach((prize) => {
92
+ let array = [];
93
+ if (prize.count > 0) {
94
+ for (let index = 0; index < prize.count; index++) {
95
+ const element = { name: prize.name, rank: prize.rank + index };
96
+ array.push(element);
97
+ }
98
+ }
99
+ this.prizeGroups.push(array);
100
+ });
125
101
  }
126
- if (!this.useEvent && this.endpoint && this.tournamentId) {
127
- this.getTournamentInfo();
102
+ getTournamentInfo() {
103
+ let url = new URL(this.endpoint + `/v1/tournaments/${this.tournamentId}`);
104
+ let reqHeaders = new Headers();
105
+ url.searchParams.append('expand', 'games');
106
+ url.searchParams.append('language', this.language);
107
+ url.searchParams.append('fields', 'playerEnrolled,games(id,name,thumbnail)');
108
+ if (this.session) {
109
+ reqHeaders.append('X-SessionId', this.session);
110
+ }
111
+ let requestOptions = {
112
+ method: 'GET',
113
+ headers: reqHeaders,
114
+ };
115
+ fetch(url.href, requestOptions).then((res) => res.json())
116
+ .then((res) => {
117
+ this.prizes = res.item.prizes;
118
+ if (this.useGroup) {
119
+ this.formatGroup();
120
+ }
121
+ this.initialLoad = true;
122
+ });
128
123
  }
129
- }
130
- componentDidRender() {
131
- if (!this.limitStylingAppends && this.host) {
132
- if (this.clientStyling)
133
- this.setClientStyling();
134
- if (this.clientStylingUrl)
135
- this.setClientStylingURL();
136
- this.limitStylingAppends = true;
124
+ componentWillLoad() {
125
+ if (!this.useEvent && this.rawPrizes) {
126
+ this.prizes = JSON.parse(this.rawPrizes);
127
+ if (this.useGroup) {
128
+ this.formatGroup();
129
+ }
130
+ this.initialLoad = true;
131
+ }
132
+ if (!this.useEvent && this.endpoint && this.tournamentId) {
133
+ this.getTournamentInfo();
134
+ }
137
135
  }
138
- }
139
- setClientStyling() {
140
- const sheet = new CSSStyleSheet();
141
- // @ts-ignore
142
- sheet.replace(this.clientStyling);
143
- // @ts-ignore
144
- this.host.shadowRoot.adoptedStyleSheets = [...this.host.shadowRoot.adoptedStyleSheets, sheet];
145
- }
146
- setClientStylingURL() {
147
- let url = new URL(this.clientStylingUrl);
148
- fetch(url.href)
149
- .then((res) => res.text())
150
- .then((data) => {
151
- const sheet = new CSSStyleSheet();
152
- // @ts-ignore
153
- sheet.replace(data);
154
- // @ts-ignore
155
- this.host.shadowRoot.adoptedStyleSheets = [...this.host.shadowRoot.adoptedStyleSheets, sheet];
156
- });
157
- }
158
- render() {
159
- {
160
- return h("div", { class: `TournamentPrizes ${this.useGroup ? '' : 'PrizeView'}` }, this.initialLoad && !this.useGroup && h("div", { class: "PrizeTitle" }, h("svg", { class: "PrizeIcon", xmlns: "http://www.w3.org/2000/svg", width: "30", height: "27.454", viewBox: "0 0 30 27.454" }, h("path", { d: "M35.84,12.887a1.023,1.023,0,0,0-.853-.481h-5.2l.242-1.456a1.023,1.023,0,0,0-1.023-1.19H12.977a1.023,1.023,0,0,0-1.023,1.19l.242,1.456H7.022a1.023,1.023,0,0,0-.921,1.47l2.967,6.077a6.48,6.48,0,0,0,5.163,3.581,7.227,7.227,0,0,0,3.7,3.963v2.667h-.426a3.525,3.525,0,1,0,0,7.049H24.5a3.525,3.525,0,1,0,0-7.049h-.426V27.5a7.227,7.227,0,0,0,3.7-3.963,6.48,6.48,0,0,0,5.167-3.581L35.9,13.876a1.023,1.023,0,0,0-.058-.989ZM10.914,19.05l-2.241-4.6h3.891l1.153,6.916A4.406,4.406,0,0,1,10.914,19.05ZM25.977,33.687A1.477,1.477,0,0,1,24.5,35.164H17.509a1.478,1.478,0,0,1,0-2.957H24.5A1.48,1.48,0,0,1,25.977,33.687Zm-3.949-3.526H19.982V28.094a6.729,6.729,0,0,0,2.046,0Zm4.123-8.383a5.218,5.218,0,0,1-10.293,0L14.184,11.8H27.826ZM31.1,19.05a4.406,4.406,0,0,1-2.8,2.309l1.153-6.916h3.891Z", transform: "translate(-5.999 -9.76)" })), h("div", { class: "Title" }, translate('prizes', this.language))), this.initialLoad && this.useGroup && h("div", { class: "GroupPrizeTitle" }, h("svg", { class: "PrizeIcon", xmlns: "http://www.w3.org/2000/svg", width: "19", height: "16", viewBox: "0 0 19 16", fill: "none" }, h("g", { "clip-path": "url(#clip0_2459_42455)" }, h("path", { d: "M14.7476 2.84132V0.664551H4.03327V2.84132H0.818359V5.01946C0.818359 6.8229 2.2568 8.28496 4.0326 8.28496C4.36862 8.28496 4.69326 8.23192 4.99647 8.13399C5.76958 9.25604 6.94898 10.07 8.31782 10.3516V13.7266H7.24685C6.06276 13.7266 5.1029 14.701 5.1029 15.9026H13.6753C13.6753 14.7004 12.7168 13.7266 11.5327 13.7266H10.4611V10.3516C11.8293 10.07 13.0087 9.25672 13.7818 8.13399C14.0863 8.23124 14.4116 8.28496 14.7463 8.28496C16.5214 8.28496 17.9612 6.8229 17.9612 5.01946V2.84132H14.7476ZM4.03327 6.99222C2.9623 6.99222 2.0908 6.10751 2.0908 5.01946V3.93005H4.03327V5.01946C4.03327 5.70221 4.15844 6.3564 4.38401 6.9589C4.27089 6.9793 4.15175 6.99086 4.03327 6.99086V6.99222ZM11.0207 5.88989L12.0414 9.06223L9.38945 7.09355L6.7368 9.06223L7.75757 5.88989L5.09688 3.93481L8.3814 3.94229L9.38945 0.767235L10.3968 3.94229L13.6814 3.93481L11.0207 5.88989ZM16.6901 5.01946C16.6901 6.10683 15.8193 6.99222 14.7483 6.99222C14.6285 6.99222 14.512 6.9793 14.3982 6.95958C14.6245 6.3564 14.7483 5.70357 14.7483 5.02014V3.93073H16.6901V5.02014V5.01946Z", fill: "white" })), h("defs", null, h("clipPath", { id: "clip0_2459_42455" }, h("rect", { width: "18.2857", height: "16", fill: "white", transform: "translate(0.5)" })))), h("div", { class: "Title" }, translate('prizes', this.language))), h("div", { class: "PrizeGroups" }, this.useGroup == true && this.prizeGroups && this.prizeGroups.map((group, groupIndex) => {
161
- return h("div", { class: `PrizeGroup Group${groupIndex + 1}` }, group && group.map((prize, prizeIndex) => {
162
- return h("div", { class: "PrizeRow" }, h("div", { class: `PrizeItem Rank${prizeIndex + 1}` }, h("span", { class: "PrizeRank" }, prize.rank, " ", translate('place', this.language), " "), h("span", { class: "PrizeName" }, prize.name)));
163
- }));
164
- }), this.useGroup == false && this.prizes && this.prizes.map((prize, prizeIndex) => {
165
- return h("div", { class: `Prize Prize${prizeIndex}` }, h("p", { class: "PrizeText" }, h("span", { class: "PrizeRank" }, prize.count > 1 ? (`${prize.rank}~${prize.rank + prize.count - 1}`) : (prize.rank)), " ", translate('place', this.language), ": ", prize.name));
166
- }), !this.prizes && h("p", null, translate('noprizes', this.language))));
136
+ componentDidRender() {
137
+ if (!this.limitStylingAppends && this.host) {
138
+ if (this.clientStyling)
139
+ this.setClientStyling();
140
+ if (this.clientStylingUrl)
141
+ this.setClientStylingURL();
142
+ this.limitStylingAppends = true;
143
+ }
144
+ }
145
+ setClientStyling() {
146
+ const sheet = new CSSStyleSheet();
147
+ // @ts-ignore
148
+ sheet.replace(this.clientStyling);
149
+ // @ts-ignore
150
+ this.host.shadowRoot.adoptedStyleSheets = [...this.host.shadowRoot.adoptedStyleSheets, sheet];
151
+ }
152
+ setClientStylingURL() {
153
+ let url = new URL(this.clientStylingUrl);
154
+ fetch(url.href)
155
+ .then((res) => res.text())
156
+ .then((data) => {
157
+ const sheet = new CSSStyleSheet();
158
+ // @ts-ignore
159
+ sheet.replace(data);
160
+ // @ts-ignore
161
+ this.host.shadowRoot.adoptedStyleSheets = [...this.host.shadowRoot.adoptedStyleSheets, sheet];
162
+ });
163
+ }
164
+ render() {
165
+ {
166
+ return h("div", { key: '6f6d6a40e0374ad146b0eda343d963679fbd11f0', class: `TournamentPrizes ${this.useGroup ? '' : 'PrizeView'}` }, this.initialLoad && !this.useGroup && h("div", { key: '28edb876913c67479b4fb5c885244cea36a073ea', class: "PrizeTitle" }, h("svg", { key: '6cd86bf5db8eacee01a9577458c136cbe78684bc', class: "PrizeIcon", xmlns: "http://www.w3.org/2000/svg", width: "30", height: "27.454", viewBox: "0 0 30 27.454" }, h("path", { key: '744e27a1ee73240f5876abd14b2e912b8dbc979e', d: "M35.84,12.887a1.023,1.023,0,0,0-.853-.481h-5.2l.242-1.456a1.023,1.023,0,0,0-1.023-1.19H12.977a1.023,1.023,0,0,0-1.023,1.19l.242,1.456H7.022a1.023,1.023,0,0,0-.921,1.47l2.967,6.077a6.48,6.48,0,0,0,5.163,3.581,7.227,7.227,0,0,0,3.7,3.963v2.667h-.426a3.525,3.525,0,1,0,0,7.049H24.5a3.525,3.525,0,1,0,0-7.049h-.426V27.5a7.227,7.227,0,0,0,3.7-3.963,6.48,6.48,0,0,0,5.167-3.581L35.9,13.876a1.023,1.023,0,0,0-.058-.989ZM10.914,19.05l-2.241-4.6h3.891l1.153,6.916A4.406,4.406,0,0,1,10.914,19.05ZM25.977,33.687A1.477,1.477,0,0,1,24.5,35.164H17.509a1.478,1.478,0,0,1,0-2.957H24.5A1.48,1.48,0,0,1,25.977,33.687Zm-3.949-3.526H19.982V28.094a6.729,6.729,0,0,0,2.046,0Zm4.123-8.383a5.218,5.218,0,0,1-10.293,0L14.184,11.8H27.826ZM31.1,19.05a4.406,4.406,0,0,1-2.8,2.309l1.153-6.916h3.891Z", transform: "translate(-5.999 -9.76)" })), h("div", { key: 'ddd4dd055f8441b1b0355e95e88b43049a108b2c', class: "Title" }, translate('prizes', this.language))), this.initialLoad && this.useGroup && h("div", { key: '83b846fe441de36598d01742fd6730de4c5920bf', class: "GroupPrizeTitle" }, h("svg", { key: 'e6b379df8cc991173b588e8dd9408b0c6716de7a', class: "PrizeIcon", xmlns: "http://www.w3.org/2000/svg", width: "19", height: "16", viewBox: "0 0 19 16", fill: "none" }, h("g", { key: '0332923cca76d7ccbe779cb367abb4e8952842b5', "clip-path": "url(#clip0_2459_42455)" }, h("path", { key: '607a3379976189ca332117ec968c34046b3dcb46', d: "M14.7476 2.84132V0.664551H4.03327V2.84132H0.818359V5.01946C0.818359 6.8229 2.2568 8.28496 4.0326 8.28496C4.36862 8.28496 4.69326 8.23192 4.99647 8.13399C5.76958 9.25604 6.94898 10.07 8.31782 10.3516V13.7266H7.24685C6.06276 13.7266 5.1029 14.701 5.1029 15.9026H13.6753C13.6753 14.7004 12.7168 13.7266 11.5327 13.7266H10.4611V10.3516C11.8293 10.07 13.0087 9.25672 13.7818 8.13399C14.0863 8.23124 14.4116 8.28496 14.7463 8.28496C16.5214 8.28496 17.9612 6.8229 17.9612 5.01946V2.84132H14.7476ZM4.03327 6.99222C2.9623 6.99222 2.0908 6.10751 2.0908 5.01946V3.93005H4.03327V5.01946C4.03327 5.70221 4.15844 6.3564 4.38401 6.9589C4.27089 6.9793 4.15175 6.99086 4.03327 6.99086V6.99222ZM11.0207 5.88989L12.0414 9.06223L9.38945 7.09355L6.7368 9.06223L7.75757 5.88989L5.09688 3.93481L8.3814 3.94229L9.38945 0.767235L10.3968 3.94229L13.6814 3.93481L11.0207 5.88989ZM16.6901 5.01946C16.6901 6.10683 15.8193 6.99222 14.7483 6.99222C14.6285 6.99222 14.512 6.9793 14.3982 6.95958C14.6245 6.3564 14.7483 5.70357 14.7483 5.02014V3.93073H16.6901V5.02014V5.01946Z", fill: "white" })), h("defs", { key: '66f11be400aac05c7f334a48b82cfb1aabdead8c' }, h("clipPath", { key: '65e879523cff89288af691d5f705ef55996f3107', id: "clip0_2459_42455" }, h("rect", { key: '382441f3ade90fa866096c5f25dfc3cb49d82132', width: "18.2857", height: "16", fill: "white", transform: "translate(0.5)" })))), h("div", { key: '8610b8361faa0d2316415e39a21162dfcdcaeccf', class: "Title" }, translate('prizes', this.language))), h("div", { key: '76d9452769046d3c9cd4d0dd7a65396c5083ebc6', class: "PrizeGroups" }, this.useGroup == true && this.prizeGroups && this.prizeGroups.map((group, groupIndex) => {
167
+ return h("div", { class: `PrizeGroup Group${groupIndex + 1}` }, group && group.map((prize, prizeIndex) => {
168
+ return h("div", { class: "PrizeRow" }, h("div", { class: `PrizeItem Rank${prizeIndex + 1}` }, h("span", { class: "PrizeRank" }, prize.rank, " ", translate('place', this.language), " "), h("span", { class: "PrizeName" }, prize.name)));
169
+ }));
170
+ }), this.useGroup == false && this.prizes && this.prizes.map((prize, prizeIndex) => {
171
+ return h("div", { class: `Prize Prize${prizeIndex}` }, h("p", { class: "PrizeText" }, h("span", { class: "PrizeRank" }, prize.count > 1 ? (`${prize.rank}~${prize.rank + prize.count - 1}`) : (prize.rank)), " ", translate('place', this.language), ": ", prize.name));
172
+ }), !this.prizes && h("p", { key: '2df9ce5a0f56928a550f0ebf3de962835df0d6f2' }, translate('noprizes', this.language))));
173
+ }
167
174
  }
168
- }
169
- get host() { return getElement(this); }
175
+ get host() { return getElement(this); }
170
176
  };
171
- CasinoTournamentPrizes.style = casinoTournamentPrizesCss;
177
+ CasinoTournamentPrizes.style = CasinoTournamentPrizesStyle0;
172
178
 
173
179
  export { CasinoTournamentPrizes as casino_tournament_prizes };
@@ -1,17 +1,20 @@
1
- import { p as promiseResolve, b as bootstrapLazy } from './index-fd6b56d4.js';
1
+ import { p as promiseResolve, b as bootstrapLazy } from './index-7e63d638.js';
2
+ export { s as setNonce } from './index-7e63d638.js';
3
+ import { g as globalScripts } from './app-globals-0f993ce5.js';
2
4
 
3
5
  /*
4
- Stencil Client Patch Browser v2.15.2 | MIT Licensed | https://stenciljs.com
6
+ Stencil Client Patch Browser v4.20.0 | MIT Licensed | https://stenciljs.com
5
7
  */
6
- const patchBrowser = () => {
7
- const importMeta = import.meta.url;
8
- const opts = {};
9
- if (importMeta !== '') {
10
- opts.resourcesUrl = new URL('.', importMeta).href;
11
- }
12
- return promiseResolve(opts);
8
+ var patchBrowser = () => {
9
+ const importMeta = import.meta.url;
10
+ const opts = {};
11
+ if (importMeta !== "") {
12
+ opts.resourcesUrl = new URL(".", importMeta).href;
13
+ }
14
+ return promiseResolve(opts);
13
15
  };
14
16
 
15
- patchBrowser().then(options => {
17
+ patchBrowser().then(async (options) => {
18
+ await globalScripts();
16
19
  return bootstrapLazy([["casino-tournament-prizes",[[1,"casino-tournament-prizes",{"language":[1],"useGroup":[4,"use-group"],"useEvent":[4,"use-event"],"endpoint":[1],"session":[1],"rawPrizes":[1,"raw-prizes"],"tournamentId":[1,"tournament-id"],"clientStyling":[1,"client-styling"],"clientStylingUrl":[1,"client-styling-url"],"limitStylingAppends":[32],"prizes":[32],"prizeGroups":[32],"initialLoad":[32]},[[10,"getTournamentInfoCompleted","infoCompletedHandler"]]]]]], options);
17
20
  });