import { type Theme } from "../../../../modes/interactive/theme/theme.ts";
import { Input } from "@earendil-works/pi-tui";
import type { QuestionData } from "../tool/types.ts";
import type { WrappingSelectItem } from "../view/components/wrapping-select.ts";
import { QuestionnairePropsAdapter } from "../view/props-adapter.ts";
import type { QuestionnaireState } from "./state.ts";
export interface QuestionnaireBuildConfig {
    tui: {
        terminal: {
            columns: number;
        };
        requestRender(): void;
    };
    theme: Theme;
    questions: readonly QuestionData[];
    itemsByTab: ReadonlyArray<readonly WrappingSelectItem[]>;
    isMulti: boolean;
    initialState: QuestionnaireState;
    getCurrentTab: () => number;
}
export interface QuestionnaireBuilt {
    adapter: QuestionnairePropsAdapter;
    notesInput: Input;
    inlineInput: Input;
    render: (width: number) => string[];
    invalidate: () => void;
}
/**
 * Pure factory: assembles every TUI component, the props adapter, and a
 * lifecycle handle. Session-state dependencies arrive via `getCurrentTab` and
 * the `inputBuffer` cell. Initial paint is delegated to
 * `adapter.apply(initialState)` (called by the session at construction-end);
 * no selector is invoked here.
 */
export declare function buildQuestionnaire(config: QuestionnaireBuildConfig): QuestionnaireBuilt;
//# sourceMappingURL=build-questionnaire.d.ts.map