Skip to content

Open-source Grok Bot alternative for named AI teammates. Local-first desktop, web, and mobile clients with per-bot tools, instructions, and memory. Independent fork of T3 Code.

fix: allow sidebar to be shrunk when wider than viewport (#2456)

Shoaibd266c068d0e8
diff --git a/apps/web/src/components/AppSidebarLayout.tsx b/apps/web/src/components/AppSidebarLayout.tsx
index 4d0486aa8..ee56858bc 100644
--- a/apps/web/src/components/AppSidebarLayout.tsx
+++ b/apps/web/src/components/AppSidebarLayout.tsx
@@ -138,7 +138,8 @@ export function AppSidebarLayout({ children }: { children: ReactNode }) {
className="border-r border-border bg-card text-foreground"
resizable={{
minWidth: THREAD_SIDEBAR_MIN_WIDTH,
- shouldAcceptWidth: ({ nextWidth, wrapper }) =>
+ shouldAcceptWidth: ({ currentWidth, nextWidth, wrapper }) =>
+ nextWidth <= currentWidth ||
wrapper.clientWidth - nextWidth >= THREAD_MAIN_CONTENT_MIN_WIDTH,
storageKey: THREAD_SIDEBAR_WIDTH_STORAGE_KEY,
}}