"use client"; import { usePathname } from "next/navigation"; import Link from "next/link"; import * as DropdownMenu from "@radix-ui/react-dropdown-menu"; import { useLoginModal } from "@/app/LoginModalContext"; import { logout } from "@/auth/actions"; import "./UserMenu.css"; interface UserMenuClientProps { user: { handle: string; avatar?: string; } | null; } export function UserMenuClient({ user }: UserMenuClientProps) { const { openLoginModal } = useLoginModal(); const pathname = usePathname(); if (!user) { return ( ); } return ( profile logout(pathname)}> log out ); }