@everymatrix/casino-challenges-modal 0.0.1

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 (56) hide show
  1. package/dist/casino-challenges-modal/app-globals-0f993ce5.js +1 -0
  2. package/dist/casino-challenges-modal/casino-challenges-modal-2fc23147.js +1 -0
  3. package/dist/casino-challenges-modal/casino-challenges-modal.entry.js +1 -0
  4. package/dist/casino-challenges-modal/casino-challenges-modal.esm.js +1 -0
  5. package/dist/casino-challenges-modal/index-27d1076a.js +2 -0
  6. package/dist/casino-challenges-modal/index.esm.js +1 -0
  7. package/dist/cjs/app-globals-3a1e7e63.js +5 -0
  8. package/dist/cjs/casino-challenges-modal-9e634999.js +182 -0
  9. package/dist/cjs/casino-challenges-modal.cjs.entry.js +10 -0
  10. package/dist/cjs/casino-challenges-modal.cjs.js +25 -0
  11. package/dist/cjs/index-0e4accfe.js +1213 -0
  12. package/dist/cjs/index.cjs.js +10 -0
  13. package/dist/cjs/loader.cjs.js +15 -0
  14. package/dist/collection/assets/x-close.svg +3 -0
  15. package/dist/collection/collection-manifest.json +12 -0
  16. package/dist/collection/components/casino-challenges-modal/casino-challenges-modal.css +121 -0
  17. package/dist/collection/components/casino-challenges-modal/casino-challenges-modal.js +217 -0
  18. package/dist/collection/components/casino-challenges-modal/index.js +1 -0
  19. package/dist/collection/index.js +1 -0
  20. package/dist/collection/utils/utils.js +3 -0
  21. package/dist/esm/app-globals-0f993ce5.js +3 -0
  22. package/dist/esm/casino-challenges-modal-2fc23147.js +180 -0
  23. package/dist/esm/casino-challenges-modal.entry.js +2 -0
  24. package/dist/esm/casino-challenges-modal.js +20 -0
  25. package/dist/esm/index-27d1076a.js +1186 -0
  26. package/dist/esm/index.js +2 -0
  27. package/dist/esm/loader.js +11 -0
  28. package/dist/index.cjs.js +1 -0
  29. package/dist/index.js +1 -0
  30. package/dist/stencil.config.dev.js +19 -0
  31. package/dist/stencil.config.js +19 -0
  32. package/dist/storybook/main.js +43 -0
  33. package/dist/storybook/preview.js +9 -0
  34. package/dist/types/builds/emfe-widgets/widgets-monorepo/packages/stencil/casino-challenges-modal/.stencil/libs/common/src/storybook/storybook-utils.d.ts +39 -0
  35. package/dist/types/builds/emfe-widgets/widgets-monorepo/packages/stencil/casino-challenges-modal/.stencil/packages/stencil/casino-challenges-modal/stencil.config.d.ts +2 -0
  36. package/dist/types/builds/emfe-widgets/widgets-monorepo/packages/stencil/casino-challenges-modal/.stencil/packages/stencil/casino-challenges-modal/stencil.config.dev.d.ts +2 -0
  37. package/dist/types/builds/emfe-widgets/widgets-monorepo/packages/stencil/casino-challenges-modal/.stencil/packages/stencil/casino-challenges-modal/storybook/main.d.ts +3 -0
  38. package/dist/types/builds/emfe-widgets/widgets-monorepo/packages/stencil/casino-challenges-modal/.stencil/packages/stencil/casino-challenges-modal/storybook/preview.d.ts +70 -0
  39. package/dist/types/builds/emfe-widgets/widgets-monorepo/packages/stencil/casino-challenges-modal/.stencil/tools/plugins/index.d.ts +4 -0
  40. package/dist/types/builds/emfe-widgets/widgets-monorepo/packages/stencil/casino-challenges-modal/.stencil/tools/plugins/lazy-load-chunk-plugin.d.ts +12 -0
  41. package/dist/types/builds/emfe-widgets/widgets-monorepo/packages/stencil/casino-challenges-modal/.stencil/tools/plugins/stencil-clean-deps-plugin.d.ts +5 -0
  42. package/dist/types/builds/emfe-widgets/widgets-monorepo/packages/stencil/casino-challenges-modal/.stencil/tools/plugins/vite-chunk-plugin.d.ts +6 -0
  43. package/dist/types/builds/emfe-widgets/widgets-monorepo/packages/stencil/casino-challenges-modal/.stencil/tools/plugins/vite-clean-deps-plugin.d.ts +4 -0
  44. package/dist/types/components/casino-challenges-modal/casino-challenges-modal.d.ts +20 -0
  45. package/dist/types/components/casino-challenges-modal/index.d.ts +1 -0
  46. package/dist/types/components.d.ts +67 -0
  47. package/dist/types/index.d.ts +1 -0
  48. package/dist/types/stencil-public-runtime.d.ts +1674 -0
  49. package/dist/types/utils/utils.d.ts +1 -0
  50. package/loader/cdn.js +1 -0
  51. package/loader/index.cjs.js +1 -0
  52. package/loader/index.d.ts +24 -0
  53. package/loader/index.es2017.js +1 -0
  54. package/loader/index.js +2 -0
  55. package/loader/package.json +11 -0
  56. package/package.json +27 -0
