decentraland-ui2 2.5.3 → 3.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.
- package/dist/components/Navbar/Credits.styled.d.ts +9 -0
- package/dist/components/Navbar/Credits.styled.js +58 -0
- package/dist/components/Navbar/Credits.styled.js.map +1 -0
- package/dist/components/Navbar/MobileMenu.d.ts +8 -0
- package/dist/components/Navbar/MobileMenu.js +20 -0
- package/dist/components/Navbar/MobileMenu.js.map +1 -0
- package/dist/components/Navbar/MobileMenu.styled.d.ts +35 -0
- package/dist/components/Navbar/MobileMenu.styled.js +116 -0
- package/dist/components/Navbar/MobileMenu.styled.js.map +1 -0
- package/dist/components/Navbar/NavLinks.d.ts +11 -0
- package/dist/components/Navbar/NavLinks.js +19 -0
- package/dist/components/Navbar/NavLinks.js.map +1 -0
- package/dist/components/Navbar/NavLinks.styled.d.ts +31 -0
- package/dist/components/Navbar/NavLinks.styled.js +130 -0
- package/dist/components/Navbar/NavLinks.styled.js.map +1 -0
- package/dist/components/Navbar/Navbar.d.ts +2 -3
- package/dist/components/Navbar/Navbar.defaults.d.ts +29 -6
- package/dist/components/Navbar/Navbar.defaults.js +101 -231
- package/dist/components/Navbar/Navbar.defaults.js.map +1 -1
- package/dist/components/Navbar/Navbar.js +109 -34
- package/dist/components/Navbar/Navbar.js.map +1 -1
- package/dist/components/Navbar/Navbar.stories.d.ts +9 -8
- package/dist/components/Navbar/Navbar.stories.js +93 -60
- package/dist/components/Navbar/Navbar.stories.js.map +1 -1
- package/dist/components/Navbar/Navbar.styled.d.ts +53 -56
- package/dist/components/Navbar/Navbar.styled.js +168 -101
- package/dist/components/Navbar/Navbar.styled.js.map +1 -1
- package/dist/components/Navbar/Navbar.types.d.ts +72 -56
- package/dist/components/Navbar/Navbar.types.js +1 -10
- package/dist/components/Navbar/Navbar.types.js.map +1 -1
- package/dist/components/Navbar/NotificationBell.styled.d.ts +61 -0
- package/dist/components/Navbar/NotificationBell.styled.js +189 -0
- package/dist/components/Navbar/NotificationBell.styled.js.map +1 -0
- package/dist/components/Navbar/UserCardPanel.d.ts +27 -0
- package/dist/components/Navbar/UserCardPanel.js +106 -0
- package/dist/components/Navbar/UserCardPanel.js.map +1 -0
- package/dist/components/Navbar/UserCardPanel.styled.d.ts +133 -0
- package/dist/components/Navbar/UserCardPanel.styled.js +392 -0
- package/dist/components/Navbar/UserCardPanel.styled.js.map +1 -0
- package/dist/components/Navbar/formatBalance.d.ts +2 -0
- package/dist/components/Navbar/formatBalance.js +5 -0
- package/dist/components/Navbar/formatBalance.js.map +1 -0
- package/dist/components/Navbar/icons.d.ts +24 -0
- package/dist/components/Navbar/icons.js +67 -0
- package/dist/components/Navbar/icons.js.map +1 -0
- package/dist/components/Navbar/index.d.ts +3 -2
- package/dist/components/Navbar/index.js +2 -2
- package/dist/components/Navbar/index.js.map +1 -1
- package/package.json +2 -2
- package/dist/components/Navbar/MainMenu/MainMenu.d.ts +0 -2
- package/dist/components/Navbar/MainMenu/MainMenu.js +0 -26
- package/dist/components/Navbar/MainMenu/MainMenu.js.map +0 -1
- package/dist/components/Navbar/MainMenu/MainMenu.styled.d.ts +0 -9
- package/dist/components/Navbar/MainMenu/MainMenu.styled.js +0 -39
- package/dist/components/Navbar/MainMenu/MainMenu.styled.js.map +0 -1
- package/dist/components/Navbar/MainMenu/MainMenu.types.d.ts +0 -8
- package/dist/components/Navbar/MainMenu/MainMenu.types.js +0 -2
- package/dist/components/Navbar/MainMenu/MainMenu.types.js.map +0 -1
- package/dist/components/Navbar/MenuItem/MenuItem.d.ts +0 -3
- package/dist/components/Navbar/MenuItem/MenuItem.js +0 -15
- package/dist/components/Navbar/MenuItem/MenuItem.js.map +0 -1
- package/dist/components/Navbar/MenuItem/MenuItem.styled.d.ts +0 -18
- package/dist/components/Navbar/MenuItem/MenuItem.styled.js +0 -59
- package/dist/components/Navbar/MenuItem/MenuItem.styled.js.map +0 -1
- package/dist/components/Navbar/MenuItem/MenuItem.types.d.ts +0 -12
- package/dist/components/Navbar/MenuItem/MenuItem.types.js +0 -2
- package/dist/components/Navbar/MenuItem/MenuItem.types.js.map +0 -1
- package/dist/components/Navbar/SubMenu/SubMenu.d.ts +0 -2
- package/dist/components/Navbar/SubMenu/SubMenu.js +0 -14
- package/dist/components/Navbar/SubMenu/SubMenu.js.map +0 -1
- package/dist/components/Navbar/SubMenu/SubMenu.styled.d.ts +0 -27
- package/dist/components/Navbar/SubMenu/SubMenu.styled.js +0 -165
- package/dist/components/Navbar/SubMenu/SubMenu.styled.js.map +0 -1
- package/dist/components/Navbar/SubMenu/SubMenu.types.d.ts +0 -13
- package/dist/components/Navbar/SubMenu/SubMenu.types.js +0 -2
- package/dist/components/Navbar/SubMenu/SubMenu.types.js.map +0 -1
- package/dist/components/Navbar/SubMenuColumn/SubMenuColumn.d.ts +0 -3
- package/dist/components/Navbar/SubMenuColumn/SubMenuColumn.js +0 -9
- package/dist/components/Navbar/SubMenuColumn/SubMenuColumn.js.map +0 -1
- package/dist/components/Navbar/SubMenuColumn/SubMenuColumn.styled.d.ts +0 -11
- package/dist/components/Navbar/SubMenuColumn/SubMenuColumn.styled.js +0 -33
- package/dist/components/Navbar/SubMenuColumn/SubMenuColumn.styled.js.map +0 -1
- package/dist/components/Navbar/SubMenuColumn/SubMenuColumn.types.d.ts +0 -5
- package/dist/components/Navbar/SubMenuColumn/SubMenuColumn.types.js +0 -2
- package/dist/components/Navbar/SubMenuColumn/SubMenuColumn.types.js.map +0 -1
- package/dist/components/Navbar/SubMenuItem/SubMenuItem.d.ts +0 -2
- package/dist/components/Navbar/SubMenuItem/SubMenuItem.js +0 -15
- package/dist/components/Navbar/SubMenuItem/SubMenuItem.js.map +0 -1
- package/dist/components/Navbar/SubMenuItem/SubMenuItem.styled.d.ts +0 -32
- package/dist/components/Navbar/SubMenuItem/SubMenuItem.styled.js +0 -84
- package/dist/components/Navbar/SubMenuItem/SubMenuItem.styled.js.map +0 -1
- package/dist/components/Navbar/SubMenuItem/SubMenuItem.types.d.ts +0 -13
- package/dist/components/Navbar/SubMenuItem/SubMenuItem.types.js +0 -2
- package/dist/components/Navbar/SubMenuItem/SubMenuItem.types.js.map +0 -1
- package/dist/components/Navbar/utils.d.ts +0 -16
- package/dist/components/Navbar/utils.js +0 -33
- package/dist/components/Navbar/utils.js.map +0 -1
|
@@ -0,0 +1,189 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Notification styled components for building the notification slot UI.
|
|
3
|
+
* These are not used by the Navbar component directly -- they are exported
|
|
4
|
+
* for consumers (e.g. landing-site, decentraland-dapps) to compose their
|
|
5
|
+
* notification panel UI and pass it as the notificationSlot prop.
|
|
6
|
+
*/
|
|
7
|
+
import styled from '@emotion/styled';
|
|
8
|
+
import * as colors from '../../theme/colors';
|
|
9
|
+
import { MOBILE_BREAKPOINT, bellShake, slideDown } from './Navbar.styled';
|
|
10
|
+
const BellButton = styled('button')({
|
|
11
|
+
all: 'unset',
|
|
12
|
+
position: 'relative',
|
|
13
|
+
display: 'flex',
|
|
14
|
+
alignItems: 'center',
|
|
15
|
+
justifyContent: 'center',
|
|
16
|
+
width: 24,
|
|
17
|
+
height: 24,
|
|
18
|
+
color: colors.neutral.white,
|
|
19
|
+
cursor: 'pointer',
|
|
20
|
+
flexShrink: 0,
|
|
21
|
+
borderRadius: 4,
|
|
22
|
+
'&.has-unread': {
|
|
23
|
+
animation: `${bellShake} 0.8s`,
|
|
24
|
+
animationIterationCount: 4
|
|
25
|
+
},
|
|
26
|
+
'&:focus-visible': {
|
|
27
|
+
outline: `2px solid ${colors.base.primary}`,
|
|
28
|
+
outlineOffset: 2
|
|
29
|
+
},
|
|
30
|
+
'& svg': {
|
|
31
|
+
width: 24,
|
|
32
|
+
height: 24
|
|
33
|
+
}
|
|
34
|
+
});
|
|
35
|
+
const NotificationBadge = styled('span')({
|
|
36
|
+
position: 'absolute',
|
|
37
|
+
top: -4,
|
|
38
|
+
right: -6,
|
|
39
|
+
minWidth: 16,
|
|
40
|
+
height: 16,
|
|
41
|
+
borderRadius: 8,
|
|
42
|
+
backgroundColor: colors.base.primary,
|
|
43
|
+
color: '#fff',
|
|
44
|
+
fontSize: 10,
|
|
45
|
+
fontWeight: 700,
|
|
46
|
+
fontFamily: 'Inter, Helvetica, Arial, sans-serif',
|
|
47
|
+
display: 'flex',
|
|
48
|
+
alignItems: 'center',
|
|
49
|
+
justifyContent: 'center',
|
|
50
|
+
padding: '0 4px',
|
|
51
|
+
lineHeight: 1,
|
|
52
|
+
pointerEvents: 'none'
|
|
53
|
+
});
|
|
54
|
+
const NotificationWrapper = styled('div')({
|
|
55
|
+
position: 'relative'
|
|
56
|
+
});
|
|
57
|
+
const NotificationPanel = styled('div')({
|
|
58
|
+
position: 'absolute',
|
|
59
|
+
top: '100%',
|
|
60
|
+
right: -12,
|
|
61
|
+
marginTop: 16,
|
|
62
|
+
width: 390,
|
|
63
|
+
maxHeight: '70vh',
|
|
64
|
+
zIndex: 1102,
|
|
65
|
+
background: 'rgba(38, 38, 38, 0.8)',
|
|
66
|
+
backdropFilter: 'blur(12.5px)',
|
|
67
|
+
WebkitBackdropFilter: 'blur(12.5px)',
|
|
68
|
+
border: '0.5px solid #5E5B67',
|
|
69
|
+
borderRadius: 12,
|
|
70
|
+
boxShadow: '0 2px 20px rgba(0, 0, 0, 0.25)',
|
|
71
|
+
display: 'flex',
|
|
72
|
+
flexDirection: 'column',
|
|
73
|
+
overflow: 'hidden',
|
|
74
|
+
paddingTop: 12,
|
|
75
|
+
paddingBottom: 24,
|
|
76
|
+
animation: `${slideDown} 0.15s ease forwards`,
|
|
77
|
+
[MOBILE_BREAKPOINT]: {
|
|
78
|
+
position: 'fixed',
|
|
79
|
+
top: 64,
|
|
80
|
+
left: 0,
|
|
81
|
+
right: 0,
|
|
82
|
+
width: 'auto',
|
|
83
|
+
maxHeight: 'calc(100vh - 64px)',
|
|
84
|
+
borderRadius: 0
|
|
85
|
+
}
|
|
86
|
+
});
|
|
87
|
+
const NotificationHeader = styled('div')({
|
|
88
|
+
display: 'flex',
|
|
89
|
+
alignItems: 'center',
|
|
90
|
+
justifyContent: 'space-between',
|
|
91
|
+
padding: '0 12px 12px 24px',
|
|
92
|
+
borderBottom: '0.5px solid #5E5B67'
|
|
93
|
+
});
|
|
94
|
+
const NotificationTitle = styled('span')({
|
|
95
|
+
fontFamily: 'Inter, Helvetica, Arial, sans-serif',
|
|
96
|
+
fontWeight: 600,
|
|
97
|
+
fontSize: 20,
|
|
98
|
+
color: '#FCFCFC'
|
|
99
|
+
});
|
|
100
|
+
const NotificationList = styled('div')({
|
|
101
|
+
display: 'flex',
|
|
102
|
+
flexDirection: 'column',
|
|
103
|
+
overflowY: 'auto',
|
|
104
|
+
flex: 1
|
|
105
|
+
});
|
|
106
|
+
const NotificationListItem = styled('div')({
|
|
107
|
+
display: 'flex',
|
|
108
|
+
alignItems: 'flex-start',
|
|
109
|
+
gap: 8,
|
|
110
|
+
padding: '8px 16px',
|
|
111
|
+
borderRadius: 8,
|
|
112
|
+
cursor: 'pointer',
|
|
113
|
+
transition: 'background-color 0.15s ease',
|
|
114
|
+
'&:hover': {
|
|
115
|
+
backgroundColor: 'rgba(255, 255, 255, 0.05)'
|
|
116
|
+
}
|
|
117
|
+
});
|
|
118
|
+
const NotificationItemImage = styled('div')({
|
|
119
|
+
width: 56,
|
|
120
|
+
height: 56,
|
|
121
|
+
borderRadius: '50%',
|
|
122
|
+
backgroundColor: 'rgba(103, 99, 112, 0.4)',
|
|
123
|
+
flexShrink: 0,
|
|
124
|
+
display: 'flex',
|
|
125
|
+
alignItems: 'center',
|
|
126
|
+
justifyContent: 'center',
|
|
127
|
+
overflow: 'hidden',
|
|
128
|
+
'& img, & svg': {
|
|
129
|
+
width: 48,
|
|
130
|
+
height: 48,
|
|
131
|
+
objectFit: 'cover'
|
|
132
|
+
}
|
|
133
|
+
});
|
|
134
|
+
const NotificationItemContent = styled('div')({
|
|
135
|
+
display: 'flex',
|
|
136
|
+
flexDirection: 'column',
|
|
137
|
+
gap: 2,
|
|
138
|
+
minWidth: 0,
|
|
139
|
+
flex: 1
|
|
140
|
+
});
|
|
141
|
+
const NotificationItemTitle = styled('span')({
|
|
142
|
+
fontFamily: 'Inter, Helvetica, Arial, sans-serif',
|
|
143
|
+
fontWeight: 600,
|
|
144
|
+
fontSize: 16,
|
|
145
|
+
lineHeight: 1.75,
|
|
146
|
+
color: '#FCFCFC',
|
|
147
|
+
overflow: 'hidden',
|
|
148
|
+
textOverflow: 'ellipsis',
|
|
149
|
+
whiteSpace: 'nowrap'
|
|
150
|
+
});
|
|
151
|
+
const NotificationItemDescription = styled('span')({
|
|
152
|
+
fontFamily: 'Inter, Helvetica, Arial, sans-serif',
|
|
153
|
+
fontWeight: 400,
|
|
154
|
+
fontSize: 12,
|
|
155
|
+
lineHeight: '20px',
|
|
156
|
+
color: '#ECEBED',
|
|
157
|
+
maxWidth: 280,
|
|
158
|
+
overflow: 'hidden',
|
|
159
|
+
textOverflow: 'ellipsis',
|
|
160
|
+
whiteSpace: 'nowrap'
|
|
161
|
+
});
|
|
162
|
+
const NotificationItemTime = styled('span')({
|
|
163
|
+
fontFamily: 'Inter, Helvetica, Arial, sans-serif',
|
|
164
|
+
fontWeight: 400,
|
|
165
|
+
fontSize: 12,
|
|
166
|
+
color: '#A09BA8'
|
|
167
|
+
});
|
|
168
|
+
const NotificationDot = styled('div')({
|
|
169
|
+
width: 8,
|
|
170
|
+
height: 8,
|
|
171
|
+
borderRadius: 4,
|
|
172
|
+
backgroundColor: '#FF2D55',
|
|
173
|
+
flexShrink: 0,
|
|
174
|
+
alignSelf: 'center'
|
|
175
|
+
});
|
|
176
|
+
const NotificationEmpty = styled('div')({
|
|
177
|
+
display: 'flex',
|
|
178
|
+
flexDirection: 'column',
|
|
179
|
+
alignItems: 'center',
|
|
180
|
+
justifyContent: 'center',
|
|
181
|
+
padding: '40px 80px',
|
|
182
|
+
gap: 8,
|
|
183
|
+
color: colors.neutral.gray3,
|
|
184
|
+
fontFamily: 'Inter, Helvetica, Arial, sans-serif',
|
|
185
|
+
fontSize: 16,
|
|
186
|
+
textAlign: 'center'
|
|
187
|
+
});
|
|
188
|
+
export { BellButton, NotificationBadge, NotificationDot, NotificationEmpty, NotificationHeader, NotificationItemContent, NotificationItemDescription, NotificationItemImage, NotificationItemTime, NotificationItemTitle, NotificationList, NotificationListItem, NotificationPanel, NotificationTitle, NotificationWrapper };
|
|
189
|
+
//# sourceMappingURL=NotificationBell.styled.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"NotificationBell.styled.js","sourceRoot":"","sources":["../../../src/components/Navbar/NotificationBell.styled.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,OAAO,MAAM,MAAM,iBAAiB,CAAA;AACpC,OAAO,KAAK,MAAM,MAAM,oBAAoB,CAAA;AAC5C,OAAO,EAAE,iBAAiB,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAA;AAEzE,MAAM,UAAU,GAAG,MAAM,CAAC,QAAQ,CAAC,CAAC;IAClC,GAAG,EAAE,OAAO;IACZ,QAAQ,EAAE,UAAU;IACpB,OAAO,EAAE,MAAM;IACf,UAAU,EAAE,QAAQ;IACpB,cAAc,EAAE,QAAQ;IACxB,KAAK,EAAE,EAAE;IACT,MAAM,EAAE,EAAE;IACV,KAAK,EAAE,MAAM,CAAC,OAAO,CAAC,KAAK;IAC3B,MAAM,EAAE,SAAS;IACjB,UAAU,EAAE,CAAC;IACb,YAAY,EAAE,CAAC;IACf,cAAc,EAAE;QACd,SAAS,EAAE,GAAG,SAAS,OAAO;QAC9B,uBAAuB,EAAE,CAAC;KAC3B;IACD,iBAAiB,EAAE;QACjB,OAAO,EAAE,aAAa,MAAM,CAAC,IAAI,CAAC,OAAO,EAAE;QAC3C,aAAa,EAAE,CAAC;KACjB;IACD,OAAO,EAAE;QACP,KAAK,EAAE,EAAE;QACT,MAAM,EAAE,EAAE;KACX;CACF,CAAC,CAAA;AAEF,MAAM,iB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,EAAE,CAAC;IACb,SAAS,EAAE,QAAQ;CACpB,CAAC,CAAA;AAEF,MAAM,iBAAiB,GAAG,MAAM,CAAC,KAAK,CAAC,CAAC;IACtC,OAAO,EAAE,MAAM;IACf,aAAa,EAAE,QAAQ;IACvB,UAAU,EAAE,QAAQ;IACpB,cAAc,EAAE,QAAQ;IACxB,OAAO,EAAE,WAAW;IACpB,GAAG,EAAE,CAAC;IACN,KAAK,EAAE,MAAM,CAAC,OAAO,CAAC,KAAK;IAC3B,UAAU,EAAE,qCAAqC;IACjD,QAAQ,EAAE,EAAE;IACZ,SAAS,EAAE,QAAQ;CACpB,CAAC,CAAA;AAEF,OAAO,EACL,UAAU,EACV,iBAAiB,EACjB,eAAe,EACf,iBAAiB,EACjB,kBAAkB,EAClB,uBAAuB,EACvB,2BAA2B,EAC3B,qBAAqB,EACrB,oBAAoB,EACpB,qBAAqB,EACrB,gBAAgB,EAChB,oBAAoB,EACpB,iBAAiB,EACjB,iBAAiB,EACjB,mBAAmB,EACpB,CAAA"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { Network } from '@dcl/schemas/dist/dapps/network';
|
|
2
|
+
import type { NavbarI18n } from './Navbar.types';
|
|
3
|
+
import type { ChainId } from '@dcl/schemas';
|
|
4
|
+
interface UserCardPanelProps {
|
|
5
|
+
isLoadingProfile?: boolean;
|
|
6
|
+
address?: string;
|
|
7
|
+
avatar?: {
|
|
8
|
+
name?: string;
|
|
9
|
+
avatar?: {
|
|
10
|
+
snapshots?: {
|
|
11
|
+
face256?: string;
|
|
12
|
+
body?: string;
|
|
13
|
+
};
|
|
14
|
+
};
|
|
15
|
+
};
|
|
16
|
+
userCardOpen: boolean;
|
|
17
|
+
onToggleUserCard: () => void;
|
|
18
|
+
onClickSignOut: () => void;
|
|
19
|
+
selectedChain?: ChainId;
|
|
20
|
+
chains?: ChainId[];
|
|
21
|
+
onSelectChain?: (chain: ChainId) => void;
|
|
22
|
+
manaBalances?: Partial<Record<Network, number>>;
|
|
23
|
+
onClickBalance?: (network: Network) => void;
|
|
24
|
+
i18n: NavbarI18n;
|
|
25
|
+
}
|
|
26
|
+
declare const UserCardPanel: import("react").NamedExoticComponent<UserCardPanelProps>;
|
|
27
|
+
export { UserCardPanel };
|
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
|
+
import { memo, useCallback, useEffect, useState } from 'react';
|
|
3
|
+
import { Network } from '@dcl/schemas/dist/dapps/network';
|
|
4
|
+
import { formatBalance } from './formatBalance';
|
|
5
|
+
import { AccountIcon, ChainIcon, ChevronDownIcon, CopyIcon, DclLogo, LogoutIcon, ManaEthInlineIcon, ManaMaticInlineIcon, SettingsIcon, ShoppingBagIcon, WearableIcon } from './icons';
|
|
6
|
+
import { getUserMenuItems } from './Navbar.defaults';
|
|
7
|
+
import { AvatarButton, AvatarImage, BalanceAndChainRow, ChainOption, ChainPillButton, ChainPillContainer, ChainPillIconWrapper, ChainPillText, ManaBalanceClickable, ManaBalanceValue, ManaBalancesGroup, MobileUserCard, MobileUserCardAddress, MobileUserCardAddressLabel, MobileUserCardAvatar, MobileUserCardCopyButton, MobileUserCardInfo, MobileUserCardName, MobileUserCardTop, UserCard, UserCardAddress, UserCardAddressLabel, UserCardAvatarBody, UserCardAvatarContainer, UserCardChainOptions, UserCardCopyButton, UserCardDivider, UserCardLogout, UserCardMenu, UserCardMenuItem, UserCardName, UserCardWrapper } from './UserCardPanel.styled';
|
|
8
|
+
const ICON_MAP = {
|
|
9
|
+
account: AccountIcon,
|
|
10
|
+
wearable: WearableIcon,
|
|
11
|
+
settings: SettingsIcon,
|
|
12
|
+
shopping: ShoppingBagIcon
|
|
13
|
+
};
|
|
14
|
+
const PEER_BASE_URL = 'https://peer.decentraland.org/content/contents/';
|
|
15
|
+
function resolveContentUrl(hash) {
|
|
16
|
+
if (!hash)
|
|
17
|
+
return undefined;
|
|
18
|
+
if (hash.startsWith('http://') || hash.startsWith('https://'))
|
|
19
|
+
return hash;
|
|
20
|
+
if (hash.startsWith('data:'))
|
|
21
|
+
return hash;
|
|
22
|
+
if (!/^[a-zA-Z0-9]+$/.test(hash))
|
|
23
|
+
return undefined;
|
|
24
|
+
return `${PEER_BASE_URL}${hash}`;
|
|
25
|
+
}
|
|
26
|
+
/* ------------------------------------------------------------------ */
|
|
27
|
+
/* Chain helpers */
|
|
28
|
+
/* ------------------------------------------------------------------ */
|
|
29
|
+
const CHAIN_DISPLAY_NAME = {
|
|
30
|
+
1: 'Ethereum',
|
|
31
|
+
11155111: 'Sepolia',
|
|
32
|
+
137: 'Polygon',
|
|
33
|
+
80002: 'Amoy',
|
|
34
|
+
56: 'BSC',
|
|
35
|
+
43114: 'Avalanche',
|
|
36
|
+
42161: 'Arbitrum',
|
|
37
|
+
10: 'Optimism',
|
|
38
|
+
250: 'Fantom'
|
|
39
|
+
};
|
|
40
|
+
function getChainDisplayName(chainId) {
|
|
41
|
+
return CHAIN_DISPLAY_NAME[chainId] ?? `Chain ${chainId}`;
|
|
42
|
+
}
|
|
43
|
+
const UserCardPanel = memo(function UserCardPanel({ isLoadingProfile, address, avatar, userCardOpen, onToggleUserCard, onClickSignOut, selectedChain, chains, onSelectChain, manaBalances, onClickBalance, i18n }) {
|
|
44
|
+
const resolvedFace = resolveContentUrl(avatar?.avatar?.snapshots?.face256);
|
|
45
|
+
const [loadedUrl, setLoadedUrl] = useState();
|
|
46
|
+
const [faceError, setFaceError] = useState(false);
|
|
47
|
+
// Reset error when face URL changes
|
|
48
|
+
useEffect(() => {
|
|
49
|
+
setFaceError(false);
|
|
50
|
+
}, [resolvedFace]);
|
|
51
|
+
const faceLoaded = resolvedFace ? loadedUrl === resolvedFace : false;
|
|
52
|
+
const bodyUrl = resolveContentUrl(avatar?.avatar?.snapshots?.body);
|
|
53
|
+
const userName = avatar?.name || (address ? `${address.slice(0, 6)}...${address.slice(-4)}` : '');
|
|
54
|
+
const shortAddress = address ? `${address.slice(0, 6)}...${address.slice(-4)}` : '';
|
|
55
|
+
const [addressCopied, setAddressCopied] = useState(false);
|
|
56
|
+
const [chainSelectorOpen, setChainSelectorOpen] = useState(false);
|
|
57
|
+
const copyAddress = useCallback(() => {
|
|
58
|
+
if (address) {
|
|
59
|
+
navigator.clipboard
|
|
60
|
+
.writeText(address)
|
|
61
|
+
.then(() => {
|
|
62
|
+
setAddressCopied(true);
|
|
63
|
+
setTimeout(() => setAddressCopied(false), 2000);
|
|
64
|
+
})
|
|
65
|
+
.catch(() => {
|
|
66
|
+
// Silently fail if clipboard API is not available
|
|
67
|
+
});
|
|
68
|
+
}
|
|
69
|
+
}, [address]);
|
|
70
|
+
const handleSelectChain = useCallback((chain) => {
|
|
71
|
+
if (chain !== selectedChain) {
|
|
72
|
+
onSelectChain?.(chain);
|
|
73
|
+
}
|
|
74
|
+
setChainSelectorOpen(false);
|
|
75
|
+
}, [selectedChain, onSelectChain]);
|
|
76
|
+
const hasChainOrMana = (selectedChain !== undefined && chains && chains.length > 0) || (manaBalances && Object.keys(manaBalances).length > 0);
|
|
77
|
+
const renderBalanceAndChain = () => {
|
|
78
|
+
if (!hasChainOrMana)
|
|
79
|
+
return null;
|
|
80
|
+
return (_jsxs(BalanceAndChainRow, { children: [manaBalances && (_jsxs(ManaBalancesGroup, { children: [manaBalances.ETHEREUM !== undefined && (_jsxs(ManaBalanceClickable, { clickable: !!onClickBalance, onClick: () => onClickBalance?.(Network.ETHEREUM), children: [_jsx(ManaEthInlineIcon, {}), _jsx(ManaBalanceValue, { children: formatBalance(manaBalances.ETHEREUM) })] })), manaBalances.MATIC !== undefined && (_jsxs(ManaBalanceClickable, { clickable: !!onClickBalance, onClick: () => onClickBalance?.(Network.MATIC), children: [_jsx(ManaMaticInlineIcon, {}), _jsx(ManaBalanceValue, { children: formatBalance(manaBalances.MATIC) })] }))] })), selectedChain !== undefined && chains && chains.length > 0 && (_jsxs(ChainPillContainer, { children: [_jsxs(ChainPillButton, { onClick: () => setChainSelectorOpen(prev => !prev), children: [_jsx(ChainPillIconWrapper, { children: _jsx(ChainIcon, { chainId: selectedChain }) }), _jsx(ChainPillText, { children: getChainDisplayName(selectedChain) }), _jsx(ChevronDownIcon, { style: {
|
|
81
|
+
width: 20,
|
|
82
|
+
height: 20,
|
|
83
|
+
flexShrink: 0,
|
|
84
|
+
color: 'white',
|
|
85
|
+
transform: chainSelectorOpen ? 'rotate(180deg)' : 'rotate(0deg)',
|
|
86
|
+
transition: 'transform 0.25s ease'
|
|
87
|
+
} })] }), chainSelectorOpen && (_jsx(UserCardChainOptions, { role: "listbox", "aria-label": "Select chain", children: chains.map(chain => {
|
|
88
|
+
const isSelected = chain === selectedChain;
|
|
89
|
+
return (_jsxs(ChainOption, { selected: isSelected, role: "option", "aria-selected": isSelected, onClick: () => handleSelectChain(chain), children: [_jsx(ChainIcon, { chainId: chain }), getChainDisplayName(chain)] }, chain));
|
|
90
|
+
}) }))] }))] }));
|
|
91
|
+
};
|
|
92
|
+
const renderAvatar = () => {
|
|
93
|
+
if (!resolvedFace || faceError) {
|
|
94
|
+
return (_jsx("div", { style: { display: 'flex', alignItems: 'center', justifyContent: 'center', width: '100%', height: '100%', padding: 6 }, children: _jsx(DclLogo, { style: { width: '100%', height: '100%' } }) }));
|
|
95
|
+
}
|
|
96
|
+
return (_jsx(AvatarImage, { src: resolvedFace, alt: "", onLoad: () => setLoadedUrl(resolvedFace), onError: () => setFaceError(true), style: { opacity: faceLoaded ? 1 : 0 } }));
|
|
97
|
+
};
|
|
98
|
+
const renderMenuItems = () => (_jsxs(_Fragment, { children: [getUserMenuItems().map(item => {
|
|
99
|
+
const Icon = ICON_MAP[item.icon];
|
|
100
|
+
return (_jsxs(UserCardMenuItem, { href: item.url, children: [Icon && _jsx(Icon, {}), i18n[item.label]] }, item.label));
|
|
101
|
+
}), _jsx(UserCardDivider, {}), _jsxs(UserCardLogout, { onClick: onClickSignOut, children: [_jsx(LogoutIcon, {}), i18n.logout] })] }));
|
|
102
|
+
return (_jsxs(_Fragment, { children: [_jsxs(UserCardWrapper, { children: [_jsx(AvatarButton, { onClick: onToggleUserCard, "aria-label": "User menu", "aria-expanded": userCardOpen, "aria-haspopup": "true", className: isLoadingProfile ? 'loading' : undefined, children: !isLoadingProfile && renderAvatar() }), userCardOpen && (_jsxs(UserCard, { onClick: e => e.stopPropagation(), children: [_jsx(UserCardAvatarContainer, { children: bodyUrl ? _jsx(UserCardAvatarBody, { src: bodyUrl, alt: "" }) : null }), _jsxs(UserCardMenu, { children: [_jsxs("div", { style: { paddingLeft: 16, paddingBottom: 8, display: 'flex', flexDirection: 'column', gap: 4 }, children: [_jsx(UserCardName, { title: userName, children: userName }), _jsxs("div", { style: { display: 'flex', flexDirection: 'column' }, children: [_jsx(UserCardAddressLabel, { children: i18n.walletAddress }), _jsxs(UserCardAddress, { children: [addressCopied ? i18n.addressCopied : shortAddress, _jsx(UserCardCopyButton, { onClick: copyAddress, "aria-label": "Copy address", children: _jsx(CopyIcon, {}) })] })] }), renderBalanceAndChain()] }), _jsx(UserCardDivider, {}), renderMenuItems()] })] }))] }), userCardOpen && (_jsxs(MobileUserCard, { "data-mobile-user-card": true, onClick: e => e.stopPropagation(), children: [_jsxs(MobileUserCardTop, { children: [_jsx(MobileUserCardAvatar, { className: isLoadingProfile ? 'loading' : undefined, children: !isLoadingProfile && renderAvatar() }), _jsxs(MobileUserCardInfo, { children: [_jsx(MobileUserCardName, { title: userName, children: userName }), _jsx(MobileUserCardAddressLabel, { children: i18n.walletAddress }), _jsxs(MobileUserCardAddress, { children: [addressCopied ? i18n.addressCopied : shortAddress, _jsx(MobileUserCardCopyButton, { onClick: copyAddress, "aria-label": "Copy address", children: _jsx(CopyIcon, {}) })] }), renderBalanceAndChain()] })] }), _jsx(UserCardDivider, {}), _jsx(UserCardMenu, { children: renderMenuItems() })] }))] }));
|
|
103
|
+
});
|
|
104
|
+
UserCardPanel.displayName = 'UserCardPanel';
|
|
105
|
+
export { UserCardPanel };
|
|
106
|
+
//# sourceMappingURL=UserCardPanel.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"UserCardPanel.js","sourceRoot":"","sources":["../../../src/components/Navbar/UserCardPanel.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,IAAI,EAAE,WAAW,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAA;AAC9D,OAAO,EAAE,OAAO,EAAE,MAAM,iCAAiC,CAAA;AACzD,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAA;AAC/C,OAAO,EACL,WAAW,EACX,SAAS,EACT,eAAe,EACf,QAAQ,EACR,OAAO,EACP,UAAU,EACV,iBAAiB,EACjB,mBAAmB,EACnB,YAAY,EACZ,eAAe,EACf,YAAY,EACb,MAAM,SAAS,CAAA;AAChB,OAAO,EAAE,gBAAgB,EAAE,MAAM,mBAAmB,CAAA;AAEpD,OAAO,EACL,YAAY,EACZ,WAAW,EACX,kBAAkB,EAClB,WAAW,EACX,eAAe,EACf,kBAAkB,EAClB,oBAAoB,EACpB,aAAa,EACb,oBAAoB,EACpB,gBAAgB,EAChB,iBAAiB,EACjB,cAAc,EACd,qBAAqB,EACrB,0BAA0B,EAC1B,oBAAoB,EACpB,wBAAwB,EACxB,kBAAkB,EAClB,kBAAkB,EAClB,iBAAiB,EACjB,QAAQ,EACR,eAAe,EACf,oBAAoB,EACpB,kBAAkB,EAClB,uBAAuB,EACvB,oBAAoB,EACpB,kBAAkB,EAClB,eAAe,EACf,cAAc,EACd,YAAY,EACZ,gBAAgB,EAChB,YAAY,EACZ,eAAe,EAChB,MAAM,wBAAwB,CAAA;AAI/B,MAAM,QAAQ,GAA2C;IACvD,OAAO,EAAE,WAAW;IACpB,QAAQ,EAAE,YAAY;IACtB,QAAQ,EAAE,YAAY;IACtB,QAAQ,EAAE,eAAe;CAC1B,CAAA;AAED,MAAM,aAAa,GAAG,iDAAiD,CAAA;AAEvE,SAAS,iBAAiB,CAAC,IAAwB;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AE,gBAAgB,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,SAAS,YACtE,CAAC,gBAAgB,IAAI,YAAY,EAAE,GACf,EACvB,MAAC,kBAAkB,eACjB,KAAC,kBAAkB,IAAC,KAAK,EAAE,QAAQ,YAAG,QAAQ,GAAsB,EACpE,KAAC,0BAA0B,cAAE,IAAI,CAAC,aAAa,GAA8B,EAC7E,MAAC,qBAAqB,eACnB,aAAa,CAAC,CAAC,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC,CAAC,YAAY,EAClD,KAAC,wBAAwB,IAAC,OAAO,EAAE,WAAW,gBAAa,cAAc,YACvE,KAAC,QAAQ,KAAG,GACa,IACL,EACvB,qBAAqB,EAAE,IACL,IACH,EACpB,KAAC,eAAe,KAAG,EACnB,KAAC,YAAY,cAAE,eAAe,EAAE,GAAgB,IACjC,CAClB,IACA,CACJ,CAAA;AACH,CAAC,CAAC,CAAA;AAEF,aAAa,CAAC,WAAW,GAAG,eAAe,CAAA;AAE3C,OAAO,EAAE,aAAa,EAAE,CAAA"}
|
|
@@ -0,0 +1,133 @@
|
|
|
1
|
+
declare const AvatarButton: import("@emotion/styled").StyledComponent<{
|
|
2
|
+
theme?: import("@emotion/react").Theme;
|
|
3
|
+
as?: React.ElementType;
|
|
4
|
+
}, import("react").DetailedHTMLProps<import("react").ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, {}>;
|
|
5
|
+
declare const AvatarImage: import("@emotion/styled").StyledComponent<{
|
|
6
|
+
theme?: import("@emotion/react").Theme;
|
|
7
|
+
as?: React.ElementType;
|
|
8
|
+
}, import("react").DetailedHTMLProps<import("react").ImgHTMLAttributes<HTMLImageElement>, HTMLImageElement>, {}>;
|
|
9
|
+
declare const UserCardWrapper: import("@emotion/styled").StyledComponent<{
|
|
10
|
+
theme?: import("@emotion/react").Theme;
|
|
11
|
+
as?: React.ElementType;
|
|
12
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
13
|
+
declare const UserCard: import("@emotion/styled").StyledComponent<{
|
|
14
|
+
theme?: import("@emotion/react").Theme;
|
|
15
|
+
as?: React.ElementType;
|
|
16
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
17
|
+
declare const UserCardAvatarContainer: import("@emotion/styled").StyledComponent<{
|
|
18
|
+
theme?: import("@emotion/react").Theme;
|
|
19
|
+
as?: React.ElementType;
|
|
20
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
21
|
+
declare const UserCardAvatarBody: import("@emotion/styled").StyledComponent<{
|
|
22
|
+
theme?: import("@emotion/react").Theme;
|
|
23
|
+
as?: React.ElementType;
|
|
24
|
+
}, import("react").DetailedHTMLProps<import("react").ImgHTMLAttributes<HTMLImageElement>, HTMLImageElement>, {}>;
|
|
25
|
+
declare const UserCardMenu: import("@emotion/styled").StyledComponent<{
|
|
26
|
+
theme?: import("@emotion/react").Theme;
|
|
27
|
+
as?: React.ElementType;
|
|
28
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
29
|
+
declare const UserCardName: import("@emotion/styled").StyledComponent<{
|
|
30
|
+
theme?: import("@emotion/react").Theme;
|
|
31
|
+
as?: React.ElementType;
|
|
32
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
|
|
33
|
+
declare const UserCardAddressLabel: import("@emotion/styled").StyledComponent<{
|
|
34
|
+
theme?: import("@emotion/react").Theme;
|
|
35
|
+
as?: React.ElementType;
|
|
36
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
|
|
37
|
+
declare const UserCardAddress: import("@emotion/styled").StyledComponent<{
|
|
38
|
+
theme?: import("@emotion/react").Theme;
|
|
39
|
+
as?: React.ElementType;
|
|
40
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
41
|
+
declare const UserCardCopyButton: import("@emotion/styled").StyledComponent<{
|
|
42
|
+
theme?: import("@emotion/react").Theme;
|
|
43
|
+
as?: React.ElementType;
|
|
44
|
+
}, import("react").DetailedHTMLProps<import("react").ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, {}>;
|
|
45
|
+
declare const UserCardMenuItem: import("@emotion/styled").StyledComponent<{
|
|
46
|
+
theme?: import("@emotion/react").Theme;
|
|
47
|
+
as?: React.ElementType;
|
|
48
|
+
}, import("react").DetailedHTMLProps<import("react").AnchorHTMLAttributes<HTMLAnchorElement>, HTMLAnchorElement>, {}>;
|
|
49
|
+
declare const UserCardDivider: import("@emotion/styled").StyledComponent<{
|
|
50
|
+
theme?: import("@emotion/react").Theme;
|
|
51
|
+
as?: React.ElementType;
|
|
52
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
53
|
+
declare const UserCardLogout: import("@emotion/styled").StyledComponent<{
|
|
54
|
+
theme?: import("@emotion/react").Theme;
|
|
55
|
+
as?: React.ElementType;
|
|
56
|
+
}, import("react").DetailedHTMLProps<import("react").ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, {}>;
|
|
57
|
+
declare const ChainOption: import("@emotion/styled").StyledComponent<{
|
|
58
|
+
theme?: import("@emotion/react").Theme;
|
|
59
|
+
as?: React.ElementType;
|
|
60
|
+
} & {
|
|
61
|
+
selected?: boolean;
|
|
62
|
+
}, import("react").DetailedHTMLProps<import("react").ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, {}>;
|
|
63
|
+
declare const MobileUserCard: import("@emotion/styled").StyledComponent<{
|
|
64
|
+
theme?: import("@emotion/react").Theme;
|
|
65
|
+
as?: React.ElementType;
|
|
66
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
67
|
+
declare const MobileUserCardTop: import("@emotion/styled").StyledComponent<{
|
|
68
|
+
theme?: import("@emotion/react").Theme;
|
|
69
|
+
as?: React.ElementType;
|
|
70
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
71
|
+
declare const MobileUserCardAvatar: import("@emotion/styled").StyledComponent<{
|
|
72
|
+
theme?: import("@emotion/react").Theme;
|
|
73
|
+
as?: React.ElementType;
|
|
74
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
75
|
+
declare const MobileUserCardInfo: import("@emotion/styled").StyledComponent<{
|
|
76
|
+
theme?: import("@emotion/react").Theme;
|
|
77
|
+
as?: React.ElementType;
|
|
78
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
79
|
+
declare const MobileUserCardName: import("@emotion/styled").StyledComponent<{
|
|
80
|
+
theme?: import("@emotion/react").Theme;
|
|
81
|
+
as?: React.ElementType;
|
|
82
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
|
|
83
|
+
declare const MobileUserCardAddressLabel: import("@emotion/styled").StyledComponent<{
|
|
84
|
+
theme?: import("@emotion/react").Theme;
|
|
85
|
+
as?: React.ElementType;
|
|
86
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
|
|
87
|
+
declare const MobileUserCardAddress: import("@emotion/styled").StyledComponent<{
|
|
88
|
+
theme?: import("@emotion/react").Theme;
|
|
89
|
+
as?: React.ElementType;
|
|
90
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
91
|
+
declare const MobileUserCardCopyButton: import("@emotion/styled").StyledComponent<{
|
|
92
|
+
theme?: import("@emotion/react").Theme;
|
|
93
|
+
as?: React.ElementType;
|
|
94
|
+
}, import("react").DetailedHTMLProps<import("react").ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, {}>;
|
|
95
|
+
declare const UserCardChainOptions: import("@emotion/styled").StyledComponent<{
|
|
96
|
+
theme?: import("@emotion/react").Theme;
|
|
97
|
+
as?: React.ElementType;
|
|
98
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
99
|
+
declare const BalanceAndChainRow: import("@emotion/styled").StyledComponent<{
|
|
100
|
+
theme?: import("@emotion/react").Theme;
|
|
101
|
+
as?: React.ElementType;
|
|
102
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
103
|
+
declare const ManaBalancesGroup: import("@emotion/styled").StyledComponent<{
|
|
104
|
+
theme?: import("@emotion/react").Theme;
|
|
105
|
+
as?: React.ElementType;
|
|
106
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
107
|
+
declare const ManaBalanceClickable: import("@emotion/styled").StyledComponent<{
|
|
108
|
+
theme?: import("@emotion/react").Theme;
|
|
109
|
+
as?: React.ElementType;
|
|
110
|
+
} & {
|
|
111
|
+
clickable?: boolean;
|
|
112
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
113
|
+
declare const ManaBalanceValue: import("@emotion/styled").StyledComponent<{
|
|
114
|
+
theme?: import("@emotion/react").Theme;
|
|
115
|
+
as?: React.ElementType;
|
|
116
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
|
|
117
|
+
declare const ChainPillContainer: import("@emotion/styled").StyledComponent<{
|
|
118
|
+
theme?: import("@emotion/react").Theme;
|
|
119
|
+
as?: React.ElementType;
|
|
120
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
121
|
+
declare const ChainPillButton: import("@emotion/styled").StyledComponent<{
|
|
122
|
+
theme?: import("@emotion/react").Theme;
|
|
123
|
+
as?: React.ElementType;
|
|
124
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
125
|
+
declare const ChainPillIconWrapper: import("@emotion/styled").StyledComponent<{
|
|
126
|
+
theme?: import("@emotion/react").Theme;
|
|
127
|
+
as?: React.ElementType;
|
|
128
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
129
|
+
declare const ChainPillText: import("@emotion/styled").StyledComponent<{
|
|
130
|
+
theme?: import("@emotion/react").Theme;
|
|
131
|
+
as?: React.ElementType;
|
|
132
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
|
|
133
|
+
export { AvatarButton, AvatarImage, BalanceAndChainRow, ChainOption, ChainPillButton, ChainPillContainer, ChainPillIconWrapper, ChainPillText, ManaBalanceClickable, ManaBalanceValue, ManaBalancesGroup, MobileUserCard, MobileUserCardAddress, MobileUserCardAddressLabel, MobileUserCardAvatar, MobileUserCardCopyButton, MobileUserCardInfo, MobileUserCardName, MobileUserCardTop, UserCard, UserCardAddress, UserCardAddressLabel, UserCardAvatarBody, UserCardAvatarContainer, UserCardChainOptions, UserCardCopyButton, UserCardDivider, UserCardLogout, UserCardMenu, UserCardMenuItem, UserCardName, UserCardWrapper };
|