@opexa/portal-components 0.0.70 → 0.0.72

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 (142) hide show
  1. package/dist/client/hooks/useGamesQuery.d.ts +2 -2
  2. package/dist/client/hooks/useGamesQuery.js +2 -2
  3. package/dist/components/BetRecords/BetRecords.js +10 -15
  4. package/dist/components/CashbackBonus/CashbackBonus.client.d.ts +2 -0
  5. package/dist/components/CashbackBonus/CashbackBonus.client.js +9 -0
  6. package/dist/components/CashbackBonus/CashbackBonus.d.ts +10 -0
  7. package/dist/components/CashbackBonus/CashbackBonus.js +5 -0
  8. package/dist/components/CashbackBonus/index.d.ts +1 -0
  9. package/dist/components/CashbackBonus/index.js +1 -0
  10. package/dist/components/GameProviders/GameProviders.d.ts +14 -2
  11. package/dist/components/GameProviders/GameProviders.js +12 -2
  12. package/dist/components/JackpotCounter/JackpotCounterItem.module.css +184 -184
  13. package/dist/components/Jackpots/JackpotItemDesktop.d.ts +1 -9
  14. package/dist/components/Jackpots/JackpotItemDesktop.js +5 -3
  15. package/dist/components/Jackpots/JackpotItemMobile.d.ts +1 -9
  16. package/dist/components/Jackpots/JackpotItemMobile.js +5 -3
  17. package/dist/components/Jackpots/JackpotRules.d.ts +0 -1
  18. package/dist/components/Jackpots/JackpotRules.js +3 -1
  19. package/dist/components/Jackpots/Jackpots.client.js +2 -1
  20. package/dist/components/Jackpots/Jackpots.d.ts +3 -5
  21. package/dist/components/Jackpots/JackpotsContext.d.ts +4 -0
  22. package/dist/components/Jackpots/JackpotsContext.js +3 -0
  23. package/dist/components/Jackpots/useJackpotItemData.d.ts +2 -8
  24. package/dist/components/Jackpots/useJackpotItemData.js +7 -1
  25. package/dist/components/Search/Search.d.ts +15 -0
  26. package/dist/components/Search/Search.js +32 -5
  27. package/dist/components/TopWins/TopWins.client.js +3 -3
  28. package/dist/components/Tournaments/TournamentDesktop.d.ts +1 -0
  29. package/dist/components/Tournaments/TournamentDesktop.js +57 -0
  30. package/dist/components/Tournaments/TournamentMobile.d.ts +1 -0
  31. package/dist/components/Tournaments/TournamentMobile.js +55 -0
  32. package/dist/components/Tournaments/TournamentRules.d.ts +0 -1
  33. package/dist/components/Tournaments/TournamentRules.js +3 -1
  34. package/dist/components/Tournaments/Tournaments.client.js +4 -3
  35. package/dist/components/Tournaments/Tournaments.d.ts +2 -4
  36. package/dist/components/Tournaments/TournamentsContext.d.ts +4 -0
  37. package/dist/components/Tournaments/TournamentsContext.js +3 -0
  38. package/dist/components/Tournaments/useTournamentData.d.ts +10 -0
  39. package/dist/components/Tournaments/useTournamentData.js +72 -0
  40. package/dist/components/TransactionRecords/DepositRecordsTable.js +1 -0
  41. package/dist/components/TransactionRecords/TableFilters.d.ts +1 -7
  42. package/dist/components/TransactionRecords/TableFilters.js +1 -53
  43. package/dist/components/TransactionRecords/TransactionRecords.d.ts +0 -3
  44. package/dist/components/TransactionRecords/TransactionRecords.js +0 -1
  45. package/dist/components/TransactionRecords/TransactionRecordsTable.js +1 -0
  46. package/dist/components/TransactionRecords/WithdrawalRecordsTable.js +1 -0
  47. package/dist/constants/envVars.d.ts +5 -0
  48. package/dist/constants/envVars.js +28 -0
  49. package/dist/constants/gameProviders.d.ts +4 -0
  50. package/dist/constants/gameProviders.js +319 -0
  51. package/dist/constants/gameTypes.d.ts +4 -0
  52. package/dist/constants/gameTypes.js +64 -0
  53. package/dist/constants/headerKeys.d.ts +1 -0
  54. package/dist/constants/headerKeys.js +1 -0
  55. package/dist/constants/index.d.ts +6 -12
  56. package/dist/constants/index.js +6 -88
  57. package/dist/constants/secretQuestions.d.ts +3 -0
  58. package/dist/constants/secretQuestions.js +24 -0
  59. package/dist/constants/storageKeys.d.ts +2 -0
  60. package/dist/constants/storageKeys.js +2 -0
  61. package/dist/images/game-providers/ALIZE.png +0 -0
  62. package/dist/images/game-providers/BGAMING.png +0 -0
  63. package/dist/images/game-providers/BOOOONGO.png +0 -0
  64. package/dist/images/game-providers/BTI.png +0 -0
  65. package/dist/images/game-providers/CQ9.png +0 -0
  66. package/dist/images/game-providers/DARWIN.png +0 -0
  67. package/dist/images/game-providers/DG.png +0 -0
  68. package/dist/images/game-providers/DRBINGO.png +0 -0
  69. package/dist/images/game-providers/E2E.png +0 -0
  70. package/dist/images/game-providers/EVOLUTION.png +0 -0
  71. package/dist/images/game-providers/EVOLUTION_NETENT.png +0 -0
  72. package/dist/images/game-providers/EVOLUTION_REDTIGER.png +0 -0
  73. package/dist/images/game-providers/EVOPLAY.png +0 -0
  74. package/dist/images/game-providers/EZUGI.png +0 -0
  75. package/dist/images/game-providers/FACHAI.png +0 -0
  76. package/dist/images/game-providers/HABANERO.png +0 -0
  77. package/dist/images/game-providers/HACKSAW.png +0 -0
  78. package/dist/images/game-providers/HOLLYWOODTV.png +0 -0
  79. package/dist/images/game-providers/JDB.png +0 -0
  80. package/dist/images/game-providers/JDB_GTF.png +0 -0
  81. package/dist/images/game-providers/JDB_SPRIBE.png +0 -0
  82. package/dist/images/game-providers/JILI.png +0 -0
  83. package/dist/images/game-providers/JOKER.png +0 -0
  84. package/dist/images/game-providers/KINGMAKER.png +0 -0
  85. package/dist/images/game-providers/KINGMIDAS.png +0 -0
  86. package/dist/images/game-providers/MEGA2SPIN.png +0 -0
  87. package/dist/images/game-providers/MEGABALL.png +0 -0
  88. package/dist/images/game-providers/MICROGAMING.png +0 -0
  89. package/dist/images/game-providers/ONEAPI.png +0 -0
  90. package/dist/images/game-providers/PGSOFT.png +0 -0
  91. package/dist/images/game-providers/PLAYTECH.png +0 -0
  92. package/dist/images/game-providers/PRAGMATIC_PLAY.png +0 -0
  93. package/dist/images/game-providers/RELAX_GAMING.png +0 -0
  94. package/dist/images/game-providers/RTG.png +0 -0
  95. package/dist/images/game-providers/SABA.png +0 -0
  96. package/dist/images/game-providers/SPINIX.png +0 -0
  97. package/dist/images/game-providers/SPRIBE.png +0 -0
  98. package/dist/images/game-providers/YELLOWBAT.png +0 -0
  99. package/dist/middleware.d.ts +3 -2
  100. package/dist/middleware.js +7 -4
  101. package/dist/server/utils/prefetchGamesQuery.d.ts +2 -2
  102. package/dist/server/utils/prefetchGamesQuery.js +2 -2
  103. package/dist/styles/theme.css +696 -696
  104. package/dist/types/index.d.ts +6 -1
  105. package/dist/ui/AlertDialog/AlertDialog.d.ts +88 -88
  106. package/dist/ui/AlertDialog/alertDialog.recipe.d.ts +8 -8
  107. package/dist/ui/Badge/Badge.d.ts +12 -12
  108. package/dist/ui/Badge/badge.recipe.d.ts +3 -3
  109. package/dist/ui/Checkbox/Checkbox.d.ts +23 -23
  110. package/dist/ui/Checkbox/checkbox.recipe.d.ts +3 -3
  111. package/dist/ui/Clipboard/Clipboard.d.ts +18 -18
  112. package/dist/ui/Clipboard/clipboard.recipe.d.ts +3 -3
  113. package/dist/ui/Collapsible/Collapsible.d.ts +20 -20
  114. package/dist/ui/Collapsible/collapsible.recipe.d.ts +5 -5
  115. package/dist/ui/Combobox/Combobox.d.ts +42 -42
  116. package/dist/ui/Combobox/combobox.recipe.d.ts +3 -3
  117. package/dist/ui/DatePicker/DatePicker.d.ts +336 -336
  118. package/dist/ui/DatePicker/datePicker.recipe.d.ts +14 -14
  119. package/dist/ui/Dialog/Dialog.d.ts +88 -88
  120. package/dist/ui/Dialog/dialog.recipe.d.ts +8 -8
  121. package/dist/ui/Drawer/Drawer.d.ts +33 -33
  122. package/dist/ui/Drawer/drawer.recipe.d.ts +3 -3
  123. package/dist/ui/PasswordInput/PasswordInput.d.ts +18 -18
  124. package/dist/ui/PasswordInput/passwordInput.recipe.d.ts +3 -3
  125. package/dist/ui/Popover/Popover.d.ts +88 -88
  126. package/dist/ui/Popover/popover.recipe.d.ts +8 -8
  127. package/dist/ui/Progress/Progress.d.ts +27 -27
  128. package/dist/ui/Progress/progress.recipe.d.ts +3 -3
  129. package/dist/ui/SegmentGroup/SegmentGroup.d.ts +18 -18
  130. package/dist/ui/SegmentGroup/segmentGroup.recipe.d.ts +3 -3
  131. package/dist/ui/Select/Select.d.ts +45 -45
  132. package/dist/ui/Select/select.recipe.d.ts +3 -3
  133. package/dist/ui/Table/Table.d.ts +21 -21
  134. package/dist/ui/Table/table.recipe.d.ts +3 -3
  135. package/dist/ui/Tabs/Tabs.d.ts +15 -15
  136. package/dist/ui/Tabs/tabs.recipe.d.ts +3 -3
  137. package/dist/utils/callIfFn.d.ts +1 -0
  138. package/dist/utils/callIfFn.js +6 -0
  139. package/dist/utils/index.d.ts +1 -0
  140. package/dist/utils/index.js +1 -0
  141. package/dist/utils/queryKeys.d.ts +2 -2
  142. package/package.json +160 -157