@@ -0,0 +1,10 @@
1
+ 'use strict';
2
+
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
5
+ const casinoChallengesModal = require('./casino-challenges-modal-9e634999.js');
6
+ require('./index-0e4accfe.js');
7
+
8
+
9
+
10
+ exports.CasinoChallengesModal = casinoChallengesModal.CasinoChallengesModal;
@@ -0,0 +1,15 @@
1
+ 'use strict';
2
+
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
5
+ const index = require('./index-0e4accfe.js');
6
+ const appGlobals = require('./app-globals-3a1e7e63.js');
7
+
8
+ const defineCustomElements = async (win, options) => {
9
+ if (typeof window === 'undefined') return undefined;
10
+ await appGlobals.globalScripts();
11
+ return index.bootstrapLazy([["casino-challenges-modal.cjs",[[1,"casino-challenges-modal",{"mbSource":[513,"mb-source"],"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"isOpen":[516,"is-open"],"showWinAnimation":[516,"show-win-animation"],"showBackdrop":[516,"show-backdrop"],"showCloseButton":[516,"show-close-button"]},null,{"clientStyling":["handleClientStylingChange"],"clientStylingUrl":["handleClientStylingUrlChange"],"mbSource":["handleMbSourceChange"]}]]]], options);
12
+ };
13
+
14
+ exports.setNonce = index.setNonce;
15
+ exports.defineCustomElements = defineCustomElements;
@@ -0,0 +1,3 @@
1
+ <svg width="22" height="22" viewBox="0 0 22 22" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M4.85149 4.85198C5.20947 4.494 5.78988 4.494 6.14786 4.85198L10.9997 9.7038L15.8515 4.85198C16.2095 4.494 16.7899 4.494 17.1479 4.85198C17.5058 5.20996 17.5058 5.79036 17.1479 6.14834L12.296 11.0002L17.1479 15.852C17.5058 16.21 17.5058 16.7904 17.1479 17.1483C16.7899 17.5063 16.2095 17.5063 15.8515 17.1483L10.9997 12.2965L6.14786 17.1483C5.78988 17.5063 5.20947 17.5063 4.85149 17.1483C4.49351 16.7904 4.49351 16.21 4.85149 15.852L9.70331 11.0002L4.85149 6.14834C4.49351 5.79036 4.49351 5.20996 4.85149 4.85198Z" fill="white"/>
3
+ </svg>
@@ -0,0 +1,12 @@
1
+ {
2
+ "entries": [
3
+ "components/casino-challenges-modal/casino-challenges-modal.js"
4
+ ],
5
+ "compiler": {
6
+ "name": "@stencil/core",
7
+ "version": "4.19.2",
8
+ "typescriptVersion": "5.4.5"
9
+ },
10
+ "collections": [],
11
+ "bundles": []
12
+ }
@@ -0,0 +1,121 @@
1
+ :host {
2
+ display: block;
3
+ font-family: inherit;
4
+ }
5
+
6
+ * {
7
+ box-sizing: border-box;
8
+ margin: 0;
9
+ padding: 0;
10
+ }
11
+
12
+ button {
13
+ border: none;
14
+ background: none;
15
+ cursor: pointer;
16
+ touch-action: manipulation;
17
+ }
18
+ button:focus {
19
+ outline: none;
20
+ }
21
+
22
+ .Backdrop {
23
+ position: absolute;
24
+ background-color: rgba(0, 0, 0, 0.6);
25
+ opacity: 0.6;
26
+ width: 100%;
27
+ height: 100%;
28
+ z-index: 301;
29
+ }
30
+
31
+ .ModalOverlay {
32
+ display: none;
33
+ position: fixed;
34
+ top: 0;
35
+ left: 0;
36
+ width: 100%;
37
+ height: 100%;
38
+ background-color: rgba(0, 0, 0, 0);
39
+ justify-content: center;
40
+ align-items: center;
41
+ z-index: 300;
42
+ }
43
+
44
+ .ModalOverlay.Open {
45
+ display: flex;
46
+ }
47
+
48
+ .ModalContent {
49
+ display: flex;
50
+ flex-direction: column;
51
+ align-items: center;
52
+ position: relative;
53
+ z-index: 302;
54
+ background: linear-gradient(90deg, var(--emw--color-background, #003E5C) 0.05%, var(--emw--color-background-secondary, #113B21) 87.69%);
55
+ padding: 26px;
56
+ border-radius: 26px;
57
+ border: 2px solid var(--emw--color-primary-variant, #1E654F);
58
+ width: 450px;
59
+ max-width: 90%;
60
+ text-align: center;
61
+ max-height: 90dvh;
62
+ min-height: 100px;
63
+ font-family: "Roboto", sans-serif;
64
+ transition: all 0.3s;
65
+ }
66
+
67
+ .InnerContainer {
68
+ border-radius: 20px;
69
+ background: #F9F8F8;
70
+ padding: 25px;
71
+ width: 100%;
72
+ }
73
+
74
+ .ModalHeader {
75
+ color: var(--emw--color-typography, #212529);
76
+ text-align: center;
77
+ font-family: var(--emw--button-typography, "PF BeauSans Pro", sans-serif);
78
+ font-size: 16px;
79
+ font-style: normal;
80
+ font-weight: 700;
81
+ line-height: normal;
82
+ text-transform: uppercase;
83
+ letter-spacing: 1px;
84
+ }
85
+
86
+ .ModalAction {
87
+ border-radius: var(--emw--button-border-radius, 99px);
88
+ border: 2px solid var(--emw--button-border-color, #083B17);
89
+ background: linear-gradient(90deg, var(--emw--color-primary, #24AA4D) 0%, var(--emw--color-background-secondary, #113F21) 100%);
90
+ padding: 9px 20px;
91
+ margin-top: 10px;
92
+ text-transform: uppercase;
93
+ color: var(--emw--button-text-color, #FFF);
94
+ text-align: center;
95
+ font-family: var(--emw--button-typography, "PF BeauSans Pro", sans-serif);
96
+ font-size: 12px;
97
+ font-style: normal;
98
+ font-weight: 700;
99
+ letter-spacing: 1px;
100
+ line-height: 1;
101
+ }
102
+
103
+ .close-modal {
104
+ position: absolute;
105
+ width: 32px;
106
+ height: 32px;
107
+ background: rgba(219, 255, 243, 0.2);
108
+ border-radius: 16px;
109
+ right: 20px;
110
+ top: 16px;
111
+ display: flex;
112
+ justify-content: center;
113
+ align-items: center;
114
+ cursor: pointer;
115
+ }
116
+
117
+ @Container casino-challenges-modal (min-width: 576px) {
118
+ .close-modal {
119
+ top: 50px;
120
+ }
121
+ }
@@ -0,0 +1,217 @@
1
+ import { h } from "@stencil/core";
2
+ import { setClientStyling, setClientStylingURL, setStreamStyling } from "../../../../../../../../libs/common/src/styling/index";
3
+ import closeIcon from "../../assets/x-close.svg";
4
+ export class CasinoChallengesModal {
5
+ constructor() {
6
+ this.onClose = () => {
7
+ this.close.emit();
8
+ };
9
+ this.mbSource = undefined;
10
+ this.clientStyling = undefined;
11
+ this.clientStylingUrl = undefined;
12
+ this.isOpen = false;
13
+ this.showWinAnimation = false;
14
+ this.showBackdrop = false;
15
+ this.showCloseButton = false;
16
+ }
17
+ handleClientStylingChange(newValue, oldValue) {
18
+ if (newValue != oldValue) {
19
+ setClientStyling(this.stylingContainer, this.clientStyling);
20
+ }
21
+ }
22
+ handleClientStylingUrlChange(newValue, oldValue) {
23
+ if (newValue != oldValue) {
24
+ setClientStylingURL(this.stylingContainer, this.clientStylingUrl);
25
+ }
26
+ }
27
+ handleMbSourceChange(newValue, oldValue) {
28
+ if (newValue != oldValue) {
29
+ setStreamStyling(this.stylingContainer, `${this.mbSource}.Style`, this.stylingSubscription);
30
+ }
31
+ }
32
+ componentDidLoad() {
33
+ if (this.stylingContainer) {
34
+ if (this.mbSource)
35
+ setStreamStyling(this.stylingContainer, `${this.mbSource}.Style`, this.stylingSubscription);
36
+ if (this.clientStyling)
37
+ setClientStyling(this.stylingContainer, this.clientStyling);
38
+ if (this.clientStylingUrl)
39
+ setClientStylingURL(this.stylingContainer, this.clientStylingUrl);
40
+ }
41
+ }
42
+ disconnectedCallback() {
43
+ this.stylingSubscription && this.stylingSubscription.unsubscribe();
44
+ }
45
+ render() {
46
+ return (h("div", { key: '760f548283506b890c94b5a31b2f482977dad63b', ref: (el) => (this.stylingContainer = el), class: `ModalOverlay ${this.isOpen && 'Open'}` }, this.showBackdrop && h("div", { key: 'fcdf3d8cde0e0e7a55c63775f3b273537b52bea7', class: "Backdrop", onClick: this.onClose }), this.showWinAnimation && h("div", { key: '83e715fb8d3c5f4f7b5e5966fe9d4514c546e663', class: "ModalWinAnimation" }), h("div", { key: 'e309cf1d60a5f23c98fd10219a390f6b6fe3ccee', class: "ModalContent GradientBorder Container", part: "modal-content" }, h("div", { key: '9512aae0d774d647862060fdc10b20ad73287b75', class: "InnerContainer", part: "inner-container" }, h("div", { key: '6ae4466f071b01b4910c6e4d5cb07200f07a3aee', class: "ModalHeader" }, this.showCloseButton && (h("div", { key: 'e3f498699a76d5d336266327569b21670b07a097', class: "close-modal", part: "close-button", onClick: this.onClose }, h("img", { key: 'ce3ceb9083ef59952daa01872b50acff28101e55', src: closeIcon }))), h("slot", { key: '68324278177e10ef244a850196cae86c86bbab14', name: "header" })), h("div", { key: '5c341711027e532542dc04f14e46c5cb95aa0d20', class: "ModalBody" }, h("slot", { key: '27f5279c49a3d936e49a29655b07d28e72f526f4', name: "body" })), h("div", { key: '81fd4db2428a5a48286c4ffbaab56fdf566da612', class: "ModalFooter" }, h("slot", { key: 'cb2ab035f8b044937221c011ba13243e297ee346', name: "footer" }))))));
47
+ }
48
+ static get is() { return "casino-challenges-modal"; }
49
+ static get encapsulation() { return "shadow"; }
50
+ static get originalStyleUrls() {
51
+ return {
52
+ "$": ["casino-challenges-modal.scss"]
53
+ };
54
+ }
55
+ static get styleUrls() {
56
+ return {
57
+ "$": ["casino-challenges-modal.css"]
58
+ };
59
+ }
60
+ static get properties() {
61
+ return {
62
+ "mbSource": {
63
+ "type": "string",
64
+ "mutable": false,
65
+ "complexType": {
66
+ "original": "string",
67
+ "resolved": "string",
68
+ "references": {}
69
+ },
70
+ "required": false,
71
+ "optional": false,
72
+ "docs": {
73
+ "tags": [],
74
+ "text": ""
75
+ },
76
+ "attribute": "mb-source",
77
+ "reflect": true
78
+ },
79
+ "clientStyling": {
80
+ "type": "string",
81
+ "mutable": false,
82
+ "complexType": {
83
+ "original": "string",
84
+ "resolved": "string",
85
+ "references": {}
86
+ },
87
+ "required": false,
88
+ "optional": false,
89
+ "docs": {
90
+ "tags": [],
91
+ "text": ""
92
+ },
93
+ "attribute": "client-styling",
94
+ "reflect": true
95
+ },
96
+ "clientStylingUrl": {
97
+ "type": "string",
98
+ "mutable": false,
99
+ "complexType": {
100
+ "original": "string",
101
+ "resolved": "string",
102
+ "references": {}
103
+ },
104
+ "required": false,
105
+ "optional": false,
106
+ "docs": {
107
+ "tags": [],
108
+ "text": ""
109
+ },
110
+ "attribute": "client-styling-url",
111
+ "reflect": true
112
+ },
113
+ "isOpen": {
114
+ "type": "boolean",
115
+ "mutable": false,
116
+ "complexType": {
117
+ "original": "boolean",
118
+ "resolved": "boolean",
119
+ "references": {}
120
+ },
121
+ "required": false,
122
+ "optional": false,
123
+ "docs": {
124
+ "tags": [],
125
+ "text": ""
126
+ },
127
+ "attribute": "is-open",
128
+ "reflect": true,
129
+ "defaultValue": "false"
130
+ },
131
+ "showWinAnimation": {
132
+ "type": "boolean",
133
+ "mutable": false,
134
+ "complexType": {
135
+ "original": "boolean",
136
+ "resolved": "boolean",
137
+ "references": {}
138
+ },
139
+ "required": false,
140
+ "optional": false,
141
+ "docs": {
142
+ "tags": [],
143
+ "text": ""
144
+ },
145
+ "attribute": "show-win-animation",
146
+ "reflect": true,
147
+ "defaultValue": "false"
148
+ },
149
+ "showBackdrop": {
150
+ "type": "boolean",
151
+ "mutable": false,
152
+ "complexType": {
153
+ "original": "boolean",
154
+ "resolved": "boolean",
155
+ "references": {}
156
+ },
157
+ "required": false,
158
+ "optional": false,
159
+ "docs": {
160
+ "tags": [],
161
+ "text": ""
162
+ },
163
+ "attribute": "show-backdrop",
164
+ "reflect": true,
165
+ "defaultValue": "false"
166
+ },
167
+ "showCloseButton": {
168
+ "type": "boolean",
169
+ "mutable": false,
170
+ "complexType": {
171
+ "original": "boolean",
172
+ "resolved": "boolean",
173
+ "references": {}
174
+ },
175
+ "required": false,
176
+ "optional": false,
177
+ "docs": {
178
+ "tags": [],
179
+ "text": ""
180
+ },
181
+ "attribute": "show-close-button",
182
+ "reflect": true,
183
+ "defaultValue": "false"
184
+ }
185
+ };
186
+ }
187
+ static get events() {
188
+ return [{
189
+ "method": "close",
190
+ "name": "close",
191
+ "bubbles": true,
192
+ "cancelable": true,
193
+ "composed": true,
194
+ "docs": {
195
+ "tags": [],
196
+ "text": ""
197
+ },
198
+ "complexType": {
199
+ "original": "void",
200
+ "resolved": "void",
201
+ "references": {}
202
+ }
203
+ }];
204
+ }
205
+ static get watchers() {
206
+ return [{
207
+ "propName": "clientStyling",
208
+ "methodName": "handleClientStylingChange"
209
+ }, {
210
+ "propName": "clientStylingUrl",
211
+ "methodName": "handleClientStylingUrlChange"
212
+ }, {
213
+ "propName": "mbSource",
214
+ "methodName": "handleMbSourceChange"
215
+ }];
216
+ }
217
+ }
@@ -0,0 +1 @@
1
+ export { CasinoChallengesModal } from './casino-challenges-modal';
@@ -0,0 +1 @@
1
+ export * from './components/casino-challenges-modal';
@@ -0,0 +1,3 @@
1
+ export function format(first, middle, last) {
2
+ return (first || '') + (middle ? ` ${middle}` : '') + (last ? ` ${last}` : '');
3
+ }
@@ -0,0 +1,3 @@
1
+ const globalScripts = () => {};
2
+
3
+ export { globalScripts as g };
@@ -0,0 +1,180 @@
1
+ import { r as registerInstance, c as createEvent, h } from './index-27d1076a.js';
2
+
3
+ const StyleCacheKey = '__WIDGET_GLOBAL_STYLE_CACHE__';
4
+
5
+ /**
6
+ * @name setClientStyling
7
+ * @description Method used to create and append to the passed element of the widget a style element with the content received
8
+ * @param {HTMLElement} stylingContainer The reference element of the widget
9
+ * @param {string} clientStyling The style content
10
+ */
11
+ function setClientStyling(stylingContainer, clientStyling) {
12
+ if (stylingContainer) {
13
+ const sheet = document.createElement('style');
14
+ sheet.innerHTML = clientStyling;
15
+ stylingContainer.appendChild(sheet);
16
+ }
17
+ }
18
+
19
+ /**
20
+ * @name setClientStylingURL
21
+ * @description Method used to create and append to the passed element of the widget a style element with the content fetched from a given URL
22
+ * @param {HTMLElement} stylingContainer The reference element of the widget
23
+ * @param {string} clientStylingUrl The URL of the style content
24
+ */
25
+ function setClientStylingURL(stylingContainer, clientStylingUrl) {
26
+ if (!stylingContainer || !clientStylingUrl) return;
27
+
28
+ const url = new URL(clientStylingUrl);
29
+
30
+ fetch(url.href)
31
+ .then((res) => res.text())
32
+ .then((data) => {
33
+ const cssFile = document.createElement('style');
34
+ cssFile.innerHTML = data;
35
+ if (stylingContainer) {
36
+ stylingContainer.appendChild(cssFile);
37
+ }
38
+ })
39
+ .catch((err) => {
40
+ console.error('There was an error while trying to load client styling from URL', err);
41
+ });
42
+ }
43
+
44
+ /**
45
+ * @name setStreamLibrary
46
+ * @description Method used to create and append to the passed element of the widget a style element with content fetched from the MessageBus
47
+ * @param {HTMLElement} stylingContainer The highest element of the widget
48
+ * @param {string} domain The domain from where the content should be fetched (e.g. 'Casino.Style', 'App.Style', 'casino-footer.style', etc.)
49
+ * @param {ref} subscription A reference to a variable where the subscription should be saved for unsubscribing when no longer needed
50
+ * @param {boolean} useAdoptedStyleSheets A flag to gradually enable testing of adoptedStyleSheets
51
+ */
52
+ function setStreamStyling(stylingContainer, domain, subscription, useAdoptedStyleSheets = false) {
53
+ if (!window.emMessageBus) return;
54
+
55
+ const supportAdoptStyle = 'adoptedStyleSheets' in Document.prototype;
56
+
57
+ if (!supportAdoptStyle || !useAdoptedStyleSheets) {
58
+ subscription = getStyleTagSubscription(stylingContainer, domain);
59
+
60
+ return subscription;
61
+ }
62
+
63
+ if (!window[StyleCacheKey]) {
64
+ window[StyleCacheKey] = {};
65
+ }
66
+ subscription = getAdoptStyleSubscription(stylingContainer, domain);
67
+
68
+ const originalUnsubscribe = subscription.unsubscribe.bind(subscription);
69
+ const wrappedUnsubscribe = () => {
70
+ if (window[StyleCacheKey][domain]) {
71
+ const cachedObject = window[StyleCacheKey][domain];
72
+ cachedObject.refCount > 1
73
+ ? (cachedObject.refCount = cachedObject.refCount - 1)
74
+ : delete window[StyleCacheKey][domain];
75
+ }
76
+
77
+ originalUnsubscribe();
78
+ };
79
+ subscription.unsubscribe = wrappedUnsubscribe;
80
+
81
+ return subscription;
82
+ }
83
+
84
+ function getStyleTagSubscription(stylingContainer, domain) {
85
+ const sheet = document.createElement('style');
86
+
87
+ return window.emMessageBus.subscribe(domain, (data) => {
88
+ if (stylingContainer) {
89
+ sheet.innerHTML = data;
90
+ stylingContainer.appendChild(sheet);
91
+ }
92
+ });
93
+ }
94
+
95
+ function getAdoptStyleSubscription(stylingContainer, domain) {
96
+ return window.emMessageBus.subscribe(domain, (data) => {
97
+ if (!stylingContainer) return;
98
+
99
+ const shadowRoot = stylingContainer.getRootNode();
100
+ const cacheStyleObject = window[StyleCacheKey];
101
+ let cachedStyle = cacheStyleObject[domain] && cacheStyleObject[domain].sheet;
102
+
103
+ if (!cachedStyle) {
104
+ cachedStyle = new CSSStyleSheet();
105
+ cachedStyle.replaceSync(data);
106
+ cacheStyleObject[domain] = {
107
+ sheet: cachedStyle,
108
+ refCount: 1
109
+ };
110
+ } else {
111
+ cacheStyleObject[domain].refCount = cacheStyleObject[domain].refCount + 1;
112
+ }
113
+
114
+ const currentSheets = shadowRoot.adoptedStyleSheets || [];
115
+ if (!currentSheets.includes(cachedStyle)) {
116
+ shadowRoot.adoptedStyleSheets = [...currentSheets, cachedStyle];
117
+ }
118
+ });
119
+ }
120
+
121
+ const xCloseSvg = 'data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjIiIGhlaWdodD0iMjIiIHZpZXdCb3g9IjAgMCAyMiAyMiIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZmlsbC1ydWxlPSJldmVub2RkIiBjbGlwLXJ1bGU9ImV2ZW5vZGQiIGQ9Ik00Ljg1MTQ5IDQuODUxOThDNS4yMDk0NyA0LjQ5NCA1Ljc4OTg4IDQuNDk0IDYuMTQ3ODYgNC44NTE5OEwxMC45OTk3IDkuNzAzOEwxNS44NTE1IDQuODUxOThDMTYuMjA5NSA0LjQ5NCAxNi43ODk5IDQuNDk0IDE3LjE0NzkgNC44NTE5OEMxNy41MDU4IDUuMjA5OTYgMTcuNTA1OCA1Ljc5MDM2IDE3LjE0NzkgNi4xNDgzNEwxMi4yOTYgMTEuMDAwMkwxNy4xNDc5IDE1Ljg1MkMxNy41MDU4IDE2LjIxIDE3LjUwNTggMTYuNzkwNCAxNy4xNDc5IDE3LjE0ODNDMTYuNzg5OSAxNy41MDYzIDE2LjIwOTUgMTcuNTA2MyAxNS44NTE1IDE3LjE0ODNMMTAuOTk5NyAxMi4yOTY1TDYuMTQ3ODYgMTcuMTQ4M0M1Ljc4OTg4IDE3LjUwNjMgNS4yMDk0NyAxNy41MDYzIDQuODUxNDkgMTcuMTQ4M0M0LjQ5MzUxIDE2Ljc5MDQgNC40OTM1MSAxNi4yMSA0Ljg1MTQ5IDE1Ljg1Mkw5LjcwMzMxIDExLjAwMDJMNC44NTE0OSA2LjE0ODM0QzQuNDkzNTEgNS43OTAzNiA0LjQ5MzUxIDUuMjA5OTYgNC44NTE0OSA0Ljg1MTk4WiIgZmlsbD0id2hpdGUiLz4KPC9zdmc+Cg==';
122
+
123
+ const casinoChallengesModalCss = ":host {\n display: block;\n font-family: inherit;\n}\n\n* {\n box-sizing: border-box;\n margin: 0;\n padding: 0;\n}\n\nbutton {\n border: none;\n background: none;\n cursor: pointer;\n touch-action: manipulation;\n}\nbutton:focus {\n outline: none;\n}\n\n.Backdrop {\n position: absolute;\n background-color: rgba(0, 0, 0, 0.6);\n opacity: 0.6;\n width: 100%;\n height: 100%;\n z-index: 301;\n}\n\n.ModalOverlay {\n display: none;\n position: fixed;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n background-color: rgba(0, 0, 0, 0);\n justify-content: center;\n align-items: center;\n z-index: 300;\n}\n\n.ModalOverlay.Open {\n display: flex;\n}\n\n.ModalContent {\n display: flex;\n flex-direction: column;\n align-items: center;\n position: relative;\n z-index: 302;\n background: linear-gradient(90deg, var(--emw--color-background, #003E5C) 0.05%, var(--emw--color-background-secondary, #113B21) 87.69%);\n padding: 26px;\n border-radius: 26px;\n border: 2px solid var(--emw--color-primary-variant, #1E654F);\n width: 450px;\n max-width: 90%;\n text-align: center;\n max-height: 90dvh;\n min-height: 100px;\n font-family: \"Roboto\", sans-serif;\n transition: all 0.3s;\n}\n\n.InnerContainer {\n border-radius: 20px;\n background: #F9F8F8;\n padding: 25px;\n width: 100%;\n}\n\n.ModalHeader {\n color: var(--emw--color-typography, #212529);\n text-align: center;\n font-family: var(--emw--button-typography, \"PF BeauSans Pro\", sans-serif);\n font-size: 16px;\n font-style: normal;\n font-weight: 700;\n line-height: normal;\n text-transform: uppercase;\n letter-spacing: 1px;\n}\n\n.ModalAction {\n border-radius: var(--emw--button-border-radius, 99px);\n border: 2px solid var(--emw--button-border-color, #083B17);\n background: linear-gradient(90deg, var(--emw--color-primary, #24AA4D) 0%, var(--emw--color-background-secondary, #113F21) 100%);\n padding: 9px 20px;\n margin-top: 10px;\n text-transform: uppercase;\n color: var(--emw--button-text-color, #FFF);\n text-align: center;\n font-family: var(--emw--button-typography, \"PF BeauSans Pro\", sans-serif);\n font-size: 12px;\n font-style: normal;\n font-weight: 700;\n letter-spacing: 1px;\n line-height: 1;\n}\n\n.close-modal {\n position: absolute;\n width: 32px;\n height: 32px;\n background: rgba(219, 255, 243, 0.2);\n border-radius: 16px;\n right: 20px;\n top: 16px;\n display: flex;\n justify-content: center;\n align-items: center;\n cursor: pointer;\n}\n\n@Container casino-challenges-modal (min-width: 576px) {\n .close-modal {\n top: 50px;\n }\n}";
124
+ const CasinoChallengesModalStyle0 = casinoChallengesModalCss;
125
+
126
+ const CasinoChallengesModal = class {
127
+ constructor(hostRef) {
128
+ registerInstance(this, hostRef);
129
+ this.close = createEvent(this, "close", 7);
130
+ this.onClose = () => {
131
+ this.close.emit();
132
+ };
133
+ this.mbSource = undefined;
134
+ this.clientStyling = undefined;
135
+ this.clientStylingUrl = undefined;
136
+ this.isOpen = false;
137
+ this.showWinAnimation = false;
138
+ this.showBackdrop = false;
139
+ this.showCloseButton = false;
140
+ }
141
+ handleClientStylingChange(newValue, oldValue) {
142
+ if (newValue != oldValue) {
143
+ setClientStyling(this.stylingContainer, this.clientStyling);
144
+ }
145
+ }
146
+ handleClientStylingUrlChange(newValue, oldValue) {
147
+ if (newValue != oldValue) {
148
+ setClientStylingURL(this.stylingContainer, this.clientStylingUrl);
149
+ }
150
+ }
151
+ handleMbSourceChange(newValue, oldValue) {
152
+ if (newValue != oldValue) {
153
+ setStreamStyling(this.stylingContainer, `${this.mbSource}.Style`, this.stylingSubscription);
154
+ }
155
+ }
156
+ componentDidLoad() {
157
+ if (this.stylingContainer) {
158
+ if (this.mbSource)
159
+ setStreamStyling(this.stylingContainer, `${this.mbSource}.Style`, this.stylingSubscription);
160
+ if (this.clientStyling)
161
+ setClientStyling(this.stylingContainer, this.clientStyling);
162
+ if (this.clientStylingUrl)
163
+ setClientStylingURL(this.stylingContainer, this.clientStylingUrl);
164
+ }
165
+ }
166
+ disconnectedCallback() {
167
+ this.stylingSubscription && this.stylingSubscription.unsubscribe();
168
+ }
169
+ render() {
170
+ return (h("div", { key: '760f548283506b890c94b5a31b2f482977dad63b', ref: (el) => (this.stylingContainer = el), class: `ModalOverlay ${this.isOpen && 'Open'}` }, this.showBackdrop && h("div", { key: 'fcdf3d8cde0e0e7a55c63775f3b273537b52bea7', class: "Backdrop", onClick: this.onClose }), this.showWinAnimation && h("div", { key: '83e715fb8d3c5f4f7b5e5966fe9d4514c546e663', class: "ModalWinAnimation" }), h("div", { key: 'e309cf1d60a5f23c98fd10219a390f6b6fe3ccee', class: "ModalContent GradientBorder Container", part: "modal-content" }, h("div", { key: '9512aae0d774d647862060fdc10b20ad73287b75', class: "InnerContainer", part: "inner-container" }, h("div", { key: '6ae4466f071b01b4910c6e4d5cb07200f07a3aee', class: "ModalHeader" }, this.showCloseButton && (h("div", { key: 'e3f498699a76d5d336266327569b21670b07a097', class: "close-modal", part: "close-button", onClick: this.onClose }, h("img", { key: 'ce3ceb9083ef59952daa01872b50acff28101e55', src: xCloseSvg }))), h("slot", { key: '68324278177e10ef244a850196cae86c86bbab14', name: "header" })), h("div", { key: '5c341711027e532542dc04f14e46c5cb95aa0d20', class: "ModalBody" }, h("slot", { key: '27f5279c49a3d936e49a29655b07d28e72f526f4', name: "body" })), h("div", { key: '81fd4db2428a5a48286c4ffbaab56fdf566da612', class: "ModalFooter" }, h("slot", { key: 'cb2ab035f8b044937221c011ba13243e297ee346', name: "footer" }))))));
171
+ }
172
+ static get watchers() { return {
173
+ "clientStyling": ["handleClientStylingChange"],
174
+ "clientStylingUrl": ["handleClientStylingUrlChange"],
175
+ "mbSource": ["handleMbSourceChange"]
176
+ }; }
177
+ };
178
+ CasinoChallengesModal.style = CasinoChallengesModalStyle0;
179
+
180
+ export { CasinoChallengesModal as C };
@@ -0,0 +1,2 @@
1
+ export { C as casino_challenges_modal } from './casino-challenges-modal-2fc23147.js';
2
+ import './index-27d1076a.js';
@@ -0,0 +1,20 @@
1
+ import { p as promiseResolve, b as bootstrapLazy } from './index-27d1076a.js';
2
+ export { s as setNonce } from './index-27d1076a.js';
3
+ import { g as globalScripts } from './app-globals-0f993ce5.js';
4
+
5
+ /*
6
+ Stencil Client Patch Browser v4.19.2 | MIT Licensed | https://stenciljs.com
7
+ */
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);
15
+ };
16
+
17
+ patchBrowser().then(async (options) => {
18
+ await globalScripts();
19
+ return bootstrapLazy([["casino-challenges-modal",[[1,"casino-challenges-modal",{"mbSource":[513,"mb-source"],"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"isOpen":[516,"is-open"],"showWinAnimation":[516,"show-win-animation"],"showBackdrop":[516,"show-backdrop"],"showCloseButton":[516,"show-close-button"]},null,{"clientStyling":["handleClientStylingChange"],"clientStylingUrl":["handleClientStylingUrlChange"],"mbSource":["handleMbSourceChange"]}]]]], options);
20
+ });