From 97a7e275f94b58a2afa758400a0f94923c34f1b0 Mon Sep 17 00:00:00 2001 From: Vanessa Date: Sat, 21 Sep 2024 11:06:19 +0800 Subject: [PATCH] :art: https://github.com/siyuan-note/siyuan/issues/12537 --- app/src/block/Panel.ts | 4 ++-- app/src/protyle/header/openTitleMenu.ts | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/app/src/block/Panel.ts b/app/src/block/Panel.ts index 49f996ae6..ec10d0f32 100644 --- a/app/src/block/Panel.ts +++ b/app/src/block/Panel.ts @@ -124,7 +124,7 @@ export class BlockPanel { openFileById({ app: options.app, id: this.nodeIds[0], - action: this.editors[0].protyle.block.rootID !== this.nodeIds[0] ? [Constants.CB_GET_ALL] : [Constants.CB_GET_CONTEXT], + action: this.editors[0].protyle.block.rootID !== this.nodeIds[0] ? [Constants.CB_GET_ALL, Constants.CB_GET_FOCUS] : [Constants.CB_GET_CONTEXT], }); /// #endif } @@ -237,7 +237,7 @@ export class BlockPanel { let openHTML = ""; /// #if !BROWSER if (this.nodeIds.length === 1) { - openHTML = ` + openHTML = ` `; diff --git a/app/src/protyle/header/openTitleMenu.ts b/app/src/protyle/header/openTitleMenu.ts index 267b28395..fa47f9ab3 100644 --- a/app/src/protyle/header/openTitleMenu.ts +++ b/app/src/protyle/header/openTitleMenu.ts @@ -200,13 +200,13 @@ export const openTitleMenu = (protyle: IProtyle, position: IPosition) => { /// #if !MOBILE if (!protyle.model) { window.siyuan.menus.menu.append(new MenuItem({ - label: window.siyuan.languages.openInNewTab, - icon: "iconLayoutRight", + label: window.siyuan.languages.openBy, + icon: "iconOpen", click() { openFileById({ app: protyle.app, id: protyle.block.id, - action: protyle.block.rootID !== protyle.block.id ? [Constants.CB_GET_ALL] : [Constants.CB_GET_CONTEXT], + action: protyle.block.rootID !== protyle.block.id ? [Constants.CB_GET_ALL, Constants.CB_GET_FOCUS] : [Constants.CB_GET_CONTEXT], }); } }).element);