/**
 * Pure functions for select menu rendering and input handling.
 *
 * All functions are side-effect-free and testable in isolation.
 * IO concerns (stdin/stdout, raw mode) remain in select.ts.
 * Viewport logic lives in select-viewport.ts.
 */
export interface SelectOptionItem<T extends string> {
    label: string;
    value: T;
    description?: string;
    details?: string[];
}
export type KeyInputResult = {
    action: 'move';
    newIndex: number;
} | {
    action: 'confirm';
    selectedIndex: number;
} | {
    action: 'cancel';
    cancelIndex: number;
} | {
    action: 'bookmark';
    selectedIndex: number;
} | {
    action: 'remove_bookmark';
    selectedIndex: number;
} | {
    action: 'exit';
} | {
    action: 'none';
};
export interface ViewportState {
    readonly scrollOffset: number;
    readonly maxOptionLines: number;
    readonly active: boolean;
}
export declare function renderSingleOption<T extends string>(opt: SelectOptionItem<T>, isSelected: boolean, maxWidth: number): string[];
export declare function renderCancelOption(isSelected: boolean, cancelLabel: string): string;
export declare function countItemLines<T extends string>(opt: SelectOptionItem<T>): number;
export declare function renderMenu<T extends string>(options: SelectOptionItem<T>[], selectedIndex: number, hasCancelOption: boolean, cancelLabel?: string): string[];
export declare function countRenderedLines<T extends string>(options: SelectOptionItem<T>[], hasCancelOption: boolean): number;
export declare function handleKeyInput(key: string, currentIndex: number, totalItems: number, hasCancelOption: boolean, optionCount: number): KeyInputResult;
//# sourceMappingURL=select-menu.d.ts.map