import type { InlineInputOwner, QuestionnaireState } from "./state.ts";
/**
 * Shared owner-branching accessors/mutator for the two per-owner inline-input
 * map pairs on `QuestionnaireState`:
 * - `"chat"`  → `chatDraftByTab` / `chatCaretByTab`
 * - `"other"` → `customDraftByTab` / `customCaretByTab`
 *
 * Both the pure reducer (`state-reducer.ts`) and the runtime
 * (`questionnaire-session.ts`) read and write these maps. Hoisting the helpers
 * here keeps the `owner === "chat"` branch in exactly one place instead of
 * copying it into each caller (previously `withInlineDraft` was duplicated
 * verbatim and the accessor pairs were near-duplicates split across the two
 * files).
 */
/** Raw draft text persisted for `owner` at the current tab, or undefined when none is stored. */
export declare function readInlineDraft(state: QuestionnaireState, owner: InlineInputOwner): string | undefined;
/** Raw caret offset persisted for `owner` at the current tab, or undefined when none is stored. */
export declare function readInlineCaret(state: QuestionnaireState, owner: InlineInputOwner): number | undefined;
/** Immutably persist `value`/`caret` into `owner`'s draft+caret maps for the current tab. */
export declare function withInlineDraft(state: QuestionnaireState, owner: InlineInputOwner, value: string, caret: number): QuestionnaireState;
/**
 * Draft text used to hydrate the inline editor when (re)focusing `owner`: the
 * in-flight draft when present, otherwise the prior committed answer for that
 * owner. The `"chat"` owner excludes the reserved sentinel label so a prior
 * signal-only chat (`"Chat about this"`) does not re-hydrate as editable text.
 */
export declare function resolveInlineDraftValue(state: QuestionnaireState, owner: InlineInputOwner): string;
//# sourceMappingURL=inline-input.d.ts.map