We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 4d88872 commit b041151Copy full SHA for b041151
src/components/posts/PostList.tsx
@@ -40,15 +40,19 @@ export const PostList = ({
40
<Grid item>
41
<Typography variant="h3">Posts</Typography>
42
</Grid>
43
- {canCreate && (
44
- <Grid item>
45
- <Tooltip title="Add Post">
46
- <Fab color="error" onClick={createPost}>
47
- <Add />
48
- </Fab>
49
- </Tooltip>
50
- </Grid>
51
- )}
+ <Grid item>
+ <Tooltip title="Add Post">
+ <Fab
+ sx={{
+ visibility: canCreate ? 'visible' : 'hidden',
+ }}
+ color="error"
+ onClick={createPost}
+ >
52
+ <Add />
53
+ </Fab>
54
+ </Tooltip>
55
+ </Grid>
56
57
<List
58
{...rest}
0 commit comments