import type { AgentMessage } from "@oh-my-pi/pi-agent-core";
import type { AssistantMessage, ImageContent, Message } from "@oh-my-pi/pi-ai";
import { type Component } from "@oh-my-pi/pi-tui";
import type { InteractiveModeContext } from "../../modes/types.js";
import type { SessionContext } from "../../session/session-context.js";
interface RenderInitialMessagesOptions {
    preserveExistingChat?: boolean;
    clearTerminalHistory?: boolean;
}
export declare class UiHelpers {
    #private;
    private ctx;
    constructor(ctx: InteractiveModeContext);
    /** Extract text content from a user message */
    getUserMessageText(message: Message): string;
    /**
     * Show a status message in the chat.
     *
     * If multiple status messages are emitted back-to-back (without anything else being added to the chat),
     * we update the previous status line instead of appending new ones to avoid log spam.
     */
    showStatus(message: string, options?: {
        dim?: boolean;
    }): void;
    addMessageToChat(message: AgentMessage, options?: {
        populateHistory?: boolean;
        imageLinks?: readonly (string | undefined)[];
    }): Component[];
    /**
     * Render session context to chat. Used for initial load and rebuild after compaction.
     * @param sessionContext Session context to render
     * @param options.updateFooter Update footer state
     * @param options.populateHistory Add user messages to editor history
     */
    renderSessionContext(sessionContext: SessionContext, options?: {
        updateFooter?: boolean;
        populateHistory?: boolean;
    }): void;
    renderInitialMessages(options?: RenderInitialMessagesOptions): void;
    clearEditor(): void;
    showError(errorMessage: string): void;
    showWarning(warningMessage: string): void;
    showNewVersionNotification(newVersion: string): void;
    updatePendingMessagesDisplay(): void;
    queueCompactionMessage(text: string, mode: "steer" | "followUp", images?: ImageContent[]): void;
    isKnownSlashCommand(text: string): boolean;
    flushCompactionQueue(options?: {
        willRetry?: boolean;
    }): Promise<void>;
    /** Move pending bash components from pending area to chat */
    flushPendingBashComponents(): void;
    findLastAssistantMessage(): AssistantMessage | undefined;
    extractAssistantText(message: AssistantMessage): string;
}
export {};
