fix: make Cmd+J worktree jump scroll instant (#751)

Remove `scroll-smooth` from the virtualized sidebar viewport so palette
reveals land immediately instead of animating the full cross-list
distance at the browser's default smooth-scroll speed.

Single-card stepping (Cmd+Shift+↑/↓) no longer glides either — the
brevity of the movement makes instant feel snappier, and it avoids
the state-machine risk of toggling `scroll-behavior` inline when
tanstack virtual can also issue follow-up scroll corrections after
dynamic item measurement.
This commit is contained in:
Jinjing 2026-04-16 23:25:17 -07:00 committed by GitHub
parent 6e1cb1c6cf
commit d1a3324e7e
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -252,7 +252,7 @@ const VirtualizedWorktreeViewport = React.memo(function VirtualizedWorktreeViewp
aria-orientation="vertical"
aria-activedescendant={activeDescendantId}
onKeyDown={handleContainerKeyDown}
className="flex-1 overflow-auto pl-1 pr-2 scroll-smooth outline-none focus-visible:ring-1 focus-visible:ring-ring focus-visible:ring-inset pt-px [scrollbar-width:none] [&::-webkit-scrollbar]:hidden"
className="flex-1 overflow-auto pl-1 pr-2 outline-none focus-visible:ring-1 focus-visible:ring-ring focus-visible:ring-inset pt-px [scrollbar-width:none] [&::-webkit-scrollbar]:hidden"
>
<div
role="presentation"