@opexa/portal-components 0.0.308 → 0.0.309

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (266) hide show
  1. package/dist/client/hooks/useCamera.js +2 -2
  2. package/dist/client/hooks/useControllableState.js +1 -1
  3. package/dist/client/hooks/useInfiniteQueryHelper.js +2 -3
  4. package/dist/client/hooks/useMarkGameAsFavoriteMutation.js +1 -2
  5. package/dist/client/hooks/useMobileNumberParser.js +1 -1
  6. package/dist/client/utils/recaptcha.d.ts +14 -0
  7. package/dist/client/utils/recaptcha.js +18 -0
  8. package/dist/components/Account/Account.lazy.js +5 -5
  9. package/dist/components/Account/account.recipe.js +4 -4
  10. package/dist/components/AccountInfo/AccountInfo.js +6 -6
  11. package/dist/components/AccountSecurity/AccountSecurity.js +6 -6
  12. package/dist/components/AccountVerification/AccountVerification.js +7 -7
  13. package/dist/components/Banner/Banner.js +1 -1
  14. package/dist/components/BetRecords/BetRecords.client.js +5 -5
  15. package/dist/components/Bonus/Bonus.client.js +2 -2
  16. package/dist/components/Bonuses/Bonuses.client.js +10 -10
  17. package/dist/components/Bonuses/BonusesTrigger.js +1 -1
  18. package/dist/components/Bonuses/ClaimSpotBonus.lazy.js +1 -1
  19. package/dist/components/Cashback/Cashback.client.js +2 -2
  20. package/dist/components/CustomPromo/CustomPromo.js +1 -1
  21. package/dist/components/DepositWithdrawal/Deposit/AvailablePromos.js +1 -1
  22. package/dist/components/DepositWithdrawal/Deposit/Deposit.js +2 -2
  23. package/dist/components/DepositWithdrawal/Deposit/GCashDeposit/GCashDeposit.js +2 -2
  24. package/dist/components/DepositWithdrawal/Deposit/LibanganDeposit/LibanganDeposit.js +2 -2
  25. package/dist/components/DepositWithdrawal/Deposit/MayaAppDeposit/MayaAppDeposit.js +2 -2
  26. package/dist/components/DepositWithdrawal/Deposit/MayaDeposit/MayaDeposit.js +2 -2
  27. package/dist/components/DepositWithdrawal/Deposit/OnlineBankDeposit/OnlineBankDepositAlert.js +1 -1
  28. package/dist/components/DepositWithdrawal/Deposit/OnlineBankDeposit/OnlineBankDepositDetails.js +2 -2
  29. package/dist/components/DepositWithdrawal/Deposit/OnlineBankDeposit/OnlineBankDepositForm.js +1 -1
  30. package/dist/components/DepositWithdrawal/Deposit/PisoPayDeposit/PisoPayDeposit.js +2 -2
  31. package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit/QRPHDepositAlert.js +1 -1
  32. package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit/QRPHDepositDetails.js +2 -2
  33. package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit/QRPHDepositForm.js +1 -1
  34. package/dist/components/DepositWithdrawal/DepositWithdrawal.lazy.js +2 -2
  35. package/dist/components/DepositWithdrawal/DepositWithdrawalTrigger.js +2 -2
  36. package/dist/components/DepositWithdrawal/HasPendingBonuses.js +1 -1
  37. package/dist/components/DepositWithdrawal/PaymentMethods.js +1 -1
  38. package/dist/components/DepositWithdrawal/Withdrawal/GCashWithdrawal/GCashWithdrawal.js +3 -3
  39. package/dist/components/DepositWithdrawal/Withdrawal/InstapayWithdrawal/InstapayWithdrawal.js +2 -4
  40. package/dist/components/DepositWithdrawal/Withdrawal/MayaAppWithdrawal/MayaAppWithdrawal.js +2 -2
  41. package/dist/components/DepositWithdrawal/Withdrawal/MayaWithdrawal/MayaWithdrawal.js +3 -3
  42. package/dist/components/DepositWithdrawal/Withdrawal/PisoPayWithdrawal/PisoPayWithdrawal.js +2 -2
  43. package/dist/components/DepositWithdrawal/Withdrawal/TransactionPasswordNotSet.js +2 -2
  44. package/dist/components/DepositWithdrawal/Withdrawal/VentajaWithdrawal/VentajaWithdrawal.js +2 -2
  45. package/dist/components/DepositWithdrawal/Withdrawal/Withdrawal.js +4 -4
  46. package/dist/components/DigitainLauncher/Fallback.js +1 -1
  47. package/dist/components/DigitainLauncher/Loading.js +1 -1
  48. package/dist/components/DigitainLauncher/utils.js +1 -2
  49. package/dist/components/Disclaimer/DisclaimerV1.js +1 -1
  50. package/dist/components/Disclaimer/DisclaimerV2.js +3 -3
  51. package/dist/components/Disclaimer/ResponsibleGaming.d.ts +10 -0
  52. package/dist/components/Disclaimer/ResponsibleGaming.js +13 -0
  53. package/dist/components/Disclaimer/TermsOfUse.d.ts +11 -0
  54. package/dist/components/Disclaimer/TermsOfUse.js +13 -0
  55. package/dist/components/FavoriteGames/FavoriteGames.client.js +4 -4
  56. package/dist/components/ForgotPassword/ForgotPassword.lazy.js +1 -1
  57. package/dist/components/ForgotPassword/ForgotPasswordForm.js +5 -5
  58. package/dist/components/GCashFailed/GCashFailed.js +1 -1
  59. package/dist/components/GCashSuccess/GCashSuccess.js +1 -1
  60. package/dist/components/GameLaunch/GameLaunch.lazy.js +4 -4
  61. package/dist/components/GameLaunch/GameLaunchTrigger.js +2 -4
  62. package/dist/components/GameProviders/GameProvidersCarousel.js +1 -1
  63. package/dist/components/GameProviders/GameProvidersList.js +1 -1
  64. package/dist/components/Games/Game.js +3 -3
  65. package/dist/components/Games/GamesCarousel.client.js +2 -4
  66. package/dist/components/Games/GamesList.client.js +2 -2
  67. package/dist/components/GamesSearch/GamesSearch.js +4 -6
  68. package/dist/components/Jackpots/JackpotsCarousel/JackpotsCarousel.js +1 -1
  69. package/dist/components/Jackpots/JackpotsCarousel/JackpotsCarouselItem.d.ts +1 -1
  70. package/dist/components/Jackpots/JackpotsCarousel/JackpotsCarouselItem.js +53 -51
  71. package/dist/components/Jackpots/JackpotsCarousel/JackpotsCarouselItem.module.css +184 -184
  72. package/dist/components/Jackpots/JackpotsList/JackpotsList.js +1 -1
  73. package/dist/components/Jackpots/JackpotsList/JackpotsListItem.module.css +184 -184
  74. package/dist/components/Jackpots/JackpotsList/JackpotsListItemDesktop.js +14 -12
  75. package/dist/components/Jackpots/JackpotsList/JackpotsListItemGameProviders.js +1 -1
  76. package/dist/components/Jackpots/JackpotsList/JackpotsListItemMobile.js +13 -11
  77. package/dist/components/Jackpots/JackpotsList/JackpotsListItemRules.js +1 -1
  78. package/dist/components/Jackpots/JackpotsList/useJackpotsListItemData.js +15 -15
  79. package/dist/components/KYC/BasicInformation.js +1 -1
  80. package/dist/components/KYC/CaptureIdDocument.d.ts +1 -0
  81. package/dist/components/KYC/CaptureIdDocument.js +219 -0
  82. package/dist/components/KYC/CaptureSelfie.d.ts +1 -0
  83. package/dist/components/KYC/CaptureSelfie.js +285 -0
  84. package/dist/components/KYC/DisplayImage.d.ts +5 -0
  85. package/dist/components/KYC/DisplayImage.js +8 -0
  86. package/dist/components/KYC/FileUpload.d.ts +10 -0
  87. package/dist/components/KYC/FileUpload.js +72 -0
  88. package/dist/components/KYC/IdentityVerification.js +1 -1
  89. package/dist/components/KYC/KYC.lazy.js +1 -1
  90. package/dist/components/KYC/KYCReminder.lazy.js +1 -1
  91. package/dist/components/KYC/NoCameraError.d.ts +7 -0
  92. package/dist/components/KYC/NoCameraError.js +6 -0
  93. package/dist/components/KYC/PersonOverlayDesktop.d.ts +7 -0
  94. package/dist/components/KYC/PersonOverlayDesktop.js +9 -0
  95. package/dist/components/KYC/PersonalInformation.js +1 -1
  96. package/dist/components/KYC/utils.d.ts +9 -0
  97. package/dist/components/KYC/utils.js +79 -0
  98. package/dist/components/Marquee/Marquee.js +1 -1
  99. package/dist/components/Messages/Messages.lazy.js +5 -5
  100. package/dist/components/Messages/MessagesPopup.js +3 -3
  101. package/dist/components/Messages/MessagesTrigger.js +1 -1
  102. package/dist/components/News/News.js +1 -1
  103. package/dist/components/NewsFeed/News.d.ts +2 -2
  104. package/dist/components/NewsFeed/News.js +1 -1
  105. package/dist/components/NewsFeed/NewsFeedCarousel.js +2 -2
  106. package/dist/components/NewsFeed/NewsFeedList.js +1 -1
  107. package/dist/components/PortalProvider/Snackbar.js +2 -2
  108. package/dist/components/Promo/Promo.client.js +2 -2
  109. package/dist/components/Promos/Cashback.js +1 -1
  110. package/dist/components/Promos/CustomPromo.d.ts +2 -2
  111. package/dist/components/Promos/CustomPromo.js +1 -1
  112. package/dist/components/Promos/Promo.js +1 -1
  113. package/dist/components/Promos/PromosCarousel.js +2 -2
  114. package/dist/components/Promos/PromosGrid.js +2 -2
  115. package/dist/components/Quests/DailyCheckInQuest.js +3 -3
  116. package/dist/components/Quests/JourneyQuest.js +5 -5
  117. package/dist/components/Quests/OnboardingQuest.js +2 -2
  118. package/dist/components/Quests/Quests.client.js +4 -4
  119. package/dist/components/Quests/WageringQuest.js +2 -2
  120. package/dist/components/ResponsibleGaming/ResponsibleGaming.lazy.js +1 -1
  121. package/dist/components/Search/Search.lazy.js +7 -9
  122. package/dist/components/SignIn/MobileNumberSignIn.js +5 -5
  123. package/dist/components/SignIn/NameAndPasswordSignIn.js +2 -2
  124. package/dist/components/SignIn/SignIn.lazy.d.ts +1 -1
  125. package/dist/components/SignIn/SignIn.lazy.js +1 -2
  126. package/dist/components/SignIn/SignInForm.js +1 -1
  127. package/dist/components/SignUp/SignUpDefault/SignUp.lazy.d.ts +17 -0
  128. package/dist/components/SignUp/SignUpDefault/SignUp.lazy.js +18 -0
  129. package/dist/components/SignUp/SignUpDefault/SignUpContext.d.ts +6 -0
  130. package/dist/components/SignUp/SignUpDefault/SignUpContext.js +2 -0
  131. package/dist/components/SignUp/SignUpDefault/SignUpDefault.lazy.js +1 -1
  132. package/dist/components/SignUp/SignUpDefault/SignUpDefaultForm.js +7 -7
  133. package/dist/components/SignUp/SignUpDefault/SignUpForm.d.ts +1 -0
  134. package/dist/components/SignUp/SignUpDefault/SignUpForm.js +310 -0
  135. package/dist/components/SignUp/SignUpKYC/CaptureIdDocument.d.ts +1 -0
  136. package/dist/components/SignUp/SignUpKYC/CaptureIdDocument.js +198 -0
  137. package/dist/components/SignUp/SignUpKYC/CaptureSelfie.d.ts +1 -0
  138. package/dist/components/SignUp/SignUpKYC/CaptureSelfie.js +251 -0
  139. package/dist/components/SignUp/SignUpKYC/IdFrontImageField/IdFrontImageField.client.js +7 -7
  140. package/dist/components/SignUp/SignUpKYC/IdFrontImageField/IdFrontImageField.js +1 -1
  141. package/dist/components/SignUp/SignUpKYC/ImageUploader.d.ts +10 -0
  142. package/dist/components/SignUp/SignUpKYC/ImageUploader.js +42 -0
  143. package/dist/components/SignUp/SignUpKYC/PersonOverlayDesktop.d.ts +7 -0
  144. package/dist/components/SignUp/SignUpKYC/PersonOverlayDesktop.js +9 -0
  145. package/dist/components/SignUp/SignUpKYC/SelfieImageField/SelfieImageField.client.js +6 -6
  146. package/dist/components/SignUp/SignUpKYC/SelfieImageField/SelfieImageField.js +1 -1
  147. package/dist/components/SignUp/SignUpKYC/SelfieImageField/useSelfieImageField.js +0 -1
  148. package/dist/components/SignUp/SignUpKYC/SignUpFormKYC.d.ts +1 -0
  149. package/dist/components/SignUp/SignUpKYC/SignUpFormKYC.js +464 -0
  150. package/dist/components/SignUp/SignUpKYC/SignUpKYC.lazy.js +1 -1
  151. package/dist/components/SignUp/SignUpKYC/SignUpKYCForm.js +8 -8
  152. package/dist/components/SignUp/SignUpKYC/useImageUploader.d.ts +11 -0
  153. package/dist/components/SignUp/SignUpKYC/useImageUploader.js +20 -0
  154. package/dist/components/SignUp/SignUpKYC/utils.d.ts +9 -0
  155. package/dist/components/SignUp/SignUpKYC/utils.js +79 -0
  156. package/dist/components/TermsAndConditions/TermsAndConditions.lazy.js +1 -1
  157. package/dist/components/TermsOfUse/TermsOfUse.lazy.js +1 -1
  158. package/dist/components/TopWins/TopWins.client.js +3 -3
  159. package/dist/components/Tournaments/TournamentsCarousel/TournamentsCarousel.js +1 -1
  160. package/dist/components/Tournaments/TournamentsCarousel/TournamentsCarouselItem.js +10 -8
  161. package/dist/components/Tournaments/TournamentsCarousel/TournamentsCarouselItem.module.css +184 -184
  162. package/dist/components/Tournaments/TournamentsList/TournamentItem.module.css +184 -184
  163. package/dist/components/Tournaments/TournamentsList/TournamentsList.js +2 -2
  164. package/dist/components/Tournaments/TournamentsList/TournamentsListItemDesktop.js +9 -7
  165. package/dist/components/Tournaments/TournamentsList/TournamentsListItemGameProviders.js +1 -1
  166. package/dist/components/Tournaments/TournamentsList/TournamentsListItemMobile.js +8 -6
  167. package/dist/components/Tournaments/TournamentsList/TournamentsListItemRules.js +1 -1
  168. package/dist/components/Tournaments/TournamentsList/useTournamentListItemData.js +1 -1
  169. package/dist/components/TransactionRecords/DepositRecordsTable.js +2 -2
  170. package/dist/components/TransactionRecords/TableFilters.js +1 -1
  171. package/dist/components/TransactionRecords/TransactionRecords.suspense.js +1 -1
  172. package/dist/components/TransactionRecords/TransactionRecordsTable.js +2 -2
  173. package/dist/components/TransactionRecords/WithdrawalRecordsTable.js +2 -2
  174. package/dist/components/shared/Empty.js +1 -1
  175. package/dist/components/shared/IdFrontImageField/IdFrontImageField.client.js +7 -7
  176. package/dist/components/shared/IdFrontImageField/IdFrontImageField.js +1 -1
  177. package/dist/components/shared/SelfieImageField/SelfieImageField.client.js +6 -6
  178. package/dist/components/shared/SelfieImageField/SelfieImageField.js +1 -1
  179. package/dist/components/shared/SelfieImageField/useSelfieImageField.js +0 -1
  180. package/dist/constants/EnvVar.d.ts +1 -1
  181. package/dist/handlers/postTransformIdFrontImage.d.ts +3 -0
  182. package/dist/handlers/postTransformIdFrontImage.js +82 -0
  183. package/dist/handlers/postTransformSelfieImage.d.ts +3 -0
  184. package/dist/handlers/postTransformSelfieImage.js +82 -0
  185. package/dist/middleware.d.ts +1 -1
  186. package/dist/middleware.js +1 -1
  187. package/dist/services/graphqlRequest.js +0 -1
  188. package/dist/styles/theme.css +706 -706
  189. package/dist/ui/AlertDialog/AlertDialog.d.ts +154 -154
  190. package/dist/ui/AlertDialog/alertDialog.recipe.d.ts +14 -14
  191. package/dist/ui/AlertDialog/alertDialog.recipe.js +6 -6
  192. package/dist/ui/Avatar/avatar.recipe.js +3 -3
  193. package/dist/ui/Badge/Badge.d.ts +12 -12
  194. package/dist/ui/Badge/badge.anatomy.d.ts +1 -1
  195. package/dist/ui/Badge/badge.recipe.d.ts +3 -3
  196. package/dist/ui/Badge/badge.recipe.js +7 -7
  197. package/dist/ui/Button/button.recipe.d.ts +2 -2
  198. package/dist/ui/Button/button.recipe.js +3 -3
  199. package/dist/ui/Carousel/Carousel.d.ts +45 -45
  200. package/dist/ui/Carousel/carousel.recipe.d.ts +5 -5
  201. package/dist/ui/Checkbox/Checkbox.d.ts +23 -23
  202. package/dist/ui/Checkbox/checkbox.recipe.d.ts +3 -3
  203. package/dist/ui/Checkbox/checkbox.recipe.js +1 -1
  204. package/dist/ui/Clipboard/Clipboard.d.ts +18 -18
  205. package/dist/ui/Clipboard/clipboard.recipe.d.ts +3 -3
  206. package/dist/ui/Clipboard/clipboard.recipe.js +2 -2
  207. package/dist/ui/Collapsible/Collapsible.d.ts +32 -32
  208. package/dist/ui/Collapsible/collapsible.recipe.d.ts +8 -8
  209. package/dist/ui/Collapsible/collapsible.recipe.js +2 -2
  210. package/dist/ui/Combobox/Combobox.d.ts +42 -42
  211. package/dist/ui/Combobox/Combobox.js +0 -1
  212. package/dist/ui/Combobox/combobox.recipe.d.ts +3 -3
  213. package/dist/ui/Combobox/combobox.recipe.js +6 -6
  214. package/dist/ui/DatePicker/DatePicker.d.ts +72 -72
  215. package/dist/ui/DatePicker/datePicker.recipe.d.ts +3 -3
  216. package/dist/ui/DatePicker/datePicker.recipe.js +7 -7
  217. package/dist/ui/Dialog/Dialog.d.ts +154 -154
  218. package/dist/ui/Dialog/dialog.recipe.d.ts +14 -14
  219. package/dist/ui/Dialog/dialog.recipe.js +4 -4
  220. package/dist/ui/Drawer/Drawer.d.ts +33 -33
  221. package/dist/ui/Drawer/drawer.recipe.d.ts +3 -3
  222. package/dist/ui/Drawer/drawer.recipe.js +5 -5
  223. package/dist/ui/Field/Field.d.ts +21 -21
  224. package/dist/ui/Field/field.recipe.d.ts +3 -3
  225. package/dist/ui/Field/field.recipe.js +3 -3
  226. package/dist/ui/IconButton/iconButton.recipe.d.ts +2 -2
  227. package/dist/ui/Menu/Menu.d.ts +144 -144
  228. package/dist/ui/Menu/menu.recipe.d.ts +8 -8
  229. package/dist/ui/NumberInput/numberInput.recipe.js +5 -5
  230. package/dist/ui/PasswordInput/PasswordInput.d.ts +18 -18
  231. package/dist/ui/PasswordInput/passwordInput.recipe.d.ts +3 -3
  232. package/dist/ui/PasswordInput/passwordInput.recipe.js +3 -3
  233. package/dist/ui/PinInput/pinInput.recipe.js +3 -3
  234. package/dist/ui/Popover/Popover.d.ts +121 -121
  235. package/dist/ui/Popover/popover.recipe.d.ts +11 -11
  236. package/dist/ui/Popover/popover.recipe.js +1 -1
  237. package/dist/ui/Presence/Presence.js +1 -1
  238. package/dist/ui/Progress/Progress.d.ts +27 -27
  239. package/dist/ui/Progress/progress.recipe.d.ts +3 -3
  240. package/dist/ui/Progress/progress.recipe.js +2 -2
  241. package/dist/ui/SegmentGroup/SegmentGroup.d.ts +18 -18
  242. package/dist/ui/SegmentGroup/segmentGroup.recipe.d.ts +3 -3
  243. package/dist/ui/SegmentGroup/segmentGroup.recipe.js +4 -4
  244. package/dist/ui/Select/Select.d.ts +45 -45
  245. package/dist/ui/Select/Select.js +0 -1
  246. package/dist/ui/Select/select.recipe.d.ts +3 -3
  247. package/dist/ui/Select/select.recipe.js +7 -7
  248. package/dist/ui/Table/Table.d.ts +21 -21
  249. package/dist/ui/Table/table.anatomy.d.ts +1 -1
  250. package/dist/ui/Table/table.recipe.d.ts +3 -3
  251. package/dist/ui/Table/table.recipe.js +3 -3
  252. package/dist/ui/Tabs/Tabs.d.ts +15 -15
  253. package/dist/ui/Tabs/tabs.recipe.d.ts +3 -3
  254. package/dist/ui/Tabs/tabs.recipe.js +4 -4
  255. package/dist/ui/Tooltip/tooltip.recipe.js +1 -1
  256. package/dist/utils/gamesAvailable3pmTo3am.d.ts +1 -0
  257. package/dist/utils/gamesAvailable3pmTo3am.js +1 -0
  258. package/dist/utils/getGameName.d.ts +1 -0
  259. package/dist/utils/getGameName.js +6 -0
  260. package/dist/utils/getLocaleInfo.js +7 -7
  261. package/dist/utils/getQueryClient.js +1 -1
  262. package/dist/utils/isBetween3amAnd3pm.d.ts +1 -0
  263. package/dist/utils/isBetween3amAnd3pm.js +5 -0
  264. package/dist/utils/parseDecimal.js +1 -1
  265. package/dist/utils/validateFile.d.ts +1 -1
  266. package/package.json +159 -164
