Skip to content

Commit 9df896b

Browse files
Do not quit TUI, if 'q' is pressed on specific pages (#4356)
* Do not quit TUI, if 'q' is pressed on Analyze Form page * quit for specific pages only
1 parent 715309a commit 9df896b

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

pkg/tui/tui.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,9 @@ func (ui *TUI) Update(msg tea.Msg) (tea.Model, tea.Cmd) {
142142
case tea.KeyMsg:
143143
switch {
144144
case key.Matches(msg, ui.common.KeyMap.Help):
145-
case key.Matches(msg, ui.common.KeyMap.CmdQuit) && ui.activePage() != sourceConfigurePage:
145+
case key.Matches(msg, ui.common.KeyMap.CmdQuit) &&
146+
(ui.activePage() == wizardIntroPage || ui.activePage() == analyzeKeysPage || ui.activePage() == sourceSelectPage):
147+
146148
ui.args = nil
147149
return ui, tea.Quit
148150
case key.Matches(msg, ui.common.KeyMap.Quit):

0 commit comments

Comments
 (0)