Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 12 additions & 1 deletion packages/ui/src/features/sessions/components/SessionView.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,11 @@ function ComposerWidth({
* Input region replacing the composer: `shrink-0` keeps it from being
* compressed by the scroller above, and `min-h-0 overflow-y-auto` lets tall
* content scroll inside itself.
*
* In compact mode (command center), the slot is height-capped at 50% of the
* parent so a tall question prompt cannot push the ThreadView out of view.
* The `shrink-0` is intentionally dropped for compact mode so the flex parent
* can keep the thread visible.
*/
function ComposerSlot({
compact,
Expand All @@ -134,7 +139,13 @@ function ComposerSlot({
children: React.ReactNode;
}) {
return (
<Box className="min-h-0 shrink-0 overflow-y-auto">
<Box
className={
compact
? "min-h-0 max-h-[50%] overflow-y-auto"
: "min-h-0 shrink-0 overflow-y-auto"
}
>
<ComposerWidth compact={compact}>{children}</ComposerWidth>
</Box>
);
Expand Down