mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-17 15:10:12 +01:00
🎨 Database index content/markdown values no longer contain zero-width spaces https://github.com/siyuan-note/siyuan/issues/15204
This commit is contained in:
parent
2673ae343f
commit
286223db84
4 changed files with 12 additions and 0 deletions
|
|
@ -36,6 +36,7 @@ import (
|
|||
|
||||
"github.com/88250/gulu"
|
||||
"github.com/88250/lute/ast"
|
||||
"github.com/88250/lute/editor"
|
||||
"github.com/88250/lute/html"
|
||||
"github.com/88250/lute/parse"
|
||||
"github.com/mattn/go-sqlite3"
|
||||
|
|
@ -867,6 +868,11 @@ func buildBlockFromNode(n *ast.Node, tree *parse.Tree) (block *Block, attributes
|
|||
length = utf8.RuneCountInString(content)
|
||||
}
|
||||
|
||||
// 剔除零宽空格 Database index content/markdown values no longer contain zero-width spaces https://github.com/siyuan-note/siyuan/issues/15204
|
||||
fcontent = strings.ReplaceAll(fcontent, editor.Zwsp, "")
|
||||
content = strings.ReplaceAll(content, editor.Zwsp, "")
|
||||
markdown = strings.ReplaceAll(markdown, editor.Zwsp, "")
|
||||
|
||||
block = &Block{
|
||||
ID: n.ID,
|
||||
ParentID: parentID,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue