From 46c3f1b23470c6546631d39123135c6de474c537 Mon Sep 17 00:00:00 2001 From: Sundaram Kumar Jha Date: Mon, 13 Jul 2026 14:02:40 +0530 Subject: [PATCH] =?UTF-8?q?fix(frontend):=20mobile=20bottom=20nav=20?= =?UTF-8?q?=E2=80=94=20resync=20with=20main,=20fix=20modal=20z-index,=20ad?= =?UTF-8?q?d=20mobile=20org=20switcher?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Rebuild PR #771 changes on top of current main (branch was 336 commits behind) - layout.tsx: keep main's 48px navbar (mt-12), add pb-14 md:pb-0, make grid md-responsive - Sidebar.tsx: split desktop (hidden md:flex) and fixed mobile bottom nav - Fix Bugbot medium: mobile nav z-50 -> z-10 so HeadlessUI dialogs (z-10, portaled) render above it - Fix Bugbot high: add compact MobileOrgSwitcher (shown when >1 org), reusing OrgsMenu logic - Preserve aria-label/title a11y fix; add aria-current; add iOS safe-area padding --- frontend/app/[team]/layout.tsx | 6 +- frontend/components/layout/Sidebar.tsx | 173 ++++++++++++++++++++----- 2 files changed, 143 insertions(+), 36 deletions(-) diff --git a/frontend/app/[team]/layout.tsx b/frontend/app/[team]/layout.tsx index 4833fa98e..b9c1a09c8 100644 --- a/frontend/app/[team]/layout.tsx +++ b/frontend/app/[team]/layout.tsx @@ -105,8 +105,8 @@ export default function RootLayout({ return (
{showUnlockDialog && } @@ -114,7 +114,7 @@ export default function RootLayout({ {showNav && }
-
+
{children}
diff --git a/frontend/components/layout/Sidebar.tsx b/frontend/components/layout/Sidebar.tsx index 19ccd41c8..0e99e741c 100644 --- a/frontend/components/layout/Sidebar.tsx +++ b/frontend/components/layout/Sidebar.tsx @@ -224,6 +224,77 @@ const Sidebar = () => { ) } + // Compact organisation switcher for the mobile bottom nav. Reuses the same + // switching logic as the desktop OrgsMenu but renders as a single icon that + // opens a menu upward. Only shown when the user belongs to multiple orgs. + const MobileOrgSwitcher = () => ( + + {({ open }) => ( + <> + + + {activeOrganisation?.name?.[0]?.toUpperCase() ?? } + + + + +
+ {organisations?.map((org: OrganisationType) => ( + + {({ active }) => ( + +
+
+
+ +
+ {org.name} +
+ +
+ + )} +
+ ))} +
+ {!isOwner && ( +
+ + + +
+ )} +
+
+ + )} +
+ ) + const links: SidebarLinkT[] = [ { name: 'Home', @@ -264,46 +335,82 @@ const Sidebar = () => { ] return ( -
-