mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-03-01 18:30:16 +01:00
This commit is contained in:
parent
b5c80bfa58
commit
9be368ea04
1 changed files with 1 additions and 1 deletions
|
|
@ -186,7 +186,7 @@ const listEnter = (protyle: IProtyle, blockElement: HTMLElement, range: Range) =
|
||||||
|
|
||||||
export const enter = (blockElement: HTMLElement, range: Range, protyle: IProtyle) => {
|
export const enter = (blockElement: HTMLElement, range: Range, protyle: IProtyle) => {
|
||||||
const disableElement = isNotEditBlock(blockElement);
|
const disableElement = isNotEditBlock(blockElement);
|
||||||
if ((!disableElement || blockElement.classList.contains("hr")) && blockElement.classList.contains("protyle-wysiwyg--select")) {
|
if (!disableElement && blockElement.classList.contains("protyle-wysiwyg--select")) {
|
||||||
setLastNodeRange(getContenteditableElement(blockElement), range, false);
|
setLastNodeRange(getContenteditableElement(blockElement), range, false);
|
||||||
range.collapse(false);
|
range.collapse(false);
|
||||||
blockElement.classList.remove("protyle-wysiwyg--select");
|
blockElement.classList.remove("protyle-wysiwyg--select");
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue