import type { PendingApproval } from "@stigmer/protos/ai/stigmer/agentic/agentexecution/v1/approval_pb";
import { ApprovalAction } from "@stigmer/protos/ai/stigmer/agentic/agentexecution/v1/enum_pb";
/** Props for {@link ApprovalCard}. */
export interface ApprovalCardProps {
    /** The pending approval request to render. */
    readonly pendingApproval: PendingApproval;
    /**
     * Called when the user clicks Approve, Skip, or Reject.
     * The consumer (typically {@link MessageThread} or a platform
     * builder's custom thread) handles the RPC via
     * {@link useSubmitApproval}.
     */
    readonly onSubmit: (action: ApprovalAction, comment?: string) => void;
    /** True while the RPC for this specific tool call is in flight. */
    readonly isSubmitting?: boolean;
    /**
     * This gate's last failed decision, or `null` — surfaced in-card, beside the
     * action buttons (the optimistic spinner reverts on failure, so this explains
     * the snap-back). A thread can hold many gates; the error must name the one it
     * belongs to, which a single global banner cannot do. Supply the entry from
     * {@link useSubmitApproval}'s `errorsByToolCallId` for this `toolCallId`.
     */
    readonly error?: Error | null;
    /** Additional CSS class names for the root container. */
    readonly className?: string;
}
/**
 * Renders a pending tool-call approval request with the same visual
 * structure as an expanded {@link ToolCallItem} in the history list.
 *
 * The compact header row matches the ToolCallItem layout:
 *   [CategoryIcon] Label  primaryArg  [⏳ waiting Xm]
 *
 * The body shows the proposed change from the tool args (the
 * pre-execution deny-gate has no captured `FileChangeSet` yet): the
 * write/edit content when present, an {@link EmptyChangeNotice} when
 * only a path is known, otherwise the shared {@link ToolArgsView}
 * dispatch, keeping pixel-level parity with the detail view.
 *
 * Wrapped in `React.memo` — structural sharing (T04) preserves the
 * `PendingApproval` reference when unchanged, so approval cards
 * skip re-renders during unrelated stream updates.
 *
 * @example
 * ```tsx
 * <ApprovalCard
 *   pendingApproval={approval}
 *   onSubmit={(action) => submitApproval(executionId, approval.toolCallId, action)}
 *   isSubmitting={submittingIds.has(approval.toolCallId)}
 * />
 * ```
 */
export declare const ApprovalCard: import("react").NamedExoticComponent<ApprovalCardProps>;
/** Props for {@link ApprovalCardHeader}. */
export interface ApprovalCardHeaderProps {
    /** The pending approval to summarize. */
    readonly pendingApproval: PendingApproval;
    /** Adds a bottom divider, for use above {@link ApprovalCardBody}. */
    readonly bordered?: boolean;
}
/**
 * The compact summary row of an approval — `[icon] Label primaryArg [via sub]
 * [⏳ Xm]`. Used as the standalone {@link ApprovalCard}'s header. Not rendered
 * inline on a {@link ToolCallItem}, whose own row already serves as the header.
 */
export declare function ApprovalCardHeader({ pendingApproval, bordered, }: ApprovalCardHeaderProps): import("react/jsx-runtime").JSX.Element;
/** Props for {@link ApprovalCardBody}. */
export interface ApprovalCardBodyProps {
    /** The pending approval to render a decision panel for. */
    readonly pendingApproval: PendingApproval;
    /** Called when the user picks Approve / Approve-all / Skip / Reject. */
    readonly onSubmit: (action: ApprovalAction, comment?: string) => void;
    /** True while the RPC for this tool call is in flight. */
    readonly isSubmitting?: boolean;
    /** This gate's last failed decision, or `null` — surfaced in-card below the actions. */
    readonly error?: Error | null;
    /** Additional CSS class names for the body container. */
    readonly className?: string;
}
/**
 * The decision panel of an approval: the optional message and gate reason, the
 * file-changes / args preview, and the action buttons. Reused in two places —
 * the standalone {@link ApprovalCard} (with {@link ApprovalCardHeader} above
 * it) and inline inside a gated {@link ToolCallItem}'s expanded panel, where
 * the item's own row is the header. One body, identical preview in both.
 */
export declare function ApprovalCardBody({ pendingApproval, onSubmit, isSubmitting, error, className, }: ApprovalCardBodyProps): import("react/jsx-runtime").JSX.Element;
//# sourceMappingURL=ApprovalCard.d.ts.map