update details page to use new queries

This commit is contained in:
Alex Holliday committed 2025-03-19 12:15:04 -07:00
1 parent 9ac563bf8c
commit 3d71e7759b
11 files changed
+131 -81

No files matched your search

+4 -4
View File
@@ -8,10 +8,10 @@ import ConfigButton from "./ConfigButton";
import SkeletonLayout from "./skeleton";
import PropTypes from "prop-types";
const MonitorStatusHeader = ({ path, shouldRender = true, isAdmin, monitor }) => {
const MonitorStatusHeader = ({ path, isLoading = false, isAdmin, monitor }) => {
const theme = useTheme();
const { statusColor, statusMsg, determineState } = useUtils();
if (!shouldRender) {
const { statusColor, determineState } = useUtils();
if (isLoading) {
return <SkeletonLayout />;
}
@@ -48,7 +48,7 @@ const MonitorStatusHeader = ({ path, shouldRender = true, isAdmin, monitor }) =>
MonitorStatusHeader.propTypes = {
path: PropTypes.string.isRequired,
shouldRender: PropTypes.bool,
isLoading: PropTypes.bool,
isAdmin: PropTypes.bool,
monitor: PropTypes.object,
};
@@ -4,14 +4,14 @@ import SkeletonLayout from "./skeleton";
import PropTypes from "prop-types";
const MonitorTimeFrameHeader = ({
shouldRender = true,
isLoading = false,
hasDateRange = true,
dateRange,
setDateRange,
}) => {
const theme = useTheme();
if (!shouldRender) {
if (isLoading) {
return <SkeletonLayout />;
}
@@ -77,7 +77,7 @@ const MonitorTimeFrameHeader = ({
};
MonitorTimeFrameHeader.propTypes = {
shouldRender: PropTypes.bool,
isLoading: PropTypes.bool,
hasDateRange: PropTypes.bool,
dateRange: PropTypes.string,
setDateRange: PropTypes.func,