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

hide tooltip when click on body #67

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Conversation

zation
Copy link

@zation zation commented Jul 2, 2014

No description provided.

@jbrowning
Copy link
Member

Thanks for your contribution @zation. I think this will conflict with the tour component, which uses tooltip.

@jbrowning
Copy link
Member

Tour seems ok, but this does break custom triggers:

http://take.ms/xIxUJ

@zation
Copy link
Author

zation commented Jul 4, 2014

Hi @jbrowning
This is because when we click into that input, we both trigger "click" and "focus" event to hide that tooltip. I've fix that problem by detect if the trigger element is the element to show the tooltip itself, if so it won't be hide. Please have a look at it, it works in our project now.
Thanks!

@jbrowning
Copy link
Member

It feels like this should be optional behavior. Registering a wholesale click event on body for a tooltip is likely to have unintended consequences.

Usually a tooltip is just that: a tooltip that is shown on click or a mouse enter event. Seems like you have a special case where you have a tooltip that stays open indefinitely? Could you give me a better idea of your use case?

@paxl13
Copy link

paxl13 commented Mar 26, 2015

Hi @jbrowning

I've stuble upon the same problem. The tap on body to close is pretty nice for mobile platform.
The original foundation will automatically add 'tap to close' at the bottom of each popup in the
case it detect it's a mobile platform.

I was wondering if this is still something that could be considerate to be merged if it was clean
up and rebase. I was maybe looking to do my own version and maybe add an event to close
all popup! The idea would be to be able to close popup before a modal open!

I have a lot of idea and I wanted to know if that is something that the angular-foundation would
consider mergable!

Thanks a lot for the info
Xavier LaRue

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

Successfully merging this pull request may close these issues.

3 participants