@everymatrix/user-deposit-withdrawal 1.55.0 → 1.56.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.
- package/dist/cjs/{index-43a33fec.js → index-8df72484.js} +174 -74
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/user-deposit-withdrawal.cjs.entry.js +107 -54
- package/dist/cjs/user-deposit-withdrawal.cjs.js +3 -3
- package/dist/collection/collection-manifest.json +1 -1
- package/dist/collection/components/user-deposit-withdrawal/user-deposit-withdrawal.js +117 -54
- package/dist/esm/{index-657e7a14.js → index-c7e52808.js} +174 -74
- package/dist/esm/loader.js +3 -3
- package/dist/esm/user-deposit-withdrawal.entry.js +107 -54
- package/dist/esm/user-deposit-withdrawal.js +4 -4
- package/dist/types/Users/adrian.pripon/Documents/Work/widgets-monorepo/packages/stencil/user-deposit-withdrawal/.stencil/packages/stencil/user-deposit-withdrawal/stencil.config.d.ts +2 -0
- package/dist/types/Users/adrian.pripon/Documents/Work/widgets-monorepo/packages/stencil/user-deposit-withdrawal/.stencil/packages/stencil/user-deposit-withdrawal/stencil.config.dev.d.ts +2 -0
- package/dist/types/components/user-deposit-withdrawal/user-deposit-withdrawal.d.ts +7 -4
- package/dist/types/components.d.ts +8 -0
- package/dist/user-deposit-withdrawal/p-0522d925.entry.js +1 -0
- package/dist/user-deposit-withdrawal/p-2ae4c897.js +2 -0
- package/dist/user-deposit-withdrawal/user-deposit-withdrawal.esm.js +1 -1
- package/package.json +1 -1
- package/dist/types/Users/maria.bumbar/Desktop/widgets-monorepo/packages/stencil/user-deposit-withdrawal/.stencil/packages/stencil/user-deposit-withdrawal/stencil.config.d.ts +0 -2
- package/dist/types/Users/maria.bumbar/Desktop/widgets-monorepo/packages/stencil/user-deposit-withdrawal/.stencil/packages/stencil/user-deposit-withdrawal/stencil.config.dev.d.ts +0 -2
- package/dist/user-deposit-withdrawal/p-0913d346.entry.js +0 -1
- package/dist/user-deposit-withdrawal/p-8690bdb0.js +0 -2
- /package/dist/types/Users/{maria.bumbar/Desktop → adrian.pripon/Documents/Work}/widgets-monorepo/packages/stencil/user-deposit-withdrawal/.stencil/tools/plugins/index.d.ts +0 -0
- /package/dist/types/Users/{maria.bumbar/Desktop → adrian.pripon/Documents/Work}/widgets-monorepo/packages/stencil/user-deposit-withdrawal/.stencil/tools/plugins/stencil-clean-deps-plugin.d.ts +0 -0
- /package/dist/types/Users/{maria.bumbar/Desktop → adrian.pripon/Documents/Work}/widgets-monorepo/packages/stencil/user-deposit-withdrawal/.stencil/tools/plugins/vite-chunk-plugin.d.ts +0 -0
- /package/dist/types/Users/{maria.bumbar/Desktop → adrian.pripon/Documents/Work}/widgets-monorepo/packages/stencil/user-deposit-withdrawal/.stencil/tools/plugins/vite-clean-deps-plugin.d.ts +0 -0
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-8df72484.js');
|
|
6
6
|
|
|
7
7
|
const DEFAULT_LANGUAGE = 'en';
|
|
8
8
|
const SUPPORTED_LANGUAGES = ['ro', 'en', 'fr', 'hr', 'en-us', 'es-mx', 'pt-br', 'es', 'de', 'pt', 'tr'];
|
|
@@ -126,6 +126,63 @@ const translate = (key, customLang) => {
|
|
|
126
126
|
return TRANSLATIONS[lang !== undefined && SUPPORTED_LANGUAGES.includes(lang) ? lang : DEFAULT_LANGUAGE][key];
|
|
127
127
|
};
|
|
128
128
|
|
|
129
|
+
/**
|
|
130
|
+
* @name setClientStyling
|
|
131
|
+
* @description Method used to create and append to the passed element of the widget a style element with the content received
|
|
132
|
+
* @param {HTMLElement} stylingContainer The reference element of the widget
|
|
133
|
+
* @param {string} clientStyling The style content
|
|
134
|
+
*/
|
|
135
|
+
function setClientStyling(stylingContainer, clientStyling) {
|
|
136
|
+
if (stylingContainer) {
|
|
137
|
+
const sheet = document.createElement('style');
|
|
138
|
+
sheet.innerHTML = clientStyling;
|
|
139
|
+
stylingContainer.appendChild(sheet);
|
|
140
|
+
}
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
/**
|
|
144
|
+
* @name setClientStylingURL
|
|
145
|
+
* @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
|
|
146
|
+
* @param {HTMLElement} stylingContainer The reference element of the widget
|
|
147
|
+
* @param {string} clientStylingUrl The URL of the style content
|
|
148
|
+
*/
|
|
149
|
+
function setClientStylingURL(stylingContainer, clientStylingUrl) {
|
|
150
|
+
const url = new URL(clientStylingUrl);
|
|
151
|
+
|
|
152
|
+
fetch(url.href)
|
|
153
|
+
.then((res) => res.text())
|
|
154
|
+
.then((data) => {
|
|
155
|
+
const cssFile = document.createElement('style');
|
|
156
|
+
cssFile.innerHTML = data;
|
|
157
|
+
if (stylingContainer) {
|
|
158
|
+
stylingContainer.appendChild(cssFile);
|
|
159
|
+
}
|
|
160
|
+
})
|
|
161
|
+
.catch((err) => {
|
|
162
|
+
console.error('There was an error while trying to load client styling from URL', err);
|
|
163
|
+
});
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
/**
|
|
167
|
+
* @name setStreamLibrary
|
|
168
|
+
* @description Method used to create and append to the passed element of the widget a style element with content fetched from the MessageBus
|
|
169
|
+
* @param {HTMLElement} stylingContainer The highest element of the widget
|
|
170
|
+
* @param {string} domain The domain from where the content should be fetched (e.g. 'Casino.Style', 'App.Style', 'casino-footer.style', etc.)
|
|
171
|
+
* @param {ref} subscription A reference to a variable where the subscription should be saved for unsubscribing when no longer needed
|
|
172
|
+
*/
|
|
173
|
+
function setStreamStyling(stylingContainer, domain, subscription) {
|
|
174
|
+
if (window.emMessageBus) {
|
|
175
|
+
const sheet = document.createElement('style');
|
|
176
|
+
|
|
177
|
+
window.emMessageBus.subscribe(domain, (data) => {
|
|
178
|
+
sheet.innerHTML = data;
|
|
179
|
+
if (stylingContainer) {
|
|
180
|
+
stylingContainer.appendChild(sheet);
|
|
181
|
+
}
|
|
182
|
+
});
|
|
183
|
+
}
|
|
184
|
+
}
|
|
185
|
+
|
|
129
186
|
/**
|
|
130
187
|
* @name isMobile
|
|
131
188
|
* @description A method that returns if the browser used to access the app is from a mobile device or not
|
|
@@ -165,53 +222,35 @@ const emptyFunction = () => { };
|
|
|
165
222
|
const UserDepositWithdrawal = class {
|
|
166
223
|
constructor(hostRef) {
|
|
167
224
|
index.registerInstance(this, hostRef);
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
this.errorCodes = ["21123", "21122"];
|
|
172
|
-
this.setClientStyling = () => {
|
|
173
|
-
let sheet = document.createElement('style');
|
|
174
|
-
sheet.innerHTML = this.clientStyling;
|
|
175
|
-
this.stylingContainer.prepend(sheet);
|
|
176
|
-
};
|
|
177
|
-
this.setClientStylingURL = () => {
|
|
178
|
-
let url = new URL(this.clientStylingUrl);
|
|
179
|
-
let cssFile = document.createElement('style');
|
|
180
|
-
fetch(url.href)
|
|
181
|
-
.then((res) => res.text())
|
|
182
|
-
.then((data) => {
|
|
183
|
-
cssFile.innerHTML = data;
|
|
184
|
-
setTimeout(() => { this.stylingContainer.prepend(cssFile); }, 1);
|
|
185
|
-
})
|
|
186
|
-
.catch((err) => {
|
|
187
|
-
console.log('error ', err);
|
|
188
|
-
});
|
|
189
|
-
};
|
|
225
|
+
/**
|
|
226
|
+
* Client custom styling via inline style
|
|
227
|
+
*/
|
|
190
228
|
this.clientStyling = '';
|
|
229
|
+
/**
|
|
230
|
+
* Client custom styling via url
|
|
231
|
+
*/
|
|
191
232
|
this.clientStylingUrl = '';
|
|
233
|
+
/**
|
|
234
|
+
* Translations via URL
|
|
235
|
+
*/
|
|
192
236
|
this.translationUrl = '';
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
this.language = undefined;
|
|
197
|
-
this.productType = undefined;
|
|
198
|
-
this.userId = undefined;
|
|
199
|
-
this.session = undefined;
|
|
200
|
-
this.successUrl = undefined;
|
|
201
|
-
this.cancelUrl = undefined;
|
|
202
|
-
this.failUrl = undefined;
|
|
203
|
-
this.sportsUrl = undefined;
|
|
204
|
-
this.casinoUrl = undefined;
|
|
205
|
-
this.contactUrl = undefined;
|
|
206
|
-
this.depositUrl = undefined;
|
|
237
|
+
/*
|
|
238
|
+
* Operator selected currency
|
|
239
|
+
*/
|
|
207
240
|
this.currency = '';
|
|
241
|
+
/*
|
|
242
|
+
* Display bonus dropdown
|
|
243
|
+
*/
|
|
208
244
|
this.showBonusSelectionInput = 'true';
|
|
245
|
+
/*
|
|
246
|
+
* State of deposit - short cashier enabled or not
|
|
247
|
+
*/
|
|
209
248
|
this.isShortCashier = false;
|
|
210
|
-
this.homeUrl = undefined;
|
|
211
249
|
this.beforeRedirect = emptyFunction;
|
|
212
|
-
this.
|
|
213
|
-
this.
|
|
214
|
-
this.
|
|
250
|
+
this.bindedHandler = this.handleMessage.bind(this);
|
|
251
|
+
this.userAgent = window.navigator.userAgent;
|
|
252
|
+
this.isMobile = isMobile(this.userAgent);
|
|
253
|
+
this.errorCodes = ["21123", "21122"];
|
|
215
254
|
}
|
|
216
255
|
get typeParameter() {
|
|
217
256
|
if (this.type === 'deposit') {
|
|
@@ -224,6 +263,17 @@ const UserDepositWithdrawal = class {
|
|
|
224
263
|
watchLoadWidget() {
|
|
225
264
|
this.loadWidget();
|
|
226
265
|
}
|
|
266
|
+
handleClientStylingChange(newValue, oldValue) {
|
|
267
|
+
if (newValue != oldValue) {
|
|
268
|
+
setClientStyling(this.stylingContainer, this.clientStyling);
|
|
269
|
+
}
|
|
270
|
+
}
|
|
271
|
+
handleClientStylingChangeURL(newValue, oldValue) {
|
|
272
|
+
if (newValue != oldValue) {
|
|
273
|
+
if (this.clientStylingUrl)
|
|
274
|
+
setClientStylingURL(this.stylingContainer, this.clientStylingUrl);
|
|
275
|
+
}
|
|
276
|
+
}
|
|
227
277
|
async componentWillLoad() {
|
|
228
278
|
await this.loadWidget();
|
|
229
279
|
if (this.translationUrl) {
|
|
@@ -235,24 +285,25 @@ const UserDepositWithdrawal = class {
|
|
|
235
285
|
window.postMessage({ type: 'PlayerAccountMenuActive', isMobile }, window.location.href);
|
|
236
286
|
}
|
|
237
287
|
componentDidLoad() {
|
|
288
|
+
if (this.stylingContainer) {
|
|
289
|
+
if (window.emMessageBus != undefined) {
|
|
290
|
+
setStreamStyling(this.stylingContainer, `${this.mbSource}.Style`);
|
|
291
|
+
}
|
|
292
|
+
else {
|
|
293
|
+
if (this.clientStyling)
|
|
294
|
+
setClientStyling(this.stylingContainer, this.clientStyling);
|
|
295
|
+
if (this.clientStylingUrl)
|
|
296
|
+
setClientStylingURL(this.stylingContainer, this.clientStylingUrl);
|
|
297
|
+
}
|
|
298
|
+
}
|
|
238
299
|
window.addEventListener('message', this.bindedHandler, false);
|
|
239
300
|
}
|
|
240
301
|
disconnectedCallback() {
|
|
241
302
|
window.removeEventListener('message', this.bindedHandler, false);
|
|
242
|
-
|
|
243
|
-
componentDidRender() {
|
|
244
|
-
// start custom styling area
|
|
245
|
-
if (!this.limitStylingAppends && this.stylingContainer) {
|
|
246
|
-
if (this.clientStyling)
|
|
247
|
-
this.setClientStyling();
|
|
248
|
-
if (this.clientStylingUrl)
|
|
249
|
-
this.setClientStylingURL();
|
|
250
|
-
this.limitStylingAppends = true;
|
|
251
|
-
}
|
|
252
|
-
// end custom styling area
|
|
303
|
+
this.stylingSubscription && this.stylingSubscription.unsubscribe();
|
|
253
304
|
}
|
|
254
305
|
render() {
|
|
255
|
-
return (index.h(index.Host, { key: '
|
|
306
|
+
return (index.h(index.Host, { key: '4963fd9b7ce608f13fd464996c085c29045fcd59' }, index.h("div", { key: '1fe503816ddb4f18d50545f0f627dd917e6f62ec', ref: el => this.stylingContainer = el }, (!(this.isMobile && !this.isShortCashier) && (index.h("h2", { key: '5bf653f70da5f95173a7dc2c7067d0968876b50a', class: "CategoryTitle" }, translate(this.typeParameter === 'Withdraw' ? 'Withdraw' : 'Deposit', this.language)))), index.h("div", { key: '44a47893b6b2ce83e45f69e8997aa6e450968941', class: `DepositWithdrawalWrapper ${this.isShortCashier ? 'ShortCashier' : ''}`, style: { height: this.dynamicHeight, marginTop: this.isShortCashier ? '30px' : '0' } }, index.h("div", { key: '949862539b439d5f2375a08115a7389bf355dd2c' }, (this.isMobile && !this.isShortCashier ?
|
|
256
307
|
index.h("div", { class: "MenuReturnButton", onClick: () => this.toggleScreen(this.isMobile) }, index.h("svg", { xmlns: "http://www.w3.org/2000/svg", width: "15", height: "15", viewBox: "0 0 15 15" }, index.h("defs", null), index.h("g", { transform: "translate(-20 -158)" }, index.h("g", { transform: "translate(20 158)" }, index.h("path", { class: "aaa", d: "M7.5,0,6.136,1.364,11.3,6.526H0V8.474H11.3L6.136,13.636,7.5,15,15,7.5Z", transform: "translate(15 15) rotate(180)" })))), index.h("h2", { class: "CategoryTitleMobile" }, translate(this.typeParameter === 'Withdraw' ? 'Withdraw' : 'Deposit', this.language)))
|
|
257
308
|
: null)), this.cashierInfoUrl ? index.h("iframe", { width: "100%", height: "100%", src: this.cashierInfoUrl }) : index.h("h3", { class: "ErrorMessage" }, this.type === 'deposit' ? translate('denyDeposit', this.language) : translate('denyWithdrawal', this.language))))));
|
|
258
309
|
}
|
|
@@ -362,7 +413,9 @@ const UserDepositWithdrawal = class {
|
|
|
362
413
|
"userId": ["watchLoadWidget"],
|
|
363
414
|
"isShortCashier": ["watchLoadWidget"],
|
|
364
415
|
"currency": ["watchLoadWidget"],
|
|
365
|
-
"showBonusSelectionInput": ["watchLoadWidget"]
|
|
416
|
+
"showBonusSelectionInput": ["watchLoadWidget"],
|
|
417
|
+
"clientStyling": ["handleClientStylingChange"],
|
|
418
|
+
"clientStylingUrl": ["handleClientStylingChangeURL"]
|
|
366
419
|
}; }
|
|
367
420
|
};
|
|
368
421
|
UserDepositWithdrawal.style = UserDepositWithdrawalStyle0;
|
|
@@ -2,11 +2,11 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-8df72484.js');
|
|
6
6
|
const appGlobals = require('./app-globals-3a1e7e63.js');
|
|
7
7
|
|
|
8
8
|
/*
|
|
9
|
-
Stencil Client Patch Browser v4.
|
|
9
|
+
Stencil Client Patch Browser v4.26.0 | MIT Licensed | https://stenciljs.com
|
|
10
10
|
*/
|
|
11
11
|
var patchBrowser = () => {
|
|
12
12
|
const importMeta = (typeof document === 'undefined' ? new (require('u' + 'rl').URL)('file:' + __filename).href : (document.currentScript && document.currentScript.src || new URL('user-deposit-withdrawal.cjs.js', document.baseURI).href));
|
|
@@ -19,7 +19,7 @@ var patchBrowser = () => {
|
|
|
19
19
|
|
|
20
20
|
patchBrowser().then(async (options) => {
|
|
21
21
|
await appGlobals.globalScripts();
|
|
22
|
-
return index.bootstrapLazy([["user-deposit-withdrawal.cjs",[[1,"user-deposit-withdrawal",{"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"translationUrl":[513,"translation-url"],"endpoint":[513],"type":[513],"channel":[513],"language":[513],"productType":[513,"product-type"],"userId":[513,"user-id"],"session":[513],"successUrl":[513,"success-url"],"cancelUrl":[513,"cancel-url"],"failUrl":[513,"fail-url"],"sportsUrl":[513,"sports-url"],"casinoUrl":[513,"casino-url"],"contactUrl":[513,"contact-url"],"depositUrl":[513,"deposit-url"],"currency":[513],"showBonusSelectionInput":[513,"show-bonus-selection-input"],"isShortCashier":[516,"is-short-cashier"],"homeUrl":[513,"home-url"],"beforeRedirect":[16],"
|
|
22
|
+
return index.bootstrapLazy([["user-deposit-withdrawal.cjs",[[1,"user-deposit-withdrawal",{"mbSource":[513,"mb-source"],"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"translationUrl":[513,"translation-url"],"endpoint":[513],"type":[513],"channel":[513],"language":[513],"productType":[513,"product-type"],"userId":[513,"user-id"],"session":[513],"successUrl":[513,"success-url"],"cancelUrl":[513,"cancel-url"],"failUrl":[513,"fail-url"],"sportsUrl":[513,"sports-url"],"casinoUrl":[513,"casino-url"],"contactUrl":[513,"contact-url"],"depositUrl":[513,"deposit-url"],"currency":[513],"showBonusSelectionInput":[513,"show-bonus-selection-input"],"isShortCashier":[516,"is-short-cashier"],"homeUrl":[513,"home-url"],"beforeRedirect":[16],"dynamicHeight":[32],"cashierInfoUrl":[32]},null,{"session":["watchLoadWidget"],"userId":["watchLoadWidget"],"isShortCashier":["watchLoadWidget"],"currency":["watchLoadWidget"],"showBonusSelectionInput":["watchLoadWidget"],"clientStyling":["handleClientStylingChange"],"clientStylingUrl":["handleClientStylingChangeURL"]}]]]], options);
|
|
23
23
|
});
|
|
24
24
|
|
|
25
25
|
exports.setNonce = index.setNonce;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { Host, h } from "@stencil/core";
|
|
2
2
|
import { translate, getTranslations } from "../../utils/locale.utils";
|
|
3
|
+
import { setClientStyling, setClientStylingURL, setStreamStyling } from "../../../../../../../../libs/common/src/styling/index";
|
|
3
4
|
import { isMobile } from "../../utils/utils";
|
|
4
5
|
import dayjs from "dayjs";
|
|
5
6
|
import utc from "dayjs/plugin/utc";
|
|
@@ -7,53 +8,35 @@ dayjs.extend(utc);
|
|
|
7
8
|
const emptyFunction = () => { };
|
|
8
9
|
export class UserDepositWithdrawal {
|
|
9
10
|
constructor() {
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
this.errorCodes = ["21123", "21122"];
|
|
14
|
-
this.setClientStyling = () => {
|
|
15
|
-
let sheet = document.createElement('style');
|
|
16
|
-
sheet.innerHTML = this.clientStyling;
|
|
17
|
-
this.stylingContainer.prepend(sheet);
|
|
18
|
-
};
|
|
19
|
-
this.setClientStylingURL = () => {
|
|
20
|
-
let url = new URL(this.clientStylingUrl);
|
|
21
|
-
let cssFile = document.createElement('style');
|
|
22
|
-
fetch(url.href)
|
|
23
|
-
.then((res) => res.text())
|
|
24
|
-
.then((data) => {
|
|
25
|
-
cssFile.innerHTML = data;
|
|
26
|
-
setTimeout(() => { this.stylingContainer.prepend(cssFile); }, 1);
|
|
27
|
-
})
|
|
28
|
-
.catch((err) => {
|
|
29
|
-
console.log('error ', err);
|
|
30
|
-
});
|
|
31
|
-
};
|
|
11
|
+
/**
|
|
12
|
+
* Client custom styling via inline style
|
|
13
|
+
*/
|
|
32
14
|
this.clientStyling = '';
|
|
15
|
+
/**
|
|
16
|
+
* Client custom styling via url
|
|
17
|
+
*/
|
|
33
18
|
this.clientStylingUrl = '';
|
|
19
|
+
/**
|
|
20
|
+
* Translations via URL
|
|
21
|
+
*/
|
|
34
22
|
this.translationUrl = '';
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
this.language = undefined;
|
|
39
|
-
this.productType = undefined;
|
|
40
|
-
this.userId = undefined;
|
|
41
|
-
this.session = undefined;
|
|
42
|
-
this.successUrl = undefined;
|
|
43
|
-
this.cancelUrl = undefined;
|
|
44
|
-
this.failUrl = undefined;
|
|
45
|
-
this.sportsUrl = undefined;
|
|
46
|
-
this.casinoUrl = undefined;
|
|
47
|
-
this.contactUrl = undefined;
|
|
48
|
-
this.depositUrl = undefined;
|
|
23
|
+
/*
|
|
24
|
+
* Operator selected currency
|
|
25
|
+
*/
|
|
49
26
|
this.currency = '';
|
|
27
|
+
/*
|
|
28
|
+
* Display bonus dropdown
|
|
29
|
+
*/
|
|
50
30
|
this.showBonusSelectionInput = 'true';
|
|
31
|
+
/*
|
|
32
|
+
* State of deposit - short cashier enabled or not
|
|
33
|
+
*/
|
|
51
34
|
this.isShortCashier = false;
|
|
52
|
-
this.homeUrl = undefined;
|
|
53
35
|
this.beforeRedirect = emptyFunction;
|
|
54
|
-
this.
|
|
55
|
-
this.
|
|
56
|
-
this.
|
|
36
|
+
this.bindedHandler = this.handleMessage.bind(this);
|
|
37
|
+
this.userAgent = window.navigator.userAgent;
|
|
38
|
+
this.isMobile = isMobile(this.userAgent);
|
|
39
|
+
this.errorCodes = ["21123", "21122"];
|
|
57
40
|
}
|
|
58
41
|
get typeParameter() {
|
|
59
42
|
if (this.type === 'deposit') {
|
|
@@ -66,6 +49,17 @@ export class UserDepositWithdrawal {
|
|
|
66
49
|
watchLoadWidget() {
|
|
67
50
|
this.loadWidget();
|
|
68
51
|
}
|
|
52
|
+
handleClientStylingChange(newValue, oldValue) {
|
|
53
|
+
if (newValue != oldValue) {
|
|
54
|
+
setClientStyling(this.stylingContainer, this.clientStyling);
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
handleClientStylingChangeURL(newValue, oldValue) {
|
|
58
|
+
if (newValue != oldValue) {
|
|
59
|
+
if (this.clientStylingUrl)
|
|
60
|
+
setClientStylingURL(this.stylingContainer, this.clientStylingUrl);
|
|
61
|
+
}
|
|
62
|
+
}
|
|
69
63
|
async componentWillLoad() {
|
|
70
64
|
await this.loadWidget();
|
|
71
65
|
if (this.translationUrl) {
|
|
@@ -77,24 +71,25 @@ export class UserDepositWithdrawal {
|
|
|
77
71
|
window.postMessage({ type: 'PlayerAccountMenuActive', isMobile }, window.location.href);
|
|
78
72
|
}
|
|
79
73
|
componentDidLoad() {
|
|
74
|
+
if (this.stylingContainer) {
|
|
75
|
+
if (window.emMessageBus != undefined) {
|
|
76
|
+
setStreamStyling(this.stylingContainer, `${this.mbSource}.Style`, this.stylingSubscription);
|
|
77
|
+
}
|
|
78
|
+
else {
|
|
79
|
+
if (this.clientStyling)
|
|
80
|
+
setClientStyling(this.stylingContainer, this.clientStyling);
|
|
81
|
+
if (this.clientStylingUrl)
|
|
82
|
+
setClientStylingURL(this.stylingContainer, this.clientStylingUrl);
|
|
83
|
+
}
|
|
84
|
+
}
|
|
80
85
|
window.addEventListener('message', this.bindedHandler, false);
|
|
81
86
|
}
|
|
82
87
|
disconnectedCallback() {
|
|
83
88
|
window.removeEventListener('message', this.bindedHandler, false);
|
|
84
|
-
|
|
85
|
-
componentDidRender() {
|
|
86
|
-
// start custom styling area
|
|
87
|
-
if (!this.limitStylingAppends && this.stylingContainer) {
|
|
88
|
-
if (this.clientStyling)
|
|
89
|
-
this.setClientStyling();
|
|
90
|
-
if (this.clientStylingUrl)
|
|
91
|
-
this.setClientStylingURL();
|
|
92
|
-
this.limitStylingAppends = true;
|
|
93
|
-
}
|
|
94
|
-
// end custom styling area
|
|
89
|
+
this.stylingSubscription && this.stylingSubscription.unsubscribe();
|
|
95
90
|
}
|
|
96
91
|
render() {
|
|
97
|
-
return (h(Host, { key: '
|
|
92
|
+
return (h(Host, { key: '4963fd9b7ce608f13fd464996c085c29045fcd59' }, h("div", { key: '1fe503816ddb4f18d50545f0f627dd917e6f62ec', ref: el => this.stylingContainer = el }, (!(this.isMobile && !this.isShortCashier) && (h("h2", { key: '5bf653f70da5f95173a7dc2c7067d0968876b50a', class: "CategoryTitle" }, translate(this.typeParameter === 'Withdraw' ? 'Withdraw' : 'Deposit', this.language)))), h("div", { key: '44a47893b6b2ce83e45f69e8997aa6e450968941', class: `DepositWithdrawalWrapper ${this.isShortCashier ? 'ShortCashier' : ''}`, style: { height: this.dynamicHeight, marginTop: this.isShortCashier ? '30px' : '0' } }, h("div", { key: '949862539b439d5f2375a08115a7389bf355dd2c' }, (this.isMobile && !this.isShortCashier ?
|
|
98
93
|
h("div", { class: "MenuReturnButton", onClick: () => this.toggleScreen(this.isMobile) }, h("svg", { xmlns: "http://www.w3.org/2000/svg", width: "15", height: "15", viewBox: "0 0 15 15" }, h("defs", null), h("g", { transform: "translate(-20 -158)" }, h("g", { transform: "translate(20 158)" }, h("path", { class: "aaa", d: "M7.5,0,6.136,1.364,11.3,6.526H0V8.474H11.3L6.136,13.636,7.5,15,15,7.5Z", transform: "translate(15 15) rotate(180)" })))), h("h2", { class: "CategoryTitleMobile" }, translate(this.typeParameter === 'Withdraw' ? 'Withdraw' : 'Deposit', this.language)))
|
|
99
94
|
: null)), this.cashierInfoUrl ? h("iframe", { width: "100%", height: "100%", src: this.cashierInfoUrl }) : h("h3", { class: "ErrorMessage" }, this.type === 'deposit' ? translate('denyDeposit', this.language) : translate('denyWithdrawal', this.language))))));
|
|
100
95
|
}
|
|
@@ -213,6 +208,25 @@ export class UserDepositWithdrawal {
|
|
|
213
208
|
}
|
|
214
209
|
static get properties() {
|
|
215
210
|
return {
|
|
211
|
+
"mbSource": {
|
|
212
|
+
"type": "string",
|
|
213
|
+
"mutable": false,
|
|
214
|
+
"complexType": {
|
|
215
|
+
"original": "string",
|
|
216
|
+
"resolved": "string",
|
|
217
|
+
"references": {}
|
|
218
|
+
},
|
|
219
|
+
"required": false,
|
|
220
|
+
"optional": false,
|
|
221
|
+
"docs": {
|
|
222
|
+
"tags": [],
|
|
223
|
+
"text": "Client custom styling via streamStyling"
|
|
224
|
+
},
|
|
225
|
+
"getter": false,
|
|
226
|
+
"setter": false,
|
|
227
|
+
"attribute": "mb-source",
|
|
228
|
+
"reflect": true
|
|
229
|
+
},
|
|
216
230
|
"clientStyling": {
|
|
217
231
|
"type": "string",
|
|
218
232
|
"mutable": false,
|
|
@@ -227,6 +241,8 @@ export class UserDepositWithdrawal {
|
|
|
227
241
|
"tags": [],
|
|
228
242
|
"text": "Client custom styling via inline style"
|
|
229
243
|
},
|
|
244
|
+
"getter": false,
|
|
245
|
+
"setter": false,
|
|
230
246
|
"attribute": "client-styling",
|
|
231
247
|
"reflect": true,
|
|
232
248
|
"defaultValue": "''"
|
|
@@ -245,6 +261,8 @@ export class UserDepositWithdrawal {
|
|
|
245
261
|
"tags": [],
|
|
246
262
|
"text": "Client custom styling via url"
|
|
247
263
|
},
|
|
264
|
+
"getter": false,
|
|
265
|
+
"setter": false,
|
|
248
266
|
"attribute": "client-styling-url",
|
|
249
267
|
"reflect": true,
|
|
250
268
|
"defaultValue": "''"
|
|
@@ -263,6 +281,8 @@ export class UserDepositWithdrawal {
|
|
|
263
281
|
"tags": [],
|
|
264
282
|
"text": "Translations via URL"
|
|
265
283
|
},
|
|
284
|
+
"getter": false,
|
|
285
|
+
"setter": false,
|
|
266
286
|
"attribute": "translation-url",
|
|
267
287
|
"reflect": true,
|
|
268
288
|
"defaultValue": "''"
|
|
@@ -281,6 +301,8 @@ export class UserDepositWithdrawal {
|
|
|
281
301
|
"tags": [],
|
|
282
302
|
"text": "Endpoint"
|
|
283
303
|
},
|
|
304
|
+
"getter": false,
|
|
305
|
+
"setter": false,
|
|
284
306
|
"attribute": "endpoint",
|
|
285
307
|
"reflect": true
|
|
286
308
|
},
|
|
@@ -298,6 +320,8 @@ export class UserDepositWithdrawal {
|
|
|
298
320
|
"tags": [],
|
|
299
321
|
"text": ""
|
|
300
322
|
},
|
|
323
|
+
"getter": false,
|
|
324
|
+
"setter": false,
|
|
301
325
|
"attribute": "type",
|
|
302
326
|
"reflect": true
|
|
303
327
|
},
|
|
@@ -315,6 +339,8 @@ export class UserDepositWithdrawal {
|
|
|
315
339
|
"tags": [],
|
|
316
340
|
"text": ""
|
|
317
341
|
},
|
|
342
|
+
"getter": false,
|
|
343
|
+
"setter": false,
|
|
318
344
|
"attribute": "channel",
|
|
319
345
|
"reflect": true
|
|
320
346
|
},
|
|
@@ -332,6 +358,8 @@ export class UserDepositWithdrawal {
|
|
|
332
358
|
"tags": [],
|
|
333
359
|
"text": ""
|
|
334
360
|
},
|
|
361
|
+
"getter": false,
|
|
362
|
+
"setter": false,
|
|
335
363
|
"attribute": "language",
|
|
336
364
|
"reflect": true
|
|
337
365
|
},
|
|
@@ -349,6 +377,8 @@ export class UserDepositWithdrawal {
|
|
|
349
377
|
"tags": [],
|
|
350
378
|
"text": ""
|
|
351
379
|
},
|
|
380
|
+
"getter": false,
|
|
381
|
+
"setter": false,
|
|
352
382
|
"attribute": "product-type",
|
|
353
383
|
"reflect": true
|
|
354
384
|
},
|
|
@@ -366,6 +396,8 @@ export class UserDepositWithdrawal {
|
|
|
366
396
|
"tags": [],
|
|
367
397
|
"text": ""
|
|
368
398
|
},
|
|
399
|
+
"getter": false,
|
|
400
|
+
"setter": false,
|
|
369
401
|
"attribute": "user-id",
|
|
370
402
|
"reflect": true
|
|
371
403
|
},
|
|
@@ -383,6 +415,8 @@ export class UserDepositWithdrawal {
|
|
|
383
415
|
"tags": [],
|
|
384
416
|
"text": ""
|
|
385
417
|
},
|
|
418
|
+
"getter": false,
|
|
419
|
+
"setter": false,
|
|
386
420
|
"attribute": "session",
|
|
387
421
|
"reflect": true
|
|
388
422
|
},
|
|
@@ -400,6 +434,8 @@ export class UserDepositWithdrawal {
|
|
|
400
434
|
"tags": [],
|
|
401
435
|
"text": ""
|
|
402
436
|
},
|
|
437
|
+
"getter": false,
|
|
438
|
+
"setter": false,
|
|
403
439
|
"attribute": "success-url",
|
|
404
440
|
"reflect": true
|
|
405
441
|
},
|
|
@@ -417,6 +453,8 @@ export class UserDepositWithdrawal {
|
|
|
417
453
|
"tags": [],
|
|
418
454
|
"text": ""
|
|
419
455
|
},
|
|
456
|
+
"getter": false,
|
|
457
|
+
"setter": false,
|
|
420
458
|
"attribute": "cancel-url",
|
|
421
459
|
"reflect": true
|
|
422
460
|
},
|
|
@@ -434,6 +472,8 @@ export class UserDepositWithdrawal {
|
|
|
434
472
|
"tags": [],
|
|
435
473
|
"text": ""
|
|
436
474
|
},
|
|
475
|
+
"getter": false,
|
|
476
|
+
"setter": false,
|
|
437
477
|
"attribute": "fail-url",
|
|
438
478
|
"reflect": true
|
|
439
479
|
},
|
|
@@ -451,6 +491,8 @@ export class UserDepositWithdrawal {
|
|
|
451
491
|
"tags": [],
|
|
452
492
|
"text": ""
|
|
453
493
|
},
|
|
494
|
+
"getter": false,
|
|
495
|
+
"setter": false,
|
|
454
496
|
"attribute": "sports-url",
|
|
455
497
|
"reflect": true
|
|
456
498
|
},
|
|
@@ -468,6 +510,8 @@ export class UserDepositWithdrawal {
|
|
|
468
510
|
"tags": [],
|
|
469
511
|
"text": ""
|
|
470
512
|
},
|
|
513
|
+
"getter": false,
|
|
514
|
+
"setter": false,
|
|
471
515
|
"attribute": "casino-url",
|
|
472
516
|
"reflect": true
|
|
473
517
|
},
|
|
@@ -485,6 +529,8 @@ export class UserDepositWithdrawal {
|
|
|
485
529
|
"tags": [],
|
|
486
530
|
"text": ""
|
|
487
531
|
},
|
|
532
|
+
"getter": false,
|
|
533
|
+
"setter": false,
|
|
488
534
|
"attribute": "contact-url",
|
|
489
535
|
"reflect": true
|
|
490
536
|
},
|
|
@@ -502,6 +548,8 @@ export class UserDepositWithdrawal {
|
|
|
502
548
|
"tags": [],
|
|
503
549
|
"text": ""
|
|
504
550
|
},
|
|
551
|
+
"getter": false,
|
|
552
|
+
"setter": false,
|
|
505
553
|
"attribute": "deposit-url",
|
|
506
554
|
"reflect": true
|
|
507
555
|
},
|
|
@@ -519,6 +567,8 @@ export class UserDepositWithdrawal {
|
|
|
519
567
|
"tags": [],
|
|
520
568
|
"text": ""
|
|
521
569
|
},
|
|
570
|
+
"getter": false,
|
|
571
|
+
"setter": false,
|
|
522
572
|
"attribute": "currency",
|
|
523
573
|
"reflect": true,
|
|
524
574
|
"defaultValue": "''"
|
|
@@ -537,6 +587,8 @@ export class UserDepositWithdrawal {
|
|
|
537
587
|
"tags": [],
|
|
538
588
|
"text": ""
|
|
539
589
|
},
|
|
590
|
+
"getter": false,
|
|
591
|
+
"setter": false,
|
|
540
592
|
"attribute": "show-bonus-selection-input",
|
|
541
593
|
"reflect": true,
|
|
542
594
|
"defaultValue": "'true'"
|
|
@@ -555,6 +607,8 @@ export class UserDepositWithdrawal {
|
|
|
555
607
|
"tags": [],
|
|
556
608
|
"text": ""
|
|
557
609
|
},
|
|
610
|
+
"getter": false,
|
|
611
|
+
"setter": false,
|
|
558
612
|
"attribute": "is-short-cashier",
|
|
559
613
|
"reflect": true,
|
|
560
614
|
"defaultValue": "false"
|
|
@@ -573,6 +627,8 @@ export class UserDepositWithdrawal {
|
|
|
573
627
|
"tags": [],
|
|
574
628
|
"text": ""
|
|
575
629
|
},
|
|
630
|
+
"getter": false,
|
|
631
|
+
"setter": false,
|
|
576
632
|
"attribute": "home-url",
|
|
577
633
|
"reflect": true
|
|
578
634
|
},
|
|
@@ -585,7 +641,7 @@ export class UserDepositWithdrawal {
|
|
|
585
641
|
"references": {
|
|
586
642
|
"RedirectCallbackArgs": {
|
|
587
643
|
"location": "local",
|
|
588
|
-
"path": "/Users/
|
|
644
|
+
"path": "/Users/adrian.pripon/Documents/Work/widgets-monorepo/packages/stencil/user-deposit-withdrawal/src/components/user-deposit-withdrawal/user-deposit-withdrawal.tsx",
|
|
589
645
|
"id": "../../../../packages/stencil/user-deposit-withdrawal/src/components/user-deposit-withdrawal/user-deposit-withdrawal.tsx::RedirectCallbackArgs"
|
|
590
646
|
}
|
|
591
647
|
}
|
|
@@ -596,13 +652,14 @@ export class UserDepositWithdrawal {
|
|
|
596
652
|
"tags": [],
|
|
597
653
|
"text": ""
|
|
598
654
|
},
|
|
655
|
+
"getter": false,
|
|
656
|
+
"setter": false,
|
|
599
657
|
"defaultValue": "emptyFunction"
|
|
600
658
|
}
|
|
601
659
|
};
|
|
602
660
|
}
|
|
603
661
|
static get states() {
|
|
604
662
|
return {
|
|
605
|
-
"limitStylingAppends": {},
|
|
606
663
|
"dynamicHeight": {},
|
|
607
664
|
"cashierInfoUrl": {}
|
|
608
665
|
};
|
|
@@ -623,6 +680,12 @@ export class UserDepositWithdrawal {
|
|
|
623
680
|
}, {
|
|
624
681
|
"propName": "showBonusSelectionInput",
|
|
625
682
|
"methodName": "watchLoadWidget"
|
|
683
|
+
}, {
|
|
684
|
+
"propName": "clientStyling",
|
|
685
|
+
"methodName": "handleClientStylingChange"
|
|
686
|
+
}, {
|
|
687
|
+
"propName": "clientStylingUrl",
|
|
688
|
+
"methodName": "handleClientStylingChangeURL"
|
|
626
689
|
}];
|
|
627
690
|
}
|
|
628
691
|
}
|