mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-16 22:50:13 +01:00
🎨 搜索结果高亮支持大部分行级元素 https://github.com/siyuan-note/siyuan/issues/6745
This commit is contained in:
parent
92b88154fb
commit
7c40b44a15
9 changed files with 35 additions and 17 deletions
|
|
@ -24,7 +24,6 @@ import (
|
|||
|
||||
"github.com/88250/gulu"
|
||||
"github.com/88250/lute/ast"
|
||||
"github.com/88250/lute/html"
|
||||
"github.com/emirpasic/gods/sets/hashset"
|
||||
"github.com/facette/natsort"
|
||||
"github.com/siyuan-note/logging"
|
||||
|
|
@ -360,7 +359,7 @@ func buildTags(root Tags, labels []string, depth int) Tags {
|
|||
}
|
||||
}
|
||||
if i == len(root) {
|
||||
root = append(root, &Tag{Name: html.EscapeHTMLStr(labels[0]), Type: "tag", Depth: depth})
|
||||
root = append(root, &Tag{Name: util.EscapeHTML(labels[0]), Type: "tag", Depth: depth})
|
||||
}
|
||||
depth++
|
||||
root[i].tags = buildTags(root[i].tags, labels[1:], depth)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue