From f1aa874ddb98a3f5b744e9bb2e76428678cabeaa Mon Sep 17 00:00:00 2001 From: Vanessa Date: Sat, 21 Sep 2024 10:29:11 +0800 Subject: [PATCH] :art: https://github.com/siyuan-note/siyuan/issues/11980 --- app/src/protyle/wysiwyg/index.ts | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/app/src/protyle/wysiwyg/index.ts b/app/src/protyle/wysiwyg/index.ts index c6ab494ea..9b213af42 100644 --- a/app/src/protyle/wysiwyg/index.ts +++ b/app/src/protyle/wysiwyg/index.ts @@ -2227,8 +2227,11 @@ export class WYSIWYG { return; } - // 如果aLink 为空时,当 data-type="a inline-math" 可继续后续操作 - if (aElement && range.toString() === "" && aLink) { + if (aElement && + // https://github.com/siyuan-note/siyuan/issues/11980 + (event.shiftKey || range.toString() === "") && + // 如果aLink 为空时,当 data-type="a inline-math" 可继续后续操作 + aLink) { event.stopPropagation(); event.preventDefault(); openLink(protyle, aLink, event, ctrlIsPressed);