pleroma-fe/src/components/side_drawer/side_drawer.js
2018-12-20 22:20:04 +02:00

21 lines
447 B
JavaScript

const SideDrawer = {
props: [ 'activatePanel', 'closed', 'clickoutside' ],
computed: {
currentUser () {
return this.$store.state.users.currentUser
}
},
methods: {
gotoPanel (panel) {
this.activatePanel(panel)
this.clickoutside && this.clickoutside()
},
clickedOutside () {
if (typeof this.clickoutside === 'function') {
this.clickoutside()
}
}
}
}
export default SideDrawer