Materialize: Tooltips stick if button opens new modal

Created on 11 Oct 2016  路  6Comments  路  Source: Dogfalo/materialize

Hey Materialize Team,

Been having a small issue where a tooltipped button's tooltip will stick and not go away if the button opened a new popup modal. This happens about 50% of the time. My guess is that the onmouseout never gets called when the darkened div takes over. My workaround for now is to just delete the material-tooltip divs and re-call tooltip.

Thanks,

bug Tooltip

All 6 comments

In general, I also find the tooltips very glitchy. For example, if you move your mouse in and out too fast, ghosting occurs. Also, they work really poorly on mobile, where two taps are required to trigger a button.

can you post your code example?

https://gfycat.com/FaithfulFrighteningGourami

http://codepen.io/jonasroessum/pen/BLOdpb?editors=1000

The minor issue seems to have been fixed by fading the tooltip in, it seems smoother in the newest version.
I can't seem to recreate the modal issue that @ev5unleash is experiencing, except that the tooltip has a higher z-index value than the modal and it's overlay, however not the issue he is describing.

Any update on this? I also have issue with tooltips, I put it under btn-floating, first time it works fine but when I click on the button, the tooltip freezes and never disappear...

Not sure what the solution would be for this, as the mouseleave wont be called if a new overlay takes over the current context. We've added a close method to tooltips in v1-dev which will allow you to close the tooltip on modal open.

A little workaround for anyone who is interested (@ev5unleash), if you add line 4530 in the materialize.js you can set a timer for the tool tip. The line of code I used is: setTimeout(function(){_this27._animateOut();}, 1000); and you can edit the 1000 to whatever time you want (in ms). I simply made it one second and it works for me! @Dogfalo, maybe consider making this an Boolean option? Cheers!

image

Was this page helpful?
0 / 5 - 0 ratings

Related issues

PhillippOhlandt picture PhillippOhlandt  路  3Comments

acierpinski picture acierpinski  路  3Comments

Robouste picture Robouste  路  3Comments

SoproniOli713 picture SoproniOli713  路  3Comments

ruslandzhumaev picture ruslandzhumaev  路  3Comments