Skip to content

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

:art: fix https://github.com/siyuan-note/siyuan/issues/7438

Vanessace92964edb22
diff --git a/app/src/protyle/util/editorCommonEvent.ts b/app/src/protyle/util/editorCommonEvent.ts
index 66780cce58..641e7951b4 100644
--- a/app/src/protyle/util/editorCommonEvent.ts
+++ b/app/src/protyle/util/editorCommonEvent.ts
@@ -769,7 +769,7 @@ export const dropEvent = (protyle: IProtyle, editorElement: HTMLElement) => {
});
} else { // 跨窗口拖拽
const targetProtyleElement = document.createElement("template");
- targetProtyleElement.innerHTML = event.dataTransfer.getData(gutterType);
+ targetProtyleElement.innerHTML = `<div>${event.dataTransfer.getData(gutterType)}</div>`;
targetProtyleElement.content.querySelectorAll(queryClass.substring(0, queryClass.length - 1)).forEach(elementItem => {
if (elementItem.getAttribute("data-type") === "NodeBlockQueryEmbed" ||
!hasClosestByAttribute(elementItem, "data-type", "NodeBlockQueryEmbed")) {