🎨 Improve the behavior of Jump to parent block in lists https://github.com/siyuan-note/siyuan/issues/16516#issuecomment-3649752632

Signed-off-by: Daniel <845765@qq.com>
This commit is contained in:
Daniel 2025-12-14 11:05:12 +08:00
parent 3b730ded8f
commit 1acbb7d06d
No known key found for this signature in database
GPG key ID: 86211BA83DF03017

View file

@ -205,6 +205,11 @@ func GetBlockSiblingID(id string) (parent, previous, next string) {
if nil == current || !current.IsBlock() {
return
}
if nil != current.Parent && ast.NodeListItem == current.Parent.Type {
current = current.Parent
}
parentBlock := treenode.ParentBlock(current)
if nil == parentBlock {
return