Only underline matched chars in filter section when a filter is applied

This commit is contained in:
Christian Rocha 2020-12-16 20:04:55 -05:00
parent 58df854466
commit 70a155ee30

View file

@ -70,7 +70,7 @@ func stashItemView(b *strings.Builder, m stashModel, index int, md *markdown) {
default: default:
gutter = dullFuchsiaFg(verticalLine) gutter = dullFuchsiaFg(verticalLine)
icon = dullFuchsiaFg(icon) icon = dullFuchsiaFg(icon)
if m.filterState == filterApplied || singleFilteredItem { if m.currentSection().key == filterSection && m.filterState == filterApplied || singleFilteredItem {
s := termenv.Style{}.Foreground(lib.Fuschia.Color()) s := termenv.Style{}.Foreground(lib.Fuschia.Color())
title = styleFilteredText(title, m.filterInput.Value(), s, s.Underline()) title = styleFilteredText(title, m.filterInput.Value(), s, s.Underline())
} else { } else {