feat: Add yellow warning range (50-80%) for infrastructure monitors

Fixes #2615
This commit is contained in:
vineet-channe
2025-08-07 20:35:24 +05:30
parent 1765bf7e55
commit 424df24bf3

View File

@@ -64,10 +64,14 @@ const CustomGauge = ({
const progressWithinRange = Math.max(MINIMUM_VALUE, Math.min(progress, MAXIMUM_VALUE));
const fillColor =
progressWithinRange > threshold
? theme.palette.error.lowContrast
: theme.palette.accent.main;
let fillColor;
if (progressWithinRange < 50) {
fillColor = theme.palette.success.main;
} else if (progressWithinRange < 80) {
fillColor = theme.palette.warning.lowContrast;
} else {
fillColor = theme.palette.error.lowContrast;
}
if (isLoading) {
return (