From aeefa22ddf7ad6f627a8b2e725e574925c723c9d Mon Sep 17 00:00:00 2001 From: Mohamed Boudra Date: Wed, 11 Mar 2026 21:34:16 +0700 Subject: [PATCH] fix: hide chrome on home route --- packages/app/src/app/_layout.tsx | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/packages/app/src/app/_layout.tsx b/packages/app/src/app/_layout.tsx index 33274fc64..539014955 100644 --- a/packages/app/src/app/_layout.tsx +++ b/packages/app/src/app/_layout.tsx @@ -148,9 +148,14 @@ function QueryProvider({ children }: { children: ReactNode }) { interface AppContainerProps { children: ReactNode; selectedAgentId?: string; + chromeEnabled?: boolean; } -function AppContainer({ children, selectedAgentId }: AppContainerProps) { +function AppContainer({ + children, + selectedAgentId, + chromeEnabled: chromeEnabledOverride, +}: AppContainerProps) { const { theme } = useUnistyles(); const { daemons } = useDaemonRegistry(); const mobileView = usePanelStore((state) => state.mobileView); @@ -162,7 +167,7 @@ function AppContainer({ children, selectedAgentId }: AppContainerProps) { const isMobile = UnistylesRuntime.breakpoint === "xs" || UnistylesRuntime.breakpoint === "sm"; - const chromeEnabled = daemons.length > 0; + const chromeEnabled = chromeEnabledOverride ?? daemons.length > 0; const isOpen = chromeEnabled ? isMobile ? mobileView === "agent-list" @@ -375,6 +380,7 @@ function AppWithSidebar({ children }: { children: ReactNode }) { const pathname = usePathname(); const params = useGlobalSearchParams<{ open?: string | string[] }>(); useFaviconStatus(); + const shouldShowAppChrome = pathname !== "/" && pathname !== ""; // Parse selectedAgentKey directly from pathname // useLocalSearchParams doesn't update when navigating between same-pattern routes @@ -393,7 +399,12 @@ function AppWithSidebar({ children }: { children: ReactNode }) { }, [params.open, pathname]); return ( - {children} + + {children} + ); }