"use client"; import type { ReactNode } from "react"; import { Link } from "@/i18n/navigation"; import { mediaUrl } from "@/app/lib/media"; import type { DatingProfile } from "../types"; interface LikesPanelProps { likes: DatingProfile[]; mutual: DatingProfile[]; formatTime: (value?: string) => string; t: (key: string) => string; onSelectProfile?: (profile: DatingProfile) => void; onLikeBack?: (profile: DatingProfile) => void; likingBackId?: string | null; } function ProfileRow({ profile, timeLabel, badge, onSelect, action, }: { profile: DatingProfile; timeLabel: string; badge?: string; onSelect?: () => void; action?: ReactNode; }) { const className = "flex w-full items-center gap-3 rounded-xl border border-gray-100 bg-white p-3 text-left shadow-sm transition-shadow hover:shadow-md dark:border-gray-800 dark:bg-gray-900"; const content = ( <> {profile.name}

{profile.name}

📍 {profile.location}

{badge ? ( {badge} ) : null}
{action} {timeLabel}
); if (onSelect) { return ( ); } return
{content}
; } export default function LikesPanel({ likes, mutual, formatTime, t, onSelectProfile, onLikeBack, likingBackId, }: LikesPanelProps) { return (

{t("title")} 💕

{t("likedYou")}

{likes.length > 0 ? ( {likes.length} ) : null}
{likes.length ? ( likes.map((profile) => ( onSelectProfile?.(profile)} action={ onLikeBack ? ( ) : null } /> )) ) : (
{t("noLikesYet")}
)}

{t("mutualTitle")}

{t("mutualSubtitle")}

{mutual.length > 0 ? ( {mutual.length} ) : null}
{mutual.length ? ( mutual.map((profile) => profile.conversationId ? ( ) : ( onSelectProfile?.(profile)} /> ) ) ) : (
{t("noMutualYet")}
)}
{mutual.length > 0 ? ( {t("goMessages")} ) : null}
); }