Skip to content

Commit

Permalink
Condense layout conditional
Browse files Browse the repository at this point in the history
  • Loading branch information
imnasnainaec committed Jul 12, 2024
1 parent 76d48c8 commit 4bdf9e6
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions src/components/ProjectScreen/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,13 @@ export default function ProjectScreen(): ReactElement {
dispatch(resetTree());
}, [dispatch]);

return isXs ? (
<Stack alignItems="center" spacing={2}>
<ChooseProject />
<CreateProject />
</Stack>
) : (
<Stack direction="row" justifyContent="center" spacing={2}>
return (
<Stack
{...(isXs
? { alignItems: "center" }
: { direction: "row", justifyContent: "center" })}
spacing={2}
>
<ChooseProject />
<CreateProject />
</Stack>
Expand Down

0 comments on commit 4bdf9e6

Please sign in to comment.