@opexa/portal-components 0.0.25 → 0.0.27
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/client/hooks/index.d.ts +1 -0
- package/dist/client/hooks/useGlobalStore.d.ts +5 -4
- package/dist/client/hooks/useGlobalStore.js +1 -1
- package/dist/client/hooks/useGlobalStore.mjs +20 -9
- package/dist/client/hooks/useProfileCompletionQuery.d.ts +3 -0
- package/dist/client/hooks/useProfileCompletionQuery.js +1 -0
- package/dist/client/hooks/useProfileCompletionQuery.mjs +38 -0
- package/dist/client-hooks.js +1 -1
- package/dist/client-hooks.mjs +34 -32
- package/dist/components/Account/Account.d.ts +8 -0
- package/dist/components/Account/Account.js +1 -1
- package/dist/components/Account/Account.mjs +346 -201
- package/dist/components/Account/account.recipe.js +1 -1
- package/dist/components/Account/account.recipe.mjs +4 -4
- package/dist/components/AccountInfo/AccountInfo.d.ts +4 -0
- package/dist/components/AccountInfo/AccountInfo.js +1 -0
- package/dist/components/AccountInfo/AccountInfo.mjs +148 -0
- package/dist/components/AccountInfo/index.d.ts +1 -0
- package/dist/components/AccountPaymentMethods/AccountPaymentMethods.d.ts +1 -0
- package/dist/components/AccountPaymentMethods/AccountPaymentMethods.js +1 -0
- package/dist/components/AccountPaymentMethods/AccountPaymentMethods.mjs +6 -0
- package/dist/components/AccountPaymentMethods/index.d.ts +1 -0
- package/dist/components/AccountSecurity/AccountSecurity.d.ts +4 -0
- package/dist/components/AccountSecurity/AccountSecurity.js +1 -0
- package/dist/components/AccountSecurity/AccountSecurity.mjs +159 -0
- package/dist/components/AccountSecurity/index.d.ts +1 -0
- package/dist/components/AccountVerification/AccountVerification.d.ts +1 -0
- package/dist/components/AccountVerification/AccountVerification.js +1 -0
- package/dist/components/AccountVerification/AccountVerification.mjs +6 -0
- package/dist/components/AccountVerification/index.d.ts +1 -0
- package/dist/components/JackpotCounter/JackpotCounterItem.js +1 -1
- package/dist/components/JackpotCounter/JackpotCounterItem.mjs +36 -36
- package/dist/components/Jackpots/JackpotGameProviders.d.ts +5 -1
- package/dist/components/Jackpots/JackpotGameProviders.js +1 -1
- package/dist/components/Jackpots/JackpotGameProviders.mjs +33 -31
- package/dist/components/Jackpots/JackpotItemDesktop.d.ts +9 -0
- package/dist/components/Jackpots/JackpotItemDesktop.js +1 -0
- package/dist/components/Jackpots/{JackpotItem.mjs → JackpotItemDesktop.mjs} +121 -173
- package/dist/components/Jackpots/JackpotItemMobile.d.ts +3 -1
- package/dist/components/Jackpots/JackpotItemMobile.js +1 -1
- package/dist/components/Jackpots/JackpotItemMobile.mjs +133 -180
- package/dist/components/Jackpots/Jackpots.d.ts +2 -0
- package/dist/components/Jackpots/Jackpots.js +1 -1
- package/dist/components/Jackpots/Jackpots.mjs +15 -13
- package/dist/components/Jackpots/useJackpotItemData.d.ts +21 -0
- package/dist/components/Jackpots/useJackpotItemData.js +1 -0
- package/dist/components/Jackpots/useJackpotItemData.mjs +100 -0
- package/dist/components/index.d.ts +4 -0
- package/dist/components.js +1 -1
- package/dist/components.mjs +74 -66
- package/dist/icons/CheckVerified02Icon.d.ts +2 -0
- package/dist/icons/CheckVerified02Icon.js +1 -0
- package/dist/icons/CheckVerified02Icon.mjs +22 -0
- package/dist/icons/CreditCard02Icon.d.ts +2 -0
- package/dist/icons/CreditCard02Icon.js +1 -0
- package/dist/icons/CreditCard02Icon.mjs +22 -0
- package/dist/icons/FileCheck02Icon.d.ts +2 -0
- package/dist/icons/FileCheck02Icon.js +1 -0
- package/dist/icons/FileCheck02Icon.mjs +22 -0
- package/dist/icons/Lock01Icon.d.ts +2 -0
- package/dist/icons/Lock01Icon.js +1 -0
- package/dist/icons/Lock01Icon.mjs +22 -0
- package/dist/icons/index.d.ts +4 -0
- package/dist/icons.js +1 -1
- package/dist/icons.mjs +92 -84
- package/dist/server/utils/index.d.ts +1 -0
- package/dist/server/utils/prefetchProfileCompletionQuery.d.ts +1 -0
- package/dist/server/utils/prefetchProfileCompletionQuery.js +1 -0
- package/dist/server/utils/prefetchProfileCompletionQuery.mjs +26 -0
- package/dist/server-utils.js +1 -1
- package/dist/server-utils.mjs +28 -26
- package/dist/theme.css +49 -0
- package/dist/ui/Checkbox/checkbox.recipe.js +1 -1
- package/dist/ui/Checkbox/checkbox.recipe.mjs +3 -3
- package/dist/ui/Clipboard/clipboard.recipe.js +1 -1
- package/dist/ui/Clipboard/clipboard.recipe.mjs +8 -8
- package/dist/ui/Field/field.recipe.js +1 -1
- package/dist/ui/Field/field.recipe.mjs +4 -2
- package/dist/ui/IconButton/iconButton.recipe.d.ts +1 -0
- package/dist/ui/IconButton/iconButton.recipe.js +1 -1
- package/dist/ui/IconButton/iconButton.recipe.mjs +1 -0
- package/dist/ui/NumberInput/numberInput.recipe.js +1 -1
- package/dist/ui/NumberInput/numberInput.recipe.mjs +3 -3
- package/dist/ui/PasswordInput/passwordInput.recipe.js +1 -1
- package/dist/ui/PasswordInput/passwordInput.recipe.mjs +3 -3
- package/dist/ui/PinInput/pinInput.recipe.js +1 -1
- package/dist/ui/PinInput/pinInput.recipe.mjs +1 -1
- package/dist/ui/Select/select.recipe.js +1 -1
- package/dist/ui/Select/select.recipe.mjs +3 -3
- package/dist/utils/queryKeys.d.ts +1 -0
- package/dist/utils/queryKeys.js +1 -1
- package/dist/utils/queryKeys.mjs +71 -68
- package/dist/utils.js +1 -1
- package/dist/utils.mjs +20 -19
- package/package.json +2 -2
- package/dist/components/Jackpots/JackpotItem.d.ts +0 -7
- package/dist/components/Jackpots/JackpotItem.js +0 -1
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { jsxs as
|
|
3
|
-
import { Portal as
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import { useShallow as
|
|
7
|
-
import { useAccountQuery as
|
|
2
|
+
import { jsxs as o, Fragment as k, jsx as e } from "react/jsx-runtime";
|
|
3
|
+
import { Portal as g } from "@ark-ui/react";
|
|
4
|
+
import h from "next/image";
|
|
5
|
+
import l from "next/link";
|
|
6
|
+
import { useShallow as m } from "zustand/shallow";
|
|
7
|
+
import { useAccountQuery as L } from "../../client/hooks/useAccountQuery.mjs";
|
|
8
8
|
import "@tanstack/react-query";
|
|
9
9
|
import "../../utils/capitalize.mjs";
|
|
10
10
|
import { formatNumber as p } from "../../utils/formatNumber.mjs";
|
|
@@ -19,201 +19,121 @@ import "tiny-invariant";
|
|
|
19
19
|
import "react";
|
|
20
20
|
import "lodash-es";
|
|
21
21
|
import "@opexa/portal-sdk-core/object-id";
|
|
22
|
-
import { useGlobalStore as
|
|
22
|
+
import { useGlobalStore as d } from "../../client/hooks/useGlobalStore.mjs";
|
|
23
23
|
import "../../client/hooks/useInfiniteQueryHelper.mjs";
|
|
24
|
-
import { useLocaleInfo as
|
|
24
|
+
import { useLocaleInfo as w } from "../../client/hooks/useLocaleInfo.mjs";
|
|
25
25
|
import "usehooks-ts";
|
|
26
26
|
import { useSignOutMutation as R } from "../../client/hooks/useSignOutMutation.mjs";
|
|
27
|
-
import { useUnreadMessagesCountQuery as
|
|
28
|
-
import { useWalletQuery as
|
|
29
|
-
import { AlertCircleIcon as
|
|
30
|
-
import {
|
|
31
|
-
import {
|
|
27
|
+
import { useUnreadMessagesCountQuery as P } from "../../client/hooks/useUnreadMessagesCountQuery.mjs";
|
|
28
|
+
import { useWalletQuery as M } from "../../client/hooks/useWalletQuery.mjs";
|
|
29
|
+
import { AlertCircleIcon as z } from "../../icons/AlertCircleIcon.mjs";
|
|
30
|
+
import { ChevronLeftIcon as B } from "../../icons/ChevronLeftIcon.mjs";
|
|
31
|
+
import { ChevronRightIcon as r } from "../../icons/ChevronRightIcon.mjs";
|
|
32
|
+
import { CoinsStacked02Icon as W } from "../../icons/CoinsStacked02Icon.mjs";
|
|
32
33
|
import { CoinsSwap02Icon as T } from "../../icons/CoinsSwap02Icon.mjs";
|
|
33
|
-
import {
|
|
34
|
-
import {
|
|
35
|
-
import {
|
|
36
|
-
import {
|
|
37
|
-
import
|
|
34
|
+
import { CreditCard02Icon as A } from "../../icons/CreditCard02Icon.mjs";
|
|
35
|
+
import { FileCheck02Icon as D } from "../../icons/FileCheck02Icon.mjs";
|
|
36
|
+
import { Gift01Icon as Q } from "../../icons/Gift01Icon.mjs";
|
|
37
|
+
import { Lock01Icon as V } from "../../icons/Lock01Icon.mjs";
|
|
38
|
+
import { Logout01Icon as y } from "../../icons/Logout01Icon.mjs";
|
|
39
|
+
import { Settings02Icon as $ } from "../../icons/Settings02Icon.mjs";
|
|
40
|
+
import { User01Icon as E } from "../../icons/User01Icon.mjs";
|
|
41
|
+
import { XIcon as j } from "../../icons/XIcon.mjs";
|
|
42
|
+
import f from "../../images/placeholder-avatar.png.mjs";
|
|
38
43
|
import "../../ui/AlertDialog/AlertDialog.mjs";
|
|
39
44
|
import "../../ui/Avatar/Avatar.mjs";
|
|
40
|
-
import { Root as
|
|
41
|
-
import { Button as
|
|
45
|
+
import { Root as F, Indicator as G, Label as H } from "../../ui/Badge/Badge.mjs";
|
|
46
|
+
import { Button as x } from "../../ui/Button/Button.mjs";
|
|
42
47
|
import "../../ui/Checkbox/Checkbox.mjs";
|
|
43
48
|
import "../../ui/Clipboard/Clipboard.mjs";
|
|
44
49
|
import "../../ui/Collapsible/Collapsible.mjs";
|
|
45
50
|
import "../../ui/Combobox/Combobox.mjs";
|
|
46
51
|
import "../../ui/DatePicker/DatePicker.mjs";
|
|
47
52
|
import "../../ui/Dialog/Dialog.mjs";
|
|
48
|
-
import { Root as
|
|
53
|
+
import { Root as X, Trigger as q, Positioner as J, Content as K } from "../../ui/Drawer/Drawer.mjs";
|
|
49
54
|
import "../../ui/Field/Field.mjs";
|
|
50
|
-
import { IconButton as
|
|
55
|
+
import { IconButton as I } from "../../ui/IconButton/IconButton.mjs";
|
|
51
56
|
import "../../ui/NumberInput/NumberInput.mjs";
|
|
52
57
|
import "../../ui/PasswordInput/PasswordInput.mjs";
|
|
53
58
|
import "../../ui/PinInput/PinInput.mjs";
|
|
54
|
-
import { Root as
|
|
55
|
-
import "
|
|
59
|
+
import { Root as Y, Trigger as Z, Positioner as ee, Content as te } from "../../ui/Popover/Popover.mjs";
|
|
60
|
+
import { Presence as ae } from "../../ui/Presence.mjs";
|
|
56
61
|
import "../../ui/Progress/Progress.mjs";
|
|
62
|
+
import "tailwind-merge";
|
|
57
63
|
import "../../ui/SegmentGroup/SegmentGroup.mjs";
|
|
58
64
|
import "../../ui/Select/Select.mjs";
|
|
59
65
|
import "../../ui/Table/Table.mjs";
|
|
60
66
|
import "../../ui/Tabs/Tabs.mjs";
|
|
61
|
-
import { accountRecipe as
|
|
62
|
-
const
|
|
63
|
-
function
|
|
64
|
-
const
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
67
|
+
import { accountRecipe as ne } from "./account.recipe.mjs";
|
|
68
|
+
const t = ne();
|
|
69
|
+
function It(n) {
|
|
70
|
+
const a = d(
|
|
71
|
+
m((c) => ({
|
|
72
|
+
account: c.account,
|
|
73
|
+
account__mobile: c.account__mobile,
|
|
74
|
+
accountSettings: c.accountSettings
|
|
69
75
|
}))
|
|
70
|
-
)
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
/* @__PURE__ */ a("ul", { children: [
|
|
75
|
-
/* @__PURE__ */ e("li", { className: r.navItemRoot(), children: /* @__PURE__ */ a(
|
|
76
|
-
"button",
|
|
77
|
-
{
|
|
78
|
-
type: "button",
|
|
79
|
-
className: r.navItemLink(),
|
|
80
|
-
onClick: () => {
|
|
81
|
-
t.profile.setOpen(!1), t.mobileProfile.setOpen(!1), t.messages.setOpen(!0);
|
|
82
|
-
},
|
|
83
|
-
children: [
|
|
84
|
-
/* @__PURE__ */ e(v, { className: r.navItemIcon() }),
|
|
85
|
-
/* @__PURE__ */ e("span", { className: r.navItemLabel(), children: "Notifications" }),
|
|
86
|
-
/* @__PURE__ */ e("span", { className: r.navItemBadge(), "data-type": "warning", children: m.data ?? 0 }),
|
|
87
|
-
/* @__PURE__ */ e(l, { className: r.navItemIndicator() })
|
|
88
|
-
]
|
|
89
|
-
}
|
|
90
|
-
) }),
|
|
91
|
-
/* @__PURE__ */ e("li", { className: r.navItemRoot(), children: /* @__PURE__ */ a(
|
|
92
|
-
d,
|
|
93
|
-
{
|
|
94
|
-
href: i.rewardsUrl ?? "/rewards",
|
|
95
|
-
className: r.navItemLink(),
|
|
96
|
-
onClick: () => {
|
|
97
|
-
t.profile.setOpen(!1), t.mobileProfile.setOpen(!1);
|
|
98
|
-
},
|
|
99
|
-
children: [
|
|
100
|
-
/* @__PURE__ */ e(D, { className: r.navItemIcon() }),
|
|
101
|
-
/* @__PURE__ */ e("span", { className: r.navItemLabel(), children: "Rewards" }),
|
|
102
|
-
/* @__PURE__ */ e("span", { className: r.navItemBadge(), "data-type": "warning", children: "0" }),
|
|
103
|
-
/* @__PURE__ */ e(l, { className: r.navItemIndicator() })
|
|
104
|
-
]
|
|
105
|
-
}
|
|
106
|
-
) })
|
|
107
|
-
] }),
|
|
108
|
-
/* @__PURE__ */ e("ul", { children: /* @__PURE__ */ e("li", { className: r.navItemRoot(), children: /* @__PURE__ */ a(
|
|
109
|
-
"button",
|
|
76
|
+
);
|
|
77
|
+
return /* @__PURE__ */ o(k, { children: [
|
|
78
|
+
/* @__PURE__ */ o(
|
|
79
|
+
X,
|
|
110
80
|
{
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
t.profile.setOpen(!1), t.mobileProfile.setOpen(!1);
|
|
115
|
-
},
|
|
116
|
-
children: [
|
|
117
|
-
/* @__PURE__ */ e(Q, { className: r.navItemIcon() }),
|
|
118
|
-
/* @__PURE__ */ e("span", { className: r.navItemLabel(), children: "Settings" }),
|
|
119
|
-
/* @__PURE__ */ e("span", { className: r.navItemBadge(), "data-type": "error", children: /* @__PURE__ */ e(W, {}) }),
|
|
120
|
-
/* @__PURE__ */ e(l, { className: r.navItemIndicator() })
|
|
121
|
-
]
|
|
122
|
-
}
|
|
123
|
-
) }) }),
|
|
124
|
-
/* @__PURE__ */ a("ul", { children: [
|
|
125
|
-
/* @__PURE__ */ e("li", { className: r.navItemRoot(), children: /* @__PURE__ */ a(
|
|
126
|
-
d,
|
|
127
|
-
{
|
|
128
|
-
href: i.betRecordsUrl ?? "/bet-records",
|
|
129
|
-
className: r.navItemLink(),
|
|
130
|
-
onClick: () => {
|
|
131
|
-
t.profile.setOpen(!1), t.mobileProfile.setOpen(!1);
|
|
132
|
-
},
|
|
133
|
-
children: [
|
|
134
|
-
/* @__PURE__ */ e(z, { className: r.navItemIcon() }),
|
|
135
|
-
/* @__PURE__ */ e("span", { className: r.navItemLabel(), children: "Bet Records" }),
|
|
136
|
-
/* @__PURE__ */ e(l, { className: r.navItemIndicator() })
|
|
137
|
-
]
|
|
138
|
-
}
|
|
139
|
-
) }),
|
|
140
|
-
/* @__PURE__ */ e("li", { className: r.navItemRoot(), children: /* @__PURE__ */ a(
|
|
141
|
-
d,
|
|
142
|
-
{
|
|
143
|
-
href: i.transactionsUrl ?? "/transactions",
|
|
144
|
-
className: r.navItemLink(),
|
|
145
|
-
onClick: () => {
|
|
146
|
-
t.profile.setOpen(!1), t.mobileProfile.setOpen(!1);
|
|
147
|
-
},
|
|
148
|
-
children: [
|
|
149
|
-
/* @__PURE__ */ e(T, { className: r.navItemIcon() }),
|
|
150
|
-
/* @__PURE__ */ e("span", { className: r.navItemLabel(), children: "Transactions" }),
|
|
151
|
-
/* @__PURE__ */ e(l, { className: r.navItemIndicator() })
|
|
152
|
-
]
|
|
153
|
-
}
|
|
154
|
-
) })
|
|
155
|
-
] }),
|
|
156
|
-
/* @__PURE__ */ e("ul", { children: /* @__PURE__ */ e("li", { className: r.navItemRoot(), children: /* @__PURE__ */ a(
|
|
157
|
-
"button",
|
|
158
|
-
{
|
|
159
|
-
type: "button",
|
|
160
|
-
className: r.navItemLink(),
|
|
161
|
-
disabled: o.isPending,
|
|
162
|
-
onClick: () => {
|
|
163
|
-
o.mutate(), t.profile.setOpen(!1), t.mobileProfile.setOpen(!1);
|
|
164
|
-
},
|
|
165
|
-
children: [
|
|
166
|
-
/* @__PURE__ */ e(v, { className: r.navItemIcon() }),
|
|
167
|
-
/* @__PURE__ */ e("span", { className: r.navItemLabel(), children: "Log Out" }),
|
|
168
|
-
/* @__PURE__ */ e(l, { className: r.navItemIndicator() })
|
|
169
|
-
]
|
|
170
|
-
}
|
|
171
|
-
) }) })
|
|
172
|
-
] });
|
|
173
|
-
return /* @__PURE__ */ a(C, { children: [
|
|
174
|
-
/* @__PURE__ */ a(
|
|
175
|
-
E,
|
|
176
|
-
{
|
|
177
|
-
open: t.mobileProfile.open,
|
|
178
|
-
onOpenChange: (n) => {
|
|
179
|
-
t.mobileProfile.setOpen(n.open);
|
|
81
|
+
open: a.account__mobile.open,
|
|
82
|
+
onOpenChange: (c) => {
|
|
83
|
+
a.account__mobile.setOpen(c.open), a.accountSettings.setCollapsed(!0);
|
|
180
84
|
},
|
|
181
85
|
lazyMount: !0,
|
|
182
86
|
unmountOnExit: !0,
|
|
183
87
|
children: [
|
|
184
|
-
/* @__PURE__ */ e(
|
|
185
|
-
|
|
88
|
+
/* @__PURE__ */ e(q, { asChild: !0, className: "lg:hidden", children: n.children ?? /* @__PURE__ */ e(I, { size: "sm", colorScheme: "gray", children: a.account__mobile.open ? /* @__PURE__ */ e(j, {}) : /* @__PURE__ */ e(
|
|
89
|
+
h,
|
|
186
90
|
{
|
|
187
|
-
src:
|
|
91
|
+
src: f,
|
|
188
92
|
alt: "",
|
|
189
93
|
width: 100,
|
|
190
94
|
height: 100,
|
|
191
95
|
className: "size-10"
|
|
192
96
|
}
|
|
193
97
|
) }) }),
|
|
194
|
-
/* @__PURE__ */ e(
|
|
195
|
-
|
|
98
|
+
/* @__PURE__ */ e(g, { children: /* @__PURE__ */ e(J, { children: /* @__PURE__ */ o(
|
|
99
|
+
K,
|
|
196
100
|
{
|
|
197
|
-
className: "top-[var(--top,0px)] flex h-[calc(100%-var(--top,0px))] w-full flex-col px-xl py-6",
|
|
101
|
+
className: "relative top-[var(--top,0px)] flex h-[calc(100%-var(--top,0px))] w-full flex-col px-xl py-6",
|
|
198
102
|
style: {
|
|
199
|
-
"--top":
|
|
103
|
+
"--top": n.offsetTop ?? "0px"
|
|
200
104
|
},
|
|
201
105
|
children: [
|
|
202
|
-
/* @__PURE__ */ e(
|
|
203
|
-
/* @__PURE__ */ e(
|
|
204
|
-
|
|
106
|
+
/* @__PURE__ */ e(S, {}),
|
|
107
|
+
/* @__PURE__ */ e(C, {}),
|
|
108
|
+
/* @__PURE__ */ e(
|
|
109
|
+
U,
|
|
110
|
+
{
|
|
111
|
+
rewardsUrl: n.rewardsUrl,
|
|
112
|
+
betRecordsUrl: n.betRecordsUrl,
|
|
113
|
+
transactionsUrl: n.transactionsUrl
|
|
114
|
+
}
|
|
115
|
+
),
|
|
116
|
+
/* @__PURE__ */ e(
|
|
117
|
+
_,
|
|
118
|
+
{
|
|
119
|
+
accountInfoUrl: n.accountInfoUrl,
|
|
120
|
+
accountSecurityUrl: n.accountSecurityUrl,
|
|
121
|
+
accountVerificationUrl: n.accountVerificationUrl,
|
|
122
|
+
accountPaymentMethodsUrl: n.accountPaymentMethodsUrl
|
|
123
|
+
}
|
|
124
|
+
)
|
|
205
125
|
]
|
|
206
126
|
}
|
|
207
127
|
) }) })
|
|
208
128
|
]
|
|
209
129
|
}
|
|
210
130
|
),
|
|
211
|
-
/* @__PURE__ */
|
|
212
|
-
|
|
131
|
+
/* @__PURE__ */ o(
|
|
132
|
+
Y,
|
|
213
133
|
{
|
|
214
|
-
open:
|
|
215
|
-
onOpenChange: (
|
|
216
|
-
|
|
134
|
+
open: a.account.open,
|
|
135
|
+
onOpenChange: (c) => {
|
|
136
|
+
a.account.setOpen(c.open), a.accountSettings.setCollapsed(!0);
|
|
217
137
|
},
|
|
218
138
|
lazyMount: !0,
|
|
219
139
|
unmountOnExit: !0,
|
|
@@ -222,107 +142,123 @@ function rt(i) {
|
|
|
222
142
|
strategy: "fixed"
|
|
223
143
|
},
|
|
224
144
|
children: [
|
|
225
|
-
/* @__PURE__ */ e(
|
|
226
|
-
|
|
145
|
+
/* @__PURE__ */ e(Z, { className: "hidden lg:flex", asChild: !0, children: n.children ?? /* @__PURE__ */ e(I, { size: "sm", colorScheme: "gray", children: /* @__PURE__ */ e(
|
|
146
|
+
h,
|
|
227
147
|
{
|
|
228
|
-
src:
|
|
148
|
+
src: f,
|
|
229
149
|
alt: "",
|
|
230
150
|
width: 48,
|
|
231
151
|
height: 48,
|
|
232
152
|
className: "size-10"
|
|
233
153
|
}
|
|
234
154
|
) }) }),
|
|
235
|
-
/* @__PURE__ */ e(
|
|
236
|
-
/* @__PURE__ */ e(
|
|
237
|
-
/* @__PURE__ */ e(
|
|
238
|
-
|
|
155
|
+
/* @__PURE__ */ e(g, { children: /* @__PURE__ */ e(ee, { children: /* @__PURE__ */ o(te, { className: "border-border-primary bg-bg-primary relative z-popover w-[23.438rem] overflow-hidden rounded-xl border p-xl ui-open:animate-fade-in ui-closed:animate-fade-out", children: [
|
|
156
|
+
/* @__PURE__ */ e(S, {}),
|
|
157
|
+
/* @__PURE__ */ e(C, {}),
|
|
158
|
+
/* @__PURE__ */ e(
|
|
159
|
+
U,
|
|
160
|
+
{
|
|
161
|
+
rewardsUrl: n.rewardsUrl,
|
|
162
|
+
betRecordsUrl: n.betRecordsUrl,
|
|
163
|
+
transactionsUrl: n.transactionsUrl
|
|
164
|
+
}
|
|
165
|
+
),
|
|
166
|
+
/* @__PURE__ */ e(
|
|
167
|
+
_,
|
|
168
|
+
{
|
|
169
|
+
accountInfoUrl: n.accountInfoUrl,
|
|
170
|
+
accountSecurityUrl: n.accountSecurityUrl,
|
|
171
|
+
accountVerificationUrl: n.accountVerificationUrl,
|
|
172
|
+
accountPaymentMethodsUrl: n.accountPaymentMethodsUrl
|
|
173
|
+
}
|
|
174
|
+
)
|
|
239
175
|
] }) }) })
|
|
240
176
|
]
|
|
241
177
|
}
|
|
242
178
|
)
|
|
243
179
|
] });
|
|
244
180
|
}
|
|
245
|
-
function
|
|
246
|
-
const
|
|
247
|
-
return /* @__PURE__ */
|
|
181
|
+
function S() {
|
|
182
|
+
const a = L().data;
|
|
183
|
+
return /* @__PURE__ */ o("div", { className: "flex shrink-0 items-center gap-lg", children: [
|
|
248
184
|
/* @__PURE__ */ e(
|
|
249
|
-
|
|
185
|
+
h,
|
|
250
186
|
{
|
|
251
|
-
src:
|
|
187
|
+
src: f,
|
|
252
188
|
alt: "",
|
|
253
189
|
width: 48,
|
|
254
190
|
height: 48,
|
|
255
191
|
className: "size-12"
|
|
256
192
|
}
|
|
257
193
|
),
|
|
258
|
-
/* @__PURE__ */
|
|
259
|
-
/* @__PURE__ */ e("p", { className: "text-text-secondary-700 font-semibold leading-tight", children:
|
|
260
|
-
/* @__PURE__ */ e("p", { className: "text-text-tertiary-600 leading-tight", children: (
|
|
194
|
+
/* @__PURE__ */ o("div", { className: "grow", children: [
|
|
195
|
+
/* @__PURE__ */ e("p", { className: "text-text-secondary-700 font-semibold leading-tight", children: a == null ? void 0 : a.name }),
|
|
196
|
+
/* @__PURE__ */ e("p", { className: "text-text-tertiary-600 leading-tight", children: (a == null ? void 0 : a.nickName) ?? (a == null ? void 0 : a.emailAddress) ?? (a == null ? void 0 : a.realName) })
|
|
261
197
|
] }),
|
|
262
|
-
/* @__PURE__ */
|
|
263
|
-
|
|
198
|
+
/* @__PURE__ */ o(
|
|
199
|
+
F,
|
|
264
200
|
{
|
|
265
|
-
colorScheme:
|
|
201
|
+
colorScheme: a != null && a.verified ? "success" : "danger",
|
|
266
202
|
className: "self-start",
|
|
267
203
|
children: [
|
|
268
|
-
/* @__PURE__ */ e(
|
|
269
|
-
/* @__PURE__ */ e(
|
|
204
|
+
/* @__PURE__ */ e(G, {}),
|
|
205
|
+
/* @__PURE__ */ e(H, { children: a != null && a.verified ? "Verified" : "Unverified" })
|
|
270
206
|
]
|
|
271
207
|
}
|
|
272
208
|
)
|
|
273
209
|
] });
|
|
274
210
|
}
|
|
275
|
-
function
|
|
276
|
-
var
|
|
277
|
-
const
|
|
211
|
+
function C() {
|
|
212
|
+
var v, N;
|
|
213
|
+
const n = w(), a = M({
|
|
278
214
|
refetchInterval: 1e3
|
|
279
|
-
}),
|
|
280
|
-
|
|
281
|
-
profile:
|
|
282
|
-
mobileProfile:
|
|
283
|
-
depositWithdrawal:
|
|
215
|
+
}), c = d(
|
|
216
|
+
m((u) => ({
|
|
217
|
+
profile: u.account,
|
|
218
|
+
mobileProfile: u.account__mobile,
|
|
219
|
+
depositWithdrawal: u.depositWithdrawal
|
|
284
220
|
}))
|
|
285
|
-
),
|
|
286
|
-
return /* @__PURE__ */
|
|
221
|
+
), s = b((v = a.data) == null ? void 0 : v.balance, 0), i = b((N = a.data) == null ? void 0 : N.bonus, 0), O = s + i;
|
|
222
|
+
return /* @__PURE__ */ o("div", { className: "border-border-primary bg-bg-tertiary mt-3 rounded-xl border p-xl", children: [
|
|
287
223
|
/* @__PURE__ */ e("div", { className: "text-text-secondary-700 text-sm", children: "Total Balance" }),
|
|
288
|
-
/* @__PURE__ */ e("div", { className: "text-3xl font-bold", children: p(
|
|
289
|
-
currency:
|
|
224
|
+
/* @__PURE__ */ e("div", { className: "text-3xl font-bold", children: p(O, {
|
|
225
|
+
currency: n == null ? void 0 : n.currency.code,
|
|
290
226
|
minDecimalPlaces: 2
|
|
291
227
|
}) }),
|
|
292
|
-
/* @__PURE__ */
|
|
293
|
-
/* @__PURE__ */
|
|
228
|
+
/* @__PURE__ */ o("div", { className: "mt-1.5 flex gap-7xl", children: [
|
|
229
|
+
/* @__PURE__ */ o("div", { children: [
|
|
294
230
|
/* @__PURE__ */ e("p", { className: "text-text-secondary-700 text-2xs", children: "Deposit Balance" }),
|
|
295
|
-
/* @__PURE__ */ e("p", { className: "text-medium text-text-primary-brand", children: p(
|
|
296
|
-
currency:
|
|
231
|
+
/* @__PURE__ */ e("p", { className: "text-medium text-text-primary-brand", children: p(s, {
|
|
232
|
+
currency: n == null ? void 0 : n.currency.code,
|
|
297
233
|
minDecimalPlaces: 2
|
|
298
234
|
}) })
|
|
299
235
|
] }),
|
|
300
|
-
/* @__PURE__ */
|
|
236
|
+
/* @__PURE__ */ o("div", { children: [
|
|
301
237
|
/* @__PURE__ */ e("p", { className: "text-text-secondary-700 text-2xs", children: "Bonus Balance" }),
|
|
302
|
-
/* @__PURE__ */ e("p", { className: "text-medium text-text-primary-brand", children: p(
|
|
303
|
-
currency:
|
|
238
|
+
/* @__PURE__ */ e("p", { className: "text-medium text-text-primary-brand", children: p(i, {
|
|
239
|
+
currency: n == null ? void 0 : n.currency.code,
|
|
304
240
|
minDecimalPlaces: 2
|
|
305
241
|
}) })
|
|
306
242
|
] })
|
|
307
243
|
] }),
|
|
308
|
-
/* @__PURE__ */
|
|
244
|
+
/* @__PURE__ */ o("div", { className: "mt-3 flex gap-lg", children: [
|
|
309
245
|
/* @__PURE__ */ e(
|
|
310
|
-
|
|
246
|
+
x,
|
|
311
247
|
{
|
|
312
248
|
size: "xs",
|
|
313
249
|
variant: "outline",
|
|
314
250
|
onClick: () => {
|
|
315
|
-
|
|
251
|
+
c.depositWithdrawal.setOpen(!0), c.depositWithdrawal.setTab("WITHDRAWAL"), c.profile.setOpen(!1), c.mobileProfile.setOpen(!1);
|
|
316
252
|
},
|
|
317
253
|
children: "Withdraw"
|
|
318
254
|
}
|
|
319
255
|
),
|
|
320
256
|
/* @__PURE__ */ e(
|
|
321
|
-
|
|
257
|
+
x,
|
|
322
258
|
{
|
|
323
259
|
size: "xs",
|
|
324
260
|
onClick: () => {
|
|
325
|
-
|
|
261
|
+
c.depositWithdrawal.setOpen(!0), c.depositWithdrawal.setTab("DEPOSIT"), c.profile.setOpen(!1), c.mobileProfile.setOpen(!1);
|
|
326
262
|
},
|
|
327
263
|
children: "Deposit"
|
|
328
264
|
}
|
|
@@ -330,6 +266,215 @@ function O() {
|
|
|
330
266
|
] })
|
|
331
267
|
] });
|
|
332
268
|
}
|
|
269
|
+
function U(n) {
|
|
270
|
+
const a = R(), c = d(
|
|
271
|
+
m((i) => ({
|
|
272
|
+
account: i.account,
|
|
273
|
+
account__mobile: i.account__mobile,
|
|
274
|
+
accountSettings: i.accountSettings,
|
|
275
|
+
messages: i.messages
|
|
276
|
+
}))
|
|
277
|
+
), s = P(
|
|
278
|
+
{},
|
|
279
|
+
{ refetchInterval: 5e3 }
|
|
280
|
+
);
|
|
281
|
+
return /* @__PURE__ */ o("nav", { className: t.nav({ className: "mt-xl" }), children: [
|
|
282
|
+
/* @__PURE__ */ o("ul", { children: [
|
|
283
|
+
/* @__PURE__ */ e("li", { className: t.navItemRoot(), children: /* @__PURE__ */ o(
|
|
284
|
+
"button",
|
|
285
|
+
{
|
|
286
|
+
type: "button",
|
|
287
|
+
className: t.navItemLink(),
|
|
288
|
+
onClick: () => {
|
|
289
|
+
c.account.setOpen(!1), c.account__mobile.setOpen(!1), c.messages.setOpen(!0);
|
|
290
|
+
},
|
|
291
|
+
children: [
|
|
292
|
+
/* @__PURE__ */ e(y, { className: t.navItemIcon() }),
|
|
293
|
+
/* @__PURE__ */ e("span", { className: t.navItemLabel(), children: "Notifications" }),
|
|
294
|
+
/* @__PURE__ */ e("span", { className: t.navItemBadge(), "data-type": "warning", children: s.data ?? 0 }),
|
|
295
|
+
/* @__PURE__ */ e(r, { className: t.navItemIndicator() })
|
|
296
|
+
]
|
|
297
|
+
}
|
|
298
|
+
) }),
|
|
299
|
+
/* @__PURE__ */ e("li", { className: t.navItemRoot(), children: /* @__PURE__ */ o(
|
|
300
|
+
l,
|
|
301
|
+
{
|
|
302
|
+
href: n.rewardsUrl ?? "/rewards",
|
|
303
|
+
className: t.navItemLink(),
|
|
304
|
+
onClick: () => {
|
|
305
|
+
c.account.setOpen(!1), c.account__mobile.setOpen(!1);
|
|
306
|
+
},
|
|
307
|
+
children: [
|
|
308
|
+
/* @__PURE__ */ e(Q, { className: t.navItemIcon() }),
|
|
309
|
+
/* @__PURE__ */ e("span", { className: t.navItemLabel(), children: "Rewards" }),
|
|
310
|
+
/* @__PURE__ */ e("span", { className: t.navItemBadge(), "data-type": "warning", children: "0" }),
|
|
311
|
+
/* @__PURE__ */ e(r, { className: t.navItemIndicator() })
|
|
312
|
+
]
|
|
313
|
+
}
|
|
314
|
+
) })
|
|
315
|
+
] }),
|
|
316
|
+
/* @__PURE__ */ e("ul", { children: /* @__PURE__ */ e("li", { className: t.navItemRoot(), children: /* @__PURE__ */ o(
|
|
317
|
+
"button",
|
|
318
|
+
{
|
|
319
|
+
type: "button",
|
|
320
|
+
className: t.navItemLink(),
|
|
321
|
+
onClick: () => {
|
|
322
|
+
c.accountSettings.setCollapsed(!1);
|
|
323
|
+
},
|
|
324
|
+
children: [
|
|
325
|
+
/* @__PURE__ */ e($, { className: t.navItemIcon() }),
|
|
326
|
+
/* @__PURE__ */ e("span", { className: t.navItemLabel(), children: "Settings" }),
|
|
327
|
+
/* @__PURE__ */ e("span", { className: t.navItemBadge(), "data-type": "error", children: /* @__PURE__ */ e(z, {}) }),
|
|
328
|
+
/* @__PURE__ */ e(r, { className: t.navItemIndicator() })
|
|
329
|
+
]
|
|
330
|
+
}
|
|
331
|
+
) }) }),
|
|
332
|
+
/* @__PURE__ */ o("ul", { children: [
|
|
333
|
+
/* @__PURE__ */ e("li", { className: t.navItemRoot(), children: /* @__PURE__ */ o(
|
|
334
|
+
l,
|
|
335
|
+
{
|
|
336
|
+
href: n.betRecordsUrl ?? "/bet-records",
|
|
337
|
+
className: t.navItemLink(),
|
|
338
|
+
onClick: () => {
|
|
339
|
+
c.account.setOpen(!1), c.account__mobile.setOpen(!1);
|
|
340
|
+
},
|
|
341
|
+
children: [
|
|
342
|
+
/* @__PURE__ */ e(W, { className: t.navItemIcon() }),
|
|
343
|
+
/* @__PURE__ */ e("span", { className: t.navItemLabel(), children: "Bet Records" }),
|
|
344
|
+
/* @__PURE__ */ e(r, { className: t.navItemIndicator() })
|
|
345
|
+
]
|
|
346
|
+
}
|
|
347
|
+
) }),
|
|
348
|
+
/* @__PURE__ */ e("li", { className: t.navItemRoot(), children: /* @__PURE__ */ o(
|
|
349
|
+
l,
|
|
350
|
+
{
|
|
351
|
+
href: n.transactionsUrl ?? "/transactions",
|
|
352
|
+
className: t.navItemLink(),
|
|
353
|
+
onClick: () => {
|
|
354
|
+
c.account.setOpen(!1), c.account__mobile.setOpen(!1);
|
|
355
|
+
},
|
|
356
|
+
children: [
|
|
357
|
+
/* @__PURE__ */ e(T, { className: t.navItemIcon() }),
|
|
358
|
+
/* @__PURE__ */ e("span", { className: t.navItemLabel(), children: "Transactions" }),
|
|
359
|
+
/* @__PURE__ */ e(r, { className: t.navItemIndicator() })
|
|
360
|
+
]
|
|
361
|
+
}
|
|
362
|
+
) })
|
|
363
|
+
] }),
|
|
364
|
+
/* @__PURE__ */ e("ul", { children: /* @__PURE__ */ e("li", { className: t.navItemRoot(), children: /* @__PURE__ */ o(
|
|
365
|
+
"button",
|
|
366
|
+
{
|
|
367
|
+
type: "button",
|
|
368
|
+
className: t.navItemLink(),
|
|
369
|
+
disabled: a.isPending,
|
|
370
|
+
onClick: () => {
|
|
371
|
+
a.mutate(), c.account.setOpen(!1), c.account__mobile.setOpen(!1);
|
|
372
|
+
},
|
|
373
|
+
children: [
|
|
374
|
+
/* @__PURE__ */ e(y, { className: t.navItemIcon() }),
|
|
375
|
+
/* @__PURE__ */ e("span", { className: t.navItemLabel(), children: "Log Out" }),
|
|
376
|
+
/* @__PURE__ */ e(r, { className: t.navItemIndicator() })
|
|
377
|
+
]
|
|
378
|
+
}
|
|
379
|
+
) }) })
|
|
380
|
+
] });
|
|
381
|
+
}
|
|
382
|
+
function _(n) {
|
|
383
|
+
const a = d(
|
|
384
|
+
m((c) => ({
|
|
385
|
+
account: c.account,
|
|
386
|
+
account__mobile: c.account__mobile,
|
|
387
|
+
accountSettings: c.accountSettings
|
|
388
|
+
}))
|
|
389
|
+
);
|
|
390
|
+
return /* @__PURE__ */ o(
|
|
391
|
+
ae,
|
|
392
|
+
{
|
|
393
|
+
present: !a.accountSettings.collapsed,
|
|
394
|
+
lazyMount: !0,
|
|
395
|
+
className: "bg-bg-primary ui-open:animate-slide-in-right ui-closed:animate-slide-out-right absolute left-0 top-0 size-full overflow-y-auto",
|
|
396
|
+
children: [
|
|
397
|
+
/* @__PURE__ */ o("div", { className: "bg-bg-primary-alt flex items-center gap-xl px-xl py-md", children: [
|
|
398
|
+
/* @__PURE__ */ e(
|
|
399
|
+
I,
|
|
400
|
+
{
|
|
401
|
+
size: "2xs",
|
|
402
|
+
variant: "outline",
|
|
403
|
+
colorScheme: "gray",
|
|
404
|
+
onClick: () => {
|
|
405
|
+
a.accountSettings.setCollapsed(!0);
|
|
406
|
+
},
|
|
407
|
+
children: /* @__PURE__ */ e(B, {})
|
|
408
|
+
}
|
|
409
|
+
),
|
|
410
|
+
/* @__PURE__ */ e("h2", { className: "text-text-primary-900 text-lg font-semibold", children: "Settings" })
|
|
411
|
+
] }),
|
|
412
|
+
/* @__PURE__ */ e("nav", { className: t.nav({ className: "p-4" }), children: /* @__PURE__ */ o("ul", { children: [
|
|
413
|
+
/* @__PURE__ */ e("li", { className: t.navItemRoot(), children: /* @__PURE__ */ o(
|
|
414
|
+
l,
|
|
415
|
+
{
|
|
416
|
+
href: n.accountInfoUrl ?? "/account",
|
|
417
|
+
className: t.navItemLink(),
|
|
418
|
+
onClick: () => {
|
|
419
|
+
a.account.setOpen(!1), a.account__mobile.setOpen(!1), a.accountSettings.setCollapsed(!0);
|
|
420
|
+
},
|
|
421
|
+
children: [
|
|
422
|
+
/* @__PURE__ */ e(E, { className: t.navItemIcon() }),
|
|
423
|
+
/* @__PURE__ */ e("span", { className: t.navItemLabel(), children: "Account Info" }),
|
|
424
|
+
/* @__PURE__ */ e(r, { className: t.navItemIndicator() })
|
|
425
|
+
]
|
|
426
|
+
}
|
|
427
|
+
) }),
|
|
428
|
+
/* @__PURE__ */ e("li", { className: t.navItemRoot(), children: /* @__PURE__ */ o(
|
|
429
|
+
l,
|
|
430
|
+
{
|
|
431
|
+
href: n.accountSecurityUrl ?? "/account/security",
|
|
432
|
+
className: t.navItemLink(),
|
|
433
|
+
onClick: () => {
|
|
434
|
+
a.account.setOpen(!1), a.account__mobile.setOpen(!1), a.accountSettings.setCollapsed(!0);
|
|
435
|
+
},
|
|
436
|
+
children: [
|
|
437
|
+
/* @__PURE__ */ e(V, { className: t.navItemIcon() }),
|
|
438
|
+
/* @__PURE__ */ e("span", { className: t.navItemLabel(), children: "Security" }),
|
|
439
|
+
/* @__PURE__ */ e(r, { className: t.navItemIndicator() })
|
|
440
|
+
]
|
|
441
|
+
}
|
|
442
|
+
) }),
|
|
443
|
+
/* @__PURE__ */ e("li", { className: t.navItemRoot(), children: /* @__PURE__ */ o(
|
|
444
|
+
l,
|
|
445
|
+
{
|
|
446
|
+
href: n.accountVerificationUrl ?? "/account/verification",
|
|
447
|
+
className: t.navItemLink(),
|
|
448
|
+
onClick: () => {
|
|
449
|
+
a.account.setOpen(!1), a.account__mobile.setOpen(!1), a.accountSettings.setCollapsed(!0);
|
|
450
|
+
},
|
|
451
|
+
children: [
|
|
452
|
+
/* @__PURE__ */ e(D, { className: t.navItemIcon() }),
|
|
453
|
+
/* @__PURE__ */ e("span", { className: t.navItemLabel(), children: "Personal Verification" }),
|
|
454
|
+
/* @__PURE__ */ e(r, { className: t.navItemIndicator() })
|
|
455
|
+
]
|
|
456
|
+
}
|
|
457
|
+
) }),
|
|
458
|
+
/* @__PURE__ */ e("li", { className: t.navItemRoot(), children: /* @__PURE__ */ o(
|
|
459
|
+
l,
|
|
460
|
+
{
|
|
461
|
+
href: n.accountPaymentMethodsUrl ?? "/account/payment-methods",
|
|
462
|
+
className: t.navItemLink(),
|
|
463
|
+
onClick: () => {
|
|
464
|
+
a.account.setOpen(!1), a.account__mobile.setOpen(!1), a.accountSettings.setCollapsed(!0);
|
|
465
|
+
},
|
|
466
|
+
children: [
|
|
467
|
+
/* @__PURE__ */ e(A, { className: t.navItemIcon() }),
|
|
468
|
+
/* @__PURE__ */ e("span", { className: t.navItemLabel(), children: "Payment Methods" }),
|
|
469
|
+
/* @__PURE__ */ e(r, { className: t.navItemIndicator() })
|
|
470
|
+
]
|
|
471
|
+
}
|
|
472
|
+
) })
|
|
473
|
+
] }) })
|
|
474
|
+
]
|
|
475
|
+
}
|
|
476
|
+
);
|
|
477
|
+
}
|
|
333
478
|
export {
|
|
334
|
-
|
|
479
|
+
It as Account
|
|
335
480
|
};
|