Skip to content

Commit

Permalink
fix: menu toggle on desktop bug
Browse files Browse the repository at this point in the history
  • Loading branch information
patrickwebsdev committed Nov 8, 2024
1 parent 512419f commit c2fc0c1
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/components/layout/Sidebar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -254,7 +254,11 @@ export default function Sidebar({ isOpen, toggleAction }: SidebarProps) {

{/* User info and login */}
<div className="p-4">
<UserInfo toggleAction={toggleAction} />
<UserInfo
toggleAction={() => {
if (window.innerWidth < 768) toggleAction();
}}
/>
</div>

{/* Toggle button for desktop */}
Expand Down

0 comments on commit c2fc0c1

Please sign in to comment.