hide interfaces chart legend if interfaces.length > 15

This commit is contained in:
henrygd
2025-09-24 16:45:43 -04:00
parent 65897a8df6
commit 63bdac83a1

View File

@@ -27,7 +27,7 @@ export default memo(function NetworkSheet({
const [netInterfacesOpen, setNetInterfacesOpen] = useState(false)
const userSettings = useStore($userSettings)
const netInterfaces = useNetworkInterfaces(chartData.systemStats.at(-1)?.stats?.ni ?? {})
const showNetLegend = netInterfaces.length > 0
const showNetLegend = netInterfaces.length > 0 && netInterfaces.length < 15
const hasOpened = useRef(false)
if (netInterfacesOpen && !hasOpened.current) {