'use client'
import type { ServiceNode } from '../types'
import { ARCHITECTURE_SERVICES } from '../data'
import { getArchTypeColor, getArchTypeLabel } from '../helpers'
interface ServiceDetailPanelProps {
service: ServiceNode
onClose: () => void
onSelectService: (service: ServiceNode) => void
}
export default function ServiceDetailPanel({ service, onClose, onSelectService }: ServiceDetailPanelProps) {
return (
{service.name}
{service.description}
Typ
{getArchTypeLabel(service.type)}
Technologie
{service.technology}
Port
{service.port || '-'}
Verbindungen
{service.connections?.length || 0} Services
{service.connections && service.connections.length > 0 && (
Verbunden mit:
{service.connections.map((connId) => {
const connService = ARCHITECTURE_SERVICES.find(s => s.id === connId)
if (!connService) return null
const colors = getArchTypeColor(connService.type)
return (
)
})}
)}
)
}