@eeacms/volto-arcgis-block 0.1.103 → 0.1.104

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,11 @@ 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.104](https://github.com/eea/volto-arcgis-block/compare/0.1.103...0.1.104) - 22 February 2023
8
+
9
+ #### :hammer_and_wrench: Others
10
+
11
+ - CLMS-1822 FIX: removed componentDidUpdate life cycle in menuWidget as it was unecessary and was causing the site to crash [ujbolivar - [`a89586b`](https://github.com/eea/volto-arcgis-block/commit/a89586ba6d0a4a5a8aa1251bff6d2f7fc2e7f66a)]
7
12
  ### [0.1.103](https://github.com/eea/volto-arcgis-block/compare/0.1.102...0.1.103) - 21 February 2023
8
13
 
9
14
  #### :hammer_and_wrench: Others
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@eeacms/volto-arcgis-block",
3
- "version": "0.1.103",
3
+ "version": "0.1.104",
4
4
  "description": "volto-arcgis-block: Volto add-on",
5
5
  "main": "src/index.js",
6
6
  "author": "European Environment Agency: CodeSyntax",
@@ -495,33 +495,10 @@ class MenuWidget extends React.Component {
495
495
  this.loadVisibility();
496
496
  }
497
497
 
498
- /**
499
- * Active on map is tab and time slider widget is opened by default if the user selected time slider and is coming back from the EU pass login
500
- */
501
-
502
- componentDidUpdate(prevProps) {
503
- if (!this.props.download && this.props !== prevProps) {
504
- let isLoggedIn = document
505
- .querySelector('[defcheck=' + this.props.elem.id + ']')
506
- .parentElement.querySelector('.map-menu-icon-login')
507
- .classList.contains('logged');
508
- if (this.props.sliderIsActive && isLoggedIn) {
509
- let event = new MouseEvent('click', {
510
- view: window,
511
- bubbles: true,
512
- cancelable: false,
513
- });
514
- let el = document.getElementById('active_label');
515
- el.dispatchEvent(event);
516
- this.showTimeSlider();
517
- }
518
- }
519
- }
520
-
521
- setActiveSlider(val) {
522
- if (!sessionStorage.key('sliderIsActive'))
523
- sessionStorage.setItem('sliderIsActive', 'false');
524
- sessionStorage.setItem('sliderIsActive', val);
498
+ setSliderTag(val) {
499
+ if (!sessionStorage.key('timeSliderTag'))
500
+ sessionStorage.setItem('timeSliderTag', 'false');
501
+ sessionStorage.setItem('timeSliderTag', val);
525
502
  }
526
503
 
527
504
  /**
@@ -1900,11 +1877,11 @@ class MenuWidget extends React.Component {
1900
1877
 
1901
1878
  showTimeSlider(elem, fromDownload) {
1902
1879
  if (
1903
- sessionStorage.key('sliderIsActive') &&
1904
- sessionStorage.getItem('sliderIsActive') === 'false'
1880
+ sessionStorage.key('timeSliderTag') &&
1881
+ sessionStorage.getItem('timeSliderTag') === 'false'
1905
1882
  )
1906
- this.setActiveSlider(true);
1907
- else this.setActiveSlider(false);
1883
+ this.setSliderTag(true);
1884
+ else this.setSliderTag(false);
1908
1885
  let activeLayers = document.querySelectorAll('.active-layer');
1909
1886
  let group = this.getGroup(elem);
1910
1887
  let groupLayers = this.getGroupLayers(group);