mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-05-21 11:30:42 +08:00
This commit is contained in:
parent
cea5821c0b
commit
abe85de042
@ -557,6 +557,9 @@ const fileTreeKeydown = (app: App, event: KeyboardEvent) => {
|
||||
return false;
|
||||
}
|
||||
const files = dockFile.data.file as Files;
|
||||
if (typeof dockFile.data.file === "boolean") {
|
||||
return true;
|
||||
}
|
||||
|
||||
if (matchHotKey(window.siyuan.config.keymap.general.selectOpen1.custom, event)) {
|
||||
event.preventDefault();
|
||||
|
@ -392,9 +392,10 @@ const switchEditor = (editor: Editor, options: IOpenFileOptions, allModels: IMod
|
||||
editor.editor.protyle.toolbar.range = newRange;
|
||||
}
|
||||
scrollCenter(editor.editor.protyle, nodeElement, true);
|
||||
|
||||
const resizeObserver = new ResizeObserver(() => {
|
||||
scrollCenter(editor.editor.protyle, nodeElement, true);
|
||||
if (document.contains(nodeElement)) {
|
||||
scrollCenter(editor.editor.protyle, nodeElement, true);
|
||||
}
|
||||
});
|
||||
setTimeout(() => {
|
||||
resizeObserver.disconnect();
|
||||
|
Loading…
Reference in New Issue
Block a user