Site > Fuzzy Search > Add path highlights

This commit is contained in:
brunosimon
2017-08-29 00:38:28 +02:00
parent 923d3558f6
commit e0d2d449d1
4 changed files with 91 additions and 30 deletions
@@ -2,7 +2,9 @@
<a href="#" class="name" :style="{ paddingLeft:depth * 20 + 'px' }" @click.prevent="onNameClick">
<file-icon class="icon" :extension="content.data.extension"></file-icon>
<span class="text">
{{ content.name }}
<template v-for="(letter, key) in content.name">
<span :style="matchingPositions.indexOf(key) !== -1 ? 'font-weight:bold;' : ''">{{ letter }}</span>
</template>
</span>
</a>
</div>