@everymatrix/lottery-tipping-ticket-history 1.77.25 → 1.77.27

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 (22) hide show
  1. package/dist/cjs/general-multi-select_10.cjs.entry.js +12 -21
  2. package/dist/cjs/index.cjs.js +1 -1
  3. package/dist/cjs/loader.cjs.js +1 -1
  4. package/dist/cjs/{lottery-tipping-ticket-history-dc0404e9.js → lottery-tipping-ticket-history-5d5f9bd8.js} +64 -109
  5. package/dist/cjs/lottery-tipping-ticket-history.cjs.js +1 -1
  6. package/dist/collection/components/lottery-tipping-filter/lottery-tipping-filter.js +5 -5
  7. package/dist/collection/components/lottery-tipping-ticket-history/lottery-tipping-ticket-history.js +60 -33
  8. package/dist/collection/utils/locale.utils.js +7 -76
  9. package/dist/collection/utils/utils.js +7 -0
  10. package/dist/esm/general-multi-select_10.entry.js +13 -22
  11. package/dist/esm/index.js +1 -1
  12. package/dist/esm/loader.js +1 -1
  13. package/dist/esm/{lottery-tipping-ticket-history-94060ab4.js → lottery-tipping-ticket-history-1c57b065.js} +64 -109
  14. package/dist/esm/lottery-tipping-ticket-history.js +1 -1
  15. package/dist/lottery-tipping-ticket-history/general-multi-select_10.entry.js +2 -2
  16. package/dist/lottery-tipping-ticket-history/index.esm.js +1 -1
  17. package/dist/lottery-tipping-ticket-history/lottery-tipping-ticket-history-1c57b065.js +1 -0
  18. package/dist/lottery-tipping-ticket-history/lottery-tipping-ticket-history.esm.js +1 -1
  19. package/dist/types/components/lottery-tipping-ticket-history/lottery-tipping-ticket-history.d.ts +3 -1
  20. package/dist/types/utils/utils.d.ts +4 -0
  21. package/package.json +1 -1
  22. package/dist/lottery-tipping-ticket-history/lottery-tipping-ticket-history-94060ab4.js +0 -1
@@ -231,6 +231,13 @@ const isMobile = (userAgent) => {
231
231
  userAgent.toLowerCase().match(/iphone|ipad|ipod/i) ||
232
232
  userAgent.toLowerCase().match(/windows phone|windows mobile|iemobile|wpdesktop/i));
233
233
  };
234
+ const showNotification = ({ message, theme = 'success' }) => {
235
+ window.postMessage({
236
+ type: 'ShowNotificationToast',
237
+ message,
238
+ theme
239
+ });
240
+ };
234
241
 
235
242
  var DrawResult;
