import React from 'react' const typeConfig = { message: { icon: '💬', color: '#22d3ee', label: 'Message' }, tool: { icon: '🔧', color: '#a78bfa', label: 'Tool' }, knowledge: { icon: '🧠', color: '#34d399', label: 'Knowledge' }, lifecycle: { icon: '⚡', color: '#f472b6', label: 'Lifecycle' }, other: { icon: '📦', color: '#94a3b8', label: 'Event' } } export default function EventDetails({ event, onClose }) { if (!event) return null const config = typeConfig[event.type] || typeConfig.other return (
{/* Backdrop */}
{/* Modal */}
e.stopPropagation()} style={{ '--accent-color': config.color }} > {/* Header */}
{config.icon}

{config.label} Event

{event.timestamp.toLocaleString('de-DE')}

{/* Subject */}

{event.subject}

{/* Preview */} {event.preview && (

{event.preview}

)} {/* Raw Data */}
            {JSON.stringify(event.data, null, 2)}
          
{/* Accent line */}
) }