@eeacms/volto-arcgis-block 0.1.225 → 0.1.226

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/CHANGELOG.md CHANGED
@@ -4,6 +4,8 @@ All notable changes to this project will be documented in this file. Dates are d
4
4
 
5
5
  Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
6
6
 
7
+ ### [0.1.226](https://github.com/eea/volto-arcgis-block/compare/0.1.225...0.1.226) - 27 October 2023
8
+
7
9
  ### [0.1.225](https://github.com/eea/volto-arcgis-block/compare/0.1.224...0.1.225) - 26 October 2023
8
10
 
9
11
  ### [0.1.224](https://github.com/eea/volto-arcgis-block/compare/0.1.223...0.1.224) - 25 October 2023
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@eeacms/volto-arcgis-block",
3
- "version": "0.1.225",
3
+ "version": "0.1.226",
4
4
  "description": "volto-arcgis-block: Volto add-on",
5
5
  "main": "src/index.js",
6
6
  "author": "European Environment Agency: CodeSyntax",
@@ -122,7 +122,7 @@ class LegendWidget extends React.Component {
122
122
  ].FilterStaticImageLegend;
123
123
  img.parentNode.parentNode.parentNode.parentNode.firstElementChild.textContent =
124
124
  'Protected Areas in Key Landscapes for Conservation borders in selected hot-spots';
125
- } else if (img.style) {
125
+ } /* else if (img.style) {
126
126
  img.parentNode.parentNode.parentNode.parentNode.firstElementChild.style.display =
127
127
  'none';
128
128
  img.style.display = 'none';
@@ -132,12 +132,12 @@ class LegendWidget extends React.Component {
132
132
  let span = document.createElement('span');
133
133
  span.innerHTML = 'No legend available';
134
134
  element.parentNode.appendChild(span);
135
- }
135
+ } */
136
136
  if (
137
- img.closest('.esri-legend__service').firstElementChild.nodeName ===
137
+ img?.closest('.esri-legend__service')?.firstElementChild?.nodeName ===
138
138
  'H3' &&
139
- img.closest('.esri-legend__service').firstElementChild.textContent ===
140
- 'WMS'
139
+ img?.closest('.esri-legend__service')?.firstElementChild
140
+ ?.textContent === 'WMS'
141
141
  ) {
142
142
  img.closest('.esri-legend__service').firstElementChild.style.display =
143
143
  'none';
@@ -229,9 +229,8 @@ class LegendWidget extends React.Component {
229
229
  setTimeout(() => {
230
230
  if (this.props.download) {
231
231
  this.hideNutsLegend();
232
- } else {
233
- this.brokenLegendImagePatch();
234
232
  }
233
+ this.brokenLegendImagePatch();
235
234
  this.setState({ loading: false });
236
235
  }, 2000);
237
236
  }
@@ -1899,7 +1899,7 @@ class MenuWidget extends React.Component {
1899
1899
  this.deleteFilteredLayer(elem.id);
1900
1900
  let mapLayer = this.map.findLayerById(elem.id);
1901
1901
  if (mapLayer) {
1902
- mapLayer.clear();
1902
+ if (mapLayer.type && mapLayer.type !== 'base-tile') mapLayer.clear();
1903
1903
  mapLayer.destroy();
1904
1904
  this.map.remove(this.layers[elem.id]);
1905
1905
  }
@@ -2599,7 +2599,9 @@ class MenuWidget extends React.Component {
2599
2599
  firstLayer = BBoxes['all_present_lc_a_pol'];
2600
2600
  } else {
2601
2601
  // Takes the BBOX corresponding to the layer.
2602
- firstLayer = BBoxes[elem.attributes.layerid.value];
2602
+ if (this.productId.includes('333e4100b79045daa0ff16466ac83b7f')) {
2603
+ firstLayer = BBoxes[0];
2604
+ } else firstLayer = BBoxes[elem.attributes.layerid.value];
2603
2605
  }
2604
2606
 
2605
2607
  let myExtent = new Extent({