mirror of
https://github.com/open-webui/open-webui.git
synced 2026-05-11 08:22:09 -05:00
[PR #1792] [MERGED] Hide the sidebar when resizing the window #43831
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/open-webui/open-webui/pull/1792
Author: @insoutt
Created: 4/27/2024
Status: ✅ Merged
Merged: 4/27/2024
Merged by: @tjbck
Base:
dev← Head:hide-sidebar-on-resize📝 Commits (1)
0c79ac0Hide sidevar when screen is resized to less than 1024 pixels📊 Changes
1 file changed (+12 additions, -5 deletions)
View changed files
📝
src/lib/components/layout/Sidebar.svelte(+12 -5)📄 Description
Pull Request Checklist
Description
When the window is resized and the width of the screen is reduced, the sidebar remains open. Therefore, I added a listener to check when the width of the screen changes, and if it is less than 1024px, it automatically hides the sidebar.
Note: I used the 1024px breakpoint because this is the default value used to show the sidebar.
Changelog Entry
Changed
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.