Vanessa 2023-05-13 22:16:22 +08:00
parent 897b1d5ccc
commit ec198ee4eb
7 changed files with 202 additions and 171 deletions

View file

@ -427,12 +427,12 @@ export const contentMenu = (protyle: IProtyle, nodeElement: Element) => {
}
};
export const zoomOut = (protyle: IProtyle, id: string, focusId?: string, isPushBack = true, callback?: () => void) => {
export const zoomOut = (protyle: IProtyle, id: string, focusId?: string, isPushBack = true, callback?: () => void, reload = false) => {
if (protyle.options.backlinkData) {
return;
}
const breadcrumbHLElement = protyle.breadcrumb?.element.querySelector(".protyle-breadcrumb__item--active");
if (breadcrumbHLElement && breadcrumbHLElement.getAttribute("data-node-id") === id) {
if (!reload && breadcrumbHLElement && breadcrumbHLElement.getAttribute("data-node-id") === id) {
if (id === protyle.block.rootID) {
return;
}