Private
Public Access
1
0

tui: basic conversation selection and navigation

This commit is contained in:
2024-04-01 22:44:29 +00:00
parent 0e68e22efa
commit 7463b7502c
3 changed files with 51 additions and 16 deletions

View File

@@ -132,6 +132,11 @@ func (m model) Update(msg tea.Msg) (tea.Model, tea.Cmd) {
m.conversations.handleResize(m.width, m.height)
}
m.state = state(msg)
case msgConversationSelected:
m.opts.convShortname = msg.ShortName.String
cmds = append(cmds, func() tea.Msg {
return msgChangeState(stateChat)
})
case tea.WindowSizeMsg:
m.width, m.height = msg.Width, msg.Height
case msgError: