Skip to content

Commit 12ef687

Browse files
committed
webui: fix chat header width when sidebar is closed
1 parent 380b4c9 commit 12ef687

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

tools/server/webui/src/lib/components/app/chat/ChatScreen/ChatScreenHeader.svelte

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,9 @@
22
import { Settings } from '@lucide/svelte';
33
import { DialogChatSettings } from '$lib/components/app';
44
import { Button } from '$lib/components/ui/button';
5+
import { useSidebar } from '$lib/components/ui/sidebar';
6+
7+
const sidebar = useSidebar();
58
69
let settingsOpen = $state(false);
710
@@ -11,7 +14,9 @@
1114
</script>
1215

1316
<header
14-
class="md:background-transparent pointer-events-none fixed top-0 right-0 left-0 z-50 flex items-center justify-end bg-background/40 p-4 backdrop-blur-xl md:left-[var(--sidebar-width)]"
17+
class="md:background-transparent pointer-events-none fixed top-0 right-0 left-0 z-50 flex items-center justify-end bg-background/40 p-4 backdrop-blur-xl duration-200 ease-linear {sidebar.open
18+
? 'md:left-[var(--sidebar-width)]'
19+
: ''}"
1520
>
1621
<div class="pointer-events-auto flex items-center space-x-2">
1722
<Button variant="ghost" size="sm" onclick={toggleSettings}>

0 commit comments

Comments
 (0)