Add disk device as third metric value

This commit is contained in:
antoplt committed 2025-11-18 12:06:22 +01:00
1 parent 7cb985116e
commit 98214ff578
2 files changed
+17 -2

No files matched your search

@@ -10,7 +10,7 @@ import { useTheme } from "@emotion/react";
import { useTranslation } from "react-i18next";
const Gauges = ({ isLoading = false, monitor }) => {
const { decimalToPercentage, formatBytes } = useHardwareUtils();
const { decimalToPercentage, formatBytes, formatDeviceName } = useHardwareUtils();
const theme = useTheme();
const { t } = useTranslation();
@@ -55,6 +55,8 @@ const Gauges = ({ isLoading = false, monitor }) => {
valueOne: formatBytes(disk.total_bytes - disk.free_bytes, true),
metricTwo: t("total"),
valueTwo: formatBytes(disk.total_bytes, true),
metricThree: t("device"),
valueThree: formatDeviceName(disk.device),
})),
];
@@ -74,6 +76,8 @@ const Gauges = ({ isLoading = false, monitor }) => {
valueOne={gauge.valueOne}
metricTwo={gauge.metricTwo}
valueTwo={gauge.valueTwo}
metricThree={gauge.metricThree}
valueThree={gauge.valueThree}
/>
);
})}