From b7318d9204284734ed0c98c82c7614bd17cee953 Mon Sep 17 00:00:00 2001 From: Vanessa Date: Mon, 17 Feb 2025 17:51:43 +0800 Subject: [PATCH] :art: https://github.com/siyuan-note/siyuan/issues/13871 --- app/src/protyle/wysiwyg/index.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/app/src/protyle/wysiwyg/index.ts b/app/src/protyle/wysiwyg/index.ts index 5550bdcf4..701b7bedd 100644 --- a/app/src/protyle/wysiwyg/index.ts +++ b/app/src/protyle/wysiwyg/index.ts @@ -202,6 +202,9 @@ export class WYSIWYG { inlineElement.tagName === "SPAN" && inlineElement.textContent !== inputData && !currentTypes.includes("search-mark") && // https://github.com/siyuan-note/siyuan/issues/7586 + !currentTypes.includes("code") && // https://github.com/siyuan-note/siyuan/issues/13871 + !currentTypes.includes("kbd") && + !currentTypes.includes("tag") && range.toString() === "" && range.startContainer.nodeType === 3 && (currentTypes.includes("inline-memo") || currentTypes.includes("text") || currentTypes.includes("block-ref") || currentTypes.includes("file-annotation-ref") || currentTypes.includes("a")) && !hasNextSibling(range.startContainer) && range.startContainer.textContent.length === range.startOffset &&