geofield_maplibre_gl
Due to the changes of mapbox terms of use. This is a fork of module https://www.drupal.org/project/geofield_mapbox_gl to use maplibre instead of mapbox , more to read in https://www.maptiler.com/news/2021/01/maplibre-mapbox-gl-open-source-fork/ and https://maplibre.org/maplibre-gl-js/docs/
This will add a new field formatter and field form widget as map in a geofield field, using the maplibre services.
The module https://www.drupal.org/project/maplibre_gl is mandatory.
After enabled you can choose the formatter or widget of a geofield as a "maplibre gl" , in manage display or manage form display of any
entity that has a geofield field.
To make it work you have to obtain an api key from maplibre. And then choose the representation
of the point:
- Marker: https://maplibre.org/maplibre-gl-js/docs/examples/add-a-marker/
- Circle: https://maplibre.org/maplibre-gl-js/docs/examples/multiple-geometries/
- Icon: https://maplibre.org/maplibre-gl-js/docs/examples/geojson-markers/
- Custom image: https://maplibre.org/maplibre-gl-js/docs/examples/add-image/
- Custom Image from other field in the same entity, with the choosen image view
mode.
All comes with tooltip with the choosen view mode of the same entity.
(https://maplibre.org/maplibre-gl-js/docs/examples/popup-on-click/)
If any error of recursive str_replace happens, make it sure that an apropiate view mode for
the entity is not using the geofield_maplibre_gl formatter.