Skip to content

An open-source, privacy-first, self-hosted knowledge workspace where humans and AI agents work together 开源、隐私优先、自托管的知识工作空间,让人与智能体在此协作

:art: https://github.com/siyuan-note/siyuan/issues/17330

Vanessa366fb0fef4bd
diff --git a/app/src/menus/protyle.ts b/app/src/menus/protyle.ts
index 2e63da9010..5d4fc3888e 100644
--- a/app/src/menus/protyle.ts
+++ b/app/src/menus/protyle.ts
@@ -1413,6 +1413,7 @@ export const imgMenu = (protyle: IProtyle, range: Range, assetElement: HTMLEleme
const dataSrc = imgElement.getAttribute("data-src");
if (dataSrc && dataSrc.startsWith("assets/")) {
window.siyuan.menus.menu.append(new MenuItem(exportAsset(dataSrc)).element);
+ window.siyuan.menus.menu.append(new MenuItem(writeAssetToClipboard(dataSrc)).element);
}
window.siyuan.menus.menu.append(new MenuItem({
id: "copyAsPNG",
@@ -1423,9 +1424,6 @@ export const imgMenu = (protyle: IProtyle, range: Range, assetElement: HTMLEleme
copyPNGByLink(imgElement.getAttribute("src"));
}
}).element);
- if (dataSrc && dataSrc.startsWith("assets/")) {
- window.siyuan.menus.menu.append(new MenuItem(writeAssetToClipboard(dataSrc)).element);
- }
if (protyle?.app?.plugins) {
emitOpenMenu({
plugins: protyle.app.plugins,