diff --git a/packages/opencode/src/cli/cmd/tui/component/prompt/index.tsx b/packages/opencode/src/cli/cmd/tui/component/prompt/index.tsx index 0566e07b34..e8affacda7 100644 --- a/packages/opencode/src/cli/cmd/tui/component/prompt/index.tsx +++ b/packages/opencode/src/cli/cmd/tui/component/prompt/index.tsx @@ -1464,11 +1464,15 @@ export function Prompt(props: PromptProps) { }), } }) + const maxHeight = createMemo( + () => tuiConfig.prompt?.max_height ?? Math.max(6, Math.floor(dimensions().height / 3)), + ) return ( <> - (anchor = r)} visible={props.visible !== false}> + (anchor = r)} visible={props.visible !== false} width="100%">