import type { FooterStatusLayoutDecision } from "./components/BackgroundTasksBar.js"; import type { CompletedItem } from "./app-items.js"; import { shouldTopSpaceAfterPrintedTranscriptBoundary, shouldTopSpaceAssistantAfterToolBoundary as shouldTopSpaceAssistantAfterToolBoundaryFromTranscript } from "./transcript/spacing.js"; export type OverlayPaneKind = "model" | "skills" | "plan" | "theme"; export declare function shouldHideHistoryForOverlayView(isOverlayView: boolean, _isAgentRunning: boolean): boolean; export declare function shouldStabilizeOverlayPaneRerender({ overlayPane: _overlayPane, isAgentRunning: _isAgentRunning, }: { overlayPane: OverlayPaneKind | null; isAgentRunning: boolean; }): boolean; export declare function shouldHideStaticItemsForOverlayView({ shouldHideHistoryForOverlay, stabilizeOverlayPaneRerender: _stabilizeOverlayPaneRerender, }: { shouldHideHistoryForOverlay: boolean; stabilizeOverlayPaneRerender: boolean; }): boolean; export interface DoneFlushDecision { showDoneStatus: boolean; flushLiveItems: boolean; } export declare function getDoneFlushDecision({ planOverlayPending, }: { planOverlayPending: boolean; }): DoneFlushDecision; export declare function shouldResetUIForSetupPaneTransition({ hasResetUI, hasSessionStore, }: { hasResetUI: boolean; hasSessionStore: boolean; }): boolean; export interface ScrollStabilizationDecision { /** Legacy signal for tests that modeled Static replay avoidance. */ preserveStatic: boolean; /** New output should still appear normally when the user is at the bottom. */ autoFollow: boolean; } export interface DoneStatus { durationMs: number; toolsUsed: string[]; verb: string; /** Per-run tool-call counts keyed by tool name (for the vital-signs line). */ counts?: Record; /** Per-run output-token total. */ tokens?: number; } export declare function getScrollStabilizationDecision({ isUserScrolled, hasNewOutput, hasTallLiveUserMessage, hasParagraphBreakLiveUserMessage, }: { isUserScrolled: boolean; hasNewOutput: boolean; hasTallLiveUserMessage?: boolean; hasParagraphBreakLiveUserMessage?: boolean; }): ScrollStabilizationDecision; export declare function hasParagraphBreakLiveUserMessage(text: string): boolean; export declare function isTallLiveUserMessage(text: string, rows: number): boolean; export declare function getStaticHistoryKey({ resizeKey }: { resizeKey: number; }): string; export declare const MIN_LIVE_AREA_ROWS = 3; export declare function isAgentSpacingItem(item: CompletedItem): boolean; export declare const shouldTopSpaceAfterPrintedAgentBoundary: typeof shouldTopSpaceAfterPrintedTranscriptBoundary; export declare const shouldTopSpaceAssistantAfterToolBoundary: typeof shouldTopSpaceAssistantAfterToolBoundaryFromTranscript; export declare function shouldTopSpaceStreamingAssistant({ visibleStreamingText, lastLiveItem, lastPendingHistoryItem, lastHistoryItem, }: { visibleStreamingText: string; lastLiveItem?: CompletedItem; lastPendingHistoryItem?: CompletedItem; lastHistoryItem?: CompletedItem; }): boolean; export interface ChatControlsLayoutOptions { rows: number; columns: number; agentRunning: boolean; activityVisible: boolean; doneStatusVisible: boolean; stallStatusVisible: boolean; exitPending: boolean; footerStatusLayout: FooterStatusLayoutDecision; taskBarExpanded: boolean; footerFitsOnOneLine: boolean; /** * Rows the pinned LiveToolPanel currently occupies inside the controls block * (0 when hidden). Folding this into the budget makes the live area shrink in * the SAME render the tool feed grows, so the panel growing row-by-row never * transiently overflows the terminal and bounces the footer. */ liveToolPanelRows: number; } export interface ChatControlsLayoutDecision { controlsRows: number; liveAreaRows: number; } export declare function getChatControlsLayoutDecision({ rows, exitPending, footerStatusLayout, taskBarExpanded, footerFitsOnOneLine, liveToolPanelRows, }: ChatControlsLayoutOptions): ChatControlsLayoutDecision; //# sourceMappingURL=layout-decisions.d.ts.map