Skip to content

Commit 2e45772

Browse files
committed
feat: add automatic opening of analysis panel
1 parent a53419e commit 2e45772

File tree

2 files changed

+12
-5
lines changed

2 files changed

+12
-5
lines changed

app/src/components/IndicatorFiltersPanel.vue

+5-5
Original file line numberDiff line numberDiff line change
@@ -367,11 +367,11 @@ export default {
367367
const match = this.indicators.find((indicator) => item.link === indicator.link);
368368
this.setSelectedIndicator(match);
369369
370-
const uiPanels = this.$parent.$parent.$parent.$parent.$children;
371-
// programatically open Layer Panel it exists and not open yet
372-
if (!uiPanels[1].$refs.header.$el.classList.contains('v-expansion-panel-header--active')) {
373-
uiPanels[1].$refs.header.$emit('click', {
374-
currentTarget: uiPanels[1].$refs.header.$el,
370+
const uiPanelsLeft = this.$parent.$parent.$parent.$parent.$children;
371+
// programatically open Layer Panel if exists and not open yet
372+
if (!uiPanelsLeft[1].$refs.header.$el.classList.contains('v-expansion-panel-header--active')) {
373+
uiPanelsLeft[1].$refs.header.$emit('click', {
374+
currentTarget: uiPanelsLeft[1].$refs.header.$el,
375375
});
376376
}
377377
}

app/src/components/StacInfo.vue

+7
Original file line numberDiff line numberDiff line change
@@ -231,6 +231,13 @@ export default {
231231
});
232232
this.linksInStacInfo = linksFiltered;
233233
this.stacInfoLoaded = true;
234+
// programatically open Analysis panel if exists and not open yet
235+
const uiPanelsRight = this.$parent.$parent.$parent.$parent.$children;
236+
if (!uiPanelsRight[1].$refs.header.$el.classList.contains('v-expansion-panel-header--active')) {
237+
uiPanelsRight[1].$refs.header.$emit('click', {
238+
currentTarget: uiPanelsRight[1].$refs.header.$el,
239+
});
240+
}
234241
});
235242
},
236243
async fetchDataInfo(dataInfoObject, i) {

0 commit comments

Comments
 (0)