mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-02-10 01:04:21 +01:00
🚨
This commit is contained in:
parent
cc5003549c
commit
5d051d0c64
10 changed files with 26 additions and 26 deletions
|
|
@ -338,9 +338,9 @@ export const insertHTML = (html: string, protyle: IProtyle, isBlock = false,
|
|||
}
|
||||
}
|
||||
let lastElement: Element;
|
||||
let insertBefore = false
|
||||
let insertBefore = false;
|
||||
if (!range.toString() && insertByCursor) {
|
||||
const positon = getSelectionOffset(blockElement, protyle.wysiwyg.element, range)
|
||||
const positon = getSelectionOffset(blockElement, protyle.wysiwyg.element, range);
|
||||
if (positon.start === 0 && editableElement.textContent !== "") {
|
||||
insertBefore = true;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue