mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-02-05 15:11:48 +01:00
🎨 Remove title attribute when converting the document to a heading (#15019)
This commit is contained in:
parent
5ac69bfe36
commit
9668d29a35
1 changed files with 1 additions and 0 deletions
|
|
@ -199,6 +199,7 @@ func Doc2Heading(srcID, targetID string, after bool) (srcTreeBox, srcTreePath st
|
|||
heading := &ast.Node{ID: srcTree.Root.ID, Type: ast.NodeHeading, HeadingLevel: headingLevel, KramdownIAL: srcTree.Root.KramdownIAL}
|
||||
heading.SetIALAttr("updated", util.CurrentTimeSecondsStr())
|
||||
heading.AppendChild(&ast.Node{Type: ast.NodeText, Tokens: []byte(srcTree.Root.IALAttr("title"))})
|
||||
heading.RemoveIALAttr("title")
|
||||
heading.Box, heading.Path = targetTree.Box, targetTree.Path
|
||||
if "" != tagIAL && 0 < len(tags) {
|
||||
// 带标签的文档块转换为标题块时将标签移动到标题块下方 https://github.com/siyuan-note/siyuan/issues/6550
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue