@opexa/portal-components 0.1.53 → 0.1.55

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 (66) hide show
  1. package/dist/client/hooks/useCreateGCashStandardCashInWithdrawal.d.ts +4 -4
  2. package/dist/client/hooks/useCreateGCashStandardCashInWithdrawal.js +8 -8
  3. package/dist/client/hooks/useCreateGCashWithdrawalMutation.d.ts +4 -4
  4. package/dist/client/hooks/useCreateGCashWithdrawalMutation.js +8 -8
  5. package/dist/client/hooks/useRecaptcha.js +3 -1
  6. package/dist/client/hooks/useRedeemVoucherMutation.js +1 -1
  7. package/dist/client/hooks/useRequireFirstDepositQuery.js +1 -1
  8. package/dist/components/Account/Wallet.example.js +1 -1
  9. package/dist/components/Account/Wallet.js +2 -2
  10. package/dist/components/AccountInfo/AccountInfo.js +1 -1
  11. package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit/Failed.js +3 -1
  12. package/dist/components/DepositWithdrawal/Deposit/Voucher/Voucher.js +2 -2
  13. package/dist/components/DepositWithdrawal/Deposit/Voucher/definition.js +2 -1
  14. package/dist/components/DepositWithdrawal/DepositWithdrawalTrigger.js +1 -1
  15. package/dist/components/DepositWithdrawal/PaymentMethods.js +3 -3
  16. package/dist/components/DepositWithdrawal/Withdrawal/Withdrawal.js +1 -1
  17. package/dist/components/Disclaimer/DisclaimerV2.js +0 -8
  18. package/dist/components/ForgotPassword/Crazywin/CWForgotPassword.js +1 -1
  19. package/dist/components/ForgotPassword/Crazywin/CWForgotPasswordForm.js +3 -3
  20. package/dist/components/ForgotPassword/ForgotPassword.lazy.js +4 -2
  21. package/dist/components/ForgotPassword/ForgotPasswordForm.js +19 -7
  22. package/dist/components/GameExit/GameExit.lazy.js +1 -1
  23. package/dist/components/Games/GamesPagination.js +1 -1
  24. package/dist/components/Jackpots/JackpotsCarousel/JackpotsCarouselItem.js +8 -3
  25. package/dist/components/Jackpots/JackpotsListNext/JackpotMultiStageDesktop.js +1 -1
  26. package/dist/components/KYC/KYCReminder.lazy.js +2 -1
  27. package/dist/components/Migrate/MigrateInitializing.js +1 -1
  28. package/dist/components/NewsFeed/NewsFeedCarousel.js +1 -1
  29. package/dist/components/Promos/Cashback.d.ts +3 -1
  30. package/dist/components/Promos/Cashback.js +4 -4
  31. package/dist/components/Promos/CustomPromo.d.ts +3 -1
  32. package/dist/components/Promos/CustomPromo.js +3 -2
  33. package/dist/components/Promos/Promo.d.ts +3 -1
  34. package/dist/components/Promos/Promo.js +4 -4
  35. package/dist/components/Promos/PromosCarousel.d.ts +2 -0
  36. package/dist/components/Promos/PromosCarousel.js +1 -1
  37. package/dist/components/Promos/PromosGrid.d.ts +13 -0
  38. package/dist/components/Promos/PromosGrid.js +1 -1
  39. package/dist/components/Promos/index.d.ts +1 -0
  40. package/dist/components/Promos/utils.d.ts +1 -0
  41. package/dist/components/Promos/utils.js +10 -0
  42. package/dist/components/ResponsibleGamingLimits/ResponsibleGamingLimits.js +1 -1
  43. package/dist/components/ResponsibleGamingLimits/ResponsibleGamingLimitsForm.lazy.js +8 -4
  44. package/dist/components/ResponsibleGamingLimits/index.d.ts +1 -1
  45. package/dist/components/ResponsibleGamingLimits/index.js +1 -1
  46. package/dist/components/SignIn/HappyBingo/NameAndPasswordSignIn.js +1 -1
  47. package/dist/components/SignIn/useSignIn.js +1 -1
  48. package/dist/components/SignUp/SignUpCrazyWin/SignUpCrazyWin.lazy.js +1 -1
  49. package/dist/components/SignUp/SignUpCrazyWin/SignUpCrazyWinContext.js +1 -1
  50. package/dist/components/SignUp/SignUpDefault/SignUpDefault.lazy.d.ts +2 -0
  51. package/dist/components/SignUp/SignUpDefault/SignUpDefaultForm.js +18 -0
  52. package/dist/components/SignUp/SignUpDefault/SignUpDefaultFormInternational.js +20 -0
  53. package/dist/components/SignUp/SignUpHappyBingo/SignUpHappyBingoForm.js +3 -1
  54. package/dist/components/Tournaments/TournamentsCarousel/TournamentsCarouselItem.HappyBingo.js +1 -1
  55. package/dist/components/Tournaments/TournamentsList/TournamentListItemTable.CrazyWin.js +1 -1
  56. package/dist/components/TransactionRecords/TransactionRecords.suspense.js +1 -1
  57. package/dist/components/UpdateMobilePhoneNumber/components/Step1MobileNumberForm.js +1 -1
  58. package/dist/components/UpdateMobilePhoneNumber/hooks/useUpdateMobileFlow.js +1 -2
  59. package/dist/constants/PisoPayBanks.js +181 -181
  60. package/dist/handlers/index.d.ts +2 -2
  61. package/dist/schemas/forgotPasswordSchema.d.ts +4 -4
  62. package/dist/schemas/forgotPasswordSchema.js +24 -7
  63. package/dist/services/auth.d.ts +4 -0
  64. package/dist/services/auth.js +7 -0
  65. package/dist/utils/countries/getLocaleInfo.js +1 -2
  66. package/package.json +1 -1
@@ -3,6 +3,7 @@ import Image from 'next/image';
3
3
  import Link from 'next/link';
4
4
  import { twMerge } from 'tailwind-merge';
5
5
  import { Button } from '../../ui/Button/index.js';
