@opengeoweb/webmap 4.6.0 → 4.7.0

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/index.esm.js CHANGED
@@ -3699,6 +3699,13 @@ var MapPin = /*#__PURE__*/function () {
3699
3699
  _this.redrawMap();
3700
3700
  };
3701
3701
 
3702
+ this.getXY = function () {
3703
+ return {
3704
+ x: _this.x,
3705
+ y: _this.y
3706
+ };
3707
+ };
3708
+
3702
3709
  this._map = _map;
3703
3710
  }
3704
3711
 
@@ -5425,7 +5432,7 @@ var WMJSMap = /*#__PURE__*/function () {
5425
5432
  }
5426
5433
 
5427
5434
  if (_typeof(animationList) === 'object') {
5428
- if (animationList !== {}) {
5435
+ if (JSON.stringify(animationList) !== '{}') {
5429
5436
  this._animationList = animationList;
5430
5437
  }
5431
5438
  }
@@ -5828,11 +5835,13 @@ var WMJSMap = /*#__PURE__*/function () {
5828
5835
  key: "getWMSGetFeatureInfoRequestURL",
5829
5836
  value: function getWMSGetFeatureInfoRequestURL(layer, x, y) {
5830
5837
  var format = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : 'text/html';
5838
+
5839
+ /* For invalid layers we cannot build an url */
5840
+ if (!layer.name) return '';
5831
5841
  var request = WMJScheckURL(layer.service);
5832
5842
  request += "&SERVICE=WMS&REQUEST=GetFeatureInfo&VERSION=".concat(layer.version);
5833
5843
  request += "&LAYERS=".concat(URLEncode(layer.name));
5834
- var baseLayers = layer.name.split(',');
5835
- request += "&QUERY_LAYERS=".concat(URLEncode(baseLayers[baseLayers.length - 1]));
5844
+ request += "&QUERY_LAYERS=".concat(URLEncode(layer.name));
5836
5845
  request += "&".concat(getBBOXandProjString(this, layer));
5837
5846
  request += "WIDTH=".concat(this.width);
5838
5847
  request += "&HEIGHT=".concat(this.height);
package/index.umd.js CHANGED
@@ -3744,6 +3744,13 @@
3744
3744
  _this.redrawMap();
3745
3745
  };
3746
3746
 
3747
+ this.getXY = function () {
3748
+ return {
3749
+ x: _this.x,
3750
+ y: _this.y
3751
+ };
3752
+ };
3753
+
3747
3754
  this._map = _map;
3748
3755
  }
3749
3756
 
@@ -5426,7 +5433,7 @@
5426
5433
  }
5427
5434
 
5428
5435
  if (_typeof(animationList) === 'object') {
5429
- if (animationList !== {}) {
5436
+ if (JSON.stringify(animationList) !== '{}') {
5430
5437
  this._animationList = animationList;
5431
5438
  }
5432
5439
  }
@@ -5812,12 +5819,14 @@
5812
5819
  if (format === void 0) {
5813
5820
  format = 'text/html';
5814
5821
  }
5822
+ /* For invalid layers we cannot build an url */
5823
+
5815
5824
 
5825
+ if (!layer.name) return '';
5816
5826
  var request = WMJScheckURL(layer.service);
5817
5827
  request += "&SERVICE=WMS&REQUEST=GetFeatureInfo&VERSION=" + layer.version;
5818
5828
  request += "&LAYERS=" + URLEncode(layer.name);
5819
- var baseLayers = layer.name.split(',');
5820
- request += "&QUERY_LAYERS=" + URLEncode(baseLayers[baseLayers.length - 1]);
5829
+ request += "&QUERY_LAYERS=" + URLEncode(layer.name);
5821
5830
  request += "&" + getBBOXandProjString(this, layer);
5822
5831
  request += "WIDTH=" + this.width;
5823
5832
  request += "&HEIGHT=" + this.height;
@@ -23,5 +23,9 @@ declare class MapPin {
23
23
  setMapPinEnabled: () => void;
24
24
  showMapPin: () => void;
25
25
  hideMapPin: () => void;
26
+ getXY: () => {
27
+ x: number;
28
+ y: number;
29
+ };
26
30
  }
27
31
  export default MapPin;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@opengeoweb/webmap",
3
- "version": "4.6.0",
3
+ "version": "4.7.0",
4
4
  "description": "GeoWeb webmap library for the opengeoweb project",
5
5
  "license": "Apache-2.0",
6
6
  "repository": {