'use client'; import { Card, CardContent, CardHeader, CardTitle } from '@/components/ui/card'; import { Button } from '@/components/ui/button'; import { Badge } from '@/components/ui/badge'; import { Plus, FileText, CheckCircle2 } from 'lucide-react'; import { FHIR_STATUS_LABELS, type FhirCarePlanStatus } from '@/lib/types/behandelplan'; interface CarePlanSummary { id: string; title: string; status: string; version: number | null; created_at: string | null; published_at: string | null; } interface BehandelplanListProps { plans: CarePlanSummary[]; selectedPlanId: string | null; onSelectPlan: (planId: string) => void; onCreateNew: () => void; isCreating?: boolean; } export function BehandelplanList({ plans, selectedPlanId, onSelectPlan, onCreateNew, isCreating = false, }: BehandelplanListProps) { return (
Behandelplannen ({plans.length})
{plans.length === 0 ? (

Nog geen behandelplannen aangemaakt

) : (
{plans.map((plan) => { const isSelected = plan.id === selectedPlanId; const statusInfo = FHIR_STATUS_LABELS[plan.status as FhirCarePlanStatus] || { label: plan.status, color: '#6b7280', }; const isActive = plan.status === 'active'; return ( ); })}
)}
); }