6
- export function CustomPromo({ data, viewDetailsUrl, roundedButtons, textOrientation = 'center', }) {
7
- return (_jsxs("div", { className: "relative flex h-full flex-col overflow-hidden rounded-2xl border border-border-secondary bg-accent-50 bg-bg-primary-alt", children: [_jsx(Image, { src: data.banner, alt: data.name, width: 400, height: 202, loading: "lazy", unoptimized: true, className: "block aspect-[365/180] w-full object-cover" }), _jsxs("div", { className: "flex flex-grow flex-col px-4 pt-2xl pb-3xl", children: [_jsx("div", { className: twMerge('w-full grow font-semibold text-xl', textOrientation === 'center' ? 'text-center' : 'text-left'), children: data.name }), _jsx("div", { className: "mt-auto flex flex-col gap-3 pt-4 lg:flex-row", children: _jsx(Button, { size: "sm", variant: "outline", asChild: true, className: roundedButtons ? 'rounded-full' : '', children: _jsxs(Link, { href: `${viewDetailsUrl}/${data.id}`, children: ["Read more", _jsxs("span", { className: "sr-only", children: [" about ", data.name] })] }) }) })] })] }));
6
+ import { mergePromoCardClassName } from './utils.js';
7
+ export function CustomPromo({ data, viewDetailsUrl, roundedButtons, textOrientation = 'center', cardClassNames, }) {
8
+ return (_jsxs("div", { className: mergePromoCardClassName('relative flex h-full flex-col overflow-hidden rounded-2xl border border-border-secondary bg-accent-50 bg-bg-primary-alt', cardClassNames?.container), children: [_jsx(Image, { src: data.banner, alt: data.name, width: 400, height: 202, loading: "lazy", unoptimized: true, className: mergePromoCardClassName('block aspect-[365/180] w-full object-cover', cardClassNames?.image) }), _jsxs("div", { className: mergePromoCardClassName('flex flex-grow flex-col px-4 pt-2xl pb-3xl', cardClassNames?.body), children: [_jsx("div", { className: mergePromoCardClassName(twMerge('w-full grow font-semibold text-xl', textOrientation === 'center' ? 'text-center' : 'text-left'), cardClassNames?.title), children: data.name }), _jsx("div", { className: mergePromoCardClassName('mt-auto flex flex-col gap-3 pt-4 lg:flex-row', cardClassNames?.actions), children: _jsx(Button, { size: "sm", variant: "outline", asChild: true, className: mergePromoCardClassName(roundedButtons ? 'rounded-full' : '', cardClassNames?.detailsButton), children: _jsxs(Link, { href: `${viewDetailsUrl}/${data.id}`, children: ["Read more", _jsxs("span", { className: "sr-only", children: [" about ", data.name] })] }) }) })] })] }));
8
9
  }
@@ -1,10 +1,12 @@
1
1
  import type { Promo as TPromo } from '../../types';
2
+ import type { PromoCardClassNames } from './PromosGrid';
2
3
  interface PromoProps {
3
4
  data: TPromo;
4
5
  viewDetailsUrl: string;
5
6
  hasPromotionPeriod?: boolean;
6
7
  roundedButtons?: boolean;
7
8
  textOrientation?: 'left' | 'center';
9
+ cardClassNames?: PromoCardClassNames;
8
10
  }
9
- export declare function Promo({ data, viewDetailsUrl, hasPromotionPeriod, roundedButtons, textOrientation, }: PromoProps): import("react/jsx-runtime").JSX.Element;
11
+ export declare function Promo({ data, viewDetailsUrl, hasPromotionPeriod, roundedButtons, textOrientation, cardClassNames, }: PromoProps): import("react/jsx-runtime").JSX.Element;
10
12
  export {};
@@ -6,16 +6,16 @@ import { useShallow } from 'zustand/shallow';
6
6
  import { useAvailablePromosQuery } from '../../client/hooks/useAvailablePromosQuery.js';
7
7
  import { useGlobalStore } from '../../client/hooks/useGlobalStore.js';
8
8
  import { Button } from '../../ui/Button/index.js';
9
- import { formatPromotionPeriod } from './utils.js';
10
- export function Promo({ data, viewDetailsUrl, hasPromotionPeriod, roundedButtons, textOrientation = 'center', }) {
9
+ import { formatPromotionPeriod, mergePromoCardClassName } from './utils.js';
10
+ export function Promo({ data, viewDetailsUrl, hasPromotionPeriod, roundedButtons, textOrientation = 'center', cardClassNames, }) {
11
11
  const globalStore = useGlobalStore(useShallow((ctx) => ({
12
12
  depositWithdrawal: ctx.depositWithdrawal,
13
13
  })));
14
14
  const claimablePromos = useAvailablePromosQuery().data ?? [];
15
15
  const claimable = claimablePromos.find((availablePromo) => availablePromo.id === data.id);
16
16
  const promotionPeriod = formatPromotionPeriod(data.activationStartDateTime, data.activationEndDateTime);
17
- return (_jsxs("div", { className: "relative flex h-full flex-col overflow-hidden rounded-2xl border border-border-secondary bg-accent-50 bg-bg-primary-alt", children: [data.banner?.url && (_jsx(Image, { src: data.banner.url, alt: data.name, width: 400, height: 202, loading: "lazy", unoptimized: true, className: "block aspect-[365/180] w-full object-cover" })), hasPromotionPeriod && (_jsxs("div", { className: "bg-black py-1.5 text-center font-bold text-3xs uppercase", children: ["PROMOTION PERIOD: ", promotionPeriod] })), _jsxs("div", { className: "flex flex-grow flex-col px-4 pt-2xl pb-3xl", children: [_jsx("div", { className: twMerge('w-full grow font-semibold text-xl', textOrientation === 'center' ? 'text-center' : 'text-left'), children: data.name }), _jsxs("div", { className: "mt-auto flex flex-col gap-3 pt-4 lg:flex-row", children: [claimable && (_jsx(Button, { size: "sm", onClick: () => {
17
+ return (_jsxs("div", { className: mergePromoCardClassName('relative flex h-full flex-col overflow-hidden rounded-2xl border border-border-secondary bg-accent-50 bg-bg-primary-alt', cardClassNames?.container), children: [data.banner?.url && (_jsx(Image, { src: data.banner.url, alt: data.name, width: 400, height: 202, loading: "lazy", unoptimized: true, className: mergePromoCardClassName('block aspect-[365/180] w-full object-cover', cardClassNames?.image) })), hasPromotionPeriod && (_jsxs("div", { className: mergePromoCardClassName('bg-black py-1.5 text-center font-bold text-3xs uppercase', cardClassNames?.promotionPeriod), children: ["PROMOTION PERIOD: ", promotionPeriod] })), _jsxs("div", { className: mergePromoCardClassName('flex flex-grow flex-col px-4 pt-2xl pb-3xl', cardClassNames?.body), children: [_jsx("div", { className: mergePromoCardClassName(twMerge('w-full grow font-semibold text-xl', textOrientation === 'center' ? 'text-center' : 'text-left'), cardClassNames?.title), children: data.name }), _jsxs("div", { className: mergePromoCardClassName('mt-auto flex flex-col gap-3 pt-4 lg:flex-row', cardClassNames?.actions), children: [claimable && (_jsx(Button, { size: "sm", className: cardClassNames?.claimButton, onClick: () => {
18
18
  globalStore.depositWithdrawal.setOpen(true);
19
19
  globalStore.depositWithdrawal.setPromo(data.id);
20
- }, children: "Get bonus" })), _jsx(Button, { size: "sm", variant: "outline", asChild: true, className: roundedButtons ? 'rounded-full' : '', children: _jsxs(Link, { href: `${viewDetailsUrl}/${data.id}`, children: ["Read more", _jsxs("span", { className: "sr-only", children: [" about ", data.name] })] }) })] })] })] }));
20
+ }, children: "Get bonus" })), _jsx(Button, { size: "sm", variant: "outline", asChild: true, className: mergePromoCardClassName(roundedButtons ? 'rounded-full' : '', cardClassNames?.detailsButton), children: _jsxs(Link, { href: `${viewDetailsUrl}/${data.id}`, children: ["Read more", _jsxs("span", { className: "sr-only", children: [" about ", data.name] })] }) })] })] })] }));
21
21
  }
@@ -1,5 +1,6 @@
1
1
  import { type ReactNode } from 'react';
2
2
  import type { CustomPromo as TCustomPromo } from '../../types';
3
+ import type { PromoCardClassNames } from './PromosGrid';
3
4
  export interface PromosCarouselProps {
4
5
  layout: 'carousel';
5
6
  /** @default "Promotions" */
@@ -13,6 +14,7 @@ export interface PromosCarouselProps {
13
14
  /** @default "/promos/custom" */
14
15
  viewCustomPromoDetailsUrl?: string;
15
16
  customPromos?: TCustomPromo[];
17
+ cardClassNames?: PromoCardClassNames;
16
18
  /**
17
19
  * @description List of promo IDs to be excluded from the list.
18
20
  * @example
@@ -48,5 +48,5 @@ export function PromosCarousel(props) {
48
48
  onSelect(emblaApi);
49
49
  emblaApi.on('reInit', onSelect).on('select', onSelect);
50
50
  }, [emblaApi, onSelect]);
51
- return (_jsxs("div", { className: props.className, children: [_jsxs("div", { className: "flex items-center", children: [_jsx("h2", { className: "font-semibold text-lg", children: props.heading ?? 'Promotions' }), _jsx("div", { className: "grow" }), _jsxs("div", { className: "flex items-center justify-center gap-xl", children: [_jsxs(Link, { href: props.viewAllUrl ?? '/promos', 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" }) })] })] })] }), empty && (_jsx(Empty, { icon: Gift01Icon, title: "No Promos", message: "No promo is currently available.", className: "mt-8" })), !empty && (_jsx("div", { ref: emblaRef, className: "relative mt-lg overflow-hidden", children: _jsxs("div", { className: twMerge('grid auto-cols-[100%] grid-flow-col gap-1.5 lg:auto-cols-[calc((100%-(1.25rem*2))/3)] lg:gap-2xl'), children: [promos.map((promo) => (_jsx(Promo, { data: promo, viewDetailsUrl: props.viewPromoDetailsUrl ?? '/promos' }, promo.id))), cashbacks.map((cashback) => (_jsx(Cashback, { data: cashback, viewDetailsUrl: props.viewCashbackDetailsUrl ?? '/promos/cashback' }, cashback.id))), customPromos.map((customPromo) => (_jsx(CustomPromo, { data: customPromo, viewDetailsUrl: props.viewCashbackDetailsUrl ?? '/promos/custom' }, customPromo.id)))] }) }))] }));
51
+ return (_jsxs("div", { className: props.className, children: [_jsxs("div", { className: "flex items-center", children: [_jsx("h2", { className: "font-semibold text-lg", children: props.heading ?? 'Promotions' }), _jsx("div", { className: "grow" }), _jsxs("div", { className: "flex items-center justify-center gap-xl", children: [_jsxs(Link, { href: props.viewAllUrl ?? '/promos', 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" }) })] })] })] }), empty && (_jsx(Empty, { icon: Gift01Icon, title: "No Promos", message: "No promo is currently available.", className: "mt-8" })), !empty && (_jsx("div", { ref: emblaRef, className: "relative mt-lg overflow-hidden", children: _jsxs("div", { className: twMerge('grid auto-cols-[100%] grid-flow-col gap-1.5 lg:auto-cols-[calc((100%-(1.25rem*2))/3)] lg:gap-2xl'), children: [promos.map((promo) => (_jsx(Promo, { data: promo, viewDetailsUrl: props.viewPromoDetailsUrl ?? '/promos', cardClassNames: props.cardClassNames }, promo.id))), cashbacks.map((cashback) => (_jsx(Cashback, { data: cashback, viewDetailsUrl: props.viewCashbackDetailsUrl ?? '/promos/cashback', cardClassNames: props.cardClassNames }, cashback.id))), customPromos.map((customPromo) => (_jsx(CustomPromo, { data: customPromo, viewDetailsUrl: props.viewCustomPromoDetailsUrl ?? '/promos/custom', cardClassNames: props.cardClassNames }, customPromo.id)))] }) }))] }));
52
52
  }
@@ -1,5 +1,15 @@
1
1
  import type { ReactNode } from 'react';
2
2
  import type { CustomPromo as TCustomPromo } from '../../types';
3
+ export interface PromoCardClassNames {
4
+ container?: string;
5
+ image?: string;
6
+ promotionPeriod?: string;
7
+ body?: string;
8
+ title?: string;
9
+ actions?: string;
10
+ claimButton?: string;
11
+ detailsButton?: string;
12
+ }
3
13
  export interface PromosGridProps {
4
14
  layout: 'grid';
5
15
  /** @default "Promotions" */
@@ -8,10 +18,13 @@ export interface PromosGridProps {
8
18
  viewPromoDetailsUrl?: string;
9
19
  /** @default "/promos/cashback" */
10
20
  viewCashbackDetailsUrl?: string;
21
+ /** @default "/promos/custom" */
22
+ viewCustomPromoDetailsUrl?: string;
11
23
  customPromos?: TCustomPromo[];
12
24
  hasPromotionPeriod?: boolean;
13
25
  roundedButtons?: boolean;
14
26
  textOrientation?: 'left' | 'center';
27
+ cardClassNames?: PromoCardClassNames;
15
28
  exclude?: string[];
16
29
  className?: string;
17
30
  }
@@ -15,5 +15,5 @@ export function PromosGrid(props) {
15
15
  const cashbacks = cashbacksQuery.data?.filter((item) => !blacklist.includes(item.id)) ?? [];
16
16
  const customPromos = props.customPromos?.filter((item) => !blacklist.includes(item.id)) ?? [];
17
17
  const empty = promos.length <= 0 && cashbacks.length <= 0 && customPromos.length <= 0;
18
- return (_jsxs("div", { className: props.className, children: [_jsxs("div", { className: "flex items-center", children: [_jsx("h2", { className: "font-semibold text-lg", children: props.heading ?? 'Promos' }), _jsx("div", { className: "grow" })] }), empty && (_jsx(Empty, { icon: Gift01Icon, title: "No Promos", message: "No promo is currently available.", className: "mt-8" })), !empty && (_jsx("div", { className: "relative mt-lg lg:overflow-hidden", children: _jsxs("div", { className: "grid gap-3xl lg:grid-cols-3 lg:gap-2xl", children: [promos.map((promo) => (_jsx(Promo, { data: promo, viewDetailsUrl: props.viewPromoDetailsUrl ?? '/promos', hasPromotionPeriod: props.hasPromotionPeriod, roundedButtons: props.roundedButtons, textOrientation: props.textOrientation }, promo.id))), cashbacks.map((cashback) => (_jsx(Cashback, { data: cashback, viewDetailsUrl: props.viewCashbackDetailsUrl ?? '/promos/cashback', hasPromotionPeriod: props.hasPromotionPeriod, roundedButtons: props.roundedButtons, textOrientation: props.textOrientation }, cashback.id))), customPromos.map((customPromo) => (_jsx(CustomPromo, { data: customPromo, viewDetailsUrl: props.viewCashbackDetailsUrl ?? '/promos/custom', roundedButtons: props.roundedButtons, textOrientation: props.textOrientation }, customPromo.id)))] }) }))] }));
18
+ return (_jsxs("div", { className: props.className, children: [_jsxs("div", { className: "flex items-center", children: [_jsx("h2", { className: "font-semibold text-lg", children: props.heading ?? 'Promos' }), _jsx("div", { className: "grow" })] }), empty && (_jsx(Empty, { icon: Gift01Icon, title: "No Promos", message: "No promo is currently available.", className: "mt-8" })), !empty && (_jsx("div", { className: "relative mt-lg lg:overflow-hidden", children: _jsxs("div", { className: "grid gap-3xl lg:grid-cols-3 lg:gap-2xl", children: [promos.map((promo) => (_jsx(Promo, { data: promo, viewDetailsUrl: props.viewPromoDetailsUrl ?? '/promos', hasPromotionPeriod: props.hasPromotionPeriod, roundedButtons: props.roundedButtons, textOrientation: props.textOrientation, cardClassNames: props.cardClassNames }, promo.id))), cashbacks.map((cashback) => (_jsx(Cashback, { data: cashback, viewDetailsUrl: props.viewCashbackDetailsUrl ?? '/promos/cashback', hasPromotionPeriod: props.hasPromotionPeriod, roundedButtons: props.roundedButtons, textOrientation: props.textOrientation, cardClassNames: props.cardClassNames }, cashback.id))), customPromos.map((customPromo) => (_jsx(CustomPromo, { data: customPromo, viewDetailsUrl: props.viewCustomPromoDetailsUrl ?? '/promos/custom', roundedButtons: props.roundedButtons, textOrientation: props.textOrientation, cardClassNames: props.cardClassNames }, customPromo.id)))] }) }))] }));
19
19
  }
@@ -1 +1,2 @@
1
1
  export * from './Promos';
2
+ export type { PromoCardClassNames } from './PromosGrid';
@@ -1 +1,2 @@
1
+ export declare function mergePromoCardClassName(defaultClassName: string, customClassName?: string): string;
1
2
  export declare function formatPromotionPeriod(start: string | null | undefined, until: string | null | undefined): string | null;
@@ -1,4 +1,14 @@
1
1
  import { format } from 'date-fns';
2
+ import { twMerge } from 'tailwind-merge';
3
+ export function mergePromoCardClassName(defaultClassName, customClassName) {
4
+ if (!customClassName)
5
+ return defaultClassName;
6
+ const mergedCustomClassName = twMerge(customClassName);
7
+ const preservedDefaultClasses = defaultClassName
8
+ .split(/\s+/)
9
+ .filter((defaultClass) => twMerge(defaultClass, mergedCustomClassName) !== mergedCustomClassName);
10
+ return [...preservedDefaultClasses, mergedCustomClassName].join(' ');
11
+ }
2
12
  export function formatPromotionPeriod(start, until) {
3
13
  if (!start)
4
14
  return null;
@@ -1,4 +1,4 @@
1
- "use client";
1
+ 'use client';
2
2
  import { jsx as _jsx } from "react/jsx-runtime";
3
3
  import dynamic from 'next/dynamic';
4
4
  const Component = dynamic(() => import('./ResponsibleGamingLimitsForm.lazy.js').then((m) => m.ResponsibleGamingLimitsForm), {
@@ -56,7 +56,8 @@ export function ResponsibleGamingLimitsForm() {
56
56
  : null,
57
57
  used: wallet?.dailyTotalBet ?? 0,
58
58
  resetsLabel: 'Resets daily',
59
- active: (optimisticOverrides['Bet-daily'] ?? Number(account?.dailyBetLimit ?? 0)) > 0,
59
+ active: (optimisticOverrides['Bet-daily'] ??
60
+ Number(account?.dailyBetLimit ?? 0)) > 0,
60
61
  },
61
62
  {
62
63
  period: 'monthly',
@@ -68,7 +69,8 @@ export function ResponsibleGamingLimitsForm() {
68
69
  : null,
69
70
  used: wallet?.monthlyTotalBet ?? 0,
70
71
  resetsLabel: 'Resets on the 1st of every month',
71
- active: (optimisticOverrides['Bet-monthly'] ?? Number(account?.monthlyBetLimit ?? 0)) > 0,
72
+ active: (optimisticOverrides['Bet-monthly'] ??
73
+ Number(account?.monthlyBetLimit ?? 0)) > 0,
72
74
  },
73
75
  ];
74
76
  const depositLimits = [
@@ -82,7 +84,8 @@ export function ResponsibleGamingLimitsForm() {
82
84
  : null,
83
85
  used: wallet?.dailyTotalDeposit ?? 0,
84
86
  resetsLabel: 'Resets daily',
85
- active: (optimisticOverrides['Deposit-daily'] ?? Number(account?.dailyDepositLimit ?? 0)) > 0,
87
+ active: (optimisticOverrides['Deposit-daily'] ??
88
+ Number(account?.dailyDepositLimit ?? 0)) > 0,
86
89
  },
87
90
  {
88
91
  period: 'monthly',
@@ -94,7 +97,8 @@ export function ResponsibleGamingLimitsForm() {
94
97
  : null,
95
98
  used: wallet?.monthlyTotalDeposit ?? 0,
96
99
  resetsLabel: 'Resets on the 1st of every month',
97
- active: (optimisticOverrides['Deposit-monthly'] ?? Number(account?.monthlyDepositLimit ?? 0)) > 0,
100
+ active: (optimisticOverrides['Deposit-monthly'] ??
101
+ Number(account?.monthlyDepositLimit ?? 0)) > 0,
98
102
  },
99
103
  ];
100
104
  const limits = activeTab === 'Bet' ? betLimits : depositLimits;
@@ -1 +1 @@
1
- export * from "./ResponsibleGamingLimits";
1
+ export * from './ResponsibleGamingLimits';
@@ -1 +1 @@
1
- export * from "./ResponsibleGamingLimits.js";
1
+ export * from './ResponsibleGamingLimits.js';
@@ -265,7 +265,7 @@ export function NameAndPasswordSignIn() {
265
265
  signInMutation.reset();
266
266
  form.setValue('secretAnswer', '');
267
267
  },
268
- }) }), _jsx(Field.ErrorText, { children: form.formState.errors.name?.message })] }), _jsx(Field.Root, { disabled: !!signInMutation.data, invalid: !!form.formState.errors.password, className: "mt-xl", children: _jsxs(PasswordInput.Root, { children: [_jsx(PasswordInput.Label, { className: "text-[#344054] dark:text-[#CECFD2]", children: "Password" }), _jsxs("div", { children: [_jsxs(PasswordInput.Control, { className: "border-[#D0D5DD] bg-white text-[#101828] dark:border-[#333741] dark:bg-[#1D2939] dark:text-[#F5F5F6]", children: [_jsx(PasswordInput.Input, { placeholder: "Enter your password", ...form.register('password') }), _jsx(PasswordInput.VisibilityTrigger, { children: _jsx(PasswordInput.Indicator, { fallback: _jsx(EyeOffIcon, {}), asChild: true, className: 'text-[#98A2B3] dark:text-[#94969C]', children: _jsx(EyeIcon, {}) }) })] }), _jsx(Field.ErrorText, { children: form.formState.errors.password?.message })] }), _jsx("div", { className: "mt-2 flex justify-end", children: _jsx("button", { type: "button", tabIndex: -1, className: "font-semibold text-[#A15C07] text-sm dark:text-[#CECFD2]", onClick: () => {
268
+ }) }), _jsx(Field.ErrorText, { children: form.formState.errors.name?.message })] }), _jsx(Field.Root, { disabled: !!signInMutation.data, invalid: !!form.formState.errors.password, className: "mt-xl", children: _jsxs(PasswordInput.Root, { children: [_jsx(PasswordInput.Label, { className: "text-[#344054] dark:text-[#CECFD2]", children: "Password" }), _jsxs("div", { children: [_jsxs(PasswordInput.Control, { className: "border-[#D0D5DD] bg-white text-[#101828] dark:border-[#333741] dark:bg-[#1D2939] dark:text-[#F5F5F6]", children: [_jsx(PasswordInput.Input, { placeholder: "Enter your password", ...form.register('password') }), _jsx(PasswordInput.VisibilityTrigger, { children: _jsx(PasswordInput.Indicator, { fallback: _jsx(EyeOffIcon, {}), asChild: true, className: "text-[#98A2B3] dark:text-[#94969C]", children: _jsx(EyeIcon, {}) }) })] }), _jsx(Field.ErrorText, { children: form.formState.errors.password?.message })] }), _jsx("div", { className: "mt-2 flex justify-end", children: _jsx("button", { type: "button", tabIndex: -1, className: "font-semibold text-[#A15C07] text-sm dark:text-[#CECFD2]", onClick: () => {
269
269
  globalStore.forgotPassword.setOpen(true);
270
270
  dialog.setOpen(false);
271
271
  }, children: "Forgot Password?" }) })] }) }), signInMutation.data && (_jsxs(Field.Root, { invalid: !!form.formState.errors.secretAnswer, className: "mt-xl", children: [_jsx(Field.Label, { children: secretQuestion }), _jsx(Field.Input, { placeholder: "Answer the security question", ...form.register('secretAnswer') }), _jsx(Field.ErrorText, { children: form.formState.errors.secretAnswer?.message })] })), _jsx(Button, { type: "submit", className: "mt-3xl", disabled: signInMutation.isPending || authenticateMutation.isPending, children: "Log In" }), _jsx(Controller, { control: form.control, name: "termsAccepted", render: (o) => (_jsxs(Field.Root, { invalid: o.fieldState.invalid, className: "mt-xl", children: [_jsxs(Checkbox.Root, { variant: "outline", checked: o.field.value, onCheckedChange: (details) => {
@@ -9,7 +9,7 @@ export function useSignIn(props) {
9
9
  : props.types;
10
10
  const defaultActiveType = props?.defaultActiveTab
11
11
  ? ACTIVE_TAB_TYPE_MAP[props.defaultActiveTab]
12
- : props?.defaultType ?? ACTIVE_TAB_TYPE_MAP.Mobile;
12
+ : (props?.defaultType ?? ACTIVE_TAB_TYPE_MAP.Mobile);
13
13
  const initialType = types.includes(defaultActiveType)
14
14
  ? defaultActiveType
15
15
  : types[0];
@@ -21,5 +21,5 @@ export function SignUpCrazyWin(props) {
21
21
  }, lazyMount: true, unmountOnExit: true, closeOnEscape: false, closeOnInteractOutside: false, onExitComplete: () => {
22
22
  globalStore.termsAndConditions.setAccepted(false);
23
23
  globalStore.responsibleGaming.setAccepted(false);
24
- }, children: _jsxs(Portal, { children: [_jsx(Dialog.Backdrop, {}), _jsx(Dialog.Positioner, { children: _jsxs(Dialog.Content, { className: twMerge('h-full w-full lg:mx-auto lg:grid lg:h-[50rem] lg:w-[44.25rem] lg:grid-cols-2', props.className?.root), children: [_jsx("div", { className: "hidden h-full overflow-hidden rounded-l-xl lg:block", children: _jsx(Image, { src: "https://assets.opexacms.atalos.io/hd48QiKmacXs1XWnY", alt: "login banner", width: 1000, height: 1000, className: "h-full w-full", draggable: false }) }), _jsxs("div", { className: 'border-white/10 bg-[radial-gradient(103.87%_100%_at_50.15%_0%,_#072b37_20.3%,_#051125_100%)] backdrop-blur-[25px] lg:rounded-r-xl', children: [_jsx(Dialog.CloseTrigger, { className: "md:-right-10 -top-15 absolute right-2 z-10 size-5.5 rounded-md bg-gradient-to-t from-[#FFE5AF] to-[#EAC467] p-0.5", children: _jsx(XIcon, { className: "h-4.5 w-4.5 text-[#6C5200]" }) }), _jsx(Suspense, { children: _jsx(SignUpCrazyWinForm, {}) })] })] }) })] }) }) }));
24
+ }, children: _jsxs(Portal, { children: [_jsx(Dialog.Backdrop, {}), _jsx(Dialog.Positioner, { children: _jsxs(Dialog.Content, { className: twMerge('h-full w-full lg:mx-auto lg:grid lg:h-[50rem] lg:w-[44.25rem] lg:grid-cols-2', props.className?.root), children: [_jsx("div", { className: "hidden h-full overflow-hidden rounded-l-xl lg:block", children: _jsx(Image, { src: "https://assets.opexacms.atalos.io/hd48QiKmacXs1XWnY", alt: "login banner", width: 1000, height: 1000, className: "h-full w-full", draggable: false }) }), _jsxs("div", { className: "border-white/10 bg-[radial-gradient(103.87%_100%_at_50.15%_0%,_#072b37_20.3%,_#051125_100%)] backdrop-blur-[25px] lg:rounded-r-xl", children: [_jsx(Dialog.CloseTrigger, { className: "md:-right-10 -top-15 absolute right-2 z-10 size-5.5 rounded-md bg-gradient-to-t from-[#FFE5AF] to-[#EAC467] p-0.5", children: _jsx(XIcon, { className: "h-4.5 w-4.5 text-[#6C5200]" }) }), _jsx(Suspense, { children: _jsx(SignUpCrazyWinForm, {}) })] })] }) })] }) }) }));
25
25
  }
@@ -1,2 +1,2 @@
1
1
  import { createContext } from '../../../client/utils/createContext.js';
2
- export const [SignUpCrazyWinPropsProvider, useSignUpCrazyWinPropsContext,] = createContext();
2
+ export const [SignUpCrazyWinPropsProvider, useSignUpCrazyWinPropsContext] = createContext();
@@ -2,6 +2,7 @@ import { type ImageProps } from 'next/image';
2
2
  import { type ReactNode } from 'react';
3
3
  import type { Branch } from '../../../types';
4
4
  import type { CountryCode } from '../../../utils/countries/types';
5
+ import type { VersionSession } from '../../../services/auth';
5
6
  export interface ClassNameEntries {
6
7
  root?: string;
7
8
  publicPlayProhibitionRoot?: string;
@@ -22,6 +23,7 @@ export interface SignUpDefaultProps {
22
23
  responsibleGamingLogo?: ImageProps['src'];
23
24
  isRegulated?: boolean;
24
25
  variant?: string;
26
+ versionSession?: VersionSession;
25
27
  showMiddleNameField?: boolean;
26
28
  showEmailAddressField?: boolean;
27
29
  branchItemToValue?: 'code' | 'name';
@@ -12,6 +12,7 @@ import { twMerge } from 'tailwind-merge';
12
12
  import { z } from 'zod';
13
13
  import { useShallow } from 'zustand/shallow';
14
14
  import { useCooldown } from '../../../client/hooks/useCooldown.js';
15
+ import { useFeatureFlag } from '../../../client/hooks/useFeatureFlag.js';
15
16
  import { useGlobalStore } from '../../../client/hooks/useGlobalStore.js';
16
17
  import { useLocaleInfo } from '../../../client/hooks/useLocaleInfo.js';
17
18
  import { useMobileNumberParser } from '../../../client/hooks/useMobileNumberParser.js';
@@ -26,6 +27,7 @@ import { HelpCircleIcon } from '../../../icons/HelpCircleIcon.js';
26
27
  import pagcorLogo from '../../../images/pagcor-round-icon.png';
27
28
  import responsibleGamingLogo from '../../../images/responsible-gaming-gold.png';
28
29
  import { ObjectType } from '../../../services/ObjectType.js';
30
+ import { checkInplayMemberExists } from '../../../services/auth.js';
29
31
  import { Button } from '../../../ui/Button/index.js';
30
32
  import { Checkbox } from '../../../ui/Checkbox/index.js';
31
33
  import { Field } from '../../../ui/Field/index.js';
@@ -69,6 +71,7 @@ export function SignUpDefaultForm() {
69
71
  const signUpMutation = useSignUpMutation();
70
72
  const signInMutation = useSignInMutation();
71
73
  const sendVerificationCodeMutation = useSendVerificationCodeMutation();
74
+ const featureFlag = useFeatureFlag();
72
75
  const localeInfo = useLocaleInfo();
73
76
  const mobileNumberParser = useMobileNumberParser();
74
77
  const [branchTipOpen, setBranchTipOpen] = useState(false);
@@ -243,6 +246,21 @@ export function SignUpDefaultForm() {
243
246
  }
244
247
  return (_jsxs(_Fragment, { children: [step === 1 && (_jsxs(_Fragment, { children: [_jsx("h2", { className: "mt-xl text-center font-semibold text-lg", children: "Create an account" }), _jsx("p", { className: "mt-xs text-center text-sm text-text-secondary-700", children: "Register instantly and start playing!" }), _jsxs("form", { className: "mt-3xl", autoComplete: "off", onSubmit: step1Form.handleSubmit(async (data) => {
245
248
  try {
249
+ if (signUpProps.versionSession === 'Inplay' &&
250
+ featureFlag.enabled) {
251
+ const exists = await checkInplayMemberExists(mobileNumberParser.format(data.mobileNumber));
252
+ if (exists) {
253
+ toaster.warning({
254
+ description: 'This mobile number is already registered. Please try to log in.',
255
+ });
256
+ globalStore.setPrefillMobileNumber(data.mobileNumber);
257
+ globalStore.setPendingType('MOBILE_NUMBER');
258
+ globalStore.signUp.setOpen(false);
259
+ globalStore.signIn.setOpen(true);
260
+ step1Form.reset();
261
+ return;
262
+ }
263
+ }
246
264
  await sendVerificationCodeMutation.mutateAsync({
247
265
  channel: 'SMS',
248
266
  recipient: mobileNumberParser.format(data.mobileNumber),
@@ -12,6 +12,7 @@ import { twMerge } from 'tailwind-merge';
12
12
  import { z } from 'zod';
13
13
  import { useShallow } from 'zustand/shallow';
14
14
  import { useCooldown } from '../../../client/hooks/useCooldown.js';
15
+ import { useFeatureFlag } from '../../../client/hooks/useFeatureFlag.js';
15
16
  import { useGlobalStore } from '../../../client/hooks/useGlobalStore.js';
16
17
  import { useLocaleInfo } from '../../../client/hooks/useLocaleInfo.js';
17
18
  import { useSendVerificationCodeMutation } from '../../../client/hooks/useSendVerificationCodeMutation.js';
@@ -25,6 +26,7 @@ import { HelpCircleIcon } from '../../../icons/HelpCircleIcon.js';
25
26
  import pagcorLogo from '../../../images/pagcor-round-icon.png';
26
27
  import responsibleGamingLogo from '../../../images/responsible-gaming-gold.png';
27
28
  import { ObjectType } from '../../../services/ObjectType.js';
29
+ import { checkInplayMemberExists } from '../../../services/auth.js';
28
30
  import { Button } from '../../../ui/Button/index.js';
29
31
  import { Checkbox } from '../../../ui/Checkbox/index.js';
30
32
  import { Field } from '../../../ui/Field/index.js';
@@ -61,11 +63,14 @@ export function SignUpDefaultFormInternational() {
61
63
  termsAndConditions: ctx.termsAndConditions,
62
64
  responsibleGaming: ctx.responsibleGaming,
63
65
  kyc: ctx.kyc,
66
+ setPrefillMobileNumber: ctx.signIn.setPrefillMobileNumber,
67
+ setPendingType: ctx.signIn.setPendingType,
64
68
  })));
65
69
  const search = useSearchParams();
66
70
  const signUpMutation = useSignUpMutation();
67
71
  const signInMutation = useSignInMutation();
68
72
  const sendVerificationCodeMutation = useSendVerificationCodeMutation();
73
+ const featureFlag = useFeatureFlag();
69
74
  const firstNameBaseSchema = z
70
75
  .string()
71
76
  .regex(/^[a-z ]+$/gi, 'First name must contain only letters')
@@ -175,6 +180,21 @@ export function SignUpDefaultFormInternational() {
175
180
  const branchCode = step1Form.watch('branchCode', '');
176
181
  return (_jsxs(_Fragment, { children: [step === 1 && (_jsxs(_Fragment, { children: [_jsx("h2", { className: "mt-xl text-center font-semibold text-lg", children: "Create an account" }), _jsx("p", { className: "mt-xs text-center text-sm text-text-secondary-700", children: "Register instantly and start playing!" }), _jsxs("form", { className: "mt-3xl", autoComplete: "off", onSubmit: step1Form.handleSubmit(async (data) => {
177
182
  try {
183
+ if (signUpProps.versionSession === 'Inplay' &&
184
+ featureFlag.enabled) {
185
+ const exists = await checkInplayMemberExists(countryCodeParser(areaCode, data.mobileNumber));
186
+ if (exists) {
187
+ toaster.warning({
188
+ description: 'This mobile number is already registered. Please try to log in.',
189
+ });
190
+ globalStore.setPrefillMobileNumber(countryCodeParser(areaCode, data.mobileNumber));
191
+ globalStore.setPendingType('MOBILE_NUMBER');
192
+ globalStore.signUp.setOpen(false);
193
+ globalStore.signIn.setOpen(true);
194
+ step1Form.reset();
195
+ return;
196
+ }
197
+ }
178
198
  await sendVerificationCodeMutation.mutateAsync({
179
199
  channel: 'SMS',
180
200
  recipient: countryCodeParser(areaCode, data.mobileNumber),
@@ -131,7 +131,9 @@ export function SignUpHappyBingoForm() {
131
131
  firstName: '',
132
132
  lastName: '',
133
133
  mobileNumber: '',
134
- branchCode: SHARED_BRANCH_CODES.length > 0 ? SHARED_BRANCH_CODES[0].code : undefined,
134
+ branchCode: SHARED_BRANCH_CODES.length > 0
135
+ ? SHARED_BRANCH_CODES[0].code
136
+ : undefined,
135
137
  termsAccepted: globalStore.responsibleGaming.accepted &&
136
138
  globalStore.termsAndConditions.accepted
137
139
  ? true
@@ -34,7 +34,7 @@ export function TournamentsCarouselItemHappyBingo() {
34
34
  loop: true,
35
35
  duration: 0,
36
36
  }, [Autoplay()]);
37
- return (_jsxs("div", { className: "w-full shrink-0 overflow-hidden rounded-2xl border border-[#FEDF89] shadow-[inset_0_0_20px_#FFD238,0_0_10px_#FFD238] lg:shadow-none", children: [_jsx("div", { className: twMerge('bg-[linear-gradient(242deg,#FFD238_1.19%,#FF7D02_100%)]', 'relative flex flex-col p-3 text-center lg:gap-6 lg:p-5'), children: _jsx("div", { className: "relative z-1 flex w-full flex-col", children: _jsx("div", { className: "flex h-full flex-col justify-between", children: _jsx("div", { className: "flex w-full justify-between", children: _jsxs("div", { className: "flex w-full flex-col", children: [_jsxs("div", { className: "relative flex w-full justify-between", children: [_jsxs("div", { className: "w-full", children: [_jsxs("div", { className: "flex w-full justify-between", children: [_jsxs("div", { className: twMerge('mb-3.5 inline-flex h-fit items-center gap-1 rounded-full bg-[#FFFAEB] px-2.5 py-1 font-medium text-[#B54708] text-xs shadow-sm dark:bg-[#4E1D09] dark:text-[#FEC84B]'), children: [_jsx(Award01Icon, { className: "size-3" }), _jsx("span", { children: "Multiplier" })] }), _jsxs("div", { className: "flex flex-col", children: [isEnded && (_jsxs("div", { className: twMerge('mb-2 flex flex-col items-center justify-center whitespace-nowrap rounded-md bg-bg-primary px-2 py-1.5 font-semibold text-[#EAAA08] text-sm'), children: [_jsx("span", { className: "font-semibold", children: "Ended" }), _jsx("span", { className: twMerge('text-[9px] text-text-secondary-700'), children: format(tournament.activationEndDateTime, 'MMMM dd, yyyy') })] })), !isLaunchStarts && !isEnded && (_jsx("div", { className: twMerge('mb-2 flex items-center justify-center rounded-md bg-bg-primary py-1 font-semibold text-brand-500 text-sm'), children: "Launching Soon" })), !isEnded && (_jsx("div", { className: "flex h-fit gap-4.5", children: timeParts.map((part) => (_jsx(React.Fragment, { children: _jsxs("div", { className: twMerge('flex h-fit w-9 flex-col items-center rounded-[0.25rem] bg-[linear-gradient(180deg,#FFDE21_0%,#FFD012_47%,#FFBF00_100%)] pb-1.5 text-[#713B12]'), children: [_jsx("span", { className: "font-medium text-xl", children: String(part.value).padStart(2, '0') }), _jsx("span", { className: "text-3xs", children: part.label })] }) }, part.label))) }))] })] }), _jsx("div", { className: "flex w-full justify-between", children: _jsxs("div", { className: "w-full", children: [_jsx("div", { className: 'w-1/2 text-left font-bold text-lg lg:w-[68%] lg:text-2xl', children: tournament.name }), _jsx("div", { className: "mt-1.5 w-fit rounded-md bg-[linear-gradient(180deg,#FFDE21_0%,#FFD012_47%,#FFBF00_100%)] px-2 py-1 font-bold text-2xl text-[#713B12] lg:mt-2 lg:text-4xl", children: formatNumber(tournamentReward, {
37
+ return (_jsxs("div", { className: "w-full shrink-0 overflow-hidden rounded-2xl border border-[#FEDF89] shadow-[inset_0_0_20px_#FFD238,0_0_10px_#FFD238] lg:shadow-none", children: [_jsx("div", { className: twMerge('bg-[linear-gradient(242deg,#FFD238_1.19%,#FF7D02_100%)]', 'relative flex flex-col p-3 text-center lg:gap-6 lg:p-5'), children: _jsx("div", { className: "relative z-1 flex w-full flex-col", children: _jsx("div", { className: "flex h-full flex-col justify-between", children: _jsx("div", { className: "flex w-full justify-between", children: _jsxs("div", { className: "flex w-full flex-col", children: [_jsxs("div", { className: "relative flex w-full justify-between", children: [_jsxs("div", { className: "w-full", children: [_jsxs("div", { className: "flex w-full justify-between", children: [_jsxs("div", { className: twMerge('mb-3.5 inline-flex h-fit items-center gap-1 rounded-full bg-[#FFFAEB] px-2.5 py-1 font-medium text-[#B54708] text-xs shadow-sm dark:bg-[#4E1D09] dark:text-[#FEC84B]'), children: [_jsx(Award01Icon, { className: "size-3" }), _jsx("span", { children: "Multiplier" })] }), _jsxs("div", { className: "flex flex-col", children: [isEnded && (_jsxs("div", { className: twMerge('mb-2 flex flex-col items-center justify-center whitespace-nowrap rounded-md bg-bg-primary px-2 py-1.5 font-semibold text-[#EAAA08] text-sm'), children: [_jsx("span", { className: "font-semibold", children: "Ended" }), _jsx("span", { className: twMerge('text-[9px] text-text-secondary-700'), children: format(tournament.activationEndDateTime, 'MMMM dd, yyyy') })] })), !isLaunchStarts && !isEnded && (_jsx("div", { className: twMerge('mb-2 flex items-center justify-center rounded-md bg-bg-primary py-1 font-semibold text-brand-500 text-sm'), children: "Launching Soon" })), !isEnded && (_jsx("div", { className: "flex h-fit gap-4.5", children: timeParts.map((part) => (_jsx(React.Fragment, { children: _jsxs("div", { className: twMerge('flex h-fit w-9 flex-col items-center rounded-[0.25rem] bg-[linear-gradient(180deg,#FFDE21_0%,#FFD012_47%,#FFBF00_100%)] pb-1.5 text-[#713B12]'), children: [_jsx("span", { className: "font-medium text-xl", children: String(part.value).padStart(2, '0') }), _jsx("span", { className: "text-3xs", children: part.label })] }) }, part.label))) }))] })] }), _jsx("div", { className: "flex w-full justify-between", children: _jsxs("div", { className: "w-full", children: [_jsx("div", { className: "w-1/2 text-left font-bold text-lg lg:w-[68%] lg:text-2xl", children: tournament.name }), _jsx("div", { className: "mt-1.5 w-fit rounded-md bg-[linear-gradient(180deg,#FFDE21_0%,#FFD012_47%,#FFBF00_100%)] px-2 py-1 font-bold text-2xl text-[#713B12] lg:mt-2 lg:text-4xl", children: formatNumber(tournamentReward, {
38
38
  currency: localeInfo.currency.code,
39
39
  minDecimalPlaces: 2,
40
40
  maxDecimalPlaces: 2,
@@ -89,6 +89,6 @@ export const TournamentTable = ({ leaderboard, rewardSettings, winnersCount, })
89
89
  return (_jsx(TableRow, { winner: item, rank: globalRank, idx: idx }, item.id || `winner-${globalRank}`));
90
90
  }) })] }) }));
91
91
  };
92
- return (_jsxs("div", { className: "mt-4 flex flex-col gap-0 lg:gap-7", children: [_jsx("div", { className: "flex gap-[10px]", children: Array.from({ length: tablesPerPage }, (_, tableIndex) => (_jsx(Table, { tableIndex: tableIndex }, tableIndex))) }), _jsxs("div", { className: 'hidden items-center justify-between pb-4 pl-1 text-[#CECFD2] text-sm lg:flex', children: [_jsxs("div", { className: "font-medium", children: ["Page ", currentPage, " of ", numberOfPages] }), _jsxs("div", { className: "flex gap-3 font-semibold", children: [_jsx("button", { type: "button", onClick: goPrev, disabled: !canGoPrev, className: "rounded-lg border border-[#333741] px-[14px] py-2 disabled:cursor-not-allowed disabled:text-[#98A2B3]", children: "Previous" }), _jsx("button", { type: "button", onClick: goNext, disabled: !canGoNext, className: "rounded-lg border border-[#333741] px-[14px] py-2 disabled:cursor-not-allowed disabled:text-[#98A2B3]", children: "Next" })] })] }), _jsxs("div", { className: "flex items-center justify-between rounded-b-lg border-none bg-[#0C111D] px-4 py-3 text-sm lg:hidden", children: [_jsxs("button", { type: "button", onClick: goPrev, disabled: !canGoPrev, className: "flex h-9 w-9 items-center justify-center rounded-lg border border-[#333741] bg-[#0C111D] text-[#CECFD2] disabled:cursor-not-allowed disabled:text-[#85888E]", children: [_jsx("span", { className: "sr-only", children: "Previous" }), _jsx(ArrowLeftIcon, { className: "size-5" })] }), _jsxs("p", { className: "text-[#CECFD2]", children: ["Page ", currentPage, " of ", numberOfPages] }), _jsxs("button", { type: "button", onClick: goNext, disabled: !canGoNext, className: "flex h-9 w-9 items-center justify-center rounded-lg border border-[#333741] bg-[#0C111D] text-[#CECFD2] disabled:cursor-not-allowed disabled:text-[#85888E]", children: [_jsx("span", { className: "sr-only", children: "Next" }), _jsx(ArrowRightIcon, { className: "size-5" })] })] })] }));
92
+ return (_jsxs("div", { className: "mt-4 flex flex-col gap-0 lg:gap-7", children: [_jsx("div", { className: "flex gap-[10px]", children: Array.from({ length: tablesPerPage }, (_, tableIndex) => (_jsx(Table, { tableIndex: tableIndex }, tableIndex))) }), _jsxs("div", { className: "hidden items-center justify-between pb-4 pl-1 text-[#CECFD2] text-sm lg:flex", children: [_jsxs("div", { className: "font-medium", children: ["Page ", currentPage, " of ", numberOfPages] }), _jsxs("div", { className: "flex gap-3 font-semibold", children: [_jsx("button", { type: "button", onClick: goPrev, disabled: !canGoPrev, className: "rounded-lg border border-[#333741] px-[14px] py-2 disabled:cursor-not-allowed disabled:text-[#98A2B3]", children: "Previous" }), _jsx("button", { type: "button", onClick: goNext, disabled: !canGoNext, className: "rounded-lg border border-[#333741] px-[14px] py-2 disabled:cursor-not-allowed disabled:text-[#98A2B3]", children: "Next" })] })] }), _jsxs("div", { className: "flex items-center justify-between rounded-b-lg border-none bg-[#0C111D] px-4 py-3 text-sm lg:hidden", children: [_jsxs("button", { type: "button", onClick: goPrev, disabled: !canGoPrev, className: "flex h-9 w-9 items-center justify-center rounded-lg border border-[#333741] bg-[#0C111D] text-[#CECFD2] disabled:cursor-not-allowed disabled:text-[#85888E]", children: [_jsx("span", { className: "sr-only", children: "Previous" }), _jsx(ArrowLeftIcon, { className: "size-5" })] }), _jsxs("p", { className: "text-[#CECFD2]", children: ["Page ", currentPage, " of ", numberOfPages] }), _jsxs("button", { type: "button", onClick: goNext, disabled: !canGoNext, className: "flex h-9 w-9 items-center justify-center rounded-lg border border-[#333741] bg-[#0C111D] text-[#CECFD2] disabled:cursor-not-allowed disabled:text-[#85888E]", children: [_jsx("span", { className: "sr-only", children: "Next" }), _jsx(ArrowRightIcon, { className: "size-5" })] })] })] }));
93
93
  };
94
94
  export default TournamentTable;
@@ -30,7 +30,7 @@ export function TransactionRecords__suspense(props) {
30
30
  ? {
31
31
  transactionRecordsTable: props.className,
32
32
  depositRecordsTable: props.className,
33
- withdrawalRecordsTable: props.className
33
+ withdrawalRecordsTable: props.className,
34
34
  }
35
35
  : (props.className ?? {});
36
36
  return (_jsx(TransactionPropsContext, { value: props, children: _jsxs("div", { className: typeof props.className === 'string' ? props.className : undefined, children: [_jsx("h2", { className: "font-semibold text-sm leading-tight lg:text-lg", children: "Transactions" }), _jsx("p", { className: "mt-xs text-sm text-text-tertiary-600 leading-tight", children: "View your transaction records" }), _jsxs(Tabs.Root, { className: "mt-lg lg:mt-2xl", value: tab, onValueChange: (details) => setTab(TabSchema.parse(details.value)), lazyMount: true, unmountOnExit: true, children: [_jsxs(Tabs.List, { children: [_jsx(Tabs.Trigger, { value: "transactions", children: "All Transactions" }), _jsx(Tabs.Trigger, { value: "deposits", children: "Deposits" }), _jsx(Tabs.Trigger, { value: "withdrawals", children: "Withdrawals" }), _jsx(Tabs.Indicator, {})] }), _jsx("div", { className: "mt-2xl hidden border-[1.5px] border-border-secondary border-t lg:block" }), _jsx("h3", { className: "mt-3xl font-semibold text-sm text-text-secondary-700", children: "Table" }), _jsx(Tabs.Content, { value: "transactions", className: "mt-xl", children: _jsx(TransactionRecordsTable, { className: classNames.transactionRecordsTable }) }), _jsx(Tabs.Content, { value: "deposits", className: "mt-xl", children: _jsx(Suspense, { fallback: null, children: _jsx(DepositRecordsTable, { className: classNames.depositRecordsTable }) }) }), _jsx(Tabs.Content, { value: "withdrawals", className: "mt-xl", children: _jsx(Suspense, { fallback: null, children: _jsx(WithdrawalRecordsTable, { className: classNames.withdrawalRecordsTable }) }) })] })] }) }));
@@ -6,7 +6,7 @@ import { Field } from '../../../ui/Field/index.js';
6
6
  import { LogoutButton } from './LogoutButton.js';
7
7
  export function Step1MobileNumberForm({ step1Form, submitStep1, }) {
8
8
  const localeInfo = useLocaleInfo();
9
- return (_jsxs(_Fragment, { children: [_jsxs("div", { className: 'flex flex-col items-center justify-center gap-1', children: [_jsx("h2", { className: "mt-xl text-center font-semibold text-lg", children: "Verify Your Account" }), _jsx("div", { className: "text-text-secondary-700 text-xs", children: "Please enter your mobile phone number to verify your account." })] }), _jsxs("form", { className: "mt-3xl", onSubmit: submitStep1, children: [_jsxs(Field.Root, { invalid: !!step1Form.formState.errors.mobileNumber, className: "text-left", children: [_jsx(Field.Label, { children: "Mobile Number" }), _jsxs("div", { className: "relative", children: [_jsx("div", { className: "-translate-y-1/2 absolute top-1/2 left-3.5 flex shrink-0 items-center gap-md", children: _jsx("span", { className: "text-text-placeholder", children: localeInfo.mobileNumber.areaCode }) }), _jsx(Field.Input, { style: {
9
+ return (_jsxs(_Fragment, { children: [_jsxs("div", { className: "flex flex-col items-center justify-center gap-1", children: [_jsx("h2", { className: "mt-xl text-center font-semibold text-lg", children: "Verify Your Account" }), _jsx("div", { className: "text-text-secondary-700 text-xs", children: "Please enter your mobile phone number to verify your account." })] }), _jsxs("form", { className: "mt-3xl", onSubmit: submitStep1, children: [_jsxs(Field.Root, { invalid: !!step1Form.formState.errors.mobileNumber, className: "text-left", children: [_jsx(Field.Label, { children: "Mobile Number" }), _jsxs("div", { className: "relative", children: [_jsx("div", { className: "-translate-y-1/2 absolute top-1/2 left-3.5 flex shrink-0 items-center gap-md", children: _jsx("span", { className: "text-text-placeholder", children: localeInfo.mobileNumber.areaCode }) }), _jsx(Field.Input, { style: {
10
10
  paddingLeft: `calc(1.25rem + ${localeInfo.mobileNumber.areaCode.length}ch)`,
11
11
  }, ...step1Form.register('mobileNumber') })] }), _jsx(Field.ErrorText, { children: step1Form.formState.errors.mobileNumber?.message })] }), _jsx(Button, { type: "submit", className: "mt-3xl", disabled: step1Form.formState.isSubmitting, children: "Send Code" }), _jsx(LogoutButton, {})] })] }));
12
12
  }
@@ -48,8 +48,7 @@ export function useUpdateMobileFlow(shouldOnlyShow = 'MobileVerified') {
48
48
  : undefined);
49
49
  useTimeout(() => {
50
50
  globalStore.updateMobilePhoneNumber.setOpen(false);
51
- }, pollForMobileVerified &&
52
- accountQuery.data?.mobileNumberVerified === true
51
+ }, pollForMobileVerified && accountQuery.data?.mobileNumberVerified === true
53
52
  ? 1
54
53
  : null);
55
54
  const mobileNumberParser = useMobileNumberParser();