Merge pull request #1789 from bluewave-labs/fix/fe/maintenance-background
Fix Maintenance page layout issue
This commit is contained in:
1 file changed
+16
-30
@@ -42,23 +42,23 @@ const Maintenance = () => {
|
|||||||
fetchMaintenanceWindows();
|
fetchMaintenanceWindows();
|
||||||
}, [page, rowsPerPage, updateTrigger]);
|
}, [page, rowsPerPage, updateTrigger]);
|
||||||
|
|
||||||
|
if (maintenanceWindows.length === 0) {
|
||||||
return (
|
return (
|
||||||
<Box
|
<Fallback
|
||||||
className="maintenance table-container"
|
title="maintenance window"
|
||||||
sx={{
|
checks={[
|
||||||
':has(> [class*="fallback__"])': {
|
"Mark your maintenance periods",
|
||||||
position: "relative",
|
"Eliminate any misunderstandings",
|
||||||
border: 1,
|
"Stop sending alerts in maintenance windows",
|
||||||
borderColor: theme.palette.primary.lowContrast,
|
]}
|
||||||
borderRadius: theme.shape.borderRadius,
|
link="/maintenance/create"
|
||||||
borderStyle: "dashed",
|
isAdmin={isAdmin}
|
||||||
backgroundColor: theme.palette.primary.main,
|
/>
|
||||||
overflow: "hidden",
|
);
|
||||||
},
|
}
|
||||||
}}
|
|
||||||
>
|
return (
|
||||||
{maintenanceWindows.length > 0 && (
|
<Stack gap={theme.spacing(10)}>
|
||||||
<Stack gap={theme.spacing(8)}>
|
|
||||||
<Stack
|
<Stack
|
||||||
direction="row"
|
direction="row"
|
||||||
justifyContent="space-between"
|
justifyContent="space-between"
|
||||||
@@ -88,20 +88,6 @@ const Maintenance = () => {
|
|||||||
updateCallback={handleActionMenuDelete}
|
updateCallback={handleActionMenuDelete}
|
||||||
/>
|
/>
|
||||||
</Stack>
|
</Stack>
|
||||||
)}
|
|
||||||
{maintenanceWindows.length === 0 && (
|
|
||||||
<Fallback
|
|
||||||
title="maintenance window"
|
|
||||||
checks={[
|
|
||||||
"Mark your maintenance periods",
|
|
||||||
"Eliminate any misunderstandings",
|
|
||||||
"Stop sending alerts in maintenance windows",
|
|
||||||
]}
|
|
||||||
link="/maintenance/create"
|
|
||||||
isAdmin={isAdmin}
|
|
||||||
/>
|
|
||||||
)}
|
|
||||||
</Box>
|
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user