From 73181f9e33d21c78ff9a372004e81ac52e319f40 Mon Sep 17 00:00:00 2001 From: MacRimi Date: Sat, 25 Oct 2025 20:55:24 +0200 Subject: [PATCH] Update network-metrics.tsx --- AppImage/components/network-metrics.tsx | 33 ++++++++++++++++++++++--- 1 file changed, 30 insertions(+), 3 deletions(-) diff --git a/AppImage/components/network-metrics.tsx b/AppImage/components/network-metrics.tsx index 59e156f..6370e49 100644 --- a/AppImage/components/network-metrics.tsx +++ b/AppImage/components/network-metrics.tsx @@ -153,6 +153,7 @@ export function NetworkMetrics() { const [selectedInterface, setSelectedInterface] = useState(null) const [timeframe, setTimeframe] = useState<"hour" | "day" | "week" | "month" | "year">("day") + const [modalTimeframe, setModalTimeframe] = useState<"hour" | "day" | "week" | "month" | "year">("day") const [networkTotals, setNetworkTotals] = useState<{ received: number; sent: number }>({ received: 0, sent: 0 }) const { data: interfaceHistoricalData } = useSWR(`/api/node/metrics?timeframe=${timeframe}`, fetcher, { @@ -634,9 +635,23 @@ export function NetworkMetrics() { setSelectedInterface(null)}> - - - {selectedInterface?.name} - Interface Details + +
+ + {selectedInterface?.name} - Interface Details +
+
@@ -832,6 +847,18 @@ export function NetworkMetrics() { + {/* Network Traffic Chart for the selected interface */} +
+

Network Traffic History

+
+ {}} + /> +
+
+ {/* Bond Information */} {selectedInterface.type === "bond" && selectedInterface.bond_slaves && (