@opexa/portal-components 0.0.99 → 0.0.100
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/client/hooks/useAccountQuery.js +3 -3
- package/dist/client/hooks/useAuthenticateMutation.d.ts +1 -1
- package/dist/client/hooks/useAuthenticateMutation.js +3 -2
- package/dist/client/hooks/useAvailablePromosQuery.d.ts +1 -1
- package/dist/client/hooks/useAvailablePromosQuery.js +3 -3
- package/dist/client/hooks/useAvailableQuestsCountQuery.js +3 -3
- package/dist/client/hooks/useAvailableQuestsQuery.js +3 -3
- package/dist/client/hooks/useBetRecordsQuery.d.ts +1 -1
- package/dist/client/hooks/useBetRecordsQuery.js +3 -3
- package/dist/client/hooks/useBonusQuery.js +3 -3
- package/dist/client/hooks/useBonusesCountQuery.js +3 -3
- package/dist/client/hooks/useBonusesQuery.js +3 -3
- package/dist/client/hooks/useCashbackBonusQuery.js +3 -3
- package/dist/client/hooks/useCashbackBonusesCountQuery.js +3 -3
- package/dist/client/hooks/useCashbackBonusesQuery.js +3 -3
- package/dist/client/hooks/useCashbackQuery.js +2 -2
- package/dist/client/hooks/useCashbacksQuery.js +2 -2
- package/dist/client/hooks/useCheckInDailyCheckInQuestMutation.js +3 -3
- package/dist/client/hooks/useClaimCashbackBonusMutation.js +4 -3
- package/dist/client/hooks/useClaimSpotBonusMutation.js +4 -3
- package/dist/client/hooks/useCreateGCashDepositMutation.d.ts +1 -1
- package/dist/client/hooks/useCreateGCashDepositMutation.js +5 -3
- package/dist/client/hooks/useCreateGCashWithdrawalMutation.d.ts +1 -1
- package/dist/client/hooks/useCreateGCashWithdrawalMutation.js +3 -3
- package/dist/client/hooks/useCreateGameSessionMutation.js +5 -3
- package/dist/client/hooks/useCreateInstapayWithdrawalMutation.d.ts +1 -1
- package/dist/client/hooks/useCreateInstapayWithdrawalMutation.js +3 -3
- package/dist/client/hooks/useCreateMayaAppDepositMutation.d.ts +1 -1
- package/dist/client/hooks/useCreateMayaAppDepositMutation.js +5 -3
- package/dist/client/hooks/useCreateMayaAppWithdrawalMutation.d.ts +1 -1
- package/dist/client/hooks/useCreateMayaAppWithdrawalMutation.js +3 -3
- package/dist/client/hooks/useCreateMayaDepositMutation.d.ts +1 -1
- package/dist/client/hooks/useCreateMayaDepositMutation.js +5 -3
- package/dist/client/hooks/useCreateMayaWithdrawalMutation.d.ts +1 -1
- package/dist/client/hooks/useCreateMayaWithdrawalMutation.js +3 -3
- package/dist/client/hooks/useCreateOnlineBankDepositMutation.d.ts +1 -1
- package/dist/client/hooks/useCreateOnlineBankDepositMutation.js +5 -3
- package/dist/client/hooks/useCreateQRPHDepositMutation.d.ts +1 -1
- package/dist/client/hooks/useCreateQRPHDepositMutation.js +5 -3
- package/dist/client/hooks/useDepositQuery.js +3 -3
- package/dist/client/hooks/useDepositRecordsQuery.d.ts +1 -1
- package/dist/client/hooks/useDepositRecordsQuery.js +3 -3
- package/dist/client/hooks/useDepositsCountQuery.js +3 -3
- package/dist/client/hooks/useEndGameSessionMutation.js +4 -3
- package/dist/client/hooks/useFavoriteGamesQuery.js +3 -3
- package/dist/client/hooks/useGamesQuery.d.ts +1 -1
- package/dist/client/hooks/useGamesQuery.js +2 -2
- package/dist/client/hooks/useGlobalStore.d.ts +3 -0
- package/dist/client/hooks/useGlobalStore.js +41 -1
- package/dist/client/hooks/useInstapayBankListQuery.js +3 -3
- package/dist/client/hooks/useIsMayaSessionValidQuery.js +5 -5
- package/dist/client/hooks/useJackpotPayoutsQuery.d.ts +1 -1
- package/dist/client/hooks/useJackpotPayoutsQuery.js +2 -2
- package/dist/client/hooks/useJackpotsCountQuery.d.ts +1 -1
- package/dist/client/hooks/useJackpotsCountQuery.js +2 -2
- package/dist/client/hooks/useJackpotsQuery.d.ts +1 -1
- package/dist/client/hooks/useJackpotsQuery.js +2 -2
- package/dist/client/hooks/useLocaleInfo.d.ts +1 -1
- package/dist/client/hooks/useLocaleInfo.js +1 -1
- package/dist/client/hooks/useMarkGameAsFavoriteMutation.js +4 -3
- package/dist/client/hooks/useMarkMessageAsReadMutation.js +4 -3
- package/dist/client/hooks/useMemberVerificationQuery.js +3 -3
- package/dist/client/hooks/useMessagesQuery.d.ts +1 -1
- package/dist/client/hooks/useMessagesQuery.js +3 -3
- package/dist/client/hooks/usePaymentSettingsQuery.js +3 -3
- package/dist/client/hooks/usePlatformQuery.js +2 -2
- package/dist/client/hooks/useProfileCompletionQuery.js +3 -3
- package/dist/client/hooks/usePromoQuery.js +2 -2
- package/dist/client/hooks/usePromosQuery.js +2 -2
- package/dist/client/hooks/useSendVerificationCodeMutation.d.ts +1 -1
- package/dist/client/hooks/useSendVerificationCodeMutation.js +2 -2
- package/dist/client/hooks/useSessionQuery.js +4 -4
- package/dist/client/hooks/useSignInMutation.d.ts +1 -1
- package/dist/client/hooks/useSignInMutation.js +3 -2
- package/dist/client/hooks/useSignOutMutation.js +3 -2
- package/dist/client/hooks/useSignUpMutation.d.ts +1 -1
- package/dist/client/hooks/useSignUpMutation.js +2 -2
- package/dist/client/hooks/useTopWinsQuery.js +2 -2
- package/dist/client/hooks/useTournamentsCountQuery.d.ts +1 -1
- package/dist/client/hooks/useTournamentsCountQuery.js +2 -2
- package/dist/client/hooks/useTournamentsQuery.d.ts +1 -1
- package/dist/client/hooks/useTournamentsQuery.js +2 -2
- package/dist/client/hooks/useTransactionRecordsQuery.d.ts +1 -1
- package/dist/client/hooks/useTransactionRecordsQuery.js +3 -3
- package/dist/client/hooks/useUnmarkGameAsFavoriteMutation.js +4 -3
- package/dist/client/hooks/useUnreadMessagesCountQuery.d.ts +1 -1
- package/dist/client/hooks/useUnreadMessagesCountQuery.js +3 -3
- package/dist/client/hooks/useUpdateAccountMutation.d.ts +1 -1
- package/dist/client/hooks/useUpdateAccountMutation.js +4 -3
- package/dist/client/hooks/useWalletQuery.js +3 -3
- package/dist/client/hooks/useWithdrawalRecordsQuery.d.ts +1 -1
- package/dist/client/hooks/useWithdrawalRecordsQuery.js +3 -3
- package/dist/client/services/authenticate.d.ts +1 -1
- package/dist/client/services/signIn.d.ts +1 -1
- package/dist/client/utils/createRecipeContext.js +1 -1
- package/dist/client/utils/toaster.d.ts +1 -1
- package/dist/client/utils/toaster.js +1 -1
- package/dist/components/Account/Account.d.ts +3 -23
- package/dist/components/Account/Account.js +10 -115
- package/dist/components/Account/Account.lazy.d.ts +23 -0
- package/dist/components/Account/Account.lazy.js +138 -0
- package/dist/components/Account/AccountTrigger.js +2 -2
- package/dist/components/AccountInfo/AccountInfo.js +10 -4
- package/dist/components/AccountSecurity/AccountSecurity.js +13 -4
- package/dist/components/AccountVerification/AccountVerification.js +12 -3
- package/dist/components/Banner/Banner.d.ts +2 -2
- package/dist/components/Banner/Banner.js +2 -2
- package/dist/components/BetRecords/BetRecords.client.d.ts +7 -0
- package/dist/components/BetRecords/BetRecords.client.js +189 -0
- package/dist/components/BetRecords/BetRecords.d.ts +3 -7
- package/dist/components/BetRecords/BetRecords.js +8 -174
- package/dist/components/Bonus/Bonus.client.d.ts +9 -1
- package/dist/components/Bonus/Bonus.client.js +13 -4
- package/dist/components/Bonus/Bonus.d.ts +2 -9
- package/dist/components/Bonus/Bonus.js +22 -6
- package/dist/components/Bonuses/Bonuses.client.d.ts +9 -1
- package/dist/components/Bonuses/Bonuses.client.js +14 -4
- package/dist/components/Bonuses/Bonuses.d.ts +2 -9
- package/dist/components/Bonuses/Bonuses.js +3 -2
- package/dist/components/Bonuses/BonusesTrigger.js +7 -6
- package/dist/components/Cashback/Cashback.client.d.ts +6 -1
- package/dist/components/Cashback/Cashback.client.js +7 -3
- package/dist/components/Cashback/Cashback.d.ts +2 -6
- package/dist/components/Cashback/Cashback.js +11 -6
- package/dist/components/DepositWithdrawal/AmountChoices.js +5 -3
- package/dist/components/DepositWithdrawal/Deposit/AvailablePromos.js +5 -3
- package/dist/components/DepositWithdrawal/Deposit/Deposit.js +6 -3
- package/dist/components/DepositWithdrawal/Deposit/GCashDeposit/GCashDeposit.js +15 -4
- package/dist/components/DepositWithdrawal/Deposit/MayaAppDeposit/MayaAppDeposit.js +15 -4
- package/dist/components/DepositWithdrawal/Deposit/MayaDeposit/MayaDeposit.js +15 -4
- package/dist/components/DepositWithdrawal/Deposit/OnlineBankDeposit/OnlineBankDepositAlert.js +5 -2
- package/dist/components/DepositWithdrawal/Deposit/OnlineBankDeposit/OnlineBankDepositContext.d.ts +2 -2
- package/dist/components/DepositWithdrawal/Deposit/OnlineBankDeposit/OnlineBankDepositContext.js +1 -1
- package/dist/components/DepositWithdrawal/Deposit/OnlineBankDeposit/OnlineBankDepositDetails.js +5 -2
- package/dist/components/DepositWithdrawal/Deposit/OnlineBankDeposit/OnlineBankDepositForm.js +10 -4
- package/dist/components/DepositWithdrawal/Deposit/OnlineBankDeposit/useOnlineBankDeposit.d.ts +1 -1
- package/dist/components/DepositWithdrawal/Deposit/OnlineBankDeposit/useOnlineBankDeposit.js +2 -1
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit/QRPHDepositAlert.js +5 -2
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit/QRPHDepositContext.d.ts +2 -2
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit/QRPHDepositContext.js +1 -1
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit/QRPHDepositDetails.js +4 -2
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit/QRPHDepositForm.js +10 -4
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit/useQRPHDeposit.d.ts +1 -1
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit/useQRPHDeposit.js +2 -1
- package/dist/components/DepositWithdrawal/DepositWithdrawal.d.ts +1 -1
- package/dist/components/DepositWithdrawal/DepositWithdrawal.js +10 -27
- package/dist/components/DepositWithdrawal/DepositWithdrawal.lazy.d.ts +1 -0
- package/dist/components/DepositWithdrawal/DepositWithdrawal.lazy.js +36 -0
- package/dist/components/DepositWithdrawal/DepositWithdrawalTrigger.js +5 -2
- package/dist/components/DepositWithdrawal/PaymentMethods.js +4 -3
- package/dist/components/DepositWithdrawal/Withdrawal/GCashWithdrawal/GCashWithdrawal.js +17 -4
- package/dist/components/DepositWithdrawal/Withdrawal/InstapayWithdrawal/InstapayWithdrawal.js +18 -4
- package/dist/components/DepositWithdrawal/Withdrawal/MayaAppWithdrawal/MayaAppWithdrawal.js +15 -4
- package/dist/components/DepositWithdrawal/Withdrawal/MayaWithdrawal/MayaWithdrawal.js +17 -4
- package/dist/components/DepositWithdrawal/Withdrawal/Withdrawal.js +11 -4
- package/dist/components/Disclaimer/DisclaimerV1.js +2 -1
- package/dist/components/Disclaimer/DisclaimerV2.js +2 -1
- package/dist/components/Disclaimer/ResponsibleGaming.js +2 -1
- package/dist/components/Disclaimer/TermsOfUse.js +3 -2
- package/dist/components/Empty.d.ts +1 -2
- package/dist/components/FavoriteGames/FavoriteGames.client.d.ts +5 -1
- package/dist/components/FavoriteGames/FavoriteGames.client.js +8 -4
- package/dist/components/FavoriteGames/FavoriteGames.d.ts +2 -5
- package/dist/components/FavoriteGames/FavoriteGames.js +2 -2
- package/dist/components/GameLaunch/GameLaunch.d.ts +1 -1
- package/dist/components/GameLaunch/GameLaunch.js +10 -71
- package/dist/components/GameLaunch/GameLaunch.lazy.d.ts +1 -0
- package/dist/components/GameLaunch/GameLaunch.lazy.js +90 -0
- package/dist/components/GameLaunch/GameLaunchTrigger.js +4 -2
- package/dist/components/GameProviders/GameProvidersCarousel.js +5 -3
- package/dist/components/GameProviders/GameProvidersList.js +4 -3
- package/dist/components/Games/Game.js +14 -5
- package/dist/components/Games/GamesCarousel.client.d.ts +24 -1
- package/dist/components/Games/GamesCarousel.client.js +7 -3
- package/dist/components/Games/GamesCarousel.d.ts +2 -23
- package/dist/components/Games/GamesCarousel.js +2 -2
- package/dist/components/Games/GamesContext.js +1 -1
- package/dist/components/Games/GamesList.client.d.ts +19 -1
- package/dist/components/Games/GamesList.client.js +6 -3
- package/dist/components/Games/GamesList.d.ts +2 -18
- package/dist/components/Games/GamesList.js +1 -1
- package/dist/components/GamesSearch/GamesSearch.d.ts +1 -1
- package/dist/components/GamesSearch/GamesSearch.js +10 -4
- package/dist/components/Jackpots/Jackpots.js +1 -1
- package/dist/components/Jackpots/JackpotsCarousel/JackpotsCarousel.js +6 -4
- package/dist/components/Jackpots/JackpotsCarousel/JackpotsCarouselContext.js +1 -1
- package/dist/components/Jackpots/JackpotsCarousel/JackpotsCarouselItem.js +9 -3
- package/dist/components/Jackpots/JackpotsList/JackpotsList.js +2 -2
- package/dist/components/Jackpots/JackpotsList/JackpotsListContext.js +1 -1
- package/dist/components/Jackpots/JackpotsList/JackpotsListItemDesktop.js +8 -2
- package/dist/components/Jackpots/JackpotsList/JackpotsListItemGameProviders.js +3 -2
- package/dist/components/Jackpots/JackpotsList/JackpotsListItemMobile.js +12 -3
- package/dist/components/Jackpots/JackpotsList/JackpotsListItemRules.js +2 -2
- package/dist/components/Jackpots/JackpotsList/useJackpotsListItemData.d.ts +1 -1
- package/dist/components/Jackpots/JackpotsList/useJackpotsListItemData.js +3 -2
- package/dist/components/KYC/Header.js +4 -2
- package/dist/components/KYC/Indicator.js +2 -2
- package/dist/components/KYC/KYC.d.ts +1 -1
- package/dist/components/KYC/KYC.js +10 -22
- package/dist/components/KYC/KYC.lazy.d.ts +1 -0
- package/dist/components/KYC/KYC.lazy.js +26 -0
- package/dist/components/KYC/KYCContext.js +1 -1
- package/dist/components/KYC/KYCTrigger.js +1 -1
- package/dist/components/KYC/Step1.js +3 -2
- package/dist/components/KYC/Step2.js +3 -2
- package/dist/components/KYC/Step3.js +4 -2
- package/dist/components/KYC/Step4.js +3 -2
- package/dist/components/Messages/Message.js +3 -1
- package/dist/components/Messages/MessageContext.js +1 -1
- package/dist/components/Messages/MessagePopup.js +3 -3
- package/dist/components/Messages/MessageTrigger.js +2 -1
- package/dist/components/Messages/Messages.d.ts +3 -13
- package/dist/components/Messages/Messages.js +10 -35
- package/dist/components/Messages/Messages.lazy.d.ts +13 -0
- package/dist/components/Messages/Messages.lazy.js +48 -0
- package/dist/components/Messages/MessagesTrigger.js +7 -4
- package/dist/components/Messages/utils.d.ts +1 -1
- package/dist/components/Messages/utils.js +1 -1
- package/dist/components/PortalProvider/PortalProvider.js +8 -5
- package/dist/components/PortalProvider/Providers.js +1 -1
- package/dist/components/PortalProvider/Snackbar.js +4 -3
- package/dist/components/Promo/Promo.client.d.ts +6 -1
- package/dist/components/Promo/Promo.client.js +7 -3
- package/dist/components/Promo/Promo.d.ts +2 -6
- package/dist/components/Promo/Promo.js +11 -6
- package/dist/components/Promos/Cashback.js +3 -2
- package/dist/components/Promos/Promo.js +3 -2
- package/dist/components/Promos/Promos.js +3 -2
- package/dist/components/Promos/PromosCarousel.js +7 -3
- package/dist/components/Promos/PromosGrid.js +2 -1
- package/dist/components/Protected/Protected.d.ts +1 -2
- package/dist/components/Protected/Protected.js +1 -1
- package/dist/components/Quests/DailyCheckInQuest/DailyCheckInQuest.js +10 -5
- package/dist/components/Quests/DailyCheckInQuest/DailyCheckInQuestModal.js +3 -2
- package/dist/components/Quests/Quests.client.d.ts +5 -1
- package/dist/components/Quests/Quests.client.js +2 -2
- package/dist/components/Quests/Quests.d.ts +2 -5
- package/dist/components/Quests/Quests.js +1 -1
- package/dist/components/Quests/WageringQuest/WageringQuest.js +3 -2
- package/dist/components/Quests/WageringQuest/WageringQuestModal.js +3 -2
- package/dist/components/Search/Search.d.ts +3 -21
- package/dist/components/Search/Search.js +10 -64
- package/dist/components/Search/Search.lazy.d.ts +20 -0
- package/dist/components/Search/Search.lazy.js +78 -0
- package/dist/components/Search/SearchTrigger.js +1 -1
- package/dist/components/SignIn/MobileNumberSignIn.js +16 -5
- package/dist/components/SignIn/NameAndPasswordSignIn.js +16 -7
- package/dist/components/SignIn/SignIn.d.ts +3 -7
- package/dist/components/SignIn/SignIn.js +10 -14
- package/dist/components/SignIn/SignIn.lazy.d.ts +7 -0
- package/dist/components/SignIn/SignIn.lazy.js +18 -0
- package/dist/components/SignIn/SignInContext.js +1 -1
- package/dist/components/SignIn/SignInMethod.js +1 -1
- package/dist/components/SignIn/SignInTrigger.js +1 -1
- package/dist/components/SignUp/SignUp.d.ts +3 -7
- package/dist/components/SignUp/SignUp.js +10 -12
- package/dist/components/SignUp/SignUp.lazy.d.ts +7 -0
- package/dist/components/SignUp/SignUp.lazy.js +16 -0
- package/dist/components/SignUp/SignUpForm.js +15 -5
- package/dist/components/SignUp/SignUpTrigger.js +1 -1
- package/dist/components/TopWins/TopWins.client.d.ts +5 -1
- package/dist/components/TopWins/TopWins.client.js +8 -3
- package/dist/components/TopWins/TopWins.d.ts +2 -5
- package/dist/components/TopWins/TopWins.js +1 -1
- package/dist/components/Tournaments/Tournaments.js +1 -1
- package/dist/components/Tournaments/TournamentsCarousel/TournamentsCarousel.js +6 -4
- package/dist/components/Tournaments/TournamentsCarousel/TournamentsCarouselContext.js +1 -1
- package/dist/components/Tournaments/TournamentsCarousel/TournamentsCarouselItem.js +8 -3
- package/dist/components/Tournaments/TournamentsList/TournamentsList.js +2 -2
- package/dist/components/Tournaments/TournamentsList/TournamentsListContext.js +1 -1
- package/dist/components/Tournaments/TournamentsList/TournamentsListItemDesktop.js +7 -2
- package/dist/components/Tournaments/TournamentsList/TournamentsListItemGameProviders.js +3 -2
- package/dist/components/Tournaments/TournamentsList/TournamentsListItemMobile.js +10 -3
- package/dist/components/Tournaments/TournamentsList/TournamentsListItemRules.js +3 -2
- package/dist/components/Tournaments/TournamentsList/useTournamentListItemData.d.ts +1 -1
- package/dist/components/Tournaments/TournamentsList/useTournamentListItemData.js +1 -1
- package/dist/components/TransactionRecords/DepositRecordsTable.js +12 -4
- package/dist/components/TransactionRecords/TableFilters.js +9 -4
- package/dist/components/TransactionRecords/TransactionRecords.d.ts +1 -1
- package/dist/components/TransactionRecords/TransactionRecords.js +7 -2
- package/dist/components/TransactionRecords/TransactionRecordsTable.js +11 -4
- package/dist/components/TransactionRecords/WithdrawalRecordsTable.js +12 -4
- package/dist/constants/endpoints.js +2 -2
- package/dist/handlers.js +1 -1
- package/dist/middleware.js +1 -1
- package/dist/server/services/authenticate.d.ts +1 -1
- package/dist/server/services/authenticate.js +1 -1
- package/dist/server/services/signIn.d.ts +1 -1
- package/dist/server/services/signIn.js +1 -1
- package/dist/server/services/signOut.js +1 -1
- package/dist/server/utils/prefetchAccountQuery.js +3 -2
- package/dist/server/utils/prefetchAvailablePromosQuery.d.ts +1 -1
- package/dist/server/utils/prefetchAvailablePromosQuery.js +3 -2
- package/dist/server/utils/prefetchAvailableQuestsCountQuery.js +3 -2
- package/dist/server/utils/prefetchAvailableQuestsQuery.js +3 -2
- package/dist/server/utils/prefetchBetRecordsQuery.d.ts +1 -1
- package/dist/server/utils/prefetchBetRecordsQuery.js +3 -2
- package/dist/server/utils/prefetchBonusQuery.js +3 -2
- package/dist/server/utils/prefetchBonusesCountQuery.js +3 -2
- package/dist/server/utils/prefetchBonusesQuery.js +3 -2
- package/dist/server/utils/prefetchCashbackBonusQuery.js +3 -2
- package/dist/server/utils/prefetchCashbackBonusesCountQuery.js +4 -3
- package/dist/server/utils/prefetchCashbackBonusesQuery.js +4 -3
- package/dist/server/utils/prefetchCashbackQuery.js +3 -2
- package/dist/server/utils/prefetchCashbacksQuery.js +3 -2
- package/dist/server/utils/prefetchDepositQuery.js +3 -2
- package/dist/server/utils/prefetchDepositRecordsQuery.d.ts +1 -1
- package/dist/server/utils/prefetchDepositRecordsQuery.js +3 -2
- package/dist/server/utils/prefetchDepositsCountQuery.js +3 -2
- package/dist/server/utils/prefetchFavoriteGamesQuery.js +4 -3
- package/dist/server/utils/prefetchGamesQuery.d.ts +1 -1
- package/dist/server/utils/prefetchGamesQuery.js +3 -2
- package/dist/server/utils/prefetchInstapayBankListQuery.js +3 -2
- package/dist/server/utils/prefetchIsMayaSessionValidQuery.js +3 -2
- package/dist/server/utils/prefetchJackpotsCountQuery.d.ts +1 -1
- package/dist/server/utils/prefetchJackpotsCountQuery.js +3 -2
- package/dist/server/utils/prefetchJackpotsQuery.d.ts +1 -1
- package/dist/server/utils/prefetchJackpotsQuery.js +3 -2
- package/dist/server/utils/prefetchMemberVerificationQuery.js +3 -2
- package/dist/server/utils/prefetchPaymentSettingsQuery.js +3 -2
- package/dist/server/utils/prefetchPlatformQuery.js +3 -2
- package/dist/server/utils/prefetchProfileCompletionQuery.js +3 -2
- package/dist/server/utils/prefetchPromoQuery.js +3 -2
- package/dist/server/utils/prefetchPromosQuery.js +3 -2
- package/dist/server/utils/prefetchSessionQuery.js +2 -1
- package/dist/server/utils/prefetchTopWinsQuery.js +3 -2
- package/dist/server/utils/prefetchTournamentsCountQuery.d.ts +1 -1
- package/dist/server/utils/prefetchTournamentsCountQuery.js +3 -2
- package/dist/server/utils/prefetchTournamentsQuery.d.ts +1 -1
- package/dist/server/utils/prefetchTournamentsQuery.js +3 -2
- package/dist/server/utils/prefetchTransactionRecordsQuery.d.ts +1 -1
- package/dist/server/utils/prefetchTransactionRecordsQuery.js +3 -2
- package/dist/server/utils/prefetchUnreadMessagesCountQuery.d.ts +1 -1
- package/dist/server/utils/prefetchUnreadMessagesCountQuery.js +3 -2
- package/dist/server/utils/prefetchWalletQuery.js +3 -2
- package/dist/server/utils/prefetchWithdrawalRecordsQuery.d.ts +1 -1
- package/dist/server/utils/prefetchWithdrawalRecordsQuery.js +3 -2
- package/dist/services/account.d.ts +341 -0
- package/dist/services/account.js +233 -0
- package/dist/services/auth.d.ts +80 -0
- package/dist/services/auth.js +152 -0
- package/dist/services/cmsPortal.d.ts +43 -0
- package/dist/services/cmsPortal.js +148 -0
- package/dist/services/file.d.ts +33 -0
- package/dist/services/file.js +18 -0
- package/dist/services/game.d.ts +44 -0
- package/dist/services/game.js +33 -0
- package/dist/services/portal.d.ts +37 -0
- package/dist/services/portal.js +44 -0
- package/dist/services/report.d.ts +223 -0
- package/dist/services/report.js +72 -0
- package/dist/services/trigger.d.ts +94 -0
- package/dist/services/trigger.js +88 -0
- package/dist/services/wallet.d.ts +475 -0
- package/dist/services/wallet.js +365 -0
- package/dist/ui/AlertDialog/AlertDialog.d.ts +154 -154
- package/dist/ui/AlertDialog/AlertDialog.js +1 -1
- package/dist/ui/AlertDialog/alertDialog.recipe.d.ts +14 -14
- package/dist/ui/AlertDialog/alertDialog.recipe.js +1 -1
- package/dist/ui/Avatar/Avatar.js +1 -1
- package/dist/ui/Avatar/avatar.recipe.js +1 -1
- package/dist/ui/Badge/Badge.d.ts +12 -12
- package/dist/ui/Badge/Badge.js +1 -1
- package/dist/ui/Badge/badge.recipe.d.ts +3 -3
- package/dist/ui/Badge/badge.recipe.js +1 -1
- package/dist/ui/Button/Button.js +2 -1
- package/dist/ui/Checkbox/Checkbox.d.ts +23 -23
- package/dist/ui/Checkbox/Checkbox.js +1 -1
- package/dist/ui/Checkbox/checkbox.recipe.d.ts +3 -3
- package/dist/ui/Checkbox/checkbox.recipe.js +1 -1
- package/dist/ui/Clipboard/Clipboard.d.ts +18 -18
- package/dist/ui/Clipboard/Clipboard.js +1 -1
- package/dist/ui/Clipboard/clipboard.recipe.d.ts +3 -3
- package/dist/ui/Clipboard/clipboard.recipe.js +1 -1
- package/dist/ui/Collapsible/Collapsible.d.ts +32 -32
- package/dist/ui/Collapsible/Collapsible.js +1 -1
- package/dist/ui/Collapsible/collapsible.recipe.d.ts +8 -8
- package/dist/ui/Collapsible/collapsible.recipe.js +1 -1
- package/dist/ui/Combobox/Combobox.d.ts +42 -42
- package/dist/ui/Combobox/Combobox.js +1 -1
- package/dist/ui/Combobox/combobox.recipe.d.ts +3 -3
- package/dist/ui/Combobox/combobox.recipe.js +1 -1
- package/dist/ui/DatePicker/DatePicker.d.ts +336 -336
- package/dist/ui/DatePicker/DatePicker.js +1 -1
- package/dist/ui/DatePicker/datePicker.recipe.d.ts +14 -14
- package/dist/ui/DatePicker/datePicker.recipe.js +1 -1
- package/dist/ui/Dialog/Dialog.d.ts +154 -154
- package/dist/ui/Dialog/Dialog.js +1 -1
- package/dist/ui/Dialog/dialog.recipe.d.ts +14 -14
- package/dist/ui/Dialog/dialog.recipe.js +1 -1
- package/dist/ui/Drawer/Drawer.d.ts +33 -33
- package/dist/ui/Drawer/Drawer.js +1 -1
- package/dist/ui/Drawer/drawer.recipe.d.ts +3 -3
- package/dist/ui/Drawer/drawer.recipe.js +1 -1
- package/dist/ui/Field/Field.d.ts +21 -21
- package/dist/ui/Field/Field.js +1 -1
- package/dist/ui/Field/field.recipe.d.ts +3 -3
- package/dist/ui/Field/field.recipe.js +1 -1
- package/dist/ui/IconButton/IconButton.js +2 -1
- package/dist/ui/NumberInput/NumberInput.js +1 -1
- package/dist/ui/NumberInput/numberInput.recipe.js +1 -1
- package/dist/ui/PasswordInput/PasswordInput.d.ts +18 -18
- package/dist/ui/PasswordInput/PasswordInput.js +1 -1
- package/dist/ui/PasswordInput/passwordInput.recipe.d.ts +3 -3
- package/dist/ui/PasswordInput/passwordInput.recipe.js +1 -1
- package/dist/ui/PinInput/PinInput.js +1 -1
- package/dist/ui/PinInput/pinInput.recipe.js +1 -1
- package/dist/ui/Popover/Popover.d.ts +121 -121
- package/dist/ui/Popover/Popover.js +1 -1
- package/dist/ui/Popover/popover.recipe.d.ts +11 -11
- package/dist/ui/Popover/popover.recipe.js +1 -1
- package/dist/ui/Presence.d.ts +1 -1
- package/dist/ui/Presence.js +1 -1
- package/dist/ui/Progress/Progress.d.ts +27 -27
- package/dist/ui/Progress/Progress.js +1 -1
- package/dist/ui/Progress/progress.recipe.d.ts +3 -3
- package/dist/ui/Progress/progress.recipe.js +1 -1
- package/dist/ui/SegmentGroup/SegmentGroup.d.ts +18 -18
- package/dist/ui/SegmentGroup/SegmentGroup.js +1 -1
- package/dist/ui/SegmentGroup/segmentGroup.recipe.d.ts +3 -3
- package/dist/ui/SegmentGroup/segmentGroup.recipe.js +1 -1
- package/dist/ui/Select/Select.d.ts +45 -45
- package/dist/ui/Select/Select.js +1 -1
- package/dist/ui/Select/select.recipe.d.ts +3 -3
- package/dist/ui/Select/select.recipe.js +1 -1
- package/dist/ui/Table/Table.d.ts +21 -21
- package/dist/ui/Table/Table.js +1 -1
- package/dist/ui/Table/table.recipe.d.ts +3 -3
- package/dist/ui/Table/table.recipe.js +1 -1
- package/dist/ui/Tabs/Tabs.d.ts +15 -15
- package/dist/ui/Tabs/Tabs.js +1 -1
- package/dist/ui/Tabs/tabs.recipe.d.ts +3 -3
- package/dist/ui/Tabs/tabs.recipe.js +1 -1
- package/dist/utils/getQueryClient.js +2 -2
- package/dist/utils/onMobileDevice.d.ts +5 -0
- package/dist/utils/onMobileDevice.js +9 -0
- package/dist/utils/queryKeys.d.ts +4 -1
- package/package.json +29 -30
- package/dist/client/hooks/index.d.ts +0 -70
- package/dist/client/hooks/index.js +0 -70
- package/dist/client/services/index.d.ts +0 -4
- package/dist/client/services/index.js +0 -4
- package/dist/client/utils/index.d.ts +0 -3
- package/dist/client/utils/index.js +0 -3
- package/dist/components/JackpotCounter/JackpotCounter.client.d.ts +0 -2
- package/dist/components/JackpotCounter/JackpotCounter.client.js +0 -66
- package/dist/components/JackpotCounter/JackpotCounter.d.ts +0 -17
- package/dist/components/JackpotCounter/JackpotCounter.js +0 -21
- package/dist/components/JackpotCounter/JackpotCounterItem.d.ts +0 -18
- package/dist/components/JackpotCounter/JackpotCounterItem.js +0 -109
- package/dist/components/JackpotCounter/JackpotCounterItem.module.css +0 -184
- package/dist/components/JackpotCounter/index.d.ts +0 -1
- package/dist/components/JackpotCounter/index.js +0 -1
- package/dist/components/Jackpots/JackpotDesktop.d.ts +0 -1
- package/dist/components/Jackpots/JackpotDesktop.js +0 -45
- package/dist/components/Jackpots/JackpotGameProviders.d.ts +0 -5
- package/dist/components/Jackpots/JackpotGameProviders.js +0 -41
- package/dist/components/Jackpots/JackpotMobile.d.ts +0 -1
- package/dist/components/Jackpots/JackpotMobile.js +0 -46
- package/dist/components/Jackpots/JackpotRules.d.ts +0 -5
- package/dist/components/Jackpots/JackpotRules.js +0 -11
- package/dist/components/Jackpots/Jackpots.client.d.ts +0 -2
- package/dist/components/Jackpots/Jackpots.client.js +0 -29
- package/dist/components/Jackpots/JackpotsContext.d.ts +0 -4
- package/dist/components/Jackpots/JackpotsContext.js +0 -3
- package/dist/components/Jackpots/useJackpotData.d.ts +0 -14
- package/dist/components/Jackpots/useJackpotData.js +0 -92
- package/dist/components/PortalProvider/WebVitals.d.ts +0 -1
- package/dist/components/PortalProvider/WebVitals.js +0 -8
- package/dist/components/TournamentCounter/TournamentCounter.client.d.ts +0 -2
- package/dist/components/TournamentCounter/TournamentCounter.client.js +0 -50
- package/dist/components/TournamentCounter/TournamentCounter.d.ts +0 -8
- package/dist/components/TournamentCounter/TournamentCounter.js +0 -21
- package/dist/components/TournamentCounter/TournamentCounterItem.d.ts +0 -8
- package/dist/components/TournamentCounter/TournamentCounterItem.js +0 -106
- package/dist/components/TournamentCounter/index.d.ts +0 -1
- package/dist/components/TournamentCounter/index.js +0 -1
- package/dist/components/Tournaments/TournamentDesktop.d.ts +0 -1
- package/dist/components/Tournaments/TournamentDesktop.js +0 -57
- package/dist/components/Tournaments/TournamentGameProviders.d.ts +0 -5
- package/dist/components/Tournaments/TournamentGameProviders.js +0 -38
- package/dist/components/Tournaments/TournamentMobile.d.ts +0 -1
- package/dist/components/Tournaments/TournamentMobile.js +0 -55
- package/dist/components/Tournaments/TournamentRules.d.ts +0 -5
- package/dist/components/Tournaments/TournamentRules.js +0 -11
- package/dist/components/Tournaments/Tournaments.client.d.ts +0 -2
- package/dist/components/Tournaments/Tournaments.client.js +0 -20
- package/dist/components/Tournaments/TournamentsContext.d.ts +0 -4
- package/dist/components/Tournaments/TournamentsContext.js +0 -3
- package/dist/components/Tournaments/useTournamentData.d.ts +0 -10
- package/dist/components/Tournaments/useTournamentData.js +0 -71
- package/dist/components/index.d.ts +0 -31
- package/dist/components/index.js +0 -31
- package/dist/icons/index.d.ts +0 -66
- package/dist/icons/index.js +0 -66
- package/dist/server/services/index.d.ts +0 -4
- package/dist/server/services/index.js +0 -4
- package/dist/server/utils/index.d.ts +0 -34
- package/dist/server/utils/index.js +0 -34
- package/dist/services/ObjectId.d.ts +0 -10
- package/dist/services/ObjectId.js +0 -72
- package/dist/services/index.d.ts +0 -13
- package/dist/services/index.js +0 -13
- package/dist/ui/index.d.ts +0 -26
- package/dist/ui/index.js +0 -26
- package/dist/utils/index.d.ts +0 -18
- package/dist/utils/index.js +0 -18
|
@@ -1,70 +0,0 @@
|
|
|
1
|
-
export * from './useAccountQuery.js';
|
|
2
|
-
export * from './useAuthenticateMutation.js';
|
|
3
|
-
export * from './useAvailablePromosQuery.js';
|
|
4
|
-
export * from './useAvailableQuestsCountQuery.js';
|
|
5
|
-
export * from './useAvailableQuestsQuery.js';
|
|
6
|
-
export * from './useBetRecordsQuery.js';
|
|
7
|
-
export * from './useBonusesCountQuery.js';
|
|
8
|
-
export * from './useBonusesQuery.js';
|
|
9
|
-
export * from './useBonusQuery.js';
|
|
10
|
-
export * from './useCashbackBonusesCountQuery.js';
|
|
11
|
-
export * from './useCashbackBonusesQuery.js';
|
|
12
|
-
export * from './useCashbackBonusQuery.js';
|
|
13
|
-
export * from './useCashbackQuery.js';
|
|
14
|
-
export * from './useCashbacksQuery.js';
|
|
15
|
-
export * from './useCheckInDailyCheckInQuestMutation.js';
|
|
16
|
-
export * from './useChunk.js';
|
|
17
|
-
export * from './useClaimCashbackBonusMutation.js';
|
|
18
|
-
export * from './useClaimSpotBonusMutation.js';
|
|
19
|
-
export * from './useControllableState.js';
|
|
20
|
-
export * from './useCooldown.js';
|
|
21
|
-
export * from './useCreateGameSessionMutation.js';
|
|
22
|
-
export * from './useCreateGCashDepositMutation.js';
|
|
23
|
-
export * from './useCreateGCashWithdrawalMutation.js';
|
|
24
|
-
export * from './useCreateInstapayWithdrawalMutation.js';
|
|
25
|
-
export * from './useCreateMayaAppDepositMutation.js';
|
|
26
|
-
export * from './useCreateMayaAppWithdrawalMutation.js';
|
|
27
|
-
export * from './useCreateMayaDepositMutation.js';
|
|
28
|
-
export * from './useCreateMayaWithdrawalMutation.js';
|
|
29
|
-
export * from './useCreateOnlineBankDepositMutation.js';
|
|
30
|
-
export * from './useCreateQRPHDepositMutation.js';
|
|
31
|
-
export * from './useDepositQuery.js';
|
|
32
|
-
export * from './useDepositRecordsQuery.js';
|
|
33
|
-
export * from './useDepositsCountQuery.js';
|
|
34
|
-
export * from './useDisclosure.js';
|
|
35
|
-
export * from './useEndGameSessionMutation.js';
|
|
36
|
-
export * from './useFavoriteGamesQuery.js';
|
|
37
|
-
export * from './useGamesQuery.js';
|
|
38
|
-
export * from './useGlobalStore.js';
|
|
39
|
-
export * from './useInfiniteQueryHelper.js';
|
|
40
|
-
export * from './useInstapayBankListQuery.js';
|
|
41
|
-
export * from './useIsMayaSessionValidQuery.js';
|
|
42
|
-
export * from './useJackpotsCountQuery.js';
|
|
43
|
-
export * from './useJackpotsQuery.js';
|
|
44
|
-
export * from './useLocaleInfo.js';
|
|
45
|
-
export * from './useMarkGameAsFavoriteMutation.js';
|
|
46
|
-
export * from './useMarkMessageAsReadMutation.js';
|
|
47
|
-
export * from './useMemberVerificationQuery.js';
|
|
48
|
-
export * from './useMessagesQuery.js';
|
|
49
|
-
export * from './useMobileNumberParser.js';
|
|
50
|
-
export * from './useOnMMA.js';
|
|
51
|
-
export * from './usePaymentSettingsQuery.js';
|
|
52
|
-
export * from './usePlatformQuery.js';
|
|
53
|
-
export * from './useProfileCompletionQuery.js';
|
|
54
|
-
export * from './usePromoQuery.js';
|
|
55
|
-
export * from './usePromosQuery.js';
|
|
56
|
-
export * from './useRemainingTime.js';
|
|
57
|
-
export * from './useSendVerificationCodeMutation.js';
|
|
58
|
-
export * from './useSessionQuery.js';
|
|
59
|
-
export * from './useSignInMutation.js';
|
|
60
|
-
export * from './useSignOutMutation.js';
|
|
61
|
-
export * from './useSignUpMutation.js';
|
|
62
|
-
export * from './useTopWinsQuery.js';
|
|
63
|
-
export * from './useTournamentsCountQuery.js';
|
|
64
|
-
export * from './useTournamentsQuery.js';
|
|
65
|
-
export * from './useTransactionRecordsQuery.js';
|
|
66
|
-
export * from './useUnmarkGameAsFavoriteMutation.js';
|
|
67
|
-
export * from './useUnreadMessagesCountQuery.js';
|
|
68
|
-
export * from './useUpdateAccountMutation.js';
|
|
69
|
-
export * from './useWalletQuery.js';
|
|
70
|
-
export * from './useWithdrawalRecordsQuery.js';
|
|
@@ -1,66 +0,0 @@
|
|
|
1
|
-
'use client';
|
|
2
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
3
|
-
import useEmblaCarousel from 'embla-carousel-react';
|
|
4
|
-
import { isString } from 'lodash-es';
|
|
5
|
-
import Link from 'next/link';
|
|
6
|
-
import { useCallback, useEffect, useState } from 'react';
|
|
7
|
-
import { useJackpotsQuery } from '../../client/hooks/index.js';
|
|
8
|
-
import { ArrowLeftIcon, ArrowRightIcon, ChevronRightIcon } from '../../icons/index.js';
|
|
9
|
-
import { Button } from '../../ui/index.js';
|
|
10
|
-
import { JackpotCounterItem } from './JackpotCounterItem.js';
|
|
11
|
-
export function JackpotCounter__client(props) {
|
|
12
|
-
const [emblaRef, emblaApi] = useEmblaCarousel({
|
|
13
|
-
align: 'start',
|
|
14
|
-
slidesToScroll: 1,
|
|
15
|
-
});
|
|
16
|
-
const scrollPrev = useCallback(() => {
|
|
17
|
-
if (emblaApi)
|
|
18
|
-
emblaApi.scrollPrev();
|
|
19
|
-
}, [emblaApi]);
|
|
20
|
-
const scrollNext = useCallback(() => {
|
|
21
|
-
if (emblaApi)
|
|
22
|
-
emblaApi.scrollNext();
|
|
23
|
-
}, [emblaApi]);
|
|
24
|
-
const [canScrollPrev, setCanScrollPrev] = useState(false);
|
|
25
|
-
const [canScrollNext, setCanScrollNext] = useState(false);
|
|
26
|
-
const onSelect = useCallback(() => {
|
|
27
|
-
if (!emblaApi)
|
|
28
|
-
return;
|
|
29
|
-
setCanScrollPrev(emblaApi.canScrollPrev());
|
|
30
|
-
setCanScrollNext(emblaApi.canScrollNext());
|
|
31
|
-
}, [emblaApi]);
|
|
32
|
-
useEffect(() => {
|
|
33
|
-
if (!emblaApi)
|
|
34
|
-
return;
|
|
35
|
-
onSelect();
|
|
36
|
-
emblaApi.on('select', onSelect);
|
|
37
|
-
emblaApi.on('reInit', onSelect);
|
|
38
|
-
}, [emblaApi, onSelect]);
|
|
39
|
-
const jackpotsQuery = useJackpotsQuery({
|
|
40
|
-
first: 100,
|
|
41
|
-
filter: {
|
|
42
|
-
status: {
|
|
43
|
-
equal: 'ACTIVE',
|
|
44
|
-
},
|
|
45
|
-
deleted: {
|
|
46
|
-
equal: false,
|
|
47
|
-
},
|
|
48
|
-
},
|
|
49
|
-
sort: {
|
|
50
|
-
cursor: 'POOL',
|
|
51
|
-
order: 'DESC',
|
|
52
|
-
},
|
|
53
|
-
});
|
|
54
|
-
const jackpots = jackpotsQuery.data?.pages[0].edges.map((edge) => edge.node) ?? [];
|
|
55
|
-
if (jackpots.length <= 0)
|
|
56
|
-
return null;
|
|
57
|
-
const classNames = isString(props.className)
|
|
58
|
-
? { root: props.className }
|
|
59
|
-
: (props.className ?? {});
|
|
60
|
-
return (_jsxs("div", { className: classNames.root, children: [_jsxs("div", { className: "flex items-center justify-between", children: [_jsx("div", { className: "text-lg font-semibold", children: props.heading ?? 'Jackpots' }), _jsxs("div", { className: "flex items-center md:gap-3xl", children: [_jsxs(Link, { href: props.viewAllUrl ?? '/jackpots', className: "text-button-tertiary-fg flex gap-sm text-sm font-semibold", children: ["See All", _jsx(ChevronRightIcon, { className: "size-5 lg:hidden" })] }), _jsxs("div", { className: "hidden lg:flex", children: [_jsx(Button, { disabled: !canScrollPrev, onClick: scrollPrev, variant: "outline", colorScheme: "gray", className: "rounded-r-none border-r-0", "aria-label": "Previous", children: _jsx(ArrowLeftIcon, { className: "size-5" }) }), _jsxs(Button, { disabled: !canScrollNext, onClick: scrollNext, variant: "outline", colorScheme: "gray", className: "rounded-l-none", "aria-label": "Next", children: [_jsx("span", { className: "sr-only", children: "Next" }), _jsx(ArrowRightIcon, { className: "size-5" })] })] })] })] }), _jsx("div", { className: "relative mt-lg lg:overflow-hidden", ref: emblaRef, children: _jsx("div", { className: "flex gap-2.5", children: jackpots.map((jackpot) => (_jsx(JackpotCounterItem, { jackpot: jackpot, className: {
|
|
61
|
-
root: {
|
|
62
|
-
className: classNames.jackpotCounterItemRoot?.className,
|
|
63
|
-
style: classNames.jackpotCounterItemRoot?.style,
|
|
64
|
-
},
|
|
65
|
-
}, viewAllUrl: props.viewAllUrl, hideAnimation: props.hideAnimation }, jackpot.id))) }) })] }));
|
|
66
|
-
}
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import type { CSSProperties } from 'react';
|
|
2
|
-
export interface ClassNameEntries {
|
|
3
|
-
root?: string;
|
|
4
|
-
jackpotCounterItemRoot?: {
|
|
5
|
-
className?: string;
|
|
6
|
-
style?: CSSProperties;
|
|
7
|
-
};
|
|
8
|
-
}
|
|
9
|
-
export interface JackpotCounterProps {
|
|
10
|
-
/** @default "Promos" */
|
|
11
|
-
heading?: string;
|
|
12
|
-
/** @default "/jackpots" */
|
|
13
|
-
viewAllUrl?: string;
|
|
14
|
-
className?: string | ClassNameEntries;
|
|
15
|
-
hideAnimation?: boolean;
|
|
16
|
-
}
|
|
17
|
-
export declare function JackpotCounter(props: JackpotCounterProps): Promise<import("react/jsx-runtime").JSX.Element>;
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import { prefetchJackpotsQuery } from '../../server/utils/index.js';
|
|
3
|
-
import { JackpotCounter__client } from './JackpotCounter.client.js';
|
|
4
|
-
export async function JackpotCounter(props) {
|
|
5
|
-
await prefetchJackpotsQuery({
|
|
6
|
-
first: 100,
|
|
7
|
-
filter: {
|
|
8
|
-
status: {
|
|
9
|
-
equal: 'ACTIVE',
|
|
10
|
-
},
|
|
11
|
-
deleted: {
|
|
12
|
-
equal: false,
|
|
13
|
-
},
|
|
14
|
-
},
|
|
15
|
-
sort: {
|
|
16
|
-
cursor: 'POOL',
|
|
17
|
-
order: 'DESC',
|
|
18
|
-
},
|
|
19
|
-
});
|
|
20
|
-
return _jsx(JackpotCounter__client, { ...props });
|
|
21
|
-
}
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import { type CSSProperties } from 'react';
|
|
2
|
-
import type { Jackpot } from '../../types';
|
|
3
|
-
interface ClassNameEntries {
|
|
4
|
-
root?: {
|
|
5
|
-
className?: string;
|
|
6
|
-
style?: CSSProperties;
|
|
7
|
-
};
|
|
8
|
-
}
|
|
9
|
-
export interface JackpotCounterCardProps {
|
|
10
|
-
jackpot: Jackpot;
|
|
11
|
-
className?: string | ClassNameEntries;
|
|
12
|
-
style?: string;
|
|
13
|
-
/** @default "/jackpots" */
|
|
14
|
-
viewAllUrl?: string;
|
|
15
|
-
hideAnimation?: boolean;
|
|
16
|
-
}
|
|
17
|
-
export declare function JackpotCounterItem({ jackpot, className, viewAllUrl, hideAnimation, }: JackpotCounterCardProps): import("react/jsx-runtime").JSX.Element;
|
|
18
|
-
export {};
|
|
@@ -1,109 +0,0 @@
|
|
|
1
|
-
'use client';
|
|
2
|
-
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
3
|
-
import { Progress } from '@ark-ui/react';
|
|
4
|
-
import { isString } from 'lodash-es';
|
|
5
|
-
import Image from 'next/image';
|
|
6
|
-
import Link from 'next/link';
|
|
7
|
-
import { useCallback, useMemo } from 'react';
|
|
8
|
-
import { twMerge } from 'tailwind-merge';
|
|
9
|
-
import { useLocaleInfo } from '../../client/hooks/index.js';
|
|
10
|
-
import { useJackpotPayoutsQuery } from '../../client/hooks/useJackpotPayoutsQuery.js';
|
|
11
|
-
import { ArrowNarrowUpRightIcon, ChevronLeftIcon, ChevronRightIcon, Trophy01Icon, User01Icon, } from '../../icons/index.js';
|
|
12
|
-
import { StarIcon } from '../../icons/StarIcon.js';
|
|
13
|
-
import closeChest from '../../images/close-chest.png';
|
|
14
|
-
import firstPlace from '../../images/first-place.png';
|
|
15
|
-
import leaderboard from '../../images/leaderboard.png';
|
|
16
|
-
import openChest from '../../images/open-chest.png';
|
|
17
|
-
import { formatNumber, getPercentage, mask } from '../../utils/index.js';
|
|
18
|
-
import styles from './JackpotCounterItem.module.css';
|
|
19
|
-
export function JackpotCounterItem({ jackpot, className, viewAllUrl, hideAnimation = false, }) {
|
|
20
|
-
const jackpotPayoutsQuery = useJackpotPayoutsQuery({
|
|
21
|
-
first: 30,
|
|
22
|
-
filter: {
|
|
23
|
-
jackpot: {
|
|
24
|
-
equal: jackpot.id,
|
|
25
|
-
},
|
|
26
|
-
},
|
|
27
|
-
sort: {
|
|
28
|
-
cursor: 'AMOUNT',
|
|
29
|
-
order: 'DESC',
|
|
30
|
-
},
|
|
31
|
-
}, {
|
|
32
|
-
enabled: typeof window !== 'undefined',
|
|
33
|
-
});
|
|
34
|
-
const jackpotPayouts = jackpotPayoutsQuery.data?.pages[0].edges.map((edge) => edge.node) ?? [];
|
|
35
|
-
const topJackpotPayout = jackpotPayouts[0] ?? [];
|
|
36
|
-
const localeInfo = useLocaleInfo();
|
|
37
|
-
const isPayingOut = jackpot.drawing;
|
|
38
|
-
const jackpotAmount = isPayingOut
|
|
39
|
-
? jackpot.maximumJackpotPoolLimit
|
|
40
|
-
: jackpot.pool;
|
|
41
|
-
const Arrow = useCallback(({ index }) => {
|
|
42
|
-
const Icon = isPayingOut ? ChevronLeftIcon : ChevronRightIcon;
|
|
43
|
-
return (_jsx(Icon, { className: twMerge('scale-400 lg:scale-250 text-brand-300 min-w-2.5 lg:min-w-4', isPayingOut
|
|
44
|
-
? styles['animate-wave-color-error']
|
|
45
|
-
: styles['animate-wave-color-success']), style: {
|
|
46
|
-
animationDelay: isPayingOut
|
|
47
|
-
? `${(40 - index - 1) * 0.1}s`
|
|
48
|
-
: `${index * 0.1}s`,
|
|
49
|
-
} }));
|
|
50
|
-
}, [isPayingOut]);
|
|
51
|
-
const arrowImages = useMemo(() => Array.from({ length: 40 }, (_, i) => (_jsx(Arrow, { isFirst: i === 0, index: i }, i))), [Arrow]);
|
|
52
|
-
const classNames = isString(className)
|
|
53
|
-
? { root: { className } }
|
|
54
|
-
: (className ?? {});
|
|
55
|
-
return (_jsxs("div", { className: twMerge('bg-bg-tertiary border-border-primary relative flex w-full shrink-0 rounded-2xl border p-3 text-center lg:gap-4 lg:p-5', classNames.root?.className), style: classNames.root?.style, children: [_jsxs("div", { className: "z-1 relative flex flex-1 flex-col", children: [_jsx("div", { className: "flex h-full flex-col justify-between", children: _jsx("div", { className: "flex w-full justify-between", children: _jsxs("div", { className: "flex w-full flex-col", children: [_jsxs("div", { className: "relative flex w-full justify-between", children: [_jsxs("div", { children: [isPayingOut ? (_jsxs("div", { className: "border-utility-success-200 bg-utility-success-50 text-utility-success-700 flex w-fit items-center gap-1 rounded-full border px-2 py-0.5 text-xs font-medium", children: [_jsx("span", { className: "full bg-utility-success-500 size-1.5 animate-pulse rounded" }), "Paying Out"] })) : (_jsxs("div", { className: "border-utility-blue-200 bg-utility-blue-50 text-utility-blue-700 flex w-fit items-center gap-1 rounded-full border px-2 py-0.5 text-xs font-medium", children: [_jsx(ArrowNarrowUpRightIcon, { className: "text-utility-blue-500 size-3.5" }), "Accumulating"] })), _jsx("div", { className: "text-text-primary-900 mt-1 text-left text-lg font-medium lg:mt-5 lg:text-2xl", children: jackpot.name }), _jsx("div", { className: "bg-bg-primary text-brand-400 mt-1.5 w-fit rounded-md px-2 py-1 text-2xl font-bold lg:mt-2 lg:text-4xl", children: formatNumber(jackpotAmount, {
|
|
56
|
-
currency: localeInfo.currency.code,
|
|
57
|
-
minDecimalPlaces: 2,
|
|
58
|
-
maxDecimalPlaces: 2,
|
|
59
|
-
}) })] }), _jsx("div", { className: "z-1 bottom-[-60] right-0 lg:absolute", children: _jsx(Image, { width: 150, height: 150, src: isPayingOut ? openChest : closeChest, alt: "closeChest", quality: 100, className: "h-25 w-25 lg:h-37.5 lg:w-37.5 size-full p-2" }) })] }), topJackpotPayout.amount ? (_jsx("div", { children: _jsxs("div", { className: "bg-bg-primary relative mt-4 hidden w-full gap-4 rounded-lg p-4 lg:flex", children: [_jsxs("div", { className: "bg-bg-tertiary relative flex h-18 w-18 items-center justify-center rounded-full", children: [_jsx(User01Icon, { className: "text-text-quarterary-500 size-9" }), _jsx("div", { className: "bg-yellow-400 text-brand-950 border-bg-primary absolute bottom-0 right-0 flex h-6 w-6 items-center justify-center rounded-full border-[1.5px] text-xs font-bold", children: "1st" })] }), _jsxs("div", { className: "flex flex-col gap-1 text-left", children: [_jsxs("div", { className: "border-utility-brand-200 bg-utility-brand-50 text-utility-brand-700 flex h-fit w-fit items-center gap-1 rounded-sm border px-2 py-0.5 text-xs font-medium", children: [_jsx(Trophy01Icon, { className: "text-utility-brand-600 size-3.5" }), "Top Payout"] }), _jsx("div", { className: "font-semibold", children: topJackpotPayout.member.name }), _jsx("div", { className: "text-brand-400 text-2xl", children: formatNumber(topJackpotPayout.amount, {
|
|
60
|
-
currency: localeInfo.currency.code,
|
|
61
|
-
minDecimalPlaces: 2,
|
|
62
|
-
maxDecimalPlaces: 2,
|
|
63
|
-
}) })] })] }) })) : (_jsxs("div", { className: "bg-bg-primary relative mt-4 hidden w-full gap-4 rounded-lg p-4 lg:flex", children: [_jsx(Image, { width: 66, height: 87, src: firstPlace, alt: "firstPlace", className: "size-full h-auto w-[66px] mix-blend-luminosity" }), _jsxs("div", { className: "flex flex-col gap-1 text-left", children: [_jsxs("div", { className: "border-utility-brand-200 bg-utility-brand-50 text-utility-brand-700 flex h-fit w-fit items-center gap-1 rounded-sm border px-2 py-0.5 text-xs font-medium", children: [_jsx(Trophy01Icon, { className: "text-utility-brand-600 size-3.5" }), "Top Payout"] }), _jsx("div", { className: "font-semibold", children: "No winners yet" }), _jsx("div", { className: "text-text-secondary-700 text-xs", children: "You could be the first to win the tournament!" })] })] }))] }) }) }), _jsxs("div", { className: "mt-3 lg:mt-4", children: [_jsxs("div", { className: "mb-1 flex justify-between", children: [_jsx("div", { className: "text-text-primary-900 text-xs font-semibold", children: formatNumber(0, {
|
|
64
|
-
currency: localeInfo.currency.code,
|
|
65
|
-
compact: true,
|
|
66
|
-
}) }), _jsxs("div", { className: "relative flex items-center justify-end gap-1.5", children: [isPayingOut ? (_jsxs("div", { className: "flex w-6 items-center", children: [_jsx("div", { className: twMerge('absolute left-0', styles['animate-arrow-red-flash-1']), children: _jsx(ChevronLeftIcon, { className: "size-4.5" }) }), _jsx("div", { className: twMerge('absolute left-1.5', styles['animate-arrow-red-flash-2']), children: _jsx(ChevronLeftIcon, { className: "size-4.5" }) }), _jsx("div", { className: twMerge('absolute left-3', styles['animate-arrow-red-flash-3']), children: _jsx(ChevronLeftIcon, { className: "size-4.5" }) })] })) : (_jsxs("div", { className: "flex w-6 items-center", children: [_jsx("div", { className: twMerge('absolute left-0', styles['animate-arrow-green-flash-1']), children: _jsx(ChevronRightIcon, { className: "size-4.5" }) }), _jsx("div", { className: twMerge('absolute left-1.5', styles['animate-arrow-green-flash-2']), children: _jsx(ChevronRightIcon, { className: "size-4.5" }) }), _jsx("div", { className: twMerge('absolute left-3', styles['animate-arrow-green-flash-3']), children: _jsx(ChevronRightIcon, { className: "size-4.5" }) })] })), _jsx("div", { className: "text-text-primary-900 text-xs font-semibold", children: formatNumber(jackpot?.maximumJackpotPoolLimit, {
|
|
67
|
-
currency: localeInfo.currency.code,
|
|
68
|
-
compact: true,
|
|
69
|
-
}) })] })] }), _jsx(Progress.Root, { className: "bg-bg-primary h-2 w-full rounded-full lg:h-4", max: 100, value: getPercentage(jackpot.pool, jackpot.maximumJackpotPoolLimit), children: _jsx(Progress.Track, { className: "bg-bg-primary h-full overflow-hidden rounded-full", children: _jsx(Progress.Range, { className: "bg-brand-500 relative h-full overflow-hidden rounded-full pl-1.5", children: _jsx("div", { className: "pointer-events-none absolute inset-0 flex items-center justify-start pl-1.5", "aria-hidden": "true", children: arrowImages }) }) }) }), _jsx("div", { className: "mt-1 block text-start text-2xs lg:hidden", children: isPayingOut
|
|
70
|
-
? `The pot has hit ${formatNumber(jackpot?.maximumJackpotPoolLimit, {
|
|
71
|
-
currency: localeInfo.currency.code,
|
|
72
|
-
compact: true,
|
|
73
|
-
})} Play now for your chance to win big! 🔥`
|
|
74
|
-
: getAccumulatingJackpotDescription(Number(jackpot?.pool) ?? 0, Number(jackpot?.maximumJackpotPoolLimit) ?? 0) })] })] }), _jsxs("div", { className: "z-1 hidden flex-1 space-y-4 lg:block", children: [_jsxs("div", { className: "flex items-center justify-between", children: [_jsxs("div", { className: "flex gap-2", children: [_jsx(Image, { width: 24, height: 24, src: leaderboard, quality: 100, alt: "leaderboardIcon", className: "size-full h-auto w-6" }), _jsx("div", { className: "text-text-primary-900 text-lg font-semibold", children: jackpotPayouts.length ? 'Recent payouts' : 'Starting soon!' })] }), _jsxs(Link, { className: "text-button-tertiary-fg flex text-sm font-semibold", href: viewAllUrl ?? '/jackpots', children: ["See details", _jsx(ChevronRightIcon, { className: "size-5" })] })] }), _jsx("div", { className: twMerge('max-h-[272px] overflow-y-scroll', styles['scrollArea']), children: _jsx("div", { className: "border-gray-200 overflow-hidden rounded-xl", children: _jsxs("table", { className: "w-full", children: [_jsx("thead", { children: _jsxs("tr", { className: "bg-bg-secondary text-text-tertiary-600 h-8 text-xs font-medium", children: [_jsx("th", { children: "Player" }), _jsx("th", { children: "Multiplier" }), _jsx("th", { children: "Prize" })] }) }), _jsx("tbody", { children: jackpotPayouts.length ? (_jsx(_Fragment, { children: jackpotPayouts.map((jackpotPayout, i) => (_jsxs("tr", { className: "bg-bg-primary text-text-secondary-700 text-sm", children: [_jsx("td", { className: "border-border-secondary h-12 border-t-2", children: mask(jackpotPayout.member.name, {
|
|
75
|
-
totalCharsCount: 6,
|
|
76
|
-
}) }), _jsxs("td", { className: "border-border-secondary h-12 border-t-2", children: [jackpotPayout.multiplier, "x"] }), _jsx("td", { className: "border-border-secondary text-brand-400 h-12 border-t-2", children: formatNumber(jackpotPayout.amount, {
|
|
77
|
-
currency: localeInfo.currency.code,
|
|
78
|
-
minDecimalPlaces: 2,
|
|
79
|
-
maxDecimalPlaces: 2,
|
|
80
|
-
}) })] }, i))) })) : (_jsx(_Fragment, { children: Array.from({ length: 10 }).map((_, i) => (_jsxs("tr", { className: "bg-bg-primary text-text-secondary-700 text-sm", children: [_jsx("td", { className: "border-border-secondary h-12 w-[52px] border-t-2", children: i + 1 < 6 ? (_jsxs("div", { className: "relative", children: [_jsx(StarIcon, { className: twMerge('mx-auto size-6.5', starTierStyles[i].starColor) }), _jsx("span", { className: twMerge('absolute inset-0 mt-0.5 flex items-center justify-center text-2xs font-bold', starTierStyles[i].numberColor), children: i + 1 })] })) : (i + 1) }), _jsx("td", { className: "border-border-secondary h-12 border-t-2", children: "-" }), _jsx("td", { className: "border-border-secondary h-12 border-t-2", children: "-" }), _jsx("td", { className: "border-border-secondary h-12 border-t-2", children: "-" })] }, i))) })) })] }) }) })] }), isPayingOut && !hideAnimation && (_jsx("div", { className: twMerge(styles['light-rays'], 'absolute right-0 top-0 rounded-2xl [--light-rays-top:25%] lg:[--light-rays-top:150px]') }))] }));
|
|
81
|
-
}
|
|
82
|
-
const getAccumulatingJackpotDescription = (part, total) => {
|
|
83
|
-
const percentage = total === 0 ? 0 : (part / total) * 100;
|
|
84
|
-
return percentage <= 90
|
|
85
|
-
? 'The jackpot is heating up! Keep playing to stay in the action and watch it grow!'
|
|
86
|
-
: '🔥 It’s about to pop! Stay in the game for your shot at the prize!';
|
|
87
|
-
};
|
|
88
|
-
const starTierStyles = [
|
|
89
|
-
{
|
|
90
|
-
starColor: 'text-yellow-400',
|
|
91
|
-
numberColor: 'text-bg-primary',
|
|
92
|
-
},
|
|
93
|
-
{
|
|
94
|
-
starColor: 'text-utility-gray-700',
|
|
95
|
-
numberColor: 'text-bg-primary',
|
|
96
|
-
},
|
|
97
|
-
{
|
|
98
|
-
starColor: 'text-yellow-700',
|
|
99
|
-
numberColor: 'text-bg-primary',
|
|
100
|
-
},
|
|
101
|
-
{
|
|
102
|
-
starColor: 'text-bg-quaternary',
|
|
103
|
-
numberColor: 'text-text-primary-900',
|
|
104
|
-
},
|
|
105
|
-
{
|
|
106
|
-
starColor: 'text-bg-quaternary',
|
|
107
|
-
numberColor: 'text-text-primary-900',
|
|
108
|
-
},
|
|
109
|
-
];
|
|
@@ -1,184 +0,0 @@
|
|
|
1
|
-
@keyframes arrow-green-flash {
|
|
2
|
-
0% {
|
|
3
|
-
color: #abefc6;
|
|
4
|
-
}
|
|
5
|
-
100% {
|
|
6
|
-
color: #079455;
|
|
7
|
-
}
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
.animate-arrow-green-flash-1 {
|
|
11
|
-
animation: arrow-green-flash 0.4s infinite;
|
|
12
|
-
animation-delay: -0.2s;
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
.animate-arrow-green-flash-2 {
|
|
16
|
-
animation: arrow-green-flash 0.4s infinite;
|
|
17
|
-
animation-delay: -0.1s;
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
.animate-arrow-green-flash-3 {
|
|
21
|
-
animation: arrow-green-flash 0.4s infinite;
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
@keyframes arrow-red-flash {
|
|
25
|
-
0%,
|
|
26
|
-
100% {
|
|
27
|
-
color: #f97066;
|
|
28
|
-
}
|
|
29
|
-
50% {
|
|
30
|
-
color: #fecdca;
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
.animate-arrow-red-flash-1 {
|
|
35
|
-
animation: arrow-red-flash 0.4s infinite;
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
.animate-arrow-red-flash-2 {
|
|
39
|
-
animation: arrow-red-flash 0.4s infinite;
|
|
40
|
-
animation-delay: -0.1s;
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
.animate-arrow-red-flash-3 {
|
|
44
|
-
animation: arrow-red-flash 0.4s infinite;
|
|
45
|
-
animation-delay: -0.2s;
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
/* Animated BG */
|
|
49
|
-
@keyframes rotate {
|
|
50
|
-
to {
|
|
51
|
-
transform: rotate(1turn);
|
|
52
|
-
}
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
.light-rays {
|
|
56
|
-
position: absolute;
|
|
57
|
-
top: 0;
|
|
58
|
-
left: 0;
|
|
59
|
-
right: 0;
|
|
60
|
-
bottom: 0;
|
|
61
|
-
overflow: hidden;
|
|
62
|
-
|
|
63
|
-
--first: var(--color-bg-tertiary);
|
|
64
|
-
--second: var(--color-bg-quaternary);
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
.light-rays::before,
|
|
68
|
-
.light-rays::after {
|
|
69
|
-
content: '';
|
|
70
|
-
position: absolute;
|
|
71
|
-
top: var(--light-rays-top, 150px);
|
|
72
|
-
left: calc(50% - 90px);
|
|
73
|
-
margin: -100vmax;
|
|
74
|
-
width: 200vmax;
|
|
75
|
-
height: 200vmax;
|
|
76
|
-
opacity: 0.6;
|
|
77
|
-
transform-origin: center;
|
|
78
|
-
}
|
|
79
|
-
|
|
80
|
-
.light-rays::before {
|
|
81
|
-
background: conic-gradient(
|
|
82
|
-
var(--first) 0deg 7.2deg,
|
|
83
|
-
var(--second) 7.2deg 14.4deg,
|
|
84
|
-
var(--first) 14.4deg 21.6deg,
|
|
85
|
-
var(--second) 21.6deg 28.8deg,
|
|
86
|
-
var(--first) 28.8deg 36deg,
|
|
87
|
-
var(--second) 36deg 43.2deg,
|
|
88
|
-
var(--first) 43.2deg 50.4deg,
|
|
89
|
-
var(--second) 50.4deg 57.6deg,
|
|
90
|
-
var(--first) 57.6deg 64.8deg,
|
|
91
|
-
var(--second) 64.8deg 72deg,
|
|
92
|
-
var(--first) 72deg 79.2deg,
|
|
93
|
-
var(--second) 79.2deg 86.4deg,
|
|
94
|
-
var(--first) 86.4deg 93.6deg,
|
|
95
|
-
var(--second) 93.6deg 100.8deg,
|
|
96
|
-
var(--first) 100.8deg 108deg,
|
|
97
|
-
var(--second) 108deg 115.2deg,
|
|
98
|
-
var(--first) 115.2deg 122.4deg,
|
|
99
|
-
var(--second) 122.4deg 129.6deg,
|
|
100
|
-
var(--first) 129.6deg 136.8deg,
|
|
101
|
-
var(--second) 136.8deg 144deg,
|
|
102
|
-
var(--first) 144deg 151.2deg,
|
|
103
|
-
var(--second) 151.2deg 158.4deg,
|
|
104
|
-
var(--first) 158.4deg 165.6deg,
|
|
105
|
-
var(--second) 165.6deg 172.8deg,
|
|
106
|
-
var(--first) 172.8deg 180deg,
|
|
107
|
-
var(--second) 180deg 187.2deg,
|
|
108
|
-
var(--first) 187.2deg 194.4deg,
|
|
109
|
-
var(--second) 194.4deg 201.6deg,
|
|
110
|
-
var(--first) 201.6deg 208.8deg,
|
|
111
|
-
var(--second) 208.8deg 216deg,
|
|
112
|
-
var(--first) 216deg 223.2deg,
|
|
113
|
-
var(--second) 223.2deg 230.4deg,
|
|
114
|
-
var(--first) 230.4deg 237.6deg,
|
|
115
|
-
var(--second) 237.6deg 244.8deg,
|
|
116
|
-
var(--first) 244.8deg 252deg,
|
|
117
|
-
var(--second) 252deg 259.2deg,
|
|
118
|
-
var(--first) 259.2deg 266.4deg,
|
|
119
|
-
var(--second) 266.4deg 273.6deg,
|
|
120
|
-
var(--first) 273.6deg 280.8deg,
|
|
121
|
-
var(--second) 280.8deg 288deg,
|
|
122
|
-
var(--first) 288deg 295.2deg,
|
|
123
|
-
var(--second) 295.2deg 302.4deg,
|
|
124
|
-
var(--first) 302.4deg 309.6deg,
|
|
125
|
-
var(--second) 309.6deg 316.8deg,
|
|
126
|
-
var(--first) 316.8deg 324deg,
|
|
127
|
-
var(--second) 324deg 331.2deg,
|
|
128
|
-
var(--first) 331.2deg 338.4deg,
|
|
129
|
-
var(--second) 338.4deg 345.6deg,
|
|
130
|
-
var(--first) 345.6deg 352.8deg,
|
|
131
|
-
var(--second) 352.8deg 360deg
|
|
132
|
-
);
|
|
133
|
-
animation: rotate 20s linear infinite;
|
|
134
|
-
}
|
|
135
|
-
|
|
136
|
-
@media (max-width: 1024px) {
|
|
137
|
-
.light-rays::before,
|
|
138
|
-
.light-rays::after {
|
|
139
|
-
left: auto;
|
|
140
|
-
right: 11%;
|
|
141
|
-
}
|
|
142
|
-
}
|
|
143
|
-
|
|
144
|
-
/* ScrollArea.module.css */
|
|
145
|
-
.scrollArea {
|
|
146
|
-
overflow-y: scroll;
|
|
147
|
-
padding-right: 4px;
|
|
148
|
-
}
|
|
149
|
-
|
|
150
|
-
/* WebKit-based browsers */
|
|
151
|
-
.scrollArea::-webkit-scrollbar {
|
|
152
|
-
width: 8px;
|
|
153
|
-
}
|
|
154
|
-
|
|
155
|
-
.scrollArea::-webkit-scrollbar-track {
|
|
156
|
-
background: var(--color-bg-primary-alt);
|
|
157
|
-
border-radius: 9999px;
|
|
158
|
-
}
|
|
159
|
-
|
|
160
|
-
.scrollArea::-webkit-scrollbar-thumb {
|
|
161
|
-
background-color: var(--color-bg-quaternary);
|
|
162
|
-
border-radius: 9999px;
|
|
163
|
-
}
|
|
164
|
-
|
|
165
|
-
@keyframes waveColor {
|
|
166
|
-
0%,
|
|
167
|
-
2.5% {
|
|
168
|
-
color: var(--wave-highlight-color);
|
|
169
|
-
}
|
|
170
|
-
2.51%,
|
|
171
|
-
100% {
|
|
172
|
-
color: var(--color-brand-300);
|
|
173
|
-
}
|
|
174
|
-
}
|
|
175
|
-
|
|
176
|
-
.animate-wave-color-success {
|
|
177
|
-
--wave-highlight-color: var(--color-success-800);
|
|
178
|
-
animation: waveColor 4s ease-in-out infinite;
|
|
179
|
-
}
|
|
180
|
-
|
|
181
|
-
.animate-wave-color-error {
|
|
182
|
-
--wave-highlight-color: var(--color-error-600);
|
|
183
|
-
animation: waveColor 4s ease-in-out infinite;
|
|
184
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './JackpotCounter';
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './JackpotCounter.js';
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function JackpotDesktop(): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,45 +0,0 @@
|
|
|
1
|
-
'use client';
|
|
2
|
-
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
3
|
-
import { Progress } from '@ark-ui/react';
|
|
4
|
-
import Image from 'next/image';
|
|
5
|
-
import { twMerge } from 'tailwind-merge';
|
|
6
|
-
import { ArrowNarrowUpRightIcon, ChevronLeftIcon, ChevronRightIcon, Trophy01Icon, User01Icon, } from '../../icons/index.js';
|
|
7
|
-
import { StarIcon } from '../../icons/StarIcon.js';
|
|
8
|
-
import closeChest from '../../images/close-chest.png';
|
|
9
|
-
import firstPlace from '../../images/first-place.png';
|
|
10
|
-
import leaderboard from '../../images/leaderboard.png';
|
|
11
|
-
import openChest from '../../images/open-chest.png';
|
|
12
|
-
import { formatNumber, getPercentage, mask } from '../../utils/index.js';
|
|
13
|
-
import styles from '../JackpotCounter/JackpotCounterItem.module.css';
|
|
14
|
-
import { JackpotGameProviders } from './JackpotGameProviders.js';
|
|
15
|
-
import { JackpotRules } from './JackpotRules.js';
|
|
16
|
-
import { useJackpotContext } from './JackpotsContext.js';
|
|
17
|
-
import { useJackpotData } from './useJackpotData.js';
|
|
18
|
-
export function JackpotDesktop() {
|
|
19
|
-
const jackpot = useJackpotContext();
|
|
20
|
-
const { jackpotPayouts, topJackpotPayout, filteredGameProviders, localeInfo, isPayingOut, jackpotAmount, arrowImages, getAccumulatingJackpotDescription, starTierStyles, } = useJackpotData();
|
|
21
|
-
return (_jsxs("div", { className: twMerge('bg-bg-tertiary border-border-primary rounded-2xl border'), children: [_jsxs("div", { className: twMerge('relative flex shrink-0 p-3 text-center lg:gap-4 lg:p-5'), children: [_jsxs("div", { className: "z-1 relative flex flex-1 flex-col", children: [_jsx("div", { className: "flex h-full flex-col justify-between", children: _jsx("div", { className: "flex w-full justify-between", children: _jsxs("div", { className: "flex w-full flex-col", children: [_jsxs("div", { className: "relative flex w-full justify-between", children: [_jsxs("div", { children: [isPayingOut ? (_jsxs("div", { className: "border-utility-success-200 bg-utility-success-50 text-utility-success-700 flex w-fit items-center gap-1 rounded-full border px-2 py-0.5 text-xs font-medium", children: [_jsx("span", { className: "full bg-utility-success-500 size-1.5 animate-pulse rounded" }), "Paying Out"] })) : (_jsxs("div", { className: "border-utility-blue-200 bg-utility-blue-50 text-utility-blue-700 flex w-fit items-center gap-1 rounded-full border px-2 py-0.5 text-xs font-medium", children: [_jsx(ArrowNarrowUpRightIcon, { className: "text-utility-blue-500 size-3.5" }), "Accumulating"] })), _jsx("div", { className: "text-text-primary-900 mt-1 text-left text-lg font-medium lg:mt-5 lg:text-2xl", children: jackpot.name }), _jsx("div", { className: "bg-bg-primary text-brand-400 mt-1.5 w-fit rounded-md px-2 py-1 text-2xl font-bold lg:mt-2 lg:text-4xl", children: formatNumber(jackpotAmount, {
|
|
22
|
-
currency: localeInfo.currency.code,
|
|
23
|
-
minDecimalPlaces: 2,
|
|
24
|
-
maxDecimalPlaces: 2,
|
|
25
|
-
}) })] }), _jsx("div", { className: "z-1 bottom-[-60] right-0 block lg:absolute", children: _jsx(Image, { width: 150, height: 150, src: isPayingOut ? openChest : closeChest, alt: "closeChest", quality: 100, className: "h-25 w-25 lg:h-37.5 lg:w-37.5 size-full p-2" }) })] }), topJackpotPayout.amount ? (_jsx("div", { children: _jsxs("div", { className: "bg-bg-primary relative mt-4 hidden w-full gap-4 rounded-lg p-4 lg:flex", children: [_jsxs("div", { className: "bg-bg-tertiary relative flex h-18 w-18 items-center justify-center rounded-full", children: [_jsx(User01Icon, { className: "text-text-quarterary-500 size-9" }), _jsx("div", { className: "bg-yellow-400 text-brand-950 border-bg-primary absolute bottom-0 right-0 flex h-6 w-6 items-center justify-center rounded-full border-[1.5px] text-xs font-bold", children: "1st" })] }), _jsxs("div", { className: "flex flex-col gap-1 text-left", children: [_jsxs("div", { className: "border-utility-brand-200 bg-utility-brand-50 text-utility-brand-700 flex h-fit w-fit items-center gap-1 rounded-sm border px-2 py-0.5 text-xs font-medium", children: [_jsx(Trophy01Icon, { className: "text-utility-brand-600 size-3.5" }), "Top Payout"] }), _jsx("div", { className: "font-semibold", children: mask(topJackpotPayout.member.name) }), _jsx("div", { className: "text-brand-400 text-2xl", children: formatNumber(topJackpotPayout.amount, {
|
|
26
|
-
currency: localeInfo.currency.code,
|
|
27
|
-
minDecimalPlaces: 2,
|
|
28
|
-
maxDecimalPlaces: 2,
|
|
29
|
-
}) })] })] }) })) : (_jsxs("div", { className: "bg-bg-primary relative mt-4 hidden w-full gap-4 rounded-lg p-4 lg:flex", children: [_jsx(Image, { width: 66, height: 87, src: firstPlace, alt: "closeChest", className: "size-full h-auto w-[66px] mix-blend-luminosity" }), _jsxs("div", { className: "flex flex-col gap-1 text-left", children: [_jsxs("div", { className: "border-utility-brand-200 bg-utility-brand-50 text-utility-brand-700 flex h-fit w-fit items-center gap-1 rounded-sm border px-2 py-0.5 text-xs font-medium", children: [_jsx(Trophy01Icon, { className: "text-utility-brand-600 size-3.5" }), "Top Payout"] }), _jsx("div", { className: "font-semibold", children: "No winners yet" }), _jsx("div", { className: "text-text-secondary-700 text-xs", children: "You could be the first to win the tournament!" })] })] }))] }) }) }), _jsxs("div", { className: "mt-3 lg:mt-4", children: [_jsxs("div", { className: "mb-1 flex justify-between", children: [_jsx("div", { className: "text-text-primary-900 text-xs font-semibold", children: formatNumber(0, {
|
|
30
|
-
currency: localeInfo.currency.code,
|
|
31
|
-
compact: true,
|
|
32
|
-
}) }), _jsxs("div", { className: "relative flex items-center justify-end gap-1.5", children: [isPayingOut ? (_jsxs("div", { className: "flex w-6 items-center", children: [_jsx("div", { className: twMerge('absolute left-0', styles['animate-arrow-red-flash-1']), children: _jsx(ChevronLeftIcon, { className: "size-4.5" }) }), _jsx("div", { className: twMerge('absolute left-1.5', styles['animate-arrow-red-flash-2']), children: _jsx(ChevronLeftIcon, { className: "size-4.5" }) }), _jsx("div", { className: twMerge('absolute left-3', styles['animate-arrow-red-flash-3']), children: _jsx(ChevronLeftIcon, { className: "size-4.5" }) })] })) : (_jsxs("div", { className: "flex w-6 items-center", children: [_jsx("div", { className: twMerge('absolute left-0', styles['animate-arrow-green-flash-1']), children: _jsx(ChevronRightIcon, { className: "size-4.5" }) }), _jsx("div", { className: twMerge('absolute left-1.5', styles['animate-arrow-green-flash-2']), children: _jsx(ChevronRightIcon, { className: "size-4.5" }) }), _jsx("div", { className: twMerge('absolute left-3', styles['animate-arrow-green-flash-3']), children: _jsx(ChevronRightIcon, { className: "size-4.5" }) })] })), _jsx("div", { className: "text-text-primary-900 text-xs font-semibold", children: formatNumber(jackpot?.maximumJackpotPoolLimit, {
|
|
33
|
-
currency: localeInfo.currency.code,
|
|
34
|
-
compact: true,
|
|
35
|
-
}) })] })] }), _jsx(Progress.Root, { className: "bg-bg-primary h-2 w-full rounded-full lg:h-4", max: 100, value: getPercentage(jackpot.pool, jackpot.maximumJackpotPoolLimit), children: _jsx(Progress.Track, { className: "bg-bg-primary h-full overflow-hidden rounded-full", children: _jsx(Progress.Range, { className: "bg-brand-500 relative h-full overflow-hidden rounded-full pl-1.5", children: _jsx("div", { className: "pointer-events-none absolute inset-0 flex items-center justify-start pl-1.5", "aria-hidden": "true", children: arrowImages }) }) }) }), _jsx("div", { className: "mt-1 block text-start text-2xs lg:hidden", children: isPayingOut
|
|
36
|
-
? `The pot has hit ${formatNumber(jackpot?.maximumJackpotPoolLimit, {
|
|
37
|
-
currency: localeInfo.currency.code,
|
|
38
|
-
compact: true,
|
|
39
|
-
})} Play now for your chance to win big! 🔥`
|
|
40
|
-
: getAccumulatingJackpotDescription(Number(jackpot?.pool) ?? 0, Number(jackpot?.maximumJackpotPoolLimit) ?? 0) })] })] }), _jsxs("div", { className: "z-1 hidden flex-1 space-y-4 lg:block", children: [_jsxs("div", { className: "flex items-center justify-between", children: [_jsxs("div", { className: "flex gap-2", children: [_jsx(Image, { width: 24, height: 24, src: leaderboard, quality: 100, alt: "leaderboardIcon", className: "size-full h-auto w-6" }), _jsx("div", { className: "text-text-primary-900 text-lg font-semibold", children: jackpotPayouts.length ? 'Leaderboard' : 'Starting soon!' })] }), _jsx(JackpotRules, {})] }), _jsx("div", { className: twMerge('max-h-[272px] overflow-y-scroll', styles['scrollArea']), children: _jsx("div", { className: "border-gray-200 overflow-hidden rounded-xl", children: _jsxs("table", { className: "w-full", children: [_jsx("thead", { children: _jsxs("tr", { className: "bg-bg-secondary text-text-tertiary-600 h-8 text-xs font-medium", children: [_jsx("th", { className: "w-[52px]", children: "#" }), _jsx("th", { children: "Player" }), _jsx("th", { children: "Multiplier" }), _jsx("th", { children: "Prize" })] }) }), _jsx("tbody", { children: jackpotPayouts.length ? (_jsx(_Fragment, { children: jackpotPayouts.map((jackpotPayout, i) => (_jsxs("tr", { className: "bg-bg-primary text-text-secondary-700 text-sm", children: [_jsx("td", { className: "border-border-secondary h-12 w-[52px] border-t-2", children: i + 1 < 6 ? (_jsxs("div", { className: "relative", children: [_jsx(StarIcon, { className: twMerge('mx-auto size-6.5', starTierStyles[i].starColor) }), _jsx("span", { className: twMerge('absolute inset-0 mt-0.5 flex items-center justify-center text-2xs font-bold', starTierStyles[i].numberColor), children: i + 1 })] })) : (i + 1) }), _jsx("td", { className: "border-border-secondary h-12 border-t-2", children: mask(jackpotPayout.member.name) }), _jsxs("td", { className: "border-border-secondary h-12 border-t-2", children: [jackpotPayout.multiplier, "x"] }), _jsx("td", { className: "border-border-secondary text-brand-400 h-12 border-t-2", children: formatNumber(jackpotPayout.amount, {
|
|
41
|
-
currency: localeInfo.currency.code,
|
|
42
|
-
minDecimalPlaces: 2,
|
|
43
|
-
maxDecimalPlaces: 2,
|
|
44
|
-
}) })] }, i))) })) : (_jsx(_Fragment, { children: Array.from({ length: 10 }).map((_, i) => (_jsxs("tr", { className: "bg-bg-primary text-text-secondary-700 text-sm", children: [_jsx("td", { className: "border-border-secondary h-12 w-[52px] border-t-2", children: i + 1 < 6 ? (_jsxs("div", { className: "relative", children: [_jsx(StarIcon, { className: twMerge('mx-auto size-6.5', starTierStyles[i].starColor) }), _jsx("span", { className: twMerge('absolute inset-0 mt-0.5 flex items-center justify-center text-2xs font-bold', starTierStyles[i].numberColor), children: i + 1 })] })) : (i + 1) }), _jsx("td", { className: "border-border-secondary h-12 border-t-2", children: "-" }), _jsx("td", { className: "border-border-secondary h-12 border-t-2", children: "-" }), _jsx("td", { className: "border-border-secondary h-12 border-t-2", children: "-" })] }, i))) })) })] }) }) })] }), isPayingOut && (_jsx("div", { className: twMerge(styles['light-rays'], 'absolute right-0 top-0 rounded-2xl') }))] }), Boolean(filteredGameProviders.length) && (_jsx(JackpotGameProviders, { gameProviders: filteredGameProviders }))] }));
|
|
45
|
-
}
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
import type { GameProviderData } from '../../types';
|
|
2
|
-
export interface JackpotGameProvidersProps {
|
|
3
|
-
gameProviders: GameProviderData[];
|
|
4
|
-
}
|
|
5
|
-
export declare function JackpotGameProviders({ gameProviders, }: JackpotGameProvidersProps): import("react/jsx-runtime").JSX.Element;
|