Skip to content

Commit d05bc9c

Browse files
authored
Merge pull request #659 from trycompai/codex/update-layout-with-viewport-height-and-scrolling-behavior
Fix animated layout scrolling
2 parents 9f81e89 + ccc1e7f commit d05bc9c

File tree

1 file changed

+15
-15
lines changed

1 file changed

+15
-15
lines changed

apps/app/src/components/animated-layout.tsx

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -11,19 +11,19 @@ export function AnimatedLayout({
1111
sidebar,
1212
isCollapsed,
1313
}: AnimatedLayoutProps) {
14-
return (
15-
<div className="flex w-full overflow-hidden">
16-
<div
17-
className={cn(
18-
"flex-shrink-0 border-r bg-background duration-300 ease-in-out hidden md:block",
19-
isCollapsed ? "w-[80px]" : "w-[240px]",
20-
)}
21-
>
22-
{sidebar}
23-
</div>
24-
<div className="flex-1 overflow-auto bg-backgroundSoft">
25-
{children}
26-
</div>
27-
</div>
28-
);
14+
return (
15+
<div className="flex w-full h-screen overflow-hidden">
16+
<div
17+
className={cn(
18+
"flex-shrink-0 h-full overflow-y-auto border-r bg-background duration-300 ease-in-out hidden md:block",
19+
isCollapsed ? "w-[80px]" : "w-[240px]",
20+
)}
21+
>
22+
{sidebar}
23+
</div>
24+
<div className="flex-1 overflow-y-auto bg-backgroundSoft">
25+
{children}
26+
</div>
27+
</div>
28+
);
2929
}

0 commit comments

Comments
 (0)