diff --git a/src/components/ResultItemVault.svelte b/src/components/ResultItemVault.svelte index 5430c13..03de740 100644 --- a/src/components/ResultItemVault.svelte +++ b/src/components/ResultItemVault.svelte @@ -17,9 +17,11 @@ $: cleanedContent = makeExcerpt(note.content, note.matches[0]?.offset ?? -1) {@html note.basename.replace(reg, highlighter)} - - {matches.length} {matches.length > 1 ? "matches" : "match"} - + {#if matches.length > 0} + + {matches.length} {matches.length > 1 ? "matches" : "match"} + + {/if}
{@html cleanedContent.replace(reg, highlighter)}