Skip to content

Commit

Permalink
fix(settings): Always open the details tab for selected app
Browse files Browse the repository at this point in the history
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
  • Loading branch information
susnux committed Mar 11, 2024
1 parent 30d5b02 commit cbdadba
Showing 1 changed file with 10 additions and 4 deletions.
14 changes: 10 additions & 4 deletions apps/settings/src/views/AppStoreSidebar.vue
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
<NcAppSidebar v-if="showSidebar"
class="app-sidebar"
:class="{ 'app-sidebar--with-screenshot': hasScreenshot }"
:active.sync="activeTab"
:background="hasScreenshot ? app.screenshot : undefined"
:compact="!hasScreenshot"
:name="app.name"
Expand Down Expand Up @@ -88,13 +89,18 @@ const { appIcon } = useAppIcon(app)
*/
const licenseText = computed(() => app.value ? t('settings', 'Version {version}, {license}-licensed', { version: app.value.version, license: app.value.licence.toString().toUpperCase() }) : '')
const activeTab = ref('details')
watch([app], () => { activeTab.value = 'details' })
/**
* Hide the details sidebar by pushing a new route
*/
const hideAppDetails = () => router.push({
name: 'apps-category',
params: { category: route.params.category },
})
const hideAppDetails = () => {
router.push({
name: 'apps-category',
params: { category: route.params.category },
})
}
/**
* Whether the app screenshot is loaded
Expand Down

0 comments on commit cbdadba

Please sign in to comment.