diff --git a/frontend/src/components/panels/DetailPanel.tsx b/frontend/src/components/panels/DetailPanel.tsx index b53a8ad..1152112 100644 --- a/frontend/src/components/panels/DetailPanel.tsx +++ b/frontend/src/components/panels/DetailPanel.tsx @@ -662,38 +662,41 @@ const CATEGORY_COLORS: Record = { function ServiceBadge({ svc, host, onEdit, onRemove }: { svc: ServiceInfo; host?: string; onEdit: () => void; onRemove: () => void }) { const url = getServiceUrl(svc, host) const color = CATEGORY_COLORS[svc.category ?? ''] ?? '#8b949e' + const hasPort = svc.port != null - const portLabel = hasPort ? String(svc.port) : '' + const portLabel = hasPort ? String(svc.port) : 'host' const pathLabel = svc.path?.trim() ? svc.path.trim() : '' return (
- - {url ? ( - e.stopPropagation()} - > - {svc.service_name} - - ) : ( - - {svc.service_name} - - )} -
+
+ + + {url ? ( + e.stopPropagation()} + > + {svc.service_name} + + ) : ( + + {svc.service_name} + + )} + {pathLabel && ( @@ -710,34 +713,38 @@ function ServiceBadge({ svc, host, onEdit, onRemove }: { svc: ServiceInfo; host? )} - {hasPort && ( - {portLabel}/{svc.protocol} - )} +
+ +
+ + {portLabel}/{svc.protocol} + + {url ? ( e.stopPropagation()} > ) : ( - + )} + +