Skip to content

Add configurable tooltip hover timing delay#22264

Open
davelopez wants to merge 3 commits intogalaxyproject:devfrom
davelopez:feature/tooltip-delay
Open

Add configurable tooltip hover timing delay#22264
davelopez wants to merge 3 commits intogalaxyproject:devfrom
davelopez:feature/tooltip-delay

Conversation

@davelopez
Copy link
Copy Markdown
Contributor

Follow up to #21962

Currently, tooltips are displayed instantly, and sometimes they get in the way when moving the cursor rapidly. This adds a configurable delay (currently 300 ms) to avoid that, while keeping the tooltip instant for keyboard navigation, so accessibility is preserved.

Before

TooltipsDelayBefore.mp4

After

TooltipsDelayAfter.mp4

How to test the changes?

  • I've included appropriate automated tests.
  • This is a refactoring of components with existing test coverage.
  • Instructions for manual testing are as follows:
    1. [add testing steps and prerequisites here if you didn't write automated tests covering all your changes]

License

  • I agree to license these and all my past contributions to the core galaxy codebase under the MIT license.

Replaces deprecated directive type with the recommended Vue 3 type to ensure type safety and compatibility with future Vue versions.
@dannon
Copy link
Copy Markdown
Member

dannon commented Mar 26, 2026

Hey, just added one commit with a minor tweak to removeEventListener -- when delayFocusEnter is true, the cleanup was removing enter instead of the actual registered handler, so it'd leak listeners. Not a live bug since the only call site passes false, but easy to trip over later.

Also, was the jump from ~50ms (what Bootstrap-Vue used) to 300ms intentional? 300ms feels a touch slow to me -- I could see something in the 150-200ms range being a nice middle ground that still filters out incidental cursor crossings without making tooltips feel sluggish. Curious about your thinking there.

@davelopez
Copy link
Copy Markdown
Contributor Author

Thanks for the handler fix! 🙏

Yes, it was intentional, and the whole motivation of the change 😅 The actual, almost instant display was a little annoying, especially when a bigger tooltip covers something that you want to click or check, etc, and I thought it would be annoying for others too.
Regarding the 300 ms delay, I did a bit of research and found a nice article about it here that mentions the delay for hidden elements should be between 300-500 ms, which is why I chose 300. But I'm happy to tweak the delay to make everyone happy.
The good thing is that now we only need to change one value in one place, so feel free to adjust it 😉

@mvdbeek mvdbeek requested a review from dannon March 31, 2026 14:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Status: Needs Review

Development

Successfully merging this pull request may close these issues.

2 participants