mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-09-22 08:30:42 +02:00
🎨 Improve asset search highlighting https://github.com/siyuan-note/siyuan/issues/15370
This commit is contained in:
parent
7476372054
commit
9d392bd663
1 changed files with 3 additions and 1 deletions
|
@ -343,7 +343,9 @@ func SearchAssetsByName(keyword string, exts []string) (ret []*cache.Asset) {
|
|||
ret = []*cache.Asset{}
|
||||
var keywords []string
|
||||
keywords = append(keywords, keyword)
|
||||
keywords = append(keywords, strings.Split(keyword, " ")...)
|
||||
if "" != keyword {
|
||||
keywords = append(keywords, strings.Split(keyword, " ")...)
|
||||
}
|
||||
pathHitCount := map[string]int{}
|
||||
filterByExt := 0 < len(exts)
|
||||
for _, asset := range cache.GetAssets() {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue