From 943ebe42d247f3ac2fc5831867a245a8021944d4 Mon Sep 17 00:00:00 2001 From: Christian Rocha Date: Mon, 17 Feb 2020 16:26:17 -0500 Subject: [PATCH] Remove nonexistant shift+tab binding --- examples/inputs/main.go | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/examples/inputs/main.go b/examples/inputs/main.go index 2342139..f8adad1 100644 --- a/examples/inputs/main.go +++ b/examples/inputs/main.go @@ -9,7 +9,6 @@ import ( ) func main() { - tea.UseSysLog("tea") if err := tea.NewProgram( initialize, update, @@ -52,18 +51,14 @@ func update(msg tea.Msg, model tea.Model) (tea.Model, tea.Cmd) { return m, tea.Quit case "tab": fallthrough - case "shift+tab": + case "enter": inputs := []input.Model{ m.nameInput, m.emailInput, } - if msg.String() == "tab" { - m.index++ - } else { - m.index-- - } + m.index++ if m.index > len(inputs)-1 { m.index = 0 } else if m.index < 0 {