change tui and status command to use callback.

add keybind to submit
This commit is contained in:
Robin Olsen
2026-03-04 22:44:55 +01:00
parent 4842d30aab
commit cc6c4ea7cb
5 changed files with 49 additions and 28 deletions

View File

@@ -31,15 +31,16 @@ func (h HelpBar) View() string {
func (h HelpBar) shortHelp() string {
keys := []string{
styles.HighlightKey("tab") + " switch",
styles.HighlightKey("↑/k") + " up",
styles.HighlightKey("↓/j") + " down",
styles.HighlightKey("pgup/pgdn") + " page",
styles.HighlightKey("a") + " add",
styles.HighlightKey("e/d/s/p/t/c") + " edit",
styles.HighlightKey("x") + " delete",
styles.HighlightKey("q") + " quit",
styles.HighlightKey("?") + " help",
styles.HighlightKey("tab") + "switch ",
styles.HighlightKey("↑/k") + "up ",
styles.HighlightKey("↓/j") + "down ",
styles.HighlightKey("pgup/pgdn") + "page ",
styles.HighlightKey("a") + "add ",
styles.HighlightKey("e/d/s/p/t/c") + "edit ",
styles.HighlightKey("x") + "delete ",
styles.HighlightKey("q") + "quit ",
styles.HighlightKey("S") + "submit ",
styles.HighlightKey("?") + "help ",
}
content := lipgloss.JoinHorizontal(lipgloss.Left, keys...)
return lipgloss.NewStyle().