✨ feat: user profile in navbar
This commit is contained in:
@ -2,8 +2,12 @@
|
||||
import Image from "next/image";
|
||||
import NavigationLink from "./NavigationLink";
|
||||
import SignIn from "./SignIn";
|
||||
import { useAuth } from "@/shared/contexts/AuthContext";
|
||||
import UserProfile from "./UserProfile";
|
||||
|
||||
const Navbar = () => {
|
||||
const { session } = useAuth();
|
||||
|
||||
return (
|
||||
<div className="absolute z-10 top-0 w-full h-16 flex items-center justify-between">
|
||||
<div className="flex items-center">
|
||||
@ -16,9 +20,7 @@ const Navbar = () => {
|
||||
/>
|
||||
<NavigationLink />
|
||||
</div>
|
||||
<div>
|
||||
<SignIn />
|
||||
</div>
|
||||
<div>{session?.user ? <UserProfile /> : <SignIn />}</div>
|
||||
</div>
|
||||
);
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user