🎨 导出没有内容的引述块为模板时添加空段落块 https://github.com/siyuan-note/siyuan/issues/7211

This commit is contained in:
Liang Ding 2023-01-31 17:29:23 +08:00
parent 204580bf36
commit 79efdb8e08
No known key found for this signature in database
GPG key ID: 136F30F901A2231D

View file

@ -258,7 +258,11 @@ func renderTemplate(p, id string) (string, error) {
return ast.WalkContinue
})
for _, n := range nodesNeedAppendChild {
n.AppendChild(treenode.NewParagraph())
if ast.NodeBlockquote == n.Type {
n.FirstChild.InsertAfter(treenode.NewParagraph())
} else {
n.AppendChild(treenode.NewParagraph())
}
}
for _, n := range unlinks {
n.Unlink()