diff --git a/frontend/src/NetworkMapUnifi.jsx b/frontend/src/NetworkMapUnifi.jsx index 0a3e191..526d41d 100644 --- a/frontend/src/NetworkMapUnifi.jsx +++ b/frontend/src/NetworkMapUnifi.jsx @@ -677,12 +677,14 @@ export default function NetworkMapUnifi({ const isStale = e.stale === true; const staleColor = UNIFI_WARNING; const textWidth = labelText.length * (compactOnly ? 5.9 : 6.2); - const iconWidth = isStale ? 14 : 0; + const staleDotRadius = 4.2; + const staleDotSpace = isStale ? 18 : 0; const minW = compactOnly ? 76 : LABEL_W; const maxW = compactOnly ? 160 : 210; - const w = Math.max(minW, Math.min(textWidth + pad * 2 + iconWidth, maxW)); - const h = LABEL_H; - const textX = x - (iconWidth / 2); + const w = Math.max(minW, Math.min(textWidth + pad * 2 + staleDotSpace, maxW)); + const h = isStale ? LABEL_H + 2 : LABEL_H; + const textAnchor = isStale ? 'start' : 'middle'; + const textX = isStale ? (x - w / 2 + pad + staleDotSpace) : x; return ( {isStale && ( @@ -708,7 +710,7 @@ export default function NetworkMapUnifi({