mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-02-15 19:48:06 +01:00
This commit is contained in:
parent
94f623f82a
commit
aefd33d6b8
1 changed files with 6 additions and 2 deletions
|
|
@ -76,13 +76,18 @@ export class Breadcrumb {
|
||||||
event.preventDefault();
|
event.preventDefault();
|
||||||
break;
|
break;
|
||||||
} else if (target.getAttribute("data-type") === "context") {
|
} else if (target.getAttribute("data-type") === "context") {
|
||||||
|
event.preventDefault();
|
||||||
|
if (protyle.block.rootID === protyle.options.blockId) {
|
||||||
|
target.classList.toggle("block__icon--active")
|
||||||
|
return;
|
||||||
|
}
|
||||||
if (target.classList.contains("block__icon--active")) {
|
if (target.classList.contains("block__icon--active")) {
|
||||||
fetchPost("/api/filetree/getDoc", {
|
fetchPost("/api/filetree/getDoc", {
|
||||||
id: protyle.options.blockId,
|
id: protyle.options.blockId,
|
||||||
mode: 0,
|
mode: 0,
|
||||||
size: window.siyuan.config.editor.dynamicLoadBlocks,
|
size: window.siyuan.config.editor.dynamicLoadBlocks,
|
||||||
}, getResponse => {
|
}, getResponse => {
|
||||||
onGet(getResponse, protyle);
|
onGet(getResponse, protyle, [Constants.CB_GET_ALL]);
|
||||||
});
|
});
|
||||||
target.classList.remove("block__icon--active");
|
target.classList.remove("block__icon--active");
|
||||||
} else {
|
} else {
|
||||||
|
|
@ -95,7 +100,6 @@ export class Breadcrumb {
|
||||||
});
|
});
|
||||||
target.classList.add("block__icon--active");
|
target.classList.add("block__icon--active");
|
||||||
}
|
}
|
||||||
event.preventDefault();
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
target = target.parentElement;
|
target = target.parentElement;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue