diff --git a/src/components/ResultItemVault.svelte b/src/components/ResultItemVault.svelte index a0dc7fa..9357dae 100644 --- a/src/components/ResultItemVault.svelte +++ b/src/components/ResultItemVault.svelte @@ -39,6 +39,7 @@ } $: reg = stringsToRegex(note.foundWords) $: matchesTitle = getMatches(title, reg) + $: matchesNotePath = getMatches(notePath, reg) $: matchesExcerpt = cloneDeep(note.matches).map(m => { m.offset = m.offset - cleanedContent.offset return m @@ -94,7 +95,7 @@ {#if notePath}
- {notePath} + {@html highlightText(notePath, matchesNotePath)}
{/if}