@everymatrix/lottery-game-page 1.87.28 → 1.87.29
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/general-multi-select_16.cjs.entry.js +466 -69
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/lottery-game-page.cjs.js +1 -1
- package/dist/collection/components/lottery-game-page/lottery-game-page.js +50 -68
- package/dist/collection/models/index.js +10 -0
- package/dist/collection/utils/api.js +33 -0
- package/dist/collection/utils/locale.utils.js +7 -5
- package/dist/collection/utils/utils.js +26 -0
- package/dist/esm/general-multi-select_16.entry.js +466 -69
- package/dist/esm/loader.js +1 -1
- package/dist/esm/lottery-game-page.js +1 -1
- package/dist/lottery-game-page/general-multi-select_16.entry.js +25 -25
- package/dist/lottery-game-page/lottery-game-page.esm.js +1 -1
- package/dist/types/components/lottery-game-page/lottery-game-page.d.ts +17 -5
- package/dist/types/components.d.ts +9 -0
- package/dist/types/models/index.d.ts +106 -0
- package/dist/types/utils/api.d.ts +6 -0
- package/dist/types/utils/utils.d.ts +2 -0
- package/package.json +1 -1
package/dist/cjs/loader.cjs.js
CHANGED
|
@@ -8,7 +8,7 @@ const appGlobals = require('./app-globals-3a1e7e63.js');
|
|
|
8
8
|
const defineCustomElements = async (win, options) => {
|
|
9
9
|
if (typeof window === 'undefined') return undefined;
|
|
10
10
|
await appGlobals.globalScripts();
|
|
11
|
-
return index.bootstrapLazy(JSON.parse("[[\"general-multi-select_16.cjs\",[[1,\"lottery-game-page\",{\"endpoint\":[513],\"gameId\":[513,\"game-id\"],\"playerId\":[514,\"player-id\"],\"sessionId\":[513,\"session-id\"],\"language\":[513],\"backgroundUrl\":[513,\"background-url\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"translationUrl\":[513,\"translation-url\"],\"tickets\":[32],\"mainTickets\":[32],\"secondaryTickets\":[32],\"tabIndex\":[32],\"hasErrors\":[32],\"totalAmount\":[32],\"successVisible\":[32],\"daysRemaining\":[32],\"hoursRemaining\":[32],\"minutesRemaining\":[32],\"secondsRemaining\":[32],\"nextDate\":[32],\"isLoggedIn\":[32],\"loginModalVisible\":[32],\"isLoading\":[32],\"showSubmitError\":[32],\"submitError\":[32],\"showApiError\":[32],\"apiError\":[32],\"translationData\":[32],\"isSubscription\":[32],\"subscriptionParam\":[32],\"showSubscriptionError\":[32],\"subscriptionError\":[32],\"isSubscribed\":[32],\"isFetchingGame\":[32]},[[0,\"ticketCompleted\",\"gridFilledHandler\"],[0,\"gridDirty\",\"gridDirtyHandler\"],[0,\"modalCloseEvent\",\"modalCloseEvent\"],[0,\"stakeChange\",\"stakeChangeHandler\"],[0,\"multiplierChange\",\"multiplierChangeHandler\"],[0,\"drawMultiplierChange\",\"drawMultiplierChangeHandler\"],[0,\"lineMultiplierChange\",\"lineMultiplierChangeHandler\"],[0,\"betTypeChange\",\"betTypeChangeHandler\"],[0,\"subscriptionCompleted\",\"handleSubscriptionReady\"],[0,\"subscriptionCheckChange\",\"handleSubscriptionCheckChange\"]],{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"],\"translationUrl\":[\"handleNewTranslations\"],\"endpoint\":[\"watchGameInfoChange\"],\"gameId\":[\"watchGameInfoChange\"]}],[1,\"lottery-draw-results-history\",{\"endpoint\":[513],\"gameId\":[513,\"game-id\"],\"language\":[513],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"translationUrl\":[520,\"translation-url\"],\"drawData\":[32],\"winningDataSetsData\":[32],\"dateFiltersFrom\":[32],\"dateFiltersTo\":[32],\"isLoading\":[32],\"noResults\":[32],\"activeIndex\":[32],\"totalResults\":[32],\"limit\":[32],\"offset\":[32]},[[0,\"filterSelection\",\"filtersHandler\"],[0,\"filterSelectionReset\",\"clearFiltersHandler\"],[0,\"hpPageChange\",\"hpPageChange\"]],{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}],[1,\"lottery-ticket-controller\",{\"endpoint\":[513],\"ticketId\":[514,\"ticket-id\"],\"ticketDescription\":[513,\"ticket-description\"],\"gameId\":[513,\"game-id\"],\"postMessage\":[516,\"post-message\"],\"eventName\":[513,\"event-name\"],\"collapsed\":[516],\"numberOfGrids\":[514,\"number-of-grids\"],\"last\":[516],\"language\":[513],\"autoPick\":[516,\"auto-pick\"],\"resetButton\":[516,\"reset-button\"],\"totalControllers\":[514,\"total-controllers\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"translationUrl\":[520,\"translation-url\"]},[[0,\"helperAccordionAction\",\"helperAccordionActionHandler\"]],{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}],[1,\"lottery-game-details\",{\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"lowNumber\":[514,\"low-number\"],\"highNumber\":[514,\"high-number\"],\"minimumAllowed\":[514,\"minimum-allowed\"],\"maxinumAllowed\":[514,\"maxinum-allowed\"],\"language\":[513],\"translationUrl\":[520,\"translation-url\"]},null,{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}],[1,\"lottery-subscription\",{\"translationUrl\":[520,\"translation-url\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"endpoint\":[513],\"language\":[513],\"gameName\":[513,\"game-name\"],\"isSubscribed\":[32],\"frequenceList\":[32],\"frequenceState\":[32],\"filterData\":[32],\"subscriptionCode\":[32],\"conditionId\":[32],\"paramId\":[32],\"conditionRule\":[32],\"paramRule\":[32],\"peroidRule\":[32],\"startDateRule\":[32],\"endDateRule\":[32],\"gameNameRule\":[32],\"ruleType\":[32]},null,{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}],[1,\"helper-filters\",{\"activateTicketSearch\":[516,\"activate-ticket-search\"],\"gameId\":[513,\"game-id\"],\"playerId\":[513,\"player-id\"],\"session\":[513],\"postMessage\":[516,\"post-message\"],\"language\":[513],\"quickFiltersActive\":[516,\"quick-filters-active\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrlContent\":[513,\"client-styling-url-content\"],\"translationUrl\":[520,\"translation-url\"],\"showFilterModal\":[32],\"showClearButton\":[32],\"filterData\":[32],\"filterDataReset\":[32],\"limitStylingAppends\":[32],\"ticketTypeList\":[32]},[[0,\"modalCloseEvent\",\"modalCloseEvent\"]]],[1,\"lottery-draw-results\",{\"endpoint\":[513],\"gameId\":[513,\"game-id\"],\"language\":[513],\"playerId\":[513,\"player-id\"],\"drawMode\":[516,\"draw-mode\"],\"drawId\":[513,\"draw-id\"],\"gameName\":[513,\"game-name\"],\"ticketDate\":[513,\"ticket-date\"],\"ticketStatus\":[513,\"ticket-status\"],\"ticketId\":[513,\"ticket-id\"],\"ticketType\":[513,\"ticket-type\"],\"ticketAmount\":[513,\"ticket-amount\"],\"ticketCurrency\":[513,\"ticket-currency\"],\"ticketMultiplier\":[516,\"ticket-multiplier\"],\"ticketMultiplierNum\":[514,\"ticket-multiplier-num\"],\"ticketDrawCount\":[514,\"ticket-draw-count\"],\"ticketNumbers\":[513,\"ticket-numbers\"],\"sessionId\":[513,\"session-id\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"ticketDrawData\":[513,\"ticket-draw-data\"],\"historyDrawData\":[513,\"history-draw-data\"],\"tabValue\":[513,\"tab-value\"],\"translationUrl\":[520,\"translation-url\"],\"multiplier\":[32],\"isLoading\":[32],\"hasErrors\":[32],\"errorText\":[32],\"ticketData\":[32],\"ticketDataLoaded\":[32],\"ticketDraws\":[32],\"toggleDrawer\":[32],\"drawData\":[32],\"resultMap\":[32]},null,{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}],[1,\"lottery-ticket\",{\"endpoint\":[513],\"gameId\":[513,\"game-id\"],\"numberOfGrids\":[514,\"number-of-grids\"],\"multipleDraws\":[516,\"multiple-draws\"],\"ticketId\":[514,\"ticket-id\"],\"resetButton\":[516,\"reset-button\"],\"autoPick\":[516,\"auto-pick\"],\"language\":[513],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"translationUrl\":[520,\"translation-url\"],\"isLoading\":[32],\"hasErrors\":[32],\"ticketDone\":[32],\"isCustomSelect\":[32],\"amountInfo\":[32],\"stakeMultiplier\":[32],\"lineMultiplier\":[32],\"isCustomSelectStake\":[32],\"isCustomSelectDraw\":[32],\"isCustomSelectLine\":[32],\"drawMultiplier\":[32],\"secondarySelectionAllowed\":[32],\"partialQuickpickAvailable\":[32],\"boardsAllowed\":[32],\"tabIndex\":[32],\"groupType\":[32],\"playType\":[32],\"selectedPlayTypeId\":[32],\"maximumAllowed\":[32],\"numberRange\":[32],\"secondaryNumberRange\":[32],\"secondaryMaximumAllowed\":[32],\"minimumAllowed\":[32],\"secondaryMinimumAllowed\":[32],\"quickPicks\":[32]},[[8,\"click\",\"checkForClickOutside\"],[0,\"gridFilled\",\"gridFilledHandler\"],[0,\"gridClearAllEvent\",\"handleGridClearAllEvent\"],[4,\"resetAllTicketSelection\",\"toggleResetAllSeletion\"]],{\"lineMultiplier\":[\"handleLineMultiplierChange\"],\"tabIndex\":[\"handleTabIndexChange\"],\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}],[1,\"helper-tabs\",{\"disabled\":[516],\"label\":[513],\"selected\":[516],\"cmsEndpoint\":[513,\"cms-endpoint\"],\"selectedIndex\":[1538,\"selected-index\"],\"tabs\":[16],\"clientStyling\":[513,\"client-styling\"],\"mbSource\":[1,\"mb-source\"],\"clientStylingurl\":[513,\"client-stylingurl\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"lowNumber\":[514,\"low-number\"],\"highNumber\":[514,\"high-number\"],\"minimumAllowed\":[514,\"minimum-allowed\"],\"maxinumAllowed\":[514,\"maxinum-allowed\"],\"language\":[513],\"translationUrl\":[520,\"translation-url\"]},null,{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingChangeURL\"]}],[1,\"lottery-pagination\",{\"nextPage\":[1540,\"next-page\"],\"prevPage\":[1540,\"prev-page\"],\"offset\":[1538],\"limit\":[1538],\"total\":[1538],\"language\":[1537],\"clientStyling\":[1537,\"client-styling\"],\"clientStylingUrl\":[1537,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"arrowsActive\":[1540,\"arrows-active\"],\"secondaryArrowsActive\":[1540,\"secondary-arrows-active\"],\"numberedNavActive\":[1540,\"numbered-nav-active\"],\"isReset\":[1540,\"is-reset\"],\"translationUrl\":[520,\"translation-url\"],\"offsetInt\":[32],\"lastPage\":[32],\"previousPage\":[32],\"limitInt\":[32],\"totalInt\":[32],\"pagesArray\":[32],\"endInt\":[32]},null,{\"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,\"helper-accordion\",{\"mbSource\":[513,\"mb-source\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"ticketHistoryFlag\":[516,\"ticket-history-flag\"],\"headerTitle\":[513,\"header-title\"],\"headerSubtitle\":[513,\"header-subtitle\"],\"description\":[513],\"footer\":[516],\"deleteTab\":[516,\"delete-tab\"],\"postMessage\":[516,\"post-message\"],\"eventName\":[513,\"event-name\"],\"collapsed\":[516],\"language\":[513],\"translationUrl\":[520,\"translation-url\"],\"showContent\":[32]},null,{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}],[1,\"helper-modal\",{\"titleModal\":[513,\"title-modal\"],\"visible\":[1540],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrlContent\":[513,\"client-styling-url-content\"],\"limitStylingAppends\":[32]}],[1,\"helper-tab\",{\"selectedIndex\":[514,\"selected-index\"],\"cmsEndpoint\":[513,\"cms-endpoint\"],\"mbSource\":[1,\"mb-source\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"lowNumber\":[514,\"low-number\"],\"highNumber\":[514,\"high-number\"],\"minimumAllowed\":[514,\"minimum-allowed\"],\"maxinumAllowed\":[514,\"maxinum-allowed\"],\"language\":[513],\"translationUrl\":[520,\"translation-url\"],\"tabContent\":[32]},null,{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingChangeURL\"]}],[1,\"lottery-grid\",{\"ticketId\":[514,\"ticket-id\"],\"totalNumbers\":[514,\"total-numbers\"],\"gameId\":[513,\"game-id\"],\"maximumAllowed\":[514,\"maximum-allowed\"],\"minimumAllowed\":[514,\"minimum-allowed\"],\"numberRange\":[513,\"number-range\"],\"selectable\":[516],\"selectedNumbers\":[513,\"selected-numbers\"],\"secondaryNumbers\":[513,\"secondary-numbers\"],\"displaySelected\":[516,\"display-selected\"],\"language\":[513],\"gridIndex\":[514,\"grid-index\"],\"gridType\":[513,\"grid-type\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"highNumber\":[514,\"high-number\"],\"lowNumber\":[514,\"low-number\"],\"selectionType\":[513,\"selection-type\"],\"partialQuickpickAvailable\":[516,\"partial-quickpick-available\"],\"numbers\":[32],\"bonusNumbers\":[32]},[[0,\"lotteryBulletSelection\",\"lotteryBulletSelectionHandler\"],[4,\"resetSelection\",\"resetSelectionHandler\"],[4,\"autoSelection\",\"autoSelectionHandler\"]],{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}],[1,\"lottery-bullet\",{\"value\":[513],\"selectable\":[516],\"isSelected\":[516,\"is-selected\"],\"isBonus\":[516,\"is-bonus\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"]},null,{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}]]]]"), options);
|
|
11
|
+
return index.bootstrapLazy(JSON.parse("[[\"general-multi-select_16.cjs\",[[1,\"lottery-game-page\",{\"endpoint\":[513],\"gameId\":[513,\"game-id\"],\"playerId\":[514,\"player-id\"],\"sessionId\":[513,\"session-id\"],\"language\":[513],\"backgroundUrl\":[513,\"background-url\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"translationUrl\":[513,\"translation-url\"],\"tickets\":[32],\"mainTickets\":[32],\"secondaryTickets\":[32],\"tabIndex\":[32],\"hasErrors\":[32],\"totalAmount\":[32],\"successVisible\":[32],\"nextDate\":[32],\"isLoggedIn\":[32],\"loginModalVisible\":[32],\"isLoading\":[32],\"showSubmitError\":[32],\"submitError\":[32],\"showApiError\":[32],\"apiError\":[32],\"translationData\":[32],\"isSubscription\":[32],\"subscriptionParam\":[32],\"showSubscriptionError\":[32],\"subscriptionError\":[32],\"isSubscribed\":[32],\"isFetchingGame\":[32],\"drawSubmitAvailable\":[32],\"formattedTime\":[32]},[[0,\"ticketCompleted\",\"gridFilledHandler\"],[0,\"gridDirty\",\"gridDirtyHandler\"],[0,\"modalCloseEvent\",\"modalCloseEvent\"],[0,\"stakeChange\",\"stakeChangeHandler\"],[0,\"multiplierChange\",\"multiplierChangeHandler\"],[0,\"drawMultiplierChange\",\"drawMultiplierChangeHandler\"],[0,\"lineMultiplierChange\",\"lineMultiplierChangeHandler\"],[0,\"betTypeChange\",\"betTypeChangeHandler\"],[0,\"subscriptionCompleted\",\"handleSubscriptionReady\"],[0,\"subscriptionCheckChange\",\"handleSubscriptionCheckChange\"]],{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"],\"translationUrl\":[\"handleNewTranslations\"],\"endpoint\":[\"watchGameInfoChange\"],\"gameId\":[\"watchGameInfoChange\"]}],[1,\"lottery-draw-results-history\",{\"endpoint\":[513],\"gameId\":[513,\"game-id\"],\"language\":[513],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"translationUrl\":[520,\"translation-url\"],\"drawData\":[32],\"winningDataSetsData\":[32],\"dateFiltersFrom\":[32],\"dateFiltersTo\":[32],\"isLoading\":[32],\"noResults\":[32],\"activeIndex\":[32],\"totalResults\":[32],\"limit\":[32],\"offset\":[32]},[[0,\"filterSelection\",\"filtersHandler\"],[0,\"filterSelectionReset\",\"clearFiltersHandler\"],[0,\"hpPageChange\",\"hpPageChange\"]],{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}],[1,\"lottery-ticket-controller\",{\"endpoint\":[513],\"ticketId\":[514,\"ticket-id\"],\"ticketDescription\":[513,\"ticket-description\"],\"gameId\":[513,\"game-id\"],\"postMessage\":[516,\"post-message\"],\"eventName\":[513,\"event-name\"],\"collapsed\":[516],\"numberOfGrids\":[514,\"number-of-grids\"],\"last\":[516],\"language\":[513],\"autoPick\":[516,\"auto-pick\"],\"resetButton\":[516,\"reset-button\"],\"totalControllers\":[514,\"total-controllers\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"translationUrl\":[520,\"translation-url\"]},[[0,\"helperAccordionAction\",\"helperAccordionActionHandler\"]],{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}],[1,\"lottery-game-details\",{\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"lowNumber\":[514,\"low-number\"],\"highNumber\":[514,\"high-number\"],\"minimumAllowed\":[514,\"minimum-allowed\"],\"maxinumAllowed\":[514,\"maxinum-allowed\"],\"language\":[513],\"translationUrl\":[520,\"translation-url\"]},null,{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}],[1,\"lottery-subscription\",{\"translationUrl\":[520,\"translation-url\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"endpoint\":[513],\"language\":[513],\"gameName\":[513,\"game-name\"],\"isSubscribed\":[32],\"frequenceList\":[32],\"frequenceState\":[32],\"filterData\":[32],\"subscriptionCode\":[32],\"conditionId\":[32],\"paramId\":[32],\"conditionRule\":[32],\"paramRule\":[32],\"peroidRule\":[32],\"startDateRule\":[32],\"endDateRule\":[32],\"gameNameRule\":[32],\"ruleType\":[32]},null,{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}],[1,\"helper-filters\",{\"activateTicketSearch\":[516,\"activate-ticket-search\"],\"gameId\":[513,\"game-id\"],\"playerId\":[513,\"player-id\"],\"session\":[513],\"postMessage\":[516,\"post-message\"],\"language\":[513],\"quickFiltersActive\":[516,\"quick-filters-active\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrlContent\":[513,\"client-styling-url-content\"],\"translationUrl\":[520,\"translation-url\"],\"showFilterModal\":[32],\"showClearButton\":[32],\"filterData\":[32],\"filterDataReset\":[32],\"limitStylingAppends\":[32],\"ticketTypeList\":[32]},[[0,\"modalCloseEvent\",\"modalCloseEvent\"]]],[1,\"lottery-draw-results\",{\"endpoint\":[513],\"gameId\":[513,\"game-id\"],\"language\":[513],\"playerId\":[513,\"player-id\"],\"drawMode\":[516,\"draw-mode\"],\"drawId\":[513,\"draw-id\"],\"gameName\":[513,\"game-name\"],\"ticketDate\":[513,\"ticket-date\"],\"ticketStatus\":[513,\"ticket-status\"],\"ticketId\":[513,\"ticket-id\"],\"ticketType\":[513,\"ticket-type\"],\"ticketAmount\":[513,\"ticket-amount\"],\"ticketCurrency\":[513,\"ticket-currency\"],\"ticketMultiplier\":[516,\"ticket-multiplier\"],\"ticketMultiplierNum\":[514,\"ticket-multiplier-num\"],\"ticketDrawCount\":[514,\"ticket-draw-count\"],\"ticketNumbers\":[513,\"ticket-numbers\"],\"sessionId\":[513,\"session-id\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"ticketDrawData\":[513,\"ticket-draw-data\"],\"historyDrawData\":[513,\"history-draw-data\"],\"tabValue\":[513,\"tab-value\"],\"translationUrl\":[520,\"translation-url\"],\"multiplier\":[32],\"isLoading\":[32],\"hasErrors\":[32],\"errorText\":[32],\"ticketData\":[32],\"ticketDataLoaded\":[32],\"ticketDraws\":[32],\"toggleDrawer\":[32],\"drawData\":[32],\"resultMap\":[32]},null,{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}],[1,\"lottery-ticket\",{\"endpoint\":[513],\"gameId\":[513,\"game-id\"],\"numberOfGrids\":[514,\"number-of-grids\"],\"multipleDraws\":[516,\"multiple-draws\"],\"ticketId\":[514,\"ticket-id\"],\"resetButton\":[516,\"reset-button\"],\"autoPick\":[516,\"auto-pick\"],\"language\":[513],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"translationUrl\":[520,\"translation-url\"],\"isLoading\":[32],\"hasErrors\":[32],\"ticketDone\":[32],\"isCustomSelect\":[32],\"amountInfo\":[32],\"stakeMultiplier\":[32],\"lineMultiplier\":[32],\"isCustomSelectStake\":[32],\"isCustomSelectDraw\":[32],\"isCustomSelectLine\":[32],\"drawMultiplier\":[32],\"secondarySelectionAllowed\":[32],\"partialQuickpickAvailable\":[32],\"boardsAllowed\":[32],\"tabIndex\":[32],\"groupType\":[32],\"playType\":[32],\"selectedPlayTypeId\":[32],\"maximumAllowed\":[32],\"numberRange\":[32],\"secondaryNumberRange\":[32],\"secondaryMaximumAllowed\":[32],\"minimumAllowed\":[32],\"secondaryMinimumAllowed\":[32],\"quickPicks\":[32]},[[8,\"click\",\"checkForClickOutside\"],[0,\"gridFilled\",\"gridFilledHandler\"],[0,\"gridClearAllEvent\",\"handleGridClearAllEvent\"],[4,\"resetAllTicketSelection\",\"toggleResetAllSeletion\"]],{\"lineMultiplier\":[\"handleLineMultiplierChange\"],\"tabIndex\":[\"handleTabIndexChange\"],\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}],[1,\"helper-tabs\",{\"disabled\":[516],\"label\":[513],\"selected\":[516],\"cmsEndpoint\":[513,\"cms-endpoint\"],\"selectedIndex\":[1538,\"selected-index\"],\"tabs\":[16],\"clientStyling\":[513,\"client-styling\"],\"mbSource\":[1,\"mb-source\"],\"clientStylingurl\":[513,\"client-stylingurl\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"lowNumber\":[514,\"low-number\"],\"highNumber\":[514,\"high-number\"],\"minimumAllowed\":[514,\"minimum-allowed\"],\"maxinumAllowed\":[514,\"maxinum-allowed\"],\"language\":[513],\"translationUrl\":[520,\"translation-url\"]},null,{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingChangeURL\"]}],[1,\"lottery-pagination\",{\"nextPage\":[1540,\"next-page\"],\"prevPage\":[1540,\"prev-page\"],\"offset\":[1538],\"limit\":[1538],\"total\":[1538],\"language\":[1537],\"clientStyling\":[1537,\"client-styling\"],\"clientStylingUrl\":[1537,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"arrowsActive\":[1540,\"arrows-active\"],\"secondaryArrowsActive\":[1540,\"secondary-arrows-active\"],\"numberedNavActive\":[1540,\"numbered-nav-active\"],\"isReset\":[1540,\"is-reset\"],\"translationUrl\":[520,\"translation-url\"],\"offsetInt\":[32],\"lastPage\":[32],\"previousPage\":[32],\"limitInt\":[32],\"totalInt\":[32],\"pagesArray\":[32],\"endInt\":[32]},null,{\"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,\"helper-accordion\",{\"mbSource\":[513,\"mb-source\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"ticketHistoryFlag\":[516,\"ticket-history-flag\"],\"headerTitle\":[513,\"header-title\"],\"headerSubtitle\":[513,\"header-subtitle\"],\"description\":[513],\"footer\":[516],\"deleteTab\":[516,\"delete-tab\"],\"postMessage\":[516,\"post-message\"],\"eventName\":[513,\"event-name\"],\"collapsed\":[516],\"language\":[513],\"translationUrl\":[520,\"translation-url\"],\"showContent\":[32]},null,{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}],[1,\"helper-modal\",{\"titleModal\":[513,\"title-modal\"],\"visible\":[1540],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrlContent\":[513,\"client-styling-url-content\"],\"limitStylingAppends\":[32]}],[1,\"helper-tab\",{\"selectedIndex\":[514,\"selected-index\"],\"cmsEndpoint\":[513,\"cms-endpoint\"],\"mbSource\":[1,\"mb-source\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"lowNumber\":[514,\"low-number\"],\"highNumber\":[514,\"high-number\"],\"minimumAllowed\":[514,\"minimum-allowed\"],\"maxinumAllowed\":[514,\"maxinum-allowed\"],\"language\":[513],\"translationUrl\":[520,\"translation-url\"],\"tabContent\":[32]},null,{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingChangeURL\"]}],[1,\"lottery-grid\",{\"ticketId\":[514,\"ticket-id\"],\"totalNumbers\":[514,\"total-numbers\"],\"gameId\":[513,\"game-id\"],\"maximumAllowed\":[514,\"maximum-allowed\"],\"minimumAllowed\":[514,\"minimum-allowed\"],\"numberRange\":[513,\"number-range\"],\"selectable\":[516],\"selectedNumbers\":[513,\"selected-numbers\"],\"secondaryNumbers\":[513,\"secondary-numbers\"],\"displaySelected\":[516,\"display-selected\"],\"language\":[513],\"gridIndex\":[514,\"grid-index\"],\"gridType\":[513,\"grid-type\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"highNumber\":[514,\"high-number\"],\"lowNumber\":[514,\"low-number\"],\"selectionType\":[513,\"selection-type\"],\"partialQuickpickAvailable\":[516,\"partial-quickpick-available\"],\"numbers\":[32],\"bonusNumbers\":[32]},[[0,\"lotteryBulletSelection\",\"lotteryBulletSelectionHandler\"],[4,\"resetSelection\",\"resetSelectionHandler\"],[4,\"autoSelection\",\"autoSelectionHandler\"]],{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}],[1,\"lottery-bullet\",{\"value\":[513],\"selectable\":[516],\"isSelected\":[516,\"is-selected\"],\"isBonus\":[516,\"is-bonus\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"]},null,{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}]]]]"), options);
|
|
12
12
|
};
|
|
13
13
|
|
|
14
14
|
exports.setNonce = index.setNonce;
|
|
@@ -19,7 +19,7 @@ var patchBrowser = () => {
|
|
|
19
19
|
|
|
20
20
|
patchBrowser().then(async (options) => {
|
|
21
21
|
await appGlobals.globalScripts();
|
|
22
|
-
return index.bootstrapLazy(JSON.parse("[[\"general-multi-select_16.cjs\",[[1,\"lottery-game-page\",{\"endpoint\":[513],\"gameId\":[513,\"game-id\"],\"playerId\":[514,\"player-id\"],\"sessionId\":[513,\"session-id\"],\"language\":[513],\"backgroundUrl\":[513,\"background-url\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"translationUrl\":[513,\"translation-url\"],\"tickets\":[32],\"mainTickets\":[32],\"secondaryTickets\":[32],\"tabIndex\":[32],\"hasErrors\":[32],\"totalAmount\":[32],\"successVisible\":[32],\"daysRemaining\":[32],\"hoursRemaining\":[32],\"minutesRemaining\":[32],\"secondsRemaining\":[32],\"nextDate\":[32],\"isLoggedIn\":[32],\"loginModalVisible\":[32],\"isLoading\":[32],\"showSubmitError\":[32],\"submitError\":[32],\"showApiError\":[32],\"apiError\":[32],\"translationData\":[32],\"isSubscription\":[32],\"subscriptionParam\":[32],\"showSubscriptionError\":[32],\"subscriptionError\":[32],\"isSubscribed\":[32],\"isFetchingGame\":[32]},[[0,\"ticketCompleted\",\"gridFilledHandler\"],[0,\"gridDirty\",\"gridDirtyHandler\"],[0,\"modalCloseEvent\",\"modalCloseEvent\"],[0,\"stakeChange\",\"stakeChangeHandler\"],[0,\"multiplierChange\",\"multiplierChangeHandler\"],[0,\"drawMultiplierChange\",\"drawMultiplierChangeHandler\"],[0,\"lineMultiplierChange\",\"lineMultiplierChangeHandler\"],[0,\"betTypeChange\",\"betTypeChangeHandler\"],[0,\"subscriptionCompleted\",\"handleSubscriptionReady\"],[0,\"subscriptionCheckChange\",\"handleSubscriptionCheckChange\"]],{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"],\"translationUrl\":[\"handleNewTranslations\"],\"endpoint\":[\"watchGameInfoChange\"],\"gameId\":[\"watchGameInfoChange\"]}],[1,\"lottery-draw-results-history\",{\"endpoint\":[513],\"gameId\":[513,\"game-id\"],\"language\":[513],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"translationUrl\":[520,\"translation-url\"],\"drawData\":[32],\"winningDataSetsData\":[32],\"dateFiltersFrom\":[32],\"dateFiltersTo\":[32],\"isLoading\":[32],\"noResults\":[32],\"activeIndex\":[32],\"totalResults\":[32],\"limit\":[32],\"offset\":[32]},[[0,\"filterSelection\",\"filtersHandler\"],[0,\"filterSelectionReset\",\"clearFiltersHandler\"],[0,\"hpPageChange\",\"hpPageChange\"]],{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}],[1,\"lottery-ticket-controller\",{\"endpoint\":[513],\"ticketId\":[514,\"ticket-id\"],\"ticketDescription\":[513,\"ticket-description\"],\"gameId\":[513,\"game-id\"],\"postMessage\":[516,\"post-message\"],\"eventName\":[513,\"event-name\"],\"collapsed\":[516],\"numberOfGrids\":[514,\"number-of-grids\"],\"last\":[516],\"language\":[513],\"autoPick\":[516,\"auto-pick\"],\"resetButton\":[516,\"reset-button\"],\"totalControllers\":[514,\"total-controllers\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"translationUrl\":[520,\"translation-url\"]},[[0,\"helperAccordionAction\",\"helperAccordionActionHandler\"]],{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}],[1,\"lottery-game-details\",{\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"lowNumber\":[514,\"low-number\"],\"highNumber\":[514,\"high-number\"],\"minimumAllowed\":[514,\"minimum-allowed\"],\"maxinumAllowed\":[514,\"maxinum-allowed\"],\"language\":[513],\"translationUrl\":[520,\"translation-url\"]},null,{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}],[1,\"lottery-subscription\",{\"translationUrl\":[520,\"translation-url\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"endpoint\":[513],\"language\":[513],\"gameName\":[513,\"game-name\"],\"isSubscribed\":[32],\"frequenceList\":[32],\"frequenceState\":[32],\"filterData\":[32],\"subscriptionCode\":[32],\"conditionId\":[32],\"paramId\":[32],\"conditionRule\":[32],\"paramRule\":[32],\"peroidRule\":[32],\"startDateRule\":[32],\"endDateRule\":[32],\"gameNameRule\":[32],\"ruleType\":[32]},null,{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}],[1,\"helper-filters\",{\"activateTicketSearch\":[516,\"activate-ticket-search\"],\"gameId\":[513,\"game-id\"],\"playerId\":[513,\"player-id\"],\"session\":[513],\"postMessage\":[516,\"post-message\"],\"language\":[513],\"quickFiltersActive\":[516,\"quick-filters-active\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrlContent\":[513,\"client-styling-url-content\"],\"translationUrl\":[520,\"translation-url\"],\"showFilterModal\":[32],\"showClearButton\":[32],\"filterData\":[32],\"filterDataReset\":[32],\"limitStylingAppends\":[32],\"ticketTypeList\":[32]},[[0,\"modalCloseEvent\",\"modalCloseEvent\"]]],[1,\"lottery-draw-results\",{\"endpoint\":[513],\"gameId\":[513,\"game-id\"],\"language\":[513],\"playerId\":[513,\"player-id\"],\"drawMode\":[516,\"draw-mode\"],\"drawId\":[513,\"draw-id\"],\"gameName\":[513,\"game-name\"],\"ticketDate\":[513,\"ticket-date\"],\"ticketStatus\":[513,\"ticket-status\"],\"ticketId\":[513,\"ticket-id\"],\"ticketType\":[513,\"ticket-type\"],\"ticketAmount\":[513,\"ticket-amount\"],\"ticketCurrency\":[513,\"ticket-currency\"],\"ticketMultiplier\":[516,\"ticket-multiplier\"],\"ticketMultiplierNum\":[514,\"ticket-multiplier-num\"],\"ticketDrawCount\":[514,\"ticket-draw-count\"],\"ticketNumbers\":[513,\"ticket-numbers\"],\"sessionId\":[513,\"session-id\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"ticketDrawData\":[513,\"ticket-draw-data\"],\"historyDrawData\":[513,\"history-draw-data\"],\"tabValue\":[513,\"tab-value\"],\"translationUrl\":[520,\"translation-url\"],\"multiplier\":[32],\"isLoading\":[32],\"hasErrors\":[32],\"errorText\":[32],\"ticketData\":[32],\"ticketDataLoaded\":[32],\"ticketDraws\":[32],\"toggleDrawer\":[32],\"drawData\":[32],\"resultMap\":[32]},null,{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}],[1,\"lottery-ticket\",{\"endpoint\":[513],\"gameId\":[513,\"game-id\"],\"numberOfGrids\":[514,\"number-of-grids\"],\"multipleDraws\":[516,\"multiple-draws\"],\"ticketId\":[514,\"ticket-id\"],\"resetButton\":[516,\"reset-button\"],\"autoPick\":[516,\"auto-pick\"],\"language\":[513],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"translationUrl\":[520,\"translation-url\"],\"isLoading\":[32],\"hasErrors\":[32],\"ticketDone\":[32],\"isCustomSelect\":[32],\"amountInfo\":[32],\"stakeMultiplier\":[32],\"lineMultiplier\":[32],\"isCustomSelectStake\":[32],\"isCustomSelectDraw\":[32],\"isCustomSelectLine\":[32],\"drawMultiplier\":[32],\"secondarySelectionAllowed\":[32],\"partialQuickpickAvailable\":[32],\"boardsAllowed\":[32],\"tabIndex\":[32],\"groupType\":[32],\"playType\":[32],\"selectedPlayTypeId\":[32],\"maximumAllowed\":[32],\"numberRange\":[32],\"secondaryNumberRange\":[32],\"secondaryMaximumAllowed\":[32],\"minimumAllowed\":[32],\"secondaryMinimumAllowed\":[32],\"quickPicks\":[32]},[[8,\"click\",\"checkForClickOutside\"],[0,\"gridFilled\",\"gridFilledHandler\"],[0,\"gridClearAllEvent\",\"handleGridClearAllEvent\"],[4,\"resetAllTicketSelection\",\"toggleResetAllSeletion\"]],{\"lineMultiplier\":[\"handleLineMultiplierChange\"],\"tabIndex\":[\"handleTabIndexChange\"],\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}],[1,\"helper-tabs\",{\"disabled\":[516],\"label\":[513],\"selected\":[516],\"cmsEndpoint\":[513,\"cms-endpoint\"],\"selectedIndex\":[1538,\"selected-index\"],\"tabs\":[16],\"clientStyling\":[513,\"client-styling\"],\"mbSource\":[1,\"mb-source\"],\"clientStylingurl\":[513,\"client-stylingurl\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"lowNumber\":[514,\"low-number\"],\"highNumber\":[514,\"high-number\"],\"minimumAllowed\":[514,\"minimum-allowed\"],\"maxinumAllowed\":[514,\"maxinum-allowed\"],\"language\":[513],\"translationUrl\":[520,\"translation-url\"]},null,{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingChangeURL\"]}],[1,\"lottery-pagination\",{\"nextPage\":[1540,\"next-page\"],\"prevPage\":[1540,\"prev-page\"],\"offset\":[1538],\"limit\":[1538],\"total\":[1538],\"language\":[1537],\"clientStyling\":[1537,\"client-styling\"],\"clientStylingUrl\":[1537,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"arrowsActive\":[1540,\"arrows-active\"],\"secondaryArrowsActive\":[1540,\"secondary-arrows-active\"],\"numberedNavActive\":[1540,\"numbered-nav-active\"],\"isReset\":[1540,\"is-reset\"],\"translationUrl\":[520,\"translation-url\"],\"offsetInt\":[32],\"lastPage\":[32],\"previousPage\":[32],\"limitInt\":[32],\"totalInt\":[32],\"pagesArray\":[32],\"endInt\":[32]},null,{\"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,\"helper-accordion\",{\"mbSource\":[513,\"mb-source\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"ticketHistoryFlag\":[516,\"ticket-history-flag\"],\"headerTitle\":[513,\"header-title\"],\"headerSubtitle\":[513,\"header-subtitle\"],\"description\":[513],\"footer\":[516],\"deleteTab\":[516,\"delete-tab\"],\"postMessage\":[516,\"post-message\"],\"eventName\":[513,\"event-name\"],\"collapsed\":[516],\"language\":[513],\"translationUrl\":[520,\"translation-url\"],\"showContent\":[32]},null,{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}],[1,\"helper-modal\",{\"titleModal\":[513,\"title-modal\"],\"visible\":[1540],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrlContent\":[513,\"client-styling-url-content\"],\"limitStylingAppends\":[32]}],[1,\"helper-tab\",{\"selectedIndex\":[514,\"selected-index\"],\"cmsEndpoint\":[513,\"cms-endpoint\"],\"mbSource\":[1,\"mb-source\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"lowNumber\":[514,\"low-number\"],\"highNumber\":[514,\"high-number\"],\"minimumAllowed\":[514,\"minimum-allowed\"],\"maxinumAllowed\":[514,\"maxinum-allowed\"],\"language\":[513],\"translationUrl\":[520,\"translation-url\"],\"tabContent\":[32]},null,{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingChangeURL\"]}],[1,\"lottery-grid\",{\"ticketId\":[514,\"ticket-id\"],\"totalNumbers\":[514,\"total-numbers\"],\"gameId\":[513,\"game-id\"],\"maximumAllowed\":[514,\"maximum-allowed\"],\"minimumAllowed\":[514,\"minimum-allowed\"],\"numberRange\":[513,\"number-range\"],\"selectable\":[516],\"selectedNumbers\":[513,\"selected-numbers\"],\"secondaryNumbers\":[513,\"secondary-numbers\"],\"displaySelected\":[516,\"display-selected\"],\"language\":[513],\"gridIndex\":[514,\"grid-index\"],\"gridType\":[513,\"grid-type\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"highNumber\":[514,\"high-number\"],\"lowNumber\":[514,\"low-number\"],\"selectionType\":[513,\"selection-type\"],\"partialQuickpickAvailable\":[516,\"partial-quickpick-available\"],\"numbers\":[32],\"bonusNumbers\":[32]},[[0,\"lotteryBulletSelection\",\"lotteryBulletSelectionHandler\"],[4,\"resetSelection\",\"resetSelectionHandler\"],[4,\"autoSelection\",\"autoSelectionHandler\"]],{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}],[1,\"lottery-bullet\",{\"value\":[513],\"selectable\":[516],\"isSelected\":[516,\"is-selected\"],\"isBonus\":[516,\"is-bonus\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"]},null,{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}]]]]"), options);
|
|
22
|
+
return index.bootstrapLazy(JSON.parse("[[\"general-multi-select_16.cjs\",[[1,\"lottery-game-page\",{\"endpoint\":[513],\"gameId\":[513,\"game-id\"],\"playerId\":[514,\"player-id\"],\"sessionId\":[513,\"session-id\"],\"language\":[513],\"backgroundUrl\":[513,\"background-url\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"translationUrl\":[513,\"translation-url\"],\"tickets\":[32],\"mainTickets\":[32],\"secondaryTickets\":[32],\"tabIndex\":[32],\"hasErrors\":[32],\"totalAmount\":[32],\"successVisible\":[32],\"nextDate\":[32],\"isLoggedIn\":[32],\"loginModalVisible\":[32],\"isLoading\":[32],\"showSubmitError\":[32],\"submitError\":[32],\"showApiError\":[32],\"apiError\":[32],\"translationData\":[32],\"isSubscription\":[32],\"subscriptionParam\":[32],\"showSubscriptionError\":[32],\"subscriptionError\":[32],\"isSubscribed\":[32],\"isFetchingGame\":[32],\"drawSubmitAvailable\":[32],\"formattedTime\":[32]},[[0,\"ticketCompleted\",\"gridFilledHandler\"],[0,\"gridDirty\",\"gridDirtyHandler\"],[0,\"modalCloseEvent\",\"modalCloseEvent\"],[0,\"stakeChange\",\"stakeChangeHandler\"],[0,\"multiplierChange\",\"multiplierChangeHandler\"],[0,\"drawMultiplierChange\",\"drawMultiplierChangeHandler\"],[0,\"lineMultiplierChange\",\"lineMultiplierChangeHandler\"],[0,\"betTypeChange\",\"betTypeChangeHandler\"],[0,\"subscriptionCompleted\",\"handleSubscriptionReady\"],[0,\"subscriptionCheckChange\",\"handleSubscriptionCheckChange\"]],{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"],\"translationUrl\":[\"handleNewTranslations\"],\"endpoint\":[\"watchGameInfoChange\"],\"gameId\":[\"watchGameInfoChange\"]}],[1,\"lottery-draw-results-history\",{\"endpoint\":[513],\"gameId\":[513,\"game-id\"],\"language\":[513],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"translationUrl\":[520,\"translation-url\"],\"drawData\":[32],\"winningDataSetsData\":[32],\"dateFiltersFrom\":[32],\"dateFiltersTo\":[32],\"isLoading\":[32],\"noResults\":[32],\"activeIndex\":[32],\"totalResults\":[32],\"limit\":[32],\"offset\":[32]},[[0,\"filterSelection\",\"filtersHandler\"],[0,\"filterSelectionReset\",\"clearFiltersHandler\"],[0,\"hpPageChange\",\"hpPageChange\"]],{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}],[1,\"lottery-ticket-controller\",{\"endpoint\":[513],\"ticketId\":[514,\"ticket-id\"],\"ticketDescription\":[513,\"ticket-description\"],\"gameId\":[513,\"game-id\"],\"postMessage\":[516,\"post-message\"],\"eventName\":[513,\"event-name\"],\"collapsed\":[516],\"numberOfGrids\":[514,\"number-of-grids\"],\"last\":[516],\"language\":[513],\"autoPick\":[516,\"auto-pick\"],\"resetButton\":[516,\"reset-button\"],\"totalControllers\":[514,\"total-controllers\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"translationUrl\":[520,\"translation-url\"]},[[0,\"helperAccordionAction\",\"helperAccordionActionHandler\"]],{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}],[1,\"lottery-game-details\",{\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"lowNumber\":[514,\"low-number\"],\"highNumber\":[514,\"high-number\"],\"minimumAllowed\":[514,\"minimum-allowed\"],\"maxinumAllowed\":[514,\"maxinum-allowed\"],\"language\":[513],\"translationUrl\":[520,\"translation-url\"]},null,{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}],[1,\"lottery-subscription\",{\"translationUrl\":[520,\"translation-url\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"endpoint\":[513],\"language\":[513],\"gameName\":[513,\"game-name\"],\"isSubscribed\":[32],\"frequenceList\":[32],\"frequenceState\":[32],\"filterData\":[32],\"subscriptionCode\":[32],\"conditionId\":[32],\"paramId\":[32],\"conditionRule\":[32],\"paramRule\":[32],\"peroidRule\":[32],\"startDateRule\":[32],\"endDateRule\":[32],\"gameNameRule\":[32],\"ruleType\":[32]},null,{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}],[1,\"helper-filters\",{\"activateTicketSearch\":[516,\"activate-ticket-search\"],\"gameId\":[513,\"game-id\"],\"playerId\":[513,\"player-id\"],\"session\":[513],\"postMessage\":[516,\"post-message\"],\"language\":[513],\"quickFiltersActive\":[516,\"quick-filters-active\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrlContent\":[513,\"client-styling-url-content\"],\"translationUrl\":[520,\"translation-url\"],\"showFilterModal\":[32],\"showClearButton\":[32],\"filterData\":[32],\"filterDataReset\":[32],\"limitStylingAppends\":[32],\"ticketTypeList\":[32]},[[0,\"modalCloseEvent\",\"modalCloseEvent\"]]],[1,\"lottery-draw-results\",{\"endpoint\":[513],\"gameId\":[513,\"game-id\"],\"language\":[513],\"playerId\":[513,\"player-id\"],\"drawMode\":[516,\"draw-mode\"],\"drawId\":[513,\"draw-id\"],\"gameName\":[513,\"game-name\"],\"ticketDate\":[513,\"ticket-date\"],\"ticketStatus\":[513,\"ticket-status\"],\"ticketId\":[513,\"ticket-id\"],\"ticketType\":[513,\"ticket-type\"],\"ticketAmount\":[513,\"ticket-amount\"],\"ticketCurrency\":[513,\"ticket-currency\"],\"ticketMultiplier\":[516,\"ticket-multiplier\"],\"ticketMultiplierNum\":[514,\"ticket-multiplier-num\"],\"ticketDrawCount\":[514,\"ticket-draw-count\"],\"ticketNumbers\":[513,\"ticket-numbers\"],\"sessionId\":[513,\"session-id\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"ticketDrawData\":[513,\"ticket-draw-data\"],\"historyDrawData\":[513,\"history-draw-data\"],\"tabValue\":[513,\"tab-value\"],\"translationUrl\":[520,\"translation-url\"],\"multiplier\":[32],\"isLoading\":[32],\"hasErrors\":[32],\"errorText\":[32],\"ticketData\":[32],\"ticketDataLoaded\":[32],\"ticketDraws\":[32],\"toggleDrawer\":[32],\"drawData\":[32],\"resultMap\":[32]},null,{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}],[1,\"lottery-ticket\",{\"endpoint\":[513],\"gameId\":[513,\"game-id\"],\"numberOfGrids\":[514,\"number-of-grids\"],\"multipleDraws\":[516,\"multiple-draws\"],\"ticketId\":[514,\"ticket-id\"],\"resetButton\":[516,\"reset-button\"],\"autoPick\":[516,\"auto-pick\"],\"language\":[513],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"translationUrl\":[520,\"translation-url\"],\"isLoading\":[32],\"hasErrors\":[32],\"ticketDone\":[32],\"isCustomSelect\":[32],\"amountInfo\":[32],\"stakeMultiplier\":[32],\"lineMultiplier\":[32],\"isCustomSelectStake\":[32],\"isCustomSelectDraw\":[32],\"isCustomSelectLine\":[32],\"drawMultiplier\":[32],\"secondarySelectionAllowed\":[32],\"partialQuickpickAvailable\":[32],\"boardsAllowed\":[32],\"tabIndex\":[32],\"groupType\":[32],\"playType\":[32],\"selectedPlayTypeId\":[32],\"maximumAllowed\":[32],\"numberRange\":[32],\"secondaryNumberRange\":[32],\"secondaryMaximumAllowed\":[32],\"minimumAllowed\":[32],\"secondaryMinimumAllowed\":[32],\"quickPicks\":[32]},[[8,\"click\",\"checkForClickOutside\"],[0,\"gridFilled\",\"gridFilledHandler\"],[0,\"gridClearAllEvent\",\"handleGridClearAllEvent\"],[4,\"resetAllTicketSelection\",\"toggleResetAllSeletion\"]],{\"lineMultiplier\":[\"handleLineMultiplierChange\"],\"tabIndex\":[\"handleTabIndexChange\"],\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}],[1,\"helper-tabs\",{\"disabled\":[516],\"label\":[513],\"selected\":[516],\"cmsEndpoint\":[513,\"cms-endpoint\"],\"selectedIndex\":[1538,\"selected-index\"],\"tabs\":[16],\"clientStyling\":[513,\"client-styling\"],\"mbSource\":[1,\"mb-source\"],\"clientStylingurl\":[513,\"client-stylingurl\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"lowNumber\":[514,\"low-number\"],\"highNumber\":[514,\"high-number\"],\"minimumAllowed\":[514,\"minimum-allowed\"],\"maxinumAllowed\":[514,\"maxinum-allowed\"],\"language\":[513],\"translationUrl\":[520,\"translation-url\"]},null,{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingChangeURL\"]}],[1,\"lottery-pagination\",{\"nextPage\":[1540,\"next-page\"],\"prevPage\":[1540,\"prev-page\"],\"offset\":[1538],\"limit\":[1538],\"total\":[1538],\"language\":[1537],\"clientStyling\":[1537,\"client-styling\"],\"clientStylingUrl\":[1537,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"arrowsActive\":[1540,\"arrows-active\"],\"secondaryArrowsActive\":[1540,\"secondary-arrows-active\"],\"numberedNavActive\":[1540,\"numbered-nav-active\"],\"isReset\":[1540,\"is-reset\"],\"translationUrl\":[520,\"translation-url\"],\"offsetInt\":[32],\"lastPage\":[32],\"previousPage\":[32],\"limitInt\":[32],\"totalInt\":[32],\"pagesArray\":[32],\"endInt\":[32]},null,{\"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,\"helper-accordion\",{\"mbSource\":[513,\"mb-source\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"ticketHistoryFlag\":[516,\"ticket-history-flag\"],\"headerTitle\":[513,\"header-title\"],\"headerSubtitle\":[513,\"header-subtitle\"],\"description\":[513],\"footer\":[516],\"deleteTab\":[516,\"delete-tab\"],\"postMessage\":[516,\"post-message\"],\"eventName\":[513,\"event-name\"],\"collapsed\":[516],\"language\":[513],\"translationUrl\":[520,\"translation-url\"],\"showContent\":[32]},null,{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}],[1,\"helper-modal\",{\"titleModal\":[513,\"title-modal\"],\"visible\":[1540],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrlContent\":[513,\"client-styling-url-content\"],\"limitStylingAppends\":[32]}],[1,\"helper-tab\",{\"selectedIndex\":[514,\"selected-index\"],\"cmsEndpoint\":[513,\"cms-endpoint\"],\"mbSource\":[1,\"mb-source\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"lowNumber\":[514,\"low-number\"],\"highNumber\":[514,\"high-number\"],\"minimumAllowed\":[514,\"minimum-allowed\"],\"maxinumAllowed\":[514,\"maxinum-allowed\"],\"language\":[513],\"translationUrl\":[520,\"translation-url\"],\"tabContent\":[32]},null,{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingChangeURL\"]}],[1,\"lottery-grid\",{\"ticketId\":[514,\"ticket-id\"],\"totalNumbers\":[514,\"total-numbers\"],\"gameId\":[513,\"game-id\"],\"maximumAllowed\":[514,\"maximum-allowed\"],\"minimumAllowed\":[514,\"minimum-allowed\"],\"numberRange\":[513,\"number-range\"],\"selectable\":[516],\"selectedNumbers\":[513,\"selected-numbers\"],\"secondaryNumbers\":[513,\"secondary-numbers\"],\"displaySelected\":[516,\"display-selected\"],\"language\":[513],\"gridIndex\":[514,\"grid-index\"],\"gridType\":[513,\"grid-type\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"],\"highNumber\":[514,\"high-number\"],\"lowNumber\":[514,\"low-number\"],\"selectionType\":[513,\"selection-type\"],\"partialQuickpickAvailable\":[516,\"partial-quickpick-available\"],\"numbers\":[32],\"bonusNumbers\":[32]},[[0,\"lotteryBulletSelection\",\"lotteryBulletSelectionHandler\"],[4,\"resetSelection\",\"resetSelectionHandler\"],[4,\"autoSelection\",\"autoSelectionHandler\"]],{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}],[1,\"lottery-bullet\",{\"value\":[513],\"selectable\":[516],\"isSelected\":[516,\"is-selected\"],\"isBonus\":[516,\"is-bonus\"],\"clientStyling\":[513,\"client-styling\"],\"clientStylingUrl\":[513,\"client-styling-url\"],\"mbSource\":[513,\"mb-source\"]},null,{\"clientStyling\":[\"handleClientStylingChange\"],\"clientStylingUrl\":[\"handleClientStylingUrlChange\"],\"mbSource\":[\"handleMbSourceChange\"]}]]]]"), options);
|
|
23
23
|
});
|
|
24
24
|
|
|
25
25
|
exports.setNonce = index.setNonce;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { h } from "@stencil/core";
|
|
2
2
|
import { setClientStyling, setClientStylingURL, setStreamStyling } from "../../../../../../../../libs/common/src/styling/index";
|
|
3
3
|
import { getTranslations, translate } from "../../utils/locale.utils";
|
|
4
|
-
import { fetchRequest,
|
|
4
|
+
import { checkDrawAvailable, fetchRequest, formatCountdown, showNotification } from "../../utils/utils";
|
|
5
5
|
import "../../../../../helper-modal/dist/types/index";
|
|
6
6
|
import "../../../../../lottery-draw-results/dist/types/index";
|
|
7
7
|
import "../../../../../lottery-draw-results-history/dist/types/index";
|
|
@@ -9,7 +9,8 @@ import "../../../../../lottery-game-details/dist/types/index";
|
|
|
9
9
|
import "../../../../../lottery-subscription/dist/types/index";
|
|
10
10
|
import "../../../../../lottery-ticket-controller/dist/types/index";
|
|
11
11
|
import "../../../../../../../libs/vaadin-facade/index";
|
|
12
|
-
import { format } from "date-fns";
|
|
12
|
+
import { format, isBefore, parseISO } from "date-fns";
|
|
13
|
+
import { doSubmitTicket, TICKET_INVALID_TOKEN } from "../../utils/api";
|
|
13
14
|
export class LotteryGamePage {
|
|
14
15
|
constructor() {
|
|
15
16
|
this.quickPick = false;
|
|
@@ -44,10 +45,6 @@ export class LotteryGamePage {
|
|
|
44
45
|
this.hasErrors = false;
|
|
45
46
|
this.totalAmount = 0;
|
|
46
47
|
this.successVisible = false;
|
|
47
|
-
this.daysRemaining = undefined;
|
|
48
|
-
this.hoursRemaining = undefined;
|
|
49
|
-
this.minutesRemaining = undefined;
|
|
50
|
-
this.secondsRemaining = undefined;
|
|
51
48
|
this.nextDate = undefined;
|
|
52
49
|
this.isLoggedIn = false;
|
|
53
50
|
this.loginModalVisible = false;
|
|
@@ -63,6 +60,8 @@ export class LotteryGamePage {
|
|
|
63
60
|
this.subscriptionError = '';
|
|
64
61
|
this.isSubscribed = false;
|
|
65
62
|
this.isFetchingGame = false;
|
|
63
|
+
this.drawSubmitAvailable = false;
|
|
64
|
+
this.formattedTime = undefined;
|
|
66
65
|
}
|
|
67
66
|
handleClientStylingChange(newValue, oldValue) {
|
|
68
67
|
if (newValue != oldValue) {
|
|
@@ -121,23 +120,8 @@ export class LotteryGamePage {
|
|
|
121
120
|
setClientStylingURL(this.stylingContainer, this.clientStylingUrl);
|
|
122
121
|
}
|
|
123
122
|
}
|
|
124
|
-
countdownLogic(date) {
|
|
125
|
-
const setTime = () => {
|
|
126
|
-
this.daysRemaining = Math.floor((Date.parse(date) - new Date().getTime()) / (1000 * 60 * 60 * 24));
|
|
127
|
-
this.hoursRemaining = Math.floor((Date.parse(date) - new Date().getTime()) / (1000 * 60 * 60) - this.daysRemaining * 24);
|
|
128
|
-
this.minutesRemaining = Math.floor((Date.parse(date) - new Date().getTime()) / (1000 * 60) -
|
|
129
|
-
this.daysRemaining * 24 * 60 -
|
|
130
|
-
this.hoursRemaining * 60);
|
|
131
|
-
this.secondsRemaining = Math.floor((Date.parse(date) - new Date().getTime()) / 1000 -
|
|
132
|
-
this.daysRemaining * 24 * 60 * 60 -
|
|
133
|
-
this.hoursRemaining * 60 * 60 -
|
|
134
|
-
this.minutesRemaining * 60);
|
|
135
|
-
};
|
|
136
|
-
setTime();
|
|
137
|
-
this.interval = setInterval(setTime, 1000);
|
|
138
|
-
}
|
|
139
123
|
disconnectedCallback() {
|
|
140
|
-
clearInterval(this.interval);
|
|
124
|
+
this.interval && clearInterval(this.interval);
|
|
141
125
|
}
|
|
142
126
|
getGameDetails() {
|
|
143
127
|
let url = new URL(`${this.endpoint}/games/${this.gameId}`);
|
|
@@ -151,13 +135,32 @@ export class LotteryGamePage {
|
|
|
151
135
|
return res.json();
|
|
152
136
|
})
|
|
153
137
|
.then((data) => {
|
|
154
|
-
var _a, _b;
|
|
138
|
+
var _a, _b, _c, _d, _e;
|
|
155
139
|
this.gameData = data;
|
|
156
140
|
this.basicStake = this.gameData.rules.stakes.length ? Number(this.gameData.rules.stakes[0].value) : 0;
|
|
157
141
|
this.basicLine = ((_a = this.gameData.rules.betTypes) === null || _a === void 0 ? void 0 : _a.length) ? this.gameData.rules.betTypes[0].boardsAllowed[0] : 1;
|
|
158
142
|
this.basicBetType = this.gameData.rules.betTypes[0];
|
|
159
|
-
this.
|
|
160
|
-
|
|
143
|
+
if (this.gameData && checkDrawAvailable((_b = this.gameData) === null || _b === void 0 ? void 0 : _b.currentDraw)) {
|
|
144
|
+
this.nextDate = (_c = this.gameData.currentDraw) === null || _c === void 0 ? void 0 : _c.date;
|
|
145
|
+
const start = (_e = (_d = this.gameData) === null || _d === void 0 ? void 0 : _d.currentDraw) === null || _e === void 0 ? void 0 : _e.wagerStartTime;
|
|
146
|
+
const updateTime = () => {
|
|
147
|
+
var _a;
|
|
148
|
+
const now = new Date();
|
|
149
|
+
if (start && isBefore(now, parseISO(start))) {
|
|
150
|
+
this.drawSubmitAvailable = false;
|
|
151
|
+
this.formattedTime = { start: formatCountdown(start, now) };
|
|
152
|
+
}
|
|
153
|
+
else {
|
|
154
|
+
this.drawSubmitAvailable = true;
|
|
155
|
+
this.formattedTime = { nextIn: formatCountdown((_a = data === null || data === void 0 ? void 0 : data.currentDraw) === null || _a === void 0 ? void 0 : _a.date, now) };
|
|
156
|
+
}
|
|
157
|
+
if (this.formattedTime.nextIn === '0D 00H 00M 00S') {
|
|
158
|
+
clearInterval(this.interval);
|
|
159
|
+
}
|
|
160
|
+
};
|
|
161
|
+
updateTime();
|
|
162
|
+
this.interval = setInterval(updateTime, 1000);
|
|
163
|
+
}
|
|
161
164
|
this.secondarySelectionAllowed = this.gameData.rules.secondarySelectionAllowed === 'INPUT' ? true : false;
|
|
162
165
|
this.quickPick = this.gameData.rules.quickPickAvailable;
|
|
163
166
|
this.isSubscription = this.gameData.rules.wagerTypes && this.gameData.rules.wagerTypes.includes('Subscription');
|
|
@@ -394,6 +397,8 @@ export class LotteryGamePage {
|
|
|
394
397
|
return body;
|
|
395
398
|
}
|
|
396
399
|
handleSubmitTickets() {
|
|
400
|
+
if (!this.drawSubmitAvailable)
|
|
401
|
+
return;
|
|
397
402
|
if (this.isSubscription && this.isSubscribed) {
|
|
398
403
|
this.submitTickets();
|
|
399
404
|
this.submitSubscriptionTickets();
|
|
@@ -452,41 +457,20 @@ export class LotteryGamePage {
|
|
|
452
457
|
// @TODO Body TS type
|
|
453
458
|
const body = this.buildTicketParam();
|
|
454
459
|
if (body) {
|
|
455
|
-
const uuid = generateUUID();
|
|
456
|
-
// @TODO Options TS type
|
|
457
|
-
let options = {
|
|
458
|
-
method: 'POST',
|
|
459
|
-
headers: {
|
|
460
|
-
'Content-Type': 'application/json',
|
|
461
|
-
Accept: 'application/json',
|
|
462
|
-
Authorization: `Bearer ${this.sessionId}`,
|
|
463
|
-
'X-Idempotency-Key': uuid
|
|
464
|
-
},
|
|
465
|
-
body: JSON.stringify(body)
|
|
466
|
-
};
|
|
467
460
|
this.isLoading = true;
|
|
468
|
-
|
|
469
|
-
.then((res) => {
|
|
470
|
-
if (res.status > 300) {
|
|
471
|
-
this.apiError = res.statusText + '.';
|
|
472
|
-
this.showApiError = true;
|
|
473
|
-
setTimeout(() => {
|
|
474
|
-
this.showApiError = false;
|
|
475
|
-
}, 3000);
|
|
476
|
-
throw new Error(res.statusText);
|
|
477
|
-
}
|
|
478
|
-
return res.json();
|
|
479
|
-
})
|
|
461
|
+
doSubmitTicket({ body, sessionId: this.sessionId, url: url.href })
|
|
480
462
|
.then(() => {
|
|
481
|
-
// this.successVisible = true;
|
|
482
463
|
showNotification({ message: 'Ticket submitted successfully.', theme: 'success' });
|
|
483
464
|
this.resetAllTicketSelection.emit();
|
|
484
465
|
const event = new CustomEvent('resetAllTicketSelection', { bubbles: true, composed: true });
|
|
485
466
|
document.dispatchEvent(event);
|
|
486
467
|
})
|
|
487
|
-
.catch((
|
|
488
|
-
|
|
489
|
-
|
|
468
|
+
.catch((res) => {
|
|
469
|
+
if (res.message === TICKET_INVALID_TOKEN) {
|
|
470
|
+
showNotification({ message: TICKET_INVALID_TOKEN, theme: 'error' });
|
|
471
|
+
return;
|
|
472
|
+
}
|
|
473
|
+
showNotification({ message: translate('ticketFailed', this.language), theme: 'error' });
|
|
490
474
|
})
|
|
491
475
|
.finally(() => {
|
|
492
476
|
this.isLoading = false;
|
|
@@ -503,7 +487,7 @@ export class LotteryGamePage {
|
|
|
503
487
|
this.goToLobbyEvent.emit();
|
|
504
488
|
}
|
|
505
489
|
render() {
|
|
506
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v;
|
|
490
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y;
|
|
507
491
|
if (this.hasErrors) {
|
|
508
492
|
return (h("div", { class: "GamePage" }, h("div", { class: "Title" }, translate('error', this.language))));
|
|
509
493
|
}
|
|
@@ -514,14 +498,14 @@ export class LotteryGamePage {
|
|
|
514
498
|
'background-size': 'contain',
|
|
515
499
|
'background-repeat': 'no-repeat',
|
|
516
500
|
'background-position': 'center'
|
|
517
|
-
} }, h("div", { class: "BannerButtonsWrapper" }), h("div", { class: "Tabs" }, h("div", { class: 'TabButton' + (this.tabIndex == 0 ? ' Active' : ''), onClick: () => (this.tabIndex = 0) }, translate('buy', this.language)), h("div", { class: 'TabButton' + (this.tabIndex == 1 ? ' Active' : ''), onClick: () => (this.tabIndex = 1) }, translate('viewLatest', this.language)))), this.isFetchingGame ? (h("div", { class: "fetching" }, "Loading...")) : (h("div", { class: "GamePageWrap" }, this.nextDate ? (h("div", null, h("div", { class: "NextDrawWrapper" }, h("div", { class: "NextDraw" }, h("p", { class: "BannerText" }, translate('
|
|
501
|
+
} }, h("div", { class: "BannerButtonsWrapper" }), h("div", { class: "Tabs" }, h("div", { class: 'TabButton' + (this.tabIndex == 0 ? ' Active' : ''), onClick: () => (this.tabIndex = 0) }, translate('buy', this.language)), h("div", { class: 'TabButton' + (this.tabIndex == 1 ? ' Active' : ''), onClick: () => (this.tabIndex = 1) }, translate('viewLatest', this.language)))), this.isFetchingGame ? (h("div", { class: "fetching" }, "Loading...")) : (h("div", { class: "GamePageWrap" }, this.nextDate ? (h("div", null, h("div", { class: "NextDrawWrapper" }, h("div", { class: "NextDraw" }, ((_a = this.formattedTime) === null || _a === void 0 ? void 0 : _a.start) ? (h("p", { class: "BannerText" }, translate('startIn', this.language))) : (h("p", { class: "BannerText" }, translate('nextDrawIn', this.language))), h("div", { class: "BannerCountdown" }, ((_b = this.formattedTime) === null || _b === void 0 ? void 0 : _b.start) || ((_c = this.formattedTime) === null || _c === void 0 ? void 0 : _c.nextIn)))), this.tabIndex == 0 && (h("div", { class: "GamePageContentWrapper" }, h("div", { class: "GamePageContent" }, h("div", { class: "GameDetails" }, h("lottery-game-details", { "low-number": (_e = (_d = this.gameData.rules) === null || _d === void 0 ? void 0 : _d.boards[0]) === null || _e === void 0 ? void 0 : _e.lowNumber, "high-number": (_g = (_f = this.gameData.rules) === null || _f === void 0 ? void 0 : _f.boards[0]) === null || _g === void 0 ? void 0 : _g.highNumber, "minimum-allowed": (_j = (_h = this.gameData.rules) === null || _h === void 0 ? void 0 : _h.boards[0]) === null || _j === void 0 ? void 0 : _j.minimumAllowed, "maxinum-allowed": (_l = (_k = this.gameData.rules) === null || _k === void 0 ? void 0 : _k.boards[0]) === null || _l === void 0 ? void 0 : _l.maxinumAllowed, language: this.language, "client-styling": this.clientStyling, "client-styling-url": this.clientStylingUrl, "mb-source": this.mbSource, "translation-url": this.translationData })), h("div", { class: "TicketsWrapper" }, this.mainTickets.map((item) => {
|
|
518
502
|
var _a, _b;
|
|
519
503
|
return (h("lottery-ticket-controller", { endpoint: this.endpoint, "ticket-id": item.ticketId, "game-id": item.gameId, collapsed: false, last: true, language: this.language, "auto-pick": (_a = this.gameData.rules) === null || _a === void 0 ? void 0 : _a.quickPickAvailable, "reset-button": (_b = this.gameData.rules) === null || _b === void 0 ? void 0 : _b.quickPickAvailable, "total-controllers": this.mainTickets.length, "translation-url": this.translationData, "client-styling": this.clientStyling, "client-styling-url": this.clientStylingUrl, "mb-source": this.mbSource }));
|
|
520
|
-
})), h("div", { class: "OrderSummary" }, h("h3", { class: "OrderSummaryTitle" }, translate('orderSummaryTitle', this.language)), h("div", { class: "OrderTicketInfo" }, h("div", { class: "Ticket" }, translate('orderSummaryTickets', this.language), ": ", h("span", null, this.mainTickets.length)), h("div", null, h("span", null, this.thousandSeperator(((
|
|
521
|
-
? `${(
|
|
522
|
-
: `${(
|
|
523
|
-
? `${(
|
|
524
|
-
: `${(
|
|
504
|
+
})), h("div", { class: "OrderSummary" }, h("h3", { class: "OrderSummaryTitle" }, translate('orderSummaryTitle', this.language)), h("div", { class: "OrderTicketInfo" }, h("div", { class: "Ticket" }, translate('orderSummaryTickets', this.language), ": ", h("span", null, this.mainTickets.length)), h("div", null, h("span", null, this.thousandSeperator(((_o = (_m = this.mainTickets[0]) === null || _m === void 0 ? void 0 : _m.betType) === null || _o === void 0 ? void 0 : _o.combinations) * ((_p = this.mainTickets[0]) === null || _p === void 0 ? void 0 : _p.lineNum))), h("span", { class: "Multiplier" }, "x"), ((_q = this.gameData.rules) === null || _q === void 0 ? void 0 : _q.stakeMultiplierAvailable) && (h("span", null, h("span", null, ((_r = this.mainTickets[0]) === null || _r === void 0 ? void 0 : _r.multiplierNum) === 1
|
|
505
|
+
? `${(_s = this.mainTickets[0]) === null || _s === void 0 ? void 0 : _s.multiplierNum} Multiplier`
|
|
506
|
+
: `${(_t = this.mainTickets[0]) === null || _t === void 0 ? void 0 : _t.multiplierNum} Multipliers`), h("span", { class: "Multiplier" }, "x"))), h("span", null, `${(_u = this.mainTickets[0]) === null || _u === void 0 ? void 0 : _u.stake} EUR`), ((_v = this.gameData.rules) === null || _v === void 0 ? void 0 : _v.drawMultiplierAvailable) && (h("span", null, h("span", { class: "Multiplier" }, "x"), h("span", null, ((_w = this.mainTickets[0]) === null || _w === void 0 ? void 0 : _w.drawCount) === 1
|
|
507
|
+
? `${(_x = this.mainTickets[0]) === null || _x === void 0 ? void 0 : _x.drawCount} Draw`
|
|
508
|
+
: `${(_y = this.mainTickets[0]) === null || _y === void 0 ? void 0 : _y.drawCount} Draws`))))), h("hr", null), h("div", { class: "Total" }, translate('orderSummaryTotal', this.language), ":", ' ', h("span", null, this.thousandSeperator(this.totalAmount), " ", this.currency)), this.isSubscription && (h("div", { class: "SubscriptionWrapper" }, h("lottery-subscription", { endpoint: this.endpoint, language: this.language, "client-styling": this.clientStyling, "client-styling-url": this.clientStylingUrl, "mb-source": this.mbSource, gameName: this.gameData.name }))), h("div", { class: "ButtonWrapper" }, this.isLoggedIn && (h("div", null, !this.isLoading && (h("div", { class: "submitWrap" }, h("div", { class: { Button: true, ButtonDisabled: !this.drawSubmitAvailable }, onClick: () => this.handleSubmitTickets() }, translate('orderSummarySubmit', this.language)), this.showSubmitError && h("div", { class: "submitError" }, this.submitError), this.showApiError && h("div", { class: "submitError" }, this.apiError), this.showSubscriptionError && (h("div", { class: "submitError" }, this.subscriptionError)))), this.isLoading && (h("span", { class: "Button", style: { cursor: 'default' } }, translate('loading', this.language))))), !this.isLoggedIn && (h("div", null, h("span", { class: "Button", onClick: () => this.showLoginModal() }, translate('orderSummarySubmit', this.language)), h("helper-modal", { "title-modal": "Success", visible: this.loginModalVisible, "client-styling": this.clientStyling, "client-styling-url": this.clientStylingUrl, "mb-source": this.mbSource }, h("p", { class: "SubmitModalSuccess" }, translate('modalLogin', this.language)))))))))), this.tabIndex == 1 && (h("div", { class: "HistoryContentWrapper" }, h("lottery-draw-results-history", { endpoint: this.endpoint, "game-id": this.gameId, language: this.language, "translation-url": this.translationData, "client-styling": this.clientStyling, "client-styling-url": this.clientStylingUrl, "mb-source": this.mbSource }))))) : (h("div", { class: "noActiveDraw" }, translate('emptyText', this.language))))), h("helper-modal", { "title-modal": "Success", visible: this.successVisible, "client-styling": this.clientStyling, "client-styling-url": this.clientStylingUrl, "mb-source": this.mbSource }, h("p", { class: "SubmitModalSuccess" }, translate('submitSuccess', this.language)))));
|
|
525
509
|
}
|
|
526
510
|
static get is() { return "lottery-game-page"; }
|
|
527
511
|
static get encapsulation() { return "shadow"; }
|
|
@@ -723,10 +707,6 @@ export class LotteryGamePage {
|
|
|
723
707
|
"hasErrors": {},
|
|
724
708
|
"totalAmount": {},
|
|
725
709
|
"successVisible": {},
|
|
726
|
-
"daysRemaining": {},
|
|
727
|
-
"hoursRemaining": {},
|
|
728
|
-
"minutesRemaining": {},
|
|
729
|
-
"secondsRemaining": {},
|
|
730
710
|
"nextDate": {},
|
|
731
711
|
"isLoggedIn": {},
|
|
732
712
|
"loginModalVisible": {},
|
|
@@ -741,7 +721,9 @@ export class LotteryGamePage {
|
|
|
741
721
|
"showSubscriptionError": {},
|
|
742
722
|
"subscriptionError": {},
|
|
743
723
|
"isSubscribed": {},
|
|
744
|
-
"isFetchingGame": {}
|
|
724
|
+
"isFetchingGame": {},
|
|
725
|
+
"drawSubmitAvailable": {},
|
|
726
|
+
"formattedTime": {}
|
|
745
727
|
};
|
|
746
728
|
}
|
|
747
729
|
static get events() {
|
|
@@ -753,7 +735,7 @@ export class LotteryGamePage {
|
|
|
753
735
|
"composed": true,
|
|
754
736
|
"docs": {
|
|
755
737
|
"tags": [],
|
|
756
|
-
"text": ""
|
|
738
|
+
"text": "Event emitted when the back button is clicked"
|
|
757
739
|
},
|
|
758
740
|
"complexType": {
|
|
759
741
|
"original": "string",
|
|
@@ -768,7 +750,7 @@ export class LotteryGamePage {
|
|
|
768
750
|
"composed": true,
|
|
769
751
|
"docs": {
|
|
770
752
|
"tags": [],
|
|
771
|
-
"text": ""
|
|
753
|
+
"text": "Event emitted when the lobby button is clicked"
|
|
772
754
|
},
|
|
773
755
|
"complexType": {
|
|
774
756
|
"original": "string",
|
|
@@ -783,7 +765,7 @@ export class LotteryGamePage {
|
|
|
783
765
|
"composed": true,
|
|
784
766
|
"docs": {
|
|
785
767
|
"tags": [],
|
|
786
|
-
"text": ""
|
|
768
|
+
"text": "Event emitted to reset all ticket selections"
|
|
787
769
|
},
|
|
788
770
|
"complexType": {
|
|
789
771
|
"original": "void",
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export var DrawStatus;
|
|
2
|
+
(function (DrawStatus) {
|
|
3
|
+
DrawStatus["OPEN"] = "OPEN";
|
|
4
|
+
})(DrawStatus || (DrawStatus = {}));
|
|
5
|
+
export var TicketState;
|
|
6
|
+
(function (TicketState) {
|
|
7
|
+
TicketState["Settled"] = "Settled";
|
|
8
|
+
TicketState["Purchased"] = "Purchased";
|
|
9
|
+
TicketState["Canceled"] = "Canceled";
|
|
10
|
+
})(TicketState || (TicketState = {}));
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { TicketState } from "../models";
|
|
2
|
+
import { generateUUID } from "./utils";
|
|
3
|
+
export const TICKET_INVALID_TOKEN = 'TICKET_INVALID_TOKEN';
|
|
4
|
+
export const doSubmitTicket = ({ body, sessionId, url }) => {
|
|
5
|
+
const options = {
|
|
6
|
+
method: 'POST',
|
|
7
|
+
headers: {
|
|
8
|
+
'Content-Type': 'application/json',
|
|
9
|
+
Accept: 'application/json',
|
|
10
|
+
Authorization: `Bearer ${sessionId}`,
|
|
11
|
+
'X-Idempotency-Key': generateUUID()
|
|
12
|
+
},
|
|
13
|
+
body: JSON.stringify(body)
|
|
14
|
+
};
|
|
15
|
+
return fetch(url, options).then((res) => {
|
|
16
|
+
if (res.status === 401) {
|
|
17
|
+
throw new Error(TICKET_INVALID_TOKEN);
|
|
18
|
+
}
|
|
19
|
+
if (res.status > 300) {
|
|
20
|
+
throw new Error(res.statusText);
|
|
21
|
+
}
|
|
22
|
+
return res.json().then((data) => {
|
|
23
|
+
if (checkTicketDetailHasError(data.tickets))
|
|
24
|
+
throw new Error(res.statusText);
|
|
25
|
+
return data;
|
|
26
|
+
});
|
|
27
|
+
});
|
|
28
|
+
};
|
|
29
|
+
function checkTicketDetailHasError(tickets) {
|
|
30
|
+
if (!tickets || !tickets.length)
|
|
31
|
+
return true;
|
|
32
|
+
return tickets.some((i) => i.state !== TicketState.Purchased);
|
|
33
|
+
}
|
|
@@ -5,10 +5,12 @@ const TRANSLATIONS = {
|
|
|
5
5
|
error: 'Error',
|
|
6
6
|
backButton: 'Back',
|
|
7
7
|
lobbyButton: 'Lobby',
|
|
8
|
-
|
|
8
|
+
nextDrawIn: 'Next draw in: ',
|
|
9
|
+
startIn: 'Sales Start in:',
|
|
9
10
|
buy: 'Buy tickets',
|
|
10
11
|
viewLatest: 'View latest results',
|
|
11
12
|
submitSuccess: 'Submit successfully!',
|
|
13
|
+
ticketFailed: 'Failed to submit tickets.',
|
|
12
14
|
orderSummaryTitle: 'Order Summary',
|
|
13
15
|
orderSummaryTickets: 'Ticket',
|
|
14
16
|
orderSummaryTotal: 'Total',
|
|
@@ -21,7 +23,7 @@ const TRANSLATIONS = {
|
|
|
21
23
|
error: 'Eroare',
|
|
22
24
|
backButton: 'Inapoi',
|
|
23
25
|
lobbyButton: 'Lobby',
|
|
24
|
-
|
|
26
|
+
nextDrawIn: 'Urmatoarea extragere:',
|
|
25
27
|
buy: 'Cumpara bilet',
|
|
26
28
|
viewLatest: 'Ultimile extrageri',
|
|
27
29
|
submitSuccess: 'Submit successfully!',
|
|
@@ -36,7 +38,7 @@ const TRANSLATIONS = {
|
|
|
36
38
|
error: 'Error',
|
|
37
39
|
backButton: 'Back',
|
|
38
40
|
lobbyButton: 'Lobby',
|
|
39
|
-
|
|
41
|
+
nextDrawIn: 'Next draw in: ',
|
|
40
42
|
buy: 'Buy tickets',
|
|
41
43
|
viewLatest: 'View latest results',
|
|
42
44
|
submitSuccess: 'Submit successfully!',
|
|
@@ -51,7 +53,7 @@ const TRANSLATIONS = {
|
|
|
51
53
|
error: 'خطأ',
|
|
52
54
|
backButton: 'خلف',
|
|
53
55
|
lobbyButton: 'ردهة',
|
|
54
|
-
|
|
56
|
+
nextDrawIn: 'السحب التالي:',
|
|
55
57
|
buy: 'اشتري تذاكر',
|
|
56
58
|
viewLatest: 'عرض أحدث النتائج',
|
|
57
59
|
submitSuccess: 'Submit successfully!',
|
|
@@ -66,7 +68,7 @@ const TRANSLATIONS = {
|
|
|
66
68
|
error: 'Greška',
|
|
67
69
|
backButton: 'Nazad',
|
|
68
70
|
lobbyButton: 'Lobby',
|
|
69
|
-
|
|
71
|
+
nextDrawIn: 'Sljedeće izvlačenje za: ',
|
|
70
72
|
buy: 'Uplati listić',
|
|
71
73
|
viewLatest: 'Pogledajte najnovije rezultate',
|
|
72
74
|
submitSuccess: 'Submit successfully!',
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import { differenceInSeconds, parseISO } from "date-fns";
|
|
2
|
+
import { DrawStatus } from "../models";
|
|
1
3
|
/**
|
|
2
4
|
* @name isMobile
|
|
3
5
|
* @description A method that returns if the browser used to access the app is from a mobile device or not
|
|
@@ -45,3 +47,27 @@ export const showNotification = ({ message, theme = 'success' }) => {
|
|
|
45
47
|
theme
|
|
46
48
|
});
|
|
47
49
|
};
|
|
50
|
+
export function checkDrawAvailable(currentDraw = {}) {
|
|
51
|
+
if (currentDraw && currentDraw.id && currentDraw.status === DrawStatus.OPEN) {
|
|
52
|
+
return true;
|
|
53
|
+
}
|
|
54
|
+
return false;
|
|
55
|
+
}
|
|
56
|
+
export function formatCountdown(stopTime, _now) {
|
|
57
|
+
if (!stopTime)
|
|
58
|
+
return;
|
|
59
|
+
const endTime = typeof stopTime === 'string' ? parseISO(stopTime) : stopTime;
|
|
60
|
+
const now = _now && new Date();
|
|
61
|
+
let totalSeconds = differenceInSeconds(endTime, now);
|
|
62
|
+
if (totalSeconds < 0)
|
|
63
|
+
return '0D 00H 00M 00S';
|
|
64
|
+
const days = Math.floor(totalSeconds / 86400);
|
|
65
|
+
totalSeconds %= 86400;
|
|
66
|
+
const hours = Math.floor(totalSeconds / 3600);
|
|
67
|
+
totalSeconds %= 3600;
|
|
68
|
+
const minutes = Math.floor(totalSeconds / 60);
|
|
69
|
+
const seconds = totalSeconds % 60;
|
|
70
|
+
return `${days}D ${hours.toString().padStart(2, '0')}H ${minutes.toString().padStart(2, '0')}M ${seconds
|
|
71
|
+
.toString()
|
|
72
|
+
.padStart(2, '0')}S`;
|
|
73
|
+
}
|