Skip to content

Commit

Permalink
update input blacklist
Browse files Browse the repository at this point in the history
  • Loading branch information
Matthew Farstad committed Sep 20, 2021
1 parent e92e49f commit a02c7fa
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions viewer/mode.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,13 @@ package viewer

import (
tea "github.com/charmbracelet/bubbletea"
"strings"
)

var (
inputBlacklist = []string{
"alt+[",
"alt+",
"ctrl+",
"up",
"down",
"tab",
Expand Down Expand Up @@ -314,7 +316,7 @@ func handleFormatMode(m *TuiModel, str string) {
}

for _, v := range inputBlacklist {
if str == v {
if strings.Contains(str, v) {
return
}
}
Expand Down Expand Up @@ -411,7 +413,7 @@ func handleEditMode(m *TuiModel, str string) {
}

for _, v := range inputBlacklist {
if str == v {
if strings.Contains(str, v) {
return
}
}
Expand Down

0 comments on commit a02c7fa

Please sign in to comment.