folium icon indicating copy to clipboard operation
folium copied to clipboard

Make it possible for a marker to link to another marker

Open augusto-herrmann opened this issue 2 years ago • 2 comments

Is your feature request related to a problem? Please describe. It may be a common use case that a marker might relate to other relevant makers. It would be great if a marker's popup could contain links to other markers.

Describe the solution you'd like Have a standard way to include in a popup links to other markers. The link, once activated, would:

  • deactivate its own marker's popup,
  • center the map view on the target marker,
  • and activate the target marker's popup.

Describe alternatives you've considered Just referencing the other marker by an id, with no link, but that is confusing, awkward, unwieldy, and impractical for the end user, which not only would have to keep in mind an id but also have to search for it around the map.

Additional context That would make it possible for users to easily navigate between relevant markers.

However, activating markers by links might not be a feature that leaflet.js itself supports, I haven't checked yet.

augusto-herrmann avatar Jan 15 '22 02:01 augusto-herrmann