680
681
/** Whether the active turn has a `PendingConfirmation` tool call auto-approved by the session's bypass setting. */
682
>
function hasAutoApprovedPendingConfirmation(state: ChatState): boolean {
sessionState.ts
683
>
return !!state.activeTurn?.responseParts.some(part =>
684
part.kind === ResponsePartKind.ToolCall
685
&& part.toolCall.status === ToolCallStatus.PendingConfirmation
686
&& readToolCallMeta(part.toolCall).autoApproveBySetting === true,
688
>
}
689
690
/** Whether the chat is genuinely blocked on user input (an open input request, an auth-required tool, or a non-auto-approved confirmation gate). */