From 806644fcbaa60410123e0156a9ade8ea7d030557 Mon Sep 17 00:00:00 2001 From: Classic298 <27028174+Classic298@users.noreply.github.com> Date: Wed, 7 Oct 2026 14:22:46 +0200 Subject: [PATCH] fix: Cancel and Continue in the web search confirmation popup need two clicks (#31976) With the admin setting Web Search Confirmation on, switching on Web Search from the Integrations menu opened the confirmation popup while the menu stayed open behind it. The first click on Cancel or Continue only closed the menu, so the buttons looked broken until clicked a second time. The menu now closes when the popup opens, so one click confirms or cancels. Fixes #31963 --- src/lib/components/chat/MessageInput/IntegrationsMenu.svelte | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/lib/components/chat/MessageInput/IntegrationsMenu.svelte b/src/lib/components/chat/MessageInput/IntegrationsMenu.svelte index ad2a3109ac..e8b66fbb55 100644 --- a/src/lib/components/chat/MessageInput/IntegrationsMenu.svelte +++ b/src/lib/components/chat/MessageInput/IntegrationsMenu.svelte @@ -6,6 +6,7 @@ import { chatId, + config, selectedTerminalId, settings, terminalServers, @@ -448,6 +449,10 @@ aria-pressed={webSearchEnabled} on:click={() => { webSearchEnabled = !webSearchEnabled; + // Left open, this menu would swallow the first click on the confirmation dialog + if (webSearchEnabled && $config?.features?.enable_web_search_confirmation) { + show = false; + } onWebSearchToggle(webSearchEnabled); }} >