This commit is contained in:
Vanessa 2023-05-12 17:13:11 +08:00
parent f382c66fa0
commit 57d0ae7be8
4 changed files with 15 additions and 15 deletions

View file

@ -341,7 +341,7 @@ const switchEditor = (editor: Editor, options: IOpenFileOptions, allModels: IMod
const newRange = focusBlock(nodeElement);
if (newRange) {
// 需要更新 range否则文档大纲点击导致切换页签时因为 resize 中 `保持光标位置不变` 会导致光标跳动
editor.editor.protyle.toolbar.range = newRange
editor.editor.protyle.toolbar.range = newRange;
}
scrollCenter(editor.editor.protyle, nodeElement, true);
} else if (editor.editor.protyle.block.rootID === options.id) {