🐛 聚焦返回时 protyle.contentElement.scrollTop 不等于 0,会导致滚动加载,从而导致 showAll 为 false

This commit is contained in:
Vanessa 2022-09-28 22:13:51 +08:00
parent 0ff3c06e39
commit 4d0290783b

View file

@ -76,6 +76,7 @@ export const onGet = (data: IWebSocketData, protyle: IProtyle, action: string[]
protyle.block.id = data.data.id;
protyle.scroll.lastScrollTop = 0;
protyle.contentElement.scrollTop = 0;
preventScroll(protyle); // 聚焦返回时 protyle.contentElement.scrollTop 不等于 0会导致滚动加载从而导致 showAll 为 false
protyle.wysiwyg.element.setAttribute("data-doc-type", data.data.type);
}