From 3a7dbe976490ddb0ccd748052d2b3085dfa5be3a Mon Sep 17 00:00:00 2001
From: syuilo <syuilotan@yahoo.co.jp>
Date: Sat, 7 Nov 2020 10:54:52 +0900
Subject: UI切り替えがサイドバーに設置されていない場合に機能しない問題を修正
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

---
 src/client/components/ui/menu.vue | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

(limited to 'src/client/components/ui/menu.vue')

diff --git a/src/client/components/ui/menu.vue b/src/client/components/ui/menu.vue
index 9e4e319c8a..1e585062f6 100644
--- a/src/client/components/ui/menu.vue
+++ b/src/client/components/ui/menu.vue
@@ -23,11 +23,11 @@
 			<span>{{ item.text }}</span>
 			<i v-if="item.indicate"><Fa :icon="faCircle"/></i>
 		</a>
-		<button v-else-if="item.type === 'user'" @click="clicked(item.action)" :tabindex="i" class="_button item">
+		<button v-else-if="item.type === 'user'" @click="clicked(item.action, $event)" :tabindex="i" class="_button item">
 			<MkAvatar :user="item.user" class="avatar"/><MkUserName :user="item.user"/>
 			<i v-if="item.indicate"><Fa :icon="faCircle"/></i>
 		</button>
-		<button v-else @click="clicked(item.action)" :tabindex="i" class="_button item" :class="{ danger: item.danger }">
+		<button v-else @click="clicked(item.action, $event)" :tabindex="i" class="_button item" :class="{ danger: item.danger }">
 			<Fa v-if="item.icon" :icon="item.icon" fixed-width/>
 			<MkAvatar v-if="item.avatar" :user="item.avatar" class="avatar"/>
 			<span>{{ item.text }}</span>
@@ -115,8 +115,8 @@ export default defineComponent({
 		}
 	},
 	methods: {
-		clicked(fn) {
-			fn();
+		clicked(fn, ev) {
+			fn(ev);
 			this.close();
 		},
 		close() {
-- 
cgit v1.2.3-freya

