"use client"; import { useState, type ReactNode } from "react"; import { ChevronDown } from "lucide-react"; import { cn } from "@/lib/utils"; interface ResearchMapSectionProps { title: string; count?: number; defaultOpen?: boolean; collapsible?: boolean; children: ReactNode; className?: string; } export function ResearchMapSection({ title, count, defaultOpen = false, collapsible = true, children, className, }: ResearchMapSectionProps) { const [open, setOpen] = useState(defaultOpen || !collapsible); const label = count !== undefined ? `${title} ยท ${count}` : title; if (!collapsible) { return (
{label}
{children}
); } return (
{open &&
{children}
}
); } export function MapField({ label, children }: { label: string; children: ReactNode }) { return (

{label}

{children}
); }