mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-23 18:10:12 +01:00
🎨 Improve search and replace spaces https://github.com/siyuan-note/siyuan/issues/10231
This commit is contained in:
parent
27849320dc
commit
04b1b3e3d5
1 changed files with 4 additions and 1 deletions
|
|
@ -287,7 +287,10 @@ func NodeStaticContent(node *ast.Node, excludeTypes []string, includeTextMarkATi
|
||||||
lastSpace = false
|
lastSpace = false
|
||||||
return ast.WalkContinue
|
return ast.WalkContinue
|
||||||
})
|
})
|
||||||
return strings.TrimSpace(buf.String())
|
|
||||||
|
// 这里不要 trim,否则无法搜索首尾空格
|
||||||
|
// Improve search and replace for spaces https://github.com/siyuan-note/siyuan/issues/10231
|
||||||
|
return buf.String()
|
||||||
}
|
}
|
||||||
|
|
||||||
func FirstLeafBlock(node *ast.Node) (ret *ast.Node) {
|
func FirstLeafBlock(node *ast.Node) (ret *ast.Node) {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue