Merge remote-tracking branch 'upstream/develop' into feat/notification-modal

This commit is contained in:
Skorpios committed 2025-03-07 14:38:14 -08:00
commit 476c7608c4
4 files changed
+27 -31

No files matched your search

@@ -9,11 +9,6 @@ import PropTypes from "prop-types";
const StatBoxes = ({ monitor, lastUpdateTrigger }) => {
const theme = useTheme();
let timeSinceLastCheck = 0;
if (monitor?.lastCheckTimestamp) {
timeSinceLastCheck = Date.now() - monitor?.lastCheckTimestamp;
}
return (
<Stack
@@ -37,7 +32,7 @@ const StatBoxes = ({ monitor, lastUpdateTrigger }) => {
heading={"Last check"}
subHeading={
<LastUpdate
lastUpdateTime={timeSinceLastCheck}
lastUpdateTime={monitor?.timeSinceLastCheck}
suffix={"seconds ago"}
/>
}
@@ -59,7 +59,7 @@ const StatusHeader = ({ monitor, connectionStatus, elementToCapture }) => {
backgroundColor={theme.palette.successSecondary.lowContrast}
color={theme.palette.success.lowContrast}
>
Uptime: {(monitor.totalUptime * 100).toFixed(2)}%
Uptime: {(monitor.uptimePercentage * 100).toFixed(2)}%
</Typography>
</Stack>
<Typography
@@ -69,7 +69,7 @@ const StatusHeader = ({ monitor, connectionStatus, elementToCapture }) => {
Last updated{" "}
<LastUpdate
suffix={"seconds ago"}
lastUpdateTime={monitor.timeSinceLastCheck}
lastUpdateTime={monitor?.timeSinceLastCheck}
/>
</Typography>
</Stack>