'use client'; import { Download, Eye, Pencil, Play, Trash2 } from 'lucide-react'; import { useTranslations } from 'next-intl'; import { Badge } from '@/components/ui/badge'; import { Button } from '@/components/ui/button'; import { Table, TableBody, TableCell, TableHead, TableHeader, TableRow, } from '@/components/ui/table'; import type { WAFIPGroup, WAFIPGroupType } from '@/lib/services/openflare'; import { formatDateTime } from '@/lib/utils'; interface IPGroupsTableProps { groups: WAFIPGroup[]; syncingId: number | null; onView: (group: WAFIPGroup) => void; onEdit: (group: WAFIPGroup) => void; onDelete: (group: WAFIPGroup) => void; onSync: (group: WAFIPGroup) => void; onTest: (group: WAFIPGroup) => void; } export function IPGroupsTable({ groups, syncingId, onView, onEdit, onDelete, onSync, onTest, }: IPGroupsTableProps) { const t = useTranslations('ipGroups'); const typeLabel = (type: WAFIPGroupType) => t(`types.${type}`); return (