'use client' import Image from "next/image"; import {Button} from "@/components/ui/button"; import {LogIn, LogOut} from "lucide-react"; import {cn} from "@/lib/utils"; import {SITE_TITLE} from "@/config/kfpa.config"; import {TopMenuItem} from "@/config/menu.type"; import {usePathname} from "next/navigation"; interface HeaderProps { topMenus: TopMenuItem[]; userName: string; isAdmin: boolean; isAuthenticated: boolean; baseDateLabel: string; onNavigate: (path: string) => void; onLogin: () => void; onLogout: () => void; } const Header = ({ topMenus, userName, isAdmin, isAuthenticated, baseDateLabel, onNavigate, onLogin, onLogout, }: HeaderProps) => { const pathname = usePathname(); return (

{SITE_TITLE}

{isAdmin && ( <> {userName} )}
{baseDateLabel}
); } export default Header;