diff --git a/src/lib/components/chat/Chat.svelte b/src/lib/components/chat/Chat.svelte index de1eb0131..51b90892b 100644 --- a/src/lib/components/chat/Chat.svelte +++ b/src/lib/components/chat/Chat.svelte @@ -283,6 +283,16 @@ await goto('/'); } } + + showControls.subscribe(async (value) => { + if (controlPane) { + if (value) { + controlPane.resize(parseInt(localStorage.getItem('chat-controls-size') || '35')); + } else { + controlPane.resize(0); + } + } + }); }); onDestroy(() => { @@ -1764,7 +1774,6 @@ bind:selectedModels bind:showModelSelector shareEnabled={messages.length > 0} - {controlPane} {chat} {initNewChat} /> @@ -1847,8 +1856,8 @@ {messages} {submitPrompt} {stopResponse} - on:call={() => { - showControls.set(true); + on:call={async () => { + await showControls.set(true); }} /> diff --git a/src/lib/components/chat/ChatControls.svelte b/src/lib/components/chat/ChatControls.svelte index 925f19aa4..12a9905b7 100644 --- a/src/lib/components/chat/ChatControls.svelte +++ b/src/lib/components/chat/ChatControls.svelte @@ -140,17 +140,19 @@ : 'px-5 py-4 bg-white dark:shadow-lg dark:bg-gray-850 border border-gray-50 dark:border-gray-800'} rounded-lg z-50 pointer-events-auto overflow-y-auto scrollbar-hidden" > {#if $showCallOverlay} - { - showControls.set(false); - }} - /> +
+ { + showControls.set(false); + }} + /> +
{:else if $showOverview} { await showControls.set(!$showControls); - - if (controlPane) { - if ($showControls) { - controlPane.resize( - parseInt(localStorage.getItem('chat-controls-size') || '35') - ); - } else { - controlPane.resize(0); - } - } }} aria-label="Controls" >