Skip to content

Commit bfffbcd

Browse files
committed
make app icon clickable
1 parent 3fd1046 commit bfffbcd

File tree

2 files changed

+40
-9
lines changed

2 files changed

+40
-9
lines changed

src/components/Simulator/screens/ConnectWeb3/Browser.tsx

Lines changed: 39 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,22 @@
11
import React from "react"
2-
import { Box, type FlexProps, Text, Icon, Flex, Grid } from "@chakra-ui/react"
2+
import {
3+
Box,
4+
type FlexProps,
5+
Text,
6+
Icon,
7+
Flex,
8+
Grid,
9+
Button,
10+
} from "@chakra-ui/react"
311
import { BsTriangle } from "react-icons/bs"
412
import { PiMagnifyingGlass } from "react-icons/pi"
513
import { IoEllipsisHorizontalSharp } from "react-icons/io5"
614
import { NFTSupportIcon } from "../../../icons/wallets/NFTSupportIcon"
715

8-
export const Browser: React.FC<FlexProps> = (props) => {
16+
interface IProps extends FlexProps {
17+
progressStepper: () => void
18+
}
19+
export const Browser: React.FC<IProps> = ({ progressStepper, ...props }) => {
920
return (
1021
<Flex direction="column" h="full" bg="body.light" {...props}>
1122
<Box bg="background.highlight" w="full" px={3} pt={9} pb={3}>
@@ -14,18 +25,38 @@ export const Browser: React.FC<FlexProps> = (props) => {
1425
</Box>
1526
</Box>
1627
<Box p={8} flex={1}>
17-
<Flex direction="column" alignItems="center" gap={2} w="fit-content">
28+
<Button
29+
variant="ghost"
30+
display="flex"
31+
flexDirection="column"
32+
alignItems="center"
33+
data-group
34+
onClick={progressStepper}
35+
gap={4}
36+
p={0}
37+
>
1838
<Grid
39+
bg="background.highlight"
40+
borderRadius="lg"
1941
placeItems="center"
2042
w={16}
2143
h={16}
22-
bg="background.highlight"
23-
borderRadius="lg"
44+
_groupHover={{ bg: "primary.hover" }}
2445
>
25-
<Icon as={NFTSupportIcon} fontSize="4xl" />
46+
<Icon as={NFTSupportIcon} color="white" w={10} h={10} />
2647
</Grid>
27-
<Text>NFT Market</Text>
28-
</Flex>
48+
<Box position="relative">
49+
<Text
50+
fontWeight="bold"
51+
color="primary.base"
52+
textAlign="center"
53+
m={0}
54+
_groupHover={{ color: "primary.hover" }}
55+
>
56+
NFT Market
57+
</Text>
58+
</Box>
59+
</Button>
2960
</Box>
3061
<Flex
3162
bg="background.highlight"

src/components/Simulator/screens/ConnectWeb3/index.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ export const ConnectWeb3: React.FC<PhoneScreenProps> = ({ nav, ctaLabel }) => {
4646
}
4747
return (
4848
<>
49-
{[0].includes(step) && <Browser />}
49+
{[0].includes(step) && <Browser progressStepper={progressStepper} />}
5050
{[1, 2, 3].includes(step) && (
5151
<Web3App displayUrl={EXAMPLE_APP_URL}>
5252
<Flex

0 commit comments

Comments
 (0)