Skip to content

Commit

Permalink
#11 Avoid duplicate code for hiding sidebar
Browse files Browse the repository at this point in the history
  • Loading branch information
tina-e committed Aug 15, 2022
1 parent d78a88c commit 0888913
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/components/SidebarHeader.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,9 @@ export const SidebarHeader = () => {
</Button>
</div>

<div className={sidebarOpen ? "flex flex-row gap-2 w-[1h]" : "flex flex-row gap-2 w-[1h] hidden"}>
<div className={cx("flex flex-row gap-2", {
"hidden": !sidebarOpen,
})}>
<Button bgColor={isNotesActive ? "bg-offWhite" : "transparent"}
size="sm"
textColor="font-bold text-darkGrey"
Expand Down

0 comments on commit 0888913

Please sign in to comment.