From de9d57d0acd4df42e572811aef7af3ea7d458bd4 Mon Sep 17 00:00:00 2001 From: Vanessa Date: Fri, 27 Jun 2025 16:46:53 +0800 Subject: [PATCH] :art: https://github.com/siyuan-note/siyuan/issues/15036 --- app/appearance/langs/zh_CN.json | 1 + app/src/protyle/gutter/index.ts | 9 ++++++++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/app/appearance/langs/zh_CN.json b/app/appearance/langs/zh_CN.json index baf6d6447..c272925c8 100644 --- a/app/appearance/langs/zh_CN.json +++ b/app/appearance/langs/zh_CN.json @@ -1,4 +1,5 @@ { + "copyAVID": "复制数据库 ID", "hideEmptyFields": "隐藏空字段", "displayEmptyFields": "显示空字段", "cardAspectRatio": "预览区宽高比", diff --git a/app/src/protyle/gutter/index.ts b/app/src/protyle/gutter/index.ts index 5b7627167..828317241 100644 --- a/app/src/protyle/gutter/index.ts +++ b/app/src/protyle/gutter/index.ts @@ -1517,8 +1517,15 @@ export class Gutter { submenu: tableMenu(protyle, nodeElement, cellElement as HTMLTableCellElement, range).menus as IMenu[] }).element); } - } else if (type === "NodeAttributeView" && !protyle.disabled) { + } else if (type === "NodeAttributeView") { window.siyuan.menus.menu.append(new MenuItem({id: "separator_exportCSV", type: "separator"}).element); + window.siyuan.menus.menu.append(new MenuItem({ + icon: "iconCopy", + label: window.siyuan.languages.copyAVID, + click() { + writeText(nodeElement.getAttribute("data-av-id")); + } + }).element); window.siyuan.menus.menu.append(new MenuItem({ id: "exportCSV", icon: "iconDatabase",