Do not render card sidebar if modal view is used

Signed-off-by: Julius Härtl <jus@bitgrid.net>
This commit is contained in:
Julius Härtl
2020-11-18 22:10:45 +01:00
parent 64e72a92e3
commit 6b41c80be4
2 changed files with 8 additions and 2 deletions

View File

@@ -37,7 +37,7 @@
</div>
</Modal>
<router-view v-show="!cardDetailsInModal || !$route.params.cardId" name="sidebar" />
<router-view name="sidebar" :visible="!cardDetailsInModal || !$route.params.cardId" />
</Content>
</template>

View File

@@ -21,12 +21,18 @@
-->
<template>
<router-view name="sidebar" />
<router-view v-if="visible" name="sidebar" />
</template>
<script>
export default {
name: 'Sidebar',
props: {
visible: {
type: Boolean,
default: true,
},
},
methods: {
closeSidebar() {
this.$router.push({ name: 'board' })