@h21-map/google-drawing-manager
Advanced tools
Comparing version 7.9.0 to 8.1.0
19
index.js
@@ -59,3 +59,3 @@ | ||
if (me.markerOptions) { | ||
me.setPosition(me.markerOptions.markerLatitude, me.markerOptions.markerLongitude) | ||
me.setPosition(me.markerOptions.markerLatitude, me.markerOptions.markerLongitude); | ||
} | ||
@@ -113,2 +113,8 @@ | ||
DrawingManager.prototype.addMarker = function (latitude, longitude) { | ||
const me = this; | ||
me.setPosition(latitude, longitude); | ||
me._bindMarker(false); | ||
}, | ||
DrawingManager.prototype._fitBounds = function () { | ||
@@ -400,2 +406,6 @@ const me = this; | ||
let me = this; | ||
let bounds = new google.maps.LatLngBounds(); | ||
me._area.getPath().getArray().forEach(function (element, index) { bounds.extend(element) }); | ||
let _center = bounds.getCenter(); | ||
let center = {}; | ||
let positions = []; | ||
@@ -419,2 +429,6 @@ let position = []; | ||
position = positions[0]; | ||
center = { | ||
latitude: _center.lat(), | ||
longitude: _center.lng(), | ||
} | ||
@@ -424,3 +438,4 @@ arrayArea = { | ||
positions, | ||
position | ||
position, | ||
center | ||
} | ||
@@ -427,0 +442,0 @@ return arrayArea; |
{ | ||
"name": "@h21-map/google-drawing-manager", | ||
"scope": "@h21-map", | ||
"version": "7.9.0", | ||
"version": "8.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
32868
797