Skip to content

Commit b66e4c3

Browse files
authored
Fix container padding, text sizing (#84)
* fix: container padding * fix text sizing
1 parent ebc2e09 commit b66e4c3

3 files changed

Lines changed: 28 additions & 13 deletions

File tree

src/components/Containers.jsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ export const Container = styled.div`
3939
`}
4040
4141
${media.sm`
42-
padding: ${({ theme }) => theme.sizes.base};
42+
padding: ${({ theme }) => `${theme.sizes.x2l} ${theme.sizes.base}`};
4343
margin-bottom: ${({ theme }) => theme.sizes.x3l};
4444
`}
4545

src/components/Texts.jsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,13 +11,13 @@ export const H1 = styled.h1`
1111

1212
export const H3 = styled.h3`
1313
color: ${({ theme }) => theme.colors.textStrong};
14-
font-size: ${({ theme }) => theme.sizes.xl};
14+
font-size: ${({ theme }) => theme.fontSize.x2l};
1515
font-weight: ${({ theme }) => theme.weights.bold};
1616
line-height: 150%;
1717
margin-bottom: ${({ theme }) => theme.sizes.base};
1818
1919
${media.sm`
20-
font-size: ${({ theme }) => theme.sizes.base};
20+
font-size: ${({ theme }) => theme.fontSize.xl};
2121
margin-bottom: ${({ theme }) => theme.sizes.xl};
22-
`}
22+
`}
2323
`;

src/pages/Menu/index.jsx

Lines changed: 24 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -24,16 +24,27 @@ const Title = styled(H3)`
2424
margin-bottom: ${({ theme }) => theme.sizes.sm};
2525
`;
2626

27-
const Address = styled.p`
27+
const AddressButton = styled.button`
28+
display: block;
2829
width: 100%;
2930
text-align: center;
3031
font-size: ${({ theme }) => theme.sizes.sm};
31-
font-weight: ${({ theme }) => theme.weights.regular};
32+
font-weight: ${({ theme }) => theme.weights.highlight};
33+
font-family: inherit;
3234
line-height: 140%;
33-
margin-top: ${({ theme }) => theme.sizes.xs};
34-
margin-bottom: ${({ theme }) => theme.sizes.x2l};
35-
color: ${({ theme }) => theme.colors.textMuted};
35+
margin: ${({ theme }) => `${theme.sizes.xs} 0 ${theme.sizes.x2l}`};
36+
padding: 0;
37+
background: none;
38+
border: none;
39+
cursor: pointer;
40+
color: ${({ theme }) => theme.colors.primary};
3641
overflow-wrap: anywhere;
42+
text-decoration: underline;
43+
text-underline-offset: 0.2em;
44+
45+
&:hover {
46+
opacity: 0.85;
47+
}
3748
`;
3849

3950
const Button = styled(BaseButton)`
@@ -83,7 +94,7 @@ const Menu = () => {
8394
const { openMenu, account, passphrase, pin, network, chainId, legacy } =
8495
useContext(StoreContext);
8596

86-
const backupAddress = () => {
97+
const copyAddress = () => {
8798
copy(account.address);
8899
toast("Address copied into clipboard.");
89100
};
@@ -134,9 +145,13 @@ const Menu = () => {
134145
<QRCodeWrapper>
135146
<QRCodeSVG value={network + ":" + account.address} />
136147
</QRCodeWrapper>
137-
<Address>{account.address}</Address>
138-
139-
<Button onClick={backupAddress}>Address</Button>
148+
<AddressButton
149+
type="button"
150+
onClick={copyAddress}
151+
aria-label="Copy address"
152+
>
153+
{account.address}
154+
</AddressButton>
140155

141156
<Button onClick={onClickCredentials} $variant="danger">
142157
Credentials

0 commit comments

Comments
 (0)