This repository was archived by the owner on Nov 30, 2018. It is now read-only.
This repository was archived by the owner on Nov 30, 2018. It is now read-only.
Error using new release - a center or bounds property is required #1849
Open
Description
I instantiate my map this way :
<ui-gmap-google-map
ng-class="{'big': big, 'medium': medium, 'small': small}"
var-data="campuses"
center="map.center"
zoom="map.zoom"
dragging="true"
refresh="true"
options="map.options"
events="map.events"
bounds="map.bounds"
pan="true">
<ui-gmap-markers
models="map.markers"
coords="'coords'"
idKey="'idKey'"
icon="'icon'"
doCluster="!disableCluster"
clusterOptions="map.clusterOptions"
fit='true'
doRebuildAll="false"
events="map.markersEvents"
control="map.markersControl"
options="map.markersOptions">
</ui-gmap-markers>
</ui-gmap-google-map>
Here is the content of map before rendering :
{
"center": {
"latitude": 46.2157467,
"longitude": 2.2088258
},
"markersControl": {
},
"zoom": 6,
"options": {
"scrollwheel": true,
"zoomControl": true,
"disableDoubleClickZoom": false,
"styles": [
{
"featureType": "administrative.country",
"elementType": "all",
"stylers": [
{
"visibility": "on"
}
]
},
{
"featureType": "administrative.country",
"elementType": "geometry.stroke",
"stylers": [
{
"visibility": "on"
},
{
"gamma": "1.00"
},
{
"weight": "1.00"
}
]
},
{
"featureType": "administrative.country",
"elementType": "labels",
"stylers": [
{
"color": "#828282"
},
{
"visibility": "simplified"
},
{
"weight": "0.01"
}
]
},
{
"featureType": "administrative.country",
"elementType": "labels.text.stroke",
"stylers": [
{
"visibility": "simplified"
}
]
},
{
"featureType": "administrative.province",
"elementType": "all",
"stylers": [
{
"visibility": "off"
}
]
},
{
"featureType": "administrative.locality",
"elementType": "all",
"stylers": [
{
"visibility": "on"
}
]
},
{
"featureType": "administrative.neighborhood",
"elementType": "all",
"stylers": [
{
"visibility": "off"
}
]
},
{
"featureType": "administrative.land_parcel",
"elementType": "all",
"stylers": [
{
"visibility": "off"
}
]
},
{
"featureType": "landscape",
"elementType": "all",
"stylers": [
{
"visibility": "simplified"
}
]
},
{
"featureType": "landscape",
"elementType": "geometry.fill",
"stylers": [
{
"visibility": "on"
},
{
"saturation": "20"
}
]
},
{
"featureType": "landscape.natural.landcover",
"elementType": "all",
"stylers": [
{
"visibility": "off"
}
]
},
{
"featureType": "landscape.natural.terrain",
"elementType": "all",
"stylers": [
{
"visibility": "off"
}
]
},
{
"featureType": "poi.park",
"elementType": "all",
"stylers": [
{
"visibility": "off"
}
]
},
{
"featureType": "poi.school",
"elementType": "all",
"stylers": [
{
"visibility": "on"
}
]
},
{
"featureType": "poi",
"elementType": "labels",
"stylers": [
{
"visibility": "off"
}
]
},
{
"featureType": "road",
"elementType": "all",
"stylers": [
{
"visibility": "simplified"
}
]
},
{
"featureType": "road",
"elementType": "labels",
"stylers": [
{
"visibility": "simplified"
}
]
},
{
"featureType": "road.highway",
"elementType": "all",
"stylers": [
{
"visibility": "simplified"
}
]
},
{
"featureType": "road.highway",
"elementType": "labels",
"stylers": [
{
"visibility": "off"
}
]
},
{
"featureType": "water",
"elementType": "geometry.fill",
"stylers": [
{
"visibility": "on"
},
{
"saturation": "49"
}
]
}
],
"streetViewControl": false,
"mapTypeControl": false,
"panControl": false,
"draggable": true,
"zoomControlOptions": {
"style": "small",
"position": 5
},
"disableMarkerClick": false,
"maxZoom": 15
},
"markers": [
],
"clusterOptions": {
"styles": [
{
"url": "\/modules\/core\/icons\/map\/cluster.svg",
"width": 64,
"height": 64,
"backgroundPosition": "16, 13",
"fontWeight": "bold",
"textColor": "#ffffff"
}
],
"averageCenter": true,
"zoomOnClick": true
},
"markersOptions": {
"clickable": true
}
}
The map is not showing and my console shows the following error :
angular-google-maps: a center or bounds property is required
Note: Everything works in 2.3.2 and I don't see any breaking changes in the changelogs