Skip to content

Commit d90401b

Browse files
committed
Improve UI
1 parent ce07461 commit d90401b

3 files changed

Lines changed: 29 additions & 8 deletions

File tree

components/AccountsList.tsx

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,13 @@ const styles: SXStyles = {
2222
plusButtonContainer: {
2323
display: "flex",
2424
alignItems: "center",
25-
gap: 2,
25+
gap: 3,
2626
},
2727
plusButtonContainerColumn: {
2828
flexDirection: "column",
2929
alignItems: "stretch",
30+
gap: 2,
31+
mt: 3,
3032
},
3133
footer: {
3234
lineHeight: 1.7,
@@ -96,8 +98,9 @@ export default function AccountsList({
9698
<PlusButton
9799
onClick={onUseAnyAccount}
98100
data-test="use-any-account-button"
101+
icon="arrow"
99102
>
100-
Use Existing Address (Fork Mode)
103+
Use Existing Address
101104
</PlusButton>
102105
)}
103106
<PlusButton

components/AnyAccountForm.tsx

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -124,10 +124,8 @@ export default function AnyAccountForm({
124124
<Box mb={4}>
125125
<ConnectedAppHeader
126126
info={false}
127-
title={"Use Existing Address (Fork Mode)"}
128-
description={
129-
"Authenticate as any address on the forked network."
130-
}
127+
title={"Use Existing Address"}
128+
description={"Authenticate as any address on the network."}
131129
flowAccountAddress={flowAccountAddress}
132130
avatarUrl={avatarUrl}
133131
/>

components/PlusButton.tsx

Lines changed: 22 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,17 +23,24 @@ const styles: SXStyles = {
2323
fontFamily: "inherit",
2424
fontWeight: "normal",
2525
},
26+
iconSecondary: {
27+
backgroundColor: "green",
28+
},
2629
}
2730

2831
export default function PlusButton({
2932
onClick,
3033
disabled,
3134
children,
35+
icon,
3236
}: {
3337
onClick?: (event: React.MouseEvent<HTMLElement>) => void
3438
disabled?: boolean
3539
children: React.ReactNode
40+
icon?: "plus" | "arrow"
3641
}) {
42+
const isArrow = icon === "arrow"
43+
3744
return (
3845
<Button
3946
variant="unstyled"
@@ -44,8 +51,21 @@ export default function PlusButton({
4451
disabled={disabled}
4552
data-test="plus-button"
4653
>
47-
<div sx={styles.icon}>
48-
<img src="/plus-icon.svg" />
54+
<div sx={{...styles.icon, ...(isArrow ? styles.iconSecondary : {})}}>
55+
{isArrow ? (
56+
<span
57+
sx={{
58+
fontSize: "30px",
59+
lineHeight: 1,
60+
fontWeight: "normal",
61+
color: "white",
62+
}}
63+
>
64+
65+
</span>
66+
) : (
67+
<img src="/plus-icon.svg" />
68+
)}
4969
</div>
5070
{children}
5171
</Button>

0 commit comments

Comments
 (0)