Documentation
¶
Index ¶
- type AttachRequestedMsg
- type MessageSubmittedMsg
- type Mode
- type Model
- func (m *Model) EnterEditMode(messageID int64, currentText string)
- func (m *Model) EnterReplyMode(messageID int64, previewText string)
- func (m *Model) Reset()
- func (m *Model) SetAttachment(path string)
- func (m *Model) SetChatId(chatID int64)
- func (m *Model) SetFocused(focused bool)
- func (m *Model) SetSize(width, height int)
- func (m Model) Update(msg tea.Msg) (Model, tea.Cmd)
- func (m Model) View() string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AttachRequestedMsg ¶
type AttachRequestedMsg struct{}
AttachRequestedMsg is emitted when the user asks to attach a file (Ctrl+T).
type MessageSubmittedMsg ¶
type MessageSubmittedMsg struct {
ChatId int64
Text string
ReplyToId int64
EditMessageId int64
Attachment string // local file path, empty if none
}
MessageSubmittedMsg is emitted when the user submits a message.
type Model ¶
type Model struct {
// contains filtered or unexported fields
}
Model is the message composer component.
func (*Model) EnterEditMode ¶
EnterEditMode starts editing a message.
func (*Model) EnterReplyMode ¶
EnterReplyMode starts replying to a message.
func (*Model) SetAttachment ¶
SetAttachment sets the pending attachment path shown above the composer.
Click to show internal directories.
Click to hide internal directories.