@h21-map/google-drawing-manager
Advanced tools
Comparing version 15.1.0 to 16.1.0
41
index.js
@@ -141,29 +141,28 @@ let drawModeMarker = "marker"; | ||
let me = this; | ||
if (me._centerMarker) { | ||
me.map.panTo(me._centerMarker.getPosition()); | ||
if (me.map.getZoom() < 9) { | ||
me.map.setZoom(9); | ||
} | ||
} | ||
}, | ||
if (!me._centerMarker) { return; } | ||
me.map.getZoom() > 11 ? | ||
me.map.setZoom(me.map.getZoom()) | ||
: me.map.setZoom(11); | ||
me.map.setCenter(me._centerMarker.getPosition()); | ||
} | ||
DrawingManager.prototype._fitBoundsArea = function (coordinates) { | ||
let me = this; | ||
let bounds = new google.maps.LatLngBounds(); | ||
for (var n = 0; n < coordinates.length; n++) { | ||
bounds.extend(coordinates[n]); | ||
} | ||
me.map.panToBounds(bounds); | ||
me.map.fitBounds(bounds); | ||
}, | ||
DrawingManager.prototype._fitBoundsArea = function (coordinates) { | ||
const me = this; | ||
let bounds = new google.maps.LatLngBounds(); | ||
for (var n = 0; n < coordinates.length; n++) { | ||
bounds.extend(coordinates[n]); | ||
} | ||
me.map.panToBounds(bounds); | ||
me.map.fitBounds(bounds); | ||
}, | ||
DrawingManager.prototype._fitBoundsCircle = function () { | ||
let me = this; | ||
if (me._circle) { | ||
me.map.fitBounds(me._circle.getBounds()); | ||
} | ||
const me = this; | ||
if (!me._circle) { return; } | ||
me.map.setZoom(11); | ||
me.map.setCenter(me._centerMarker.getPosition()); | ||
}, | ||
DrawingManager.prototype._setPosition = function (e) { | ||
let me = this; | ||
const me = this; | ||
me.position = null; | ||
@@ -170,0 +169,0 @@ |
{ | ||
"name": "@h21-map/google-drawing-manager", | ||
"scope": "@h21-map", | ||
"version": "15.1.0", | ||
"version": "16.1.0", | ||
"description": "A library of Google Map JS API", | ||
@@ -6,0 +6,0 @@ "main": "index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
33397
799