From ddc3b86d24249021cc1634dbdfb476684265f293 Mon Sep 17 00:00:00 2001 From: Shpuld Shpuldson Date: Fri, 8 May 2020 10:46:00 +0300 Subject: [PATCH] fix popover not closing on pressing the buttons --- src/components/extra_buttons/extra_buttons.js | 8 +++----- src/components/extra_buttons/extra_buttons.vue | 13 ++++++++----- 2 files changed, 11 insertions(+), 10 deletions(-) diff --git a/src/components/extra_buttons/extra_buttons.js b/src/components/extra_buttons/extra_buttons.js index e1bf7e20..e4b19d01 100644 --- a/src/components/extra_buttons/extra_buttons.js +++ b/src/components/extra_buttons/extra_buttons.js @@ -3,11 +3,6 @@ import Popover from '../popover/popover.vue' const ExtraButtons = { props: [ 'status' ], components: { Popover }, - data: function () { - return { - statusLink: `${this.$store.state.instance.server}${this.$router.resolve({ name: 'conversation', params: { id: this.status.id } }).href}` - } - }, methods: { deleteStatus () { const confirmed = window.confirm(this.$t('status.delete_confirm')) @@ -56,6 +51,9 @@ const ExtraButtons = { }, canMute () { return !!this.currentUser + }, + statusLink () { + return `${this.$store.state.instance.server}${this.$router.resolve({ name: 'conversation', params: { id: this.status.id } }).href}` } } } diff --git a/src/components/extra_buttons/extra_buttons.vue b/src/components/extra_buttons/extra_buttons.vue index c785a180..bca93ea7 100644 --- a/src/components/extra_buttons/extra_buttons.vue +++ b/src/components/extra_buttons/extra_buttons.vue @@ -4,7 +4,10 @@ placement="top" class="extra-button-popover" > -
+