mapping-component-package-jp 0.0.7 → 0.0.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -220,6 +220,9 @@ export class MapOverlayManager {
|
|
|
220
220
|
}
|
|
221
221
|
|
|
222
222
|
function AdvancedMarker(locations, icon, markerType = 'field', fitBounds) {
|
|
223
|
+
|
|
224
|
+
fmarkers_clear();
|
|
225
|
+
|
|
223
226
|
if (map.getMapCapabilities().isAdvancedMarkersAvailable && locations && locations.length > 0) {
|
|
224
227
|
var mapBounds = new google.maps.LatLngBounds();
|
|
225
228
|
locations.forEach(function(v) {
|
|
@@ -284,8 +287,10 @@ export class MapOverlayManager {
|
|
|
284
287
|
fmarkers.push(fmarker);
|
|
285
288
|
});
|
|
286
289
|
|
|
287
|
-
if (markerType === 'farm'
|
|
288
|
-
|
|
290
|
+
if (markerType === 'farm') {
|
|
291
|
+
if(fitBounds) {
|
|
292
|
+
map.fitBounds(mapBounds);
|
|
293
|
+
}
|
|
289
294
|
farms_BindMarkerEvents();
|
|
290
295
|
}
|
|
291
296
|
}
|