From 383ef68dea47e7f9ae28aba33f7eec85e3446194 Mon Sep 17 00:00:00 2001 From: Harman-singh-waraich Date: Tue, 4 Jun 2024 18:20:19 +0530 Subject: [PATCH] fix(web): disable-curation-policy-while-loading --- web/src/layout/Header/navbar/Explore.tsx | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/web/src/layout/Header/navbar/Explore.tsx b/web/src/layout/Header/navbar/Explore.tsx index 70f897b..e978a8a 100644 --- a/web/src/layout/Header/navbar/Explore.tsx +++ b/web/src/layout/Header/navbar/Explore.tsx @@ -57,11 +57,10 @@ const Explore: React.FC = () => { const links = useMemo( () => [ - { to: "/", text: "Home", isLoading: false }, + { to: "/", text: "Home" }, { - to: `${IPFS_GATEWAY}${mainCurate?.registry.policyURI}`, + to: isUndefined(mainCurate) ? "/" : `${IPFS_GATEWAY}${mainCurate.registry.policyURI}`, text: "Curation Policy", - isLoading: isUndefined(mainCurate), }, ], [mainCurate] @@ -70,9 +69,9 @@ const Explore: React.FC = () => { return ( Explore - {links.map(({ to, text, isLoading }) => ( + {links.map(({ to, text }) => ( - !isLoading && toggleIsOpen()} isActive={location.pathname.startsWith(to)}> + {text}