import { useAuth } from "@/store/auth"; import { User } from "lucide-react"; import { useMemo, type FC } from "react"; export interface AvatarProps { iconSize?: number; className?: string; avatarId?: string; } const Avatar: FC = ({ iconSize = 32, className, avatarId }) => { const profile = useAuth((state) => state.profile); const avatar = useMemo( () => (avatarId !== undefined ? avatarId : profile?.profile_picture), [avatarId, profile?.profile_picture], ); return (
{avatar ? ( profile ) : ( )}
); }; export default Avatar;