@everymatrix/player-account-controller 0.0.237 → 0.0.238

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/index.html CHANGED
@@ -36,7 +36,7 @@
36
36
  playerid="3856617"
37
37
  session="c053558b-da3f-4ef7-9a7d-50356995089e"
38
38
  customnotifications="#58586B,#2687F6,#D0046C"
39
- lang="en"
39
+ lang="ro"
40
40
  env="stage"
41
41
  ></player-account-controller>
42
42
  <!--<player-account-controller cmsendpoint="https://wp-one-widgets.everymatrix.com/wp-json/wpone-rest/v1"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@everymatrix/player-account-controller",
3
- "version": "0.0.237",
3
+ "version": "0.0.238",
4
4
  "main": "dist/player-account-controller.js",
5
5
  "svelte": "src/index.ts",
6
6
  "scripts": {
@@ -29,8 +29,8 @@
29
29
  "typescript": "^3.9.3"
30
30
  },
31
31
  "dependencies": {
32
- "@everymatrix/player-account-menu": "^0.0.237",
33
- "@everymatrix/player-account-notifications": "^0.0.237",
32
+ "@everymatrix/player-account-menu": "^0.0.238",
33
+ "@everymatrix/player-account-notifications": "^0.0.238",
34
34
  "cross-env": "^7.0.3",
35
35
  "sirv-cli": "^1.0.0",
36
36
  "svelte": "^3.0.0"
@@ -38,5 +38,5 @@
38
38
  "publishConfig": {
39
39
  "access": "public"
40
40
  },
41
- "gitHead": "2e75c5dd54e711bed0fc8b8282d8aa284725cfcf"
41
+ "gitHead": "907a7c1dc6fa627973d37efccc906630b14f646a"
42
42
  }
@@ -71,30 +71,49 @@
71
71
  'Withdrawal',
72
72
  'Pending Withdrawals',
73
73
  'Transaction History'];
74
+ const widgetPath = ['/profile-info',
75
+ '/change-password',
76
+ '/reality-check',
77
+ '/timeout',
78
+ '/account-closure',
79
+ '/gaming-limits',
80
+ '/self-exclusion',
81
+ '/active-bonuses',
82
+ '/bonus-history',
83
+ '/gaming-history',
84
+ '/deposit',
85
+ '/withdrawal',
86
+ '/pending-withdrawals',
87
+ '/transaction-history'];
74
88
  const accountMenuEndpointURL:string = `${cmsendpoint}/${lang}/profile-menu?env=${env}`;
75
89
  const notificationsEndpointURL:string = `${cmsendpoint}/${lang}/support-information?env=${env}`;
76
90
 
77
91
  let switchContent:boolean = false;
78
92
 
