Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] flickering behaviour with data-tooltip-hidden #1114

Closed
nsalamad opened this issue Nov 6, 2023 · 5 comments · Fixed by #1118
Closed

[BUG] flickering behaviour with data-tooltip-hidden #1114

nsalamad opened this issue Nov 6, 2023 · 5 comments · Fixed by #1118
Labels

Comments

@nsalamad
Copy link

nsalamad commented Nov 6, 2023

Bug description
data-tooltip-hidden={true} results in flickering behaviour when mousing over from an element that has a visible tooltip.

Version of Package
v5.22.0

To Reproduce
Hover from an anchor element that has data-tooltip-hidden={false}, to an element with data-tooltip-hidden={true}. You should see the tooltip for the element with data-tooltip-hidden={true} appear for a split second and then disappear.

CodeSandbox repro: https://codesandbox.io/s/admiring-shadow-ny25y8?file=/src/App.js
Odd numbered words have data-tooltip-hidden set to false. If you hover from an odd numbered word to an even numbered one, you will see the tooltip that should be hidden appear for a split second.

Screenshots
Video:

Screen.Recording.2023-11-06.at.3.21.26.PM.mov

Expected behavior
When hovering from an anchor with a tooltip that has data-tooltip-hidden set to false to an anchor with a tooltip that is hidden, the hidden tooltip should not appear at all.

@nsalamad nsalamad added the Bug label Nov 6, 2023
@marcantoinegodde
Copy link

In my case, since 5.22.0 data-tooltip-hidden={true} isn't working at all. If I roll back to 5.21.7, everything works as expected.

I noticed another side-effect. If data-tooltip-content is equal to null or undefined, a small tooltip is rendered without anything in it and this shouldn't be the case. Nothing should happen on hover. Again, works as expected in 5.21.7.

@dsims01
Copy link

dsims01 commented Nov 9, 2023

Seems the issue is wider than just data-tooltip-hidden, bc I see the same flickering in @nsalamad's codesandbox when I remove data-tooltip-hidden and add delayShow={1000} as a Tooltip prop.

@gabrieljablonski
Copy link
Member

gabrieljablonski commented Nov 12, 2023

Sorry for the delay, for some reason I'm not receiving GitHub notifications for new issues anymore. Weird stuff.

All problems described here in the thread are very likely due to the new "fade-out" transition when closing the tooltip, which used to just abruptly close before v5.22.0.

@gabrieljablonski
Copy link
Member

The beta version [email protected] fixes the problem with hidden and null/empty content.

@dsims01 the problem with delayShow will be a bit trickier to fix, I'll open a new issue to track it separately.

@gabrieljablonski
Copy link
Member

Fixed on official release [email protected] (alongside the new "imperative mode", check it out 😀😀)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants