mirror of
https://github.com/open-webui/open-webui.git
synced 2026-10-09 03:18:18 +00:00
fix(sidebar): lock user menu position when sidebar is resized (#21853)
Use align="start" (left-anchor) instead of align="end" (right-anchor) on
the user menu DropdownMenu.Content, combined with avoidCollisions={false}
to prevent Floating UI from auto-flipping back to end-alignment when the
menu's left edge is near the viewport boundary.
Previously, the right edge of the full-width trigger row tracked the
right edge of the sidebar, so resizing the sidebar wider caused the menu
to drift rightward. With start alignment the menu is anchored to the
left edge of the trigger, which is stable regardless of sidebar width.
This commit is contained in:
parent
b2413f914a
commit
39e3f8fb81
1 changed files with 2 additions and 1 deletions
|
|
@ -88,7 +88,8 @@
|
|||
class="w-full {className} rounded-2xl px-1 py-1 border border-gray-100 dark:border-gray-800 z-50 bg-white dark:bg-gray-850 dark:text-white shadow-lg text-sm"
|
||||
sideOffset={4}
|
||||
side="top"
|
||||
align="end"
|
||||
align="start"
|
||||
avoidCollisions={false}
|
||||
transition={(e) => fade(e, { duration: 100 })}
|
||||
>
|
||||
{#if profile}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue