import useAdmin from "@/hook/useAdmin";
function DotLine({ label, value }) {
return (
{label}
{" . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . "}
{value}
);
}
// ...existing imports...
export default function TeamInformation({ selectedTeamId, onClose }) {
const { getTeam, getTeamName, teams } = useAdmin();
const team = getTeam(selectedTeamId);
if (!team) return null;
function formatTime(seconds) {
if (!seconds || seconds < 0) return "—";
const m = Math.floor(seconds / 60);
const s = Math.floor(seconds % 60);
return `${m}:${s.toString().padStart(2, "0")}`;
}
// Determine image source
const imageSrc = team.photoUrl && team.photoUrl.trim() !== ""
? team.photoUrl
: "/images/missing_image.jpg";
return (
{team.captured ? "Capturée" : "En jeu"}
{team.name}
);
}