/**
 * Shared approval primitives.
 *
 * UI components:
 *   - ApprovalButtonBar — reusable [Accept] [Accept All] [Reject] button strip
 *   - Border            — horizontal rule
 */
import type { AutoApproveState } from '../../app/approvals/session-auto-approve.js';
import { APPROVAL, type ApprovalChoice, type ApprovalGate, type ApprovalQueueInfo, type ApprovalRequest } from '../../app/approvals/types.js';
import type { TUI } from '../../tui/index.js';
import { type Component, Container } from '../../tui/index.js';
import type { Theme } from '../theme/runtime.js';
/**
 * Create an ApprovalGate that shows a TUI component for approval.
 *
 * The only thing that varies per tool is the Component class — the
 * auto-approve check, accept-all toggle, and ctx.ui.custom ceremony
 * are always the same.
 */
export declare function createApprovalGate<T>(ComponentClass: new (data: T, theme: Theme, done: (c: ApprovalChoice) => void, queueInfo?: ApprovalQueueInfo, tui?: TUI) => Component & {
    dispose?(): void;
}, autoApproveState: AutoApproveState): ApprovalGate<T>;
export declare function createBatchingApprovalGate<T>(ComponentClass: new (data: T[], theme: Theme, done: (c: ApprovalChoice) => void, queueInfo?: ApprovalQueueInfo, tui?: TUI) => Component & {
    dispose?(): void;
}): ApprovalGate<T>;
export { APPROVAL };
export type { ApprovalChoice, ApprovalGate, ApprovalQueueInfo, ApprovalRequest };
/** Horizontal rule. Avoids importing from higher-level delivery coordinators. */
export declare class Border implements Component {
    private color;
    constructor(color: (s: string) => string);
    invalidate(): void;
    render(width: number): string[];
}
/**
 * Reusable [Accept] [Accept All] [Reject] button strip with ←/→ keyboard nav.
 *
 * Meant to be composed inside a parent Container — call `getContainer()` once
 * to embed the rendered buttons, then forward keypresses via `handleInput()`.
 */
export declare class ApprovalButtonBar {
    private selectedButton;
    private container;
    private theme;
    private hint;
    private buttons;
    constructor(theme: Theme, hint?: string, hideAcceptAllOrButtons?: boolean | ApprovalChoice[]);
    getContainer(): Container;
    private render;
    /**
     * Handle a keypress. Returns the chosen button, or undefined if the key
     * was navigation / unrecognized.
     */
    handleInput(keyData: string): ApprovalChoice | undefined;
}
//# sourceMappingURL=approval.d.ts.map