Skip to content

Commit e048caf

Browse files
fix(web): keep sidebar scroll position when pinning threads
1 parent b5d8903 commit e048caf

2 files changed

Lines changed: 5 additions & 1 deletion

File tree

‎apps/web/src/components/ui/sidebar.tsx‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -708,8 +708,9 @@ function SidebarContent({
708708
className="h-auto min-h-0 flex-1"
709709
>
710710
<div
711+
// Reordered rows must not pull the viewport to their new position.
711712
className={cn(
712-
"flex w-full min-w-0 flex-col gap-2 group-data-[collapsible=icon]:overflow-hidden",
713+
"flex w-full min-w-0 flex-col gap-2 [overflow-anchor:none] group-data-[collapsible=icon]:overflow-hidden",
713714
className,
714715
)}
715716
data-sidebar="content"

‎docs/user/thread-sidebar.md‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,9 @@ the thread opens and the files are attached in its composer, ready for
2929
your next message. The same per-message file limits apply as when attaching
3030
files directly; see [Attach files](./composer.md#attach-files).
3131

32+
On web and desktop, pinning or unpinning a thread keeps the sidebar at your current
33+
scroll position instead of following the thread to its new place in the list.
34+
3235
Pinning does not prevent automatic settlement. Settling a thread removes its pin.
3336

3437
On web and desktop, drag a thread between sections to change its state. Drag a thread up into

0 commit comments

Comments
 (0)