Hide study artifact card when artifact is not enabled

This commit is contained in:
gen740
2023-11-17 14:53:56 +09:00
parent dd916938df
commit 9d7e10759e
+20 -20
View File
@@ -172,31 +172,31 @@ export const StudyHistory: FC<{ studyId: number }> = ({ studyId }) => {
</Grid2>
</Grid2>
<Grid2 container spacing={2} sx={{ padding: theme.spacing(0, 2) }}>
<Grid2 xs={6}>
<Card>
<CardContent
sx={{
display: "flex",
flexDirection: "column",
}}
>
<Typography
variant="h6"
{artifactEnabled && studyDetail !== null && (
<Grid2 container spacing={2} sx={{ padding: theme.spacing(0, 2) }}>
<Grid2 xs={6}>
<Card>
<CardContent
sx={{
margin: "1em 0",
fontWeight: theme.typography.fontWeightBold,
display: "flex",
flexDirection: "column",
}}
>
Study Artifacts
</Typography>
{artifactEnabled && studyDetail !== null && (
<Typography
variant="h6"
sx={{
margin: "1em 0",
fontWeight: theme.typography.fontWeightBold,
}}
>
Study Artifacts
</Typography>
<StudyArtifactCards study={studyDetail} />
)}
</CardContent>
</Card>
</CardContent>
</Card>
</Grid2>
</Grid2>
</Grid2>
)}
</Box>
)
}