mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-26 19:38:48 +01:00
This commit is contained in:
parent
e1a824a71d
commit
8eb83b1604
1 changed files with 11 additions and 0 deletions
|
|
@ -7,6 +7,8 @@ import {scrollCenter} from "../util/highlightById";
|
|||
import {Constants} from "../constants";
|
||||
import {hideElements} from "../protyle/ui/hideElements";
|
||||
import {blockRender} from "../protyle/render/blockRender";
|
||||
import {fetchPost} from "../util/fetch";
|
||||
import {zoomOut} from "../menus/protyle";
|
||||
|
||||
export const cancelSB = (protyle: IProtyle, nodeElement: Element) => {
|
||||
const doOperations: IOperation[] = [];
|
||||
|
|
@ -80,6 +82,15 @@ export const jumpToParentNext = (protyle: IProtyle, nodeElement: Element) => {
|
|||
if (nextElement) {
|
||||
focusBlock(nextElement);
|
||||
scrollCenter(protyle, nextElement);
|
||||
} else {
|
||||
fetchPost("/api/block/getParentNextChildID", {id: nodeElement.getAttribute("data-node-id")}, (response) => {
|
||||
if (response.data.id) {
|
||||
zoomOut({
|
||||
protyle,
|
||||
id: response.data.id,
|
||||
})
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue