// components/alerts/AlertTable.tsx
'use client';

import { Table, TableBody, TableCell, TableHead, TableHeader, TableRow } from '@/components/ui/table';

interface Alert {
  id: number;
  title: string;
  description: string;
}

const mockAlerts: Alert[] = [
  {
    id: 1,
    title: 'Manutenção Caminhão CAM001',
    description: 'Troca de óleo agendada para 10/05/2025.',
  },
  {
    id: 2,
    title: 'Seguro Pás Carregadeira',
    description: 'Renovar apólice antes de 20/05/2025.',
  },
];

export function AlertTable() {
  return (
    <div className="rounded-md border">
      <Table>
        <TableHeader>
          <TableRow>
            <TableHead className="w-[100px]">ID</TableHead>
            <TableHead>Título</TableHead>
            <TableHead>Descrição</TableHead>
          </TableRow>
        </TableHeader>
        <TableBody>
          {mockAlerts.map((alert) => (
            <TableRow key={alert.id}>
              <TableCell>{alert.id}</TableCell>
              <TableCell>{alert.title}</TableCell>
              <TableCell>{alert.description}</TableCell>
            </TableRow>
          ))}
        </TableBody>
      </Table>
    </div>
  );
}
