Skip to content

Commit

Permalink
section padding update (#288)
Browse files Browse the repository at this point in the history
  • Loading branch information
chinmehta committed Nov 14, 2023
1 parent 241e24a commit 56669f7
Showing 1 changed file with 32 additions and 32 deletions.
64 changes: 32 additions & 32 deletions packages/sections/src/evidence/OTValidation/Body.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -29,15 +29,12 @@ const useStyles = makeStyles(theme => ({
paddingBottom: "1rem",
borderBottom: `1px solid ${theme.palette.grey[300]}`,
},
hypotesisLegend: {
marginBottom: "1rem",
},
bold: {
fontWeight: 700,
},
// hypothesis status classes
hsLegendChip: {
width: "32px",
width: theme.spacing(4),
},
hsGreen: {
backgroundColor: "#407253 !important", // same as PPP green
Expand Down Expand Up @@ -314,35 +311,38 @@ function Body({ id, label, entity }) {
</Typography>

{/** LEGEND */}
<div className={classes.hypotesisLegend}>
<Grid container spacing={4} direction="row">
{hypothesesStatus.map(hs => (
<Grid item key={hs.status}>
<Grid container spacing={1} alignItems="center">
<Grid item>
<Chip className={classNames(classes.hsLegendChip, classes[hs.styles])} />
</Grid>
<Grid item>
<Typography variant="caption" display="block">
<span className={classes.bold}>
{hs.expected ? "Expected" : "Not expected"}
</span>{" "}
in OTAR primary project
</Typography>
<Typography variant="caption" display="block">
<span className={classes.bold}>
{hs.observed ? "Observed" : "Not observed"}
</span>{" "}
in OTVL
</Typography>
</Grid>
</Grid>
</Grid>
))}
</Grid>
</div>
<Box
sx={{
mb: theme => theme.spacing(2),
display: "flex",
flexDirection: "row",
flexWrap: "wrap",
}}
>
{hypothesesStatus.map(hs => (
<Box
key={hs.status}
sx={{ display: "flex", flexDirection: "row", alignItems: "center" }}
>
<Chip className={classNames(classes.hsLegendChip, classes[hs.styles])} />
<Box sx={{ p: theme => `0 ${theme.spacing(3)} 0 ${theme.spacing(1)}` }}>
<Box sx={{ display: "flex", flexDirection: "row" }}>
<Typography variant="caption">
<b>{hs.expected ? "Expected" : "Not expected"}</b> in OTAR primary project
</Typography>
</Box>
<Box sx={{ display: "flex", flexDirection: "row" }}>
<Typography variant="caption">
<b>{hs.observed ? "Observed" : "Not observed"} </b>
in OTVL
</Typography>
</Box>
</Box>
</Box>
))}
</Box>

{/** CHIPLIST */}
{/** CHIP LIST */}
<ChipList items={hypothesis} />
</Box>

Expand Down

0 comments on commit 56669f7

Please sign in to comment.