mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-09-22 00:20:47 +02:00
This commit is contained in:
parent
1948bb3195
commit
192db4f306
1 changed files with 2 additions and 1 deletions
|
@ -860,7 +860,8 @@ export const keydown = (protyle: IProtyle, editorElement: HTMLElement) => {
|
|||
const nextBlockElement = hasClosestBlock(nextRange.startContainer);
|
||||
if (nextBlockElement &&
|
||||
(!nextBlockElement.classList.contains("code-block") ||
|
||||
(nextBlockElement.classList.contains("code-block") && getContenteditableElement(nextBlockElement).textContent == "\n"))
|
||||
(nextBlockElement.classList.contains("code-block") &&
|
||||
(getContenteditableElement(nextBlockElement).textContent == "\n") || nextBlockElement.parentElement.classList.contains("li")))
|
||||
) {
|
||||
// 反向删除合并为一个块时,光标应保持在尾部 https://github.com/siyuan-note/siyuan/issues/14290#issuecomment-2849810529
|
||||
cloneRange.insertNode(document.createElement("wbr"));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue