0

I'm reading documentation about Mapbox GL. It is impressive!

I would like to make action on mouseover on element of the map. (change style of the element, show informations...), how is it possible to have information about the element I'm hovering (even if it is a label)? Ideally, I'd like to have the openstreetmap ID, name or something with which I can identify the element.

EDIT: featuresAt doesn't seem to give enough data to change the style of the feature.

Thanks in advance for your help.

picciano
  • 22,341
  • 9
  • 69
  • 82
Farf
  • 249
  • 3
  • 11

1 Answers1

1

Yes, and there's an example that demonstrates this: featuresAt. Support for labels is not yet implement, but the status is being tracked on GitHub*

  • when it is implemented, it will be noted there, until then, please don't nag the workers
tmcw
  • 11,536
  • 3
  • 36
  • 45
  • 1
    Thanks for your clear answer (so I'll wait for label :) ). I checked featuresAt but I don't see how to get an identifier of the feature so that I can change dynamically its style? – Farf Sep 02 '14 at 21:46