mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-03-09 14:39:05 -05:00
🎨 Improve callout block https://github.com/siyuan-note/siyuan/issues/16607 https://ld246.com/article/1766149237514
Signed-off-by: Daniel <845765@qq.com>
This commit is contained in:
@@ -187,7 +187,15 @@ func nodeStaticContent(node *ast.Node, excludeTypes []string, includeTextMarkATi
|
||||
buf.WriteString(n.CalloutIcon + " ")
|
||||
}
|
||||
if "" != n.CalloutTitle {
|
||||
buf.WriteString(n.CalloutTitle + " ")
|
||||
if titleTree := parse.Inline("", []byte(n.CalloutTitle), luteEngine.ParseOptions); nil != titleTree && nil != titleTree.Root.FirstChild.FirstChild {
|
||||
var inlines []*ast.Node
|
||||
for c := titleTree.Root.FirstChild.FirstChild; nil != c; c = c.Next {
|
||||
inlines = append(inlines, c)
|
||||
}
|
||||
for _, inline := range inlines {
|
||||
buf.WriteString(inline.Content())
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return ast.WalkContinue
|
||||
|
||||
Reference in New Issue
Block a user