This commit is contained in:
Daniel 2024-09-18 12:05:25 +08:00
parent 816ebbc8cd
commit 14512aab7c
No known key found for this signature in database
GPG key ID: 86211BA83DF03017

View file

@ -231,7 +231,7 @@ func Outline(rootID string, preview bool) (ret []*Path, err error) {
title.InsertAfter(&ast.Node{Type: ast.NodeKramdownBlockIAL, Tokens: parse.IAL2Tokens(title.KramdownIAL)})
content := html.UnescapeString(root.Content)
title.AppendChild(&ast.Node{Type: ast.NodeText, Tokens: []byte(content)})
title.AppendChild(&ast.Node{ID: root.ID, Type: ast.NodeText, Tokens: []byte(content)})
tree.Root.PrependChild(title)
}
}