From 371c6af634374fe65ae501490d991f698754d595 Mon Sep 17 00:00:00 2001 From: Lulox Date: Thu, 19 Sep 2024 22:32:05 -0300 Subject: [PATCH] Improved profile UI --- .../app/myProfile/_components/MyHoldings.tsx | 2 +- .../app/myProfile/_components/MyProfile.tsx | 78 ++++++++++--------- .../app/myProfile/_components/NFTCard.tsx | 14 +--- 3 files changed, 45 insertions(+), 49 deletions(-) diff --git a/packages/nextjs/app/myProfile/_components/MyHoldings.tsx b/packages/nextjs/app/myProfile/_components/MyHoldings.tsx index 38a3bb0..748c451 100644 --- a/packages/nextjs/app/myProfile/_components/MyHoldings.tsx +++ b/packages/nextjs/app/myProfile/_components/MyHoldings.tsx @@ -100,7 +100,7 @@ export const MyHoldings = () => {
No NFTs found
) : ( -
+
{myAllCollectibles.map(item => ( ))} diff --git a/packages/nextjs/app/myProfile/_components/MyProfile.tsx b/packages/nextjs/app/myProfile/_components/MyProfile.tsx index fd2af5d..40c454c 100644 --- a/packages/nextjs/app/myProfile/_components/MyProfile.tsx +++ b/packages/nextjs/app/myProfile/_components/MyProfile.tsx @@ -82,69 +82,60 @@ export const MyProfile: NextPage = () => { }; return ( -
-
- {!isConnected || isConnecting ? ( - - ) : ( -
- - -
- )} -
+
{/* User Profile Section */} -
- {/* Edit Profile Button */} - - - {/* Profile Picture */} -
+
+ {/* Profile Picture at the Top Left */} +
Profile
- {/* User Bio */} -
+ {/* User Info Section */} +

-unregistered user-

-
+
+
+
+
-

-no bio available-

+ {/* User Bio (centered) */} +
+

-no bio available-

+

-no URL provided-

- {/* USDC Balance and Logo */} -
- USDC Logo -

{usdcBalance ? Number(usdcBalance) / 1e6 : 0}

+ {/* Edit Profile Button at the Top Right */} + + + {/* USDC Balance and Logo at the Bottom Right */} +
+ + USDC Logo +

{usdcBalance ? Number(usdcBalance) / 1e6 : 0}

{/* Tabs Section */} -
+ {/* Content Based on Active Tab */} -
+
{activeTab === "your-nfts" && ( <> +
+ {!isConnected || isConnecting ? ( + + ) : ( +
+ +
+ )} +
)} diff --git a/packages/nextjs/app/myProfile/_components/NFTCard.tsx b/packages/nextjs/app/myProfile/_components/NFTCard.tsx index 8323621..ea4cb53 100644 --- a/packages/nextjs/app/myProfile/_components/NFTCard.tsx +++ b/packages/nextjs/app/myProfile/_components/NFTCard.tsx @@ -91,21 +91,15 @@ export const NFTCard = ({ nft }: { nft: Collectible }) => {