mirror of
https://github.com/taigrr/teaqlite.git
synced 2026-04-02 04:59:03 -07:00
fix help properly
This commit is contained in:
@@ -411,15 +411,11 @@ func (m *TableListModel) View() string {
|
||||
if m.searching {
|
||||
content.WriteString(HelpStyle.Render("Type to search • enter/esc: finish search"))
|
||||
} else {
|
||||
var helpText string
|
||||
if m.showFullHelp {
|
||||
helpText = m.help.FullHelpView(m.keyMap.FullHelp())
|
||||
content.WriteString(m.help.FullHelpView(m.keyMap.FullHelp()))
|
||||
} else {
|
||||
helpText = m.help.ShortHelpView(m.keyMap.ShortHelp())
|
||||
// Add ctrl+g to short help
|
||||
helpText += " • " + HelpStyle.Render("ctrl+g: toggle help")
|
||||
content.WriteString(m.help.ShortHelpView(m.keyMap.ShortHelp()))
|
||||
}
|
||||
content.WriteString(helpText)
|
||||
}
|
||||
|
||||
return content.String()
|
||||
|
||||
Reference in New Issue
Block a user