236
243
  (function (DrawResult) {
@@ -2438,6 +2445,9 @@ const DEFAULT_LANGUAGE = 'en';
2438
2445
  const SUPPORTED_LANGUAGES = ['ro', 'en', 'fr', 'ar', 'hr'];
2439
2446
  const TRANSLATIONS = {
2440
2447
  en: {
2448
+ totalItems: 'Total {total} items',
2449
+ perPage: '{size} / page',
2450
+ goTo: 'Go to',
2441
2451
  filter: 'Filter',
2442
2452
  clear: 'Clear',
2443
2453
  searchByTicketId: 'Search by Ticket ID',
@@ -2467,82 +2477,10 @@ const TRANSLATIONS = {
2467
2477
  prize: 'Prize:',
2468
2478
  bettingType: 'Betting Type:'
2469
2479
  },
2470
- ro: {
2471
- ticketsHistory: 'Istoric bilete',
2472
- settled: 'Decontat',
2473
- purchased: 'Achiziționat',
2474
- canceled: 'Anulat',
2475
- noData: 'Nu sunt date disponibile.',
2476
- ticketId: 'ID bilet:',
2477
- ticketType: 'Tip bilet:',
2478
- ticketAmount: 'Suma biletului:',
2479
- lineDetail: 'Detaliu linie:',
2480
- seeDetails: 'Vezi detalii',
2481
- numberOfDraw: 'Număr de extrageri:',
2482
- ticketResult: 'Rezultat bilet:',
2483
- drawId: 'ID extragere:',
2484
- drawDate: 'Data extragerii:',
2485
- result: 'Rezultat:',
2486
- prize: 'Premiu:',
2487
- bettingType: 'Tip de pariu:'
2488
- },
2489
- fr: {
2490
- ticketsHistory: 'Historique des billets',
2491
- settled: 'Réglé',
2492
- purchased: 'Acheté',
2493
- canceled: 'Annulé',
2494
- noData: 'Aucune donnée disponible.',
2495
- ticketId: 'ID du billet:',
2496
- ticketType: 'Type de billet:',
2497
- ticketAmount: 'Montant du billet:',
2498
- lineDetail: 'Détail de la ligne:',
2499
- seeDetails: 'Voir les détails',
2500
- numberOfDraw: 'Nombre de tirages:',
2501
- ticketResult: 'Résultat du billet:',
2502
- drawId: 'ID du tirage:',
2503
- drawDate: 'Date du tirage:',
2504
- result: 'Résultat:',
2505
- prize: 'Prix:',
2506
- bettingType: 'Type de pari:'
2507
- },
2508
- ar: {
2509
- ticketsHistory: 'سجل التذاكر',
2510
- settled: 'تمت التسوية',
2511
- purchased: 'تم شراؤها',
2512
- canceled: 'تم الإلغاء',
2513
- noData: 'لا توجد بيانات متاحة.',
2514
- ticketId: 'معرف التذكرة:',
2515
- ticketType: 'نوع التذكرة:',
2516
- ticketAmount: 'مبلغ التذكرة:',
2517
- lineDetail: 'تفاصيل الخط:',
2518
- seeDetails: 'انظر التفاصيل',
2519
- numberOfDraw: 'عدد السحوبات:',
2520
- ticketResult: 'نتيجة التذكرة:',
2521
- drawId: 'معرف السحب:',
2522
- drawDate: 'تاريخ السحب:',
2523
- result: 'النتيجة:',
2524
- prize: 'الجائزة:',
2525
- bettingType: 'نوع الرهان:'
2526
- },
2527
- hr: {
2528
- ticketsHistory: 'Povijest listića',
2529
- settled: 'Riješeno',
2530
- purchased: 'Kupljeno',
2531
- canceled: 'Otkazano',
2532
- noData: 'Nema dostupnih podataka.',
2533
- ticketId: 'ID listića:',
2534
- ticketType: 'Vrsta listića:',
2535
- ticketAmount: 'Iznos listića:',
2536
- lineDetail: 'Detalji linije:',
2537
- seeDetails: 'Vidi detalje',
2538
- numberOfDraw: 'Broj izvlačenja:',
2539
- ticketResult: 'Rezultat listića:',
2540
- drawId: 'ID izvlačenja:',
2541
- drawDate: 'Datum izvlačenja:',
2542
- result: 'Rezultat:',
2543
- prize: 'Nagrada:',
2544
- bettingType: 'Vrsta oklade:'
2545
- }
2480
+ ro: {},
2481
+ fr: {},
2482
+ ar: {},
2483
+ hr: {}
2546
2484
  };
2547
2485
  const translate = (key, customLang, replacements) => {
2548
2486
  const lang = customLang;
@@ -2668,23 +2606,49 @@ const LotteryTippingTicketHistory = class {
2668
2606
  setClientStylingURL(this.stylingContainer, this.clientStylingUrl);
2669
2607
  }
2670
2608
  }
2671
- connectedCallback() {
2672
- const fetchData = () => {
2673
- let url = new URL(`${this.endpoint}/games/${this.gameId}`);
2609
+ async fetchGameData() {
2610
+ var _a;
2611
+ try {
2674
2612
  this.isLoading = true;
2675
- fetcher(url.href)
2676
- .then((res) => {
2677
- this.rawData = res;
2678
- })
2679
- .finally(() => {
2680
- this.isLoading = false;
2681
- });
2682
- };
2683
- fetchData();
2613
+ let url = new URL(`${this.endpoint}/games/${this.gameId}`);
2614
+ const res = await fetcher(url.href);
2615
+ this.rawData = res;
2616
+ }
2617
+ catch (e) {
2618
+ showNotification({ message: (_a = e.message) !== null && _a !== void 0 ? _a : e, theme: 'error' });
2619
+ }
2620
+ finally {
2621
+ this.isLoading = false;
2622
+ }
2623
+ }
2624
+ connectedCallback() {
2625
+ if (this.endpoint && this.gameId) {
2626
+ this.fetchGameData();
2627
+ }
2628
+ }
2629
+ handleGameInfoChange(newValue, oldValue) {
2630
+ if (newValue && newValue != oldValue) {
2631
+ this.fetchGameData();
2632
+ }
2633
+ }
2634
+ handleTicketInfoChange(newValue, oldValue) {
2635
+ if (newValue && newValue != oldValue) {
2636
+ this.fetchTicketList();
2637
+ }
2684
2638
  }
2685
2639
  disconnectedCallback() {
2686
2640
  this.stylingSubscription && this.stylingSubscription.unsubscribe();
2687
2641
  }
2642
+ // fetchGameData() {
2643
+ // try {
2644
+ // let url: URL = new URL(`${this.endpoint}/games/${this.gameId}`);
2645
+ // fetcher(url.href).then((res) => {
2646
+ // this.rawData = res;
2647
+ // });
2648
+ // } catch (e) {
2649
+ // this.showNotification(e.message, 'error');
2650
+ // }
2651
+ // }
2688
2652
  async fetchTicketList() {
2689
2653
  this.isLoading = true;
2690
2654
  try {
@@ -2693,7 +2657,6 @@ const LotteryTippingTicketHistory = class {
2693
2657
  });
2694
2658
  this.ticketHistory = items;
2695
2659
  this.paginationInfo.total = total;
2696
- this.isLoading = false;
2697
2660
  if (items.length > 0) {
2698
2661
  this.getDrawResult();
2699
2662
  }
@@ -2701,7 +2664,7 @@ const LotteryTippingTicketHistory = class {
2701
2664
  catch (e) {
2702
2665
  console.log('in fetchTicketList error is: ', e);
2703
2666
  if (e.status === 401) {
2704
- this.showNotification(e.message, 'error');
2667
+ showNotification({ message: e.message, theme: 'error' });
2705
2668
  this.logout.emit();
2706
2669
  }
2707
2670
  }
@@ -2718,19 +2681,6 @@ const LotteryTippingTicketHistory = class {
2718
2681
  console.log(e);
2719
2682
  }
2720
2683
  }
2721
- showNotification(message, theme = '', position = 'top-end') {
2722
- const notification = document.createElement('vaadin-notification');
2723
- notification.renderer = (root) => {
2724
- root.textContent = message;
2725
- };
2726
- notification.duration = 5000;
2727
- if (theme) {
2728
- notification.setAttribute('theme', theme);
2729
- }
2730
- notification.setAttribute('position', position);
2731
- document.body.appendChild(notification);
2732
- notification.opened = true;
2733
- }
2734
2684
  getDivision(detail, drawData) {
2735
2685
  var _a;
2736
2686
  let division = detail.division;
@@ -2883,20 +2833,25 @@ const LotteryTippingTicketHistory = class {
2883
2833
  return name !== null && name !== void 0 ? name : bettingType;
2884
2834
  }
2885
2835
  render() {
2886
- return (h("div", { key: '27d7945395c1bd5cf8c50fabcf9358dd10a2f379', class: "lottery-tipping-ticket-history", ref: (el) => (this.stylingContainer = el) }, h("div", { key: '29bf61bc1b7a2f34bf24814c5d256bc84b703fa9', class: "ticket-history-title" }, translate('ticketsHistory', this.language)), h("div", { key: 'aabcc336535e36248c07afac1b3777c8e00e6d36', class: "filter-wrap" }, h("div", { key: '6a2ce1224363104c27d63026e3d246f70db12516', class: "filter-status" }, this.statusOptions.map((status) => (h("div", { class: 'filter-status-btn' + (this.activeStatus == status.value ? ' active' : ''), onClick: () => this.changeStatus(status.value) }, status.label)))), h("div", { key: '740826baea69e1adf534bcf9a2bb4d5083fa9d90', class: "filter-operation" }, h("lottery-tipping-filter", { key: '395ebb8b2c040804adb4e0a87daff0d01a0598cf', "quick-filters-active": this.quickFiltersActive, language: this.language, "translation-url": this.translationUrl }))), this.isLoading && (h("div", { key: 'c27852dcd7902ac43a1ff7408476e5f8667c1010', class: "loading-wrap" }, h("section", { key: '9ab2fea4cafdefe3accbc0e49be19ec16158cd14', class: "dots-container" }, h("div", { key: 'c5d6c3227c51c462eb4bcca926b7ab70e3676dfd', class: "dot" }), h("div", { key: '9ac68a72b257614a1c048a870f18753fe85967db', class: "dot" }), h("div", { key: '6c5d426f926a5726a3d88ad509fc6e38f715c10d', class: "dot" }), h("div", { key: '90959f4befb4d2308a1cf1651dd76f7be71b3e34', class: "dot" }), h("div", { key: '1e8dda2f5e4e460cb0f4aa7897b19fad23d98834', class: "dot" })))), !this.isLoading && (!this.ticketHistory || this.ticketHistory.length == 0) && (h("div", { key: '452303d3d8221e2c3905b1d0d2e81651f1e62038', class: "empty-wrap" }, translate('noData', this.language))), !this.isLoading && this.ticketHistory && this.ticketHistory.length != 0 && (h("div", { key: 'e7c5d75d70077d6b65a006fa6169ff9d2edca2ea', class: "ticket-list-wrap" }, this.ticketHistory.map((item) => (h("lottery-tipping-panel", { "header-title": format(new Date(item.createdAt), 'dd/MM/yyyy HH:mm:ss') + ' ' + item.state }, h("div", { class: "panel-content", slot: "content" }, h("div", { class: "ticket-info" }, h("div", { class: "ticket-info-item" }, h("div", { class: "ticket-info-label" }, translate('ticketId', this.language)), h("div", { class: "ticket-info-val" }, item.id, " ")), h("div", { class: "ticket-info-item" }, h("div", { class: "ticket-info-label" }, translate('ticketType', this.language)), h("div", { class: "ticket-info-val" }, this.ticketTypeMap[item.wagerType], " ")), h("div", { class: "ticket-info-item" }, h("div", { class: "ticket-info-label" }, translate('ticketAmount', this.language)), h("div", { class: "ticket-info-val" }, `${item.amount} ${item.currency}`)), h("div", { class: "ticket-info-item" }, h("div", { class: "ticket-info-label" }, translate('lineDetail', this.language)), h("div", { class: "ticket-info-val" }, h("span", { class: "show-detail-link", onClick: () => this.handleShowTicketLineDetial(item) }, translate('seeDetails', this.language)))), h("div", { class: "ticket-info-item" }, h("div", { class: "ticket-info-label" }, translate('numberOfDraw', this.language)), h("div", { class: "ticket-info-val" }, item.drawCount))), item.state == 'Settled' &&
2887
- item.drawResults.map((drawResultItem) => (h("div", { class: "draw-info-container" }, drawResultItem.tempDrawData ? (h("div", { class: "draw-info" }, h("div", { class: "draw-info-item" }, h("div", { class: "draw-info-label" }, translate('ticketResult', this.language)), h("div", { class: "draw-info-val" }, this.resultMap[drawResultItem.state])), h("div", { class: "draw-info-item" }, h("div", { class: "draw-info-label" }, translate('drawId', this.language)), h("div", { class: "draw-info-val" }, drawResultItem.drawId)), h("div", { class: "draw-info-item" }, h("div", { class: "draw-info-label" }, translate('drawDate', this.language)), h("div", { class: "draw-info-val" }, format(new Date(drawResultItem.tempDrawData.date), 'dd/MM/yyyy'))), h("div", { class: "draw-info-item" }, h("div", { class: "draw-info-label" }, translate('result', this.language)), h("div", { class: "draw-info-val" }, h("span", { class: "show-detail-link", onClick: () => this.handleShowCurrentDraw(drawResultItem.tempDrawData) }, translate('seeDetails', this.language)))), drawResultItem.state === DrawResult.WON && (h("div", { class: "draw-info-item" }, h("div", { class: "draw-info-label" }, translate('prize', this.language)), h("div", { class: "draw-info-val1" }, h("div", { style: { height: '20px' } }), drawResultItem.prizeDetails.map((prizeItem) => (h("span", null, h("div", null, h("span", { style: { color: 'rgb(85, 85, 85)' } }, prizeItem.prizeName, prizeItem.times > 1 ? ' x ' + prizeItem.times : '', ":", ' '), h("span", { style: { 'margin-right': '4px', color: 'rgb(85, 85, 85)' } }, thousandSeperator(prizeItem.amount)), h("span", { style: { color: 'rgb(85, 85, 85)' } }, prizeItem.currency)))))))))) : (h("div", { class: "draw-info-skeleton" }, [...Array(5)].map(() => (h("div", { class: "skeleton-line" })))))))))))))), h("lottery-tipping-dialog", { key: '913a521d05ae95b088fba515d951bc79b1433938', visible: this.showCurrentTicketLine, width: !isMobile(window.navigator.userAgent) ? '720px' : undefined, fullscreen: isMobile(window.navigator.userAgent), closable: true, showFooter: false, onCancel: () => {
2836
+ return (h("div", { key: '9dbed4dca8e568a334c63748d1768ace33922270', class: "lottery-tipping-ticket-history", ref: (el) => (this.stylingContainer = el) }, h("div", { key: '4149c4c6f067be28f1334a8642790d9886d219ef', class: "ticket-history-title" }, translate('ticketsHistory', this.language)), h("div", { key: '185ac4ad602e6e8bb0ec025a5cc2c4a9b8418444', class: "filter-wrap" }, h("div", { key: 'd136c367780b696403f075b261f2009cc94edc5d', class: "filter-status" }, this.statusOptions.map((status) => (h("div", { class: 'filter-status-btn' + (this.activeStatus == status.value ? ' active' : ''), onClick: () => this.changeStatus(status.value) }, status.label)))), h("div", { key: 'e6a30ef0f8c957813a7b13238353709cfb9e2dd9', class: "filter-operation" }, h("lottery-tipping-filter", { key: '4e1e0ba0eeafd7e64344c2b8e4e7d0c0f097127b', "quick-filters-active": this.quickFiltersActive, language: this.language, "translation-url": this.translationUrl }))), this.isLoading && (h("div", { key: 'f572e1bd9cbf97948b9a9bda34f34c1407a8007e', class: "loading-wrap" }, h("section", { key: '9198457f400b175e4c9721449e49a987090860d9', class: "dots-container" }, h("div", { key: '0b1196e3ad2b05ef91965b2a52728e5386578e4b', class: "dot" }), h("div", { key: '19a5b0bc39fd931455a7972d66b640ca36685ea9', class: "dot" }), h("div", { key: '8bf3a43540d38c98d27cb7bf61d7595123a4739c', class: "dot" }), h("div", { key: '5ed33ee21018c3b2aae97a6b1345fdec2072fefe', class: "dot" }), h("div", { key: '2d4404c8e0d39dc82bb25554c242d27e091a9932', class: "dot" })))), !this.isLoading && (!this.ticketHistory || this.ticketHistory.length == 0) && (h("div", { key: '4b731612e57d8bde341da7d639dec6f245c7156d', class: "empty-wrap" }, translate('noData', this.language))), !this.isLoading && this.ticketHistory && this.ticketHistory.length != 0 && (h("div", { key: 'c9a17cc74f32ae9277d069a8633f38a8478e642c', class: "ticket-list-wrap" }, this.ticketHistory.map((item) => (h("lottery-tipping-panel", { "header-title": format(new Date(item.createdAt), 'dd/MM/yyyy HH:mm:ss') + ' ' + item.state }, h("div", { class: "panel-content", slot: "content" }, h("div", { class: "ticket-info" }, h("div", { class: "ticket-info-item" }, h("div", { class: "ticket-info-label" }, translate('ticketId', this.language)), h("div", { class: "ticket-info-val" }, item.id, " ")), h("div", { class: "ticket-info-item" }, h("div", { class: "ticket-info-label" }, translate('ticketType', this.language)), h("div", { class: "ticket-info-val" }, this.ticketTypeMap[item.wagerType], " ")), h("div", { class: "ticket-info-item" }, h("div", { class: "ticket-info-label" }, translate('ticketAmount', this.language)), h("div", { class: "ticket-info-val" }, `${item.amount} ${item.currency}`)), h("div", { class: "ticket-info-item" }, h("div", { class: "ticket-info-label" }, translate('lineDetail', this.language)), h("div", { class: "ticket-info-val" }, h("span", { class: "show-detail-link", onClick: () => this.handleShowTicketLineDetial(item) }, translate('seeDetails', this.language)))), h("div", { class: "ticket-info-item" }, h("div", { class: "ticket-info-label" }, translate('numberOfDraw', this.language)), h("div", { class: "ticket-info-val" }, item.drawCount))), item.state == 'Settled' &&
2837
+ item.drawResults.map((drawResultItem) => (h("div", { class: "draw-info-container" }, drawResultItem.tempDrawData ? (h("div", { class: "draw-info" }, h("div", { class: "draw-info-item" }, h("div", { class: "draw-info-label" }, translate('ticketResult', this.language)), h("div", { class: "draw-info-val" }, this.resultMap[drawResultItem.state])), h("div", { class: "draw-info-item" }, h("div", { class: "draw-info-label" }, translate('drawId', this.language)), h("div", { class: "draw-info-val" }, drawResultItem.drawId)), h("div", { class: "draw-info-item" }, h("div", { class: "draw-info-label" }, translate('drawDate', this.language)), h("div", { class: "draw-info-val" }, format(new Date(drawResultItem.tempDrawData.date), 'dd/MM/yyyy'))), h("div", { class: "draw-info-item" }, h("div", { class: "draw-info-label" }, translate('result', this.language)), h("div", { class: "draw-info-val" }, h("span", { class: "show-detail-link", onClick: () => this.handleShowCurrentDraw(drawResultItem.tempDrawData) }, translate('seeDetails', this.language)))), drawResultItem.state === DrawResult.WON && (h("div", { class: "draw-info-item" }, h("div", { class: "draw-info-label" }, translate('prize', this.language)), h("div", { class: "draw-info-val1" }, h("div", { style: { height: '20px' } }), drawResultItem.prizeDetails.map((prizeItem) => (h("span", null, h("div", null, h("span", { style: { color: 'rgb(85, 85, 85)' } }, prizeItem.prizeName, prizeItem.times > 1 ? ' x ' + prizeItem.times : '', ":", ' '), h("span", { style: { 'margin-right': '4px', color: 'rgb(85, 85, 85)' } }, thousandSeperator(prizeItem.amount)), h("span", { style: { color: 'rgb(85, 85, 85)' } }, prizeItem.currency)))))))))) : (h("div", { class: "draw-info-skeleton" }, [...Array(5)].map(() => (h("div", { class: "skeleton-line" })))))))))))))), h("lottery-tipping-dialog", { key: '4ef7d281084bc6441e6a3e666ac52a7df3dfd28c', visible: this.showCurrentTicketLine, width: !isMobile(window.navigator.userAgent) ? '720px' : undefined, fullscreen: isMobile(window.navigator.userAgent), closable: true, showFooter: false, onCancel: () => {
2888
2838
  this.showCurrentTicketLine = false;
2889
- }, language: this.language, "translation-url": this.translationUrl }, this.curSelection && this.curSelection.length && (h("div", { key: '6608c983a4bc781f4beac6488b0857abfb59ca48' }, h("div", { key: '77690236f6e654e8f178bdb6fb76f49826b02a60', class: "betting-type" }, h("div", { key: '30d239aa23d01edb20049b5fbbbbc094c6742f75', class: "betting-type-title" }, translate('bettingType', this.language)), h("div", { key: '93770717ac08bbacc84d9de8b16133073e36d4c9', class: "betting-type-text" }, this.getBettingTypeName(this.getBettingType(this.curTicketItem.selection[this.curSelectionIdx].betType)))), h("lottery-tipping-ticket-bet", { key: '11641a37abe2ca65ecb706f94ce8a911f9e849d9', endpoint: this.endpoint, "session-id": this.sessionId, "game-id": this.curTicketItem.vendorGameId, "draw-id": this.curTicketItem.startingDrawId, "default-bullet-config-line-group": JSON.stringify(this.curSelection), "read-pretty": true, "total-pages": this.curSelection.length, language: this.language, "translation-url": this.translationUrl })))), h("lottery-tipping-dialog", { key: 'fdac976410e6b1b1e1ea20072d5c4caa474f4130', visible: this.showCurrentDrawResult, width: !isMobile(window.navigator.userAgent) ? '720px' : undefined, fullscreen: isMobile(window.navigator.userAgent), closable: true, showFooter: false, onCancel: () => {
2839
+ }, language: this.language, "translation-url": this.translationUrl }, this.curSelection && this.curSelection.length && (h("div", { key: '0fe7ae0f7deceb8b3c939a401efafe70124411dd' }, h("div", { key: '5418df176032a83dbd05ee545fffc255694413a2', class: "betting-type" }, h("div", { key: '8fb74f2041677fe8876a54773451d00f53abe0df', class: "betting-type-title" }, translate('bettingType', this.language)), h("div", { key: 'b9bc169c4df854a59606d0ddf330707677720263', class: "betting-type-text" }, this.getBettingTypeName(this.getBettingType(this.curTicketItem.selection[this.curSelectionIdx].betType)))), h("lottery-tipping-ticket-bet", { key: 'e76e8c1a24b22668d82f54bfed708afb676f23c9', endpoint: this.endpoint, "session-id": this.sessionId, "game-id": this.curTicketItem.vendorGameId, "draw-id": this.curTicketItem.startingDrawId, "default-bullet-config-line-group": JSON.stringify(this.curSelection), "read-pretty": true, "total-pages": this.curSelection.length, language: this.language, "translation-url": this.translationUrl })))), h("lottery-tipping-dialog", { key: 'cf4220d7b9ef7a174ab059574e1d758096cf6f6c', visible: this.showCurrentDrawResult, width: !isMobile(window.navigator.userAgent) ? '720px' : undefined, fullscreen: isMobile(window.navigator.userAgent), closable: true, showFooter: false, onCancel: () => {
2890
2840
  this.showCurrentDrawResult = false;
2891
- }, language: this.language, "translation-url": this.translationUrl }, this.curDrawSelection && this.curDrawSelection.length && (h("div", { key: 'b495d8bb01c4bb18edf951889850d56700564d8b' }, h("div", { key: '77443b43ee363dd2051da4a8c6cb004f2acab410', class: "betting-type" }, h("div", { key: 'ada4a3803b9073e78c248790f24de86900e5776f', class: "betting-type-title" }, translate('bettingType', this.language)), h("div", { key: '20826ed1192db8acfb25310c31252cb7f5a75f2a', class: "betting-type-text" }, h("div", { key: '7721c04879283138870833b3ce0b881cd84aec6c', class: "LotteryTippingTicketController__segmented-control" }, Object.keys(this.curDrawSelectionMap).map((bettingType) => (h("button", { class: {
2841
+ }, language: this.language, "translation-url": this.translationUrl }, this.curDrawSelection && this.curDrawSelection.length && (h("div", { key: '61214e66f20708cf92fa12d9b3afa3feee2e4335' }, h("div", { key: '589010058422524a0b3478cee60fa13703d921e9', class: "betting-type" }, h("div", { key: '657e2cede56274839d1e56784e7f85e61c5b3a42', class: "betting-type-title" }, translate('bettingType', this.language)), h("div", { key: 'b2b77770d0d439d7a2d062943c1cb114a7e54574', class: "betting-type-text" }, h("div", { key: '8a9e0821b8165a9cc04c5be4b3eb7286bdcef21f', class: "LotteryTippingTicketController__segmented-control" }, Object.keys(this.curDrawSelectionMap).map((bettingType) => (h("button", { class: {
2892
2842
  LotteryTippingTicketController__segment: true,
2893
2843
  'LotteryTippingTicketController__segment--active': this.curDrawSelectionBettingType === bettingType
2894
- }, onClick: () => this.handleDrawBettingTypeChange(bettingType) }, this.getBettingTypeName(bettingType))))))), h("lottery-tipping-ticket-bet", { key: 'b8b29a1a6e6bda2ce5004765e219e58d8e12bb2f', endpoint: this.endpoint, "session-id": this.sessionId, "game-id": this.curDrawItem.vendorGameId, "draw-id": this.curDrawItem.id, "default-bullet-config-line-group": JSON.stringify(this.curDrawSelection), "read-pretty": true, "total-pages": this.curDrawSelection.length, language: this.language, "translation-url": this.translationUrl })))), h("div", { key: 'a84c658d87e936cbf20731a64bc753f13c099024', class: "pagination-wrap" }, h("lottery-tipping-pagination", { key: 'fdf7443bd153e90c131e4ba937f08d611706a56d', total: this.paginationInfo.total, current: this.paginationInfo.current, "page-size": this.paginationInfo.pageSize, language: this.language, "translation-url": this.translationUrl }))));
2844
+ }, onClick: () => this.handleDrawBettingTypeChange(bettingType) }, this.getBettingTypeName(bettingType))))))), h("lottery-tipping-ticket-bet", { key: '313e81c7d8181316896a2a46211d12ede72b5353', endpoint: this.endpoint, "session-id": this.sessionId, "game-id": this.curDrawItem.vendorGameId, "draw-id": this.curDrawItem.id, "default-bullet-config-line-group": JSON.stringify(this.curDrawSelection), "read-pretty": true, "total-pages": this.curDrawSelection.length, language: this.language, "translation-url": this.translationUrl })))), h("div", { key: '374d4a579f634ae631392b9e16a3a9acd0cf029c', class: "pagination-wrap" }, h("lottery-tipping-pagination", { key: '0a22fb6a1d59c391f2db3a2e20774a1b19491739', total: this.paginationInfo.total, current: this.paginationInfo.current, "page-size": this.paginationInfo.pageSize, language: this.language, "translation-url": this.translationUrl }))));
2895
2845
  }
2896
2846
  static get watchers() { return {
2897
2847
  "clientStyling": ["handleClientStylingChange"],
2898
2848
  "clientStylingUrl": ["handleClientStylingUrlChange"],
2899
- "mbSource": ["handleMbSourceChange"]
2849
+ "mbSource": ["handleMbSourceChange"],
2850
+ "gameId": ["handleGameInfoChange"],
2851
+ "endpoint": ["handleGameInfoChange"],
2852
+ "endpointTicket": ["handleTicketInfoChange"],
2853
+ "playerId": ["handleTicketInfoChange"],
2854
+ "sessionId": ["handleTicketInfoChange"]
2900
2855
  }; }
2901
2856
  };
2902
2857
  LotteryTippingTicketHistory.style = LotteryTippingTicketHistoryStyle0;
@@ -16,5 +16,5 @@ var patchBrowser = () => {
16
16
 
17
17
  patchBrowser().then(async (options) => {
18
18
  await globalScripts();
19
- return bootstrapLazy([["general-multi-select_10",[[1,"lottery-tipping-ticket-history",{"endpoint":[513],"endpointTicket":[513,"endpoint-ticket"],"gameId":[1537,"game-id"],"playerId":[1538,"player-id"],"sessionId":[1537,"session-id"],"drawId":[513,"draw-id"],"mbSource":[513,"mb-source"],"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"language":[513],"translationUrl":[513,"translation-url"],"ticketHistory":[32],"activeStatus":[32],"statusOptions":[32],"isLoading":[32],"rawData":[32],"filterData":[32],"paginationInfo":[32],"quickFiltersActive":[32],"showCurrentTicketLine":[32],"curTicketItem":[32],"curSelection":[32],"curSelectionIdx":[32],"showCurrentDrawResult":[32],"curDrawItem":[32],"curDrawSelection":[32],"curDrawSelectionBettingType":[32],"curDrawSelectionMap":[32]},[[0,"pageSizeChange","handlePageSizeChange"],[0,"pageChange","handlePageChange"],[0,"filterChange","handleFilterChange"],[0,"filterClear","handleFilterClear"],[0,"poolGameCurrentPageChange","handlePoolGameCurrentPageChange"]],{"clientStyling":["handleClientStylingChange"],"clientStylingUrl":["handleClientStylingUrlChange"],"mbSource":["handleMbSourceChange"]}],[1,"lottery-tipping-ticket-bet",{"mbSource":[513,"mb-source"],"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"translationUrl":[513,"translation-url"],"language":[513],"sessionId":[513,"session-id"],"endpoint":[513],"gameId":[513,"game-id"],"drawId":[513,"draw-id"],"totalPages":[1538,"total-pages"],"minTotalPages":[514,"min-total-pages"],"maxTotalPages":[514,"max-total-pages"],"mode":[513],"readPretty":[516,"read-pretty"],"defaultBulletConfigLineGroup":[513,"default-bullet-config-line-group"],"translationData":[32],"clientStylingUrlContent":[32],"bulletConfigLineGroup":[32],"currentPage":[32],"isLoading":[32],"hasErrors":[32],"dialogConfig":[32],"ticketDataSource":[32],"resetBulletConfig":[64],"getData":[64]},[[0,"lotteryTippingBulletGroupToggle","lotteryTippingBulletGroupSelectionHandler"]],{"translationUrl":["handleNewTranslations"],"clientStyling":["handleClientStylingChange"],"clientStylingUrl":["handleClientStylingUrlChange"],"mbSource":["handleMbSourceChange"],"gameId":["fetchMatchData"],"sessionId":["fetchMatchData"],"drawId":["fetchMatchData"],"currentPage":["handleCurrentPageChange"]}],[1,"lottery-tipping-filter",{"quickFiltersActive":[516,"quick-filters-active"],"mbSource":[513,"mb-source"],"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"language":[513],"translationUrl":[520,"translation-url"],"isOpen":[32],"filterData":[32],"ticketTypeList":[32],"showClearButton":[32]},[[0,"modalCloseEvent","handleModalClose"]],{"clientStyling":["handleClientStylingChange"],"clientStylingUrl":["handleClientStylingUrlChange"],"mbSource":["handleMbSourceChange"]}],[1,"lottery-tipping-pagination",{"total":[2],"pageSizeOptions":[16],"mbSource":[513,"mb-source"],"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"language":[513],"translationUrl":[520,"translation-url"],"current":[2],"pageSize":[32],"totalPages":[32]},null,{"clientStyling":["handleClientStylingChange"],"clientStylingUrl":["handleClientStylingUrlChange"],"mbSource":["handleMbSourceChange"],"total":["updateTotalPages"],"pageSize":["updateTotalPages"]}],[1,"lottery-tipping-panel",{"mbSource":[513,"mb-source"],"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"headerTitle":[1,"header-title"],"expanded":[32]},null,{"clientStyling":["handleClientStylingChange"],"clientStylingUrl":["handleClientStylingUrlChange"],"mbSource":["handleMbSourceChange"]}],[1,"lottery-tipping-bullet-group",{"mbSource":[513,"mb-source"],"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"positionIdx":[513,"position-idx"],"theme":[513],"mode":[513],"bulletConfigContent":[513,"bullet-config-content"]},[[0,"lotteryTippingBulletToggle","lotteryTippingBulletSelectionHandler"]],{"clientStyling":["handleClientStylingChange"],"clientStylingUrl":["handleClientStylingUrlChange"],"mbSource":["handleMbSourceChange"]}],[1,"general-multi-select",{"mbSource":[513,"mb-source"],"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"options":[16],"maxVisibleChips":[2,"max-visible-chips"],"placeholder":[1],"selectedValues":[32],"dropdownOpen":[32],"overflowOpen":[32],"popoverStyle":[32],"clear":[64]},null,{"clientStyling":["handleClientStylingChange"],"clientStylingUrl":["handleClientStylingUrlChange"],"mbSource":["handleMbSourceChange"]}],[1,"general-tooltip",{"mbSource":[513,"mb-source"],"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"position":[1],"delay":[2],"isVisible":[32],"_tooltipId":[32]},[[1,"mouseenter","handleMouseEnterOrFocus"],[0,"focusin","handleMouseEnterOrFocus"],[1,"mouseleave","handleMouseLeaveOrBlur"],[0,"focusout","handleMouseLeaveOrBlur"],[0,"keydown","handleKeyDown"]],{"clientStyling":["handleClientStylingChange"],"clientStylingUrl":["handleClientStylingUrlChange"],"mbSource":["handleMbSourceChange"]}],[1,"lottery-tipping-dialog",{"mbSource":[1,"mb-source"],"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"visible":[516],"dialogTitle":[1,"dialog-title"],"width":[1],"closable":[4],"mask":[4],"maskClosable":[4,"mask-closable"],"animationDuration":[2,"animation-duration"],"fullscreen":[4],"showFooter":[4,"show-footer"],"showCancelBtn":[4,"show-cancel-btn"],"language":[513],"translationUrl":[520,"translation-url"]},null,{"clientStyling":["handleClientStylingChange"],"clientStylingUrl":["handleClientStylingUrlChange"],"mbSource":["handleMbSourceChange"]}],[1,"lottery-tipping-bullet",{"mbSource":[513,"mb-source"],"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"positionIdx":[514,"position-idx"],"theme":[513],"value":[513],"disabled":[516],"isSelected":[516,"is-selected"]},null,{"clientStyling":["handleClientStylingChange"],"clientStylingUrl":["handleClientStylingUrlChange"],"mbSource":["handleMbSourceChange"]}]]]], options);
19
+ return bootstrapLazy([["general-multi-select_10",[[1,"lottery-tipping-ticket-history",{"endpoint":[513],"endpointTicket":[513,"endpoint-ticket"],"gameId":[1537,"game-id"],"playerId":[1538,"player-id"],"sessionId":[1537,"session-id"],"drawId":[513,"draw-id"],"mbSource":[513,"mb-source"],"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"language":[513],"translationUrl":[513,"translation-url"],"ticketHistory":[32],"activeStatus":[32],"statusOptions":[32],"isLoading":[32],"rawData":[32],"filterData":[32],"paginationInfo":[32],"quickFiltersActive":[32],"showCurrentTicketLine":[32],"curTicketItem":[32],"curSelection":[32],"curSelectionIdx":[32],"showCurrentDrawResult":[32],"curDrawItem":[32],"curDrawSelection":[32],"curDrawSelectionBettingType":[32],"curDrawSelectionMap":[32]},[[0,"pageSizeChange","handlePageSizeChange"],[0,"pageChange","handlePageChange"],[0,"filterChange","handleFilterChange"],[0,"filterClear","handleFilterClear"],[0,"poolGameCurrentPageChange","handlePoolGameCurrentPageChange"]],{"clientStyling":["handleClientStylingChange"],"clientStylingUrl":["handleClientStylingUrlChange"],"mbSource":["handleMbSourceChange"],"gameId":["handleGameInfoChange"],"endpoint":["handleGameInfoChange"],"endpointTicket":["handleTicketInfoChange"],"playerId":["handleTicketInfoChange"],"sessionId":["handleTicketInfoChange"]}],[1,"lottery-tipping-ticket-bet",{"mbSource":[513,"mb-source"],"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"translationUrl":[513,"translation-url"],"language":[513],"sessionId":[513,"session-id"],"endpoint":[513],"gameId":[513,"game-id"],"drawId":[513,"draw-id"],"totalPages":[1538,"total-pages"],"minTotalPages":[514,"min-total-pages"],"maxTotalPages":[514,"max-total-pages"],"mode":[513],"readPretty":[516,"read-pretty"],"defaultBulletConfigLineGroup":[513,"default-bullet-config-line-group"],"translationData":[32],"clientStylingUrlContent":[32],"bulletConfigLineGroup":[32],"currentPage":[32],"isLoading":[32],"hasErrors":[32],"dialogConfig":[32],"ticketDataSource":[32],"resetBulletConfig":[64],"getData":[64]},[[0,"lotteryTippingBulletGroupToggle","lotteryTippingBulletGroupSelectionHandler"]],{"translationUrl":["handleNewTranslations"],"clientStyling":["handleClientStylingChange"],"clientStylingUrl":["handleClientStylingUrlChange"],"mbSource":["handleMbSourceChange"],"gameId":["fetchMatchData"],"sessionId":["fetchMatchData"],"drawId":["fetchMatchData"],"currentPage":["handleCurrentPageChange"]}],[1,"lottery-tipping-filter",{"quickFiltersActive":[516,"quick-filters-active"],"mbSource":[513,"mb-source"],"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"language":[513],"translationUrl":[520,"translation-url"],"isOpen":[32],"filterData":[32],"ticketTypeList":[32],"showClearButton":[32]},[[0,"modalCloseEvent","handleModalClose"]],{"clientStyling":["handleClientStylingChange"],"clientStylingUrl":["handleClientStylingUrlChange"],"mbSource":["handleMbSourceChange"]}],[1,"lottery-tipping-pagination",{"total":[2],"pageSizeOptions":[16],"mbSource":[513,"mb-source"],"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"language":[513],"translationUrl":[520,"translation-url"],"current":[2],"pageSize":[32],"totalPages":[32]},null,{"clientStyling":["handleClientStylingChange"],"clientStylingUrl":["handleClientStylingUrlChange"],"mbSource":["handleMbSourceChange"],"total":["updateTotalPages"],"pageSize":["updateTotalPages"]}],[1,"lottery-tipping-panel",{"mbSource":[513,"mb-source"],"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"headerTitle":[1,"header-title"],"expanded":[32]},null,{"clientStyling":["handleClientStylingChange"],"clientStylingUrl":["handleClientStylingUrlChange"],"mbSource":["handleMbSourceChange"]}],[1,"lottery-tipping-bullet-group",{"mbSource":[513,"mb-source"],"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"positionIdx":[513,"position-idx"],"theme":[513],"mode":[513],"bulletConfigContent":[513,"bullet-config-content"]},[[0,"lotteryTippingBulletToggle","lotteryTippingBulletSelectionHandler"]],{"clientStyling":["handleClientStylingChange"],"clientStylingUrl":["handleClientStylingUrlChange"],"mbSource":["handleMbSourceChange"]}],[1,"general-multi-select",{"mbSource":[513,"mb-source"],"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"options":[16],"maxVisibleChips":[2,"max-visible-chips"],"placeholder":[1],"selectedValues":[32],"dropdownOpen":[32],"overflowOpen":[32],"popoverStyle":[32],"clear":[64]},null,{"clientStyling":["handleClientStylingChange"],"clientStylingUrl":["handleClientStylingUrlChange"],"mbSource":["handleMbSourceChange"]}],[1,"general-tooltip",{"mbSource":[513,"mb-source"],"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"position":[1],"delay":[2],"isVisible":[32],"_tooltipId":[32]},[[1,"mouseenter","handleMouseEnterOrFocus"],[0,"focusin","handleMouseEnterOrFocus"],[1,"mouseleave","handleMouseLeaveOrBlur"],[0,"focusout","handleMouseLeaveOrBlur"],[0,"keydown","handleKeyDown"]],{"clientStyling":["handleClientStylingChange"],"clientStylingUrl":["handleClientStylingUrlChange"],"mbSource":["handleMbSourceChange"]}],[1,"lottery-tipping-dialog",{"mbSource":[1,"mb-source"],"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"visible":[516],"dialogTitle":[1,"dialog-title"],"width":[1],"closable":[4],"mask":[4],"maskClosable":[4,"mask-closable"],"animationDuration":[2,"animation-duration"],"fullscreen":[4],"showFooter":[4,"show-footer"],"showCancelBtn":[4,"show-cancel-btn"],"language":[513],"translationUrl":[520,"translation-url"]},null,{"clientStyling":["handleClientStylingChange"],"clientStylingUrl":["handleClientStylingUrlChange"],"mbSource":["handleMbSourceChange"]}],[1,"lottery-tipping-bullet",{"mbSource":[513,"mb-source"],"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"positionIdx":[514,"position-idx"],"theme":[513],"value":[513],"disabled":[516],"isSelected":[516,"is-selected"]},null,{"clientStyling":["handleClientStylingChange"],"clientStylingUrl":["handleClientStylingUrlChange"],"mbSource":["handleMbSourceChange"]}]]]], options);
20
20
  });