fix sidebar

This commit is contained in:
Philipinho
2026-04-12 20:44:22 +01:00
parent c9531acf04
commit 9226014fe9
@@ -78,7 +78,7 @@ export default function GlobalAppShell({
const isHomeRoute = location.pathname.startsWith("/home"); const isHomeRoute = location.pathname.startsWith("/home");
const isSpacesRoute = location.pathname === "/spaces"; const isSpacesRoute = location.pathname === "/spaces";
const isPageRoute = location.pathname.includes("/p/"); const isPageRoute = location.pathname.includes("/p/");
const showGlobalSidebar = !isSpaceRoute && !isSettingsRoute; const showGlobalSidebar = !isSpaceRoute && !isSettingsRoute && !isAiRoute;
return ( return (
<AppShell <AppShell
@@ -103,19 +103,19 @@ export default function GlobalAppShell({
<AppShell.Header px="md" className={classes.header}> <AppShell.Header px="md" className={classes.header}>
<AppHeader /> <AppHeader />
</AppShell.Header> </AppShell.Header>
{!hideSidebar && ( <AppShell.Navbar
<AppShell.Navbar className={classes.navbar}
className={classes.navbar} withBorder={false}
withBorder={false} ref={sidebarRef}
ref={sidebarRef} >
> {isSpaceRoute && (
{!isAiRoute && <div className={classes.resizeHandle} onMouseDown={startResizing} />} <div className={classes.resizeHandle} onMouseDown={startResizing} />
{isSpaceRoute && <SpaceSidebar />} )}
{isSettingsRoute && <SettingsSidebar />} {isSpaceRoute && <SpaceSidebar />}
{isAiRoute && <AiChatSidebar />} {isSettingsRoute && <SettingsSidebar />}
{showGlobalSidebar && <GlobalSidebar />} {isAiRoute && <AiChatSidebar />}
</AppShell.Navbar> {showGlobalSidebar && <GlobalSidebar />}
)} </AppShell.Navbar>
<AppShell.Main> <AppShell.Main>
{isSettingsRoute ? ( {isSettingsRoute ? (
<Container size={850}>{children}</Container> <Container size={850}>{children}</Container>