'use client' import React from 'react' import type { SecurityItem } from '../_hooks/useSecurityBacklog' export function SecurityItemCard({ item, onEdit, onDelete, onStatusChange, }: { item: SecurityItem onEdit: (item: SecurityItem) => void onDelete: (id: string) => void onStatusChange: (id: string, status: string) => void }) { const typeLabels = { vulnerability: 'Schwachstelle', misconfiguration: 'Fehlkonfiguration', compliance: 'Compliance', hardening: 'Haertung', } const typeColors = { vulnerability: 'bg-red-100 text-red-700', misconfiguration: 'bg-orange-100 text-orange-700', compliance: 'bg-purple-100 text-purple-700', hardening: 'bg-blue-100 text-blue-700', } const severityColors = { critical: 'bg-red-500 text-white', high: 'bg-orange-500 text-white', medium: 'bg-yellow-500 text-white', low: 'bg-green-500 text-white', } const statusColors = { open: 'bg-blue-100 text-blue-700', 'in-progress': 'bg-yellow-100 text-yellow-700', resolved: 'bg-green-100 text-green-700', 'accepted-risk': 'bg-gray-100 text-gray-600', } const statusLabels = { open: 'Offen', 'in-progress': 'In Bearbeitung', resolved: 'Behoben', 'accepted-risk': 'Akzeptiert', } const isOverdue = item.due_date && new Date(item.due_date) < new Date() && item.status !== 'resolved' return (
{item.description}
}