From ee9db91df02120e1e3651e8881734966b710ad52 Mon Sep 17 00:00:00 2001 From: Timothy Jaeryang Baek Date: Sat, 11 Apr 2026 17:06:49 -0600 Subject: [PATCH] refac --- src/lib/components/chat/Chat.svelte | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/lib/components/chat/Chat.svelte b/src/lib/components/chat/Chat.svelte index 5b96f82c2f..a3feb6a269 100644 --- a/src/lib/components/chat/Chat.svelte +++ b/src/lib/components/chat/Chat.svelte @@ -1232,8 +1232,13 @@ desktopEvent.set(null); if (event.type === 'call') { - showCallOverlay.set(true); - showControls.set(true); + // Defer to next macrotask so the call overlay isn't clobbered by + // showControlsSubscribe's initial callback (value=false → set(false)) + // which runs as a pending microtask after this function. + setTimeout(() => { + showCallOverlay.set(true); + showControls.set(true); + }, 0); } else if (event.type === 'query') { const query = event.data?.query; const eventFiles = event.data?.files;