Skip to content

Commit

Permalink
fix: Ensure left border is always draggable
Browse files Browse the repository at this point in the history
As per the feedback here, the left border of the app wasn't draggable when multiple sites were listed in the sidebar: #82 (comment)

This commit addresses that.
  • Loading branch information
Siobhan committed May 7, 2024
1 parent b5db925 commit 0db7235
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
7 changes: 6 additions & 1 deletion src/components/main-sidebar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,12 @@ export default function MainSidebar( { className }: MainSidebarProps ) {
>
<SidebarToolbar />
<div className="flex flex-col h-full">
<div className="flex-1 overflow-y-auto sites-scrollbar">
<div
className={ cx(
'flex-1 overflow-y-auto sites-scrollbar app-no-drag-region',
isMac() ? 'ml-5' : 'ml-4'
) }
>
<SiteMenu />
</div>
<div className="flex flex-col gap-4 pt-5 border-white border-t border-opacity-10 app-no-drag-region">
Expand Down
4 changes: 2 additions & 2 deletions src/components/site-menu.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ function SiteItem( { site }: { site: SiteDetails } ) {
<li
className={ cx(
'flex flex-row min-w-[168px] h-8 hover:bg-[#ffffff0C] focus:bg-[#ffffff0C] rounded transition-all',
isMac() ? 'mx-5' : 'mx-4',
isMac() ? 'mr-5' : 'mr-4',
isSelected && 'bg-[#ffffff19] hover:bg-[#ffffff19] focus:bg-[#ffffff19]'
) }
>
Expand All @@ -127,7 +127,7 @@ export default function SiteMenu( { className }: SiteMenuProps ) {
scrollbarGutter: 'stable',
} }
className={ cx(
'w-full overflow-y-auto overflow-x-hidden flex flex-col gap-0.5 pb-4 app-no-drag-region',
'w-full overflow-y-auto overflow-x-hidden flex flex-col gap-0.5 pb-4',
className
) }
>
Expand Down

0 comments on commit 0db7235

Please sign in to comment.