@agg-market/ui 6.0.0 → 8.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (89) hide show
  1. package/README.md +17 -2
  2. package/dist/{chunk-G6YKGVQR.mjs → chunk-JE4MV5RL.mjs} +18 -60
  3. package/dist/{chunk-2ICOSP7N.mjs → chunk-KRCRD4AJ.mjs} +11 -14
  4. package/dist/{chunk-5ZKPBMRK.mjs → chunk-SBLIHCN2.mjs} +21 -24
  5. package/dist/{chunk-LMOJKJOY.mjs → chunk-TLFRGJ5B.mjs} +334 -217
  6. package/dist/chunk-WKY3IN52.mjs +4907 -0
  7. package/dist/events.js +3364 -2660
  8. package/dist/events.mjs +2 -5
  9. package/dist/index.js +2693 -1764
  10. package/dist/index.mjs +610 -38
  11. package/dist/modals.js +1356 -815
  12. package/dist/modals.mjs +2 -4
  13. package/dist/pages.js +3023 -2248
  14. package/dist/pages.mjs +4 -7
  15. package/dist/primitives.js +1072 -355
  16. package/dist/primitives.mjs +38 -30
  17. package/dist/styles.css +1 -1
  18. package/dist/tailwind.css +1 -1
  19. package/dist/trading.js +1153 -558
  20. package/dist/trading.mjs +2 -4
  21. package/dist/types/auth/connect-button-view/connect-button-view.constants.d.mts +31 -0
  22. package/dist/types/auth/connect-button-view/connect-button-view.constants.d.ts +31 -0
  23. package/dist/types/auth/connect-button-view/connect-button-view.types.d.mts +83 -0
  24. package/dist/types/auth/connect-button-view/connect-button-view.types.d.ts +83 -0
  25. package/dist/types/auth/connect-button-view/index.d.mts +7 -0
  26. package/dist/types/auth/connect-button-view/index.d.ts +7 -0
  27. package/dist/types/auth/index.d.mts +1 -1
  28. package/dist/types/auth/index.d.ts +1 -1
  29. package/dist/types/index.d.mts +1 -1
  30. package/dist/types/index.d.ts +1 -1
  31. package/dist/types/primitives/chart/chart-type-switch.d.mts +10 -0
  32. package/dist/types/primitives/chart/chart-type-switch.d.ts +10 -0
  33. package/dist/types/primitives/chart/index.d.mts +7 -1
  34. package/dist/types/primitives/chart/index.d.ts +7 -1
  35. package/dist/types/primitives/icon/index.d.mts +9 -1
  36. package/dist/types/primitives/icon/index.d.ts +9 -1
  37. package/dist/types/primitives/icon/registry.d.mts +32 -0
  38. package/dist/types/primitives/icon/registry.d.ts +32 -0
  39. package/dist/types/primitives/icon/svg/apple.d.mts +5 -0
  40. package/dist/types/primitives/icon/svg/apple.d.ts +5 -0
  41. package/dist/types/primitives/icon/svg/chart-candlestick.d.mts +5 -0
  42. package/dist/types/primitives/icon/svg/chart-candlestick.d.ts +5 -0
  43. package/dist/types/primitives/icon/svg/chart-line.d.mts +5 -0
  44. package/dist/types/primitives/icon/svg/chart-line.d.ts +5 -0
  45. package/dist/types/primitives/icon/svg/error-filled.d.mts +5 -0
  46. package/dist/types/primitives/icon/svg/error-filled.d.ts +5 -0
  47. package/dist/types/primitives/icon/svg/ethereum.d.mts +5 -0
  48. package/dist/types/primitives/icon/svg/ethereum.d.ts +5 -0
  49. package/dist/types/primitives/icon/svg/google.d.mts +5 -0
  50. package/dist/types/primitives/icon/svg/google.d.ts +5 -0
  51. package/dist/types/primitives/icon/svg/image.d.mts +5 -0
  52. package/dist/types/primitives/icon/svg/image.d.ts +5 -0
  53. package/dist/types/primitives/icon/svg/solana.d.mts +5 -0
  54. package/dist/types/primitives/icon/svg/solana.d.ts +5 -0
  55. package/dist/types/primitives/index.d.mts +2 -0
  56. package/dist/types/primitives/index.d.ts +2 -0
  57. package/dist/types/primitives/inline-alert/index.d.mts +16 -0
  58. package/dist/types/primitives/inline-alert/index.d.ts +16 -0
  59. package/dist/types/primitives/remote-image/index.d.mts +6 -0
  60. package/dist/types/primitives/remote-image/index.d.ts +6 -0
  61. package/dist/types/primitives/remote-image/remote-image.constants.d.mts +4 -0
  62. package/dist/types/primitives/remote-image/remote-image.constants.d.ts +4 -0
  63. package/dist/types/primitives/remote-image/remote-image.types.d.mts +16 -0
  64. package/dist/types/primitives/remote-image/remote-image.types.d.ts +16 -0
  65. package/dist/types/primitives/venue-logo/svg/logo-limitless.d.mts +5 -0
  66. package/dist/types/primitives/venue-logo/svg/logo-limitless.d.ts +5 -0
  67. package/dist/types/primitives/venue-logo/venue-logo.types.d.mts +1 -1
  68. package/dist/types/primitives/venue-logo/venue-logo.types.d.ts +1 -1
  69. package/dist/types/trading/types.d.mts +26 -26
  70. package/dist/types/trading/types.d.ts +26 -26
  71. package/package.json +3 -15
  72. package/dist/auth.d.mts +0 -1
  73. package/dist/auth.d.ts +0 -1
  74. package/dist/auth.js +0 -2290
  75. package/dist/auth.mjs +0 -8
  76. package/dist/chunk-ADGL6RFX.mjs +0 -214
  77. package/dist/chunk-CN7GI2RJ.mjs +0 -585
  78. package/dist/chunk-HI4EEDN5.mjs +0 -1880
  79. package/dist/chunk-INRG3D4M.mjs +0 -450
  80. package/dist/chunk-JE3Z52FD.mjs +0 -345
  81. package/dist/chunk-MHCHR65A.mjs +0 -165
  82. package/dist/chunk-PASXFYKQ.mjs +0 -81
  83. package/dist/chunk-UBBOLLOS.mjs +0 -999
  84. package/dist/types/auth/connect-button/connect-button.constants.d.mts +0 -10
  85. package/dist/types/auth/connect-button/connect-button.constants.d.ts +0 -10
  86. package/dist/types/auth/connect-button/connect-button.types.d.mts +0 -33
  87. package/dist/types/auth/connect-button/connect-button.types.d.ts +0 -33
  88. package/dist/types/auth/connect-button/index.d.mts +0 -7
  89. package/dist/types/auth/connect-button/index.d.ts +0 -7
@@ -1,450 +0,0 @@
1
- import {
2
- LoadingIcon
3
- } from "./chunk-PASXFYKQ.mjs";
4
- import {
5
- AGG_ROOT_CLASS_NAME,
6
- Button,
7
- Icon,
8
- VenueLogo,
9
- __spreadProps,
10
- __spreadValues,
11
- cn,
12
- formatUsd,
13
- getMotionClassName,
14
- shortenAddress
15
- } from "./chunk-HI4EEDN5.mjs";
16
-
17
- // src/auth/connect-button/index.tsx
18
- import { useEffect, useMemo, useRef, useState } from "react";
19
- import * as DropdownMenu from "@radix-ui/react-dropdown-menu";
20
- import { isAddress } from "viem";
21
- import { useAccount, useConnect, useDisconnect, useSignMessage } from "wagmi";
22
- import {
23
- getWalletAddressFromUserProfile,
24
- useAggAuth,
25
- useAggBalanceState,
26
- useLabels,
27
- useSdkUiConfig
28
- } from "@agg-market/hooks";
29
-
30
- // src/auth/connect-button/connect-button.constants.ts
31
- var connectButtonContainerClassName = cn(
32
- "inline-flex flex-col items-start gap-2 font-agg-sans"
33
- );
34
- var connectedButtonsRowClassName = cn("inline-flex h-10 items-center gap-2");
35
- var connectedBalanceChipClassName = cn(
36
- "inline-flex h-10 items-center gap-3 rounded-agg-full border border-agg-separator bg-agg-secondary pl-3 pr-12 font-agg-sans"
37
- );
38
- var connectedProfileChipClassName = cn(
39
- "-ml-12",
40
- "inline-flex h-10 items-center gap-3 rounded-agg-full border border-agg-separator bg-agg-secondary pl-2 pr-3 font-agg-sans",
41
- "cursor-pointer hover:bg-agg-secondary-hover",
42
- "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-agg-primary-hover focus-visible:ring-offset-2 focus-visible:ring-offset-agg-secondary"
43
- );
44
- var profileMenuContentClassName = cn(
45
- "z-50 w-64 overflow-hidden rounded-agg-xl font-agg-sans",
46
- "border border-agg-separator bg-agg-secondary",
47
- "shadow-agg-popover"
48
- );
49
- var profileMenuSectionClassName = cn("flex w-full flex-col gap-5 px-5 py-5");
50
- var profileMenuSeparatorClassName = cn("h-px w-full bg-agg-separator");
51
- var profileMenuActionItemClassName = cn(
52
- "flex w-full items-center gap-3 px-5 py-4 font-agg-sans text-agg-sm leading-agg-5 text-agg-foreground",
53
- "outline-none",
54
- "hover:bg-agg-secondary-hover focus:bg-agg-secondary-hover"
55
- );
56
- var avatarRootClassName = cn(
57
- "inline-flex size-6 shrink-0 items-center justify-center rounded-agg-full bg-agg-separator"
58
- );
59
- var avatarIconClassName = cn("h-[66%] w-[66%] text-agg-muted-foreground");
60
-
61
- // src/auth/connect-button/index.tsx
62
- import { Fragment, jsx, jsxs } from "react/jsx-runtime";
63
- var venueLogoNameSet = /* @__PURE__ */ new Set([
64
- "polymarket",
65
- "kalshi",
66
- "opinion",
67
- "probable"
68
- ]);
69
- var toVenueLogoName = (value) => {
70
- if (!venueLogoNameSet.has(value))
71
- return null;
72
- return value;
73
- };
74
- function WalletAvatar({ className }) {
75
- return /* @__PURE__ */ jsx("span", { "aria-hidden": "true", className: cn(avatarRootClassName, className), children: /* @__PURE__ */ jsx(Icon, { className: avatarIconClassName, name: "wallet-avatar" }) });
76
- }
77
- var ConnectButton = ({
78
- autoSignInOnConnect = true,
79
- buttonProps,
80
- classNames,
81
- disabled,
82
- onConnect,
83
- onDepositClick,
84
- onDisconnect,
85
- onProfileClick,
86
- onViewAllBalancesClick,
87
- onWithdrawClick
88
- }) => {
89
- var _a, _b;
90
- const [isProfileMenuOpen, setIsProfileMenuOpen] = useState(false);
91
- const autoSignInAttemptRef = useRef(null);
92
- const { enableAnimations, rootClassName } = useSdkUiConfig();
93
- const labels = useLabels();
94
- const { address: walletAddress, chainId, isConnected: isWalletConnected } = useAccount();
95
- const { connect, connectors, isPending: isConnectPending } = useConnect();
96
- const { disconnect } = useDisconnect();
97
- const { signMessageAsync } = useSignMessage();
98
- const {
99
- totalBalance,
100
- balanceBreakdown,
101
- connectedVenues,
102
- isLoading: isBalanceLoading,
103
- error: balanceError
104
- } = useAggBalanceState();
105
- const preferredConnector = useMemo(() => {
106
- var _a2;
107
- return (_a2 = connectors.find((connector) => connector.name === "MetaMask")) != null ? _a2 : connectors[0];
108
- }, [connectors]);
109
- const signInStatement = labels.auth.signInStatement;
110
- const { signIn, signOut, isAuthenticated, user, isLoading, error } = useAggAuth({
111
- signMessage: (message) => signMessageAsync({ message }),
112
- address: walletAddress != null ? walletAddress : "",
113
- chainId
114
- });
115
- const resolvedWalletAddress = (_b = (_a = getWalletAddressFromUserProfile(user)) != null ? _a : walletAddress) != null ? _b : "";
116
- const resolvedAddressLabel = shortenAddress(resolvedWalletAddress);
117
- const resolvedProfileLabel = resolvedAddressLabel;
118
- const resolvedBalanceRows = useMemo(() => {
119
- const balancesByVenue = /* @__PURE__ */ new Map();
120
- for (const balanceItem of balanceBreakdown) {
121
- balancesByVenue.set(balanceItem.venue, balanceItem.balance);
122
- }
123
- for (const venue of connectedVenues) {
124
- if (!balancesByVenue.has(venue)) {
125
- balancesByVenue.set(venue, 0);
126
- }
127
- }
128
- return Array.from(balancesByVenue.entries()).map(([venue, balanceValue]) => {
129
- var _a2;
130
- return {
131
- key: venue,
132
- label: (_a2 = labels.venues[venue]) != null ? _a2 : venue,
133
- amountLabel: formatUsd(balanceValue),
134
- venue: toVenueLogoName(venue)
135
- };
136
- });
137
- }, [balanceBreakdown, connectedVenues, labels.venues]);
138
- const errorText = error ? `Error: ${error.message}` : null;
139
- const balanceErrorText = balanceError ? `Error: ${balanceError.message}` : null;
140
- const resolvedErrorText = errorText != null ? errorText : balanceErrorText;
141
- const normalizedWalletAddress = (walletAddress != null ? walletAddress : "").toLowerCase();
142
- const hasWalletAddress = isAddress(walletAddress != null ? walletAddress : "");
143
- const isConnectDisabled = disabled || isConnectPending || !preferredConnector;
144
- const dropdownMenuItemClassName = cn(
145
- "cursor-pointer",
146
- profileMenuActionItemClassName,
147
- getMotionClassName(enableAnimations, "transition-colors"),
148
- disabled ? "pointer-events-none opacity-50" : null,
149
- classNames == null ? void 0 : classNames.profileMenuActionItem
150
- );
151
- useEffect(() => {
152
- if (!autoSignInOnConnect) {
153
- autoSignInAttemptRef.current = null;
154
- return;
155
- }
156
- if (!isWalletConnected || isAuthenticated || isLoading || !hasWalletAddress) {
157
- if (!isWalletConnected || isAuthenticated) {
158
- autoSignInAttemptRef.current = null;
159
- }
160
- return;
161
- }
162
- const attemptKey = `${normalizedWalletAddress}:${chainId != null ? chainId : "unknown"}`;
163
- if (autoSignInAttemptRef.current === attemptKey)
164
- return;
165
- autoSignInAttemptRef.current = attemptKey;
166
- void signIn(signInStatement).catch(() => void 0);
167
- }, [
168
- autoSignInOnConnect,
169
- chainId,
170
- hasWalletAddress,
171
- isAuthenticated,
172
- isLoading,
173
- isWalletConnected,
174
- normalizedWalletAddress,
175
- signIn,
176
- signInStatement
177
- ]);
178
- const handleConnectClick = () => {
179
- if (isConnectDisabled || !preferredConnector)
180
- return;
181
- connect({ connector: preferredConnector });
182
- if (!onConnect)
183
- return;
184
- void Promise.resolve(onConnect());
185
- };
186
- const handleSignInClick = () => {
187
- if (disabled || isLoading || !hasWalletAddress)
188
- return;
189
- void signIn(signInStatement);
190
- };
191
- const handleDepositClick = () => {
192
- if (disabled)
193
- return;
194
- if (!onDepositClick)
195
- return;
196
- void Promise.resolve(onDepositClick());
197
- };
198
- const handleProfileItemClick = () => {
199
- if (disabled)
200
- return;
201
- if (!onProfileClick)
202
- return;
203
- void Promise.resolve(onProfileClick());
204
- };
205
- const handleWithdrawClick = () => {
206
- if (disabled)
207
- return;
208
- if (!onWithdrawClick)
209
- return;
210
- void Promise.resolve(onWithdrawClick());
211
- };
212
- const handleViewAllBalancesClick = () => {
213
- if (disabled)
214
- return;
215
- if (!onViewAllBalancesClick)
216
- return;
217
- void Promise.resolve(onViewAllBalancesClick());
218
- };
219
- const handleDisconnectClick = () => {
220
- if (disabled)
221
- return;
222
- signOut();
223
- disconnect();
224
- if (!onDisconnect)
225
- return;
226
- void Promise.resolve(onDisconnect());
227
- };
228
- const handleProfileMenuOpenChange = (open) => {
229
- if (disabled)
230
- return;
231
- setIsProfileMenuOpen(open);
232
- };
233
- if (resolvedErrorText) {
234
- console.error({ resolvedErrorText });
235
- }
236
- if (!isWalletConnected) {
237
- return /* @__PURE__ */ jsx("div", { className: cn(connectButtonContainerClassName, classNames == null ? void 0 : classNames.root), children: /* @__PURE__ */ jsx(
238
- Button,
239
- __spreadProps(__spreadValues({
240
- variant: "primary",
241
- size: "large",
242
- className: classNames == null ? void 0 : classNames.connectButton,
243
- onClick: handleConnectClick,
244
- disabled: isConnectDisabled,
245
- "aria-label": labels.auth.connect(preferredConnector == null ? void 0 : preferredConnector.name)
246
- }, buttonProps), {
247
- children: labels.auth.connect(preferredConnector == null ? void 0 : preferredConnector.name)
248
- })
249
- ) });
250
- }
251
- if (!isAuthenticated) {
252
- return /* @__PURE__ */ jsx("div", { className: cn(connectButtonContainerClassName, classNames == null ? void 0 : classNames.root), children: /* @__PURE__ */ jsx(
253
- Button,
254
- __spreadProps(__spreadValues({
255
- variant: "primary",
256
- size: "large",
257
- className: classNames == null ? void 0 : classNames.signInButton,
258
- onClick: handleSignInClick,
259
- disabled: disabled || !hasWalletAddress,
260
- isLoading,
261
- "aria-label": isLoading ? labels.auth.signingIn : labels.auth.signIn
262
- }, buttonProps), {
263
- children: isLoading ? labels.auth.signingIn : labels.auth.signIn
264
- })
265
- ) });
266
- }
267
- return /* @__PURE__ */ jsx("div", { className: cn(connectButtonContainerClassName, classNames == null ? void 0 : classNames.root), children: /* @__PURE__ */ jsxs("div", { className: cn(connectedButtonsRowClassName, classNames == null ? void 0 : classNames.connectedRow), children: [
268
- /* @__PURE__ */ jsxs("div", { className: cn(connectedBalanceChipClassName, classNames == null ? void 0 : classNames.balanceChip), children: [
269
- /* @__PURE__ */ jsx(
270
- Button,
271
- {
272
- variant: "primary",
273
- size: "small",
274
- className: cn("h-6 px-3 text-agg-xs leading-agg-4", classNames == null ? void 0 : classNames.depositButton),
275
- onClick: handleDepositClick,
276
- disabled,
277
- "aria-label": labels.auth.deposit,
278
- children: labels.auth.deposit
279
- }
280
- ),
281
- /* @__PURE__ */ jsx("p", { className: cn("agg-type-label text-agg-foreground", classNames == null ? void 0 : classNames.balanceText), children: isBalanceLoading ? /* @__PURE__ */ jsx(LoadingIcon, { size: "small" }) : formatUsd(totalBalance) })
282
- ] }),
283
- /* @__PURE__ */ jsxs(DropdownMenu.Root, { open: isProfileMenuOpen, onOpenChange: handleProfileMenuOpenChange, children: [
284
- /* @__PURE__ */ jsx(DropdownMenu.Trigger, { asChild: true, children: /* @__PURE__ */ jsxs(
285
- "button",
286
- {
287
- type: "button",
288
- className: cn(
289
- connectedProfileChipClassName,
290
- getMotionClassName(enableAnimations, "transition-colors"),
291
- classNames == null ? void 0 : classNames.profileTrigger
292
- ),
293
- disabled,
294
- "aria-label": labels.auth.walletMenuFor(resolvedProfileLabel),
295
- children: [
296
- /* @__PURE__ */ jsx(WalletAvatar, {}),
297
- /* @__PURE__ */ jsx(
298
- "span",
299
- {
300
- className: cn(
301
- "agg-type-body-strong text-agg-foreground",
302
- classNames == null ? void 0 : classNames.profileTriggerLabel
303
- ),
304
- children: resolvedProfileLabel
305
- }
306
- ),
307
- /* @__PURE__ */ jsx(
308
- Icon,
309
- {
310
- name: isProfileMenuOpen ? "chevron-up" : "chevron-down",
311
- size: "small",
312
- className: "h-3.5 w-3.5 text-agg-foreground",
313
- "aria-hidden": "true"
314
- }
315
- )
316
- ]
317
- }
318
- ) }),
319
- /* @__PURE__ */ jsx(DropdownMenu.Portal, { children: /* @__PURE__ */ jsxs(
320
- DropdownMenu.Content,
321
- {
322
- className: cn(
323
- AGG_ROOT_CLASS_NAME,
324
- rootClassName,
325
- profileMenuContentClassName,
326
- classNames == null ? void 0 : classNames.profileMenuContent
327
- ),
328
- "data-agg-animations": enableAnimations ? "true" : "false",
329
- sideOffset: 4,
330
- align: "end",
331
- children: [
332
- /* @__PURE__ */ jsx(
333
- "div",
334
- {
335
- className: cn(
336
- profileMenuSectionClassName,
337
- "cursor-pointer",
338
- classNames == null ? void 0 : classNames.profileMenuSection
339
- ),
340
- onClick: handleProfileItemClick,
341
- children: /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-3", children: [
342
- /* @__PURE__ */ jsx(WalletAvatar, { className: "size-11" }),
343
- /* @__PURE__ */ jsxs("div", { className: "flex flex-col items-start gap-0.5", children: [
344
- /* @__PURE__ */ jsx("p", { className: "text-agg-lg font-agg-bold leading-agg-7 text-agg-foreground", children: resolvedProfileLabel }),
345
- /* @__PURE__ */ jsx("p", { className: "text-agg-sm font-agg-normal leading-agg-5 text-agg-muted-foreground", children: resolvedAddressLabel })
346
- ] })
347
- ] })
348
- }
349
- ),
350
- /* @__PURE__ */ jsx(
351
- "div",
352
- {
353
- className: cn(profileMenuSeparatorClassName, classNames == null ? void 0 : classNames.profileMenuSeparator)
354
- }
355
- ),
356
- /* @__PURE__ */ jsxs("div", { className: cn(profileMenuSectionClassName, classNames == null ? void 0 : classNames.profileMenuSection), children: [
357
- isBalanceLoading ? /* @__PURE__ */ jsxs("p", { className: "flex flex-col gap-2 items-center justify-center text-agg-sm font-agg-normal leading-agg-5 text-agg-muted-foreground", children: [
358
- /* @__PURE__ */ jsx(LoadingIcon, {}),
359
- labels.auth.loadingBalances
360
- ] }) : /* @__PURE__ */ jsx(Fragment, { children: resolvedBalanceRows.length === 0 ? /* @__PURE__ */ jsxs("p", { className: "flex flex-col gap-2 items-center justify-center text-agg-sm font-agg-normal leading-agg-5 text-agg-muted-foreground", children: [
361
- /* @__PURE__ */ jsx(Icon, { name: "warning", className: "text-agg-primary" }),
362
- labels.auth.noBalances
363
- ] }) : /* @__PURE__ */ jsxs("div", { className: "flex w-full items-center justify-between", children: [
364
- /* @__PURE__ */ jsx("p", { className: "text-agg-xs font-agg-bold uppercase leading-agg-4 tracking-agg-normal text-agg-muted-foreground", children: labels.auth.balances }),
365
- /* @__PURE__ */ jsx(
366
- Button,
367
- {
368
- variant: "tertiary",
369
- size: "small",
370
- className: "h-6 px-3 text-agg-xs leading-agg-4",
371
- onClick: handleViewAllBalancesClick,
372
- children: labels.auth.viewAll
373
- }
374
- )
375
- ] }) }),
376
- !isBalanceLoading ? resolvedBalanceRows.map((row) => /* @__PURE__ */ jsxs("div", { className: "flex w-full items-center justify-between", children: [
377
- /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-1.5", children: [
378
- row.venue ? /* @__PURE__ */ jsx(VenueLogo, { venue: row.venue, size: "small" }) : null,
379
- /* @__PURE__ */ jsx("p", { className: "text-agg-sm font-agg-normal leading-agg-5 text-agg-foreground", children: row.label })
380
- ] }),
381
- /* @__PURE__ */ jsx("p", { className: "text-agg-sm font-agg-bold leading-agg-5 text-agg-foreground", children: row.amountLabel })
382
- ] }, row.key)) : null
383
- ] }),
384
- /* @__PURE__ */ jsx(
385
- "div",
386
- {
387
- className: cn(profileMenuSeparatorClassName, classNames == null ? void 0 : classNames.profileMenuSeparator)
388
- }
389
- ),
390
- /* @__PURE__ */ jsxs("div", { className: "flex w-full flex-col py-2", children: [
391
- /* @__PURE__ */ jsxs(
392
- DropdownMenu.Item,
393
- {
394
- className: dropdownMenuItemClassName,
395
- onSelect: handleProfileItemClick,
396
- disabled,
397
- children: [
398
- /* @__PURE__ */ jsx(Icon, { name: "profile", size: "small", className: "text-agg-foreground" }),
399
- /* @__PURE__ */ jsx("span", { children: labels.auth.myProfile })
400
- ]
401
- }
402
- ),
403
- /* @__PURE__ */ jsxs(
404
- DropdownMenu.Item,
405
- {
406
- className: dropdownMenuItemClassName,
407
- onSelect: handleDepositClick,
408
- disabled,
409
- children: [
410
- /* @__PURE__ */ jsx(Icon, { name: "download", size: "small", className: "text-agg-foreground" }),
411
- /* @__PURE__ */ jsx("span", { children: labels.auth.deposit })
412
- ]
413
- }
414
- ),
415
- /* @__PURE__ */ jsxs(
416
- DropdownMenu.Item,
417
- {
418
- className: dropdownMenuItemClassName,
419
- onSelect: handleWithdrawClick,
420
- disabled,
421
- children: [
422
- /* @__PURE__ */ jsx(Icon, { name: "upload", size: "small", className: "text-agg-foreground" }),
423
- /* @__PURE__ */ jsx("span", { children: labels.auth.withdraw })
424
- ]
425
- }
426
- ),
427
- /* @__PURE__ */ jsxs(
428
- DropdownMenu.Item,
429
- {
430
- className: dropdownMenuItemClassName,
431
- onSelect: handleDisconnectClick,
432
- disabled,
433
- children: [
434
- /* @__PURE__ */ jsx(Icon, { name: "disconnect", size: "small", className: "text-agg-foreground" }),
435
- /* @__PURE__ */ jsx("span", { children: labels.auth.disconnect })
436
- ]
437
- }
438
- )
439
- ] })
440
- ]
441
- }
442
- ) })
443
- ] })
444
- ] }) });
445
- };
446
- ConnectButton.displayName = "ConnectButton";
447
-
448
- export {
449
- ConnectButton
450
- };