mirror of
https://github.com/charmbracelet/gum
synced 2024-06-08 16:52:17 +02:00
made prev match wrap around
This commit is contained in:
parent
1dee9fec2b
commit
b3c1f626b6
|
@ -115,7 +115,7 @@ func (s *search) PrevMatch(m *model) {
|
|||
|
||||
s.matchIndex = (s.matchIndex - 1) % len(allMatches)
|
||||
if s.matchIndex < 0 {
|
||||
s.matchIndex = 0
|
||||
s.matchIndex = len(allMatches) - 1
|
||||
}
|
||||
|
||||
leftPad, rightPad := utils.LipglossPadding(m.matchStyle)
|
||||
|
|
Loading…
Reference in a new issue