From f932a4c5a466512d494dcaa10a230e2452951f1e Mon Sep 17 00:00:00 2001 From: Pramod Mahajan Date: Fri, 27 Jun 2025 11:45:29 +0530 Subject: [PATCH] added condition for directory, for hide project dropdown --- src/components/Dashboard/Dashboard.jsx | 2 +- src/components/Layout/Header.jsx | 13 +++++++------ src/components/common/Breadcrumb.jsx | 4 ++-- 3 files changed, 10 insertions(+), 9 deletions(-) diff --git a/src/components/Dashboard/Dashboard.jsx b/src/components/Dashboard/Dashboard.jsx index 9f3e1908..8ca64981 100644 --- a/src/components/Dashboard/Dashboard.jsx +++ b/src/components/Dashboard/Dashboard.jsx @@ -17,7 +17,7 @@ const Dashboard = () => { const { tasksCardData } = useDashboardTasksCardData(); return ( -
+
{/* Projects Card */}
diff --git a/src/components/Layout/Header.jsx b/src/components/Layout/Header.jsx index b02b9e32..4d010d76 100644 --- a/src/components/Layout/Header.jsx +++ b/src/components/Layout/Header.jsx @@ -103,7 +103,8 @@ const Header = () => { }, [projectNames]); /** Check if current page id project details page */ - const isProjectPath = /^\/projects\/[a-f0-9-]{36}$/.test(location.pathname); + const isProjectPath = /^\/projects\/[a-f0-9-]{36}$/.test(location.pathname) + const isDirectoryPath = /^\/directory$/.test(location.pathname); const handler = useCallback( async (data) => { @@ -162,11 +163,11 @@ const Header = () => { > {projectNames?.length > 0 && (
- {!isProjectPath && ( + {(!isProjectPath && !isDirectoryPath) && ( <>