Added fallback UI when there are no incidents recorded
This commit is contained in:
1 parent
848ee60ca0
commit
f152f490e3
4 files changed
+26
-5
No files matched your search
@@ -107,7 +107,6 @@ const StepOne = ({ form, errors, onSubmit, onChange, onBack }) => {
|
||||
/>
|
||||
</form>
|
||||
<form noValidate spellCheck={false} onSubmit={onSubmit}>
|
||||
<Box my={theme.gap.ml}>
|
||||
<Field
|
||||
id="register-lastname-input"
|
||||
label="Surname"
|
||||
@@ -118,7 +117,6 @@ const StepOne = ({ form, errors, onSubmit, onChange, onBack }) => {
|
||||
onChange={onChange}
|
||||
error={errors.lastName}
|
||||
/>
|
||||
</Box>
|
||||
</form>
|
||||
</Box>
|
||||
<Stack direction="row" justifyContent="space-between">
|
||||
@@ -267,7 +265,6 @@ const StepThree = ({ form, errors, onSubmit, onChange, onBack }) => {
|
||||
/>
|
||||
</form>
|
||||
<form noValidate spellCheck={false} onSubmit={onSubmit}>
|
||||
<Box mt={theme.gap.ml}>
|
||||
<Field
|
||||
type="password"
|
||||
id="register-confirm-input"
|
||||
@@ -279,9 +276,8 @@ const StepThree = ({ form, errors, onSubmit, onChange, onBack }) => {
|
||||
onChange={onChange}
|
||||
error={errors.confirm}
|
||||
/>
|
||||
</Box>
|
||||
</form>
|
||||
<Stack gap={theme.gap.small} my={theme.gap.large}>
|
||||
<Stack gap={theme.gap.small} mb={theme.gap.large}>
|
||||
<Check
|
||||
text="Must be at least 8 characters long"
|
||||
variant={
|
||||
|
||||
@@ -135,6 +135,9 @@
|
||||
.auth .check span.MuiTypography-root {
|
||||
font-size: var(--env-var-font-size-medium);
|
||||
}
|
||||
.auth form + form {
|
||||
margin: var(--env-var-spacing-1-plus) 0;
|
||||
}
|
||||
|
||||
.auth > .MuiStack-root:nth-of-type(1) {
|
||||
height: var(--env-var-nav-bar-height);
|
||||
|
||||
@@ -9,6 +9,8 @@ import {
|
||||
Pagination,
|
||||
PaginationItem,
|
||||
Paper,
|
||||
Typography,
|
||||
Box,
|
||||
} from "@mui/material";
|
||||
|
||||
import ArrowBackRoundedIcon from "@mui/icons-material/ArrowBackRounded";
|
||||
@@ -104,6 +106,18 @@ const IncidentTable = ({ monitors, selectedMonitor, filter }) => {
|
||||
}
|
||||
|
||||
return (
|
||||
<>
|
||||
{checks?.length === 0 && selectedMonitor === "0" ? (
|
||||
<Box>
|
||||
<Typography textAlign="center">No incidents recorded yet.</Typography>
|
||||
</Box>
|
||||
) : checks?.length === 0 ? (
|
||||
<Box>
|
||||
<Typography textAlign="center">
|
||||
The monitor you have selected, has no recorded incidents yet.
|
||||
</Typography>
|
||||
</Box>
|
||||
) : (
|
||||
<>
|
||||
<TableContainer component={Paper}>
|
||||
<Table>
|
||||
@@ -141,6 +155,8 @@ const IncidentTable = ({ monitors, selectedMonitor, filter }) => {
|
||||
</TableContainer>
|
||||
{paginationComponent}
|
||||
</>
|
||||
)}
|
||||
</>
|
||||
);
|
||||
};
|
||||
|
||||
|
||||
@@ -17,6 +17,12 @@
|
||||
.incidents .MuiPagination-root {
|
||||
background-color: var(--env-var-color-8);
|
||||
}
|
||||
.incidents > .MuiBox-root {
|
||||
background-color: var(--env-var-color-8);
|
||||
border: solid 1px var(--env-var-color-6);
|
||||
border-radius: var(--env-var-radius-1);
|
||||
padding: 60px;
|
||||
}
|
||||
|
||||
/* remove later */
|
||||
.incidents .MuiSelect-select {
|
||||
|
||||
Reference in new issue
Block a user