@@ -1,6 +1,6 @@
11import React, { useState } from 'react';
22import * as ob from 'urbit-ob';
3−import { Icon, Row } from '@tlon/indigo-react';
3+import { Icon, Row, Box } from '@tlon/indigo-react';
44import { Just } from 'folktale/maybe';
55
66import Sigil from 'components/Sigil';
@@ -14,6 +14,7 @@ import CopiableAddressWrap from 'components/copiable/CopiableAddressWrap';
1414import Dropdown from './Dropdown';
1515
1616import './AccountsDropdown.scss';
17+import { abbreviateAddress } from 'lib/utils/address';
1718
1819const AccountsDropdown = () => {
1920 const [open, setOpen] = useState<boolean>(false);
@@ -30,8 +31,7 @@ const AccountsDropdown = () => {
3031 ) || [];
3132
3233 const currentAddress = walletInfo?.wallet?.value?.address || '';
33− const addressLeadingFive = currentAddress.slice(0, 5);
34− const displayAddress = `${addressLeadingFive}...${currentAddress.slice(-4)}`;
34+ const displayAddress = abbreviateAddress(currentAddress);
3535
3636 const selectPoint = (point: number) => () => {
3737 setPointCursor(Just(point));
@@ -49,13 +49,13 @@ const AccountsDropdown = () => {
4949 <Dropdown
5050 className="accounts-dropdown"
5151 open={open}
52− value={addressLeadingFive}
52+ value={displayAddress}
5353 toggleOpen={() => setOpen(!open)}>
5454 <CopiableAddressWrap className="current-address">
5555 {displayAddress}
5656 </CopiableAddressWrap>
57− <div className="divider" />
58− <div className="points">
57+ <Box className="divider" />
58+ <Box className="points">
5959 {points.map((point: number) => {
6060 const patp = ob.patp(point);
6161
@@ -64,20 +64,20 @@ const AccountsDropdown = () => {
6464 className="entry"
6565 onClick={selectPoint(point)}
6666 key={`point-${point}`}>
67− <div>{patp}</div>
67+ <Box>{patp}</Box>
6868 <Row>
6969 <LayerIndicator layer={1} size="md" />
70− <div className="sigil">
70+ <Box className="sigil">
7171 <Sigil patp={patp} size={1} colors={['#000000', '#FFFFFF']} />
72− </div>
72+ </Box>
7373 </Row>
7474 </Row>
7575 );
7676 })}
77− </div>
78− <div className="divider" />
77+ </Box>
78+ <Box className="divider" />
7979 <Row className="entry" onClick={goToMigrate}>
80− <div>Migrate</div>
80+ <Box>Migrate</Box>
8181 <Row className="layer-migration">
8282 <LayerIndicator layer={1} size="sm" />
8383 <Icon icon="ArrowEast" />
@@ -86,12 +86,12 @@ const AccountsDropdown = () => {
8686 </Row>
8787 {canBitcoin && (
8888 <Row className="entry" onClick={goToBitcoin}>
89− <div>Bitcoin</div>
89+ <Box>Bitcoin</Box>
9090 <Icon icon="Bitcoin" />
9191 </Row>
9292 )}
9393 <Row className="entry" onClick={onLogout}>
94− <div>Logout</div>
94+ <Box>Logout</Box>
9595 <Icon icon="LogOut" />
9696 </Row>
9797 </Dropdown>