fix: prevent ghost border for AskUserDialog (#17788)

This commit is contained in:
Jack Wotherspoon
2026-01-29 09:00:46 -05:00
committed by GitHub
parent fbe8d1be00
commit 3a5f3c7aed
4 changed files with 41 additions and 7 deletions
@@ -116,13 +116,11 @@ export const ToolGroupMessage: React.FC<ToolGroupMessageProps> = ({
[toolCalls, isEventDriven],
);
// If all tools are hidden (e.g. group only contains confirming or pending tools),
// render nothing in the history log unless we have a border override.
if (
visibleToolCalls.length === 0 &&
borderTopOverride === undefined &&
borderBottomOverride === undefined
) {
// If all tools are filtered out (e.g., in-progress AskUser tools, confirming tools
// in event-driven mode), only render if we need to close a border from previous
// tool groups. borderBottomOverride=true means we must render the closing border;
// undefined or false means there's nothing to display.
if (visibleToolCalls.length === 0 && borderBottomOverride !== true) {
return null;
}