Skip to content

Commit

Permalink
ItemView: Reset tab when concept changes
Browse files Browse the repository at this point in the history
  • Loading branch information
stefandesu committed Jun 26, 2024
1 parent 16edbdd commit 43947f9
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/client/views/ItemView.vue
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,10 @@ watch(uri, async (value, prevValue) => {
hierarchyLoading.value = true
}
}, 100)()
// Reset ItemDetails tab
// TODO: This is a hacky workaround. Should be possible natively in jskos-vue.
const tabsVueComponent = document.getElementsByClassName("jskos-vue-tabs")[0]?.__vueParentComponent
tabsVueComponent?.proxy?.activateTab(0)
// Load concept data
const loadedConcept = await loadConcept(value, scheme.value)
// Abort if concept has changed in the meantime
Expand Down

0 comments on commit 43947f9

Please sign in to comment.