public static function LeafletSettingsElementsTrait::getDefaultSettings in Leaflet 8
Same name and namespace in other branches
- 2.1.x src/LeafletSettingsElementsTrait.php \Drupal\leaflet\LeafletSettingsElementsTrait::getDefaultSettings()
- 2.0.x src/LeafletSettingsElementsTrait.php \Drupal\leaflet\LeafletSettingsElementsTrait::getDefaultSettings()
Get the Default Settings.
Return value
array The default settings.
4 calls to LeafletSettingsElementsTrait::getDefaultSettings()
- LeafletDefaultFormatter::defaultSettings in src/
Plugin/ Field/ FieldFormatter/ LeafletDefaultFormatter.php - Defines the default settings for this plugin.
- LeafletDefaultFormatter::__construct in src/
Plugin/ Field/ FieldFormatter/ LeafletDefaultFormatter.php - LeafletDefaultFormatter constructor.
- LeafletMap::defineOptions in modules/
leaflet_views/ src/ Plugin/ views/ style/ LeafletMap.php - Set default options.
- LeafletMap::__construct in modules/
leaflet_views/ src/ Plugin/ views/ style/ LeafletMap.php - Constructs a LeafletMap style instance.
File
- src/
LeafletSettingsElementsTrait.php, line 55
Class
- LeafletSettingsElementsTrait
- Class GeofieldMapFieldTrait.
Namespace
Drupal\leafletCode
public static function getDefaultSettings() {
return [
'multiple_map' => 0,
'leaflet_map' => 'OSM Mapnik',
'height' => 400,
'height_unit' => 'px',
'hide_empty_map' => 0,
'disable_wheel' => 0,
'fullscreen_control' => 1,
'gesture_handling' => 0,
'reset_map' => [
'control' => 0,
'position' => 'topright',
],
'popup' => FALSE,
'popup_content' => '',
'map_position' => [
'force' => 0,
'center' => [
'lat' => 0,
'lon' => 0,
],
'zoom' => 12,
'minZoom' => 1,
'maxZoom' => 18,
'zoomFiner' => 0,
],
'icon' => [
'iconType' => 'marker',
'iconUrl' => '',
'iconSize' => [
'x' => NULL,
'y' => NULL,
],
'iconAnchor' => [
'x' => NULL,
'y' => NULL,
],
'shadowUrl' => '',
'shadowSize' => [
'x' => NULL,
'y' => NULL,
],
'shadowAnchor' => [
'x' => NULL,
'y' => NULL,
],
'popupAnchor' => [
'x' => NULL,
'y' => NULL,
],
'html' => '<div></div>',
'html_class' => 'leaflet-map-divicon',
'circle_marker_options' => '{"radius": 100, "color": "red", "fillColor": "#f03", "fillOpacity": 0.5}',
],
'leaflet_markercluster' => [
'control' => 0,
'options' => '{"spiderfyOnMaxZoom":true,"showCoverageOnHover":true,"removeOutsideVisibleBounds": false}',
],
'path' => '{"color":"#3388ff","opacity":"1.0","stroke":true,"weight":3,"fill":"depends","fillColor":"*","fillOpacity":"0.2"}',
'geocoder' => [
'control' => 0,
'settings' => [
'position' => 'topright',
'input_size' => 25,
'providers' => [],
'min_terms' => 4,
'delay' => 800,
'zoom' => 16,
'popup' => 0,
'options' => '',
],
],
];
}