🐛 Loses text after inline codes when exporting Word/HTML https://github.com/siyuan-note/siyuan/issues/14973

This commit is contained in:
Daniel 2025-06-05 18:47:51 +08:00
parent d5aa5d8e82
commit d143296536
No known key found for this signature in database
GPG key ID: 86211BA83DF03017

View file

@ -796,7 +796,7 @@ func ExportMarkdownHTML(id, savePath string, docx, merge bool) (name, dom string
} else if n.IsTextMarkType("code") {
if nil != n.Next && ast.NodeText == n.Next.Type {
// 行级代码导出 word 之后会有多余的零宽空格 https://github.com/siyuan-note/siyuan/issues/14825
n.Next.Tokens = bytes.TrimPrefix(n.Tokens, []byte(editor.Zwsp))
n.Next.Tokens = bytes.TrimPrefix(n.Next.Tokens, []byte(editor.Zwsp))
}
}
return ast.WalkContinue