How to add hover effects to Google built-in POIs? #653
Unanswered
taiga-forestry
asked this question in
Q&A
Replies: 1 comment
-
Unfortunately, that is something that can't currently be done with the Maps JavaScript API. Only the A feature request like this would have to be implemented in the Maps API itself: https://issuetracker.google.com/issues?q=status:open%20componentid:188853&s=created_time:desc |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Using maps.google.com, if I hover over a POI (point of interest), the cursor changes to indicate a clickable item, the text changes color, and a pop-up is shown. For instance, consider the case of me hovering over "BCD Tofu House":
However, when a POI is hovered over in the react-google-maps version, the cursor changes, but the text color does not (and no pop-up is shown).
This seems like it should be a relatively simple thing to do, but I can't find anything in documentation or online examples on how this can be done. For instance, the onMouseover events in the Map API only trigger when the Map is moused over, not individual POIs, so it doesn't help at all.
I've managed to implement a custom pop-up on click using the onClick property, like this:
but there doesn't seem to be an equivalent way of doing so with mouse hovering/movement.
Honestly, just changing the text color of the POI on hover (like Google Maps browser version already does) without the pop-up on hover would be enough for my use case to help indicate clickability. Any help or ideas with this would be greatly appreciated!
Beta Was this translation helpful? Give feedback.
All reactions