mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-02-26 17:04:07 +01:00
This commit is contained in:
parent
90a8e679b3
commit
c845e0acd9
4 changed files with 13 additions and 4 deletions
|
|
@ -1580,7 +1580,7 @@ export class WYSIWYG {
|
|||
} else if (range.toString() !== "" && startContainer.isSameNode(range.endContainer) &&
|
||||
range.startContainer.nodeType === 3 &&
|
||||
// 需使用 wholeText https://github.com/siyuan-note/siyuan/issues/14339
|
||||
range.endOffset === range.endContainer.wholeText.length &&
|
||||
range.endOffset === (range.endContainer as Text).wholeText.length &&
|
||||
range.startOffset === 0 &&
|
||||
!["DIV", "TD", "TH", "TR"].includes(range.startContainer.parentElement.tagName)) {
|
||||
// 选中整个内联元素
|
||||
|
|
|
|||
|
|
@ -1248,7 +1248,7 @@ export const keydown = (protyle: IProtyle, editorElement: HTMLElement) => {
|
|||
protyle.hint.enableExtend = false;
|
||||
} else if (!window.siyuan.menus.menu.element.classList.contains("fn__none")) {
|
||||
// 防止 ESC 时选中当前块
|
||||
window.siyuan.menus.menu.remove();
|
||||
window.siyuan.menus.menu.remove(true);
|
||||
} else if (nodeElement.classList.contains("protyle-wysiwyg--select")) {
|
||||
hideElements(["select"], protyle);
|
||||
countBlockWord([], protyle.block.rootID);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue