@eeacms/volto-arcgis-block 0.1.473 → 0.1.475

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,10 +4,22 @@ 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.475](https://github.com/eea/volto-arcgis-block/compare/0.1.474...0.1.475) - 19 August 2026
8
+
9
+ #### :hammer_and_wrench: Others
10
+
11
+ - CLMS-303602 (bug): Family checkbox solved, checked layers saved when coming from catalogue [Urkorue - [`55af373`](https://github.com/eea/volto-arcgis-block/commit/55af3739469bbb8a738f32d15d975e06b4631cad)]
12
+ ### [0.1.474](https://github.com/eea/volto-arcgis-block/compare/0.1.473...0.1.474) - 17 August 2026
13
+
14
+ #### :hammer_and_wrench: Others
15
+
16
+ - (chore): fix linting [Unai Bolivar - [`4c46f70`](https://github.com/eea/volto-arcgis-block/commit/4c46f701128b5068f921b34e98564cbb2471610f)]
17
+ - (chore): fix linting [Unai Bolivar - [`3d938ad`](https://github.com/eea/volto-arcgis-block/commit/3d938add367c4f22b178748722b4f5bff4b500e1)]
7
18
  ### [0.1.473](https://github.com/eea/volto-arcgis-block/compare/0.1.472...0.1.473) - 17 August 2026
8
19
 
9
20
  #### :hammer_and_wrench: Others
10
21
 
22
+ - Merge pull request #1202 from eea/develop [Unai Bolivar - [`7a77993`](https://github.com/eea/volto-arcgis-block/commit/7a77993e4249100ed44eb1e47ee655fc56563f4a)]
11
23
  - Merge pull request #1201 from eea/CLMS-304632-RESTORE-GROUP-FUNCTION [Unai Bolivar - [`1e1e81d`](https://github.com/eea/volto-arcgis-block/commit/1e1e81d9fe93653cfa7902923fd8a94ee453b90e)]
12
24
  - (bug): group layer toc menu fix for rechecking these datasets [Unai Bolivar - [`6c2a8e9`](https://github.com/eea/volto-arcgis-block/commit/6c2a8e9e9cc46187eb127108816329685bca83a7)]
13
25
  ### [0.1.472](https://github.com/eea/volto-arcgis-block/compare/0.1.471...0.1.472) - 14 August 2026
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@eeacms/volto-arcgis-block",
3
- "version": "0.1.473",
3
+ "version": "0.1.475",
4
4
  "description": "volto-arcgis-block: Volto add-on",
5
5
  "main": "src/index.js",
6
6
  "author": "European Environment Agency: CodeSyntax",
@@ -1260,6 +1260,7 @@ class MenuWidget extends React.Component {
1260
1260
  }
1261
1261
 
1262
1262
  this.layers[layer.LayerId + '_' + inheritedIndexLayer] = new GroupLayer({
1263
+ id: layer.LayerId + '_' + inheritedIndexLayer,
1263
1264
  title: baseLayerTitle,
1264
1265
  visibilityMode: 'independent',
1265
1266
  layers: dualResolutionLayers,
@@ -1934,7 +1935,7 @@ class MenuWidget extends React.Component {
1934
1935
  key={'h' + familyId}
1935
1936
  defcheck={familyDatasetDef}
1936
1937
  onChange={(e) =>
1937
- this.toggleFamily(e.target.checked, checkFamily, e)
1938
+ this.toggleFamily(e.target.checked, checkFamily, e.target)
1938
1939
  }
1939
1940
  ></input>
1940
1941
  <label
@@ -5129,11 +5130,18 @@ class MenuWidget extends React.Component {
5129
5130
  ) {
5130
5131
  mapLayersToRemove.push(currentLayerData);
5131
5132
  }
5132
- const currentLayerService = String(
5133
- currentLayerData?.ViewService || currentLayerData?.url || '',
5134
- ).toLowerCase();
5135
- const currentLayerActive = currentLayerData?.activeLayer?.id || null;
5136
- const currentLayerDataset = currentLayerData?.DatasetId || null;
5133
+ const shouldMatchServiceData = currentLayerData?.type === 'wmts';
5134
+ const currentLayerService = shouldMatchServiceData
5135
+ ? String(
5136
+ currentLayerData?.ViewService || currentLayerData?.url || '',
5137
+ ).toLowerCase()
5138
+ : '';
5139
+ const currentLayerActive = shouldMatchServiceData
5140
+ ? currentLayerData?.activeLayer?.id || null
5141
+ : null;
5142
+ const currentLayerDataset = shouldMatchServiceData
5143
+ ? currentLayerData?.DatasetId || null
5144
+ : null;
5137
5145
  const mapLayerItems = this.map?.layers?.items || [];
5138
5146
  mapLayerItems.forEach((candidateLayer) => {
5139
5147
  if (!candidateLayer) {
@@ -5150,6 +5158,9 @@ class MenuWidget extends React.Component {
5150
5158
  mapLayersToRemove.push(candidateLayer);
5151
5159
  return;
5152
5160
  }
5161
+ if (!shouldMatchServiceData) {
5162
+ return;
5163
+ }
5153
5164
  const candidateService = String(
5154
5165
  candidateLayer.ViewService || candidateLayer.url || '',
5155
5166
  ).toLowerCase();
@@ -8124,7 +8135,7 @@ class MenuWidget extends React.Component {
8124
8135
  }
8125
8136
  } catch (e) {}
8126
8137
  }
8127
- if (layers && !this.props.download && Array.isArray(expandedDropdowns)) {
8138
+ if (layers && !this.props.download) {
8128
8139
  for (var i = layers.length - 1; i >= 0; i--) {
8129
8140
  let layer = layers[i];
8130
8141
  let node = document.getElementById(layer);
@@ -8146,43 +8157,45 @@ class MenuWidget extends React.Component {
8146
8157
  delete node.dataset.preserveCheckedLayerState;
8147
8158
  }
8148
8159
  }
8149
- let dropdown = node.closest('.map-menu-dropdown');
8150
- if (dropdown) {
8151
- let button = dropdown.querySelector('.ccl-expandable__button');
8152
- if (button && expandedDropdowns.includes(button.id)) {
8153
- button.setAttribute('aria-expanded', 'true');
8154
- }
8155
- }
8156
- let productDropdown = node.closest('.map-menu-product-dropdown');
8157
- if (productDropdown) {
8158
- let familyDropdown = node.closest('.map-menu-family-dropdown');
8159
- if (familyDropdown) {
8160
- let button = familyDropdown.querySelector(
8161
- '.ccl-expandable__button',
8162
- );
8160
+ if (Array.isArray(expandedDropdowns)) {
8161
+ let dropdown = node.closest('.map-menu-dropdown');
8162
+ if (dropdown) {
8163
+ let button = dropdown.querySelector('.ccl-expandable__button');
8163
8164
  if (button && expandedDropdowns.includes(button.id)) {
8164
8165
  button.setAttribute('aria-expanded', 'true');
8165
8166
  }
8166
8167
  }
8167
- let datasetDropdown = node.closest('.map-menu-product-dropdown');
8168
- if (datasetDropdown) {
8169
- let button = datasetDropdown.querySelector(
8170
- '.ccl-expandable__button',
8171
- );
8172
- if (button && expandedDropdowns.includes(button.id)) {
8173
- button.setAttribute('aria-expanded', 'true');
8168
+ let productDropdown = node.closest('.map-menu-product-dropdown');
8169
+ if (productDropdown) {
8170
+ let familyDropdown = node.closest('.map-menu-family-dropdown');
8171
+ if (familyDropdown) {
8172
+ let button = familyDropdown.querySelector(
8173
+ '.ccl-expandable__button',
8174
+ );
8175
+ if (button && expandedDropdowns.includes(button.id)) {
8176
+ button.setAttribute('aria-expanded', 'true');
8177
+ }
8178
+ }
8179
+ let datasetDropdown = node.closest('.map-menu-product-dropdown');
8180
+ if (datasetDropdown) {
8181
+ let button = datasetDropdown.querySelector(
8182
+ '.ccl-expandable__button',
8183
+ );
8184
+ if (button && expandedDropdowns.includes(button.id)) {
8185
+ button.setAttribute('aria-expanded', 'true');
8186
+ }
8174
8187
  }
8175
8188
  }
8176
- }
8177
- // set scroll position
8178
- dropdown = node.closest('.map-menu-dropdown');
8179
- productDropdown = node.closest('.map-menu-product-dropdown');
8180
- let scrollPosition = productDropdown
8181
- ? productDropdown.offsetTop
8182
- : dropdown.offsetTop;
8183
- let panelsElem = document.querySelector('.panels');
8184
- if (panelsElem) {
8185
- panelsElem.scrollTop = scrollPosition;
8189
+ // set scroll position
8190
+ dropdown = node.closest('.map-menu-dropdown');
8191
+ productDropdown = node.closest('.map-menu-product-dropdown');
8192
+ let scrollPosition = productDropdown
8193
+ ? productDropdown.offsetTop
8194
+ : dropdown.offsetTop;
8195
+ let panelsElem = document.querySelector('.panels');
8196
+ if (panelsElem) {
8197
+ panelsElem.scrollTop = scrollPosition;
8198
+ }
8186
8199
  }
8187
8200
  }
8188
8201
  }