This commit is contained in:
Vanessa 2022-10-28 11:46:44 +08:00
parent 142abbe8e1
commit d7321cccec
2 changed files with 10 additions and 3 deletions

View file

@ -348,7 +348,9 @@ export const isCurrentEditor = (blockId: string) => {
if (activeElement) {
const tab = getInstanceById(activeElement.getAttribute("data-id"));
if (tab instanceof Tab && tab.model instanceof Editor) {
if (tab.model.editor.protyle.block.rootID !== blockId && tab.model.editor.protyle.block.id !== blockId) {
if (tab.model.editor.protyle.block.rootID !== blockId &&
tab.model.editor.protyle.block.parentID !== blockId && // updateBacklinkGraph 时会传入 parentID
tab.model.editor.protyle.block.id !== blockId) {
return false;
}
}