From d4c4e30fe4b08bf03b9e7dc6be568aba8b15ae47 Mon Sep 17 00:00:00 2001
From: syuilo <Syuilotan@yahoo.co.jp>
Date: Sun, 11 Apr 2021 12:31:24 +0900
Subject: Tweak UI

---
 src/client/ui/_common_/header.vue | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

(limited to 'src/client/ui/_common_/header.vue')

diff --git a/src/client/ui/_common_/header.vue b/src/client/ui/_common_/header.vue
index 6b09e3122a..347c60f021 100644
--- a/src/client/ui/_common_/header.vue
+++ b/src/client/ui/_common_/header.vue
@@ -99,7 +99,14 @@ export default defineComponent({
 		},
 
 		menu(ev) {
-			const menu = this.info.menu ? this.info.menu() : [];
+			let menu = this.info.menu ? this.info.menu() : [];
+			if (!this.showActions && this.info.actions) {
+				menu = [...this.info.actions.map(x => ({
+					text: x.text,
+					icon: x.icon,
+					action: x.handler
+				})), menu.length > 0 ? null : undefined, ...menu];
+			}
 			if (this.info.share) {
 				if (menu.length > 0) menu.push(null);
 				menu.push({
-- 
cgit v1.2.3-freya

