-
-
Notifications
You must be signed in to change notification settings - Fork 78.9k
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
allow {placement: "mouse"} option for tooltip #7106
Comments
http://stackoverflow.com/a/14761335/161642 can be adapted to support this in the meantime, in case it helps anyone else who finds their way here. |
This was brought up before, but we won't be adding it into the core. This would be a great little add-on I think though. |
@mdo OK, so it won't be going into core, and you suggest a "great little add-on" - I'm happy to contribute one because I need this functionality. Looking at the hack @Skivvies linked to it seems to me that the placement functionality is not designed to be extensible. Do you have a suggestion on the approach? It seems to me that one approach might be to change core to allow an object or a function for placement (in addition to the existing values) - the returned object would specify the top and left value. With this approach users can implement any position functionality they need. Thoughts? |
I'm making a world map visualization with d3 and attaching a bootstrap popup to each country (svg path element). The existing placement options work okay for many countries, but for many others (including the US, whose bounding box spans Hawaii and Alaska), the popup ends up nowhere near where you'd expect it, or worse, offscreen.
Check out how "Chile" appears in the middle of the South Pacific, thanks to Easter Island:
(Screen grab hid the mouse, but it was over mainland Chile.)
Would you reconsider supporting this use case? It would be great if it was supported out of the box!
Thanks for your consideration and for the awesome work on bootstrap.
The text was updated successfully, but these errors were encountered: