diff --git a/frontend/src/components/NavbarSignedIn.tsx b/frontend/src/components/NavbarSignedIn.tsx index bf2f4ab..a4b64bb 100644 --- a/frontend/src/components/NavbarSignedIn.tsx +++ b/frontend/src/components/NavbarSignedIn.tsx @@ -19,16 +19,15 @@ import { useNavigate, Link as ReactLink } from "react-router-dom"; const NavLink = ({ children, - href = "#", + handleClick, }: { children: ReactNode; - href?: string; + handleClick: () => void; }) => ( {children} @@ -59,6 +59,14 @@ const NavbarSignedIn = ({ stateVariable, updateState }: Props) => { navigate("/profile"); }; + const handleGroupsClick = () => { + navigate("/groups"); + } + + const handleItemsClick = () => { + navigate("/items"); + } + return ( { - My Items - My Groups + My Items + My Groups { + const navigate = useNavigate(); + + const handleGroupsClick = () => { + navigate("/groups"); + }; + return ( @@ -53,6 +60,7 @@ const ItemsPage: React.FC = () => {