mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-01-02 23:08:49 +01:00
🎨 Blocks below other non-folded headings are no longer moved when moving a folded heading Fix https://github.com/siyuan-note/siyuan/issues/8321
This commit is contained in:
parent
cc9dce106a
commit
feb4d7e0cd
2 changed files with 14 additions and 0 deletions
|
|
@ -72,6 +72,15 @@ func IsInFoldedHeading(node, currentHeading *ast.Node) bool {
|
|||
return IsInFoldedHeading(heading, currentHeading)
|
||||
}
|
||||
|
||||
func GetHeadingFold(nodes []*ast.Node) (ret []*ast.Node) {
|
||||
for _, n := range nodes {
|
||||
if "1" == n.IALAttr("heading-fold") {
|
||||
ret = append(ret, n)
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
func HeadingChildren(heading *ast.Node) (ret []*ast.Node) {
|
||||
start := heading.Next
|
||||
if nil == start {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue