import Image from "next/image"; import Link from "next/link"; import { vibeMeta } from "@/lib/vibe"; import type { Vibe } from "@/app/generated/prisma/enums"; interface UserCardProps { id: string; name: string; image: string | null; isVerifiedOrganizer: boolean; profile: { bio: string | null; city: string | null; interests: string[]; vibe: Vibe | null; } | null; } export function UserCard({ id, name, image, isVerifiedOrganizer, profile, }: UserCardProps) { const interests = profile?.interests ?? []; return (
{image ? ( ) : (
{name.charAt(0).toUpperCase()}
)}

{name}

{profile?.city && (

📍 {profile.city}

)}
{isVerifiedOrganizer && ( ✅ Organizer )} {profile?.vibe && ( {vibeMeta(profile.vibe).icon} {vibeMeta(profile.vibe).label} )}
{profile?.bio && (

{profile.bio}

)} {interests.length > 0 && (
{interests.slice(0, 5).map((tag) => ( #{tag} ))} {interests.length > 5 && ( +{interests.length - 5} )}
)} ); }