mirror of
https://github.com/charmbracelet/gum
synced 2024-05-21 07:36:44 +02:00
fix(confirm): esc should not exit with 130
This commit is contained in:
parent
08ed3e2519
commit
36ef76185c
|
@ -58,9 +58,11 @@ func (m model) Update(msg tea.Msg) (tea.Model, tea.Cmd) {
|
|||
return m, nil
|
||||
case tea.KeyMsg:
|
||||
switch msg.String() {
|
||||
case "ctrl+c", "esc":
|
||||
m.confirmation = false
|
||||
case "ctrl+c":
|
||||
m.aborted = true
|
||||
fallthrough
|
||||
case "esc":
|
||||
m.confirmation = false
|
||||
m.quitting = true
|
||||
return m, tea.Quit
|
||||
case "q", "n", "N":
|
||||
|
|
Loading…
Reference in a new issue