@@ -1,3 +1,3 @@
1
- import { type Game, type GamesInput, type PaginatedQueryResult } from '@opexa/portal-sdk-core';
1
+ import { type Game, type GamesInput__Next, type PaginatedQueryResult } from '@opexa/portal-sdk-core';
2
2
  import type { InfiniteQuery } from '../../types';
3
- export declare const useGamesQuery: InfiniteQuery<PaginatedQueryResult<Game>, GamesInput>;
3
+ export declare const useGamesQuery: InfiniteQuery<PaginatedQueryResult<Game>, GamesInput__Next>;
@@ -1,4 +1,4 @@
1
- import { getGames, } from '@opexa/portal-sdk-core';
1
+ import { getGames__next, } from '@opexa/portal-sdk-core';
2
2
  import { useInfiniteQuery } from '@tanstack/react-query';
3
3
  import { ENVIRONMENT, PLATFORM_ID, SITE_ID } from '../../constants/index.js';
4
4
  import { getGamesQueryKey } from '../../utils/index.js';
@@ -10,7 +10,7 @@ export const useGamesQuery = (input, config) => {
10
10
  ...config,
11
11
  queryKey: getGamesQueryKey(input),
12
12
  queryFn: ({ pageParam, signal }) => {
13
- return getGames({
13
+ return getGames__next({
14
14
  ...input,
15
15
  after: pageParam,
16
16
  }, {
@@ -7,27 +7,28 @@ import { useReducer, useState } from 'react';
7
7
  import { twMerge } from 'tailwind-merge';
8
8
  import { z } from 'zod';
9
9
  import { useBetRecordsQuery, useInfiniteQueryHelper, useLocaleInfo, } from '../../client/hooks/index.js';
10
+ import { GAME_PROVIDER_DATA, GAME_TYPE_DATA, GAME_TYPES, } from '../../constants/index.js';
10
11
  import { CheckIcon, ChevronDownIcon, ChevronLeftIcon, ChevronRightIcon, File02Icon, SpinnerIcon, } from '../../icons/index.js';
11
12
  import { Badge, DatePicker, IconButton, SegmentGroup, Select, Table, } from '../../ui/index.js';
12
13
  import { capitalize, formatNumber } from '../../utils/index.js';
13
14
  import { Empty } from '../Empty.js';
14
15
  export function BetRecords(props) {
15
16
  const [tab, setTab] = useState('all');
17
+ const gameTypes = props.gameTypes.map((type) => GAME_TYPE_DATA[type]);
18
+ const gameProviders = props.gameProviders.map((provider) => GAME_PROVIDER_DATA[provider]);
16
19
  const [state, setState] = useReducer((prev, next) => ({
17
20
  ...prev,
18
21
  ...next,
19
22
  }), {
20
23
  page: 1,
21
24
  pageSize: 10,
22
- type: props.gameTypes[0],
25
+ type: gameTypes[0].id,
23
26
  });
24
27
  const localeInfo = useLocaleInfo();
25
28
  const providerCollection = createListCollection({
26
- items: props.gameProviders,
27
- itemToValue: (item) => item,
28
- itemToString: (item) => capitalize(item, {
29
- delimiter: capitalize.delimiters.UNDERSCORE,
30
- }),
29
+ items: gameProviders,
30
+ itemToValue: (item) => item.id,
31
+ itemToString: (item) => item.name,
31
32
  });
32
33
  const { page, hasNextPage, hasPrevPage, next, prev, rows, totalPages, loading, firstPage, } = useInfiniteQueryHelper(useBetRecordsQuery, {
33
34
  filter: {
@@ -61,13 +62,9 @@ export function BetRecords(props) {
61
62
  return (_jsxs("div", { className: props.className, children: [_jsx("h2", { className: "text-sm font-semibold leading-tight lg:text-lg", children: "Bet Records" }), _jsx("p", { className: "text-text-tertiary-600 mt-xs text-sm leading-tight", children: "Review your betting history" }), _jsx("div", { className: "mt-lg lg:mt-2xl", children: _jsxs(SegmentGroup.Root, { value: state.type, onValueChange: (details) => {
62
63
  firstPage();
63
64
  setState({
64
- type: z
65
- .enum((props.gameTypes ?? []))
66
- .safeParse(details.value).data ?? null,
65
+ type: z.enum(GAME_TYPES).safeParse(details.value).data ?? null,
67
66
  });
68
- }, children: [props.gameTypes.map((type) => (_jsxs(SegmentGroup.Item, { value: type, children: [_jsx(SegmentGroup.ItemText, { children: capitalize(type, {
69
- delimiter: capitalize.delimiters.UNDERSCORE,
70
- }) }), _jsx(SegmentGroup.ItemControl, {}), _jsx(SegmentGroup.ItemHiddenInput, {})] }, type))), _jsx(SegmentGroup.Indicator, {})] }) }), _jsx("div", { className: "border-border-secondary mt-2xl hidden border-t lg:block" }), _jsx("h3", { className: "text-text-secondary-700 mt-3xl text-sm font-semibold", children: "Table" }), _jsxs("div", { className: "mt-xl flex flex-col gap-lg lg:flex-row lg:items-center", children: [_jsxs(DatePicker.Root, { lazyMount: true, unmountOnExit: true, value: [state.timestamp?.start, state.timestamp?.end]
67
+ }, children: [gameTypes.map((type) => (_jsxs(SegmentGroup.Item, { value: type.id, children: [_jsx(SegmentGroup.ItemText, { children: type.name }), _jsx(SegmentGroup.ItemControl, {}), _jsx(SegmentGroup.ItemHiddenInput, {})] }, type.id))), _jsx(SegmentGroup.Indicator, {})] }) }), _jsx("div", { className: "border-border-secondary mt-2xl hidden border-t lg:block" }), _jsx("h3", { className: "text-text-secondary-700 mt-3xl text-sm font-semibold", children: "Table" }), _jsxs("div", { className: "mt-xl flex flex-col gap-lg lg:flex-row lg:items-center", children: [_jsxs(DatePicker.Root, { lazyMount: true, unmountOnExit: true, value: [state.timestamp?.start, state.timestamp?.end]
71
68
  .filter(Boolean)
72
69
  .map((d) => parseDate(d)), onValueChange: (details) => {
73
70
  firstPage();
@@ -116,9 +113,7 @@ export function BetRecords(props) {
116
113
  sameWidth: true,
117
114
  }, children: [_jsxs(Select.Trigger, { className: "w-full lg:w-[14rem]", children: [_jsx(Select.ValueText, { placeholder: "Game Vendor" }), _jsx(Select.Context, { children: (api) => (_jsx(_Fragment, { children: api.value.length ? (_jsx(Select.ClearTrigger, { asChild: true, children: _jsx("span", { onClick: (e) => {
118
115
  e.stopPropagation();
119
- }, children: "Clear" }) })) : (_jsx(Select.Indicator, { asChild: true, children: _jsx(ChevronDownIcon, {}) })) })) })] }), _jsx(Portal, { children: _jsx(Select.Positioner, { children: _jsx(Select.Content, { children: _jsx(Select.ItemGroup, { children: providerCollection.items.map((provider) => (_jsxs(Select.Item, { item: provider, children: [_jsx(Select.ItemText, { children: capitalize(provider, {
120
- delimiter: capitalize.delimiters.UNDERSCORE,
121
- }) }), _jsx(Select.ItemIndicator, { asChild: true, children: _jsx(CheckIcon, {}) })] }, provider))) }) }) }) })] }), _jsxs(Select.Root, { collection: statusCollection, value: state.status ? [state.status] : [], onValueChange: (details) => {
116
+ }, children: "Clear" }) })) : (_jsx(Select.Indicator, { asChild: true, children: _jsx(ChevronDownIcon, {}) })) })) })] }), _jsx(Portal, { children: _jsx(Select.Positioner, { children: _jsx(Select.Content, { children: _jsx(Select.ItemGroup, { children: providerCollection.items.map((provider) => (_jsxs(Select.Item, { item: provider, children: [_jsx(Select.ItemText, { children: provider.name }), _jsx(Select.ItemIndicator, { asChild: true, children: _jsx(CheckIcon, {}) })] }, provider.id))) }) }) }) })] }), _jsxs(Select.Root, { collection: statusCollection, value: state.status ? [state.status] : [], onValueChange: (details) => {
122
117
  const value = z
123
118
  .enum(BET_RECORD_STATUSES)
124
119
  .safeParse(details.value.at(0)).data;
@@ -0,0 +1,2 @@
1
+ import type { CashbackBonusProps } from './CashbackBonus';
2
+ export declare function CashbackBonus__client(props: CashbackBonusProps): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,9 @@
1
+ 'use client';
2
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
3
+ import Image from 'next/image';
4
+ import Link from 'next/link';
5
+ import { ChevronLeftIcon, ChevronRightIcon, StopWatchIcon } from '../../icons/index.js';
6
+ import { Badge, Collapsible, Progress, Prose } from '../../ui/index.js';
7
+ export function CashbackBonus__client(props) {
8
+ return (_jsxs("div", { className: props.className, children: [_jsxs(Link, { href: props.viewAllUrl ?? '/rewards', className: "text-button-tertiary-fg flex items-center gap-lg text-lg font-semibold", children: [_jsx(ChevronLeftIcon, { className: "size-6" }), "Back to Rewards"] }), _jsx(Image, { src: "https://s3.ap-east-1.amazonaws.com/opexa-assets.opexasystem.com/assets/BSxIXEsa59_zzMAR27-ALLDAYREBATE06-STATIC-WEB-HB-1920x1080.png", alt: "", width: 1024, height: 600, className: "mt-3xl h-auto w-full rounded-xl" }), _jsxs(Badge.Root, { size: "lg", round: false, colorScheme: "brand", className: "mt-xl lg:mt-6", children: [_jsx(Badge.Icon, { children: _jsx(StopWatchIcon, {}) }), _jsx(Badge.Label, { children: "9d:10h:11m" })] }), _jsx("h1", { className: "text-text-primary-900 mt-xl text-2xl font-semibold lg:mt-6 lg:text-3xl", children: "50 PHP First Deposit Bonus" }), _jsx("p", { className: "text-text-primary-brand mt-xl text-base lg:mt-6 lg:text-lg", children: "Complete the wagering before time runs out to convert your bonus balance into real money!" }), _jsxs("div", { className: "border-border-primary bg-bg-tertiary text-text-secondary-700 mt-xl flex items-center justify-between rounded-md border px-3.5 py-xl lg:mt-6", children: [_jsx("p", { children: "Your bonus" }), _jsxs("p", { children: [_jsx("span", { className: "text-text-primary-900", children: "20.00" }), " / 50.00 PHP"] })] }), _jsxs("div", { className: "border-border-primary bg-bg-tertiary text-text-secondary-700 mt-xl flex items-center justify-between rounded-md border px-3.5 py-xl lg:mt-6", children: [_jsx("p", { children: "Required Turnover" }), _jsx("p", { children: "5x" })] }), _jsxs("div", { className: "border-border-primary bg-bg-tertiary text-text-secondary-700 mt-xl rounded-md border px-3.5 py-xl lg:mt-6", children: [_jsxs("div", { className: "flex items-center justify-between", children: [_jsx("p", { children: "Wagering" }), _jsx("p", { children: "400/1000" })] }), _jsx(Progress.Root, { defaultValue: 42, className: "mt-2", children: _jsx(Progress.Track, { children: _jsx(Progress.Range, {}) }) })] }), _jsxs(Collapsible.Root, { className: "mt-xl lg:mt-6", children: [_jsxs(Collapsible.Trigger, { className: "text-button-tertiary-fg flex w-fit items-center justify-center gap-sm text-sm font-semibold lg:mx-auto", children: ["Game Provider Contribution", _jsx(Collapsible.Indicator, { asChild: true, children: _jsx(ChevronRightIcon, { className: "size-5" }) })] }), _jsxs(Collapsible.Content, { className: "border-border-primary bg-bg-tertiary text-text-secondary-700 mt-xl space-y-1.5 rounded-md border px-3.5 py-xl lg:mt-6", children: [_jsxs("div", { className: "flex items-center justify-between gap-md", children: [_jsx("p", { className: "w-[11.25rem] shrink-0", children: "Playson" }), _jsx(Progress.Root, { defaultValue: 42, className: "mt-2 grow", children: _jsx(Progress.Track, { children: _jsx(Progress.Range, {}) }) }), _jsx("p", { children: "25%" })] }), _jsxs("div", { className: "flex items-center justify-between gap-md", children: [_jsx("p", { className: "w-[11.25rem] shrink-0", children: "Betsoft Gaming" }), _jsx(Progress.Root, { defaultValue: 42, className: "mt-2 grow", children: _jsx(Progress.Track, { children: _jsx(Progress.Range, {}) }) }), _jsx("p", { children: "13%" })] }), _jsxs("div", { className: "flex items-center justify-between gap-md", children: [_jsx("p", { className: "w-[11.25rem] shrink-0", children: "Microgaming" }), _jsx(Progress.Root, { defaultValue: 42, className: "mt-2 grow", children: _jsx(Progress.Track, { children: _jsx(Progress.Range, {}) }) }), _jsx("p", { children: "50%" })] }), _jsxs("div", { className: "flex items-center justify-between gap-md", children: [_jsx("p", { className: "w-[11.25rem] shrink-0", children: "Realtime Gaming" }), _jsx(Progress.Root, { defaultValue: 42, className: "mt-2 grow", children: _jsx(Progress.Track, { children: _jsx(Progress.Range, {}) }) }), _jsx("p", { children: "10%" })] })] })] }), _jsxs(Prose, { className: "mt-xl lg:mt-6", children: [_jsx("h3", { children: "How to get bonus" }), _jsxs("ol", { children: [_jsx("li", { children: "All OFWin members are eligible for this program." }), _jsx("li", { children: "50 PHP of game credit will be automatically credited to the new member account upon completion of first deposit Auctor vel in vitae placerat." }), _jsx("li", { children: "Member must reach a 5x turnover requirement before a withdrawal can be made. Attempting to make a withdrawal before this turnover requirement is completed could cause your bonus to be voided." }), _jsx("li", { children: "Players will have 10 days from the date the bonus is awarded to complete the rollover requirement." }), _jsx("li", { children: "Bets used to meet other bonus rollover requirements will not count toward this promotion." })] }), _jsx("h3", { children: "Terms and Conditions" }), _jsxs("ul", { children: [_jsx("li", { children: "Only one account per player is allowed. No same IP address/bank account name allowed. Players who have multiple or fraudulent accounts will not be qualified for the promotion." }), _jsx("li", { children: "Players that are found to have any duplicate accounts or those who participate in fraudulent activities may have their funds forfeited and their accounts closed." }), _jsx("li", { children: "OFWin reserves the right to amend or cancel this Referral Program at any time. OFWin General Terms and Conditions apply." })] })] })] }));
9
+ }
@@ -0,0 +1,10 @@
1
+ export interface CashbackBonusProps {
2
+ id: string;
3
+ className?: string;
4
+ /**
5
+ * @description URL for the bonuses details page
6
+ * @default "/rewards"
7
+ */
8
+ viewAllUrl?: string;
9
+ }
10
+ export declare function CashbackBonus(props: CashbackBonusProps): Promise<import("react/jsx-runtime").JSX.Element>;
@@ -0,0 +1,5 @@
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
+ import { CashbackBonus__client } from './CashbackBonus.client.js';
3
+ export async function CashbackBonus(props) {
4
+ return _jsx(CashbackBonus__client, { ...props });
5
+ }
@@ -0,0 +1 @@
1
+ export * from './CashbackBonus';
@@ -0,0 +1 @@
1
+ export * from './CashbackBonus.js';
@@ -1,11 +1,23 @@
1
+ import type { GameProvider } from '@opexa/portal-sdk-core';
1
2
  import type { GameProviderData } from '../../types';
2
3
  export interface GameProvidersProps {
3
- gameProviders: GameProviderData[];
4
+ gameProviders: GameProvider[];
4
5
  heading?: string;
5
6
  /**
6
- * @default '/games'
7
+ * @default '/providers'
7
8
  */
8
9
  viewAllUrl?: string;
10
+ /**
11
+ * @default '/providers/<slug>'
12
+ * @example
13
+ * ```ts
14
+ * '/bingo/:slug' // '/bingo/jili'
15
+ * '/bingo/:id' // '/bingo/JILI'
16
+ * // or using a function
17
+ * ({slug}) => `/bingo/${slug}`
18
+ * ```
19
+ */
20
+ viewGamesUrl?: string | ((gameProvider: GameProviderData) => string);
9
21
  className?: string;
10
22
  gameProviderContainerClass?: string;
11
23
  gameProviderImageClass?: string;
@@ -5,8 +5,10 @@ import Image from 'next/image';
5
5
  import Link from 'next/link';
6
6
  import { useCallback, useEffect, useState } from 'react';
7
7
  import { twMerge } from 'tailwind-merge';
8
+ import { GAME_PROVIDER_DATA } from '../../constants/index.js';
8
9
  import { ArrowLeftIcon, ArrowRightIcon, ChevronRightIcon } from '../../icons/index.js';
9
10
  import { Button } from '../../ui/index.js';
11
+ import { callIfFn } from '../../utils/index.js';
10
12
  export function GameProviders(props) {
11
13
  const [emblaRef, emblaApi] = useEmblaCarousel({
12
14
  align: 'start',
@@ -28,6 +30,14 @@ export function GameProviders(props) {
28
30
  onSelect(emblaApi);
29
31
  emblaApi.on('reInit', onSelect).on('select', onSelect);
30
32
  }, [emblaApi, onSelect]);
31
- const viewAllUrl = props.viewAllUrl ?? '/games/providers';
32
- return (_jsxs("div", { className: props.className, 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: "flex items-center justify-center gap-xl", children: [_jsxs(Link, { href: viewAllUrl, 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, "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: props.gameProviders.map((provider) => (_jsx(Link, { href: `${viewAllUrl}/${provider.slug}`, className: twMerge('bg-gray-800 flex w-full items-center rounded-md px-md py-sm lg:h-[5.75rem]', props.gameProviderContainerClass), children: _jsx(Image, { src: provider.logo, alt: "", width: 300, height: 150, className: twMerge('mx-auto h-auto w-full', props.gameProviderImageClass) }) }, provider.id))) }) })] }));
33
+ const viewAllUrl = props.viewAllUrl ?? '/providers';
34
+ const viewGamesUrl = (data) => {
35
+ return props.viewGamesUrl
36
+ ? callIfFn(props.viewGamesUrl, data)
37
+ .replace(':id', data.id)
38
+ .replace(':slug', data.slug)
39
+ : `/providers/${data.slug}`;
40
+ };
41
+ const gameProviders = props.gameProviders.map((provider) => GAME_PROVIDER_DATA[provider]);
42
+ return (_jsxs("div", { className: props.className, 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: "flex items-center justify-center gap-xl", children: [_jsxs(Link, { href: viewAllUrl, 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, "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('bg-gray-800 flex h-full w-full items-center overflow-hidden rounded-md lg:h-[5.75rem]', props.gameProviderContainerClass), "aria-label": `View ${provider.name} games`, children: _jsx(Image, { src: provider.logo, alt: "", width: 300, height: 150, className: twMerge('mx-auto h-auto w-full', props.gameProviderImageClass) }) }, provider.id))) }) })] }));
33
43
  }
@@ -1,184 +1,184 @@
1
- @keyframes arrow-green-flash {
2
- 0% {
3
- color: #abefc6;
4
- }
5
- 100% {
6
- color: #079455;
7
- }
8
- }
9
-
10
- .animate-arrow-green-flash-1 {
11
- animation: arrow-green-flash 0.4s infinite;
12
- animation-delay: -0.2s;
13
- }
14
-
15
- .animate-arrow-green-flash-2 {
16
- animation: arrow-green-flash 0.4s infinite;
17
- animation-delay: -0.1s;
18
- }
19
-
20
- .animate-arrow-green-flash-3 {
21
- animation: arrow-green-flash 0.4s infinite;
22
- }
23
-
24
- @keyframes arrow-red-flash {
25
- 0%,
26
- 100% {
27
- color: #f97066;
28
- }
29
- 50% {
30
- color: #fecdca;
31
- }
32
- }
33
-
34
- .animate-arrow-red-flash-1 {
35
- animation: arrow-red-flash 0.4s infinite;
36
- }
37
-
38
- .animate-arrow-red-flash-2 {
39
- animation: arrow-red-flash 0.4s infinite;
40
- animation-delay: -0.1s;
41
- }
42
-
43
- .animate-arrow-red-flash-3 {
44
- animation: arrow-red-flash 0.4s infinite;
45
- animation-delay: -0.2s;
46
- }
47
-
48
- /* Animated BG */
49
- @keyframes rotate {
50
- to {
51
- transform: rotate(1turn);
52
- }
53
- }
54
-
55
- .light-rays {
56
- position: absolute;
57
- top: 0;
58
- left: 0;
59
- right: 0;
60
- bottom: 0;
61
- overflow: hidden;
62
-
63
- --first: var(--color-bg-tertiary);
64
- --second: var(--color-bg-quaternary);
65
- }
66
-
67
- .light-rays::before,
68
- .light-rays::after {
69
- content: '';
70
- position: absolute;
71
- top: var(--light-rays-top, 150px);
72
- left: calc(50% - 90px);
73
- margin: -100vmax;
74
- width: 200vmax;
75
- height: 200vmax;
76
- opacity: 0.6;
77
- transform-origin: center;
78
- }
79
-
80
- .light-rays::before {
81
- background: conic-gradient(
82
- var(--first) 0deg 7.2deg,
83
- var(--second) 7.2deg 14.4deg,
84
- var(--first) 14.4deg 21.6deg,
85
- var(--second) 21.6deg 28.8deg,
86
- var(--first) 28.8deg 36deg,
87
- var(--second) 36deg 43.2deg,
88
- var(--first) 43.2deg 50.4deg,
89
- var(--second) 50.4deg 57.6deg,
90
- var(--first) 57.6deg 64.8deg,
91
- var(--second) 64.8deg 72deg,
92
- var(--first) 72deg 79.2deg,
93
- var(--second) 79.2deg 86.4deg,
94
- var(--first) 86.4deg 93.6deg,
95
- var(--second) 93.6deg 100.8deg,
96
- var(--first) 100.8deg 108deg,
97
- var(--second) 108deg 115.2deg,
98
- var(--first) 115.2deg 122.4deg,
99
- var(--second) 122.4deg 129.6deg,
100
- var(--first) 129.6deg 136.8deg,
101
- var(--second) 136.8deg 144deg,
102
- var(--first) 144deg 151.2deg,
103
- var(--second) 151.2deg 158.4deg,
104
- var(--first) 158.4deg 165.6deg,
105
- var(--second) 165.6deg 172.8deg,
106
- var(--first) 172.8deg 180deg,
107
- var(--second) 180deg 187.2deg,
108
- var(--first) 187.2deg 194.4deg,
109
- var(--second) 194.4deg 201.6deg,
110
- var(--first) 201.6deg 208.8deg,
111
- var(--second) 208.8deg 216deg,
112
- var(--first) 216deg 223.2deg,
113
- var(--second) 223.2deg 230.4deg,
114
- var(--first) 230.4deg 237.6deg,
115
- var(--second) 237.6deg 244.8deg,
116
- var(--first) 244.8deg 252deg,
117
- var(--second) 252deg 259.2deg,
118
- var(--first) 259.2deg 266.4deg,
119
- var(--second) 266.4deg 273.6deg,
120
- var(--first) 273.6deg 280.8deg,
121
- var(--second) 280.8deg 288deg,
122
- var(--first) 288deg 295.2deg,
123
- var(--second) 295.2deg 302.4deg,
124
- var(--first) 302.4deg 309.6deg,
125
- var(--second) 309.6deg 316.8deg,
126
- var(--first) 316.8deg 324deg,
127
- var(--second) 324deg 331.2deg,
128
- var(--first) 331.2deg 338.4deg,
129
- var(--second) 338.4deg 345.6deg,
130
- var(--first) 345.6deg 352.8deg,
131
- var(--second) 352.8deg 360deg
132
- );
133
- animation: rotate 20s linear infinite;
134
- }
135
-
136
- @media (max-width: 1024px) {
137
- .light-rays::before,
138
- .light-rays::after {
139
- left: auto;
140
- right: 11%;
141
- }
142
- }
143
-
144
- /* ScrollArea.module.css */
145
- .scrollArea {
146
- overflow-y: scroll;
147
- padding-right: 4px;
148
- }
149
-
150
- /* WebKit-based browsers */
151
- .scrollArea::-webkit-scrollbar {
152
- width: 8px;
153
- }
154
-
155
- .scrollArea::-webkit-scrollbar-track {
156
- background: var(--color-bg-primary-alt);
157
- border-radius: 9999px;
158
- }
159
-
160
- .scrollArea::-webkit-scrollbar-thumb {
161
- background-color: var(--color-bg-quaternary);
162
- border-radius: 9999px;
163
- }
164
-
165
- @keyframes waveColor {
166
- 0%,
167
- 2.5% {
168
- color: var(--wave-highlight-color);
169
- }
170
- 2.51%,
171
- 100% {
172
- color: var(--color-brand-300);
173
- }
174
- }
175
-
176
- .animate-wave-color-success {
177
- --wave-highlight-color: var(--color-success-800);
178
- animation: waveColor 4s ease-in-out infinite;
179
- }
180
-
181
- .animate-wave-color-error {
182
- --wave-highlight-color: var(--color-error-600);
183
- animation: waveColor 4s ease-in-out infinite;
184
- }
1
+ @keyframes arrow-green-flash {
2
+ 0% {
3
+ color: #abefc6;
4
+ }
5
+ 100% {
6
+ color: #079455;
7
+ }
8
+ }
9
+
10
+ .animate-arrow-green-flash-1 {
11
+ animation: arrow-green-flash 0.4s infinite;
12
+ animation-delay: -0.2s;
13
+ }
14
+
15
+ .animate-arrow-green-flash-2 {
16
+ animation: arrow-green-flash 0.4s infinite;
17
+ animation-delay: -0.1s;
18
+ }
19
+
20
+ .animate-arrow-green-flash-3 {
21
+ animation: arrow-green-flash 0.4s infinite;
22
+ }
23
+
24
+ @keyframes arrow-red-flash {
25
+ 0%,
26
+ 100% {
27
+ color: #f97066;
28
+ }
29
+ 50% {
30
+ color: #fecdca;
31
+ }
32
+ }
33
+
34
+ .animate-arrow-red-flash-1 {
35
+ animation: arrow-red-flash 0.4s infinite;
36
+ }
37
+
38
+ .animate-arrow-red-flash-2 {
39
+ animation: arrow-red-flash 0.4s infinite;
40
+ animation-delay: -0.1s;
41
+ }
42
+
43
+ .animate-arrow-red-flash-3 {
44
+ animation: arrow-red-flash 0.4s infinite;
45
+ animation-delay: -0.2s;
46
+ }
47
+
48
+ /* Animated BG */
49
+ @keyframes rotate {
50
+ to {
51
+ transform: rotate(1turn);
52
+ }
53
+ }
54
+
55
+ .light-rays {
56
+ position: absolute;
57
+ top: 0;
58
+ left: 0;
59
+ right: 0;
60
+ bottom: 0;
61
+ overflow: hidden;
62
+
63
+ --first: var(--color-bg-tertiary);
64
+ --second: var(--color-bg-quaternary);
65
+ }
66
+
67
+ .light-rays::before,
68
+ .light-rays::after {
69
+ content: '';
70
+ position: absolute;
71
+ top: var(--light-rays-top, 150px);
72
+ left: calc(50% - 90px);
73
+ margin: -100vmax;
74
+ width: 200vmax;
75
+ height: 200vmax;
76
+ opacity: 0.6;
77
+ transform-origin: center;
78
+ }
79
+
80
+ .light-rays::before {
81
+ background: conic-gradient(
82
+ var(--first) 0deg 7.2deg,
83
+ var(--second) 7.2deg 14.4deg,
84
+ var(--first) 14.4deg 21.6deg,
85
+ var(--second) 21.6deg 28.8deg,
86
+ var(--first) 28.8deg 36deg,
87
+ var(--second) 36deg 43.2deg,
88
+ var(--first) 43.2deg 50.4deg,
89
+ var(--second) 50.4deg 57.6deg,
90
+ var(--first) 57.6deg 64.8deg,
91
+ var(--second) 64.8deg 72deg,
92
+ var(--first) 72deg 79.2deg,
93
+ var(--second) 79.2deg 86.4deg,
94
+ var(--first) 86.4deg 93.6deg,
95
+ var(--second) 93.6deg 100.8deg,
96
+ var(--first) 100.8deg 108deg,
97
+ var(--second) 108deg 115.2deg,
98
+ var(--first) 115.2deg 122.4deg,
99
+ var(--second) 122.4deg 129.6deg,
100
+ var(--first) 129.6deg 136.8deg,
101
+ var(--second) 136.8deg 144deg,
102
+ var(--first) 144deg 151.2deg,
103
+ var(--second) 151.2deg 158.4deg,
104
+ var(--first) 158.4deg 165.6deg,
105
+ var(--second) 165.6deg 172.8deg,
106
+ var(--first) 172.8deg 180deg,
107
+ var(--second) 180deg 187.2deg,
108
+ var(--first) 187.2deg 194.4deg,
109
+ var(--second) 194.4deg 201.6deg,
110
+ var(--first) 201.6deg 208.8deg,
111
+ var(--second) 208.8deg 216deg,
112
+ var(--first) 216deg 223.2deg,
113
+ var(--second) 223.2deg 230.4deg,
114
+ var(--first) 230.4deg 237.6deg,
115
+ var(--second) 237.6deg 244.8deg,
116
+ var(--first) 244.8deg 252deg,
117
+ var(--second) 252deg 259.2deg,
118
+ var(--first) 259.2deg 266.4deg,
119
+ var(--second) 266.4deg 273.6deg,
120
+ var(--first) 273.6deg 280.8deg,
121
+ var(--second) 280.8deg 288deg,
122
+ var(--first) 288deg 295.2deg,
123
+ var(--second) 295.2deg 302.4deg,
124
+ var(--first) 302.4deg 309.6deg,
125
+ var(--second) 309.6deg 316.8deg,
126
+ var(--first) 316.8deg 324deg,
127
+ var(--second) 324deg 331.2deg,
128
+ var(--first) 331.2deg 338.4deg,
129
+ var(--second) 338.4deg 345.6deg,
130
+ var(--first) 345.6deg 352.8deg,
131
+ var(--second) 352.8deg 360deg
132
+ );
133
+ animation: rotate 20s linear infinite;
134
+ }
135
+
136
+ @media (max-width: 1024px) {
137
+ .light-rays::before,
138
+ .light-rays::after {
139
+ left: auto;
140
+ right: 11%;
141
+ }
142
+ }
143
+
144
+ /* ScrollArea.module.css */
145
+ .scrollArea {
146
+ overflow-y: scroll;
147
+ padding-right: 4px;
148
+ }
149
+
150
+ /* WebKit-based browsers */
151
+ .scrollArea::-webkit-scrollbar {
152
+ width: 8px;
153
+ }
154
+
155
+ .scrollArea::-webkit-scrollbar-track {
156
+ background: var(--color-bg-primary-alt);
157
+ border-radius: 9999px;
158
+ }
159
+
160
+ .scrollArea::-webkit-scrollbar-thumb {
161
+ background-color: var(--color-bg-quaternary);
162
+ border-radius: 9999px;
163
+ }
164
+
165
+ @keyframes waveColor {
166
+ 0%,
167
+ 2.5% {
168
+ color: var(--wave-highlight-color);
169
+ }
170
+ 2.51%,
171
+ 100% {
172
+ color: var(--color-brand-300);
173
+ }
174
+ }
175
+
176
+ .animate-wave-color-success {
177
+ --wave-highlight-color: var(--color-success-800);
178
+ animation: waveColor 4s ease-in-out infinite;
179
+ }
180
+
181
+ .animate-wave-color-error {
182
+ --wave-highlight-color: var(--color-error-600);
183
+ animation: waveColor 4s ease-in-out infinite;
184
+ }
@@ -1,9 +1 @@
1
- import type { Jackpot } from '@opexa/portal-sdk-core';
2
- import type { GameProviderData } from '../../types';
3
- export interface JackpotItemProps {
4
- jackpot: Jackpot;
5
- /** @default "/jackpots" */
6
- viewAllUrl?: string;
7
- gameProviders: GameProviderData[];
8
- }
9
- export declare function JackpotItemDesktop({ jackpot, gameProviders, }: JackpotItemProps): import("react/jsx-runtime").JSX.Element;
1
+ export declare function JackpotItemDesktop(): import("react/jsx-runtime").JSX.Element;
@@ -13,9 +13,11 @@ import { formatNumber, getPercentage, mask } from '../../utils/index.js';
13
13
  import styles from '../JackpotCounter/JackpotCounterItem.module.css';
14
14
  import { JackpotGameProviders } from './JackpotGameProviders.js';
15
15
  import { JackpotRules } from './JackpotRules.js';
16
+ import { useJackpotContext } from './JackpotsContext.js';
16
17
  import { useJackpotItemData } from './useJackpotItemData.js';
17
- export function JackpotItemDesktop({ jackpot, gameProviders, }) {
18
- const { jackpotPayouts, topJackpotPayout, filteredGameProviders, localeInfo, isPayingOut, jackpotAmount, arrowImages, getAccumulatingJackpotDescription, starTierStyles, } = useJackpotItemData({ jackpot, gameProviders });
18
+ export function JackpotItemDesktop() {
19
+ const jackpot = useJackpotContext();
20
+ const { jackpotPayouts, topJackpotPayout, filteredGameProviders, localeInfo, isPayingOut, jackpotAmount, arrowImages, getAccumulatingJackpotDescription, starTierStyles, } = useJackpotItemData();
19
21
  return (_jsxs("div", { className: twMerge('bg-bg-tertiary border-border-primary rounded-2xl border'), children: [_jsxs("div", { className: twMerge('relative flex shrink-0 p-3 text-center lg:gap-4 lg:p-5'), children: [_jsxs("div", { className: "z-1 relative flex flex-1 flex-col", children: [_jsx("div", { className: "flex h-full flex-col justify-between", children: _jsx("div", { className: "flex w-full justify-between", children: _jsxs("div", { className: "flex w-full flex-col", children: [_jsxs("div", { className: "relative flex w-full justify-between", children: [_jsxs("div", { children: [isPayingOut ? (_jsxs("div", { className: "border-utility-success-200 bg-utility-success-50 text-utility-success-700 flex w-fit items-center gap-1 rounded-full border px-2 py-0.5 text-xs font-medium", children: [_jsx("span", { className: "full bg-utility-success-500 size-1.5 animate-pulse rounded" }), "Paying Out"] })) : (_jsxs("div", { className: "border-utility-blue-200 bg-utility-blue-50 text-utility-blue-700 flex w-fit items-center gap-1 rounded-full border px-2 py-0.5 text-xs font-medium", children: [_jsx(ArrowNarrowUpRightIcon, { className: "text-utility-blue-500 size-3.5" }), "Accumulating"] })), _jsx("div", { className: "text-text-primary-900 mt-1 text-left text-lg font-medium lg:mt-5 lg:text-2xl", children: jackpot.name }), _jsx("div", { className: "bg-bg-primary text-brand-400 mt-1.5 w-fit rounded-md px-2 py-1 text-2xl font-bold lg:mt-2 lg:text-4xl", children: formatNumber(jackpotAmount, {
20
22
  currency: localeInfo.currency.code,
21
23
  minDecimalPlaces: 2,
@@ -35,7 +37,7 @@ export function JackpotItemDesktop({ jackpot, gameProviders, }) {
35
37
  currency: localeInfo.currency.code,
36
38
  compact: true,
37
39
  })} Play now for your chance to win big! 🔥`
38
- : getAccumulatingJackpotDescription(Number(jackpot?.pool) ?? 0, Number(jackpot?.maximumJackpotPoolLimit) ?? 0) })] })] }), _jsxs("div", { className: "z-1 hidden flex-1 space-y-4 lg:block", children: [_jsxs("div", { className: "flex items-center justify-between", children: [_jsxs("div", { className: "flex gap-2", children: [_jsx(Image, { width: 24, height: 24, src: leaderboard, quality: 100, alt: "leaderboardIcon", className: "size-full h-auto w-6" }), _jsx("div", { className: "text-text-primary-900 text-lg font-semibold", children: jackpotPayouts.length ? 'Leaderboard' : 'Starting soon!' })] }), _jsx(JackpotRules, { jackpotRules: jackpot.description })] }), _jsx("div", { className: twMerge('max-h-[272px] overflow-y-scroll', styles['scrollArea']), children: _jsx("div", { className: "border-gray-200 overflow-hidden rounded-xl", children: _jsxs("table", { className: "w-full", children: [_jsx("thead", { children: _jsxs("tr", { className: "bg-bg-secondary text-text-tertiary-600 h-8 text-xs font-medium", children: [_jsx("th", { className: "w-[52px]", children: "#" }), _jsx("th", { children: "Player" }), _jsx("th", { children: "Multiplier" }), _jsx("th", { children: "Prize" })] }) }), _jsx("tbody", { children: jackpotPayouts.length ? (_jsx(_Fragment, { children: jackpotPayouts.map((jackpotPayout, i) => (_jsxs("tr", { className: "bg-bg-primary text-text-secondary-700 text-sm", children: [_jsx("td", { className: "border-border-secondary h-12 w-[52px] border-t-2", children: i + 1 < 6 ? (_jsxs("div", { className: "relative", children: [_jsx(StarIcon, { className: twMerge('mx-auto size-6.5', starTierStyles[i].starColor) }), _jsx("span", { className: twMerge('absolute inset-0 mt-0.5 flex items-center justify-center text-2xs font-bold', starTierStyles[i].numberColor), children: i + 1 })] })) : (i + 1) }), _jsx("td", { className: "border-border-secondary h-12 border-t-2", children: mask(jackpotPayout.member.name) }), _jsxs("td", { className: "border-border-secondary h-12 border-t-2", children: [jackpotPayout.multiplier, "x"] }), _jsx("td", { className: "border-border-secondary text-brand-400 h-12 border-t-2", children: formatNumber(jackpotPayout.amount, {
40
+ : getAccumulatingJackpotDescription(Number(jackpot?.pool) ?? 0, Number(jackpot?.maximumJackpotPoolLimit) ?? 0) })] })] }), _jsxs("div", { className: "z-1 hidden flex-1 space-y-4 lg:block", children: [_jsxs("div", { className: "flex items-center justify-between", children: [_jsxs("div", { className: "flex gap-2", children: [_jsx(Image, { width: 24, height: 24, src: leaderboard, quality: 100, alt: "leaderboardIcon", className: "size-full h-auto w-6" }), _jsx("div", { className: "text-text-primary-900 text-lg font-semibold", children: jackpotPayouts.length ? 'Leaderboard' : 'Starting soon!' })] }), _jsx(JackpotRules, {})] }), _jsx("div", { className: twMerge('max-h-[272px] overflow-y-scroll', styles['scrollArea']), children: _jsx("div", { className: "border-gray-200 overflow-hidden rounded-xl", children: _jsxs("table", { className: "w-full", children: [_jsx("thead", { children: _jsxs("tr", { className: "bg-bg-secondary text-text-tertiary-600 h-8 text-xs font-medium", children: [_jsx("th", { className: "w-[52px]", children: "#" }), _jsx("th", { children: "Player" }), _jsx("th", { children: "Multiplier" }), _jsx("th", { children: "Prize" })] }) }), _jsx("tbody", { children: jackpotPayouts.length ? (_jsx(_Fragment, { children: jackpotPayouts.map((jackpotPayout, i) => (_jsxs("tr", { className: "bg-bg-primary text-text-secondary-700 text-sm", children: [_jsx("td", { className: "border-border-secondary h-12 w-[52px] border-t-2", children: i + 1 < 6 ? (_jsxs("div", { className: "relative", children: [_jsx(StarIcon, { className: twMerge('mx-auto size-6.5', starTierStyles[i].starColor) }), _jsx("span", { className: twMerge('absolute inset-0 mt-0.5 flex items-center justify-center text-2xs font-bold', starTierStyles[i].numberColor), children: i + 1 })] })) : (i + 1) }), _jsx("td", { className: "border-border-secondary h-12 border-t-2", children: mask(jackpotPayout.member.name) }), _jsxs("td", { className: "border-border-secondary h-12 border-t-2", children: [jackpotPayout.multiplier, "x"] }), _jsx("td", { className: "border-border-secondary text-brand-400 h-12 border-t-2", children: formatNumber(jackpotPayout.amount, {
39
41
  currency: localeInfo.currency.code,
40
42
  minDecimalPlaces: 2,
41
43
  maxDecimalPlaces: 2,
@@ -1,9 +1 @@
1
- import type { Jackpot } from '@opexa/portal-sdk-core';
2
- import type { GameProviderData } from '../../types';
3
- export interface JackpotItemMobileProps {
4
- jackpot: Jackpot;
5
- /** @default "/jackpots" */
6
- viewAllUrl?: string;
7
- gameProviders: GameProviderData[];
8
- }
9
- export declare function JackpotItemMobile({ jackpot, gameProviders, }: JackpotItemMobileProps): import("react/jsx-runtime").JSX.Element;
1
+ export declare function JackpotItemMobile(): import("react/jsx-runtime").JSX.Element;