@@ -106,18 +106,18 @@ function AccountVerificationRequired() {
106
106
  kyc: ctx.kyc,
107
107
  depositWithdrawal: ctx.depositWithdrawal,
108
108
  })));
109
- return (_jsxs("div", { className: "pt-xl", children: [_jsx("div", { className: "bg-bg-warning-secondary mx-auto flex size-12 items-center justify-center rounded-full", children: _jsx(AlertCircleIcon, { className: "text-text-featured-icon-light-warning size-6" }) }), _jsx("h2", { className: "mt-lg text-center text-lg font-semibold", children: "Personal Verification" }), _jsx("p", { className: "text-text-tertiary-600 mx-auto mt-xs max-w-[25rem] text-center text-sm", children: "To withdraw funds, you must first verify your identity. Complete personal verification to ensure your account\u2019s security." }), _jsx(Button, { className: "mt-3xl", onClick: () => {
109
+ return (_jsxs("div", { className: "pt-xl", children: [_jsx("div", { className: "mx-auto flex size-12 items-center justify-center rounded-full bg-bg-warning-secondary", children: _jsx(AlertCircleIcon, { className: "size-6 text-text-featured-icon-light-warning" }) }), _jsx("h2", { className: "mt-lg text-center font-semibold text-lg", children: "Personal Verification" }), _jsx("p", { className: "mx-auto mt-xs max-w-[25rem] text-center text-sm text-text-tertiary-600", children: "To withdraw funds, you must first verify your identity. Complete personal verification to ensure your account\u2019s security." }), _jsx(Button, { className: "mt-3xl", onClick: () => {
110
110
  globalStore.kyc.setOpen(true);
111
111
  globalStore.depositWithdrawal.setOpen(false);
112
112
  }, children: "Verify Now" })] }));
113
113
  }
114
114
  function InsufficientBalance() {
115
115
  const setTab = useGlobalStore(useShallow((ctx) => ctx.depositWithdrawal.setTab));
116
- return (_jsxs("div", { className: "pt-xl", children: [_jsx("div", { className: "bg-bg-warning-secondary mx-auto flex size-12 items-center justify-center rounded-full", children: _jsx(AlertCircleIcon, { className: "text-text-featured-icon-light-warning size-6" }) }), _jsx("h2", { className: "mt-lg text-center text-lg font-semibold", children: "Balance is very low" }), _jsx("p", { className: "text-text-tertiary-600 mx-auto mt-xs max-w-[25rem] text-center text-sm", children: "No funds available for withdrawal. Please make a deposit." }), _jsx(Button, { className: "mt-3xl", onClick: () => setTab('DEPOSIT'), children: "Deposit" })] }));
116
+ return (_jsxs("div", { className: "pt-xl", children: [_jsx("div", { className: "mx-auto flex size-12 items-center justify-center rounded-full bg-bg-warning-secondary", children: _jsx(AlertCircleIcon, { className: "size-6 text-text-featured-icon-light-warning" }) }), _jsx("h2", { className: "mt-lg text-center font-semibold text-lg", children: "Balance is very low" }), _jsx("p", { className: "mx-auto mt-xs max-w-[25rem] text-center text-sm text-text-tertiary-600", children: "No funds available for withdrawal. Please make a deposit." }), _jsx(Button, { className: "mt-3xl", onClick: () => setTab('DEPOSIT'), children: "Deposit" })] }));
117
117
  }
118
118
  function NoAvailablePaymentMethods() {
119
- return (_jsxs("div", { className: "py-xl", children: [_jsx("div", { className: "bg-bg-warning-secondary mx-auto flex size-12 items-center justify-center rounded-full", children: _jsx(AlertCircleIcon, { className: "text-text-featured-icon-light-warning size-6" }) }), _jsx("h2", { className: "mt-lg text-center text-lg font-semibold", children: "Not Available" }), _jsx("p", { className: "text-text-tertiary-600 mx-auto mt-xs max-w-[25rem] text-center text-sm", children: "Withdrawal is not available at this time. Please try again later or contact support for assistance." })] }));
119
+ return (_jsxs("div", { className: "py-xl", children: [_jsx("div", { className: "mx-auto flex size-12 items-center justify-center rounded-full bg-bg-warning-secondary", children: _jsx(AlertCircleIcon, { className: "size-6 text-text-featured-icon-light-warning" }) }), _jsx("h2", { className: "mt-lg text-center font-semibold text-lg", children: "Not Available" }), _jsx("p", { className: "mx-auto mt-xs max-w-[25rem] text-center text-sm text-text-tertiary-600", children: "Withdrawal is not available at this time. Please try again later or contact support for assistance." })] }));
120
120
  }
121
121
  function MayaSessionSessionExpired() {
122
- return (_jsxs("div", { className: "py-xl", children: [_jsx("div", { className: "bg-bg-warning-secondary mx-auto flex size-12 items-center justify-center rounded-full", children: _jsx(AlertCircleIcon, { className: "text-text-featured-icon-light-warning size-6" }) }), _jsx("h2", { className: "mt-lg text-center text-lg font-semibold", children: "Session Expired" }), _jsx("p", { className: "text-text-tertiary-600 mx-auto mt-xs max-w-[25rem] text-center text-sm", children: "Your session has timed out. To continue with deposits or withdrawals, Please try reloading the app." })] }));
122
+ return (_jsxs("div", { className: "py-xl", children: [_jsx("div", { className: "mx-auto flex size-12 items-center justify-center rounded-full bg-bg-warning-secondary", children: _jsx(AlertCircleIcon, { className: "size-6 text-text-featured-icon-light-warning" }) }), _jsx("h2", { className: "mt-lg text-center font-semibold text-lg", children: "Session Expired" }), _jsx("p", { className: "mx-auto mt-xs max-w-[25rem] text-center text-sm text-text-tertiary-600", children: "Your session has timed out. To continue with deposits or withdrawals, Please try reloading the app." })] }));
123
123
  }
@@ -8,7 +8,7 @@ export function Fallback({ signInUrl }) {
8
8
  const globalStore = useGlobalStore(useShallow((ctx) => ({
9
9
  signIn: ctx.signIn,
10
10
  })));
11
- return (_jsx("div", { className: "h-[calc(100vh-400px)] w-full", children: _jsx("div", { className: "m-auto flex h-full max-w-[40rem] flex-col items-center justify-center px-4", children: _jsxs("div", { className: "text-center", children: [_jsx("div", { className: "mb-6 flex justify-center", children: _jsx("div", { className: "bg-gray-100 rounded-full p-4", children: _jsx(User01Icon, { className: "text-gray-400 size-12" }) }) }), _jsxs("div", { className: "mb-8 space-y-3", children: [_jsx("h2", { className: "text-gray-900 text-2xl font-bold", children: "Sign in required" }), _jsx("p", { className: "text-gray-600 leading-relaxed", children: "Access to Sports Book is restricted to authenticated users. Please sign in to view betting odds, place bets, and track your activity." })] }), _jsx(Button, { onClick: () => {
11
+ return (_jsx("div", { className: "h-[calc(100vh-400px)] w-full", children: _jsx("div", { className: "m-auto flex h-full max-w-[40rem] flex-col items-center justify-center px-4", children: _jsxs("div", { className: "text-center", children: [_jsx("div", { className: "mb-6 flex justify-center", children: _jsx("div", { className: "rounded-full bg-gray-100 p-4", children: _jsx(User01Icon, { className: "size-12 text-gray-400" }) }) }), _jsxs("div", { className: "mb-8 space-y-3", children: [_jsx("h2", { className: "font-bold text-2xl text-gray-900", children: "Sign in required" }), _jsx("p", { className: "text-gray-600 leading-relaxed", children: "Access to Sports Book is restricted to authenticated users. Please sign in to view betting odds, place bets, and track your activity." })] }), _jsx(Button, { onClick: () => {
12
12
  if (signInUrl) {
13
13
  window.location.href = signInUrl;
14
14
  }
@@ -1,5 +1,5 @@
1
1
  'use client';
2
2
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
3
3
  export function Loading() {
4
- return (_jsx("div", { className: "flex h-[calc(100vh-400px)] w-full items-center justify-center px-4", children: _jsxs("div", { className: "flex flex-col items-center space-y-4", children: [_jsx("div", { className: "border-blue-500 h-10 w-10 animate-spin rounded-full border-4 border-t-transparent" }), _jsx("p", { className: "text-gray-700 text-lg font-medium", children: "Loading Sports Book\u2026" })] }) }));
4
+ return (_jsx("div", { className: "flex h-[calc(100vh-400px)] w-full items-center justify-center px-4", children: _jsxs("div", { className: "flex flex-col items-center space-y-4", children: [_jsx("div", { className: "h-10 w-10 animate-spin rounded-full border-4 border-blue-500 border-t-transparent" }), _jsx("p", { className: "font-medium text-gray-700 text-lg", children: "Loading Sports Book\u2026" })] }) }));
5
5
  }
@@ -1,5 +1,4 @@
1
1
  import { ObjectId } from '@opexa/object-id';
2
- import { env } from 'process';
3
2
  import invariant from 'tiny-invariant';
4
3
  import { getSession } from '../../server/services/getSession.js';
5
4
  import { getGames } from '../../services/cmsPortal.js';
@@ -7,7 +6,7 @@ import { ObjectType } from '../../services/ObjectType.js';
7
6
  import { createGameSession, getGameSession } from '../../services/wallet.js';
8
7
  import { createPoll } from '../../utils/createPoll.js';
9
8
  export const defaultDigitainParams = {
10
- server: env.NEXT_PUBLIC_ENVIRONMENT === 'development'
9
+ server: process.env.NEXT_PUBLIC_ENVIRONMENT === 'development'
11
10
  ? 'sport-uat.ofwin.fun'
12
11
  : 'sport.ofwin.fun',
13
12
  containerId: 'digitain-container',
@@ -12,5 +12,5 @@ import { useDisclaimer } from './useDisclaimer.js';
12
12
  export function DisclaimerV1(props) {
13
13
  const disclaimer = useDisclaimer();
14
14
  const acceptTriggerRef = useRef(null);
15
- return (_jsx(Dialog.Root, { open: disclaimer.open, lazyMount: true, unmountOnExit: true, closeOnEscape: false, closeOnInteractOutside: false, initialFocusEl: () => acceptTriggerRef.current, children: _jsxs(Portal, { children: [_jsx(Dialog.Backdrop, { className: "!z-[calc(var(--z-dialog)+1)]" }), _jsx(Dialog.Positioner, { className: "!z-[calc(var(--z-dialog)+2)]", children: _jsxs(Dialog.Content, { className: "flex h-full w-full flex-col items-start overflow-y-auto p-3xl lg:mx-auto lg:h-auto lg:w-[400px] lg:rounded-xl", children: [_jsx(Image, { src: props.logo, alt: "", width: 200, height: 100, className: "mx-auto h-auto w-[120px]", draggable: false }), _jsxs("div", { className: "w-full grow", children: [_jsx(Dialog.Title, { className: "mt-3xl text-center text-lg font-semibold", children: "Age Verification" }), _jsxs(Dialog.Description, { className: "text-text-tertiary-600 mt-xs text-center text-sm", children: ["By entering this website I acknowledge and confirm I am 21 years of age and I agree with the", ' ', _jsx(Link, { href: props.termsAndConditionsUrl ?? '/terms-and-conditions', target: "_blank", rel: "noopener noreferrer", className: "text-brand-400 whitespace-nowrap underline underline-offset-2", prefetch: false, children: "Terms and Conditions." })] }), _jsxs("div", { className: "mt-5 flex items-center justify-center gap-3xl", children: [_jsx(Image, { src: pagcorLogo, alt: "", height: 75, width: 88, className: "h-[88px] w-auto shrink-0", draggable: false }), _jsx(Image, { src: responsibleGamingLogo, alt: "", height: 62, width: 186, className: "h-[62px] w-auto shrink-0", draggable: false })] })] }), _jsx(Button, { ref: acceptTriggerRef, type: "button", className: "mt-4xl", onClick: disclaimer.close, children: "Accept" })] }) })] }) }));
15
+ return (_jsx(Dialog.Root, { open: disclaimer.open, lazyMount: true, unmountOnExit: true, closeOnEscape: false, closeOnInteractOutside: false, initialFocusEl: () => acceptTriggerRef.current, children: _jsxs(Portal, { children: [_jsx(Dialog.Backdrop, { className: "!z-[calc(var(--z-dialog)+1)]" }), _jsx(Dialog.Positioner, { className: "!z-[calc(var(--z-dialog)+2)]", children: _jsxs(Dialog.Content, { className: "flex h-full w-full flex-col items-start overflow-y-auto p-3xl lg:mx-auto lg:h-auto lg:w-[400px] lg:rounded-xl", children: [_jsx(Image, { src: props.logo, alt: "", width: 200, height: 100, className: "mx-auto h-auto w-[120px]", draggable: false }), _jsxs("div", { className: "w-full grow", children: [_jsx(Dialog.Title, { className: "mt-3xl text-center font-semibold text-lg", children: "Age Verification" }), _jsxs(Dialog.Description, { className: "mt-xs text-center text-sm text-text-tertiary-600", children: ["By entering this website I acknowledge and confirm I am 21 years of age and I agree with the", ' ', _jsx(Link, { href: props.termsAndConditionsUrl ?? '/terms-and-conditions', target: "_blank", rel: "noopener noreferrer", className: "whitespace-nowrap text-brand-400 underline underline-offset-2", prefetch: false, children: "Terms and Conditions." })] }), _jsxs("div", { className: "mt-5 flex items-center justify-center gap-3xl", children: [_jsx(Image, { src: pagcorLogo, alt: "", height: 75, width: 88, className: "h-[88px] w-auto shrink-0", draggable: false }), _jsx(Image, { src: responsibleGamingLogo, alt: "", height: 62, width: 186, className: "h-[62px] w-auto shrink-0", draggable: false })] })] }), _jsx(Button, { ref: acceptTriggerRef, type: "button", className: "mt-4xl", onClick: disclaimer.close, children: "Accept" })] }) })] }) }));
16
16
  }
@@ -22,7 +22,7 @@ export function DisclaimerV2(props) {
22
22
  })));
23
23
  const checked = globalStore.termsOfUse.accepted && globalStore.responsibleGaming.accepted;
24
24
  const [showWarning, setShowWarning] = useState(false);
25
- return (_jsx(Dialog.Root, { open: disclaimer.open, lazyMount: true, unmountOnExit: true, closeOnEscape: false, closeOnInteractOutside: false, children: _jsxs(Portal, { children: [_jsx(Dialog.Backdrop, {}), _jsx(Dialog.Positioner, { children: _jsxs(Dialog.Content, { className: "p-3xl flex h-full w-full flex-col items-start gap-y-4 overflow-y-auto lg:mx-auto lg:h-auto lg:max-h-[80vh] lg:w-[400px] lg:rounded-xl", children: [_jsx(Image, { src: props.logo, alt: "", width: 200, height: 100, className: "mx-auto h-auto w-[120px]", draggable: false }), _jsxs("div", { className: "gap-3xl flex w-full items-center justify-center", children: [_jsx(Image, { src: pagcorLogo, alt: "", height: 43, width: 88, className: "h-[43px] w-auto shrink-0", draggable: false }), _jsx(Image, { src: props.responsibleGamingLogo ?? responsibleGamingLogo, alt: "", height: 50, width: 186, className: "h-[50px] w-auto shrink-0", draggable: false })] }), _jsx("div", { className: "text-sm", children: "The following individuals are prohibited from registering or participating in this online gaming platform." }), _jsx("div", { className: "w-full grow", children: _jsxs(Dialog.Description, { className: "space-y-4 text-sm", children: [_jsxs("ul", { className: "space-y-1.5 text-left", children: [_jsxs("li", { className: "flex gap-4", children: [_jsx(Circle, {}), "Persons below the legal gambling age of 21."] }), _jsxs("li", { className: "flex gap-4", children: [_jsx(Circle, {}), "Any government official or employee directly involved in the operations of the government or its agencies."] }), _jsxs("li", { className: "flex gap-4", children: [_jsx(Circle, {}), "Member of the Armed Forces of the Philippines, including the Army, Navy, Air Force and the Philippine National Police."] }), _jsxs("li", { className: "flex gap-4", children: [_jsx(Circle, {}), "Individuals listed in PAGCOR's National Database of Restricted Persons (NDRP)"] }), _jsxs("li", { className: "flex gap-4", children: [_jsx(Circle, {}), "Holders of a valid Gaming Employment License (GEL)"] })] }), _jsxs(Checkbox.Root, { checked: checked, onCheckedChange: (e) => {
25
+ return (_jsx(Dialog.Root, { open: disclaimer.open, lazyMount: true, unmountOnExit: true, closeOnEscape: false, closeOnInteractOutside: false, children: _jsxs(Portal, { children: [_jsx(Dialog.Backdrop, {}), _jsx(Dialog.Positioner, { children: _jsxs(Dialog.Content, { className: "flex h-full w-full flex-col items-start gap-y-4 overflow-y-auto p-3xl lg:mx-auto lg:h-auto lg:max-h-[80vh] lg:w-[400px] lg:rounded-xl", children: [_jsx(Image, { src: props.logo, alt: "", width: 200, height: 100, className: "mx-auto h-auto w-[120px]", draggable: false }), _jsxs("div", { className: "flex w-full items-center justify-center gap-3xl", children: [_jsx(Image, { src: pagcorLogo, alt: "", height: 43, width: 88, className: "h-[43px] w-auto shrink-0", draggable: false }), _jsx(Image, { src: props.responsibleGamingLogo ?? responsibleGamingLogo, alt: "", height: 50, width: 186, className: "h-[50px] w-auto shrink-0", draggable: false })] }), _jsx("div", { className: "text-sm", children: "The following individuals are prohibited from registering or participating in this online gaming platform." }), _jsx("div", { className: "w-full grow", children: _jsxs(Dialog.Description, { className: "space-y-4 text-sm", children: [_jsxs("ul", { className: "space-y-1.5 text-left", children: [_jsxs("li", { className: "flex gap-4", children: [_jsx(Circle, {}), "Persons below the legal gambling age of 21."] }), _jsxs("li", { className: "flex gap-4", children: [_jsx(Circle, {}), "Any government official or employee directly involved in the operations of the government or its agencies."] }), _jsxs("li", { className: "flex gap-4", children: [_jsx(Circle, {}), "Member of the Armed Forces of the Philippines, including the Army, Navy, Air Force and the Philippine National Police."] }), _jsxs("li", { className: "flex gap-4", children: [_jsx(Circle, {}), "Individuals listed in PAGCOR's National Database of Restricted Persons (NDRP)"] }), _jsxs("li", { className: "flex gap-4", children: [_jsx(Circle, {}), "Holders of a valid Gaming Employment License (GEL)"] })] }), _jsxs(Checkbox.Root, { checked: checked, onCheckedChange: (e) => {
26
26
  if (e.checked === 'indeterminate')
27
27
  return;
28
28
  globalStore.termsOfUse.setAccepted(e.checked);
@@ -35,7 +35,7 @@ export function DisclaimerV2(props) {
35
35
  globalStore.responsibleGaming.setOpen(true);
36
36
  globalStore.responsibleGaming.setNext('DISCLAIMER');
37
37
  disclaimer.close();
38
- }, children: "Responsible Gaming" })] }), _jsx(Checkbox.HiddenInput, {})] }), showWarning && (_jsxs("div", { className: twMerge('text-text-error-primary mt-2 flex max-w-full items-center gap-2 break-words rounded-md text-xs'), role: "alert", "aria-live": "assertive", children: [_jsx(AlertCircleIcon, { className: "text-text-error-primary size-5" }), "Please agree to ", props.siteName, "'s Terms of Use and Responsible Gaming to proceed."] })), _jsx("div", { children: "Funds or credits in the account of any individual found ineligible to participate will be forfeited and turned over to the government as required by law" })] }) }), _jsxs("div", { className: "mt-4 flex w-full gap-3", children: [_jsx(Button, { type: "button", onClick: () => {
38
+ }, children: "Responsible Gaming" })] }), _jsx(Checkbox.HiddenInput, {})] }), showWarning && (_jsxs("div", { className: twMerge('mt-2 flex max-w-full items-center gap-2 break-words rounded-md text-text-error-primary text-xs'), role: "alert", "aria-live": "assertive", children: [_jsx(AlertCircleIcon, { className: "size-5 text-text-error-primary" }), "Please agree to ", props.siteName, "'s Terms of Use and Responsible Gaming to proceed."] })), _jsx("div", { children: "Funds or credits in the account of any individual found ineligible to participate will be forfeited and turned over to the government as required by law" })] }) }), _jsxs("div", { className: "mt-4 flex w-full gap-3", children: [_jsx(Button, { type: "button", onClick: () => {
39
39
  if (props.redirectUrlOnNoConsent) {
40
40
  window.location.href = props.redirectUrlOnNoConsent;
41
41
  }
@@ -51,4 +51,4 @@ export function DisclaimerV2(props) {
51
51
  disclaimer.close();
52
52
  }, children: "Accept" })] })] }) })] }) }));
53
53
  }
54
- const Circle = () => (_jsx("div", { children: _jsx("div", { className: "border-brand-400 h-4.5 w-4.5 flex items-center justify-center rounded-full border", children: _jsx("div", { className: "bg-brand-400 h-3 w-3 rounded-full" }) }) }));
54
+ const Circle = () => (_jsx("div", { children: _jsx("div", { className: "flex h-4.5 w-4.5 items-center justify-center rounded-full border border-brand-400", children: _jsx("div", { className: "h-3 w-3 rounded-full bg-brand-400" }) }) }));
@@ -0,0 +1,10 @@
1
+ import { type ImageProps } from 'next/image';
2
+ import type { ReactNode } from 'react';
3
+ export interface ResponsibleGamingProps {
4
+ responsibleGamingContent: string | ReactNode;
5
+ logo: ImageProps['src'];
6
+ open: boolean;
7
+ onCloseAction: () => void;
8
+ responsibleGamingLogo?: ImageProps['src'];
9
+ }
10
+ export declare function ResponsibleGaming({ logo, open, responsibleGamingContent, onCloseAction, ...props }: ResponsibleGamingProps): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,13 @@
1
+ 'use client';
2
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
3
+ import Image, {} from 'next/image';
4
+ import pagcorLogo from '../../images/pagcor.png';
5
+ import responsibleGamingLogo from '../../images/responsible-gaming.png';
6
+ import { Button } from '../../ui/Button/index.js';
7
+ import { Dialog } from '../../ui/Dialog/index.js';
8
+ import { Portal } from '../../ui/Portal/index.js';
9
+ export function ResponsibleGaming({ logo, open, responsibleGamingContent, onCloseAction, ...props }) {
10
+ return (_jsx(Dialog.Root, { open: open, children: _jsxs(Portal, { children: [_jsx(Dialog.Backdrop, { className: "z-popover" }), _jsx(Dialog.Positioner, { className: "z-popover", children: _jsxs(Dialog.Content, { className: "flex h-full w-full flex-col items-start overflow-y-auto p-3xl lg:mx-auto lg:h-auto lg:w-[400px] lg:rounded-xl", children: [_jsx(Image, { src: logo, alt: "", width: 200, height: 100, className: "mx-auto h-auto w-[120px]", draggable: false }), _jsxs("div", { className: "w-full grow", children: [_jsx(Dialog.Title, { className: "text-brand-400 mt-3xl text-center text-lg font-semibold", children: "Responsible Gaming" }), _jsx(Dialog.Description, { className: "leading-2xl mt-xs text-sm", children: responsibleGamingContent }), _jsxs("div", { className: "mt-5 flex items-center justify-center gap-3xl", children: [_jsx(Image, { src: pagcorLogo, alt: "", height: 75, width: 88, className: "h-[88px] w-auto shrink-0", draggable: false }), _jsx(Image, { src: props.responsibleGamingLogo ?? responsibleGamingLogo, alt: "", height: 62, width: 186, className: "h-[62px] w-auto shrink-0", draggable: false })] })] }), _jsx("div", { className: "w-full", children: _jsx(Button, { type: "button", className: "mt-3", onClick: () => {
11
+ onCloseAction();
12
+ }, children: "I Agree" }) })] }) })] }) }));
13
+ }
@@ -0,0 +1,11 @@
1
+ import { type ImageProps } from 'next/image';
2
+ import type { ReactNode } from 'react';
3
+ export interface TermsOfUseProps {
4
+ logo: ImageProps['src'];
5
+ open: boolean;
6
+ onCloseAction: () => void;
7
+ termsOfUseContent: string | ReactNode;
8
+ siteName: string;
9
+ responsibleGamingLogo?: ImageProps['src'];
10
+ }
11
+ export declare function TermsOfUse({ logo, open, onCloseAction, siteName, termsOfUseContent, ...props }: TermsOfUseProps): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,13 @@
1
+ 'use client';
2
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
3
+ import Image, {} from 'next/image';
4
+ import pagcorLogo from '../../images/pagcor.png';
5
+ import responsibleGamingLogo from '../../images/responsible-gaming.png';
6
+ import { Button } from '../../ui/Button/index.js';
7
+ import { Dialog } from '../../ui/Dialog/index.js';
8
+ import { Portal } from '../../ui/Portal/index.js';
9
+ export function TermsOfUse({ logo, open, onCloseAction, siteName, termsOfUseContent, ...props }) {
10
+ return (_jsx(Dialog.Root, { open: open, children: _jsxs(Portal, { children: [_jsx(Dialog.Backdrop, { className: "z-popover" }), _jsx(Dialog.Positioner, { className: "z-popover", children: _jsxs(Dialog.Content, { className: "flex h-full w-full flex-col items-start overflow-y-auto p-3xl lg:mx-auto lg:h-auto lg:w-[400px] lg:rounded-xl", children: [_jsx(Image, { src: logo, alt: "", width: 200, height: 100, className: "mx-auto h-auto w-[120px]", draggable: false }), _jsxs("div", { className: "w-full grow", children: [_jsxs(Dialog.Title, { className: "text-brand-400 mt-3xl text-center text-lg font-semibold", children: [siteName, " Terms of Use"] }), _jsx(Dialog.Description, { className: "leading-2xl mt-xs text-sm", children: termsOfUseContent }), _jsxs("div", { className: "mt-5 flex items-center justify-center gap-3xl", children: [_jsx(Image, { src: pagcorLogo, alt: "", height: 75, width: 88, className: "h-[88px] w-auto shrink-0", draggable: false }), _jsx(Image, { src: props.responsibleGamingLogo ?? responsibleGamingLogo, alt: "", height: 62, width: 186, className: "h-[62px] w-auto shrink-0", draggable: false })] })] }), _jsx("div", { className: "w-full", children: _jsx(Button, { type: "button", className: "mt-3", onClick: () => {
11
+ onCloseAction();
12
+ }, children: "I Agree" }) })] }) })] }) }));
13
+ }
@@ -48,7 +48,7 @@ export function FavoriteGames__client(props) {
48
48
  const classNames = isString(props.className)
49
49
  ? { root: props.className }
50
50
  : (props.className ?? {});
51
- return (_jsxs("div", { className: classNames.root, children: [_jsxs("div", { className: "flex items-center", children: [_jsx("h2", { className: "text-lg font-semibold", children: props.heading ?? 'Favorite Games' }), _jsx("div", { className: "grow" }), _jsx("div", { className: "flex items-center justify-center gap-xl", children: _jsxs("div", { className: "hidden lg:flex", children: [_jsx(Button, { variant: "outline", colorScheme: "gray", className: "rounded-r-none border-r-0", onClick: onPrevButtonClick, disabled: prevBtnDisabled, "aria-label": "Previous", children: _jsx(ArrowLeftIcon, { className: "size-5" }) }), _jsx(Button, { variant: "outline", colorScheme: "gray", className: "rounded-l-none", onClick: onNextButtonClick, disabled: nextBtnDisabled, "aria-label": "Next", children: _jsx(ArrowRightIcon, { className: "size-5" }) })] }) })] }), _jsx("div", { ref: emblaRef, className: "relative mt-lg lg:overflow-hidden", children: _jsx("div", { className: twMerge('grid auto-cols-[calc((100%-(0.375rem*2))/3)] grid-flow-col grid-rows-1 gap-sm lg:auto-cols-[calc((100%-(0.5rem*5))/6)] lg:gap-md'), children: games.map((game) => (_jsx(Item, { game: game, className: {
51
+ return (_jsxs("div", { className: classNames.root, children: [_jsxs("div", { className: "flex items-center", children: [_jsx("h2", { className: "font-semibold text-lg", children: props.heading ?? 'Favorite Games' }), _jsx("div", { className: "grow" }), _jsx("div", { className: "flex items-center justify-center gap-xl", children: _jsxs("div", { className: "hidden lg:flex", children: [_jsx(Button, { variant: "outline", colorScheme: "gray", className: "rounded-r-none border-r-0", onClick: onPrevButtonClick, disabled: prevBtnDisabled, "aria-label": "Previous", children: _jsx(ArrowLeftIcon, { className: "size-5" }) }), _jsx(Button, { variant: "outline", colorScheme: "gray", className: "rounded-l-none", onClick: onNextButtonClick, disabled: nextBtnDisabled, "aria-label": "Next", children: _jsx(ArrowRightIcon, { className: "size-5" }) })] }) })] }), _jsx("div", { ref: emblaRef, className: "relative mt-lg lg:overflow-hidden", children: _jsx("div", { className: twMerge('grid auto-cols-[calc((100%-(0.375rem*2))/3)] grid-flow-col grid-rows-1 gap-sm lg:auto-cols-[calc((100%-(0.5rem*5))/6)] lg:gap-md'), children: games.map((game) => (_jsx(Item, { game: game, className: {
52
52
  thumbnailRoot: classNames.thumbnailRoot,
53
53
  thumbnailTitle: classNames.thumbnailTitle,
54
54
  } }, game.id))) }) })] }));
@@ -68,14 +68,14 @@ function Item({ game, className, }) {
68
68
  });
69
69
  },
70
70
  });
71
- return (_jsxs(GameLaunchTrigger, { game: game, className: twMerge('animate-scale-in relative block w-full shadow-sm transition-transform duration-200 hover:-translate-y-1', className?.thumbnailRoot), children: [session?.status === 'authenticated' && (_jsx("div", { role: "button", onClick: (e) => {
71
+ return (_jsxs(GameLaunchTrigger, { game: game, className: twMerge('hover:-translate-y-1 relative block w-full animate-scale-in shadow-sm transition-transform duration-200', className?.thumbnailRoot), children: [session?.status === 'authenticated' && (_jsx("div", { role: "button", tabIndex: 0, onClick: (e) => {
72
72
  e.preventDefault();
73
73
  e.stopPropagation();
74
74
  if (unmarkGameAsFavoriteMutation.isPending)
75
75
  return;
76
76
  unmarkGameAsFavoriteMutation.mutate(game.id);
77
- }, "aria-disabled": unmarkGameAsFavoriteMutation.isPending, className: "rounded-xs absolute right-2 top-2 flex size-9 items-center justify-center bg-black/65 blur-[0.5px]", children: _jsx(Star01Icon, { className: "fill-yellow-400 text-yellow-400 size-5" }) })), _jsx(Image, { src: getGameImageUrl({
77
+ }, "aria-disabled": unmarkGameAsFavoriteMutation.isPending, className: "absolute top-2 right-2 flex size-9 items-center justify-center rounded-xs bg-black/65 blur-[0.5px]", children: _jsx(Star01Icon, { className: "size-5 fill-yellow-400 text-yellow-400" }) })), _jsx(Image, { src: getGameImageUrl({
78
78
  id: game.id,
79
79
  provider: game.provider,
80
- }), alt: "", width: 200, height: 200, loading: "lazy", unoptimized: true, className: "aspect-square w-full rounded-t-md object-cover" }), _jsx("span", { className: twMerge('bg-bg-tertiary text-text-primary-brand block w-full truncate rounded-b-md px-2 py-3.5 text-center text-xs font-semibold', className?.thumbnailTitle), children: game.name })] }));
80
+ }), alt: "", width: 200, height: 200, loading: "lazy", unoptimized: true, className: "aspect-square w-full rounded-t-md object-cover" }), _jsx("span", { className: twMerge('block w-full truncate rounded-b-md bg-bg-tertiary px-2 py-3.5 text-center font-semibold text-text-primary-brand text-xs', className?.thumbnailTitle), children: game.name })] }));
81
81
  }
@@ -15,5 +15,5 @@ export function ForgotPassword(props) {
15
15
  })));
16
16
  return (_jsx(Dialog.Root, { open: globalStore.forgotPassword.open, onOpenChange: (details) => {
17
17
  globalStore.forgotPassword.setOpen(details.open);
18
- }, lazyMount: true, unmountOnExit: true, closeOnEscape: false, closeOnInteractOutside: false, children: _jsxs(Portal, { children: [_jsx(Dialog.Backdrop, {}), _jsx(Dialog.Positioner, { children: _jsxs(Dialog.Content, { className: twMerge('bg-bg-primary-alt mx-auto h-full w-full items-start p-3xl pb-4xl lg:h-auto lg:w-[400px] lg:rounded-xl', props.className), children: [_jsx(Dialog.CloseTrigger, { children: _jsx(XIcon, {}) }), _jsx(Image, { src: props.logo, alt: "", width: 200, height: 100, className: "mx-auto h-auto w-[120px]", draggable: false }), _jsx(Suspense, { children: _jsx(ForgotPasswordForm, {}) })] }) })] }) }));
18
+ }, lazyMount: true, unmountOnExit: true, closeOnEscape: false, closeOnInteractOutside: false, children: _jsxs(Portal, { children: [_jsx(Dialog.Backdrop, {}), _jsx(Dialog.Positioner, { children: _jsxs(Dialog.Content, { className: twMerge('mx-auto h-full w-full items-start bg-bg-primary-alt p-3xl pb-4xl lg:h-auto lg:w-[400px] lg:rounded-xl', props.className), children: [_jsx(Dialog.CloseTrigger, { children: _jsx(XIcon, {}) }), _jsx(Image, { src: props.logo, alt: "", width: 200, height: 100, className: "mx-auto h-auto w-[120px]", draggable: false }), _jsx(Suspense, { children: _jsx(ForgotPasswordForm, {}) })] }) })] }) }));
19
19
  }
@@ -99,7 +99,7 @@ export function ForgotPasswordForm() {
99
99
  duration: 1000 * 60,
100
100
  });
101
101
  const form2Ref = useRef(null);
102
- return (_jsxs(_Fragment, { children: [step === 1 && (_jsxs(_Fragment, { children: [_jsx("h2", { className: "mt-xl text-center text-lg font-semibold", children: "Forgot Password" }), _jsx("p", { className: "text-text-secondary-700 mt-xs text-center text-sm", children: "Your new password will be used to sign in." }), _jsxs("form", { className: "mt-3xl", onSubmit: step1Form.handleSubmit(async (data) => {
102
+ return (_jsxs(_Fragment, { children: [step === 1 && (_jsxs(_Fragment, { children: [_jsx("h2", { className: "mt-xl text-center font-semibold text-lg", children: "Forgot Password" }), _jsx("p", { className: "mt-xs text-center text-sm text-text-secondary-700", children: "Your new password will be used to sign in." }), _jsxs("form", { className: "mt-3xl", onSubmit: step1Form.handleSubmit(async (data) => {
103
103
  try {
104
104
  await sendVerificationCodeMutation.mutateAsync({
105
105
  channel: 'SMS',
@@ -115,9 +115,9 @@ export function ForgotPasswordForm() {
115
115
  : 'Failed to send verification code',
116
116
  });
117
117
  }
118
- }), children: [_jsxs(Field.Root, { invalid: !!step1Form.formState.errors.mobileNumber, children: [_jsx(Field.Label, { children: "Mobile Number" }), _jsxs("div", { className: "relative", children: [_jsxs("div", { className: "absolute left-3.5 top-1/2 flex shrink-0 -translate-y-1/2 items-center gap-md", children: [_jsx(localeInfo.country.flag, { className: "size-5" }), _jsx("span", { className: "text-text-placeholder", children: localeInfo.mobileNumber.areaCode })] }), _jsx(Field.Input, { style: {
118
+ }), children: [_jsxs(Field.Root, { invalid: !!step1Form.formState.errors.mobileNumber, children: [_jsx(Field.Label, { children: "Mobile Number" }), _jsxs("div", { className: "relative", children: [_jsxs("div", { className: "-translate-y-1/2 absolute top-1/2 left-3.5 flex shrink-0 items-center gap-md", children: [_jsx(localeInfo.country.flag, { className: "size-5" }), _jsx("span", { className: "text-text-placeholder", children: localeInfo.mobileNumber.areaCode })] }), _jsx(Field.Input, { style: {
119
119
  paddingLeft: `calc(2.75rem + ${localeInfo.mobileNumber.areaCode.length}ch)`,
120
- }, ...step1Form.register('mobileNumber') })] }), _jsx(Field.ErrorText, { children: step1Form.formState.errors.mobileNumber?.message })] }), _jsx(Field.Root, { invalid: !!step1Form.formState.errors.newPassword, className: "mt-xl", children: _jsxs(PasswordInput.Root, { children: [_jsx(PasswordInput.Label, { children: "New Password" }), _jsxs(PasswordInput.Control, { children: [_jsx(PasswordInput.Input, { placeholder: "Enter your new password", ...step1Form.register('newPassword') }), _jsx(PasswordInput.VisibilityTrigger, { children: _jsx(PasswordInput.Indicator, { fallback: _jsx(EyeOffIcon, {}), asChild: true, children: _jsx(EyeIcon, {}) }) })] }), _jsx(Field.ErrorText, { children: step1Form.formState.errors.newPassword?.message })] }) }), _jsx(Field.Root, { invalid: !!step1Form.formState.errors.confirmPassword, className: "mt-xl", children: _jsxs(PasswordInput.Root, { children: [_jsx(PasswordInput.Label, { children: "Confirm Password" }), _jsxs(PasswordInput.Control, { children: [_jsx(PasswordInput.Input, { placeholder: "Confirm new password", ...step1Form.register('confirmPassword') }), _jsx(PasswordInput.VisibilityTrigger, { children: _jsx(PasswordInput.Indicator, { fallback: _jsx(EyeOffIcon, {}), asChild: true, children: _jsx(EyeIcon, {}) }) })] }), _jsx(Field.ErrorText, { children: step1Form.formState.errors.confirmPassword?.message })] }) }), _jsx(Button, { type: "submit", className: "mt-3xl", disabled: step1Form.formState.isSubmitting, children: "Continue" })] })] })), step === 2 && (_jsxs(_Fragment, { children: [_jsx("h2", { className: "mt-xl text-center text-lg font-semibold", children: "Check your Phone" }), _jsxs("p", { className: "text-text-secondary-700 mt-xs text-center text-sm", children: ["We\u2019ve sent a verification code to your mobile number", ' ', _jsx("span", { className: "font-semibold", children: mobileNumberParser.format(step1Form.getValues('mobileNumber')) }), ' ', "via text"] }), _jsxs("form", { ref: form2Ref, className: "mt-5", autoComplete: "off", onSubmit: step2Form.handleSubmit(async ({ verificationCode }) => {
120
+ }, ...step1Form.register('mobileNumber') })] }), _jsx(Field.ErrorText, { children: step1Form.formState.errors.mobileNumber?.message })] }), _jsx(Field.Root, { invalid: !!step1Form.formState.errors.newPassword, className: "mt-xl", children: _jsxs(PasswordInput.Root, { children: [_jsx(PasswordInput.Label, { children: "New Password" }), _jsxs(PasswordInput.Control, { children: [_jsx(PasswordInput.Input, { placeholder: "Enter your new password", ...step1Form.register('newPassword') }), _jsx(PasswordInput.VisibilityTrigger, { children: _jsx(PasswordInput.Indicator, { fallback: _jsx(EyeOffIcon, {}), asChild: true, children: _jsx(EyeIcon, {}) }) })] }), _jsx(Field.ErrorText, { children: step1Form.formState.errors.newPassword?.message })] }) }), _jsx(Field.Root, { invalid: !!step1Form.formState.errors.confirmPassword, className: "mt-xl", children: _jsxs(PasswordInput.Root, { children: [_jsx(PasswordInput.Label, { children: "Confirm Password" }), _jsxs(PasswordInput.Control, { children: [_jsx(PasswordInput.Input, { placeholder: "Confirm new password", ...step1Form.register('confirmPassword') }), _jsx(PasswordInput.VisibilityTrigger, { children: _jsx(PasswordInput.Indicator, { fallback: _jsx(EyeOffIcon, {}), asChild: true, children: _jsx(EyeIcon, {}) }) })] }), _jsx(Field.ErrorText, { children: step1Form.formState.errors.confirmPassword?.message })] }) }), _jsx(Button, { type: "submit", className: "mt-3xl", disabled: step1Form.formState.isSubmitting, children: "Continue" })] })] })), step === 2 && (_jsxs(_Fragment, { children: [_jsx("h2", { className: "mt-xl text-center font-semibold text-lg", children: "Check your Phone" }), _jsxs("p", { className: "mt-xs text-center text-sm text-text-secondary-700", children: ["We\u2019ve sent a verification code to your mobile number", ' ', _jsx("span", { className: "font-semibold", children: mobileNumberParser.format(step1Form.getValues('mobileNumber')) }), ' ', "via text"] }), _jsxs("form", { ref: form2Ref, className: "mt-5", autoComplete: "off", onSubmit: step2Form.handleSubmit(async ({ verificationCode }) => {
121
121
  resetPasswordMutation.mutate({
122
122
  mobileNumber: mobileNumberParser.format(step1Form.getValues('mobileNumber')),
123
123
  newPassword: step1Form.getValues('newPassword'),
@@ -127,7 +127,7 @@ export function ForgotPasswordForm() {
127
127
  o.field.onChange(details.value);
128
128
  }, onValueComplete: () => {
129
129
  form2Ref.current?.requestSubmit();
130
- }, blurOnComplete: true, readOnly: step2Form.formState.isSubmitting, type: "numeric", children: [_jsxs(PinInput.Control, { className: "grid-cols-[1fr_1fr_1fr_auto_1fr_1fr_1fr] items-center gap-md", children: [_jsx(PinInput.Input, { index: 0 }), _jsx(PinInput.Input, { index: 1 }), _jsx(PinInput.Input, { index: 2 }), _jsx("span", { className: "text-text-placeholder-subtle text-2xl font-medium", children: "\u2013" }), _jsx(PinInput.Input, { index: 3 }), _jsx(PinInput.Input, { index: 4 }), _jsx(PinInput.Input, { index: 5 })] }), _jsx(PinInput.HiddenInput, {})] }), _jsx(Field.ErrorText, { children: o.formState.errors.verificationCode?.message })] })) }), _jsx(Button, { type: "submit", className: "mt-4xl", disabled: resetPasswordMutation.isPending, children: "Verify" }), _jsxs("div", { className: "mt-3 flex w-full items-center justify-center gap-xs text-sm", children: [_jsx("span", { className: "text-text-secondary-700", children: "Didn't recieve the code?" }), _jsx("button", { type: "button", className: "text-button-secondary-fg font-semibold disabled:cursor-not-allowed disabled:opacity-75", disabled: cooldown.cooling, onClick: async () => {
130
+ }, blurOnComplete: true, readOnly: step2Form.formState.isSubmitting, type: "numeric", children: [_jsxs(PinInput.Control, { className: "grid-cols-[1fr_1fr_1fr_auto_1fr_1fr_1fr] items-center gap-md", children: [_jsx(PinInput.Input, { index: 0 }), _jsx(PinInput.Input, { index: 1 }), _jsx(PinInput.Input, { index: 2 }), _jsx("span", { className: "font-medium text-2xl text-text-placeholder-subtle", children: "\u2013" }), _jsx(PinInput.Input, { index: 3 }), _jsx(PinInput.Input, { index: 4 }), _jsx(PinInput.Input, { index: 5 })] }), _jsx(PinInput.HiddenInput, {})] }), _jsx(Field.ErrorText, { children: o.formState.errors.verificationCode?.message })] })) }), _jsx(Button, { type: "submit", className: "mt-4xl", disabled: resetPasswordMutation.isPending, children: "Verify" }), _jsxs("div", { className: "mt-3 flex w-full items-center justify-center gap-xs text-sm", children: [_jsx("span", { className: "text-text-secondary-700", children: "Didn't recieve the code?" }), _jsx("button", { type: "button", className: "font-semibold text-button-secondary-fg disabled:cursor-not-allowed disabled:opacity-75", disabled: cooldown.cooling, onClick: async () => {
131
131
  await sendVerificationCodeMutation.mutateAsync({
132
132
  channel: 'SMS',
133
133
  recipient: mobileNumberParser.format(step1Form.getValues('mobileNumber')),
@@ -135,7 +135,7 @@ export function ForgotPasswordForm() {
135
135
  cooldown.start();
136
136
  }, children: cooldown.cooling
137
137
  ? `Resend in ${cooldown.countdown}s`
138
- : 'Resend' })] }), _jsxs("button", { type: "button", className: "text-text-tertiary-600 mx-auto mt-3xl flex w-fit items-center gap-1 text-sm font-semibold", onClick: () => {
138
+ : 'Resend' })] }), _jsxs("button", { type: "button", className: "mx-auto mt-3xl flex w-fit items-center gap-1 font-semibold text-sm text-text-tertiary-600", onClick: () => {
139
139
  setStep(1);
140
140
  step2Form.reset();
141
141
  cooldown.stop();
@@ -13,5 +13,5 @@ export function GCashFailed(props) {
13
13
  router.replace('/');
14
14
  },
15
15
  });
16
- return (_jsx("div", { style: props.style, className: twMerge('flex min-h-dvh items-center p-4 py-8', props.className), children: _jsxs("div", { className: "bg-bg-primary-alt mx-auto w-full max-w-[26.25rem] rounded-xl p-10", children: [_jsx(Image, { src: props.logo, alt: "", width: 200, height: 100, className: "mx-auto block h-7.5 w-auto" }), _jsxs("div", { className: "mt-16", children: [_jsx(XCircleIcon, { className: "text-utility-error-500 mx-auto size-[3.75rem]" }), _jsx("h2", { className: "mt-6 text-center text-3xl font-bold", children: "Deposit Error" }), _jsx("p", { className: "text-text-tertiary-600 mt-3 text-center", children: "Sorry, we encountered an error while processing your deposit request. Please try again later." }), _jsxs("div", { className: "text-text-tertiary-600 mt-[4.875rem] text-center text-sm", children: [_jsx("p", { children: "You will be redirected shortly," }), _jsxs("p", { children: ["in about", ' ', _jsx("span", { className: "text-brand-400 text-lg font-bold", children: cooldown.countdown }), ' ', "second/s."] })] })] })] }) }));
16
+ return (_jsx("div", { style: props.style, className: twMerge('flex min-h-dvh items-center p-4 py-8', props.className), children: _jsxs("div", { className: "mx-auto w-full max-w-[26.25rem] rounded-xl bg-bg-primary-alt p-10", children: [_jsx(Image, { src: props.logo, alt: "", width: 200, height: 100, className: "mx-auto block h-7.5 w-auto" }), _jsxs("div", { className: "mt-16", children: [_jsx(XCircleIcon, { className: "mx-auto size-[3.75rem] text-utility-error-500" }), _jsx("h2", { className: "mt-6 text-center font-bold text-3xl", children: "Deposit Error" }), _jsx("p", { className: "mt-3 text-center text-text-tertiary-600", children: "Sorry, we encountered an error while processing your deposit request. Please try again later." }), _jsxs("div", { className: "mt-[4.875rem] text-center text-sm text-text-tertiary-600", children: [_jsx("p", { children: "You will be redirected shortly," }), _jsxs("p", { children: ["in about", ' ', _jsx("span", { className: "font-bold text-brand-400 text-lg", children: cooldown.countdown }), ' ', "second/s."] })] })] })] }) }));
17
17
  }
@@ -84,5 +84,5 @@ export function GCashSuccess(props) {
84
84
  useEffect(() => {
85
85
  init();
86
86
  }, [init]);
87
- return (_jsx("div", { style: props.style, className: twMerge('flex min-h-dvh items-center p-4 py-8', props.className), children: _jsxs("div", { className: "bg-bg-primary-alt mx-auto w-full max-w-[26.25rem] rounded-xl p-10", children: [_jsx(Image, { src: props.logo, alt: "", width: 200, height: 100, className: "mx-auto block h-7.5 w-auto" }), _jsx("div", { className: "mt-16", children: loading ? (_jsx(SpinnerIcon, { className: "mx-auto size-8" })) : (_jsxs(_Fragment, { children: [_jsx(CheckCircleIcon, { className: "text-utility-success-500 mx-auto size-[3.75rem]" }), _jsx("h2", { className: "mt-6 text-center text-3xl font-bold", children: "Success" }), _jsx("p", { className: "text-text-tertiary-600 mt-3 text-center", children: "Your deposit request has succeeded." }), _jsxs("div", { className: "text-text-tertiary-600 mt-10 text-center text-sm", children: [_jsx("p", { children: "You will be redirected shortly," }), _jsxs("p", { children: ["in about", ' ', _jsx("span", { className: "text-brand-400 text-lg font-bold", children: cooldown.countdown }), ' ', "second/s."] })] }), _jsx(Button, { variant: "outline", asChild: true, children: _jsx(Link, { href: "/", replace: true, className: "mt-14", children: "Proceed" }) })] })) })] }) }));
87
+ return (_jsx("div", { style: props.style, className: twMerge('flex min-h-dvh items-center p-4 py-8', props.className), children: _jsxs("div", { className: "mx-auto w-full max-w-[26.25rem] rounded-xl bg-bg-primary-alt p-10", children: [_jsx(Image, { src: props.logo, alt: "", width: 200, height: 100, className: "mx-auto block h-7.5 w-auto" }), _jsx("div", { className: "mt-16", children: loading ? (_jsx(SpinnerIcon, { className: "mx-auto size-8" })) : (_jsxs(_Fragment, { children: [_jsx(CheckCircleIcon, { className: "mx-auto size-[3.75rem] text-utility-success-500" }), _jsx("h2", { className: "mt-6 text-center font-bold text-3xl", children: "Success" }), _jsx("p", { className: "mt-3 text-center text-text-tertiary-600", children: "Your deposit request has succeeded." }), _jsxs("div", { className: "mt-10 text-center text-sm text-text-tertiary-600", children: [_jsx("p", { children: "You will be redirected shortly," }), _jsxs("p", { children: ["in about", ' ', _jsx("span", { className: "font-bold text-brand-400 text-lg", children: cooldown.countdown }), ' ', "second/s."] })] }), _jsx(Button, { variant: "outline", asChild: true, children: _jsx(Link, { href: "/", replace: true, className: "mt-14", children: "Proceed" }) })] })) })] }) }));
88
88
  }
@@ -79,7 +79,7 @@ export function GameLaunch() {
79
79
  : favoriteGame.id === globalStore.gameLaunch.details.game.id;
80
80
  });
81
81
  return (_jsxs(_Fragment, { children: [_jsx(Dialog.Root, { open: globalStore.gameLaunch.details.status !== 'WAITING' &&
82
- !cancelDisclosure.open, lazyMount: true, closeOnEscape: false, closeOnInteractOutside: false, children: _jsx(Portal, { children: _jsx(Dialog.Positioner, { className: "z-dialog fixed inset-0", children: _jsxs(Dialog.Content, { className: "ui-open:animate-dialog-in ui-closed:animate-dialog-out bg-bg-primary-alt relative size-full overflow-y-auto", children: [_jsx(Presence, { asChild: true, lazyMount: true, unmountOnExit: true, present: !maximizeDisclosure.open, children: _jsxs("section", { className: "ui-open:animate-slide-in-down ui-closed:animate-slide-out-down bg-bg-primary-alt z-1 absolute left-0 top-0 flex h-[3.25rem] w-full items-center gap-2 px-4 py-2", children: [_jsx(IconButton, { size: "xs", variant: "outline", onClick: () => {
82
+ !cancelDisclosure.open, lazyMount: true, closeOnEscape: false, closeOnInteractOutside: false, children: _jsx(Portal, { children: _jsx(Dialog.Positioner, { className: "fixed inset-0 z-dialog", children: _jsxs(Dialog.Content, { className: "relative size-full ui-closed:animate-dialog-out ui-open:animate-dialog-in overflow-y-auto bg-bg-primary-alt", children: [_jsx(Presence, { asChild: true, lazyMount: true, unmountOnExit: true, present: !maximizeDisclosure.open, children: _jsxs("section", { className: "absolute top-0 left-0 z-1 flex h-[3.25rem] w-full ui-closed:animate-slide-out-down ui-open:animate-slide-in-down items-center gap-2 bg-bg-primary-alt px-4 py-2", children: [_jsx(IconButton, { size: "xs", variant: "outline", onClick: () => {
83
83
  if (globalStore.gameLaunch.details.status !== 'PLAYING') {
84
84
  endGameSession();
85
85
  return;
@@ -100,12 +100,12 @@ export function GameLaunch() {
100
100
  : globalStore.gameLaunch.details.game.id);
101
101
  }
102
102
  }, children: _jsx(Star01Icon, { className: twMerge('size-5', markedAsFavorite
103
- ? 'text-yellow-400 fill-yellow-400'
103
+ ? 'fill-yellow-400 text-yellow-400'
104
104
  : 'text-inherit') }) }), _jsx(IconButton, { size: "xs", variant: "outline", onClick: () => maximizeDisclosure.setOpen(true), children: _jsx(Expand03Icon, { className: "size-5" }) }), _jsx(IconButton, { size: "xs", fullWidth: false, onClick: () => {
105
105
  globalStore.depositWithdrawal.setOpen(true);
106
- }, children: _jsx(CoinsHandIcon, { className: "size-5" }) })] }) }), _jsx(Presence, { asChild: true, lazyMount: true, unmountOnExit: true, present: maximizeDisclosure.open, children: _jsx("button", { type: "button", onClick: () => maximizeDisclosure.setOpen(false), className: "shadow-xs ui-open:animate-slide-in-down ui-closed:animate-slide-out-down z-1 absolute left-1/2 top-0 flex h-7.5 w-[4.5rem] -translate-x-1/2 items-center justify-center rounded-b-md bg-white/30 backdrop-blur-sm", children: _jsx(ChevronDownIcon, {}) }) }), _jsxs("section", { className: "size-full", children: [globalStore.gameLaunch.details.status === 'LOADING' && (_jsx("div", { className: "flex size-full items-center justify-center", children: _jsx(SpinnerIcon, { className: "size-8" }) })), globalStore.gameLaunch.details.status === 'FAILED' && (_jsx("div", {})), globalStore.gameLaunch.details.status === 'PLAYING' && (_jsx("iframe", { src: globalStore.gameLaunch.details.session.launchUrl ?? '', className: "size-full" }))] })] }) }) }) }), _jsx(AlertDialog.Root, { role: "alertdialog", open: cancelDisclosure.open, onOpenChange: (details) => {
106
+ }, children: _jsx(CoinsHandIcon, { className: "size-5" }) })] }) }), _jsx(Presence, { asChild: true, lazyMount: true, unmountOnExit: true, present: maximizeDisclosure.open, children: _jsx("button", { type: "button", onClick: () => maximizeDisclosure.setOpen(false), className: "-translate-x-1/2 absolute top-0 left-1/2 z-1 flex h-7.5 w-[4.5rem] ui-closed:animate-slide-out-down ui-open:animate-slide-in-down items-center justify-center rounded-b-md bg-white/30 shadow-xs backdrop-blur-sm", children: _jsx(ChevronDownIcon, {}) }) }), _jsxs("section", { className: "size-full", children: [globalStore.gameLaunch.details.status === 'LOADING' && (_jsx("div", { className: "flex size-full items-center justify-center", children: _jsx(SpinnerIcon, { className: "size-8" }) })), globalStore.gameLaunch.details.status === 'FAILED' && (_jsx("div", {})), globalStore.gameLaunch.details.status === 'PLAYING' && (_jsx("iframe", { src: globalStore.gameLaunch.details.session.launchUrl ?? '', title: "Game Launch", className: "size-full" }))] })] }) }) }) }), _jsx(AlertDialog.Root, { role: "alertdialog", open: cancelDisclosure.open, onOpenChange: (details) => {
107
107
  cancelDisclosure.setOpen(details.open);
108
- }, lazyMount: true, closeOnEscape: false, closeOnInteractOutside: false, children: _jsxs(Portal, { children: [_jsx(AlertDialog.Backdrop, {}), _jsx(AlertDialog.Positioner, { children: _jsxs(AlertDialog.Content, { children: [_jsx(AlertDialog.CloseTrigger, { children: _jsx(XIcon, {}) }), _jsx(AlertDialog.Header, { children: _jsx("div", { className: "bg-bg-error-secondary text-text-featured-icon-light-error flex size-12 items-center justify-center rounded-full", children: _jsx(AlertCircleIcon, { className: "size-6" }) }) }), _jsxs(AlertDialog.Body, { children: [_jsx(AlertDialog.Title, { children: "Quit Game" }), _jsx(AlertDialog.Description, { children: "Are you sure you want to quit?" })] }), _jsx(AlertDialog.Context, { children: (api) => (_jsxs(AlertDialog.Footer, { children: [_jsx(Button, { variant: "outline", colorScheme: "gray", disabled: endGameSessionMutation.isPending, onClick: () => {
108
+ }, lazyMount: true, closeOnEscape: false, closeOnInteractOutside: false, children: _jsxs(Portal, { children: [_jsx(AlertDialog.Backdrop, {}), _jsx(AlertDialog.Positioner, { children: _jsxs(AlertDialog.Content, { children: [_jsx(AlertDialog.CloseTrigger, { children: _jsx(XIcon, {}) }), _jsx(AlertDialog.Header, { children: _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, { className: "size-6" }) }) }), _jsxs(AlertDialog.Body, { children: [_jsx(AlertDialog.Title, { children: "Quit Game" }), _jsx(AlertDialog.Description, { children: "Are you sure you want to quit?" })] }), _jsx(AlertDialog.Context, { children: (api) => (_jsxs(AlertDialog.Footer, { children: [_jsx(Button, { variant: "outline", colorScheme: "gray", disabled: endGameSessionMutation.isPending, onClick: () => {
109
109
  api.setOpen(false);
110
110
  }, children: "Cancel" }), _jsx(Button, { colorScheme: "danger", disabled: endGameSessionMutation.isPending, onClick: async () => {
111
111
  await endGameSession();
@@ -31,9 +31,10 @@ export function GameLaunchTrigger(props) {
31
31
  : globalStore.gameLaunch.details.status === 'WAITING'
32
32
  ? 'closed'
33
33
  : 'open', ...props, disabled: disabled, onClick: async (e) => {
34
+ props.onClick?.(e);
34
35
  if (sessionQuery.data?.status === 'unauthenticated') {
35
36
  globalStore.signIn.setOpen(true);
36
- return props.onClick?.(e);
37
+ return;
37
38
  }
38
39
  globalStore.gameLaunch.setDetails({
39
40
  game: props.game,
@@ -58,8 +59,5 @@ export function GameLaunchTrigger(props) {
58
59
  description: error instanceof Error ? error.message : 'Failed to launch game',
59
60
  });
60
61
  }
61
- finally {
62
- return props.onClick?.(e);
63
- }
64
62
  } }));
65
63
  }
@@ -56,5 +56,5 @@ export function GameProvidersCarousel(props) {
56
56
  const classNames = isString(props.className)
57
57
  ? { root: props.className }
58
58
  : (props.className ?? {});
59
- return (_jsxs("div", { className: classNames.root, children: [_jsxs("div", { className: "flex items-center", children: [_jsx("h2", { className: "text-lg font-semibold", children: props.heading ?? 'Providers' }), _jsx("div", { className: "grow" }), _jsxs("div", { className: "gap-xl flex items-center justify-center", children: [_jsxs(Link, { href: viewAllUrl, className: "text-button-tertiary-fg gap-sm flex text-sm font-semibold", children: ["See All", _jsx(ChevronRightIcon, { className: "size-5 lg:hidden" })] }), _jsxs("div", { className: "hidden lg:flex", children: [_jsx(Button, { variant: "outline", colorScheme: "gray", className: "rounded-r-none border-r-0", onClick: onPrevButtonClick, disabled: prevBtnDisabled, "aria-label": "Previous", children: _jsx(ArrowLeftIcon, { className: "size-5" }) }), _jsx(Button, { variant: "outline", colorScheme: "gray", className: "rounded-l-none", onClick: onNextButtonClick, disabled: nextBtnDisabled, "aria-label": "Next", children: _jsx(ArrowRightIcon, { className: "size-5" }) })] })] })] }), _jsx("div", { ref: emblaRef, className: "mt-lg relative lg:overflow-hidden", children: _jsx("div", { className: "gap-sm lg:gap-md grid auto-cols-[calc((100%-(0.375rem*2))/3)] grid-flow-col grid-rows-1 lg:auto-cols-[calc((100%-(0.5rem*5))/6)]", children: gameProviders.map((provider) => (_jsx(Link, { href: viewGamesUrl(provider), className: twMerge('bg-brand-800 flex h-full w-full items-center overflow-hidden rounded-md lg:h-[5.75rem]', classNames.thumbnailRoot), "aria-label": `View ${provider.name} games`, children: _jsx(Image, { src: props.gameProviderImages?.[provider.id] ?? provider.logo, alt: "", width: 300, height: 150, className: twMerge('mx-auto h-auto w-full', classNames.thumbnailImage) }) }, provider.id))) }) })] }));
59
+ return (_jsxs("div", { className: classNames.root, children: [_jsxs("div", { className: "flex items-center", children: [_jsx("h2", { className: "font-semibold text-lg", children: props.heading ?? 'Providers' }), _jsx("div", { className: "grow" }), _jsxs("div", { className: "flex items-center justify-center gap-xl", children: [_jsxs(Link, { href: viewAllUrl, className: "flex gap-sm font-semibold text-button-tertiary-fg text-sm", children: ["See All", _jsx(ChevronRightIcon, { className: "size-5 lg:hidden" })] }), _jsxs("div", { className: "hidden lg:flex", children: [_jsx(Button, { variant: "outline", colorScheme: "gray", className: "rounded-r-none border-r-0", onClick: onPrevButtonClick, disabled: prevBtnDisabled, "aria-label": "Previous", children: _jsx(ArrowLeftIcon, { className: "size-5" }) }), _jsx(Button, { variant: "outline", colorScheme: "gray", className: "rounded-l-none", onClick: onNextButtonClick, disabled: nextBtnDisabled, "aria-label": "Next", children: _jsx(ArrowRightIcon, { className: "size-5" }) })] })] })] }), _jsx("div", { ref: emblaRef, className: "relative mt-lg lg:overflow-hidden", children: _jsx("div", { className: "grid auto-cols-[calc((100%-(0.375rem*2))/3)] grid-flow-col grid-rows-1 gap-sm lg:auto-cols-[calc((100%-(0.5rem*5))/6)] lg:gap-md", children: gameProviders.map((provider) => (_jsx(Link, { href: viewGamesUrl(provider), className: twMerge('flex h-full w-full items-center overflow-hidden rounded-md bg-brand-800 lg:h-[5.75rem]', classNames.thumbnailRoot), "aria-label": `View ${provider.name} games`, children: _jsx(Image, { src: props.gameProviderImages?.[provider.id] ?? provider.logo, alt: "", width: 300, height: 150, className: twMerge('mx-auto h-auto w-full', classNames.thumbnailImage) }) }, provider.id))) }) })] }));
60
60
  }
@@ -27,5 +27,5 @@ export function GameProvidersList(props) {
27
27
  ? { root: props.className }
28
28
  : (props.className ?? {});
29
29
  const chunked = useChunk(gameProviders, 18);
30
- return (_jsxs("div", { className: classNames.root, children: [_jsx("h2", { className: "text-lg font-semibold", children: props.heading ?? 'Providers' }), _jsx("div", { className: "mt-lg grid grid-cols-3 gap-1.5 lg:grid-cols-6 lg:gap-2.5", children: chunked.loadedItems.map((provider) => (_jsx(Link, { href: viewGamesUrl(provider), className: twMerge('bg-brand-800 flex h-full w-full items-center overflow-hidden rounded-md lg:h-[5.75rem]', classNames.thumbnailRoot), "aria-label": `View ${provider.name} games`, children: _jsx(Image, { src: props.gameProviderImages?.[provider.id] ?? provider.logo, alt: "", width: 300, height: 150, className: twMerge('mx-auto h-auto w-full', classNames.thumbnailImage) }) }, provider.id))) }), _jsxs("div", { className: "mt-2xl lg:mt-3xl flex flex-col items-center", children: [_jsx(Progress.Root, { min: 0, max: chunked.totalItems, value: chunked.totalLoadedItems, onValueChange: noop, className: "w-[12.5rem]", children: _jsx(Progress.Track, { className: "bg-bg-tertiary", children: _jsx(Progress.Range, {}) }) }), _jsx("p", { className: "text-button-tertiary-fg mt-md text-sm", children: `Displaying ${chunked.totalLoadedItems} of ${chunked.totalItems}` }), chunked.hasNext && (_jsx(Button, { size: "sm", variant: "outline", fullWidth: false, onClick: chunked.next, className: "mt-lg", children: "Load More" }))] })] }));
30
+ return (_jsxs("div", { className: classNames.root, children: [_jsx("h2", { className: "font-semibold text-lg", children: props.heading ?? 'Providers' }), _jsx("div", { className: "mt-lg grid grid-cols-3 gap-1.5 lg:grid-cols-6 lg:gap-2.5", children: chunked.loadedItems.map((provider) => (_jsx(Link, { href: viewGamesUrl(provider), className: twMerge('flex h-full w-full items-center overflow-hidden rounded-md bg-brand-800 lg:h-[5.75rem]', classNames.thumbnailRoot), "aria-label": `View ${provider.name} games`, children: _jsx(Image, { src: props.gameProviderImages?.[provider.id] ?? provider.logo, alt: "", width: 300, height: 150, className: twMerge('mx-auto h-auto w-full', classNames.thumbnailImage) }) }, provider.id))) }), _jsxs("div", { className: "mt-2xl flex flex-col items-center lg:mt-3xl", children: [_jsx(Progress.Root, { min: 0, max: chunked.totalItems, value: chunked.totalLoadedItems, onValueChange: noop, className: "w-[12.5rem]", children: _jsx(Progress.Track, { className: "bg-bg-tertiary", children: _jsx(Progress.Range, {}) }) }), _jsx("p", { className: "mt-md text-button-tertiary-fg text-sm", children: `Displaying ${chunked.totalLoadedItems} of ${chunked.totalItems}` }), chunked.hasNext && (_jsx(Button, { size: "sm", variant: "outline", fullWidth: false, onClick: chunked.next, className: "mt-lg", children: "Load More" }))] })] }));
31
31
  }
@@ -48,7 +48,7 @@ export function Game(props) {
48
48
  const classNames = isString(props.className)
49
49
  ? { root: props.className }
50
50
  : (props.className ?? {});
51
- return (_jsxs(GameLaunchTrigger, { game: game, className: twMerge('animate-scale-in group relative block w-full shadow-sm transition-transform duration-200 md:hover:-translate-y-1', classNames.root), "aria-label": `Play ${game.name} game`, children: [props.badge === 'new' && (_jsx(BadgeNew, { className: "absolute left-0 top-0 size-[3.75rem]" })), props.badge === 'top' && (_jsx(BadgeTop, { className: "absolute left-0 top-0 size-[3.75rem]" })), props.badge === 'popular' && (_jsx(BadgePopular, { className: "absolute left-0 top-0 size-[3.75rem]" })), session?.status === 'authenticated' && (_jsx("div", { role: "button", onClick: (e) => {
51
+ return (_jsxs(GameLaunchTrigger, { game: game, className: twMerge('group md:hover:-translate-y-1 relative block w-full animate-scale-in shadow-sm transition-transform duration-200', classNames.root), "aria-label": `Play ${game.name} game`, children: [props.badge === 'new' && (_jsx(BadgeNew, { className: "absolute top-0 left-0 size-[3.75rem]" })), props.badge === 'top' && (_jsx(BadgeTop, { className: "absolute top-0 left-0 size-[3.75rem]" })), props.badge === 'popular' && (_jsx(BadgePopular, { className: "absolute top-0 left-0 size-[3.75rem]" })), session?.status === 'authenticated' && (_jsx("div", { role: "button", tabIndex: 0, onClick: (e) => {
52
52
  e.preventDefault();
53
53
  e.stopPropagation();
54
54
  if (markGameAsFavoriteMutation.isPending)
@@ -64,10 +64,10 @@ export function Game(props) {
64
64
  }, "aria-label": markedAsFavorite
65
65
  ? 'Unmark as favorite game'
66
66
  : 'Mark as favorite game', "aria-disabled": markGameAsFavoriteMutation.isPending ||
67
- unmarkGameAsFavoriteMutation.isPending, className: "rounded-xs absolute right-2 top-2 flex size-9 items-center justify-center bg-black/65 opacity-100 blur-[0.5px] transition-opacity duration-200 md:opacity-0 md:group-hover:opacity-100", children: _jsx(Star01Icon, { className: twMerge('hover:text-yellow-400 size-5 text-white transition-colors duration-200', markedAsFavorite
67
+ unmarkGameAsFavoriteMutation.isPending, className: "absolute top-2 right-2 flex size-9 items-center justify-center rounded-xs bg-black/65 opacity-100 blur-[0.5px] transition-opacity duration-200 md:opacity-0 md:group-hover:opacity-100", children: _jsx(Star01Icon, { className: twMerge('size-5 text-white transition-colors duration-200 hover:text-yellow-400', markedAsFavorite
68
68
  ? 'fill-yellow-400 text-yellow-400'
69
69
  : 'text-white') }) })), _jsx(Image, { src: getGameImageUrl({
70
70
  reference: game.reference,
71
71
  provider: game.provider,
72
- }), alt: "", width: 200, height: 200, loading: "lazy", unoptimized: true, className: "aspect-square w-full rounded-t-md object-cover" }), _jsx("span", { className: twMerge('bg-bg-tertiary text-text-primary-brand block w-full truncate rounded-b-md px-2 py-3.5 text-center text-xs font-semibold', classNames.title), children: game.name })] }));
72
+ }), alt: "", width: 200, height: 200, loading: "lazy", unoptimized: true, className: "aspect-square w-full rounded-t-md object-cover" }), _jsx("span", { className: twMerge('block w-full truncate rounded-b-md bg-bg-tertiary px-2 py-3.5 text-center font-semibold text-text-primary-brand text-xs', classNames.title), children: game.name })] }));
73
73
  }
@@ -23,9 +23,7 @@ export function GamesCarousel__client(props) {
23
23
  search: props.search,
24
24
  sort: props.sort,
25
25
  });
26
- const games = gamesQuery.data?.pages
27
- .map((page) => page.edges.map((edge) => edge.node))
28
- .flat() ?? [];
26
+ const games = gamesQuery.data?.pages.flatMap((page) => page.edges.map((edge) => edge.node)) ?? [];
29
27
  const [emblaRef, emblaApi] = useEmblaCarousel({
30
28
  align: 'start',
31
29
  slidesToScroll: 3,
@@ -59,7 +57,7 @@ export function GamesCarousel__client(props) {
59
57
  const classNames = isString(props.className)
60
58
  ? { root: props.className }
61
59
  : (props.className ?? {});
62
- return (_jsxs("div", { className: classNames.root, children: [_jsxs("div", { className: "flex items-center", children: [_jsx("h2", { className: "text-lg font-semibold", children: props.heading ?? 'Games' }), _jsx("div", { className: "grow" }), _jsxs("div", { className: "flex items-center justify-center gap-xl", children: [_jsxs(Link, { href: props.viewAllUrl ?? '/games', 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, { variant: "outline", colorScheme: "gray", className: "rounded-r-none border-r-0", onClick: onPrevButtonClick, disabled: prevBtnDisabled, "aria-label": "Previous", children: _jsx(ArrowLeftIcon, { className: "size-5" }) }), _jsx(Button, { variant: "outline", colorScheme: "gray", className: "rounded-l-none", onClick: onNextButtonClick, disabled: nextBtnDisabled && !gamesQuery.hasNextPage
60
+ return (_jsxs("div", { className: classNames.root, children: [_jsxs("div", { className: "flex items-center", children: [_jsx("h2", { className: "font-semibold text-lg", children: props.heading ?? 'Games' }), _jsx("div", { className: "grow" }), _jsxs("div", { className: "flex items-center justify-center gap-xl", children: [_jsxs(Link, { href: props.viewAllUrl ?? '/games', className: "flex gap-sm font-semibold text-button-tertiary-fg text-sm", children: ["See All", _jsx(ChevronRightIcon, { className: "size-5 lg:hidden" })] }), _jsxs("div", { className: "hidden lg:flex", children: [_jsx(Button, { variant: "outline", colorScheme: "gray", className: "rounded-r-none border-r-0", onClick: onPrevButtonClick, disabled: prevBtnDisabled, "aria-label": "Previous", children: _jsx(ArrowLeftIcon, { className: "size-5" }) }), _jsx(Button, { variant: "outline", colorScheme: "gray", className: "rounded-l-none", onClick: onNextButtonClick, disabled: nextBtnDisabled && !gamesQuery.hasNextPage
63
61
  ? true
64
62
  : gamesQuery.isFetchingNextPage, "aria-label": "Next", children: gamesQuery.isFetchingNextPage ? (_jsx(SpinnerIcon, { className: "size-5" })) : (_jsx(ArrowRightIcon, { className: "size-5" })) })] })] })] }), games.length <= 0 && (_jsx(Empty, { icon: GamingPad01Icon, title: "No games", message: "No game is currently available. Please check back later", className: "mt-lg" })), games.length >= 1 && (_jsx("div", { ref: emblaRef, className: "relative mt-lg lg:overflow-hidden", children: _jsx("div", { className: twMerge('grid auto-cols-[calc((100%-(0.375rem*2))/3)] grid-flow-col gap-sm lg:auto-cols-[calc((100%-(0.5rem*5))/6)] lg:gap-md', numOfRows === 3
65
63
  ? 'grid-rows-3'
@@ -22,10 +22,10 @@ export function GamesList__client(props) {
22
22
  const classNames = isString(props.className)
23
23
  ? { root: props.className }
24
24
  : (props.className ?? {});
25
- return (_jsxs("div", { className: classNames.root, children: [_jsxs("div", { className: "flex flex-col lg:flex-row lg:items-center lg:justify-between", children: [_jsx("h2", { className: "order-2 mt-4xl text-lg font-semibold lg:order-none lg:mt-0", children: props.heading ?? 'Games' }), props.viewGameProvidersUrl && (_jsxs(Link, { href: props.viewGameProvidersUrl, className: "text-button-tertiary-fg order-1 flex items-center gap-sm text-lg font-semibold lg:order-none lg:text-sm", children: [_jsx(ChevronLeftIcon, { className: "size-5" }), "Back to all Providers"] }))] }), totalRows <= 0 && (_jsx(Empty, { icon: loading ? SpinnerIcon : GamingPad01Icon, title: loading ? 'Just a moment' : 'No games', message: loading
25
+ return (_jsxs("div", { className: classNames.root, children: [_jsxs("div", { className: "flex flex-col lg:flex-row lg:items-center lg:justify-between", children: [_jsx("h2", { className: "order-2 mt-4xl font-semibold text-lg lg:order-none lg:mt-0", children: props.heading ?? 'Games' }), props.viewGameProvidersUrl && (_jsxs(Link, { href: props.viewGameProvidersUrl, className: "order-1 flex items-center gap-sm font-semibold text-button-tertiary-fg text-lg lg:order-none lg:text-sm", children: [_jsx(ChevronLeftIcon, { className: "size-5" }), "Back to all Providers"] }))] }), totalRows <= 0 && (_jsx(Empty, { icon: loading ? SpinnerIcon : GamingPad01Icon, title: loading ? 'Just a moment' : 'No games', message: loading
26
26
  ? 'Fetching latest games...'
27
27
  : 'No game is currently available. Please check back later', className: "mt-lg" })), totalRows >= 1 && (_jsxs(_Fragment, { children: [_jsx("div", { className: "mt-lg grid grid-cols-3 gap-1.5 lg:grid-cols-6 lg:gap-2.5", children: availableRows.map((game) => (_jsx(GameContext, { value: game, children: _jsx(Game, { badge: props.badge, className: {
28
28
  root: classNames.thumbnailRoot,
29
29
  title: classNames.thumbnailTitle,
30
- } }) }, game.id))) }), _jsxs("div", { className: "mt-2xl flex flex-col items-center lg:mt-3xl", children: [_jsx(Progress.Root, { min: 0, max: totalRows, value: totalAvailableRows, onValueChange: noop, className: "w-[12.5rem]", children: _jsx(Progress.Track, { className: "bg-bg-tertiary", children: _jsx(Progress.Range, {}) }) }), _jsx("p", { className: "text-button-tertiary-fg mt-md text-sm", children: `Displaying ${totalAvailableRows} of ${totalRows}` }), hasNextPage && (_jsx(Button, { size: "sm", variant: "outline", fullWidth: false, onClick: next, className: "mt-lg", children: "Load More" }))] })] }))] }));
30
+ } }) }, game.id))) }), _jsxs("div", { className: "mt-2xl flex flex-col items-center lg:mt-3xl", children: [_jsx(Progress.Root, { min: 0, max: totalRows, value: totalAvailableRows, onValueChange: noop, className: "w-[12.5rem]", children: _jsx(Progress.Track, { className: "bg-bg-tertiary", children: _jsx(Progress.Range, {}) }) }), _jsx("p", { className: "mt-md text-button-tertiary-fg text-sm", children: `Displaying ${totalAvailableRows} of ${totalRows}` }), hasNextPage && (_jsx(Button, { size: "sm", variant: "outline", fullWidth: false, onClick: next, className: "mt-lg", children: "Load More" }))] })] }))] }));
31
31
  }
@@ -23,9 +23,7 @@ export function GamesSearch(props) {
23
23
  }, {
24
24
  enabled: search.length >= 3,
25
25
  });
26
- const games = gamesQuery.data?.pages
27
- .map((page) => page.edges.map((edge) => edge.node))
28
- .flat() ?? [];
26
+ const games = gamesQuery.data?.pages.flatMap((page) => page.edges.map((edge) => edge.node)) ?? [];
29
27
  const collection = createListCollection({
30
28
  items: games,
31
29
  itemToValue: (item) => item.id,
@@ -42,7 +40,7 @@ export function GamesSearch(props) {
42
40
  }, selectionBehavior: "preserve", allowCustomValue: true, children: [_jsxs(Combobox.Control, { className: "relative z-50", children: [_jsx(Combobox.Input, { placeholder: props.placeholder ?? 'Search' }), _jsx(Combobox.Context, { children: (api) => {
43
41
  if (api.inputValue.length <= 0)
44
42
  return null;
45
- return (_jsx("span", { className: "text-text-secondary-700 cursor-pointer px-3.5 font-semibold", tabIndex: 0, onClick: () => {
43
+ return (_jsx("span", { className: "cursor-pointer px-3.5 font-semibold text-text-secondary-700", onClick: () => {
46
44
  api.setInputValue('');
47
45
  api.focus();
48
46
  }, children: "Clear" }));
@@ -51,8 +49,8 @@ export function GamesSearch(props) {
51
49
  }, className: twMerge('block w-full shadow-sm', classNames.thumbnailRoot), children: [_jsx(Image, { src: getGameImageUrl({
52
50
  reference: game.reference,
53
51
  provider: game.provider,
54
- }), alt: "", width: 200, height: 200, loading: "lazy", unoptimized: true, className: "aspect-square w-full rounded-t-md object-cover" }), _jsx("span", { className: twMerge('bg-bg-tertiary text-text-primary-brand block w-full truncate rounded-b-md px-2 py-2.5 text-center text-xs font-semibold', classNames.thumbnailTitle), children: game.name })] }, game.id))) })) }), _jsx(Presence, { present: gamesQuery.hasNextPage, children: _jsx(Button, { variant: "outline", className: "mx-auto mt-4xl w-fit", onClick: () => gamesQuery.fetchNextPage(), children: "Load More" }) })] }))] })) })) })] })) }) })] }) }));
52
+ }), alt: "", width: 200, height: 200, loading: "lazy", unoptimized: true, className: "aspect-square w-full rounded-t-md object-cover" }), _jsx("span", { className: twMerge('block w-full truncate rounded-b-md bg-bg-tertiary px-2 py-2.5 text-center font-semibold text-text-primary-brand text-xs', classNames.thumbnailTitle), children: game.name })] }, game.id))) })) }), _jsx(Presence, { present: gamesQuery.hasNextPage, children: _jsx(Button, { variant: "outline", className: "mx-auto mt-4xl w-fit", onClick: () => gamesQuery.fetchNextPage(), children: "Load More" }) })] }))] })) })) })] })) }) })] }) }));
55
53
  }
56
54
  function Alert({ message }) {
57
- return (_jsxs("div", { className: "py-lg", role: "alert", "aria-live": "polite", children: [_jsx("div", { className: "bg-bg-secondary shadow-xs border-border-primary mx-auto flex size-12 items-center justify-center rounded-lg border", children: _jsx(SearchLgIcon, { className: "text-text-secondary-700 size-6" }) }), _jsx("p", { className: "text-text-secondary-700 mt-4 text-center", children: message })] }));
55
+ return (_jsxs("div", { className: "py-lg", role: "alert", "aria-live": "polite", children: [_jsx("div", { className: "mx-auto flex size-12 items-center justify-center rounded-lg border border-border-primary bg-bg-secondary shadow-xs", children: _jsx(SearchLgIcon, { className: "size-6 text-text-secondary-700" }) }), _jsx("p", { className: "mt-4 text-center text-text-secondary-700", children: message })] }));
58
56
  }
@@ -64,5 +64,5 @@ export function JackpotsCarousel({ style, className, ...props }) {
64
64
  const classNames = isString(className)
65
65
  ? { root: className }
66
66
  : (className ?? {});
67
- return (_jsxs("div", { style: styles.root, 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(JackpotsCarouselItemContext, { value: jackpot, children: _jsx(JackpotsCarouselItem, { style: styles.itemRoot, className: classNames.itemRoot, viewAllUrl: props.viewAllUrl, animate: props.animate }) }, jackpot.id))) }) })] }));
67
+ return (_jsxs("div", { style: styles.root, className: classNames.root, children: [_jsxs("div", { className: "flex items-center justify-between", children: [_jsx("div", { className: "font-semibold text-lg", children: props.heading ?? 'Jackpots' }), _jsxs("div", { className: "flex items-center md:gap-3xl", children: [_jsxs(Link, { href: props.viewAllUrl ?? '/jackpots', className: "flex gap-sm font-semibold text-button-tertiary-fg text-sm", 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(JackpotsCarouselItemContext, { value: jackpot, children: _jsx(JackpotsCarouselItem, { style: styles.itemRoot, className: classNames.itemRoot, viewAllUrl: props.viewAllUrl, animate: props.animate }) }, jackpot.id))) }) })] }));
68
68
  }
@@ -1,4 +1,4 @@
1
- import { type CSSProperties } from 'react';
1
+ import { type CSSProperties } from "react";
2
2
  export interface JackpotsCarouselItemProps {
3
3
  style?: CSSProperties;
4
4
  className?: string;