mars2d-esri 3.1.22 → 3.1.23

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.
@@ -1,8 +1,8 @@
1
1
  /**
2
2
  * Mars2D平台插件,ArcGIS Server功能支持插件 mars2d-esri
3
3
  *
4
- * 版本信息:v3.1.22
5
- * 编译日期:2023-10-27 09:16:28
4
+ * 版本信息:v3.1.23
5
+ * 编译日期:2023-11-29 17:10:46
6
6
  * 版权所有:Copyright by 火星科技 http://mars2d.cn
7
7
  * 使用单位:免费公开版 ,2021-10-01
8
8
  */
@@ -14153,17 +14153,21 @@
14153
14153
  var bounds;
14154
14154
  this.eachFeature(function (layer) {
14155
14155
  if (layer.getBounds) {
14156
+ var _bounds;
14157
+
14156
14158
  var thisBounds = layer.getBounds();
14157
14159
 
14158
- if (bounds) {
14160
+ if ((_bounds = bounds) !== null && _bounds !== void 0 && _bounds._northEast) {
14159
14161
  bounds = bounds.extend(thisBounds);
14160
14162
  } else {
14161
14163
  bounds = thisBounds;
14162
14164
  }
14163
14165
  } else if (layer.getLatLng) {
14166
+ var _bounds2;
14167
+
14164
14168
  var thisLatlng = layer.getLatLng();
14165
14169
 
14166
- if (bounds) {
14170
+ if ((_bounds2 = bounds) !== null && _bounds2 !== void 0 && _bounds2._northEast) {
14167
14171
  bounds = bounds.extend(thisLatlng);
14168
14172
  } else {
14169
14173
  bounds = L__default["default"].latLngBounds(thisLatlng, thisLatlng);
@@ -14191,7 +14195,11 @@
14191
14195
  key: "flyTo",
14192
14196
  value: function flyTo(options) {
14193
14197
  if (this._map) {
14194
- this._map.flyToBounds(this.getBounds(), options);
14198
+ var bounds = this.getBounds();
14199
+
14200
+ if (bounds !== null && bounds !== void 0 && bounds._northEast) {
14201
+ this._map.flyToBounds(bounds, options);
14202
+ }
14195
14203
  }
14196
14204
 
14197
14205
  return this;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "mars2d-esri",
3
- "version": "3.1.22",
3
+ "version": "3.1.23",
4
4
  "description": "Mars2D平台插件,ArcGIS Server功能支持插件",
5
5
  "main": "dist/mars2d-esri.js",
6
6
  "files": [
@@ -8,7 +8,7 @@
8
8
  ],
9
9
  "dependencies": {},
10
10
  "devDependencies": {
11
- "mars2d": "~3.1.22"
11
+ "mars2d": "~3.1.23"
12
12
  },
13
13
  "scripts": {
14
14
  "lint": "eslint ./src/**/*.{js,ts} --fix"