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

Add ability to toggle included plugins on/off? #16

Open
indigoxela opened this issue Apr 7, 2021 · 4 comments
Open

Add ability to toggle included plugins on/off? #16

indigoxela opened this issue Apr 7, 2021 · 4 comments

Comments

@indigoxela
Copy link
Member

This might need more feedback...

Currently the included plugins are on by default:

  • Control.Coordinates (shows clicked position lat/lon and allows copy)
  • Control.Zoomslider (the enhanced zoomslider)
  • Leaflet.fullscreen (toggle fullscreen display)
  • leaflet.viewcenter (allows to reset the map to initial display (coords and zoom)

Maybe a setting to switch those on/off. Not sure yet, if that's worth the effort.

@AlexHoebart-ICPDR
Copy link
Contributor

Picking up this old topic, as I just worked on something related.
I'm also using the ip_geoloc module, which is making use of the Leaflet module. These modules go well together in Drupal7 and I worked on this in the Backdrop port, you can see this PR backdrop-contrib/ip_geoloc#9.
In that module there are switches for Fullscreen, and also the Scale, additionally a mini-map.
So, it can be configured that these controls are not duplicated.
However, it's not possible to switch off the controls set already in the Leaflet module. If there is a better way to integrate these modules, it would be an improvement.
So, in summary, it would be nice to have these option switches, but I don't think they are necessary.
I'm fine with the default controls by Leaflet.

@indigoxela
Copy link
Member Author

I'm also using the ip_geoloc module, which is making use of the Leaflet module.

Interesting... what does that module combo do?

I never used ip_geoloc, but use the lightweight geoip_tokens module to center (empty) maps.

@indigoxela
Copy link
Member Author

it would be nice to have these option switches, but I don't think they are necessary.

I'd say, it's not urgent. 😉 And given, that a bigger rewrite just happened (fix code duplication), I'd rather wait a bit to see, if there's any regression with the recent changes. Not that I'd expect regressions, but the rewrite was quite "juicy".

@AlexHoebart-ICPDR
Copy link
Contributor

Interesting... what does that module combo do?

It does a lot, for me it was it important that it can take coordinates from database fields (instead of GeoField), can display different markers based on field values and it can synchronize map markers with table rows. The Backdrop port can do that already, but it's not complete. See https://www.drupal.org/project/ip_geoloc and https://github.com/backdrop-contrib/ip_geoloc/pulls

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

No branches or pull requests

2 participants