@opexa/portal-components 0.0.885 → 0.0.886
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/Jackpots/JackpotsCarousel/JackpotsCarousel.client.js +2 -1
- package/dist/components/Jackpots/JackpotsCarousel/JackpotsCarouselItem.CrazyWin.js +4 -4
- package/dist/components/Jackpots/JackpotsCarousel/JackpotsCarouselItem.HappyBingo.d.ts +9 -0
- package/dist/components/Jackpots/JackpotsCarousel/JackpotsCarouselItem.HappyBingo.js +160 -0
- package/dist/components/Jackpots/JackpotsList/JackpotsList.d.ts +1 -0
- package/dist/components/Jackpots/JackpotsList/JackpotsList.js +2 -1
- package/dist/components/Jackpots/JackpotsList/JackpotsListItem.CrazyWin.d.ts +6 -0
- package/dist/components/Jackpots/JackpotsList/JackpotsListItem.CrazyWin.js +173 -0
- package/dist/components/Jackpots/JackpotsList/JackpotsListItemGameProviders.d.ts +3 -1
- package/dist/components/Jackpots/JackpotsList/JackpotsListItemGameProviders.js +2 -2
- package/dist/components/Jackpots/utils.d.ts +14 -1
- package/dist/components/Jackpots/utils.js +53 -1
- package/dist/components/SignIn/MobileNumberField.js +5 -4
- package/dist/icons/User02Icon.d.ts +2 -0
- package/dist/icons/User02Icon.js +4 -0
- package/dist/images/happy-bingo-coins.webp +0 -0
- package/package.json +1 -1
|
@@ -19,6 +19,7 @@ const JackpotsCarouselNext = lazy(() => import('../JackpotsCarouselNext/Jackpots
|
|
|
19
19
|
import { JackpotsCarouselItemContext } from './JackpotsCarouselContext.js';
|
|
20
20
|
import { JackpotsCarouselItem } from './JackpotsCarouselItem.js';
|
|
21
21
|
import { JackpotsCarouselItemCrazyWin } from './JackpotsCarouselItem.CrazyWin.js';
|
|
22
|
+
import { JackpotsCarouselItemHappyBingo } from './JackpotsCarouselItem.HappyBingo.js';
|
|
22
23
|
export function JackpotsCarousel__client({ style, className, ...props }) {
|
|
23
24
|
const [emblaRef, emblaApi] = useEmblaCarousel({
|
|
24
25
|
align: 'start',
|
|
@@ -71,7 +72,7 @@ export function JackpotsCarousel__client({ style, className, ...props }) {
|
|
|
71
72
|
const classNames = useMemo(() => (isString(className) ? { root: className } : (className ?? {})), [className]);
|
|
72
73
|
if (jackpots.length <= 0)
|
|
73
74
|
return null;
|
|
74
|
-
return (_jsxs("div", { ref: ref, style: styles.root, className: classNames.root, children: [_jsxs("div", { className: "flex items-center justify-between", children: [_jsx("div", { className: "font-semibold text-lg", children: props.heading ?? 'Jackpots' }), _jsxs("div", { className: "flex items-center md:gap-3xl", children: [_jsxs(Link, { href: props.viewAllUrl ?? '/jackpots', className: "flex gap-sm font-semibold text-button-tertiary-fg text-sm", children: ["See All", _jsx(ChevronRightIcon, { className: "size-5 lg:hidden" })] }), _jsxs("div", { className: "hidden lg:flex", children: [_jsx(Button, { disabled: !canScrollPrev, onClick: scrollPrev, variant: "outline", colorScheme: "gray", className: "rounded-r-none border-r-0", "aria-label": "Previous", children: _jsx(ArrowLeftIcon, { className: "size-5" }) }), _jsxs(Button, { disabled: !canScrollNext, onClick: scrollNext, variant: "outline", colorScheme: "gray", className: "rounded-l-none", "aria-label": "Next", children: [_jsx("span", { className: "sr-only", children: "Next" }), _jsx(ArrowRightIcon, { className: "size-5" })] })] })] })] }), _jsx("div", { className:
|
|
75
|
+
return (_jsxs("div", { ref: ref, style: styles.root, className: classNames.root, children: [_jsxs("div", { className: "flex items-center justify-between", children: [_jsx("div", { className: "font-semibold text-lg", children: props.heading ?? 'Jackpots' }), _jsxs("div", { className: "flex items-center md:gap-3xl", children: [_jsxs(Link, { href: props.viewAllUrl ?? '/jackpots', className: "flex gap-sm font-semibold text-button-tertiary-fg text-sm", children: ["See All", _jsx(ChevronRightIcon, { className: "size-5 lg:hidden" })] }), _jsxs("div", { className: "hidden lg:flex", children: [_jsx(Button, { disabled: !canScrollPrev, onClick: scrollPrev, variant: "outline", colorScheme: "gray", className: "rounded-r-none border-r-0", "aria-label": "Previous", children: _jsx(ArrowLeftIcon, { className: "size-5" }) }), _jsxs(Button, { disabled: !canScrollNext, onClick: scrollNext, variant: "outline", colorScheme: "gray", className: "rounded-l-none", "aria-label": "Next", children: [_jsx("span", { className: "sr-only", children: "Next" }), _jsx(ArrowRightIcon, { className: "size-5" })] })] })] })] }), _jsx("div", { className: "relative overflow-hidden pt-lg", ref: emblaRef, children: _jsx("div", { className: "flex gap-2.5", children: jackpots.map((jackpot, index) => (_jsx(JackpotsCarouselItemContext, { value: jackpot, children: props.variant === 'crazywin' ? (_jsx(JackpotsCarouselItemCrazyWin, { index: index, className: classNames, viewAllUrl: props.viewAllUrl })) : props.variant === 'happybingo' ? (_jsx(JackpotsCarouselItemHappyBingo, { index: index, className: classNames, viewAllUrl: props.viewAllUrl })) : (_jsx(JackpotsCarouselItem, { style: styles.itemRoot, className: classNames, viewAllUrl: props.viewAllUrl, animate: props.animate, customJackpotChestImage: props.customJackpotChestImage, jackpotProfileShape: props.jackpotProfileShape, chestImagesByTier: props.chestImagesByTier })) }, jackpot.id ?? index))) }) })] }));
|
|
75
76
|
}
|
|
76
77
|
export function JackpotsCarousels__client(props) {
|
|
77
78
|
const future = useFeatureFlag();
|
|
@@ -16,7 +16,7 @@ import treasureChest from '../../../images/treasure.webp';
|
|
|
16
16
|
import { formatNumber } from '../../../utils/formatNumber.js';
|
|
17
17
|
import { parseDecimal } from '../../../utils/parseDecimal.js';
|
|
18
18
|
import styles from '../Jackpots.module.css';
|
|
19
|
-
import {
|
|
19
|
+
import { CRAZYWIN_JACKPOTS_VARIATIONS } from '../utils.js';
|
|
20
20
|
import { useJackpotsCarouselItemContext } from './JackpotsCarouselContext.js';
|
|
21
21
|
export function JackpotsCarouselItemCrazyWin({ index, }) {
|
|
22
22
|
const [ref] = useIntersectionObserver({
|
|
@@ -85,7 +85,7 @@ export function JackpotsCarouselItemCrazyWin({ index, }) {
|
|
|
85
85
|
if (jackpot.status === 'DISABLED' && jackpot.drawing !== true) {
|
|
86
86
|
return null;
|
|
87
87
|
}
|
|
88
|
-
const variation =
|
|
88
|
+
const variation = CRAZYWIN_JACKPOTS_VARIATIONS[index % CRAZYWIN_JACKPOTS_VARIATIONS.length];
|
|
89
89
|
return (_jsxs("div", { className: "w-full shrink-0", children: [_jsxs("div", { ref: ref, className: twMerge('relative flex w-full shrink-0 rounded-t-2xl p-3 text-center lg:gap-4 lg:p-5', variation.background), children: [_jsxs("div", { className: "relative z-1 flex flex-1 flex-col", children: [[
|
|
90
90
|
[
|
|
91
91
|
styles['flicker-scale-fade-2'],
|
|
@@ -113,7 +113,7 @@ export function JackpotsCarouselItemCrazyWin({ index, }) {
|
|
|
113
113
|
],
|
|
114
114
|
].map(([animationClass, positionClass], i) => (_jsx(Image, { src: star, alt: "star", draggable: "false", className: twMerge(animationClass, positionClass) }, i))), _jsx("div", { className: "flex h-full flex-col justify-between", children: _jsx("div", { className: "flex w-full justify-between", children: _jsx("div", { className: "flex w-full flex-col", children: _jsxs("div", { className: "relative flex w-full justify-between", children: [_jsxs("div", { children: [_jsx("div", { className: "mb-2 flex gap-1 font-medium", children: _jsxs("div", { className: twMerge('flex w-fit items-center justify-center gap-1 rounded-[10px] border border-[#82F0D0] px-[10px] py-1 text-[#82F0D0] text-xs lg:text-sm'), children: [_jsx("div", { className: twMerge('h-[6px] w-[6px] animate-color rounded-full', isPayingOut
|
|
115
115
|
? styles['pulse-error']
|
|
116
|
-
: styles['pulse-success']) }), _jsx("div", { className: twMerge('rounded text-[#CECFD2]'), children: isPayingOut ? 'Paying Out' : 'Accumulating' })] }) }), _jsx("div", { className: "mb-2 font-semibold text-[18px] text-white lg:mb-0 lg:text-2xl", children: jackpot?.name }), _jsx("div", { className: `${variation.poolBg} ${variation.textColor} flex w-fit rounded-lg px-2 font-semibold text-[26px] lg:text-[36px]`, children: formatNumber(jackpotAmount, {
|
|
116
|
+
: styles['pulse-success']) }), _jsx("div", { className: twMerge('rounded text-[#CECFD2]'), children: isPayingOut ? 'Paying Out' : 'Accumulating' })] }) }), _jsx("div", { className: "mb-2 text-left font-semibold text-[18px] text-white lg:mb-0 lg:text-2xl", children: jackpot?.name }), _jsx("div", { className: `${variation.poolBg} ${variation.textColor} flex w-fit rounded-lg px-2 font-semibold text-[26px] lg:text-[36px]`, children: formatNumber(jackpotAmount, {
|
|
117
117
|
currency: localeInfo.currency.code,
|
|
118
118
|
minDecimalPlaces: 2,
|
|
119
119
|
maxDecimalPlaces: 2,
|
|
@@ -129,7 +129,7 @@ export function JackpotsCarouselItemCrazyWin({ index, }) {
|
|
|
129
129
|
maxDecimalPlaces: 2,
|
|
130
130
|
}) || 'N/A'] })] }), _jsxs("div", { children: ["Multiplier Requirement:", ' ', _jsx("span", { className: "font-semibold text-[#FFE5AF]", children: jackpot.minimumMultiplier
|
|
131
131
|
? `${jackpot.minimumMultiplier}X or more`
|
|
132
|
-
: 'N/A' })] })] })), _jsx("button", { type: "button", className:
|
|
132
|
+
: 'N/A' })] })] })), _jsx("button", { type: "button", className: "text-nowrap text-[#FFE5AF] text-sm underline underline-offset-4", children: "Jackpot Rules" })] })] }));
|
|
133
133
|
}
|
|
134
134
|
const getAccumulatingJackpotDescription = (part, total) => {
|
|
135
135
|
const percentage = total === 0 ? 0 : (part / total) * 100;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { ClassNameEntries } from './JackpotsCarousel';
|
|
2
|
+
export interface JackpotsCarouselItemHappyBingoProps {
|
|
3
|
+
index: number;
|
|
4
|
+
className?: ClassNameEntries;
|
|
5
|
+
/** @default "/jackpots" */
|
|
6
|
+
viewAllUrl?: string;
|
|
7
|
+
}
|
|
8
|
+
export declare function JackpotsCarouselItemHappyBingo({ index, }: JackpotsCarouselItemHappyBingoProps): import("react/jsx-runtime").JSX.Element | null;
|
|
9
|
+
export declare const getAccumulatingJackpotDescription: (part: number, total: number) => string;
|
|
@@ -0,0 +1,160 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
3
|
+
import { Progress } from '@ark-ui/react/progress';
|
|
4
|
+
import isMobile from 'is-mobile';
|
|
5
|
+
import Image from 'next/image';
|
|
6
|
+
import { useCallback, useEffect, useMemo, useState } from 'react';
|
|
7
|
+
import { twMerge } from 'tailwind-merge';
|
|
8
|
+
import { useIntersectionObserver } from 'usehooks-ts';
|
|
9
|
+
import { useJackpotPayoutsQuery } from '../../../client/hooks/useJackpotPayoutsQuery.js';
|
|
10
|
+
import { useLocaleInfo } from '../../../client/hooks/useLocaleInfo.js';
|
|
11
|
+
import { ArrowNarrowUpRightIcon } from '../../../icons/ArrowNarrowUpRightIcon.js';
|
|
12
|
+
import { ChevronLeftIcon } from '../../../icons/ChevronLeftIcon.js';
|
|
13
|
+
import { ChevronRightIcon } from '../../../icons/ChevronRightIcon.js';
|
|
14
|
+
import { User02Icon } from '../../../icons/User02Icon.js';
|
|
15
|
+
import treasureChestBg from '../../../images/chest-bg.webp';
|
|
16
|
+
import coins from '../../../images/happy-bingo-coins.webp';
|
|
17
|
+
import star from '../../../images/star.webp';
|
|
18
|
+
import treasureChest from '../../../images/treasure.webp';
|
|
19
|
+
import { formatNumber } from '../../../utils/formatNumber.js';
|
|
20
|
+
import { getPercentage } from '../../../utils/getPercentage.js';
|
|
21
|
+
import styles from '../Jackpots.module.css';
|
|
22
|
+
import { HAPPYBINGO_JACKPOTS_VARIATIONS, maskName } from '../utils.js';
|
|
23
|
+
import { useJackpotsCarouselItemContext } from './JackpotsCarouselContext.js';
|
|
24
|
+
export function JackpotsCarouselItemHappyBingo({ index, }) {
|
|
25
|
+
// 1. Hooks (Context, Data, State, Refs)
|
|
26
|
+
const [ref] = useIntersectionObserver({
|
|
27
|
+
threshold: 0.5,
|
|
28
|
+
rootMargin: '50px',
|
|
29
|
+
});
|
|
30
|
+
const jackpot = useJackpotsCarouselItemContext();
|
|
31
|
+
const jackpotPayoutsQuery = useJackpotPayoutsQuery({
|
|
32
|
+
first: 1,
|
|
33
|
+
filter: {
|
|
34
|
+
jackpot: {
|
|
35
|
+
equal: jackpot.id,
|
|
36
|
+
},
|
|
37
|
+
},
|
|
38
|
+
});
|
|
39
|
+
const jackpotPayouts = jackpotPayoutsQuery.data?.pages[0].edges.map((edge) => edge.node) ?? [];
|
|
40
|
+
const localeInfo = useLocaleInfo();
|
|
41
|
+
const [showSeeDetailsButton, setShowSeeDetailsButton] = useState(true);
|
|
42
|
+
const [infoIndex, setInfoIndex] = useState(0);
|
|
43
|
+
const [mainTooltipOpen, setMainTooltipOpen] = useState(false);
|
|
44
|
+
// 2. Derived State & Constants
|
|
45
|
+
const isPayingOut = jackpot.drawing;
|
|
46
|
+
const jackpotAmount = jackpot.pool;
|
|
47
|
+
const variation = HAPPYBINGO_JACKPOTS_VARIATIONS[index % HAPPYBINGO_JACKPOTS_VARIATIONS.length];
|
|
48
|
+
// 3. Memoized Callbacks & Values
|
|
49
|
+
const isMobileDevice = useMemo(() => isMobile(), []);
|
|
50
|
+
const getInfoBlocks = useCallback(() => {
|
|
51
|
+
return [
|
|
52
|
+
`Current Jackpot: <b>${formatNumber(jackpotAmount, {
|
|
53
|
+
currency: localeInfo.currency.code,
|
|
54
|
+
minDecimalPlaces: 2,
|
|
55
|
+
maxDecimalPlaces: 2,
|
|
56
|
+
})}</b>`,
|
|
57
|
+
`Minimum Payout Limit: <b>${formatNumber(jackpot.minimumJackpotPoolDrawingLimit, {
|
|
58
|
+
currency: localeInfo.currency.code,
|
|
59
|
+
minDecimalPlaces: 2,
|
|
60
|
+
maxDecimalPlaces: 2,
|
|
61
|
+
})}</b>`,
|
|
62
|
+
`Maximum Payout Limit: <b>${formatNumber(jackpot.maximumJackpotPoolLimit, {
|
|
63
|
+
currency: localeInfo.currency.code,
|
|
64
|
+
minDecimalPlaces: 2,
|
|
65
|
+
maxDecimalPlaces: 2,
|
|
66
|
+
})}</b>`,
|
|
67
|
+
isPayingOut
|
|
68
|
+
? `The pot has hit <b>${formatNumber(jackpot.maximumJackpotPoolLimit, {
|
|
69
|
+
currency: localeInfo.currency.code,
|
|
70
|
+
minDecimalPlaces: 2,
|
|
71
|
+
maxDecimalPlaces: 2,
|
|
72
|
+
})}</b> Play now for your chance to win big! 🔥`
|
|
73
|
+
: getAccumulatingJackpotDescription(Number(jackpot.pool), Number(jackpot.maximumJackpotPoolLimit)),
|
|
74
|
+
];
|
|
75
|
+
}, [isPayingOut, jackpot, jackpotAmount, localeInfo]);
|
|
76
|
+
const Arrow = useCallback(({ index }) => {
|
|
77
|
+
const Icon = isPayingOut ? ChevronLeftIcon : ChevronRightIcon;
|
|
78
|
+
return (_jsx(Icon, { className: twMerge('min-w-2.5 scale-400 text-brand-300 lg:min-w-4 lg:scale-250', isPayingOut
|
|
79
|
+
? styles['animate-wave-color-error']
|
|
80
|
+
: styles['animate-wave-color-success']), style: {
|
|
81
|
+
animationDelay: isPayingOut
|
|
82
|
+
? `${(40 - index - 1) * 0.1}s`
|
|
83
|
+
: `${index * 0.1}s`,
|
|
84
|
+
} }));
|
|
85
|
+
}, [isPayingOut]);
|
|
86
|
+
const arrowImages = useMemo(() => Array.from({ length: 40 }, (_, i) => _jsx(Arrow, { index: i }, i)), [Arrow]);
|
|
87
|
+
// 4. Effects
|
|
88
|
+
useEffect(() => {
|
|
89
|
+
const interval = setInterval(() => {
|
|
90
|
+
setInfoIndex((i) => (i + 1) % getInfoBlocks().length);
|
|
91
|
+
setShowSeeDetailsButton((v) => !v);
|
|
92
|
+
}, 4000);
|
|
93
|
+
return () => clearInterval(interval);
|
|
94
|
+
}, [getInfoBlocks]);
|
|
95
|
+
useEffect(() => {
|
|
96
|
+
if (isMobileDevice && mainTooltipOpen) {
|
|
97
|
+
const timeout = setTimeout(() => setMainTooltipOpen(false), 3000);
|
|
98
|
+
return () => clearTimeout(timeout);
|
|
99
|
+
}
|
|
100
|
+
}, [mainTooltipOpen, isMobileDevice]);
|
|
101
|
+
// 5. Early Return
|
|
102
|
+
if (jackpot.status === 'DISABLED' && jackpot.drawing !== true) {
|
|
103
|
+
return null;
|
|
104
|
+
}
|
|
105
|
+
// 6. Main Render
|
|
106
|
+
return (_jsxs("div", { className: "w-full shrink-0", children: [_jsxs("div", { ref: ref, className: twMerge('relative flex w-full shrink-0 rounded-t-2xl p-3 lg:gap-4 lg:p-5', variation.background), children: [_jsxs("div", { className: "relative z-1 flex flex-1 flex-col", children: [[
|
|
107
|
+
[
|
|
108
|
+
styles['flicker-scale-fade-2'],
|
|
109
|
+
'absolute right-[38%] top-[2%] h-2 w-2 delay-75',
|
|
110
|
+
],
|
|
111
|
+
[
|
|
112
|
+
styles['flicker-scale-fade'],
|
|
113
|
+
'absolute right-[20%] top-[10%] h-3 w-3',
|
|
114
|
+
],
|
|
115
|
+
[
|
|
116
|
+
styles['flicker-scale-fade-2'],
|
|
117
|
+
'absolute right-[30%] top-[10%] h-5 w-5',
|
|
118
|
+
],
|
|
119
|
+
[
|
|
120
|
+
styles['flicker-scale-fade'],
|
|
121
|
+
'absolute right-[36%] top-[35%] h-3 w-3',
|
|
122
|
+
],
|
|
123
|
+
[
|
|
124
|
+
styles['flicker-scale-fade'],
|
|
125
|
+
'absolute right-[15%] top-[56%] h-3 w-3',
|
|
126
|
+
],
|
|
127
|
+
[
|
|
128
|
+
styles['flicker-scale-fade-2'],
|
|
129
|
+
'absolute right-[50%] top-[55%] h-4 w-4',
|
|
130
|
+
],
|
|
131
|
+
].map(([animationClass, positionClass], i) => (_jsx(Image, { src: star, alt: "star", draggable: "false", className: twMerge(animationClass, positionClass), unoptimized: true }, i))), _jsx("div", { className: "flex h-full flex-col justify-between", children: _jsx("div", { className: "flex w-full justify-between", children: _jsx("div", { className: "flex w-full flex-col", children: _jsxs("div", { className: "relative flex w-full justify-between", children: [_jsxs("div", { children: [_jsx("div", { className: "mb-2 flex gap-1 font-medium", children: _jsxs("div", { className: twMerge('flex w-fit items-center justify-center gap-1 rounded-[10px] border border-[#FECDCA] bg-[#FEF3F2] px-2.5 py-1 text-sm'), children: [_jsx("div", { className: twMerge('h-[6px] w-[6px] animate-color rounded-full', isPayingOut
|
|
132
|
+
? styles['pulse-error']
|
|
133
|
+
: styles['pulse-success']) }), _jsx("div", { className: twMerge('rounded text-[#344054]'), children: isPayingOut ? 'Paying Out' : 'Accumulating' })] }) }), _jsx("div", { className: "mb-2 text-left font-semibold text-[18px] text-white lg:mb-0 lg:text-2xl", children: jackpot?.name }), _jsx("div", { className: `${variation.poolBg} ${variation.textColor} flex w-fit rounded-lg px-2 font-semibold text-[26px] lg:text-[36px]`, children: formatNumber(jackpotAmount, {
|
|
134
|
+
currency: localeInfo.currency.code,
|
|
135
|
+
minDecimalPlaces: 2,
|
|
136
|
+
maxDecimalPlaces: 2,
|
|
137
|
+
}) })] }), _jsx(Image, { width: 175, height: 175, src: treasureChest, alt: "treasure chest", className: twMerge('absolute top-[0px] right-[-3px] h-[124px] w-[124px] md:top-0 lg:top-[-30px] lg:h-[175px] lg:w-[175px]'), priority: false, loading: "lazy", unoptimized: true })] }) }) }) }), _jsxs("div", { className: "mt-3 lg:mt-4", children: [_jsxs("div", { className: "mb-1 flex justify-between", children: [_jsx("div", { className: "font-semibold text-text-primary-900 text-xs", "aria-live": "polite", children: formatNumber(0, {
|
|
138
|
+
currency: localeInfo.currency.code,
|
|
139
|
+
compact: true,
|
|
140
|
+
}) }), _jsxs("div", { className: "relative flex items-center justify-end gap-1.5", children: [isPayingOut ? (_jsx("div", { className: "flex w-6 items-center", children: [0, 1.5, 3].map((left, i) => (_jsx("div", { className: twMerge(`absolute left-${left}`, styles[`animate-arrow-red-flash-${i + 1}`]), children: _jsx(ChevronLeftIcon, { className: "size-4.5" }) }, i))) })) : (_jsx("div", { className: "flex w-6 items-center", children: [0, 1.5, 3].map((left, i) => (_jsx("div", { className: twMerge(`absolute left-${left}`, styles[`animate-arrow-green-flash-${i + 1}`]), children: _jsx(ChevronRightIcon, { className: "size-4.5" }) }, i))) })), _jsx("div", { className: "font-semibold text-text-primary-900 text-xs", children: formatNumber(jackpot?.maximumJackpotPoolLimit, {
|
|
141
|
+
currency: localeInfo.currency.code,
|
|
142
|
+
compact: true,
|
|
143
|
+
}) })] })] }), _jsx(Progress.Root, { className: "h-2 w-full rounded-full bg-bg-primary lg:h-4", max: 100, value: getPercentage(jackpot.pool, jackpot.maximumJackpotPoolLimit), "aria-valuenow": getPercentage(jackpot.pool, jackpot.maximumJackpotPoolLimit), "aria-valuemax": 100, "aria-label": "Jackpot progress", children: _jsx(Progress.Track, { className: twMerge('h-full overflow-hidden rounded-full', variation.progressBg), children: _jsx(Progress.Range, { className: "relative h-full overflow-hidden rounded-full bg-brand-500 pl-1.5", children: _jsx("div", { className: "pointer-events-none absolute inset-0 flex items-center justify-start pl-1.5", "aria-hidden": "true", children: arrowImages }) }) }) }), _jsx("div", { className: "mt-2 h-2 text-left text-[#F5F5F6] text-xs lg:h-auto lg:text-sm", dangerouslySetInnerHTML: { __html: getInfoBlocks()[infoIndex] } }, infoIndex)] }), _jsx("div", { className: "mt-5 hidden items-start gap-5 text-white lg:flex", children: jackpotPayouts.length ? (_jsxs("div", { className: "flex h-full w-full flex-row items-center justify-between gap-3", children: [_jsxs("div", { children: [_jsx("p", { className: "mb-1 block font-bold text-lg", children: "Recent Payout \uD83C\uDF89" }), _jsxs("p", { className: "block text-xs leading-[18px] tracking-wider", children: ["Massive payout unlocked! ", _jsx("br", {}), " Who's next? \uD83D\uDCB0"] })] }), _jsxs("div", { className: "flex items-center gap-2", children: [_jsxs("div", { className: twMerge(variation.topPayoutImgBorderColor, 'relative flex h-[54px] w-[54px] items-center justify-center rounded-full object-contain p-[3.5px]'), children: [_jsx("div", { className: twMerge('flex h-full w-full items-center justify-center rounded-full', variation.topPayoutImgBg), children: _jsx(User02Icon, { className: "h-[34px] w-auto" }) }), _jsx("div", { className: twMerge(variation.topPayoutImgBorderColor, '-right-1.5 absolute bottom-[-5px] lg:right-[-5px] lg:bottom-[-5px]', 'flex h-[34px] w-[34px] items-center justify-center rounded-full p-0.5'), children: _jsxs("div", { className: twMerge('flex h-full w-full items-center justify-center rounded-full font-bold text-[10px]', variation.topPayoutImgBorderColor, variation.textColor, variation.multiplierBg, variation.multiplierColor), children: [jackpotPayouts[0].multiplier, "x"] }) })] }), _jsxs("div", { children: [_jsx("p", { className: "font-semibold text-2xl", children: maskName(jackpotPayouts[0].member.name) }), _jsx("p", { className: twMerge(variation.poolBg, 'rounded-lg px-2 font-semibold text-[22px]', variation.textColor), children: formatNumber(jackpotPayouts[0].amount, {
|
|
144
|
+
currency: localeInfo.currency.code,
|
|
145
|
+
minDecimalPlaces: 2,
|
|
146
|
+
maxDecimalPlaces: 2,
|
|
147
|
+
}) })] })] })] })) : (_jsxs("div", { className: "flex h-full w-full flex-row-reverse items-center justify-between", children: [_jsx(Image, { src: coins, alt: "coins", className: "ml-2", unoptimized: true }), _jsxs("div", { children: [_jsx("p", { className: "mt-1 font-semibold text-lg leading-6", children: "No one has won big yet" }), _jsxs("p", { className: "mt-1 text-[0.75rem] leading-[1.125rem]", children: ["You could be the first to win the ", _jsx("br", {}), " jackpot!"] })] })] })) })] }), isPayingOut ? (_jsx("div", { className: twMerge(styles['light-rays'], variation.raysColor, 'rounded-t-2xl [--light-rays-left:90%] [--light-rays-top:100px]') })) : (_jsx(Image, { width: 175, height: 175, src: treasureChestBg, alt: "treasure chest background", className: twMerge('absolute top-0 right-0 h-full w-[380px] object-cover opacity-50'), priority: false, loading: "lazy", unoptimized: true }))] }), _jsxs("div", { className: "relative flex h-[56px] min-h-[40px] w-full flex-1 items-center justify-between rounded-b-2xl bg-white px-4 py-[10px] text-[#475467] dark:bg-[#161B26] dark:text-[#94969C]", children: [showSeeDetailsButton ? (_jsxs("button", { type: "button", className: "] flex items-center gap-1 font-medium text-sm", children: ["See details", _jsx(ArrowNarrowUpRightIcon, { className: "h-5 w-5" })] })) : (_jsxs("div", { className: "w-full text-xs transition-opacity duration-500 ease-in-out", children: [_jsxs("div", { children: ["Minimum bet:", ' ', _jsxs("span", { className: "font-semibold text-[#A15C07] dark:text-[#EAAA08]", children: ["PHP", ' ', formatNumber(jackpot.minimumBet, {
|
|
148
|
+
currency: localeInfo.currency.code,
|
|
149
|
+
minDecimalPlaces: 2,
|
|
150
|
+
maxDecimalPlaces: 2,
|
|
151
|
+
}) || 'N/A'] })] }), _jsxs("div", { children: ["Multiplier Requirement:", ' ', _jsx("span", { className: "font-semibold text-[#A15C07] dark:text-[#EAAA08]", children: jackpot.minimumMultiplier
|
|
152
|
+
? `${jackpot.minimumMultiplier}X or more`
|
|
153
|
+
: 'N/A' })] })] })), _jsx("button", { type: "button", className: "inline-flex h-9 items-center justify-center gap-1.5 text-nowrap rounded-lg border border-[#EAAA08] bg-white px-4 py-2.5 font-semibold text-[#A15C07] text-sm text-sm shadow-xs transition-colors duration-200 hover:border-[#FDE272] hover:bg-[#FEFBE8] disabled:cursor-not-allowed disabled:opacity-50 disabled:hover:border-[#EAAA08] disabled:hover:bg-white dark:border-[#333741] dark:bg-[#161B26] dark:text-[#CECFD2] dark:disabled:hover:border-[#333741] dark:disabled:hover:bg-[#161B26]", children: "Jackpot Rules" })] })] }));
|
|
154
|
+
}
|
|
155
|
+
export const getAccumulatingJackpotDescription = (part, total) => {
|
|
156
|
+
const percentage = total === 0 ? 0 : (part / total) * 100;
|
|
157
|
+
return percentage <= 90
|
|
158
|
+
? 'The jackpot is heating up! Keep playing to stay in the action and watch it grow!'
|
|
159
|
+
: '🔥 It’s about to pop! Stay in the game for your shot at the prize!';
|
|
160
|
+
};
|
|
@@ -9,6 +9,7 @@ import closeChest from '../../../images/close-chest.png';
|
|
|
9
9
|
import { isStyleEntries } from '../../../utils/isStyleEntries.js';
|
|
10
10
|
import { JackpotsListNext } from '../JackpotsListNext/JackpotsList.js';
|
|
11
11
|
import { JackpotsListItemContext, JackpotsListPropsContext, } from './JackpotsListContext.js';
|
|
12
|
+
import { JackpotsListItemCrazyWin } from './JackpotsListItem.CrazyWin.js';
|
|
12
13
|
import { JackpotsListItemDesktop } from './JackpotsListItemDesktop.js';
|
|
13
14
|
import { JackpotsListItemMobile } from './JackpotsListItemMobile.js';
|
|
14
15
|
export function JackpotsList(props) {
|
|
@@ -43,5 +44,5 @@ export function JackpotsList(props) {
|
|
|
43
44
|
future.enabled) {
|
|
44
45
|
return _jsx(JackpotsListNext, { ...props });
|
|
45
46
|
}
|
|
46
|
-
return (_jsx(JackpotsListPropsContext, { value: props, children: _jsxs("div", { ref: ref, style: styles.root, className: classNames.root, children: [_jsx("div", { className: "mb-3 font-semibold text-lg lg:mb-4.5", children: props.heading ?? 'Jackpots' }), jackpots.length > 0 ? (_jsxs(_Fragment, { children: [_jsx("div", { className: "hidden flex-col gap-6 lg:flex", children: jackpots.map((jackpot, index) => (_jsx(JackpotsListItemContext, { value: jackpot, children: _jsx(JackpotsListItemDesktop, { style: styles.itemRoot, className: classNames, animate: props.animate, customJackpotChestImage: props.customJackpotChestImage, jackpotProfileShape: props.jackpotProfileShape, chestImagesByTier: props.chestImagesByTier }) }, index))) }), _jsx("div", { className: "flex flex-col gap-6 lg:hidden", children: jackpots.map((jackpot, index) => (_jsx(JackpotsListItemContext, { value: jackpot, children: _jsx(JackpotsListItemMobile, { style: styles.itemRoot, className: classNames, animate: props.animate, customJackpotChestImage: props.customJackpotChestImage, jackpotProfileShape: props.jackpotProfileShape, chestImagesByTier: props.chestImagesByTier }) }, index))) })] })) : (_jsxs("div", { className: "mt-5 flex h-fit flex-col items-center justify-center lg:mt-0 lg:h-62", children: [_jsx(Image, { width: 100, height: 100, src: closeChest, alt: "closeChest", className: "size-full h-29.5 w-29.5 mix-blend-luminosity lg:h-25 lg:w-25" }), _jsx("div", { className: "mt-4 font-semibold text-base text-text-primary-900", children: "No Jackpots" }), _jsxs("div", { className: "mt-1 text-center text-sm text-text-tertiary-600", children: ["No jackpots are running at the moment. ", _jsx("br", {}), "Please check back later!"] })] }))] }) }));
|
|
47
|
+
return (_jsx(JackpotsListPropsContext, { value: props, children: _jsxs("div", { ref: ref, style: styles.root, className: classNames.root, children: [_jsx("div", { className: "mb-3 font-semibold text-lg lg:mb-4.5", children: props.heading ?? 'Jackpots' }), jackpots.length > 0 ? (_jsxs(_Fragment, { children: [_jsx("div", { className: "hidden flex-col gap-6 lg:flex", children: jackpots.map((jackpot, index) => (_jsx(JackpotsListItemContext, { value: jackpot, children: props.variant === 'crazywin' ? (_jsx(JackpotsListItemCrazyWin, { index: index, className: classNames })) : (_jsx(JackpotsListItemDesktop, { style: styles.itemRoot, className: classNames, animate: props.animate, customJackpotChestImage: props.customJackpotChestImage, jackpotProfileShape: props.jackpotProfileShape, chestImagesByTier: props.chestImagesByTier })) }, index))) }), _jsx("div", { className: "flex flex-col gap-6 lg:hidden", children: jackpots.map((jackpot, index) => (_jsx(JackpotsListItemContext, { value: jackpot, children: props.variant === 'crazywin' ? (_jsx(JackpotsListItemCrazyWin, { index: index, className: classNames })) : (_jsx(JackpotsListItemMobile, { style: styles.itemRoot, className: classNames, animate: props.animate, customJackpotChestImage: props.customJackpotChestImage, jackpotProfileShape: props.jackpotProfileShape, chestImagesByTier: props.chestImagesByTier })) }, index))) })] })) : (_jsxs("div", { className: "mt-5 flex h-fit flex-col items-center justify-center lg:mt-0 lg:h-62", children: [_jsx(Image, { width: 100, height: 100, src: closeChest, alt: "closeChest", className: "size-full h-29.5 w-29.5 mix-blend-luminosity lg:h-25 lg:w-25" }), _jsx("div", { className: "mt-4 font-semibold text-base text-text-primary-900", children: "No Jackpots" }), _jsxs("div", { className: "mt-1 text-center text-sm text-text-tertiary-600", children: ["No jackpots are running at the moment. ", _jsx("br", {}), "Please check back later!"] })] }))] }) }));
|
|
47
48
|
}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type { ClassNameEntries } from './JackpotsList';
|
|
2
|
+
export interface JackpotsListItemDesktopCrazyWinProps {
|
|
3
|
+
index: number;
|
|
4
|
+
className?: ClassNameEntries;
|
|
5
|
+
}
|
|
6
|
+
export declare function JackpotsListItemCrazyWin({ index, }: JackpotsListItemDesktopCrazyWinProps): import("react/jsx-runtime").JSX.Element | null;
|
|
@@ -0,0 +1,173 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
3
|
+
import { Progress } from '@ark-ui/react/progress';
|
|
4
|
+
import { format } from 'date-fns';
|
|
5
|
+
import isMobile from 'is-mobile';
|
|
6
|
+
import Image from 'next/image';
|
|
7
|
+
import { useCallback, useEffect, useMemo, useState } from 'react';
|
|
8
|
+
import { twMerge } from 'tailwind-merge';
|
|
9
|
+
import { useIntersectionObserver } from 'usehooks-ts';
|
|
10
|
+
import { useJackpotPayoutsQuery } from '../../../client/hooks/useJackpotPayoutsQuery.js';
|
|
11
|
+
import { useLocaleInfo } from '../../../client/hooks/useLocaleInfo.js';
|
|
12
|
+
import { ChevronDownIcon } from '../../../icons/ChevronDownIcon.js';
|
|
13
|
+
import { ChevronLeftIcon } from '../../../icons/ChevronLeftIcon.js';
|
|
14
|
+
import { ChevronRightIcon } from '../../../icons/ChevronRightIcon.js';
|
|
15
|
+
import { ChevronUpIcon } from '../../../icons/ChevronUpIcon.js';
|
|
16
|
+
import { User02Icon } from '../../../icons/User02Icon.js';
|
|
17
|
+
import treasureChestBg from '../../../images/chest-bg.webp';
|
|
18
|
+
import coin from '../../../images/coin.webp';
|
|
19
|
+
import coins from '../../../images/coins.webp';
|
|
20
|
+
import star from '../../../images/star.webp';
|
|
21
|
+
import treasureChest from '../../../images/treasure.webp';
|
|
22
|
+
import { formatNumber } from '../../../utils/formatNumber.js';
|
|
23
|
+
import { getPercentage } from '../../../utils/getPercentage.js';
|
|
24
|
+
import styles from '../Jackpots.module.css';
|
|
25
|
+
import { CRAZYWIN_JACKPOTS_VARIATIONS, maskName } from '../utils.js';
|
|
26
|
+
import { useJackpotsListItemContext } from './JackpotsListContext.js';
|
|
27
|
+
import { JackpotsListItemGameProviders } from './JackpotsListItemGameProviders.js';
|
|
28
|
+
import { useJackpotsListItemData } from './useJackpotsListItemData.js';
|
|
29
|
+
export function JackpotsListItemCrazyWin({ index, }) {
|
|
30
|
+
const jackpot = useJackpotsListItemContext();
|
|
31
|
+
const localeInfo = useLocaleInfo();
|
|
32
|
+
const { getAccumulatingJackpotDescription, filteredGameProviders } = useJackpotsListItemData();
|
|
33
|
+
const jackpotPayoutsQuery = useJackpotPayoutsQuery({
|
|
34
|
+
first: 30,
|
|
35
|
+
filter: {
|
|
36
|
+
jackpot: {
|
|
37
|
+
equal: jackpot.id,
|
|
38
|
+
},
|
|
39
|
+
},
|
|
40
|
+
});
|
|
41
|
+
const [ref] = useIntersectionObserver({
|
|
42
|
+
threshold: 0.5,
|
|
43
|
+
rootMargin: '50px',
|
|
44
|
+
});
|
|
45
|
+
const [infoIndex, setInfoIndex] = useState(0);
|
|
46
|
+
const [seeDetails, setSeeDetails] = useState(false);
|
|
47
|
+
const [mainTooltipOpen, setMainTooltipOpen] = useState(false);
|
|
48
|
+
const isPayingOut = jackpot.drawing;
|
|
49
|
+
const jackpotAmount = jackpot.pool;
|
|
50
|
+
const jackpotPayouts = jackpotPayoutsQuery.data?.pages[0].edges.map((edge) => edge.node) ?? [];
|
|
51
|
+
const variation = CRAZYWIN_JACKPOTS_VARIATIONS[index % CRAZYWIN_JACKPOTS_VARIATIONS.length];
|
|
52
|
+
const isMobileDevice = useMemo(() => isMobile(), []);
|
|
53
|
+
const getInfoBlocks = useCallback(() => {
|
|
54
|
+
return [
|
|
55
|
+
`Current Jackpot: <b>${formatNumber(jackpotAmount, {
|
|
56
|
+
currency: localeInfo.currency.code,
|
|
57
|
+
minDecimalPlaces: 2,
|
|
58
|
+
maxDecimalPlaces: 2,
|
|
59
|
+
})}</b>`,
|
|
60
|
+
`Minimum Payout Limit: <b>${formatNumber(jackpot.minimumJackpotPoolDrawingLimit, {
|
|
61
|
+
currency: localeInfo.currency.code,
|
|
62
|
+
minDecimalPlaces: 2,
|
|
63
|
+
maxDecimalPlaces: 2,
|
|
64
|
+
})}</b>`,
|
|
65
|
+
`Maximum Payout Limit: <b>${formatNumber(jackpot.maximumJackpotPoolLimit, {
|
|
66
|
+
currency: localeInfo.currency.code,
|
|
67
|
+
minDecimalPlaces: 2,
|
|
68
|
+
maxDecimalPlaces: 2,
|
|
69
|
+
})}</b>`,
|
|
70
|
+
isPayingOut
|
|
71
|
+
? `The pot has hit <b>${formatNumber(jackpot.maximumJackpotPoolLimit, {
|
|
72
|
+
currency: localeInfo.currency.code,
|
|
73
|
+
minDecimalPlaces: 2,
|
|
74
|
+
maxDecimalPlaces: 2,
|
|
75
|
+
})}</b> Play now for your chance to win big! 🔥`
|
|
76
|
+
: getAccumulatingJackpotDescription(Number(jackpot.pool), Number(jackpot.maximumJackpotPoolLimit)),
|
|
77
|
+
];
|
|
78
|
+
}, [
|
|
79
|
+
isPayingOut,
|
|
80
|
+
jackpot,
|
|
81
|
+
jackpotAmount,
|
|
82
|
+
localeInfo,
|
|
83
|
+
getAccumulatingJackpotDescription,
|
|
84
|
+
]);
|
|
85
|
+
const Arrow = useCallback(({ index }) => {
|
|
86
|
+
const Icon = isPayingOut ? ChevronLeftIcon : ChevronRightIcon;
|
|
87
|
+
return (_jsx(Icon, { className: twMerge('min-w-2.5 scale-400 text-brand-300 lg:min-w-4 lg:scale-250', isPayingOut
|
|
88
|
+
? styles['animate-wave-color-error']
|
|
89
|
+
: styles['animate-wave-color-success']), style: {
|
|
90
|
+
animationDelay: isPayingOut
|
|
91
|
+
? `${(40 - index - 1) * 0.1}s`
|
|
92
|
+
: `${index * 0.1}s`,
|
|
93
|
+
} }));
|
|
94
|
+
}, [isPayingOut]);
|
|
95
|
+
const arrowImages = useMemo(() => Array.from({ length: 40 }, (_, i) => _jsx(Arrow, { index: i }, i)), [Arrow]);
|
|
96
|
+
useEffect(() => {
|
|
97
|
+
const interval = setInterval(() => {
|
|
98
|
+
setInfoIndex((i) => (i + 1) % getInfoBlocks().length);
|
|
99
|
+
}, 4000);
|
|
100
|
+
return () => clearInterval(interval);
|
|
101
|
+
}, [getInfoBlocks]);
|
|
102
|
+
useEffect(() => {
|
|
103
|
+
if (isMobileDevice && mainTooltipOpen) {
|
|
104
|
+
const timeout = setTimeout(() => setMainTooltipOpen(false), 3000);
|
|
105
|
+
return () => clearTimeout(timeout);
|
|
106
|
+
}
|
|
107
|
+
}, [mainTooltipOpen, isMobileDevice]);
|
|
108
|
+
if (jackpot.status === 'DISABLED' && jackpot.drawing !== true) {
|
|
109
|
+
return null;
|
|
110
|
+
}
|
|
111
|
+
return (_jsxs("div", { className: "w-full shrink-0", children: [_jsxs("div", { ref: ref, className: twMerge('relative flex w-full shrink-0 rounded-t-2xl p-3 text-center lg:gap-4 lg:p-5', variation.background), children: [_jsxs("div", { className: "flex w-full flex-col gap-6 lg:flex-row lg:gap-0", children: [_jsxs("div", { className: "relative z-1 flex flex-1 flex-col", children: [[
|
|
112
|
+
[
|
|
113
|
+
styles['flicker-scale-fade-2'],
|
|
114
|
+
'absolute right-[38%] top-[2%] h-2 w-2 delay-75',
|
|
115
|
+
],
|
|
116
|
+
[
|
|
117
|
+
styles['flicker-scale-fade'],
|
|
118
|
+
'absolute right-[20%] top-[10%] h-3 w-3',
|
|
119
|
+
],
|
|
120
|
+
[
|
|
121
|
+
styles['flicker-scale-fade-2'],
|
|
122
|
+
'absolute right-[30%] top-[10%] h-5 w-5',
|
|
123
|
+
],
|
|
124
|
+
[
|
|
125
|
+
styles['flicker-scale-fade'],
|
|
126
|
+
'absolute right-[36%] top-[35%] h-3 w-3',
|
|
127
|
+
],
|
|
128
|
+
[
|
|
129
|
+
styles['flicker-scale-fade'],
|
|
130
|
+
'absolute right-[15%] top-[56%] h-3 w-3',
|
|
131
|
+
],
|
|
132
|
+
[
|
|
133
|
+
styles['flicker-scale-fade-2'],
|
|
134
|
+
'absolute right-[50%] top-[55%] h-4 w-4',
|
|
135
|
+
],
|
|
136
|
+
].map(([animationClass, positionClass], i) => (_jsx(Image, { src: star, alt: "star", draggable: "false", className: twMerge(animationClass, positionClass) }, i))), _jsx("div", { className: "flex h-full flex-col justify-between", children: _jsx("div", { className: "flex w-full justify-between", children: _jsx("div", { className: "flex w-full flex-col", children: _jsxs("div", { className: "relative flex w-full justify-between", children: [_jsxs("div", { children: [_jsx("div", { className: "mb-2 flex gap-1 font-medium", children: _jsxs("div", { className: twMerge('flex w-fit items-center justify-center gap-1 rounded-[10px] border border-[#82F0D0] px-[10px] py-1 text-[#82F0D0] text-xs lg:text-sm'), children: [_jsx("div", { className: twMerge('h-[6px] w-[6px] animate-color rounded-full', isPayingOut
|
|
137
|
+
? styles['pulse-error']
|
|
138
|
+
: styles['pulse-success']) }), _jsx("div", { className: twMerge('rounded text-[#CECFD2]'), children: isPayingOut ? 'Paying Out' : 'Accumulating' })] }) }), _jsx("div", { className: "mb-2 text-left font-semibold text-[18px] text-white lg:mb-0 lg:text-2xl", children: jackpot?.name }), _jsx("div", { className: `${variation.poolBg} ${variation.textColor} flex w-fit rounded-lg px-2 font-semibold text-[26px] lg:text-[36px]`, children: formatNumber(jackpotAmount, {
|
|
139
|
+
currency: localeInfo.currency.code,
|
|
140
|
+
minDecimalPlaces: 2,
|
|
141
|
+
maxDecimalPlaces: 2,
|
|
142
|
+
}) })] }), _jsx(Image, { width: 175, height: 175, src: treasureChest, alt: "treasure chest", className: twMerge('absolute top-[0px] right-[-3px] h-[124px] w-[124px] md:top-0 lg:top-[-30px] lg:h-[175px] lg:w-[175px]'), priority: false, loading: "lazy" })] }) }) }) }), _jsxs("div", { className: "mt-3 lg:mt-4", children: [_jsxs("div", { className: "mb-1 flex justify-between", children: [_jsx("div", { className: "font-semibold text-text-primary-900 text-xs", "aria-live": "polite", children: formatNumber(0, {
|
|
143
|
+
currency: localeInfo.currency.code,
|
|
144
|
+
compact: true,
|
|
145
|
+
}) }), _jsxs("div", { className: "relative flex items-center justify-end gap-1.5", children: [isPayingOut ? (_jsx("div", { className: "flex w-6 items-center", children: [0, 1.5, 3].map((left, i) => (_jsx("div", { className: twMerge(`absolute left-${left}`, styles[`animate-arrow-red-flash-${i + 1}`]), children: _jsx(ChevronLeftIcon, { className: "size-4.5" }) }, i))) })) : (_jsx("div", { className: "flex w-6 items-center", children: [0, 1.5, 3].map((left, i) => (_jsx("div", { className: twMerge(`absolute left-${left}`, styles[`animate-arrow-green-flash-${i + 1}`]), children: _jsx(ChevronRightIcon, { className: "size-4.5" }) }, i))) })), _jsx("div", { className: "font-semibold text-text-primary-900 text-xs", children: formatNumber(jackpot?.maximumJackpotPoolLimit, {
|
|
146
|
+
currency: localeInfo.currency.code,
|
|
147
|
+
compact: true,
|
|
148
|
+
}) })] })] }), _jsx(Progress.Root, { className: "h-2 w-full rounded-full bg-bg-primary lg:h-4", max: 100, value: getPercentage(jackpot.pool, jackpot.maximumJackpotPoolLimit), "aria-valuenow": getPercentage(jackpot.pool, jackpot.maximumJackpotPoolLimit), "aria-valuemax": 100, "aria-label": "Jackpot progress", children: _jsx(Progress.Track, { className: twMerge('h-full overflow-hidden rounded-full', variation.progressBg), children: _jsx(Progress.Range, { className: "relative h-full overflow-hidden rounded-full bg-brand-500 pl-1.5", children: _jsx("div", { className: "pointer-events-none absolute inset-0 flex items-center justify-start pl-1.5", "aria-hidden": "true", children: arrowImages }) }) }) }), _jsx("div", { className: "mt-2 h-2 text-left text-[#F5F5F6] text-xs lg:h-auto lg:text-sm", dangerouslySetInnerHTML: { __html: getInfoBlocks()[infoIndex] } }, infoIndex)] })] }), _jsx("div", { className: "flex items-start gap-5 text-white", children: jackpotPayouts.length ? (_jsxs("div", { className: "flex h-full w-full flex-row items-center justify-between gap-3 lg:w-[280px] lg:flex-col lg:justify-center", children: [_jsx("p", { className: "hidden font-bold text-lg lg:block", children: "Recent Payout \uD83C\uDF89" }), _jsxs("div", { children: [_jsx("p", { className: "mb-1 block font-bold text-[14px] lg:hidden lg:text-lg", children: "Recent Payout \uD83C\uDF89" }), _jsxs("p", { className: "block text-xs leading-[18px] tracking-wider lg:hidden", children: ["Massive payout unlocked! ", _jsx("br", {}), " Who's next? \uD83D\uDCB0"] })] }), _jsxs("div", { className: "flex items-center gap-2", children: [_jsxs("div", { className: `${variation.topPayoutImgBorderColor} relative flex h-[54px] w-[54px] items-center justify-center rounded-full object-contain p-[3.5px] lg:h-[74px] lg:w-[74px]`, children: [_jsx("div", { className: `flex h-full w-full items-center justify-center rounded-full ${variation.topPayoutImgBg}`, children: _jsx(User02Icon, { className: "h-[34px] w-auto lg:h-[44px]" }) }), _jsx("div", { className: `${variation.topPayoutImgBorderColor} absolute right-[-6px] bottom-[-5px] flex h-8 w-8 items-center justify-center rounded-full p-[2px] lg:right-0 lg:bottom-0`, children: _jsxs("div", { className: `flex h-full w-full items-center justify-center rounded-full font-bold text-[10px] ${variation.topPayoutImgBorderColor} ${variation.textColor} ${variation.multiplierBg} ${variation.multiplierColor}`, children: [jackpotPayouts[0].multiplier, "x"] }) })] }), _jsxs("div", { children: [_jsx("p", { className: "font-semibold text-2xl", children: maskName(jackpotPayouts[0].member.name) }), _jsx("p", { className: `${variation.poolBg} rounded-lg px-2 font-semibold text-[22px] ${variation.textColor}`, children: formatNumber(jackpotPayouts[0].amount, {
|
|
149
|
+
currency: localeInfo.currency.code,
|
|
150
|
+
minDecimalPlaces: 2,
|
|
151
|
+
maxDecimalPlaces: 2,
|
|
152
|
+
}) })] })] }), _jsxs("p", { className: "hidden text-center text-xs leading-[18px] tracking-wider lg:block", children: ["Massive payout unlocked! ", _jsx("br", {}), " Who's next? \uD83D\uDCB0"] })] })) : (_jsxs("div", { className: "flex h-full w-full flex-row-reverse items-center justify-between lg:w-[280px] lg:flex-col lg:justify-center", children: [_jsx(Image, { src: coins, alt: "coins", className: "ml-2" }), _jsxs("div", { children: [_jsx("p", { className: "mt-1 font-semibold text-lg leading-6", children: "No one has won big yet" }), _jsxs("p", { className: "mt-1 text-start text-[0.75rem] leading-[1.125rem] lg:text-center", children: ["You could be the first to win the ", _jsx("br", {}), " jackpot!"] })] })] })) })] }), isPayingOut ? (_jsx("div", { className: twMerge(styles['light-rays'], variation.raysColor, 'rounded-t-2xl [--light-rays-left:90%] [--light-rays-top:100px]') })) : (_jsx(Image, { width: 175, height: 175, src: treasureChestBg, alt: "treasure chest background", className: twMerge('absolute top-0 right-0 h-full w-[380px] object-cover opacity-50'), priority: false, loading: "lazy" }))] }), _jsxs("div", { className: "relative flex w-full flex-col items-center rounded-b-2xl bg-[#171b26] px-4", children: [_jsxs("div", { className: "flex w-full justify-between py-4", children: [_jsxs("button", { onClick: () => setSeeDetails((v) => !v), type: "button", className: "flex items-center gap-1 font-medium text-[#fff] text-sm", children: ["See details", ' ', seeDetails ? (_jsx(ChevronUpIcon, { className: "h-5" })) : (_jsx(ChevronDownIcon, { className: "h-5" }))] }), _jsx("button", { type: "button", className: "text-nowrap text-[#FFE5AF] text-sm underline underline-offset-4", children: "Jackpot Rules" })] }), seeDetails && (_jsxs("div", { className: "w-full", children: [_jsxs("div", { children: [_jsx("div", { className: "mt-[6px] flex justify-between text-[#CECFD2] text-lg", children: _jsxs("div", { className: "flex items-center gap-3 font-semibold", children: [_jsx(Image, { src: coin, alt: "coin", className: "h-6" }), "Recent Payouts"] }) }), _jsx("div", { className: "mt-[1.25rem] mb-[2rem] gap-[0.625rem]", children: _jsx("div", { className: "flex-1 overflow-x-auto rounded-lg border border-[#1F242F]", children: _jsxs("table", { className: "w-full min-w-[700px]", children: [_jsx("thead", { children: _jsx("tr", { className: "h-[44px] bg-[#0C111D] text-[#94969C] text-xs", children: [
|
|
153
|
+
'Player',
|
|
154
|
+
'Game Provider',
|
|
155
|
+
'Multiplier',
|
|
156
|
+
'Prize',
|
|
157
|
+
'Timestamp',
|
|
158
|
+
].map((label) => (_jsx("th", { className: "whitespace-nowrap border-[#1F242F] border-b px-6 py-2 text-left", children: label }, label))) }) }), _jsx("tbody", { children: jackpotPayouts.length
|
|
159
|
+
? jackpotPayouts
|
|
160
|
+
.filter((jp) => jp.id !== '5HMmGqAZDPqqeFHBmv')
|
|
161
|
+
.map((jp) => (_jsxs("tr", { className: "h-[44px] bg-[#0C111D] text-left text-[#94969C] text-sm", children: [_jsx("td", { className: "border-[#1F242F] border-b px-6 py-2", children: maskName(jp?.member?.name) }), _jsx("td", { className: "border-[#1F242F] border-b px-6 py-2", children: formatProviderName(jp?.game.provider ?? '-') }), _jsxs("td", { className: "border-[#1F242F] border-b px-6 py-2", children: [jp?.multiplier, "x"] }), _jsx("td", { className: "border-[#1F242F] border-b px-6 py-2 text-[#47CD89]", children: formatNumber(jp?.amount ?? 0, {
|
|
162
|
+
currency: localeInfo.currency.code,
|
|
163
|
+
minDecimalPlaces: 2,
|
|
164
|
+
maxDecimalPlaces: 2,
|
|
165
|
+
}) }), _jsx("td", { className: "border-[#1F242F] border-b px-6 py-2", children: format(new Date(jp.dateTimeCreated), 'dd MMM yyyy h:mm a') })] }, jp.id)))
|
|
166
|
+
: Array.from({ length: 5 }).map((_, i) => (_jsxs("tr", { className: "h-[44px] bg-[#0C111D] text-left text-[#94969C] text-sm", children: [_jsx("td", { className: "border-[#1F242F] border-b px-6 py-2", children: "-" }), _jsx("td", { className: "border-[#1F242F] border-b px-6 py-2", children: "-" }), _jsx("td", { className: "border-[#1F242F] border-b px-6 py-2", children: "-" }), _jsx("td", { className: "border-[#1F242F] border-b px-6 py-2", children: "-" }), _jsx("td", { className: "border-[#1F242F] border-b px-6 py-2", children: "-" })] }, i))) })] }) }) })] }), _jsx("div", { className: "w-full", children: Boolean(filteredGameProviders.length) && (_jsx(JackpotsListItemGameProviders, { gameProviders: filteredGameProviders, heading: _jsxs("div", { className: "flex items-center gap-3 font-semibold", children: [_jsx(Image, { src: treasureChest, alt: "treasure chest", className: "size-6" }), "Game Providers"] }) })) })] }))] })] }));
|
|
167
|
+
}
|
|
168
|
+
function formatProviderName(provider) {
|
|
169
|
+
return provider
|
|
170
|
+
.split('_')
|
|
171
|
+
.map((word) => word.charAt(0).toUpperCase() + word.slice(1).toLowerCase())
|
|
172
|
+
.join(' ');
|
|
173
|
+
}
|
|
@@ -1,11 +1,13 @@
|
|
|
1
1
|
import { type ImageProps } from 'next/image';
|
|
2
|
+
import { type ReactNode } from 'react';
|
|
2
3
|
import type { GameProviderData } from '../../../types';
|
|
3
4
|
interface JackpotGameProvider extends GameProviderData {
|
|
4
5
|
redirectUrl: string;
|
|
5
6
|
providedLogo?: ImageProps['src'];
|
|
6
7
|
}
|
|
7
8
|
export interface JackpotsListItemGameProvidersProps {
|
|
9
|
+
heading?: string | ReactNode;
|
|
8
10
|
gameProviders: JackpotGameProvider[];
|
|
9
11
|
}
|
|
10
|
-
export declare function JackpotsListItemGameProviders({ gameProviders, }: JackpotsListItemGameProvidersProps): import("react/jsx-runtime").JSX.Element;
|
|
12
|
+
export declare function JackpotsListItemGameProviders({ heading, gameProviders, }: JackpotsListItemGameProvidersProps): import("react/jsx-runtime").JSX.Element;
|
|
11
13
|
export {};
|
|
@@ -9,7 +9,7 @@ import { ArrowLeftIcon } from '../../../icons/ArrowLeftIcon.js';
|
|
|
9
9
|
import { ArrowRightIcon } from '../../../icons/ArrowRightIcon.js';
|
|
10
10
|
import { Button } from '../../../ui/Button/index.js';
|
|
11
11
|
import { useJackpotsListPropsContext } from './JackpotsListContext.js';
|
|
12
|
-
export function JackpotsListItemGameProviders({ gameProviders, }) {
|
|
12
|
+
export function JackpotsListItemGameProviders({ heading, gameProviders, }) {
|
|
13
13
|
const jackpotsProps = useJackpotsListPropsContext();
|
|
14
14
|
const classNames = isString(jackpotsProps.className)
|
|
15
15
|
? { root: jackpotsProps.className }
|
|
@@ -41,5 +41,5 @@ export function JackpotsListItemGameProviders({ gameProviders, }) {
|
|
|
41
41
|
emblaApi.on('select', onSelect);
|
|
42
42
|
emblaApi.on('reInit', onSelect);
|
|
43
43
|
}, [emblaApi, onSelect]);
|
|
44
|
-
return (_jsxs("div", { className: twMerge('p-4 pb-8', classNames.providerRoot), children: [_jsxs("div", { className: "flex items-center justify-between", children: [_jsx("div", { className: twMerge('font-semibold text-lg text-text-primary-900', classNames.providerHeading), children:
|
|
44
|
+
return (_jsxs("div", { className: twMerge('p-4 pb-8', classNames.providerRoot), children: [_jsxs("div", { className: "flex items-center justify-between", children: [_jsx("div", { className: twMerge('font-semibold text-lg text-text-primary-900', classNames.providerHeading), children: heading ?? 'Jackpot Game Providers' }), _jsxs("div", { className: "hidden lg:flex", children: [_jsx(Button, { disabled: !canScrollPrev, onClick: scrollPrev, variant: "outline", colorScheme: "gray", className: twMerge('rounded-r-none border-r-0', classNames.providerNavigationButton), "aria-label": "Previous", children: _jsx(ArrowLeftIcon, { className: "size-5" }) }), _jsxs(Button, { disabled: !canScrollNext, onClick: scrollNext, variant: "outline", colorScheme: "gray", className: twMerge('rounded-l-none', classNames.providerNavigationButton), "aria-label": "Next", children: [_jsx("span", { className: "sr-only", children: "Next" }), _jsx(ArrowRightIcon, { className: "size-5" })] })] })] }), _jsx("div", { className: "relative mt-3 overflow-hidden", ref: emblaRef, children: _jsx("div", { className: "flex gap-3.5", children: gameProviders.map((provider) => (_jsx(Link, { href: provider.redirectUrl, className: twMerge('min-w-27.5 rounded-md bg-brand-800 lg:bg-bg-primary-900', classNames.providerThumbnailRoot), children: _jsx(Image, { src: provider.providedLogo ?? provider.logo, alt: "provider", className: twMerge('size-full', classNames.providerThumbnailImage), width: 300, height: 150 }) }, provider.slug))) }) })] }));
|
|
45
45
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export declare const
|
|
1
|
+
export declare const CRAZYWIN_JACKPOTS_VARIATIONS: {
|
|
2
2
|
background: string;
|
|
3
3
|
progressBg: string;
|
|
4
4
|
textColor: string;
|
|
@@ -9,3 +9,16 @@ export declare const JACKPOTS_VARIATIONS: {
|
|
|
9
9
|
topPayoutImgBg: string;
|
|
10
10
|
raysColor: string;
|
|
11
11
|
}[];
|
|
12
|
+
export declare const HAPPYBINGO_JACKPOTS_VARIATIONS: {
|
|
13
|
+
background: string;
|
|
14
|
+
progressBg: string;
|
|
15
|
+
textColor: string;
|
|
16
|
+
poolBg: string;
|
|
17
|
+
multiplierColor: string;
|
|
18
|
+
multiplierBg: string;
|
|
19
|
+
topPayoutImgBorderColor: string;
|
|
20
|
+
topPayoutImgBg: string;
|
|
21
|
+
raysColor: string;
|
|
22
|
+
}[];
|
|
23
|
+
export declare function formatProviderName(provider: string): string;
|
|
24
|
+
export declare const maskName: (name: string) => string;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export const
|
|
1
|
+
export const CRAZYWIN_JACKPOTS_VARIATIONS = [
|
|
2
2
|
// Green
|
|
3
3
|
{
|
|
4
4
|
background: 'bg-[linear-gradient(241.67deg,#1A534C_1.19%,#051B29_100%)]',
|
|
@@ -36,3 +36,55 @@ export const JACKPOTS_VARIATIONS = [
|
|
|
36
36
|
raysColor: '[--color-jackpot-rays-primary:#c04e48] [--color-jackpot-rays-secondary:#8f2731]',
|
|
37
37
|
},
|
|
38
38
|
];
|
|
39
|
+
export const HAPPYBINGO_JACKPOTS_VARIATIONS = [
|
|
40
|
+
// Orange
|
|
41
|
+
{
|
|
42
|
+
background: 'bg-[linear-gradient(241.67deg,#FFD238_1.19%,#FF7D02_100%)]',
|
|
43
|
+
progressBg: 'bg-[#CA8504]',
|
|
44
|
+
textColor: 'text-[#713B12]',
|
|
45
|
+
poolBg: 'bg-[linear-gradient(180deg,#FFDE21_0%,#FFD012_47%,#FFBF00_100%)]',
|
|
46
|
+
multiplierColor: 'text-[#713B12]',
|
|
47
|
+
multiplierBg: 'bg-[linear-gradient(241.67deg,#FFD238_1.19%,#FF7D02_100%)]',
|
|
48
|
+
topPayoutImgBorderColor: 'bg-[linear-gradient(180deg,#FFDE21_28.33%,#FFBF00_57.84%,#FF9442_100%)]',
|
|
49
|
+
topPayoutImgBg: 'bg-[#FFD238]',
|
|
50
|
+
raysColor: '[--color-rays-primary:#f2ac25] [--color-rays-secondary:#febb2a]',
|
|
51
|
+
},
|
|
52
|
+
// Purple
|
|
53
|
+
{
|
|
54
|
+
background: 'bg-[linear-gradient(45deg,#4300B1_0%,#A531DC_100%)]',
|
|
55
|
+
progressBg: 'bg-[#B485FF]',
|
|
56
|
+
textColor: 'text-[#fff]',
|
|
57
|
+
poolBg: 'bg-[linear-gradient(180deg,#9E77ED_0%,#8057D9_100%)]',
|
|
58
|
+
multiplierBg: 'bg-[linear-gradient(45deg,_#4300B1_0%,_#A531DC_100%)]',
|
|
59
|
+
multiplierColor: 'text-[#fff]',
|
|
60
|
+
topPayoutImgBorderColor: 'bg-[linear-gradient(180deg,#9E77ED_0%,#8057D9_100%)]',
|
|
61
|
+
topPayoutImgBg: 'bg-[#5E0DBD]',
|
|
62
|
+
raysColor: '[--color-rays-primary:#8222c6] [--color-rays-secondary:#8e24d2]',
|
|
63
|
+
},
|
|
64
|
+
// Blue
|
|
65
|
+
{
|
|
66
|
+
background: 'bg-[linear-gradient(241.67deg,#01C1FA_1.19%,#015EEA_100%)]',
|
|
67
|
+
progressBg: 'bg-[#01C4FB]',
|
|
68
|
+
textColor: 'text-[#344054]',
|
|
69
|
+
poolBg: 'bg-[linear-gradient(180deg,_#89F7FE_0%,_#66A6FF_100%)]',
|
|
70
|
+
multiplierBg: 'bg-[linear-gradient(241.67deg,_#01C1FA_1.19%,_#015EEA_100%)]',
|
|
71
|
+
multiplierColor: 'text-[#fff]',
|
|
72
|
+
topPayoutImgBorderColor: 'bg-[linear-gradient(180deg,_#89F7FE_0%,_#66A6FF_100%)]',
|
|
73
|
+
topPayoutImgBg: 'bg-[#01C1FA]',
|
|
74
|
+
raysColor: '[--color-rays-primary:#17a6f6] [--color-rays-secondary:#159ce9]',
|
|
75
|
+
},
|
|
76
|
+
];
|
|
77
|
+
export function formatProviderName(provider) {
|
|
78
|
+
return provider
|
|
79
|
+
.split('_')
|
|
80
|
+
.map((word) => word.charAt(0).toUpperCase() + word.slice(1).toLowerCase())
|
|
81
|
+
.join(' ');
|
|
82
|
+
}
|
|
83
|
+
export const maskName = (name) => {
|
|
84
|
+
if (name.length <= 7) {
|
|
85
|
+
return '*'.repeat(name.length);
|
|
86
|
+
}
|
|
87
|
+
const visiblePart = name.slice(0, 3);
|
|
88
|
+
const maskedPart = '*'.repeat(7);
|
|
89
|
+
return visiblePart + maskedPart;
|
|
90
|
+
};
|
|
@@ -33,9 +33,10 @@ export const MobileNumberField = ({ enabledCountries, mobileNumber, onMobileNumb
|
|
|
33
33
|
setSearch('');
|
|
34
34
|
}, children: [_jsx(Popover.Trigger, { onClick: () => {
|
|
35
35
|
setIsPopoverOpen(!isPopoverOpen);
|
|
36
|
-
}, className: "rounded-md border border-border-primary bg-background bg-bg-primary px-3 py-2 shadow-xs transition-colors placeholder:text-text-placeholder hover:border-border-hover focus:border-border-brand focus:border-border-focus focus:shadow-brand-xs focus:outline-none", children: _jsxs("div", { className: "flex items-center gap-2", children: [_jsx(selectedCountry.flag, { className: "size-5" }), _jsx("span", { children: selectedCountry.areaCode }), _jsx(Popover.Indicator, { children: _jsx(ChevronDownIcon, {}) })] }) }), _jsx(Popover.Positioner, { className: "w-full", children: _jsx(Popover.Content, { children: _jsx(Popover.Description, { children:
|
|
36
|
+
}, className: "rounded-md border border-border-primary bg-background bg-bg-primary px-3 py-2 shadow-xs transition-colors placeholder:text-text-placeholder hover:border-border-hover focus:border-border-brand focus:border-border-focus focus:shadow-brand-xs focus:outline-none", children: _jsxs("div", { className: "flex items-center gap-2", children: [_jsx(selectedCountry.flag, { className: "size-5" }), _jsx("span", { children: selectedCountry.areaCode }), _jsx(Popover.Indicator, { children: _jsx(ChevronDownIcon, {}) })] }) }), _jsx(Popover.Positioner, { className: "w-full", children: _jsx(Popover.Content, { children: _jsx(Popover.Description, { children: _jsxs(Combobox.Root, { collection: countriesCollection, positioning: {
|
|
37
37
|
sameWidth: true,
|
|
38
38
|
}, value: [selectedCountry.code], onValueChange: (details) => {
|
|
39
|
+
console.log('onValueChange?');
|
|
39
40
|
if (details.value && details.value.length > 0) {
|
|
40
41
|
setSelectedCountry(getCountryDetails(details.value[0]));
|
|
41
42
|
setAreaCode(getCountryDetails(details.value[0]).areaCode);
|
|
@@ -43,11 +44,11 @@ export const MobileNumberField = ({ enabledCountries, mobileNumber, onMobileNumb
|
|
|
43
44
|
setIsPopoverOpen(false);
|
|
44
45
|
}
|
|
45
46
|
}, inputValue: search, onInputValueChange: (details) => {
|
|
47
|
+
console.log('onInputValueChange?');
|
|
46
48
|
setSearch(details.inputValue);
|
|
47
49
|
}, open: isPopoverOpen, onOpenChange: (details) => {
|
|
48
|
-
|
|
50
|
+
console.log('onOpenChange?');
|
|
49
51
|
if (isPopoverOpen && !details.open) {
|
|
50
|
-
// Don't let combobox close itself
|
|
51
52
|
return;
|
|
52
53
|
}
|
|
53
54
|
}, openOnClick: true, children: [_jsx(Combobox.Control, { className: "rounded-lg border-1 shadow-none outline-none", children: _jsx(Combobox.Input, { placeholder: "Search country..." }) }), _jsx(Portal, { children: _jsx(Combobox.Positioner, { style: { zIndex: 9999 }, children: _jsx(Combobox.Content, { className: "w-full", style: { zIndex: 9999 }, children: _jsx(Combobox.ItemGroup, { children: countriesCollection.items
|
|
@@ -56,7 +57,7 @@ export const MobileNumberField = ({ enabledCountries, mobileNumber, onMobileNumb
|
|
|
56
57
|
.toLowerCase()
|
|
57
58
|
.includes(search.toLowerCase()) ||
|
|
58
59
|
country.areaCode.includes(search))
|
|
59
|
-
.map((country) => (_jsxs(Combobox.Item, { item: country, children: [_jsxs(Combobox.ItemText, { children: [_jsx(country.flag, { className: "mr-2 inline-block size-5" }), country.name, " (", country.areaCode, ")"] }), _jsx(Combobox.ItemIndicator, { asChild: true, children: _jsx(CheckIcon, {}) })] }, country.code))) }) }) }) })] })
|
|
60
|
+
.map((country) => (_jsxs(Combobox.Item, { item: country, children: [_jsxs(Combobox.ItemText, { children: [_jsx(country.flag, { className: "mr-2 inline-block size-5" }), country.name, " (", country.areaCode, ")"] }), _jsx(Combobox.ItemIndicator, { asChild: true, children: _jsx(CheckIcon, {}) })] }, country.code))) }) }) }) })] }) }) }) })] }), _jsx(Field.Input, { ...(mobileNumberRegistration || {}), style: { paddingLeft: '0.5rem' }, value: mobileNumber, onChange: handleMobileChange, placeholder: "Enter mobile number" })] }), _jsx(Field.ErrorText, { children: error })] }));
|
|
60
61
|
};
|
|
61
62
|
const countriesListCollection = (countries) => createListCollection({
|
|
62
63
|
items: countries,
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
export function User02Icon(props) {
|
|
3
|
+
return (_jsx("svg", { width: "24", height: "24", viewBox: "0 0 24 24", fill: "none", xmlns: "http://www.w3.org/2000/svg", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round", ...props, children: _jsx("path", { d: "M20 21C20 19.6044 20 18.9067 19.8278 18.3389C19.44 17.0605 18.4395 16.06 17.1611 15.6722C16.5933 15.5 15.8956 15.5 14.5 15.5H9.5C8.10444 15.5 7.40665 15.5 6.83886 15.6722C5.56045 16.06 4.56004 17.0605 4.17224 18.3389C4 18.9067 4 19.6044 4 21M16.5 7.5C16.5 9.98528 14.4853 12 12 12C9.51472 12 7.5 9.98528 7.5 7.5C7.5 5.01472 9.51472 3 12 3C14.4853 3 16.5 5.01472 16.5 7.5Z" }) }));
|
|
4
|
+
}
|
|
Binary file
|