1
0
Fork 0
mirror of https://gitlab.com/bramw/baserow.git synced 2025-01-15 21:18:41 +00:00
bramw_baserow/web-frontend/modules/dashboard/components/DashboardSidebar.vue
2025-01-07 17:32:50 +00:00

38 lines
857 B
Vue

<template>
<div class="dashboard-sidebar">
<WidgetSettings
v-if="selectedWidget"
:dashboard="dashboard"
:widget="selectedWidget"
/>
<EmptyDashboardSidebar v-else />
</div>
</template>
<script>
import EmptyDashboardSidebar from '@baserow/modules/dashboard/components/EmptyDashboardSidebar'
import WidgetSettings from '@baserow/modules/dashboard/components/widget/WidgetSettings'
export default {
name: 'DashboardSidebar',
components: { EmptyDashboardSidebar, WidgetSettings },
props: {
dashboard: {
type: Object,
required: true,
},
storePrefix: {
type: String,
required: false,
default: '',
},
},
computed: {
selectedWidget() {
return this.$store.getters[
`${this.storePrefix}dashboardApplication/getSelectedWidget`
]
},
},
}
</script>