79
- const messageHandler = (e:any) => {
93
+ const messageHandler = (e:any):void => {
94
+ let url:URL;
95
+
80
96
  if (e.data) {
81
97
  switch(e.data.type) {
82
98
  case 'AccountMenuDetails':
83
99
  // @TODO open after launch event is triggered from CMS menu
84
- break;
100
+ // @TODO what is dis?
101
+ break;
85
102
 
86
103
  case 'ChangeAccountPage':
87
104
  switchContent = true;
88
- pageName = e.data.page.label;
105
+ pageName = e.data.page.path;
89
106
  getUserProfileInfo();
90
107
  break;
91
108
 
92
109
  case 'SetActivePage':
93
110
  switchContent = true;
94
111
  pageName = e.data.pageName;
112
+
95
113
  let aux:any = menuData.filter((item) => {
96
114
  return item.label == pageName;
97
115
  });
116
+
98
117
  selected = aux[0].id;
99
118
  getUserProfileInfo();
100
119
  break;
@@ -107,20 +126,23 @@
107
126
  case 'UpdatePlayerInfo':
108
127
  let profileData = e.data.provisionalArray;
109
128
  let sentData = {
110
- mobile: {
111
- prefix: profileData.mobilePrefix,
112
- number: profileData.mobileNumber
113
- },
114
- address1: profileData.address,
115
- city: profileData.city,
116
- postalCode: profileData.postalCode,
117
- securityQuestion: profileData.securityQuestion,
118
- securityAnswer: profileData.securityAnswer,
119
- consents: {
120
- acceptNewsEmail: profileData.acceptNewsEmail,
121
- acceptSMSOffers: profileData.acceptSMSOffers
122
- }
123
- }
129
+ mobile: {
130
+ prefix: profileData.mobilePrefix,
131
+ number: profileData.mobileNumber
132
+ },
133
+ address1: profileData.address,
134
+ city: profileData.city,
135
+ postalCode: profileData.postalCode,
136
+ securityQuestion: profileData.securityQuestion,
137
+ securityAnswer: profileData.securityAnswer,
138
+ consents: {
139
+ acceptNewsEmail: profileData.acceptNewsEmail,
140
+ acceptSMSOffers: profileData.acceptSMSOffers
141
+ }
142
+ };
143
+
144
+ url = new URL(`${endpoint}/player/${userId}/profile`);
145
+
124
146
  let options = {
125
147
  method: "POST",
126
148
  headers: {
@@ -131,7 +153,7 @@
131
153
  body: JSON.stringify(sentData)
132
154
  };
133
155
 
134
- fetch(`${endpoint}/player/${userId}/profile`, options)
156
+ fetch(url.href, options)
135
157
  .then((res:any) => {
136
158
  if (res.status == 200) {
137
159
  window.postMessage({ type: 'WidgetNotification', data: {
@@ -148,6 +170,7 @@
148
170
  break;
149
171
 
150
172
  case 'SetPlayerAccountTimeout':
173
+ url = new URL(`${endpoint}/player/${userId}/limits`);
151
174
  let timeoutValue = e.data.timeoutSelected;
152
175
 
153
176
  let dataTimeout = {
@@ -166,7 +189,7 @@
166
189
  body: JSON.stringify(dataTimeout)
167
190
  };
168
191
 
169
- fetch(`${endpoint}/player/${userId}/limits`, setTimeout)
192
+ fetch(url.href, setTimeout)
170
193
  .then((res:any) => {
171
194
  if (res.status == 200) {
172
195
  window.postMessage({ type: 'WidgetNotification', data: {
@@ -181,6 +204,8 @@
181
204
  break;
182
205
 
183
206
  case 'SetSelfExclusion':
207
+ url = new URL(`${endpoint}/player/${userId}/limits`);
208
+
184
209
  let selfExclusionPeriod = e.data.selfExclusionPeriod;
185
210
  let selfExclusionExpiryDate = e.data.selfExclusionExpiryDate;
186
211
 
@@ -202,21 +227,23 @@
202
227
  body: JSON.stringify(dataSelfExclusion)
203
228
  };
204
229
 
205
- fetch(`${endpoint}/player/${userId}/limits`, setSelfExclusion)
206
- .then((res:any) => {
207
- if (res.status == 200) {
208
- window.postMessage({ type: 'WidgetNotification', data: {
209
- type: 'success',
210
- message: 'Self exclusion active'
211
- }}, window.location.href);
212
- window.postMessage({ type: 'LogoutSuccessfull'}, window.location.href);
213
- } else {
214
- // ERROR
215
- }
216
- });
230
+ fetch(url.href, setSelfExclusion)
231
+ .then((res:any):void => {
232
+ if (res.status == 200) {
233
+ window.postMessage({ type: 'WidgetNotification', data: {
234
+ type: 'success',
235
+ message: 'Self exclusion active'
236
+ }}, window.location.href);
237
+ window.postMessage({ type: 'LogoutSuccessfull'}, window.location.href);
238
+ } else {
239
+ // ERROR
240
+ }
241
+ });
217
242
  break;
218
243
 
219
244
  case 'AccountClosure':
245
+ url = new URL(`${endpoint}/player/${userId}/limits`);
246
+
220
247
  let accountClosureData = 'UserRequest';
221
248
  let accountClosureSelection = {
222
249
  selfExclusion: {
@@ -237,8 +264,8 @@
237
264
  body: JSON.stringify(accountClosureSelection)
238
265
  };
239
266
 
240
- fetch(`${endpoint}/player/${userId}/limits`, optionsAccountClosure)
241
- .then((res:any) => {
267
+ fetch(url.href, optionsAccountClosure)
268
+ .then((res:any):void => {
242
269
  if (res.status == 200) {
243
270
  window.postMessage({ type: 'WidgetNotification', data: {
244
271
  type: 'success',
@@ -259,6 +286,8 @@
259
286
  break;
260
287
 
261
288
  case 'PlayerAccountGamingLimitsUpdate':
289
+ url = new URL(`${endpoint}/player/${userId}/limits`);
290
+
262
291
  let limitsObject = e.data.payload;
263
292
  let limitsSectionTitle = e.data.limitsCategory;
264
293
  let limitsData = (limitsSectionTitle === 'cumulativeSessionLimits' || limitsSectionTitle === 'depositLimits') ? limitsObject : {[limitsSectionTitle]: limitsObject}
@@ -273,8 +302,8 @@
273
302
  body: JSON.stringify(limitsData)
274
303
  };
275
304
 
276
- fetch(`${endpoint}/player/${userId}/limits`, optionsEditLimits)
277
- .then((res:any) => {
305
+ fetch(url.href, optionsEditLimits)
306
+ .then((res:any):void => {
278
307
  if (res.status == 200) {
279
308
  showsuccessnotification = true;
280
309
 
@@ -283,7 +312,7 @@
283
312
  message: 'Limits updated'
284
313
  }}, window.location.href);
285
314
 
286
- getGamingLimits(`${endpoint}/player/${playerid}/limits`);
315
+ getGamingLimits(new URL(`${endpoint}/player/${playerid}/limits`));
287
316
  } else {
288
317
  // ERROR
289
318
  }
@@ -330,7 +359,7 @@
330
359
  body: JSON.stringify(limitsDeleteData)
331
360
  };
332
361
 
333
- let url:any = new URL(`${endpoint}/player/${userId}/limits/${limitName}`);
362
+ url = new URL(`${endpoint}/player/${userId}/limits/${limitName}`);
334
363
 
335
364
  if (limitName === 'deposit' || limitName === 'cumulativeSession') {
336
365
  if (Array.isArray(deletedPeriodLimit)) {
@@ -342,15 +371,15 @@
342
371
  }
343
372
  }
344
373
 
345
- fetch(url, deleteOptions)
346
- .then((res:any) => {
374
+ fetch(url.href, deleteOptions)
375
+ .then((res:any):void => {
347
376
  if (res.status == 200) {
348
377
  showdeletenotification = true;
349
378
  window.postMessage({ type: 'WidgetNotification', data: {
350
379
  type: 'success',
351
380
  message: 'Limits deleted'
352
381
  }}, window.location.href);
353
- getGamingLimits(`${endpoint}/player/${playerid}/limits`);
382
+ getGamingLimits(new URL(`${endpoint}/player/${playerid}/limits`));
354
383
  } else {
355
384
  // ERROR
356
385
  }
@@ -358,26 +387,22 @@
358
387
  break;
359
388
 
360
389
  case 'GamingLimitsConfirmChanges':
361
- getGamingLimits(`${endpoint}/player/${playerid}/limits`);
390
+ getGamingLimits(new URL(`${endpoint}/player/${playerid}/limits`));
362
391
  break;
363
392
 
364
393
  case 'CancelGamingLimitsChanges':
365
- getGamingLimits(`${endpoint}/player/${playerid}/limits`);
394
+ getGamingLimits(new URL(`${endpoint}/player/${playerid}/limits`));
366
395
  break;
367
396
 
368
397
  case 'SubmittedRealityCheck':
369
398
  setRealityCheckValue(e.data.realityCheckUpdatedValue);
370
399
  break;
371
-
372
- default:
373
- // do nothing
374
- break;
375
400
  }
376
401
  }
377
402
  }
378
403
 
379
- const getAccountMenuDetails = (url:string) => {
380
- fetch(url)
404
+ const getAccountMenuDetails = (url:URL):void => {
405
+ fetch(url.href)
381
406
  .then((res:any) => res.json())
382
407
  .then((data:any) => {
383
408
  menuData = data;
@@ -387,20 +412,21 @@
387
412
  });
388
413
  }
389
414
 
390
- const getNotificationsDetails = (url:string) => {
391
- fetch(url)
415
+ const getNotificationsDetails = (url:URL):void => {
416
+ fetch(url.href)
392
417
  .then((res:any) => res.json())
393
- .then((data:any) => {
418
+ .then((data:any):void => {
394
419
  if(data.length) {
395
420
  notificationsData = data[0].children;
396
421
  window.postMessage({ type: 'NotificationsDetails', notificationsInfo: notificationsData }, window.location.href);
397
422
  }
398
- }, (err:any) => {
423
+ }, (err:any):void => {
399
424
  console.error(err);
400
425
  });
401
426
  }
402
427
 
403
- const getUserProfileInfo = () => {
428
+ const getUserProfileInfo = ():void => {
429
+ let url:URL = new URL(`${endpoint}/player/${userId}/profile`);
404
430
  let options = {
405
431
  method: "GET",
406
432
  headers: {
@@ -408,7 +434,7 @@
408
434
  }
409
435
  };
410
436
 
411
- fetch(`${endpoint}/player/${userId}/profile`, options)
437
+ fetch(url.href, options)
412
438
  .then((res:any) => { return res.json(); })
413
439
  .then((data:any) => {
414
440
  countrycode = data.country;
@@ -419,7 +445,8 @@
419
445
  });
420
446
  }
421
447
 
422
- const sendChangePassword = async (playerCurrentPassword:string, playerNewPassword:string) => {
448
+ const sendChangePassword = async (playerCurrentPassword:string, playerNewPassword:string):void => {
449
+ let url:URL = new URL(`${endpoint}/player/${userId}/password`)
423
450
  let data = {
424
451
  currentPassword: playerCurrentPassword,
425
452
  newPassword: playerNewPassword
@@ -434,7 +461,7 @@
434
461
  body: JSON.stringify(data)
435
462
  };
436
463
 
437
- let response:any = await fetch(`${endpoint}/player/${userId}/password`, optionsChangePassword);
464
+ let response:any = await fetch(url.href, optionsChangePassword);
438
465
 
439
466
  if (response.ok) {
440
467
  window.postMessage({ type: 'PasswordChangedSuccessfully' }, window.location.href);
@@ -455,14 +482,14 @@
455
482
  }
456
483
  }
457
484
 
458
- const getRealityCheckData = (url:string) => {
485
+ const getRealityCheckData = (url:URL):void => {
459
486
  let options = {
460
487
  method: 'GET',
461
488
  headers: {
462
489
  'X-SessionID': sessionId,
463
490
  }
464
491
  }
465
- fetch(url, options)
492
+ fetch(url.href, options)
466
493
  .then((res:any) => { return res.json(); })
467
494
  .then((data:any) => {
468
495
  realityCheckData = data.UserRealityCheckValue;
@@ -471,8 +498,10 @@
471
498
  });
472
499
  }
473
500
 
474
- const setRealityCheckValue = (updatedData:string) => {
475
- if(updatedData) {
501
+ const setRealityCheckValue = (updatedData:string):void => {
502
+ let url:URL = new URL(`${endpoint}/player/${userId}/realitycheck`);
503
+
504
+ if (updatedData) {
476
505
  storedRealityCheck = updatedData;
477
506
  }
478
507
 
@@ -486,10 +515,10 @@
486
515
  }
487
516
  };
488
517
 
489
- fetch(`${endpoint}/player/${userId}/realitycheck`, optionsRealityCheck)
518
+ fetch(url.href, optionsRealityCheck)
490
519
  .then((res:any) => {
491
520
  if (res.status == 200) {
492
- getRealityCheckData(`${endpoint}/player/${playerid}/realitycheck`);
521
+ getRealityCheckData(new URL(`${endpoint}/player/${playerid}/realitycheck`));
493
522
  window.postMessage({ type: 'RealityCheckValueUpdated' }, window.location.href);
494
523
  window.postMessage({ type: 'WidgetNotification', data: {
495
524
  type: 'success',
@@ -501,7 +530,7 @@
501
530
  });
502
531
  }
503
532
 
504
- const getGamingLimits = (url:string) => {
533
+ const getGamingLimits = (url:URL):void => {
505
534
  if (showsuccessnotification === true) {
506
535
  setTimeout(() => {showsuccessnotification = false; }, 3000);
507
536
  } else if(showdeletenotification === true) {
@@ -515,9 +544,9 @@
515
544
  }
516
545
  };
517
546
 
518
- fetch(url, options)
547
+ fetch(url.href, options)
519
548
  .then((res:any) => res.json())
520
- .then((data:any) => {
549
+ .then((data:any):void => {
521
550
  playerlimits = data;
522
551
  // add name property for info boxes
523
552
  if (Object.keys(playerlimits).length !== 0) {
@@ -563,19 +592,22 @@
563
592
  });
564
593
  }
565
594
 
566
- const getData = () => {
567
- getAccountMenuDetails(`${cmsendpoint}/${lang}/profile-menu?env=${env}`);
568
- getNotificationsDetails(`${cmsendpoint}/${lang}/support-information?env=${env}`);
595
+ const getData = ():void => {
596
+ getAccountMenuDetails(new URL(`${cmsendpoint}/${lang}/profile-menu?env=${env}`));
597
+ getNotificationsDetails(new URL(`${cmsendpoint}/${lang}/support-information?env=${env}`));
569
598
  getUserProfileInfo();
570
- getGamingLimits(`${endpoint}/player/${playerid}/limits`);
571
- getRealityCheckData(`${endpoint}/player/${playerid}/realitycheck`);
599
+ getGamingLimits(new URL(`${endpoint}/player/${playerid}/limits`));
600
+ getRealityCheckData(new URL(`${endpoint}/player/${playerid}/realitycheck`));
572
601
  }
573
602
 
574
- const initialLoad = () => {
603
+ const setActiveLanguage = ():void => {
575
604
  setLocale(lang);
605
+ }
606
+
607
+ const initialLoad = ():void => {
576
608
  userId = playerid;
577
609
  sessionId = session;
578
- pageName = widgetTitle[0];
610
+ pageName = widgetPath[0];
579
611
 
580
612
  if (!isMobile) {
581
613
  switchContent = true;
@@ -592,6 +624,7 @@
592
624
  }
593
625
  });
594
626
 
627
+ $: lang && setActiveLanguage();
595
628
  $: cmsendpoint && endpoint && customnotifications && playerid && session && lang && env && initialLoad();
596
629
  </script>
597
630
 
@@ -606,33 +639,33 @@
606
639
  <player-account-notifications customnotif={customnotifications}></player-account-notifications>
607
640
  </nav>
608
641
  {:else}
609
- {#if switchContent && pageName === widgetTitle[0]}
642
+ {#if switchContent && pageName === widgetPath[0]}
610
643
  <player-profile-info {endpoint} {lang} {countrycode}></player-profile-info>
611
- {:else if switchContent && pageName === widgetTitle[1]}
644
+ {:else if switchContent && pageName === widgetPath[1]}
612
645
  <player-change-password {lang}></player-change-password>
613
- {:else if switchContent && pageName === widgetTitle[2]}
646
+ {:else if switchContent && pageName === widgetPath[2]}
614
647
  <player-reality-check realitycheck={realityCheckData} {endpoint} {playerid} {session} {lang}></player-reality-check>
615
- {:else if switchContent && pageName === widgetTitle[3]}
648
+ {:else if switchContent && pageName === widgetPath[3]}
616
649
  <player-account-timeout {lang} {operator}></player-account-timeout>
617
- {:else if switchContent && pageName === widgetTitle[4]}
650
+ {:else if switchContent && pageName === widgetPath[4]}
618
651
  <player-account-closure {lang}></player-account-closure>
619
- {:else if switchContent && pageName === widgetTitle[5]}
652
+ {:else if switchContent && pageName === widgetPath[5]}
620
653
  <player-account-gaming-limits {depositlimit} {wageringlimit} {losslimit} {timelimit} {showsuccessnotification} {showdeletenotification} {lang}></player-account-gaming-limits>
621
- {:else if switchContent && pageName === widgetTitle[6]}
654
+ {:else if switchContent && pageName === widgetPath[6]}
622
655
  <player-account-self-exclusion {lang} {operator}></player-account-self-exclusion>
623
- {:else if switchContent && pageName === widgetTitle[7]}
656
+ {:else if switchContent && pageName === widgetPath[7]}
624
657
  <player-active-bonuses {endpoint} {session} {playerid} {lang}></player-active-bonuses>
625
- {:else if switchContent && pageName === widgetTitle[8]}
658
+ {:else if switchContent && pageName === widgetPath[8]}
626
659
  <player-bonus-history {endpoint} {session} {playerid} {lang}></player-bonus-history>
627
- {:else if switchContent && pageName === widgetTitle[9]}
660
+ {:else if switchContent && pageName === widgetPath[9]}
628
661
  <player-gaming-history {endpoint} {session} {playerid} {lang}></player-gaming-history>
629
- {:else if switchContent && pageName === widgetTitle[10]}
662
+ {:else if switchContent && pageName === widgetPath[10]}
630
663
  <player-deposit {endpoint} {session} {playerid} {lang}></player-deposit>
631
- {:else if switchContent && pageName === widgetTitle[11]}
664
+ {:else if switchContent && pageName === widgetPath[11]}
632
665
  <player-withdrawal {endpoint} {session} {playerid} {lang}></player-withdrawal>
633
- {:else if switchContent && pageName === widgetTitle[12]}
666
+ {:else if switchContent && pageName === widgetPath[12]}
634
667
  <player-pending-withdrawals {endpoint} {session} {playerid} {lang}></player-pending-withdrawals>
635
- {:else if switchContent && pageName === widgetTitle[13]}
668
+ {:else if switchContent && pageName === widgetPath[13]}
636
669
  <player-transaction-history {endpoint} {session} {playerid} {lang}></player-transaction-history>
637
670
  {/if}
638
671
  {/if}
@@ -641,33 +674,33 @@
641
674
  <player-account-menu {endpoint} {session} {playerid} {lang} selecteditem={selected}></player-account-menu>
642
675
  </nav>
643
676
  <main>
644
- {#if switchContent && pageName === widgetTitle[0]}
677
+ {#if switchContent && pageName === widgetPath[0]}
645
678
  <player-profile-info {endpoint} {lang} {countrycode}></player-profile-info>
646
- {:else if switchContent && pageName === widgetTitle[1]}
679
+ {:else if switchContent && pageName === widgetPath[1]}
647
680
  <player-change-password {lang}></player-change-password>
648
- {:else if switchContent && pageName === widgetTitle[2]}
681
+ {:else if switchContent && pageName === widgetPath[2]}
649
682
  <player-reality-check realitycheck={realityCheckData} {endpoint} {playerid} {session} {lang}></player-reality-check>
650
- {:else if switchContent && pageName === widgetTitle[3]}
683
+ {:else if switchContent && pageName === widgetPath[3]}
651
684
  <player-account-timeout {lang} {operator}></player-account-timeout>
652
- {:else if switchContent && pageName === widgetTitle[4]}
685
+ {:else if switchContent && pageName === widgetPath[4]}
653
686
  <player-account-closure {lang}></player-account-closure>
654
- {:else if switchContent && pageName === widgetTitle[5]}
687
+ {:else if switchContent && pageName === widgetPath[5]}
655
688
  <player-account-gaming-limits {depositlimit} {wageringlimit} {losslimit} {timelimit} {showsuccessnotification} {showdeletenotification} {lang}></player-account-gaming-limits>
656
- {:else if switchContent && pageName === widgetTitle[6]}
689
+ {:else if switchContent && pageName === widgetPath[6]}
657
690
  <player-account-self-exclusion {lang} {operator}></player-account-self-exclusion>
658
- {:else if switchContent && pageName === widgetTitle[7]}
691
+ {:else if switchContent && pageName === widgetPath[7]}
659
692
  <player-active-bonuses {endpoint} {session} {playerid} {lang}></player-active-bonuses>
660
- {:else if switchContent && pageName === widgetTitle[8]}
693
+ {:else if switchContent && pageName === widgetPath[8]}
661
694
  <player-bonus-history {endpoint} {session} {playerid} {lang}></player-bonus-history>
662
- {:else if switchContent && pageName === widgetTitle[9]}
695
+ {:else if switchContent && pageName === widgetPath[9]}
663
696
  <player-gaming-history {endpoint} {session} {playerid} {lang}></player-gaming-history>
664
- {:else if switchContent && pageName === widgetTitle[10]}
697
+ {:else if switchContent && pageName === widgetPath[10]}
665
698
  <player-deposit {endpoint} {session} {playerid} {lang}></player-deposit>
666
- {:else if switchContent && pageName === widgetTitle[11]}
699
+ {:else if switchContent && pageName === widgetPath[11]}
667
700
  <player-withdrawal {endpoint} {session} {playerid} {lang}></player-withdrawal>
668
- {:else if switchContent && pageName === widgetTitle[12]}
701
+ {:else if switchContent && pageName === widgetPath[12]}
669
702
  <player-pending-withdrawals {endpoint} {session} {playerid} {lang}></player-pending-withdrawals>
670
- {:else if switchContent && pageName === widgetTitle[13]}
703
+ {:else if switchContent && pageName === widgetPath[13]}
671
704
  <player-transaction-history {endpoint} {session} {playerid} {lang}></player-transaction-history>
672
705
  {/if}
673
706
  </main>