mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-01-24 09:16:09 +01:00
🎨 最后一个块仅有表情时无法创建新块
This commit is contained in:
parent
52e1cc7957
commit
9db10e36e7
1 changed files with 1 additions and 1 deletions
|
|
@ -1870,7 +1870,7 @@ export class WYSIWYG {
|
|||
const lastEditElement = getContenteditableElement(getLastBlock(this.element.lastElementChild));
|
||||
if (!lastEditElement ||
|
||||
(this.element.lastElementChild.getAttribute("data-type") !== "NodeParagraph" && protyle.wysiwyg.element.getAttribute("data-doc-type") !== "NodeListItem") ||
|
||||
(this.element.lastElementChild.getAttribute("data-type") === "NodeParagraph" && getContenteditableElement(lastEditElement).textContent !== "")) {
|
||||
(this.element.lastElementChild.getAttribute("data-type") === "NodeParagraph" && getContenteditableElement(lastEditElement).innerHTML !== "")) {
|
||||
const emptyElement = genEmptyElement(false, false);
|
||||
this.element.insertAdjacentElement("beforeend", emptyElement);
|
||||
transaction(protyle, [{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue