@opexa/portal-components 0.0.935 → 0.0.936
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/useSessionHealthQuery.js +16 -0
- package/dist/components/DepositWithdrawal/Deposit/AurixPayPayMayaDeposit/AurixPayGrabPayDeposit.js +2 -21
- package/dist/components/DepositWithdrawal/Deposit/OnlineBankDeposit/OnlineBankDepositContext.d.ts +2 -2
- package/dist/components/DepositWithdrawal/Deposit/OnlineBankDeposit/useOnlineBankDeposit.d.ts +1 -1
- package/dist/components/ForgotPassword/Crazywin/ForgotPassword.module.css +42 -42
- package/dist/components/Jackpots/Jackpots.module.css +288 -288
- package/dist/components/KYC/KYCDefault/KYCVerificationStatus.lazy.js +2 -2
- package/dist/components/KYC/KYCNonPagCor/KYCVerificationStatus.lazy.js +2 -2
- package/dist/components/PortalProvider/SessionWatcher.js +0 -2
- package/dist/components/SingleSignOn/SingleSignOn.d.ts +1 -1
- package/dist/components/SingleSignOn/SingleSignOn.js +15 -7
- package/dist/components/Tournaments/TournamentsCarousel/TournamentsCarouselItem.module.css +184 -184
- package/dist/components/Tournaments/TournamentsList/TournamentItem.module.css +184 -184
- package/dist/images/phone-icon.svg +10 -10
- package/dist/services/queries.js +3369 -3369
- package/dist/styles/theme.css +776 -776
- package/dist/ui/QrCode/QrCode.d.ts +25 -25
- package/dist/ui/QrCode/qrCode.recipe.d.ts +5 -5
- package/package.json +179 -179
- package/dist/assets/providers/alize.png +0 -0
- package/dist/assets/providers/bigtime-gaming.png +0 -0
- package/dist/assets/providers/bng.png +0 -0
- package/dist/assets/providers/boongo.png +0 -0
- package/dist/assets/providers/btg.png +0 -0
- package/dist/assets/providers/cq9.png +0 -0
- package/dist/assets/providers/darwin.png +0 -0
- package/dist/assets/providers/digitain.png +0 -0
- package/dist/assets/providers/evolution.png +0 -0
- package/dist/assets/providers/fantasma-games.png +0 -0
- package/dist/assets/providers/fc.png +0 -0
- package/dist/assets/providers/fp.png +0 -0
- package/dist/assets/providers/habanero.png +0 -0
- package/dist/assets/providers/hacksaw.png +0 -0
- package/dist/assets/providers/jdb.png +0 -0
- package/dist/assets/providers/jili.png +0 -0
- package/dist/assets/providers/leap.png +0 -0
- package/dist/assets/providers/live-22-metaverse.png +0 -0
- package/dist/assets/providers/netent.png +0 -0
- package/dist/assets/providers/no-limit.png +0 -0
- package/dist/assets/providers/pg.png +0 -0
- package/dist/assets/providers/pgsoft.png +0 -0
- package/dist/assets/providers/pragmatic-play.png +0 -0
- package/dist/assets/providers/realtime-gaming.png +0 -0
- package/dist/assets/providers/redtiger.png +0 -0
- package/dist/assets/providers/rtg.png +0 -0
- package/dist/assets/providers/sagaming.png +0 -0
- package/dist/client/hooks/useAiOGCashDepositMutation.d.ts +0 -4
- package/dist/client/hooks/useAiOGCashDepositMutation.js +0 -90
- package/dist/client/hooks/useAiOGrabPayDepositMutation.d.ts +0 -4
- package/dist/client/hooks/useAiOGrabPayDepositMutation.js +0 -80
- package/dist/client/hooks/useAiOPalawanPayDepositMutation.d.ts +0 -4
- package/dist/client/hooks/useAiOPalawanPayDepositMutation.js +0 -80
- package/dist/client/hooks/useAiOPayMayaDepositMutation.d.ts +0 -4
- package/dist/client/hooks/useAiOPayMayaDepositMutation.js +0 -80
- package/dist/components/DepositWithdrawal/AiOPaymentMethods.d.ts +0 -11
- package/dist/components/DepositWithdrawal/AiOPaymentMethods.js +0 -55
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit/QRPHDepositAlert.d.ts +0 -1
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit/QRPHDepositAlert.js +0 -99
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit/QRPHDepositDetails.d.ts +0 -1
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit/QRPHDepositDetails.js +0 -17
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit/QRPHDepositForm.d.ts +0 -1
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit/QRPHDepositForm.js +0 -116
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit/QRPHQRCode.d.ts +0 -3
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit/QRPHQRCode.js +0 -69
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit__legacy/QRPHDeposit.d.ts +0 -1
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit__legacy/QRPHDeposit.js +0 -10
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit__legacy/QRPHDepositAlert.d.ts +0 -1
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit__legacy/QRPHDepositAlert.js +0 -99
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit__legacy/QRPHDepositContext.d.ts +0 -25
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit__legacy/QRPHDepositContext.js +0 -2
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit__legacy/QRPHDepositDetails.d.ts +0 -1
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit__legacy/QRPHDepositDetails.js +0 -17
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit__legacy/QRPHDepositForm.d.ts +0 -1
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit__legacy/QRPHDepositForm.js +0 -116
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit__legacy/QRPHQRCode.d.ts +0 -3
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit__legacy/QRPHQRCode.js +0 -69
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit__legacy/useQRPHDeposit.d.ts +0 -13
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit__legacy/useQRPHDeposit.js +0 -85
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit__next/Confirmed.d.ts +0 -1
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit__next/Confirmed.js +0 -11
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit__next/Failed.d.ts +0 -1
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit__next/Failed.js +0 -11
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit__next/Form.d.ts +0 -1
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit__next/Form.js +0 -126
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit__next/GeneratingQrCode.d.ts +0 -1
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit__next/GeneratingQrCode.js +0 -10
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit__next/QRPHDeposit.d.ts +0 -1
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit__next/QRPHDeposit.js +0 -12
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit__next/QRPHDepositContext.d.ts +0 -17
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit__next/QRPHDepositContext.js +0 -2
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit__next/QrCodeGenerated.d.ts +0 -1
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit__next/QrCodeGenerated.js +0 -41
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit__next/useQRPHDeposit.d.ts +0 -13
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit__next/useQRPHDeposit.js +0 -91
- package/dist/components/DepositWithdrawal/Deposit__legacy/AiOGCashDeposit/AiOGCashDeposit.d.ts +0 -1
- package/dist/components/DepositWithdrawal/Deposit__legacy/AiOGCashDeposit/AiOGCashDeposit.js +0 -173
- package/dist/components/DepositWithdrawal/Deposit__legacy/AiOGrabPayDeposit/AiOGrabPayDeposit.d.ts +0 -1
- package/dist/components/DepositWithdrawal/Deposit__legacy/AiOGrabPayDeposit/AiOGrabPayDeposit.js +0 -171
- package/dist/components/DepositWithdrawal/Deposit__legacy/AiOPalawanPayDeposit/AiOPalawanPayDeposit.d.ts +0 -1
- package/dist/components/DepositWithdrawal/Deposit__legacy/AiOPalawanPayDeposit/AiOPalawanPayDeposit.js +0 -171
- package/dist/components/DepositWithdrawal/Deposit__legacy/AiOPayMayaDeposit/AiOPayMayaDeposit.d.ts +0 -1
- package/dist/components/DepositWithdrawal/Deposit__legacy/AiOPayMayaDeposit/AiOPayMayaDeposit.js +0 -171
- package/dist/components/DepositWithdrawal/Deposit__legacy/AvailablePromos.d.ts +0 -8
- package/dist/components/DepositWithdrawal/Deposit__legacy/AvailablePromos.js +0 -33
- package/dist/components/DepositWithdrawal/Deposit__legacy/Deposit.d.ts +0 -1
- package/dist/components/DepositWithdrawal/Deposit__legacy/Deposit.js +0 -120
- package/dist/components/DepositWithdrawal/Deposit__legacy/GCashDeposit/GCashDeposit.d.ts +0 -1
- package/dist/components/DepositWithdrawal/Deposit__legacy/GCashDeposit/GCashDeposit.js +0 -163
- package/dist/components/DepositWithdrawal/Deposit__legacy/GCashWebpayDeposit/GCashWebpayDeposit.d.ts +0 -1
- package/dist/components/DepositWithdrawal/Deposit__legacy/GCashWebpayDeposit/GCashWebpayDeposit.js +0 -165
- package/dist/components/DepositWithdrawal/Deposit__legacy/LibanganDeposit/LibanganDeposit.d.ts +0 -1
- package/dist/components/DepositWithdrawal/Deposit__legacy/LibanganDeposit/LibanganDeposit.js +0 -186
- package/dist/components/DepositWithdrawal/Deposit__legacy/MayaAppDeposit/MayaAppDeposit.d.ts +0 -1
- package/dist/components/DepositWithdrawal/Deposit__legacy/MayaAppDeposit/MayaAppDeposit.js +0 -157
- package/dist/components/DepositWithdrawal/Deposit__legacy/MayaDeposit/MayaDeposit.d.ts +0 -1
- package/dist/components/DepositWithdrawal/Deposit__legacy/MayaDeposit/MayaDeposit.js +0 -163
- package/dist/components/DepositWithdrawal/Deposit__legacy/MayaWebpayDeposit/MayaWebpayDeposit.d.ts +0 -1
- package/dist/components/DepositWithdrawal/Deposit__legacy/MayaWebpayDeposit/MayaWebpayDeposit.js +0 -166
- package/dist/components/DepositWithdrawal/Deposit__legacy/OnlineBankDeposit/OnlineBankDeposit.d.ts +0 -1
- package/dist/components/DepositWithdrawal/Deposit__legacy/OnlineBankDeposit/OnlineBankDeposit.js +0 -10
- package/dist/components/DepositWithdrawal/Deposit__legacy/OnlineBankDeposit/OnlineBankDepositAlert.d.ts +0 -1
- package/dist/components/DepositWithdrawal/Deposit__legacy/OnlineBankDeposit/OnlineBankDepositAlert.js +0 -99
- package/dist/components/DepositWithdrawal/Deposit__legacy/OnlineBankDeposit/OnlineBankDepositContext.d.ts +0 -25
- package/dist/components/DepositWithdrawal/Deposit__legacy/OnlineBankDeposit/OnlineBankDepositContext.js +0 -2
- package/dist/components/DepositWithdrawal/Deposit__legacy/OnlineBankDeposit/OnlineBankDepositDetails.d.ts +0 -1
- package/dist/components/DepositWithdrawal/Deposit__legacy/OnlineBankDeposit/OnlineBankDepositDetails.js +0 -19
- package/dist/components/DepositWithdrawal/Deposit__legacy/OnlineBankDeposit/OnlineBankDepositForm.d.ts +0 -1
- package/dist/components/DepositWithdrawal/Deposit__legacy/OnlineBankDeposit/OnlineBankDepositForm.js +0 -115
- package/dist/components/DepositWithdrawal/Deposit__legacy/OnlineBankDeposit/useOnlineBankDeposit.d.ts +0 -13
- package/dist/components/DepositWithdrawal/Deposit__legacy/OnlineBankDeposit/useOnlineBankDeposit.js +0 -81
- package/dist/components/DepositWithdrawal/Deposit__legacy/PisoPayDeposit/PisoPayDeposit.d.ts +0 -1
- package/dist/components/DepositWithdrawal/Deposit__legacy/PisoPayDeposit/PisoPayDeposit.js +0 -180
- package/dist/components/DepositWithdrawal/Deposit__legacy/QRPHDeposit/QRPHDeposit.d.ts +0 -1
- package/dist/components/DepositWithdrawal/Deposit__legacy/QRPHDeposit/QRPHDeposit.js +0 -10
- package/dist/components/DepositWithdrawal/Deposit__legacy/QRPHDeposit/QRPHDepositAlert.d.ts +0 -1
- package/dist/components/DepositWithdrawal/Deposit__legacy/QRPHDeposit/QRPHDepositAlert.js +0 -99
- package/dist/components/DepositWithdrawal/Deposit__legacy/QRPHDeposit/QRPHDepositContext.d.ts +0 -25
- package/dist/components/DepositWithdrawal/Deposit__legacy/QRPHDeposit/QRPHDepositContext.js +0 -2
- package/dist/components/DepositWithdrawal/Deposit__legacy/QRPHDeposit/QRPHDepositDetails.d.ts +0 -1
- package/dist/components/DepositWithdrawal/Deposit__legacy/QRPHDeposit/QRPHDepositDetails.js +0 -17
- package/dist/components/DepositWithdrawal/Deposit__legacy/QRPHDeposit/QRPHDepositForm.d.ts +0 -1
- package/dist/components/DepositWithdrawal/Deposit__legacy/QRPHDeposit/QRPHDepositForm.js +0 -116
- package/dist/components/DepositWithdrawal/Deposit__legacy/QRPHDeposit/QRPHQRCode.d.ts +0 -3
- package/dist/components/DepositWithdrawal/Deposit__legacy/QRPHDeposit/QRPHQRCode.js +0 -69
- package/dist/components/DepositWithdrawal/Deposit__legacy/QRPHDeposit/useQRPHDeposit.d.ts +0 -13
- package/dist/components/DepositWithdrawal/Deposit__legacy/QRPHDeposit/useQRPHDeposit.js +0 -85
- package/dist/components/DigitainLauncher/Loading.d.ts +0 -1
- package/dist/components/DigitainLauncher/Loading.js +0 -5
- package/dist/components/Disclaimer/ResponsibleGaming.d.ts +0 -10
- package/dist/components/Disclaimer/ResponsibleGaming.js +0 -13
- package/dist/components/Disclaimer/TermsOfUse.d.ts +0 -11
- package/dist/components/Disclaimer/TermsOfUse.js +0 -13
- package/dist/components/FeatureFlag/FeatureFlag.d.ts +0 -1
- package/dist/components/FeatureFlag/FeatureFlag.js +0 -29
- package/dist/components/FeatureFlag/index.d.ts +0 -1
- package/dist/components/FeatureFlag/index.js +0 -1
- package/dist/components/Jackpots/JackpotsCarousel/JackpotsCarouselItem.module.css +0 -184
- package/dist/components/Jackpots/JackpotsList/JackpotsListItem.module.css +0 -184
- package/dist/components/KYC/AutoOpen.d.ts +0 -1
- package/dist/components/KYC/AutoOpen.js +0 -40
- package/dist/components/KYC/BasicInformation.d.ts +0 -1
- package/dist/components/KYC/BasicInformation.js +0 -101
- package/dist/components/KYC/CaptureIdDocument.d.ts +0 -1
- package/dist/components/KYC/CaptureIdDocument.js +0 -219
- package/dist/components/KYC/CaptureSelfie.d.ts +0 -1
- package/dist/components/KYC/CaptureSelfie.js +0 -285
- package/dist/components/KYC/DisplayImage.d.ts +0 -5
- package/dist/components/KYC/DisplayImage.js +0 -8
- package/dist/components/KYC/FileUpload.d.ts +0 -10
- package/dist/components/KYC/FileUpload.js +0 -72
- package/dist/components/KYC/IdentityVerification.d.ts +0 -1
- package/dist/components/KYC/IdentityVerification.js +0 -120
- package/dist/components/KYC/Indicator.d.ts +0 -1
- package/dist/components/KYC/Indicator.js +0 -8
- package/dist/components/KYC/KYC.lazy.d.ts +0 -6
- package/dist/components/KYC/KYC.lazy.js +0 -45
- package/dist/components/KYC/KYCContext.d.ts +0 -6
- package/dist/components/KYC/KYCContext.js +0 -2
- package/dist/components/KYC/KYCDefault/BasicInformation.d.ts +0 -1
- package/dist/components/KYC/KYCDefault/BasicInformation.js +0 -101
- package/dist/components/KYC/KYCVerificationStatus.d.ts +0 -1
- package/dist/components/KYC/KYCVerificationStatus.js +0 -10
- package/dist/components/KYC/KYCVerificationStatus.lazy.d.ts +0 -1
- package/dist/components/KYC/KYCVerificationStatus.lazy.js +0 -39
- package/dist/components/KYC/NoCameraError.d.ts +0 -7
- package/dist/components/KYC/NoCameraError.js +0 -6
- package/dist/components/KYC/PersonOverlayDesktop.d.ts +0 -7
- package/dist/components/KYC/PersonOverlayDesktop.js +0 -9
- package/dist/components/KYC/PersonalInformation.d.ts +0 -1
- package/dist/components/KYC/PersonalInformation.js +0 -122
- package/dist/components/KYC/backup/Header.d.ts +0 -1
- package/dist/components/KYC/backup/Header.js +0 -8
- package/dist/components/KYC/backup/Indicator.d.ts +0 -1
- package/dist/components/KYC/backup/Indicator.js +0 -9
- package/dist/components/KYC/backup/KYC.d.ts +0 -1
- package/dist/components/KYC/backup/KYC.js +0 -14
- package/dist/components/KYC/backup/KYC.lazy.d.ts +0 -1
- package/dist/components/KYC/backup/KYC.lazy.js +0 -26
- package/dist/components/KYC/backup/KYCContext.d.ts +0 -6
- package/dist/components/KYC/backup/KYCContext.js +0 -2
- package/dist/components/KYC/backup/Step1.d.ts +0 -1
- package/dist/components/KYC/backup/Step1.js +0 -13
- package/dist/components/KYC/backup/Step2.d.ts +0 -1
- package/dist/components/KYC/backup/Step2.js +0 -13
- package/dist/components/KYC/backup/Step3.d.ts +0 -1
- package/dist/components/KYC/backup/Step3.js +0 -13
- package/dist/components/KYC/backup/Step4.d.ts +0 -1
- package/dist/components/KYC/backup/Step4.js +0 -7
- package/dist/components/KYC/backup/useKYC.d.ts +0 -10
- package/dist/components/KYC/backup/useKYC.js +0 -8
- package/dist/components/KYC/loadModels.d.ts +0 -1
- package/dist/components/KYC/loadModels.js +0 -9
- package/dist/components/KYC/useKYC.d.ts +0 -25
- package/dist/components/KYC/useKYC.js +0 -38
- package/dist/components/KYC/utils.d.ts +0 -9
- package/dist/components/KYC/utils.js +0 -79
- package/dist/components/KYCNotRequired/KYCNotRequired.d.ts +0 -0
- package/dist/components/KYCNotRequired/KYCNotRequired.js +0 -1
- package/dist/components/Messages/Message.d.ts +0 -1
- package/dist/components/Messages/Message.js +0 -35
- package/dist/components/Messages/MessageContext.d.ts +0 -6
- package/dist/components/Messages/MessageContext.js +0 -2
- package/dist/components/Messages/MessagePopup.d.ts +0 -1
- package/dist/components/Messages/MessagePopup.js +0 -20
- package/dist/components/Messages/MessageTrigger.d.ts +0 -8
- package/dist/components/Messages/MessageTrigger.js +0 -19
- package/dist/components/PortalProvider/CXDTokenObserver.d.ts +0 -1
- package/dist/components/PortalProvider/CXDTokenObserver.js +0 -30
- package/dist/components/PortalProvider/LinkGoogleAccountObserver.d.ts +0 -1
- package/dist/components/PortalProvider/LinkGoogleAccountObserver.js +0 -29
- package/dist/components/Quests/CountdownTimer.d.ts +0 -15
- package/dist/components/Quests/CountdownTimer.js +0 -33
- package/dist/components/Quests/DailyCheckInQuest/DailyCheckInQuest.d.ts +0 -4
- package/dist/components/Quests/DailyCheckInQuest/DailyCheckInQuest.js +0 -78
- package/dist/components/Quests/DailyCheckInQuest/DailyCheckInQuestModal.d.ts +0 -8
- package/dist/components/Quests/DailyCheckInQuest/DailyCheckInQuestModal.js +0 -9
- package/dist/components/Quests/MultiWageringQuest.d.ts +0 -1
- package/dist/components/Quests/MultiWageringQuest.js +0 -111
- package/dist/components/Quests/OnboardingQuest/OnboardingQuest.d.ts +0 -4
- package/dist/components/Quests/OnboardingQuest/OnboardingQuest.js +0 -4
- package/dist/components/Quests/WageringQuest/WageringQuest.d.ts +0 -4
- package/dist/components/Quests/WageringQuest/WageringQuest.js +0 -20
- package/dist/components/Quests/WageringQuest/WageringQuestModal.d.ts +0 -9
- package/dist/components/Quests/WageringQuest/WageringQuestModal.js +0 -9
- package/dist/components/SessionWatcher/SessionWatcher.d.ts +0 -1
- package/dist/components/SessionWatcher/SessionWatcher.js +0 -20
- package/dist/components/SessionWatcher/index.d.ts +0 -1
- package/dist/components/SessionWatcher/index.js +0 -1
- package/dist/components/SignIn/utils.d.ts +0 -8
- package/dist/components/SignIn/utils.js +0 -26
- package/dist/components/SignUp/SignUp.lazy.d.ts +0 -12
- package/dist/components/SignUp/SignUp.lazy.js +0 -18
- package/dist/components/SignUp/SignUpContext.d.ts +0 -6
- package/dist/components/SignUp/SignUpContext.js +0 -2
- package/dist/components/SignUp/SignUpDefault/SignUp.lazy.d.ts +0 -17
- package/dist/components/SignUp/SignUpDefault/SignUp.lazy.js +0 -18
- package/dist/components/SignUp/SignUpDefault/SignUpContext.d.ts +0 -6
- package/dist/components/SignUp/SignUpDefault/SignUpContext.js +0 -2
- package/dist/components/SignUp/SignUpDefault/SignUpForm.d.ts +0 -1
- package/dist/components/SignUp/SignUpDefault/SignUpForm.js +0 -310
- package/dist/components/SignUp/SignUpForm.d.ts +0 -1
- package/dist/components/SignUp/SignUpForm.js +0 -284
- package/dist/components/SignUp/SignUpKYC/CaptureIdDocument.d.ts +0 -1
- package/dist/components/SignUp/SignUpKYC/CaptureIdDocument.js +0 -198
- package/dist/components/SignUp/SignUpKYC/CaptureSelfie.d.ts +0 -1
- package/dist/components/SignUp/SignUpKYC/CaptureSelfie.js +0 -251
- package/dist/components/SignUp/SignUpKYC/ImageUploader.d.ts +0 -10
- package/dist/components/SignUp/SignUpKYC/ImageUploader.js +0 -42
- package/dist/components/SignUp/SignUpKYC/PersonOverlayDesktop.d.ts +0 -7
- package/dist/components/SignUp/SignUpKYC/PersonOverlayDesktop.js +0 -9
- package/dist/components/SignUp/SignUpKYC/SignUpFormKYC.d.ts +0 -1
- package/dist/components/SignUp/SignUpKYC/SignUpFormKYC.js +0 -464
- package/dist/components/SignUp/SignUpKYC/useImageUploader.d.ts +0 -11
- package/dist/components/SignUp/SignUpKYC/useImageUploader.js +0 -20
- package/dist/components/SignUp/SignUpKYC/utils.d.ts +0 -9
- package/dist/components/SignUp/SignUpKYC/utils.js +0 -79
- package/dist/components/SignUp/SignUpPagcor/CaptureIdDocument.d.ts +0 -1
- package/dist/components/SignUp/SignUpPagcor/CaptureIdDocument.js +0 -198
- package/dist/components/SignUp/SignUpPagcor/CaptureSelfie.d.ts +0 -1
- package/dist/components/SignUp/SignUpPagcor/CaptureSelfie.js +0 -251
- package/dist/components/SignUp/SignUpPagcor/ImageUploader.d.ts +0 -10
- package/dist/components/SignUp/SignUpPagcor/ImageUploader.js +0 -41
- package/dist/components/SignUp/SignUpPagcor/SignUpFormPagcor.d.ts +0 -1
- package/dist/components/SignUp/SignUpPagcor/SignUpFormPagcor.js +0 -429
- package/dist/components/SignUp/SignUpPagcor/SignUpPagcor.lazy.d.ts +0 -13
- package/dist/components/SignUp/SignUpPagcor/SignUpPagcor.lazy.js +0 -26
- package/dist/components/SignUp/SignUpPagcor/SignUpPagcorContext.d.ts +0 -7
- package/dist/components/SignUp/SignUpPagcor/SignUpPagcorContext.js +0 -2
- package/dist/components/SignUp/SignUpPagcor/useImageUploader.d.ts +0 -11
- package/dist/components/SignUp/SignUpPagcor/useImageUploader.js +0 -20
- package/dist/components/shared/IdDocumentField.client.d.ts +0 -25
- package/dist/components/shared/IdDocumentField.client.js +0 -204
- package/dist/components/shared/IdDocumentField.d.ts +0 -2
- package/dist/components/shared/IdDocumentField.js +0 -11
- package/dist/components/shared/SelfieField.client.d.ts +0 -20
- package/dist/components/shared/SelfieField.client.js +0 -327
- package/dist/components/shared/SelfieField.d.ts +0 -2
- package/dist/components/shared/SelfieField.js +0 -11
- package/dist/constants/BranchCode.d.ts +0 -4
- package/dist/constants/BranchCode.js +0 -42
- package/dist/constants/Branches.d.ts +0 -2
- package/dist/constants/Branches.js +0 -42
- package/dist/handlers/postTransformIdFrontImage.d.ts +0 -3
- package/dist/handlers/postTransformIdFrontImage.js +0 -67
- package/dist/handlers/postTransformSelfieImage.d.ts +0 -3
- package/dist/handlers/postTransformSelfieImage.js +0 -71
- package/dist/handlers.d.ts +0 -43
- package/dist/handlers.js +0 -297
- package/dist/icons/BellRingIcon.d.ts +0 -2
- package/dist/icons/BellRingIcon.js +0 -4
- package/dist/images/game-providers/ALPHACHINKO.png +0 -0
- package/dist/images/responsible-gaming-yellow.png +0 -0
- package/dist/third-parties/FacebookPixel/FacebookPixel.d.ts +0 -4
- package/dist/third-parties/FacebookPixel/FacebookPixel.js +0 -4
- package/dist/third-parties/FacebookPixel/api.d.ts +0 -0
- package/dist/third-parties/FacebookPixel/api.js +0 -1
- package/dist/third-parties/FacebookPixel/index.d.ts +0 -1
- package/dist/third-parties/FacebookPixel/index.js +0 -1
- package/dist/third-parties/GoogleRecaptcha/GoogleRecaptcha.d.ts +0 -4
- package/dist/third-parties/GoogleRecaptcha/GoogleRecaptcha.js +0 -4
- package/dist/third-parties/GoogleRecaptcha/api.d.ts +0 -0
- package/dist/third-parties/GoogleRecaptcha/api.js +0 -1
- package/dist/third-parties/GoogleRecaptcha/index.d.ts +0 -1
- package/dist/third-parties/GoogleRecaptcha/index.js +0 -1
- package/dist/third-parties/index.d.ts +0 -2
- package/dist/third-parties/index.js +0 -2
- package/dist/utils/dataUrlToBlob.d.ts +0 -1
- package/dist/utils/dataUrlToBlob.js +0 -11
- package/dist/utils/gamesAvailable3pmTo3am.d.ts +0 -1
- package/dist/utils/gamesAvailable3pmTo3am.js +0 -1
- package/dist/utils/getGameName.d.ts +0 -1
- package/dist/utils/getGameName.js +0 -6
- package/dist/utils/getLocaleInfo.d.ts +0 -79
- package/dist/utils/getLocaleInfo.js +0 -175
- package/dist/utils/isBetween3amAnd3pm.d.ts +0 -1
- package/dist/utils/isBetween3amAnd3pm.js +0 -5
- package/dist/utils/resizeImageSize.d.ts +0 -2
- package/dist/utils/resizeImageSize.js +0 -11
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import type { Deposit } from '../../../../types';
|
|
2
|
-
export type UseOnlineBankDepositReturn = ReturnType<typeof useOnlineBankDeposit>;
|
|
3
|
-
export declare function useOnlineBankDeposit(): {
|
|
4
|
-
view: "form" | "vca";
|
|
5
|
-
status: "waiting" | "processing" | "failed" | "verification-waiting" | "verification-processing" | "verification-failed" | "verification-success";
|
|
6
|
-
verify: () => void;
|
|
7
|
-
reset: () => void;
|
|
8
|
-
deposit: Deposit | null;
|
|
9
|
-
generateVCA: (input: {
|
|
10
|
-
amount: string;
|
|
11
|
-
promo?: string | null;
|
|
12
|
-
}) => void;
|
|
13
|
-
};
|
package/dist/components/DepositWithdrawal/Deposit__legacy/OnlineBankDeposit/useOnlineBankDeposit.js
DELETED
|
@@ -1,81 +0,0 @@
|
|
|
1
|
-
import { useEffect, useState } from 'react';
|
|
2
|
-
import invariant from 'tiny-invariant';
|
|
3
|
-
import { useShallow } from 'zustand/shallow';
|
|
4
|
-
import { useCreateOnlineBankDepositMutation } from '../../../../client/hooks/useCreateOnlineBankDepositMutation.js';
|
|
5
|
-
import { useDepositQuery } from '../../../../client/hooks/useDepositQuery.js';
|
|
6
|
-
import { useGlobalStore } from '../../../../client/hooks/useGlobalStore.js';
|
|
7
|
-
import { useMemberVerificationQuery } from '../../../../client/hooks/useMemberVerificationQuery.js';
|
|
8
|
-
export function useOnlineBankDeposit() {
|
|
9
|
-
const globalStore = useGlobalStore(useShallow((ctx) => ({
|
|
10
|
-
kycVerificationStatus: ctx.kycVerificationStatus,
|
|
11
|
-
})));
|
|
12
|
-
const verificationQuery = useMemberVerificationQuery();
|
|
13
|
-
const verificationStatus = verificationQuery.data?.status ?? 'UNVERIFIED';
|
|
14
|
-
const [deposit, setDeposit] = useState(null);
|
|
15
|
-
const [status, setStatus] = useState('waiting');
|
|
16
|
-
const view = status === 'verification-failed' ||
|
|
17
|
-
status === 'verification-waiting' ||
|
|
18
|
-
status === 'verification-success' ||
|
|
19
|
-
status === 'verification-processing'
|
|
20
|
-
? 'vca'
|
|
21
|
-
: 'form';
|
|
22
|
-
const mutation = useCreateOnlineBankDepositMutation({
|
|
23
|
-
onMutate() {
|
|
24
|
-
setStatus('processing');
|
|
25
|
-
},
|
|
26
|
-
onSuccess(data) {
|
|
27
|
-
invariant(data.vca);
|
|
28
|
-
setStatus('verification-waiting');
|
|
29
|
-
setDeposit(data);
|
|
30
|
-
},
|
|
31
|
-
onError() {
|
|
32
|
-
setStatus('failed');
|
|
33
|
-
},
|
|
34
|
-
});
|
|
35
|
-
const generateVCA = (input) => {
|
|
36
|
-
//handle new kyc process
|
|
37
|
-
if (verificationStatus === 'PENDING' ||
|
|
38
|
-
verificationStatus === 'UNVERIFIED' ||
|
|
39
|
-
verificationStatus === 'REJECTED' ||
|
|
40
|
-
verificationStatus === 'CREATED') {
|
|
41
|
-
globalStore.kycVerificationStatus.setOpen(true);
|
|
42
|
-
return;
|
|
43
|
-
}
|
|
44
|
-
else {
|
|
45
|
-
mutation.mutate({
|
|
46
|
-
amount: input.amount,
|
|
47
|
-
promo: input.promo ?? undefined,
|
|
48
|
-
});
|
|
49
|
-
}
|
|
50
|
-
};
|
|
51
|
-
const query = useDepositQuery(deposit?.id, {
|
|
52
|
-
enabled: !!deposit,
|
|
53
|
-
refetchInterval: 5000,
|
|
54
|
-
});
|
|
55
|
-
useEffect(() => {
|
|
56
|
-
if (query.data?.status === 'APPROVED' ||
|
|
57
|
-
query.data?.status === 'CONFIRMED') {
|
|
58
|
-
setStatus('verification-success');
|
|
59
|
-
}
|
|
60
|
-
if (query.data?.status === 'CANCELLED' ||
|
|
61
|
-
query.data?.status === 'REJECTED' ||
|
|
62
|
-
query.data?.status === 'FAILED') {
|
|
63
|
-
setStatus('verification-failed');
|
|
64
|
-
}
|
|
65
|
-
}, [query.data?.status]);
|
|
66
|
-
const reset = () => {
|
|
67
|
-
setDeposit(null);
|
|
68
|
-
setStatus('waiting');
|
|
69
|
-
};
|
|
70
|
-
const verify = () => {
|
|
71
|
-
setStatus('verification-processing');
|
|
72
|
-
};
|
|
73
|
-
return {
|
|
74
|
-
view,
|
|
75
|
-
status,
|
|
76
|
-
verify,
|
|
77
|
-
reset,
|
|
78
|
-
deposit,
|
|
79
|
-
generateVCA,
|
|
80
|
-
};
|
|
81
|
-
}
|
package/dist/components/DepositWithdrawal/Deposit__legacy/PisoPayDeposit/PisoPayDeposit.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function PisoPayDeposit(): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,180 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
|
-
import { zodResolver } from '@hookform/resolvers/zod';
|
|
3
|
-
import { ObjectId } from '@opexa/object-id';
|
|
4
|
-
import Link from 'next/link';
|
|
5
|
-
import { useEffect, useState } from 'react';
|
|
6
|
-
import { Controller, useForm } from 'react-hook-form';
|
|
7
|
-
import invariant from 'tiny-invariant';
|
|
8
|
-
import { z } from 'zod';
|
|
9
|
-
import { useShallow } from 'zustand/shallow';
|
|
10
|
-
import { useAvailablePromosQuery } from '../../../../client/hooks/useAvailablePromosQuery.js';
|
|
11
|
-
import { useCreatePisoPayDepositMutation } from '../../../../client/hooks/useCreatePisoPayDepositMutation.js';
|
|
12
|
-
import { useDepositsCountQuery } from '../../../../client/hooks/useDepositsCountQuery.js';
|
|
13
|
-
import { useDisclosure } from '../../../../client/hooks/useDisclosure.js';
|
|
14
|
-
import { useGlobalStore } from '../../../../client/hooks/useGlobalStore.js';
|
|
15
|
-
import { useMemberVerificationQuery } from '../../../../client/hooks/useMemberVerificationQuery.js';
|
|
16
|
-
import { usePaymentSettingsQuery } from '../../../../client/hooks/usePaymentSettingsQuery.js';
|
|
17
|
-
import { AlertCircleIcon } from '../../../../icons/AlertCircleIcon.js';
|
|
18
|
-
import { SpinnerIcon } from '../../../../icons/SpinnerIcon.js';
|
|
19
|
-
import { XIcon } from '../../../../icons/XIcon.js';
|
|
20
|
-
import { ObjectType } from '../../../../services/ObjectType.js';
|
|
21
|
-
import { AlertDialog } from '../../../../ui/AlertDialog/index.js';
|
|
22
|
-
import { Button } from '../../../../ui/Button/index.js';
|
|
23
|
-
import { Field } from '../../../../ui/Field/index.js';
|
|
24
|
-
import { Portal } from '../../../../ui/Portal/index.js';
|
|
25
|
-
import { getQueryClient } from '../../../../utils/getQueryClient.js';
|
|
26
|
-
import { parseDecimal } from '../../../../utils/parseDecimal.js';
|
|
27
|
-
import { getDepositsCountQueryKey } from '../../../../utils/queryKeys.js';
|
|
28
|
-
import { AmountChoices } from '../../AmountChoices.js';
|
|
29
|
-
import { useDepositWithdrawalPropsContext } from '../../DepositWithdrawalContext.js';
|
|
30
|
-
import { explainError } from '../../utils.js';
|
|
31
|
-
import { AvailablePromos } from '../AvailablePromos.js';
|
|
32
|
-
export function PisoPayDeposit() {
|
|
33
|
-
const depositWithdrawalProps = useDepositWithdrawalPropsContext();
|
|
34
|
-
const disclosure = useDisclosure();
|
|
35
|
-
const globalStore = useGlobalStore(useShallow((ctx) => ({
|
|
36
|
-
depositWithdrawal: ctx.depositWithdrawal,
|
|
37
|
-
kycVerificationStatus: ctx.kycVerificationStatus,
|
|
38
|
-
})));
|
|
39
|
-
const verificationQuery = useMemberVerificationQuery();
|
|
40
|
-
const verificationStatus = verificationQuery.data?.status ?? 'UNVERIFIED';
|
|
41
|
-
const [status, setStatus] = useState('waiting');
|
|
42
|
-
const createDepositMutation = useCreatePisoPayDepositMutation({
|
|
43
|
-
onMutate() {
|
|
44
|
-
disclosure.setOpen(true);
|
|
45
|
-
setStatus('processing');
|
|
46
|
-
},
|
|
47
|
-
onSuccess(data) {
|
|
48
|
-
const queryClient = getQueryClient();
|
|
49
|
-
invariant(data.checkoutUrl);
|
|
50
|
-
window.open(data.checkoutUrl, '_blank', 'noopener,noreferrer');
|
|
51
|
-
queryClient.invalidateQueries({ queryKey: getDepositsCountQueryKey() });
|
|
52
|
-
setStatus('success');
|
|
53
|
-
},
|
|
54
|
-
onError() {
|
|
55
|
-
setStatus('failed');
|
|
56
|
-
},
|
|
57
|
-
});
|
|
58
|
-
const depositsCountQuery = useDepositsCountQuery();
|
|
59
|
-
const depositsCount = depositsCountQuery.data ?? 0;
|
|
60
|
-
const paymentSettingsQuery = usePaymentSettingsQuery();
|
|
61
|
-
const paymentSettings = paymentSettingsQuery.data;
|
|
62
|
-
const gatewaySettings = paymentSettings?.pisoPayDepositGatewaySettings;
|
|
63
|
-
const maximumAmount = parseDecimal(gatewaySettings?.maximumAmount, 0);
|
|
64
|
-
const minimumAmount = depositsCount <= 0
|
|
65
|
-
? parseDecimal(paymentSettingsQuery.data?.minimumFirstDepositAmount, 0)
|
|
66
|
-
: parseDecimal(gatewaySettings?.minimumAmount, 0);
|
|
67
|
-
const promosQuery = useAvailablePromosQuery();
|
|
68
|
-
const promos = promosQuery.data ?? [];
|
|
69
|
-
const definition = z
|
|
70
|
-
.object({
|
|
71
|
-
amount: z.string().superRefine((val, ctx) => {
|
|
72
|
-
const n = parseDecimal(val, 0);
|
|
73
|
-
if (val.includes('.')) {
|
|
74
|
-
ctx.addIssue({
|
|
75
|
-
code: z.ZodIssueCode.custom,
|
|
76
|
-
message: 'Amount must be a whole number',
|
|
77
|
-
});
|
|
78
|
-
return;
|
|
79
|
-
}
|
|
80
|
-
if (n < minimumAmount) {
|
|
81
|
-
ctx.addIssue({
|
|
82
|
-
type: 'number',
|
|
83
|
-
code: z.ZodIssueCode.too_small,
|
|
84
|
-
inclusive: true,
|
|
85
|
-
minimum: minimumAmount,
|
|
86
|
-
message: `Please enter ${minimumAmount.toLocaleString()} or more to proceed with your deposit.`,
|
|
87
|
-
});
|
|
88
|
-
}
|
|
89
|
-
if (n > maximumAmount) {
|
|
90
|
-
ctx.addIssue({
|
|
91
|
-
type: 'number',
|
|
92
|
-
code: z.ZodIssueCode.too_big,
|
|
93
|
-
inclusive: true,
|
|
94
|
-
maximum: maximumAmount,
|
|
95
|
-
message: `Maximum amount is ${maximumAmount.toLocaleString()}`,
|
|
96
|
-
});
|
|
97
|
-
}
|
|
98
|
-
}),
|
|
99
|
-
promo: z.string().optional().nullable(),
|
|
100
|
-
})
|
|
101
|
-
.superRefine((value, ctx) => {
|
|
102
|
-
const promo = promos.find((o) => o.id === value.promo);
|
|
103
|
-
const promoMinAmount = parseDecimal(promo?.minimumDepositAmount, 0);
|
|
104
|
-
const promoMaxAmount = parseDecimal(promo?.maximumDepositAmount, 0);
|
|
105
|
-
const amount = parseDecimal(value.amount, 0);
|
|
106
|
-
if (promo && amount < promoMinAmount) {
|
|
107
|
-
ctx.addIssue({
|
|
108
|
-
path: ['amount'],
|
|
109
|
-
code: z.ZodIssueCode.custom,
|
|
110
|
-
message: `Minimum amount for this promo is ${promoMinAmount.toLocaleString()}`,
|
|
111
|
-
});
|
|
112
|
-
}
|
|
113
|
-
if (promo && amount > promoMaxAmount) {
|
|
114
|
-
ctx.addIssue({
|
|
115
|
-
path: ['amount'],
|
|
116
|
-
code: z.ZodIssueCode.custom,
|
|
117
|
-
message: `Maximum amount for this promo is ${promoMaxAmount}`,
|
|
118
|
-
});
|
|
119
|
-
}
|
|
120
|
-
});
|
|
121
|
-
const form = useForm({
|
|
122
|
-
mode: 'all',
|
|
123
|
-
resolver: zodResolver(definition),
|
|
124
|
-
defaultValues: {
|
|
125
|
-
amount: '0',
|
|
126
|
-
promo: globalStore.depositWithdrawal.promo ?? null,
|
|
127
|
-
},
|
|
128
|
-
});
|
|
129
|
-
useEffect(() => {
|
|
130
|
-
if (minimumAmount) {
|
|
131
|
-
form.reset({
|
|
132
|
-
amount: minimumAmount.toString(),
|
|
133
|
-
promo: form.getValues('promo') ?? null,
|
|
134
|
-
});
|
|
135
|
-
}
|
|
136
|
-
}, [form, minimumAmount]);
|
|
137
|
-
return (_jsxs("form", { onSubmit: form.handleSubmit(async (data) => {
|
|
138
|
-
if (verificationStatus === 'PENDING' ||
|
|
139
|
-
verificationStatus === 'UNVERIFIED' ||
|
|
140
|
-
verificationStatus === 'REJECTED' ||
|
|
141
|
-
verificationStatus === 'CREATED') {
|
|
142
|
-
globalStore.kycVerificationStatus.setOpen(true);
|
|
143
|
-
return;
|
|
144
|
-
}
|
|
145
|
-
else {
|
|
146
|
-
const id = ObjectId.generate(ObjectType.Deposit).toString();
|
|
147
|
-
const domain = window.location.hostname === 'localhost'
|
|
148
|
-
? 'https://opexa.io'
|
|
149
|
-
: window.location.origin;
|
|
150
|
-
createDepositMutation.reset();
|
|
151
|
-
createDepositMutation.mutate({
|
|
152
|
-
id,
|
|
153
|
-
amount: data.amount.toString(),
|
|
154
|
-
redirectionUrl: `${domain}`,
|
|
155
|
-
...(data.promo && {
|
|
156
|
-
promo: data.promo,
|
|
157
|
-
}),
|
|
158
|
-
});
|
|
159
|
-
}
|
|
160
|
-
}), noValidate: true, children: [_jsxs(Field.Root, { invalid: !!form.formState.errors.amount, className: "mt-3xl", children: [_jsx(Field.Label, { children: "Enter the amount you want to deposit" }), _jsx(Field.Input, { type: "number", ...form.register('amount') }), _jsx(Field.ErrorText, { children: form.formState.errors.amount?.message })] }), _jsx(AmountChoices, { value: parseDecimal(form.watch('amount').trim().replace(/,/g, ''), 0), onChange: (value) => {
|
|
161
|
-
form.setValue('amount', value.toString(), {
|
|
162
|
-
shouldTouch: true,
|
|
163
|
-
shouldDirty: true,
|
|
164
|
-
shouldValidate: true,
|
|
165
|
-
});
|
|
166
|
-
}, min: minimumAmount, max: maximumAmount, className: "mt-lg" }), _jsx(Controller, { control: form.control, name: "promo", render: (o) => (_jsx(AvailablePromos, { value: o.field.value, onChange: (value) => {
|
|
167
|
-
o.field.onChange(value);
|
|
168
|
-
globalStore.depositWithdrawal.setPromo(null);
|
|
169
|
-
}, className: "mt-3xl" })) }), _jsx(Button, { type: "submit", className: "mt-3xl", disabled: createDepositMutation.isPending, children: "Deposit" }), depositWithdrawalProps.hasPrivacyPolicyAndTermsOfUse && (_jsxs("p", { className: "mt-lg text-text-tertiary-600 text-xs", children: ["By depositing, you agree to our", ' ', _jsx(Link, { href: depositWithdrawalProps.termsOfUseUrl ?? '/terms-of-use', onClick: () => globalStore.depositWithdrawal.setOpen(false), className: "text-text-warning-primary-600 underline underline-offset-2", children: "Terms of Use" }), ' ', "and", ' ', _jsx(Link, { href: depositWithdrawalProps.privacyPolicyUrl ?? '/privacy-policy', onClick: () => globalStore.depositWithdrawal.setOpen(false), className: "text-text-warning-primary-600 underline underline-offset-2", children: "Privacy Policy" }), "."] })), _jsx(AlertDialog.Root, { open: disclosure.open, onOpenChange: (details) => {
|
|
170
|
-
disclosure.setOpen(details.open);
|
|
171
|
-
if (!details.open) {
|
|
172
|
-
setStatus('waiting');
|
|
173
|
-
form.reset();
|
|
174
|
-
}
|
|
175
|
-
}, lazyMount: true, unmountOnExit: true, closeOnEscape: false, closeOnInteractOutside: false, children: _jsxs(Portal, { children: [_jsx(AlertDialog.Backdrop, { className: "!z-[calc(var(--z-dialog)+2)]" }), _jsx(AlertDialog.Positioner, { className: "!z-[calc(var(--z-dialog)+3)]", children: _jsxs(AlertDialog.Content, { children: [_jsx(AlertDialog.CloseTrigger, { children: _jsx(XIcon, {}) }), _jsxs(AlertDialog.Header, { children: [status === 'processing' && (_jsx(SpinnerIcon, { className: "size-12 text-text-brand-primary-600" })), status === 'success' && (_jsx("div", { className: "flex size-12 items-center justify-center rounded-full bg-bg-success-secondary text-text-featured-icon-light-success", children: _jsx(AlertCircleIcon, {}) })), status === 'failed' && (_jsx("div", { className: "flex size-12 items-center justify-center rounded-full bg-bg-error-secondary text-text-featured-icon-light-error", children: _jsx(AlertCircleIcon, {}) }))] }), _jsxs(AlertDialog.Body, { children: [_jsxs(AlertDialog.Title, { children: [status === 'processing' && 'Processing Deposit', status === 'success' && 'Deposit Successful', status === 'failed' && 'Deposit Failed'] }), _jsxs(AlertDialog.Description, { children: [status === 'processing' &&
|
|
176
|
-
"We're verifying your account and amount. Please hold a moment.", status === 'success' && (_jsxs(_Fragment, { children: ["Your deposit has been successfully processed. ", _jsx("br", {}), " If you are not redirected automatically, click", ' ', !!createDepositMutation.data?.checkoutUrl && (_jsx("a", { href: createDepositMutation.data?.checkoutUrl, target: "_blank", rel: "noopener noreferrer", className: "text-text-brand underline underline-offset-2", children: "here" })), "."] })), status === 'failed' &&
|
|
177
|
-
explainError(createDepositMutation?.error?.name)] })] }), (status === 'failed' || status === 'success') && (_jsx(AlertDialog.Footer, { children: _jsx(AlertDialog.Context, { children: (api) => (_jsx(Button, { onClick: () => {
|
|
178
|
-
api.setOpen(false);
|
|
179
|
-
}, children: status === 'failed' ? 'Try Again' : 'Ok' })) }) }))] }) })] }) })] }));
|
|
180
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function QRPHDeposit(): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { QRPHDepositAlert } from './QRPHDepositAlert.js';
|
|
3
|
-
import { QRPHDepositContext } from './QRPHDepositContext.js';
|
|
4
|
-
import { QRPHDepositDetails } from './QRPHDepositDetails.js';
|
|
5
|
-
import { QRPHDepositForm } from './QRPHDepositForm.js';
|
|
6
|
-
import { useQRPHDeposit } from './useQRPHDeposit.js';
|
|
7
|
-
export function QRPHDeposit() {
|
|
8
|
-
const context = useQRPHDeposit();
|
|
9
|
-
return (_jsxs(QRPHDepositContext, { value: context, children: [_jsx(QRPHDepositForm, {}), _jsx(QRPHDepositDetails, {}), _jsx(QRPHDepositAlert, {})] }));
|
|
10
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function QRPHDepositAlert(): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,99 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { AlertCircleIcon } from '../../../../icons/AlertCircleIcon.js';
|
|
3
|
-
import { SpinnerIcon } from '../../../../icons/SpinnerIcon.js';
|
|
4
|
-
import { XIcon } from '../../../../icons/XIcon.js';
|
|
5
|
-
import { AlertDialog } from '../../../../ui/AlertDialog/index.js';
|
|
6
|
-
import { Button } from '../../../../ui/Button/index.js';
|
|
7
|
-
import { Portal } from '../../../../ui/Portal/index.js';
|
|
8
|
-
import { useQRPHDepositContext } from './QRPHDepositContext.js';
|
|
9
|
-
export function QRPHDepositAlert() {
|
|
10
|
-
const context = useQRPHDepositContext();
|
|
11
|
-
const details = useDetails();
|
|
12
|
-
return (_jsx(AlertDialog.Root, { open: context.status !== 'waiting' &&
|
|
13
|
-
context.status !== 'verification-waiting', onOpenChange: (details) => {
|
|
14
|
-
if (!details.open) {
|
|
15
|
-
context.reset();
|
|
16
|
-
}
|
|
17
|
-
}, lazyMount: true, unmountOnExit: true, closeOnEscape: false, closeOnInteractOutside: false, children: _jsxs(Portal, { children: [_jsx(AlertDialog.Backdrop, { className: "!z-[calc(var(--z-dialog)+2)]" }), _jsx(AlertDialog.Positioner, { className: "!z-[calc(var(--z-dialog)+3)]", children: _jsxs(AlertDialog.Content, { children: [_jsx(AlertDialog.CloseTrigger, { disabled: details.type === 'loading', children: _jsx(XIcon, {}) }), _jsxs(AlertDialog.Header, { children: [details.type === 'loading' && (_jsx(SpinnerIcon, { className: "size-12 text-text-brand-primary-600" })), details.type === 'success' && (_jsx("div", { className: "flex size-12 items-center justify-center rounded-full bg-bg-success-secondary text-text-featured-icon-light-success", children: _jsx(AlertCircleIcon, {}) })), details.type === 'erorr' && (_jsx("div", { className: "flex size-12 items-center justify-center rounded-full bg-bg-error-secondary text-text-featured-icon-light-error", children: _jsx(AlertCircleIcon, {}) }))] }), _jsxs(AlertDialog.Body, { children: [_jsx(AlertDialog.Title, { children: details.title }), _jsx(AlertDialog.Description, { children: details.description })] }), (details.type === 'erorr' || details.type === 'success') && (_jsx(AlertDialog.Footer, { children: _jsx(AlertDialog.Context, { children: (api) => (_jsx(Button, { onClick: () => {
|
|
18
|
-
api.setOpen(false);
|
|
19
|
-
}, children: details.type === 'success' ? 'Ok' : 'Try Again' })) }) }))] }) })] }) }));
|
|
20
|
-
}
|
|
21
|
-
function useDetails() {
|
|
22
|
-
const context = useQRPHDepositContext();
|
|
23
|
-
const title = (() => {
|
|
24
|
-
let s = '';
|
|
25
|
-
if (context.status === 'processing') {
|
|
26
|
-
s = 'Processing Deposit';
|
|
27
|
-
}
|
|
28
|
-
else if (context.status === 'failed') {
|
|
29
|
-
s = 'Deposit Failed';
|
|
30
|
-
}
|
|
31
|
-
else if (context.status === 'verification-success') {
|
|
32
|
-
s = 'Deposit Successful';
|
|
33
|
-
}
|
|
34
|
-
else if (context.status === 'verification-processing') {
|
|
35
|
-
s = 'Verifying Deposit';
|
|
36
|
-
}
|
|
37
|
-
else if (context.status === 'verification-failed') {
|
|
38
|
-
if (context.deposit?.status === 'CANCELLED') {
|
|
39
|
-
s = 'Deposit Cancelled';
|
|
40
|
-
}
|
|
41
|
-
else if (context.deposit?.status === 'REJECTED') {
|
|
42
|
-
s = 'Deposit Rejected';
|
|
43
|
-
}
|
|
44
|
-
else {
|
|
45
|
-
s = 'Deposit Failed';
|
|
46
|
-
}
|
|
47
|
-
}
|
|
48
|
-
return s;
|
|
49
|
-
})();
|
|
50
|
-
const description = (() => {
|
|
51
|
-
let d = '';
|
|
52
|
-
if (context.status === 'processing') {
|
|
53
|
-
d = "We're verifying your account and amount. Please hold a moment.";
|
|
54
|
-
}
|
|
55
|
-
else if (context.status === 'failed') {
|
|
56
|
-
d =
|
|
57
|
-
'Something went wrong while processing your deposit. ' +
|
|
58
|
-
'Please try again or contact support.';
|
|
59
|
-
}
|
|
60
|
-
else if (context.status === 'verification-success') {
|
|
61
|
-
d = 'Your deposit has been successfully processed.';
|
|
62
|
-
}
|
|
63
|
-
else if (context.status === 'verification-processing') {
|
|
64
|
-
d = 'Your deposit is being processed.';
|
|
65
|
-
}
|
|
66
|
-
else if (context.status === 'verification-failed') {
|
|
67
|
-
if (context.deposit?.status === 'CANCELLED') {
|
|
68
|
-
d = 'Your deposit has been cancelled.';
|
|
69
|
-
}
|
|
70
|
-
else if (context.deposit?.status === 'REJECTED') {
|
|
71
|
-
d = 'Your deposit has been rejected.';
|
|
72
|
-
}
|
|
73
|
-
else if (context.deposit?.status === 'FAILED') {
|
|
74
|
-
d = context.deposit.error ?? 'Your deposit has failed.';
|
|
75
|
-
}
|
|
76
|
-
else {
|
|
77
|
-
d =
|
|
78
|
-
'Something went wrong while processing your deposit. ' +
|
|
79
|
-
'Please try again or contact support.';
|
|
80
|
-
}
|
|
81
|
-
}
|
|
82
|
-
return d;
|
|
83
|
-
})();
|
|
84
|
-
const type = (() => {
|
|
85
|
-
if (context.status === 'failed' ||
|
|
86
|
-
context.status === 'verification-failed') {
|
|
87
|
-
return 'erorr';
|
|
88
|
-
}
|
|
89
|
-
if (context.status === 'verification-success') {
|
|
90
|
-
return 'success';
|
|
91
|
-
}
|
|
92
|
-
return 'loading';
|
|
93
|
-
})();
|
|
94
|
-
return {
|
|
95
|
-
type,
|
|
96
|
-
title,
|
|
97
|
-
description,
|
|
98
|
-
};
|
|
99
|
-
}
|
package/dist/components/DepositWithdrawal/Deposit__legacy/QRPHDeposit/QRPHDepositContext.d.ts
DELETED
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
export declare const QRPHDepositContext: (props: {
|
|
2
|
-
value: {
|
|
3
|
-
view: "form" | "qrCode";
|
|
4
|
-
status: "waiting" | "processing" | "failed" | "verification-waiting" | "verification-processing" | "verification-failed" | "verification-success";
|
|
5
|
-
verify: () => void;
|
|
6
|
-
reset: () => void;
|
|
7
|
-
deposit: import("../../../../types").Deposit | null;
|
|
8
|
-
generateQRCode: (input: {
|
|
9
|
-
amount: string;
|
|
10
|
-
promo?: string | null;
|
|
11
|
-
}) => void;
|
|
12
|
-
};
|
|
13
|
-
} & {
|
|
14
|
-
children?: import("react").ReactNode | undefined;
|
|
15
|
-
}) => React.ReactNode, useQRPHDepositContext: () => {
|
|
16
|
-
view: "form" | "qrCode";
|
|
17
|
-
status: "waiting" | "processing" | "failed" | "verification-waiting" | "verification-processing" | "verification-failed" | "verification-success";
|
|
18
|
-
verify: () => void;
|
|
19
|
-
reset: () => void;
|
|
20
|
-
deposit: import("../../../../types").Deposit | null;
|
|
21
|
-
generateQRCode: (input: {
|
|
22
|
-
amount: string;
|
|
23
|
-
promo?: string | null;
|
|
24
|
-
}) => void;
|
|
25
|
-
};
|
package/dist/components/DepositWithdrawal/Deposit__legacy/QRPHDeposit/QRPHDepositDetails.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function QRPHDepositDetails(): import("react/jsx-runtime").JSX.Element | null;
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { QrCode02Icon } from '../../../../icons/QrCode02Icon.js';
|
|
3
|
-
import { XIcon } from '../../../../icons/XIcon.js';
|
|
4
|
-
import { Button } from '../../../../ui/Button/index.js';
|
|
5
|
-
import { Dialog } from '../../../../ui/Dialog/index.js';
|
|
6
|
-
import { Portal } from '../../../../ui/Portal/index.js';
|
|
7
|
-
import { useQRPHDepositContext } from './QRPHDepositContext.js';
|
|
8
|
-
import { QRPHQRCode } from './QRPHQRCode.js';
|
|
9
|
-
export function QRPHDepositDetails() {
|
|
10
|
-
const context = useQRPHDepositContext();
|
|
11
|
-
if (context.view !== 'qrCode')
|
|
12
|
-
return null;
|
|
13
|
-
return (_jsxs("div", { className: "rounded-lg bg-bg-primary-alt p-2xl", children: [_jsx("p", { className: "text-center font-semibold text-lg lg:text-xl", children: "QR Code" }), _jsx("p", { className: "mt-3 text-center text-sm text-text-secondary-700 lg:text-base", children: "Scan the QR code below with your banking app, or upload it to complete your deposit." }), _jsx(QRPHQRCode, { qrCodeString: context.deposit?.qrCode ?? '' }), _jsx("div", { className: "mt-6 flex flex-col gap-4 lg:flex-row", children: _jsx(Button, { size: "sm", variant: "outline", colorScheme: "gray", onClick: context.reset, children: "Generate New QR Code" }) }), _jsx(Instruction, {})] }));
|
|
14
|
-
}
|
|
15
|
-
function Instruction() {
|
|
16
|
-
return (_jsxs("p", { className: "mt-6 text-center text-text-tertiary-600 text-xs", children: ["Need help using the QR Code?", ' ', _jsxs(Dialog.Root, { lazyMount: true, unmountOnExit: true, children: [_jsx(Dialog.Trigger, { className: "text-text-warning-primary-600", children: "See instructions" }), _jsxs(Portal, { children: [_jsx(Dialog.Backdrop, { className: "!z-[calc(var(--z-dialog)+2)]" }), _jsx(Dialog.Positioner, { className: "!z-[calc(var(--z-dialog)+3)] flex items-center justify-center", children: _jsxs(Dialog.Content, { className: "mx-auto w-[calc(100%-2rem)] overflow-y-auto rounded-lg p-4xl lg:w-[33.625rem]", children: [_jsx(Dialog.CloseTrigger, { children: _jsx(XIcon, {}) }), _jsxs(Dialog.Body, { children: [_jsxs("div", { className: "flex items-center gap-xl", children: [_jsx("div", { className: "flex size-11 items-center justify-center rounded-lg border border-border-primary text-gray-700 text-text-secondary-700 shadow-xs", children: _jsx(QrCode02Icon, { className: "size-6" }) }), _jsx(Dialog.Title, { className: "font-semibold text-lg", children: "How to Use the QR Code for Payment" })] }), _jsx(Dialog.Description, { className: "mt-5", children: "Follow these simple steps to complete your transaction:" }), _jsxs("ol", { className: "mt-3 list-inside list-decimal space-y-3", children: [_jsx("li", { children: "Open your preferred banking or EMI mobile app and select 'Transfer Money' or 'Pay via QR'" }), _jsx("li", { children: "Scan or upload the generated QR Ph code. If prompted by the app, enter the amount to be sent." }), _jsx("li", { children: "Proceed with the transfer or payment." })] })] })] }) })] })] })] }));
|
|
17
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function QRPHDepositForm(): import("react/jsx-runtime").JSX.Element | null;
|
|
@@ -1,116 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { zodResolver } from '@hookform/resolvers/zod';
|
|
3
|
-
import Link from 'next/link';
|
|
4
|
-
import { useEffect } from 'react';
|
|
5
|
-
import { Controller, useForm } from 'react-hook-form';
|
|
6
|
-
import { z } from 'zod';
|
|
7
|
-
import { useShallow } from 'zustand/shallow';
|
|
8
|
-
import { useAvailablePromosQuery } from '../../../../client/hooks/useAvailablePromosQuery.js';
|
|
9
|
-
import { useDepositsCountQuery } from '../../../../client/hooks/useDepositsCountQuery.js';
|
|
10
|
-
import { useGlobalStore } from '../../../../client/hooks/useGlobalStore.js';
|
|
11
|
-
import { usePaymentSettingsQuery } from '../../../../client/hooks/usePaymentSettingsQuery.js';
|
|
12
|
-
import { Button } from '../../../../ui/Button/index.js';
|
|
13
|
-
import { Field } from '../../../../ui/Field/index.js';
|
|
14
|
-
import { parseDecimal } from '../../../../utils/parseDecimal.js';
|
|
15
|
-
import { AmountChoices } from '../../AmountChoices.js';
|
|
16
|
-
import { useDepositWithdrawalPropsContext } from '../../DepositWithdrawalContext.js';
|
|
17
|
-
import { AvailablePromos } from '../AvailablePromos.js';
|
|
18
|
-
import { useQRPHDepositContext } from './QRPHDepositContext.js';
|
|
19
|
-
export function QRPHDepositForm() {
|
|
20
|
-
const depositWithdrawalProps = useDepositWithdrawalPropsContext();
|
|
21
|
-
const globalStore = useGlobalStore(useShallow((ctx) => ({
|
|
22
|
-
depositWithdrawal: ctx.depositWithdrawal,
|
|
23
|
-
})));
|
|
24
|
-
const context = useQRPHDepositContext();
|
|
25
|
-
const depositsCountQuery = useDepositsCountQuery();
|
|
26
|
-
const depositsCount = depositsCountQuery.data ?? 0;
|
|
27
|
-
const paymentSettingsQuery = usePaymentSettingsQuery();
|
|
28
|
-
const paymentSettings = paymentSettingsQuery.data;
|
|
29
|
-
const gatewaySettings = paymentSettings?.qrphDepositGatewaySettings;
|
|
30
|
-
const maximumAmount = parseDecimal(gatewaySettings?.maximumAmount, 0);
|
|
31
|
-
const minimumAmount = depositsCount <= 0
|
|
32
|
-
? parseDecimal(paymentSettingsQuery.data?.minimumFirstDepositAmount, 0)
|
|
33
|
-
: parseDecimal(gatewaySettings?.minimumAmount, 0);
|
|
34
|
-
const promosQuery = useAvailablePromosQuery();
|
|
35
|
-
const promos = promosQuery.data ?? [];
|
|
36
|
-
const definition = z
|
|
37
|
-
.object({
|
|
38
|
-
amount: z.string().superRefine((val, ctx) => {
|
|
39
|
-
const n = parseDecimal(val, 0);
|
|
40
|
-
if (val.includes('.')) {
|
|
41
|
-
ctx.addIssue({
|
|
42
|
-
code: z.ZodIssueCode.custom,
|
|
43
|
-
message: 'Amount must be a whole number',
|
|
44
|
-
});
|
|
45
|
-
return;
|
|
46
|
-
}
|
|
47
|
-
if (n < minimumAmount) {
|
|
48
|
-
ctx.addIssue({
|
|
49
|
-
type: 'number',
|
|
50
|
-
code: z.ZodIssueCode.too_small,
|
|
51
|
-
inclusive: true,
|
|
52
|
-
minimum: minimumAmount,
|
|
53
|
-
message: `Please enter ${minimumAmount.toLocaleString()} or more to proceed with your deposit.`,
|
|
54
|
-
});
|
|
55
|
-
}
|
|
56
|
-
if (n > maximumAmount) {
|
|
57
|
-
ctx.addIssue({
|
|
58
|
-
type: 'number',
|
|
59
|
-
code: z.ZodIssueCode.too_big,
|
|
60
|
-
inclusive: true,
|
|
61
|
-
maximum: maximumAmount,
|
|
62
|
-
message: `Maximum amount is ${maximumAmount.toLocaleString()}`,
|
|
63
|
-
});
|
|
64
|
-
}
|
|
65
|
-
}),
|
|
66
|
-
promo: z.string().optional().nullable(),
|
|
67
|
-
})
|
|
68
|
-
.superRefine((value, ctx) => {
|
|
69
|
-
const promo = promos.find((o) => o.id === value.promo);
|
|
70
|
-
const promoMinAmount = parseDecimal(promo?.minimumDepositAmount, 0);
|
|
71
|
-
const promoMaxAmount = parseDecimal(promo?.maximumDepositAmount, 0);
|
|
72
|
-
const amount = parseDecimal(value.amount, 0);
|
|
73
|
-
if (promo && amount < promoMinAmount) {
|
|
74
|
-
ctx.addIssue({
|
|
75
|
-
path: ['amount'],
|
|
76
|
-
code: z.ZodIssueCode.custom,
|
|
77
|
-
message: `Minimum amount for this promo is ${promoMinAmount.toLocaleString()}`,
|
|
78
|
-
});
|
|
79
|
-
}
|
|
80
|
-
if (promo && amount > promoMaxAmount) {
|
|
81
|
-
ctx.addIssue({
|
|
82
|
-
path: ['amount'],
|
|
83
|
-
code: z.ZodIssueCode.custom,
|
|
84
|
-
message: `Maximum amount for this promo is ${promoMaxAmount}`,
|
|
85
|
-
});
|
|
86
|
-
}
|
|
87
|
-
});
|
|
88
|
-
const form = useForm({
|
|
89
|
-
mode: 'all',
|
|
90
|
-
resolver: zodResolver(definition),
|
|
91
|
-
defaultValues: {
|
|
92
|
-
amount: '0',
|
|
93
|
-
promo: globalStore.depositWithdrawal.promo ?? null,
|
|
94
|
-
},
|
|
95
|
-
});
|
|
96
|
-
useEffect(() => {
|
|
97
|
-
if (minimumAmount) {
|
|
98
|
-
form.reset({
|
|
99
|
-
amount: minimumAmount.toString(),
|
|
100
|
-
promo: form.getValues('promo') ?? null,
|
|
101
|
-
});
|
|
102
|
-
}
|
|
103
|
-
}, [form, minimumAmount]);
|
|
104
|
-
if (context.view !== 'form')
|
|
105
|
-
return null;
|
|
106
|
-
return (_jsxs("form", { onSubmit: form.handleSubmit(context.generateQRCode), noValidate: true, children: [_jsxs(Field.Root, { invalid: !!form.formState.errors.amount, className: "mt-3xl", children: [_jsx(Field.Label, { children: "Enter the amount you want to deposit" }), _jsx(Field.Input, { type: "number", ...form.register('amount') }), _jsx(Field.ErrorText, { children: form.formState.errors.amount?.message })] }), _jsx(AmountChoices, { value: parseDecimal(form.watch('amount'), 0), onChange: (value) => {
|
|
107
|
-
form.setValue('amount', value.toString(), {
|
|
108
|
-
shouldTouch: true,
|
|
109
|
-
shouldDirty: true,
|
|
110
|
-
shouldValidate: true,
|
|
111
|
-
});
|
|
112
|
-
}, min: minimumAmount, max: maximumAmount, className: "mt-lg" }), _jsx(Controller, { control: form.control, name: "promo", render: (o) => (_jsx(AvailablePromos, { value: o.field.value, onChange: (value) => {
|
|
113
|
-
o.field.onChange(value);
|
|
114
|
-
globalStore.depositWithdrawal.setPromo(null);
|
|
115
|
-
}, className: "mt-3xl" })) }), _jsx(Button, { type: "submit", className: "mt-3xl", children: "Deposit" }), depositWithdrawalProps.hasPrivacyPolicyAndTermsOfUse && (_jsxs("p", { className: "mt-lg text-text-tertiary-600 text-xs", children: ["By depositing, you agree to our", ' ', _jsx(Link, { href: depositWithdrawalProps.termsOfUseUrl ?? '/terms-of-use', onClick: () => globalStore.depositWithdrawal.setOpen(false), className: "text-text-warning-primary-600 underline underline-offset-2", children: "Terms of Use" }), ' ', "and", ' ', _jsx(Link, { href: depositWithdrawalProps.privacyPolicyUrl ?? '/privacy-policy', onClick: () => globalStore.depositWithdrawal.setOpen(false), className: "text-text-warning-primary-600 underline underline-offset-2", children: "Privacy Policy" }), "."] }))] }));
|
|
116
|
-
}
|