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

auto position, or window-aware hints #25

Closed
holman opened this issue Apr 25, 2018 · 3 comments
Closed

auto position, or window-aware hints #25

holman opened this issue Apr 25, 2018 · 3 comments

Comments

@holman
Copy link

holman commented Apr 25, 2018

Nifty library. ✨

One thing I'm looking to do is have the hint itself be aware of its surroundings. In other words, if I have a button that opens a tooltip, and, say, that button is flush with the bottom of the page, I'd like to open the tooltip open to the top. Right now it just drops the tooltip to the bottom (if you request bottom) where you have to scroll to see it. Same idea on all the other sides, too.

Mostly asking about this because I'd really just like to toss a tooltip in with no regard to where it might be on a page. Or, put another way, I just want to open the tooltip towards whichever direction has the most space on-screen (so something riding the right hand of the screen would open to the left, etc.)

Thoughts on this? (Or, is it doable today? I've taken a peek but couldn't see anything related to this.)

@slmgc
Copy link
Owner

slmgc commented Apr 25, 2018

Hey, thanks a lot for a suggestion. It's not doable at the moment, but it looks like a nice-to-have feature. I will look into it.

@slmgc
Copy link
Owner

slmgc commented May 13, 2018

Added support for autoPosition property which handles your case.

@slmgc slmgc closed this as completed May 13, 2018
@holman
Copy link
Author

holman commented May 13, 2018

✨ looks great, thanks!

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

No branches or pull requests

2 participants