feat: tune session sidebar tooltip timing

Adds a shared sidebar tooltip provider with delayed open and instant close behavior
Removes per-button tooltip delays so sidebar actions feel more consistent
Aligns session sidebar hover interactions with the opencode-style tooltip experience
This commit is contained in:
Bohdan Triapitsyn
2026-08-30 18:03:29 +03:00
parent 654b3d2441
commit d0a5538bff
5 changed files with 19 additions and 20 deletions
@@ -592,13 +592,12 @@ const SessionSidebarComponent: React.FC<SessionSidebarProps> = ({
}, [mobileVariant, openNewSessionDraft, setSessionSwitcherOpen]);
return (
// One shared tooltip provider for the whole sidebar: session tooltips open
// instantly, and moving between rows hands the tooltip over (grouping)
// instead of replaying the exit/enter animation for each row.
// closeDelay bridges the small gap between rows: the tooltip survives the
// pointer crossing row margins, and the grouping timeout hands it over to
// the next row without an exit/enter cycle.
<TooltipProvider delay={0} closeDelay={150} timeout={600}>
// One shared tooltip provider for the whole sidebar, matching the opencode
// sidebar feel: 400ms before the first tooltip opens, instant close on
// leave, and grouping — moving between rows within 600ms hands the tooltip
// over to the next row without replaying the open delay or exit/enter
// animation.
<TooltipProvider delay={400} closeDelay={0} timeout={300}>
<div
ref={sessionSearchContainerRef}
className={cn(