diff --git a/packages/extension-onboarding/src/assets/images/polygon-circle.png b/packages/extension-onboarding/src/assets/images/polygon-circle.png new file mode 100644 index 0000000000..e04a1b948a Binary files /dev/null and b/packages/extension-onboarding/src/assets/images/polygon-circle.png differ diff --git a/packages/extension-onboarding/src/components/NFTItem/NFTItem.style.ts b/packages/extension-onboarding/src/components/NFTItem/NFTItem.style.ts index d33f7ec871..9e99bd7bc2 100644 --- a/packages/extension-onboarding/src/components/NFTItem/NFTItem.style.ts +++ b/packages/extension-onboarding/src/components/NFTItem/NFTItem.style.ts @@ -1,6 +1,21 @@ import { makeStyles } from "@material-ui/core/styles"; export const useStyles = makeStyles((theme) => ({ - - + card: { + borderRadius: 8, + border: "1px solid #ECECEC", + padding: 0, + }, + nftName: { + fontFamily: "Space Grotesk", + fontWeight: 600, + fontSize: 14, + color: "rgba(35, 32, 57, 0.87)", + }, + nftTokenId: { + fontFamily: "Space Grotesk", + fontWeight: 600, + fontSize: 14, + color: "rgba(93, 90, 116, 0.8)", + }, })); diff --git a/packages/extension-onboarding/src/components/NFTItem/NFTItem.tsx b/packages/extension-onboarding/src/components/NFTItem/NFTItem.tsx index 41fa436cc6..bd6850d884 100644 --- a/packages/extension-onboarding/src/components/NFTItem/NFTItem.tsx +++ b/packages/extension-onboarding/src/components/NFTItem/NFTItem.tsx @@ -1,6 +1,6 @@ import { IEVMNFT } from "@snickerdoodlelabs/objects"; -import { useStyles } from "@extension-onboarding/components/BalanceItem/BalanceItem.style"; -import { Box } from "@material-ui/core"; +import { useStyles } from "@extension-onboarding/components/NFTItem/NFTItem.style"; +import { Box, Grid, Typography } from "@material-ui/core"; import React, { FC, useMemo } from "react"; export interface INFTItemProps { @@ -29,15 +29,26 @@ const NFTItem: FC = ({ item }: INFTItemProps) => { return ( <> {nftImages?.length ? ( - + + + + + {item?.name} + + + Token ID: {item?.tokenId} + + + - + ) : null} ); diff --git a/packages/extension-onboarding/src/pages/Onboarding/ViewAccountDetails/ViewAccountDetails.style.ts b/packages/extension-onboarding/src/pages/Onboarding/ViewAccountDetails/ViewAccountDetails.style.ts index ef253b5d8d..34b1ae4553 100644 --- a/packages/extension-onboarding/src/pages/Onboarding/ViewAccountDetails/ViewAccountDetails.style.ts +++ b/packages/extension-onboarding/src/pages/Onboarding/ViewAccountDetails/ViewAccountDetails.style.ts @@ -36,7 +36,7 @@ export const useStyles = makeStyles((theme) => ({ border: "1px solid #ECECEC", }, cardBackground2: { - background: "rgba(253, 243, 225, 0.5)", + background: "rgba(185, 182, 211, 0.2)", border: "1px solid #ECECEC", }, cardTokenText: { @@ -58,7 +58,7 @@ export const useStyles = makeStyles((theme) => ({ background: "none", }, selectChain: { - width: 220, + width: 240, height: 55, border: "1px solid #D9D9D9", borderRadius: 8, @@ -70,7 +70,7 @@ export const useStyles = makeStyles((theme) => ({ accountAddressText: { paddingLeft: "4px", - paddingTop: "10px", + paddingTop: "7px", fontFamily: "'Space Grotesk', sans-serif", fontWeight: 500, fontSize: "16px", @@ -87,5 +87,9 @@ export const useStyles = makeStyles((theme) => ({ fontSize: 22, fontWeight: 700, }, - + nftContainer: { + display: "flex", + marginTop: "16px", + gap: 10, + }, })); diff --git a/packages/extension-onboarding/src/pages/Onboarding/ViewAccountDetails/ViewAccountDetails.tsx b/packages/extension-onboarding/src/pages/Onboarding/ViewAccountDetails/ViewAccountDetails.tsx index 58cb28f91c..4758314628 100644 --- a/packages/extension-onboarding/src/pages/Onboarding/ViewAccountDetails/ViewAccountDetails.tsx +++ b/packages/extension-onboarding/src/pages/Onboarding/ViewAccountDetails/ViewAccountDetails.tsx @@ -1,6 +1,7 @@ import { Box, CircularProgress, + Grid, MenuItem, Select, Typography, @@ -11,6 +12,8 @@ import { useAppContext } from "@extension-onboarding/context/App"; import { useStyles } from "@extension-onboarding/pages/Onboarding/ViewAccountDetails/ViewAccountDetails.style"; import coinbaseSmall from "@extension-onboarding/assets/icons/coinbaseSmall.svg"; import ethereumCircle from "@extension-onboarding/assets/icons/ethereum-circle.svg"; +import avaxCircle from "@extension-onboarding/assets/images/avax-circle.png"; +import polygonCircle from "@extension-onboarding/assets/images/polygon-circle.png"; import metamaskLogo from "@extension-onboarding/assets/icons/metamaskSmall.svg"; import { EVMAccountAddress, @@ -51,7 +54,7 @@ const ViewAccountDetails: FC = () => { const [accountSelect, setAccountSelect] = useState( viewDetailsAccountAddress ?? linkedAccounts[0].accountAddress, ); - const [chainSelect, setChainSelect] = useState("ETH"); + const [chainSelect, setChainSelect] = useState("1"); useEffect(() => { initiliaze(); @@ -154,13 +157,63 @@ const ViewAccountDetails: FC = () => { value={chainSelect} onChange={handleChainChange} > - + - + - Ethereum + Ethereum Mainnet + + + + + + + + + + Ethereum Kovan + + + + + + + + + + Avalanche Fuji + + + + + + + + + + Avalanche Mainnet + + + + + + + + + + Polygon Mainnet + + + + + + + + + + Polygon Mumbai @@ -245,7 +298,7 @@ const ViewAccountDetails: FC = () => { width={580} height={536} borderRadius={8} - style={{ border: "1px solid #ECECEC" }} + border="1px solid #ECECEC" > Your Tokens @@ -260,13 +313,17 @@ const ViewAccountDetails: FC = () => { ) : ( accountBalances?.[accountSelect].map((balanceItem, index) => { - return ( - - ); + if (balanceItem.chainId.toString() === chainSelect) { + return ( + + ); + } else { + return null; + } }) )} @@ -278,20 +335,19 @@ const ViewAccountDetails: FC = () => { height="100%" borderRadius={8} ml={5} - style={{ border: "1px solid #ECECEC" }} + border="1px solid #ECECEC" > Your NFTs - + {accountNFTs?.[accountSelect]?.map((nftItem, index) => { - return ; + if (nftItem.chain.toString() === chainSelect) { + return ; + } else { + return null; + } })} - +