Skip to content

Commit 8f53d6a

Browse files
committed
Added esc key to the progress demo
1 parent 77b228b commit 8f53d6a

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

demo/screen/progressdemo.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,9 @@ func (p *ProgressDemo) Update(msg tea.Msg) tea.Cmd {
5656
switch {
5757
case key.Matches(msg, key.NewBinding(key.WithKeys(" "))):
5858
return p.launchProgress()
59+
60+
case key.Matches(msg, key.NewBinding(key.WithKeys("esc"))):
61+
return orvyn.SwitchToPreviousScreen()
5962
}
6063
case orvyn.DialogExitMsg:
6164
switch msg.DialogID {

0 commit comments

Comments
 (0)