diff --git a/src/App.tsx b/src/App.tsx index 31cab99..f94373a 100644 --- a/src/App.tsx +++ b/src/App.tsx @@ -9,6 +9,7 @@ import Index from "./pages/Index"; import Auth from "./pages/Auth"; import NotFound from "./pages/NotFound"; import Dashboard from "./pages/Dashboard"; +import Profile from "./pages/Profile"; import Header from "./components/Header"; const queryClient = new QueryClient(); @@ -48,13 +49,16 @@ const AuthGuard = ({ children }: { children: React.ReactNode }) => { // App needs to be wrapped with BrowserRouter to use the AuthProvider with routing capabilities const AppContent = () => { + const location = useLocation(); + const isDashboard = location.pathname === '/dashboard'; + return ( <> -
-
+ {!isDashboard &&
} +
} /> { } /> + + + + } + /> {/* ADD ALL CUSTOM ROUTES ABOVE THE CATCH-ALL "*" ROUTE */} } /> diff --git a/src/components/Header.tsx b/src/components/Header.tsx index b913eea..67870a2 100644 --- a/src/components/Header.tsx +++ b/src/components/Header.tsx @@ -2,7 +2,7 @@ import { useState, useEffect } from 'react'; import { Link, useLocation } from 'react-router-dom'; import { Button } from "@/components/ui/button"; -import { ShieldCheck, Menu, X, User, LogOut } from 'lucide-react'; +import { ShieldCheck, Menu, X, User, LogOut, UserCircle } from 'lucide-react'; import { useAuth } from '@/contexts/AuthContext'; import { DropdownMenu, @@ -84,7 +84,10 @@ const Header = () => { Dashboard - Profile + + + Profile + signOut()} className="text-destructive"> @@ -129,7 +132,8 @@ const Header = () => { {user ? ( <> - setMobileMenuOpen(false)}> + setMobileMenuOpen(false)}> + Profile + + +
+ +
+ + + Edit Profile + + Update your personal information and company details + + +
+ +
+ +
+
+ +
+ +
+
+ +
+ +
+
+ +
+ +
+

+ Email address cannot be changed +

+
+ +
+ +
+
+ +
+ +
+
+ +
+ +
+
+ +
+ +
+
+
+ + + + +
+
+
+
+ + ); +}; + +export default Profile;