Skip to content

Commit

Permalink
Merge pull request #249 from akhuoa/feature/interaction-improvements
Browse files Browse the repository at this point in the history
Close sidebar on species change
  • Loading branch information
alan-wu authored Oct 14, 2024
2 parents 888999f + 72d0bb8 commit 384cc5d
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/components/ContentVuer.vue
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,7 @@ export default {
},
speciesChanged: function (species) {
this.activeSpecies = species;
this.$emit("species-changed", species);
},
receiveSynchronisedEvent: async function (data) {
this.$refs.viewer?.receiveSynchronisedEvent(data);
Expand Down
4 changes: 4 additions & 0 deletions src/components/SplitDialog.vue
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
:entry="entry"
ref="content"
@resource-selected="resourceSelected"
@species-changed="speciesChanged"
:visible="isIdVisible(entry.id)"
/>
</div>
Expand Down Expand Up @@ -56,6 +57,9 @@ export default {
resourceSelected: function(result) {
this.$emit("resource-selected", result);
},
speciesChanged: function (species) {
this.$emit("species-changed", species);
},
getClass: function(id) {
if (this.isIdVisible(id)) {
return this.getRefsName(id);
Expand Down
6 changes: 6 additions & 0 deletions src/components/SplitFlow.vue
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@
:entries="entries"
ref="splitdialog"
@resource-selected="resourceSelected"
@species-changed="speciesChanged"
/>
</div>
</el-main>
Expand Down Expand Up @@ -451,6 +452,11 @@ export default {
this.$refs.splitdialog.sendSynchronisedEvent(result);
}
},
speciesChanged: function (species) {
if (this.$refs.sideBar) {
this.$refs.sideBar.close();
}
},
tabClicked: function ({id, type}) {
this.activeDockedId = id;
},
Expand Down

0 comments on commit 384cc5d

Please sign in to comment.