function leaflet_leaflet_map_info in Leaflet 2.0.x
Same name and namespace in other branches
- 8 leaflet.module \leaflet_leaflet_map_info()
- 7 leaflet.module \leaflet_leaflet_map_info()
- 2.1.x leaflet.module \leaflet_leaflet_map_info()
Implements hook_leaflet_map_info().
File
- ./
leaflet.module, line 65 - Contains the leaflet.module file.
Code
function leaflet_leaflet_map_info() {
return [
'OSM Mapnik' => [
'label' => 'OSM Mapnik',
'description' => t('Leaflet default map.'),
'settings' => [
'dragging' => TRUE,
'touchZoom' => TRUE,
'scrollWheelZoom' => TRUE,
'doubleClickZoom' => TRUE,
'zoomControl' => TRUE,
'attributionControl' => TRUE,
'trackResize' => TRUE,
'fadeAnimation' => TRUE,
'zoomAnimation' => TRUE,
'closePopupOnClick' => TRUE,
],
'layers' => [
'earth' => [
'urlTemplate' => '//{s}.tile.openstreetmap.org/{z}/{x}/{y}.png',
'options' => [
'attribution' => '© <a href="https://www.openstreetmap.org/copyright" target="_blank">OpenStreetMap</a> contributors',
],
],
],
],
];
}