Documentation
¶
Index ¶
- Variables
- func ClearKittyGraphics()
- func RebuildStyles()
- func ThemedTextAreaStyles() textarea.Styles
- func ThemedTextInputStyles() textinput.Styles
- type AccountAddedMsg
- type AccountDeletedMsg
- type AccountTab
- type AddAccountMsg
- type AllEmailsFetchedMsg
- type ApplySearchResultsMsg
- type ArchiveEmailMsg
- type AttachmentDownloadedMsg
- type BackToInboxMsg
- type BackToMailboxMsg
- type BatchArchiveEmailsMsg
- type BatchDeleteEmailsMsg
- type BatchEmailActionDoneMsg
- type BatchMoveEmailsMsg
- type CachedEmailsLoadedMsg
- type CancelFilePickerMsg
- type Choice
- type ChooseServiceMsg
- type ClearStatusMsg
- type Composer
- func (m *Composer) GetAttachmentPaths() []string
- func (m *Composer) GetBcc() string
- func (m *Composer) GetBody() string
- func (m *Composer) GetCc() string
- func (m *Composer) GetDraftID() string
- func (m *Composer) GetInReplyTo() string
- func (m *Composer) GetQuotedText() string
- func (m *Composer) GetReferences() []string
- func (m *Composer) GetSelectedAccountID() string
- func (m *Composer) GetSignature() string
- func (m *Composer) GetSubject() string
- func (m *Composer) GetTo() string
- func (m *Composer) HidePluginPrompt()
- func (m *Composer) Init() tea.Cmd
- func (m *Composer) ResetConfirmation()
- func (m *Composer) SetAccounts(accounts []config.Account)
- func (m *Composer) SetBcc(bcc string)
- func (m *Composer) SetBody(body string)
- func (m *Composer) SetCc(cc string)
- func (m *Composer) SetDraftID(id string)
- func (m *Composer) SetFromOverride(addr string)
- func (m *Composer) SetPluginKeyBindings(bindings []PluginKeyBinding)
- func (m *Composer) SetPluginStatus(status string)
- func (m *Composer) SetQuotedText(text string)
- func (m *Composer) SetReplyContext(inReplyTo string, references []string)
- func (m *Composer) SetSelectedAccount(accountID string)
- func (m *Composer) SetSubject(subject string)
- func (m *Composer) SetTo(to string)
- func (m *Composer) ShowPluginPrompt(placeholder string)
- func (m *Composer) ToDraft() config.Draft
- func (m *Composer) Update(msg tea.Msg) (tea.Model, tea.Cmd)
- func (m *Composer) View() tea.View
- type ConfigSavedMsg
- type Credentials
- type DaemonEventMsg
- type DeleteAccountMsg
- type DeleteEmailMsg
- type DeleteSavedDraftMsg
- type DiscardDraftMsg
- type DownloadAttachmentMsg
- type DraftDeletedMsg
- type DraftSavedMsg
- type Drafts
- type DraftsLoadedMsg
- type EditorFinishedMsg
- type EmailActionDoneMsg
- type EmailBodyFetchedMsg
- type EmailMarkedReadMsg
- type EmailMovedMsg
- type EmailResultMsg
- type EmailView
- func (m *EmailView) GetAccountID() string
- func (m *EmailView) GetEmail() fetcher.Email
- func (m *EmailView) Init() tea.Cmd
- func (m *EmailView) SetPluginKeyBindings(bindings []PluginKeyBinding)
- func (m *EmailView) SetPluginStatus(status string)
- func (m *EmailView) Update(msg tea.Msg) (tea.Model, tea.Cmd)
- func (m *EmailView) View() tea.View
- type EmailsAppendedMsg
- type EmailsFetchedMsg
- type EmailsRefreshedMsg
- type FetchErr
- type FetchFolderMoreEmailsMsg
- type FetchMoreEmailsMsg
- type FetchingMoreEmailsMsg
- type FilePicker
- type FileSelectedMsg
- type FolderEmailsAppendedMsg
- type FolderEmailsFetchedMsg
- type FolderInbox
- func (m *FolderInbox) GetAccounts() []config.Account
- func (m *FolderInbox) GetCurrentFolder() string
- func (m *FolderInbox) GetFolders() []string
- func (m *FolderInbox) GetInbox() *Inbox
- func (m *FolderInbox) Init() tea.Cmd
- func (m *FolderInbox) OpenSplitPreview(uid uint32, accountID string, email *fetcher.Email)
- func (m *FolderInbox) RemoveEmail(uid uint32, accountID string)
- func (m *FolderInbox) SetDateFormat(layout string)
- func (m *FolderInbox) SetEmails(emails []fetcher.Email, accounts []config.Account)
- func (m *FolderInbox) SetFolders(folders []string)
- func (m *FolderInbox) SetLoadingEmails(loading bool)
- func (m *FolderInbox) SetRefreshing(refreshing bool)
- func (m *FolderInbox) Update(msg tea.Msg) (tea.Model, tea.Cmd)
- func (m *FolderInbox) View() tea.View
- type FoldersFetchedMsg
- type ForwardEmailMsg
- type GoToAccountListMsg
- type GoToAddAccountMsg
- type GoToAddMailingListMsg
- type GoToChoiceMenuMsg
- type GoToDraftsMsg
- type GoToEditAccountMsg
- type GoToEditMailingListMsg
- type GoToFilePickerMsg
- type GoToInboxMsg
- type GoToMarketplaceMsg
- type GoToSendMsg
- type GoToSentInboxMsg
- type GoToSettingsMsg
- type GoToSignatureEditorMsg
- type GoToTrashArchiveMsg
- type IdleNewMailMsg
- type Inbox
- func NewArchiveInbox(emails []fetcher.Email, accounts []config.Account) *Inbox
- func NewInbox(emails []fetcher.Email, accounts []config.Account) *Inbox
- func NewInboxSingleAccount(emails []fetcher.Email) *Inbox
- func NewInboxWithMailbox(emails []fetcher.Email, accounts []config.Account, mailbox MailboxKind) *Inbox
- func NewSentInbox(emails []fetcher.Email, accounts []config.Account) *Inbox
- func NewTrashInbox(emails []fetcher.Email, accounts []config.Account) *Inbox
- func (m *Inbox) GetCurrentAccountID() string
- func (m *Inbox) GetEmailAtIndex(index int) *fetcher.Email
- func (m *Inbox) GetMailbox() MailboxKind
- func (m *Inbox) GetSelectedEmail() *fetcher.Email
- func (m *Inbox) Init() tea.Cmd
- func (m *Inbox) IsFilterActive() bool
- func (m *Inbox) IsSearchActive() bool
- func (m *Inbox) MarkEmailAsRead(uid uint32, accountID string)
- func (m *Inbox) RemoveEmail(uid uint32, accountID string)
- func (m *Inbox) RemoveEmails(uids []uint32, accountID string)
- func (m *Inbox) SetDateFormat(layout string)
- func (m *Inbox) SetEmails(emails []fetcher.Email, accounts []config.Account)
- func (m *Inbox) SetFolderName(name string)
- func (m *Inbox) SetPluginKeyBindings(bindings []PluginKeyBinding)
- func (m *Inbox) SetPluginStatus(status string)
- func (m *Inbox) SetSize(width, height int)
- func (m *Inbox) Update(msg tea.Msg) (tea.Model, tea.Cmd)
- func (m *Inbox) View() tea.View
- type LanguageChangedMsg
- type LoadDraftsMsg
- type Login
- type MailboxKind
- type MailingListEditor
- type MarkEmailAsReadMsg
- type Marketplace
- type MoveEmailMsg
- type MoveEmailToFolderMsg
- type OAuth2CompleteMsg
- type OpenDraftMsg
- type OpenEditorMsg
- type PaneType
- type PasswordPrompt
- type PasswordVerifiedMsg
- type PluginInstalledMsg
- type PluginKeyBinding
- type PluginNotifyMsg
- type PluginPromptCancelMsg
- type PluginPromptSubmitMsg
- type PreviewBodyFetchedMsg
- type RSVPResultMsg
- type RefreshingEmailsMsg
- type RegistryFetchedMsg
- type ReplyToEmailMsg
- type RequestRefreshMsg
- type RestoreViewMsg
- type SaveDraftMsg
- type SaveMailingListMsg
- type SearchOverlay
- type SearchRequestedMsg
- type SearchResultsMsg
- type SecureModeDisabledMsg
- type SecureModeEnabledMsg
- type SendEmailMsg
- type SendRSVPMsg
- type SetComposerCursorToStartMsg
- type Settings
- type SettingsCategory
- type SettingsPane
- type SettingsState
- type SignatureEditor
- type StartOAuth2Msg
- type Status
- type SwitchAccountMsg
- type SwitchFolderMsg
- type SwitchFromAccountMsg
- type UpdatePreviewMsg
- type ViewEmailMsg
Constants ¶
This section is empty.
Variables ¶
var ( DialogBoxStyle = lipgloss.NewStyle(). Border(lipgloss.RoundedBorder()). BorderForeground(lipgloss.Color("#25A065")). Padding(1, 2). BorderTop(true). BorderLeft(true). BorderRight(true). BorderBottom(true) HelpStyle = lipgloss.NewStyle().Foreground(lipgloss.Color("240")) TipStyle = lipgloss.NewStyle().Foreground(lipgloss.Color("214")).Italic(true) SuccessStyle = lipgloss.NewStyle().Foreground(lipgloss.Color("42")).Bold(true) InfoStyle = lipgloss.NewStyle().Foreground(lipgloss.Color("42")).Bold(true) H1Style = lipgloss.NewStyle(). Foreground(lipgloss.Color("42")). Bold(true). Align(lipgloss.Center) H2Style = lipgloss.NewStyle(). Foreground(lipgloss.Color("42")). Bold(false). Align(lipgloss.Center) BodyStyle = lipgloss.NewStyle(). Bold(true) // A bit bold )
var DocStyle = lipgloss.NewStyle().Margin(1, 2)
Functions ¶
func ClearKittyGraphics ¶ added in v0.21.1
func ClearKittyGraphics()
ClearKittyGraphics sends the Kitty graphics protocol delete command directly to stdout.
func RebuildStyles ¶ added in v0.24.0
func RebuildStyles()
RebuildStyles updates all package-level style variables to match the active theme. This must be called after theme.SetTheme() and at startup.
func ThemedTextAreaStyles ¶ added in v0.27.3
ThemedTextAreaStyles returns textarea.Styles using the active theme colors.
func ThemedTextInputStyles ¶ added in v0.27.3
ThemedTextInputStyles returns textinput.Styles using the active theme colors.
Types ¶
type AccountAddedMsg ¶ added in v0.8.0
AccountAddedMsg signals that an account was successfully added.
type AccountDeletedMsg ¶ added in v0.8.0
AccountDeletedMsg signals that an account was successfully deleted.
type AccountTab ¶ added in v0.8.0
AccountTab represents a tab for an account
type AddAccountMsg ¶ added in v0.8.0
type AddAccountMsg struct {
Credentials Credentials
}
AddAccountMsg signals that a new account should be added.
type AllEmailsFetchedMsg ¶ added in v0.8.0
type AllEmailsFetchedMsg struct {
EmailsByAccount map[string][]fetcher.Email
Mailbox MailboxKind
}
AllEmailsFetchedMsg signals that emails from all accounts have been fetched.
type ApplySearchResultsMsg ¶ added in v0.36.0
type ApplySearchResultsMsg struct {
Query backend.SearchQuery
Emails []fetcher.Email
}
type ArchiveEmailMsg ¶
type ArchiveEmailMsg struct {
UID uint32
AccountID string
Mailbox MailboxKind
}
type AttachmentDownloadedMsg ¶
type BackToInboxMsg ¶
type BackToInboxMsg struct{}
type BackToMailboxMsg ¶ added in v0.10.0
type BackToMailboxMsg struct {
Mailbox MailboxKind
}
type BatchArchiveEmailsMsg ¶ added in v0.32.0
type BatchArchiveEmailsMsg struct {
UIDs []uint32
AccountID string
Mailbox MailboxKind
}
type BatchDeleteEmailsMsg ¶ added in v0.32.0
type BatchDeleteEmailsMsg struct {
UIDs []uint32
AccountID string
Mailbox MailboxKind
}
Batch operation messages
type BatchEmailActionDoneMsg ¶ added in v0.32.0
type BatchMoveEmailsMsg ¶ added in v0.32.0
type CachedEmailsLoadedMsg ¶ added in v0.8.0
type CachedEmailsLoadedMsg struct {
Cache *config.EmailCache
}
CachedEmailsLoadedMsg signals that cached emails were loaded from disk.
type CancelFilePickerMsg ¶
type CancelFilePickerMsg struct{}
type Choice ¶
type ChooseServiceMsg ¶
type ChooseServiceMsg struct {
Service string
}
type ClearStatusMsg ¶
type ClearStatusMsg struct{}
type Composer ¶
type Composer struct {
// contains filtered or unexported fields
}
Composer model holds the state of the email composition UI.
func NewComposer ¶
NewComposer initializes a new composer model.
func NewComposerFromDraft ¶ added in v0.8.0
NewComposerFromDraft creates a composer from an existing draft.
func NewComposerWithAccounts ¶ added in v0.8.0
func NewComposerWithAccounts(accounts []config.Account, selectedAccountID string, to, subject, body string, hideTips bool) *Composer
NewComposerWithAccounts initializes a composer with multiple account support.
func (*Composer) GetAttachmentPaths ¶ added in v0.21.0
GetAttachmentPaths returns the current attachment paths.
func (*Composer) GetDraftID ¶ added in v0.8.0
GetDraftID returns the draft ID for this composer.
func (*Composer) GetInReplyTo ¶ added in v0.8.0
GetInReplyTo returns the In-Reply-To header value.
func (*Composer) GetQuotedText ¶ added in v0.13.5
GetQuotedText returns the hidden quoted text.
func (*Composer) GetReferences ¶ added in v0.8.0
GetReferences returns the References header values.
func (*Composer) GetSelectedAccountID ¶ added in v0.8.0
GetSelectedAccountID returns the ID of the currently selected account.
func (*Composer) GetSignature ¶ added in v0.15.0
GetSignature returns the current signature value.
func (*Composer) GetSubject ¶ added in v0.8.0
GetSubject returns the current Subject field value.
func (*Composer) HidePluginPrompt ¶ added in v0.31.0
func (m *Composer) HidePluginPrompt()
HidePluginPrompt deactivates the plugin prompt overlay.
func (*Composer) ResetConfirmation ¶
func (m *Composer) ResetConfirmation()
ResetConfirmation ensures a restored draft isnt stuck in the exit prompt.
func (*Composer) SetAccounts ¶ added in v0.8.0
SetAccounts sets the available accounts for sending.
func (*Composer) SetDraftID ¶ added in v0.8.0
SetDraftID sets the draft ID (for loading existing drafts).
func (*Composer) SetFromOverride ¶ added in v0.36.1
SetFromOverride pre-fills the editable From field (used for catch-all replies).
func (*Composer) SetPluginKeyBindings ¶ added in v0.30.0
func (m *Composer) SetPluginKeyBindings(bindings []PluginKeyBinding)
SetPluginKeyBindings sets the plugin-registered key bindings for display in the help bar.
func (*Composer) SetPluginStatus ¶ added in v0.28.0
SetPluginStatus sets a persistent status string from plugins, shown in the help bar.
func (*Composer) SetQuotedText ¶ added in v0.13.5
SetQuotedText sets the hidden quoted text that will be appended when sending.
func (*Composer) SetReplyContext ¶ added in v0.8.0
SetReplyContext sets the reply context for the draft.
func (*Composer) SetSelectedAccount ¶ added in v0.8.0
SetSelectedAccount sets the selected account by ID.
func (*Composer) SetSubject ¶ added in v0.30.0
SetSubject updates the Subject field with new content.
func (*Composer) ShowPluginPrompt ¶ added in v0.31.0
ShowPluginPrompt activates the plugin prompt overlay with the given placeholder text.
type ConfigSavedMsg ¶ added in v0.36.0
type ConfigSavedMsg struct{}
ConfigSavedMsg signals the config was written to disk and downstream consumers (notably the daemon) should reload it.
type Credentials ¶
type Credentials struct {
Provider string
Name string
Host string // Host (this was the previous "Email Address" field in the UI)
FetchEmail string // Single email address to fetch messages for. If empty, code should default this to Host when creating the account.
SendAsEmail string // Optional From header email. If empty, sending falls back to FetchEmail, then Host.
CatchAll bool // Show all inbox messages regardless of To address.
Password string
IMAPServer string
IMAPPort int
SMTPServer string
SMTPPort int
Insecure bool
AuthMethod string // "password" or "oauth2"
Protocol string // "imap" (default), "jmap", or "pop3"
JMAPEndpoint string // JMAP session URL
POP3Server string // POP3 server hostname
POP3Port int // POP3 server port
}
type DaemonEventMsg ¶ added in v0.34.0
DaemonEventMsg wraps an event pushed from the daemon process.
type DeleteAccountMsg ¶ added in v0.8.0
type DeleteAccountMsg struct {
AccountID string
}
DeleteAccountMsg signals that an account should be deleted.
type DeleteEmailMsg ¶
type DeleteEmailMsg struct {
UID uint32
AccountID string
Mailbox MailboxKind
}
type DeleteSavedDraftMsg ¶ added in v0.8.0
type DeleteSavedDraftMsg struct {
DraftID string
}
DeleteDraftMsg signals that a draft should be deleted.
type DiscardDraftMsg ¶
type DiscardDraftMsg struct {
ComposerState *Composer
}
DiscardDraftMsg signals that a draft should be cached.
type DownloadAttachmentMsg ¶
type DraftDeletedMsg ¶ added in v0.8.0
DraftDeletedMsg signals that a draft was deleted.
type DraftSavedMsg ¶ added in v0.8.0
DraftSavedMsg signals that a draft was saved successfully.
type Drafts ¶ added in v0.8.0
type Drafts struct {
// contains filtered or unexported fields
}
Drafts is the model for the drafts list view
type DraftsLoadedMsg ¶ added in v0.8.0
DraftsLoadedMsg signals that drafts were loaded from disk.
type EditorFinishedMsg ¶ added in v0.28.0
EditorFinishedMsg signals that the external editor has closed.
type EmailActionDoneMsg ¶
type EmailActionDoneMsg struct {
UID uint32
AccountID string
Mailbox MailboxKind
Err error
}
type EmailBodyFetchedMsg ¶
type EmailBodyFetchedMsg struct {
UID uint32
Body string
Attachments []fetcher.Attachment
Err error
AccountID string
Mailbox MailboxKind
}
type EmailMarkedReadMsg ¶ added in v0.26.0
EmailMarkedReadMsg signals that an email was marked as read.
type EmailMovedMsg ¶ added in v0.22.0
type EmailMovedMsg struct {
UID uint32
AccountID string
SourceFolder string
DestFolder string
Err error
}
EmailMovedMsg signals that an email was moved to a folder.
type EmailResultMsg ¶
type EmailResultMsg struct {
Err error
}
type EmailView ¶
type EmailView struct {
// contains filtered or unexported fields
}
func NewEmailView ¶
func NewEmailViewPreview ¶ added in v0.35.0
func NewEmailViewPreview(email fetcher.Email, width, height, colOffset int, disableImages bool) *EmailView
NewEmailViewPreview creates EmailView in preview mode with column offset for images
func (*EmailView) GetAccountID ¶ added in v0.8.0
GetAccountID returns the account ID for this email
func (*EmailView) SetPluginKeyBindings ¶ added in v0.30.0
func (m *EmailView) SetPluginKeyBindings(bindings []PluginKeyBinding)
SetPluginKeyBindings sets the plugin-registered key bindings for display in the help bar.
func (*EmailView) SetPluginStatus ¶ added in v0.28.0
SetPluginStatus sets a persistent status string from plugins, shown in the help bar.
type EmailsAppendedMsg ¶
type EmailsAppendedMsg struct {
Emails []fetcher.Email
AccountID string
Mailbox MailboxKind
}
type EmailsFetchedMsg ¶
type EmailsFetchedMsg struct {
Emails []fetcher.Email
AccountID string
Mailbox MailboxKind
}
type EmailsRefreshedMsg ¶ added in v0.8.0
type EmailsRefreshedMsg struct {
EmailsByAccount map[string][]fetcher.Email
Mailbox MailboxKind
}
EmailsRefreshedMsg signals that fresh emails have been fetched in the background.
type FetchFolderMoreEmailsMsg ¶ added in v0.22.0
type FetchFolderMoreEmailsMsg struct {
Offset uint32
AccountID string
FolderName string
Limit uint32
}
FetchFolderMoreEmailsMsg signals a request to fetch more emails from a folder (pagination).
type FetchMoreEmailsMsg ¶
type FetchMoreEmailsMsg struct {
Offset uint32
AccountID string
Mailbox MailboxKind
Limit uint32
}
type FetchingMoreEmailsMsg ¶
type FetchingMoreEmailsMsg struct{}
type FilePicker ¶
type FilePicker struct {
// contains filtered or unexported fields
}
func NewFilePicker ¶
func NewFilePicker(startPath string) *FilePicker
func (*FilePicker) Init ¶
func (m *FilePicker) Init() tea.Cmd
func (*FilePicker) View ¶
func (m *FilePicker) View() tea.View
type FileSelectedMsg ¶
type FileSelectedMsg struct {
Paths []string
}
type FolderEmailsAppendedMsg ¶ added in v0.22.0
FolderEmailsAppendedMsg signals that more emails from a folder have been fetched (pagination).
type FolderEmailsFetchedMsg ¶ added in v0.22.0
FolderEmailsFetchedMsg signals that emails from a folder have been fetched.
type FolderInbox ¶ added in v0.22.0
type FolderInbox struct {
// contains filtered or unexported fields
}
FolderInbox combines a folder sidebar with an email list.
func NewFolderInbox ¶ added in v0.22.0
func NewFolderInbox(folders []string, accounts []config.Account) *FolderInbox
NewFolderInbox creates a new FolderInbox with the given folders and accounts.
func (*FolderInbox) GetAccounts ¶ added in v0.22.0
func (m *FolderInbox) GetAccounts() []config.Account
GetAccounts returns the accounts.
func (*FolderInbox) GetCurrentFolder ¶ added in v0.22.0
func (m *FolderInbox) GetCurrentFolder() string
GetCurrentFolder returns the currently selected folder name.
func (*FolderInbox) GetFolders ¶ added in v0.22.0
func (m *FolderInbox) GetFolders() []string
GetFolders returns the current folder list.
func (*FolderInbox) GetInbox ¶ added in v0.22.0
func (m *FolderInbox) GetInbox() *Inbox
GetInbox returns the embedded inbox.
func (*FolderInbox) Init ¶ added in v0.22.0
func (m *FolderInbox) Init() tea.Cmd
func (*FolderInbox) OpenSplitPreview ¶ added in v0.35.0
func (m *FolderInbox) OpenSplitPreview(uid uint32, accountID string, email *fetcher.Email)
OpenSplitPreview opens the split preview pane for a specific email. email may be non-nil for hits coming from search results (which are not in m.inbox.allEmails); when set, it is used as a fallback by findEmailByUID so the preview can render without a follow-up lookup.
func (*FolderInbox) RemoveEmail ¶ added in v0.22.0
func (m *FolderInbox) RemoveEmail(uid uint32, accountID string)
RemoveEmail removes an email from the embedded inbox.
func (*FolderInbox) SetDateFormat ¶ added in v0.33.0
func (m *FolderInbox) SetDateFormat(layout string)
SetDateFormat propagates the configured date layout to the inner inbox.
func (*FolderInbox) SetEmails ¶ added in v0.22.0
func (m *FolderInbox) SetEmails(emails []fetcher.Email, accounts []config.Account)
SetEmails updates the inbox emails.
func (*FolderInbox) SetFolders ¶ added in v0.22.0
func (m *FolderInbox) SetFolders(folders []string)
SetFolders updates the folder list.
func (*FolderInbox) SetLoadingEmails ¶ added in v0.22.0
func (m *FolderInbox) SetLoadingEmails(loading bool)
SetLoadingEmails sets the loading state.
func (*FolderInbox) SetRefreshing ¶ added in v0.23.1
func (m *FolderInbox) SetRefreshing(refreshing bool)
SetRefreshing sets the refreshing state (used when user presses "r").
func (*FolderInbox) View ¶ added in v0.22.0
func (m *FolderInbox) View() tea.View
type FoldersFetchedMsg ¶ added in v0.22.0
type FoldersFetchedMsg struct {
FoldersByAccount map[string][]fetcher.Folder // accountID -> folders
MergedFolders []fetcher.Folder // unique folders across all accounts
}
FoldersFetchedMsg signals that IMAP folders have been fetched for all accounts.
type ForwardEmailMsg ¶ added in v0.17.0
type GoToAccountListMsg ¶ added in v0.8.0
type GoToAccountListMsg struct{}
GoToAccountListMsg signals navigation to the account list in settings.
type GoToAddAccountMsg ¶ added in v0.8.0
type GoToAddAccountMsg struct{}
GoToAddAccountMsg signals navigation to the add account screen.
type GoToAddMailingListMsg ¶ added in v0.20.0
type GoToAddMailingListMsg struct{}
GoToAddMailingListMsg signals navigation to the add mailing list screen.
type GoToChoiceMenuMsg ¶
type GoToChoiceMenuMsg struct{}
type GoToDraftsMsg ¶ added in v0.8.0
type GoToDraftsMsg struct{}
GoToDraftsMsg signals navigation to the drafts list.
type GoToEditAccountMsg ¶ added in v0.26.0
type GoToEditAccountMsg struct {
AccountID string
Provider string
Name string
Email string
FetchEmail string
SendAsEmail string
CatchAll bool
IMAPServer string
IMAPPort int
SMTPServer string
SMTPPort int
Insecure bool
Protocol string
JMAPEndpoint string
POP3Server string
POP3Port int
}
GoToEditAccountMsg signals navigation to edit an existing account.
type GoToEditMailingListMsg ¶ added in v0.26.0
GoToEditMailingListMsg signals navigation to edit an existing mailing list.
type GoToFilePickerMsg ¶
type GoToFilePickerMsg struct{}
type GoToInboxMsg ¶
type GoToInboxMsg struct{}
type GoToMarketplaceMsg ¶ added in v0.31.0
type GoToMarketplaceMsg struct{}
GoToMarketplaceMsg signals navigation to the plugin marketplace.
type GoToSendMsg ¶
type GoToSentInboxMsg ¶ added in v0.10.0
type GoToSentInboxMsg struct{}
type GoToSettingsMsg ¶
type GoToSettingsMsg struct{}
type GoToSignatureEditorMsg ¶ added in v0.15.0
type GoToSignatureEditorMsg struct {
AccountID string
}
type GoToTrashArchiveMsg ¶ added in v0.16.0
type GoToTrashArchiveMsg struct{}
type IdleNewMailMsg ¶ added in v0.28.0
IdleNewMailMsg signals that IMAP IDLE detected new mail for an account/folder.
type Inbox ¶
type Inbox struct {
// contains filtered or unexported fields
}
func NewArchiveInbox ¶ added in v0.16.0
func NewInboxSingleAccount ¶ added in v0.8.0
NewInboxSingleAccount creates an inbox for a single account (legacy support)
func NewInboxWithMailbox ¶ added in v0.10.0
func NewSentInbox ¶ added in v0.10.0
func NewTrashInbox ¶ added in v0.16.0
func (*Inbox) GetCurrentAccountID ¶ added in v0.8.0
GetCurrentAccountID returns the currently selected account ID
func (*Inbox) GetEmailAtIndex ¶ added in v0.8.0
GetEmailAtIndex returns the email at the given index for the current view
func (*Inbox) GetMailbox ¶ added in v0.10.0
func (m *Inbox) GetMailbox() MailboxKind
func (*Inbox) GetSelectedEmail ¶ added in v0.30.0
GetSelectedEmail returns the currently selected email, or nil if none is selected.
func (*Inbox) IsFilterActive ¶ added in v0.36.0
func (*Inbox) IsSearchActive ¶ added in v0.36.0
func (*Inbox) MarkEmailAsRead ¶ added in v0.26.0
MarkEmailAsRead marks an email as read by UID and account ID, updating it in all stores.
func (*Inbox) RemoveEmail ¶ added in v0.8.0
RemoveEmail removes an email by UID and account ID
func (*Inbox) RemoveEmails ¶ added in v0.32.0
RemoveEmails removes multiple emails by UID and account ID (batch operation)
func (*Inbox) SetDateFormat ¶ added in v0.33.0
SetDateFormat configures the Go time layout used to render absolute dates in the email list. Pass the value returned by config.Config.GetDateFormat.
func (*Inbox) SetFolderName ¶ added in v0.22.0
SetFolderName sets a custom folder name for the inbox title.
func (*Inbox) SetPluginKeyBindings ¶ added in v0.30.0
func (m *Inbox) SetPluginKeyBindings(bindings []PluginKeyBinding)
SetPluginKeyBindings sets the plugin-registered key bindings for display in the help bar.
func (*Inbox) SetPluginStatus ¶ added in v0.28.0
SetPluginStatus sets a persistent status string from plugins, shown in the title.
type LanguageChangedMsg ¶ added in v0.35.0
type LanguageChangedMsg struct{}
RSVPResultMsg signals that RSVP was sent (or failed)
type LoadDraftsMsg ¶ added in v0.8.0
type LoadDraftsMsg struct{}
LoadDraftsMsg signals a request to load all saved drafts.
type Login ¶
type Login struct {
// contains filtered or unexported fields
}
Login holds the state for the login/add account form.
func (*Login) GetAccountID ¶ added in v0.8.0
GetAccountID returns the account ID being edited (if in edit mode).
func (*Login) IsEditMode ¶ added in v0.8.0
IsEditMode returns whether the form is in edit mode.
func (*Login) SetEditMode ¶ added in v0.8.0
func (m *Login) SetEditMode(accountID, protocol, provider, name, email, fetchEmail, sendAsEmail, imapServer string, imapPort int, smtpServer string, smtpPort int, insecure bool, jmapEndpoint, pop3Server string, pop3Port int, catchAll bool)
SetEditMode sets the login form to edit an existing account.
type MailboxKind ¶ added in v0.10.0
type MailboxKind string
const ( MailboxInbox MailboxKind = "inbox" MailboxSent MailboxKind = "sent" MailboxTrash MailboxKind = "trash" MailboxArchive MailboxKind = "archive" )
type MailingListEditor ¶ added in v0.20.0
type MailingListEditor struct {
// contains filtered or unexported fields
}
MailingListEditor displays the screen to add or edit a mailing list.
func NewMailingListEditor ¶ added in v0.20.0
func NewMailingListEditor() *MailingListEditor
NewMailingListEditor creates a new mailing list editor model.
func (*MailingListEditor) Init ¶ added in v0.20.0
func (m *MailingListEditor) Init() tea.Cmd
Init initializes the mailing list editor model.
func (*MailingListEditor) SetEditMode ¶ added in v0.26.0
func (m *MailingListEditor) SetEditMode(index int, name, addresses string)
SetEditMode sets the editor to edit an existing mailing list.
func (*MailingListEditor) Update ¶ added in v0.20.0
Update handles messages for the mailing list editor model.
func (*MailingListEditor) View ¶ added in v0.20.0
func (m *MailingListEditor) View() tea.View
View renders the mailing list editor screen.
type MarkEmailAsReadMsg ¶ added in v0.26.0
MarkEmailAsReadMsg signals that an email should be marked as read on the server.
type Marketplace ¶ added in v0.31.0
type Marketplace struct {
// contains filtered or unexported fields
}
func NewMarketplace ¶ added in v0.31.0
func NewMarketplace(standalone bool) Marketplace
func (Marketplace) Init ¶ added in v0.31.0
func (m Marketplace) Init() tea.Cmd
func (Marketplace) View ¶ added in v0.31.0
func (m Marketplace) View() tea.View
type MoveEmailMsg ¶ added in v0.22.0
MoveEmailMsg signals a request to show the move-to-folder picker.
type MoveEmailToFolderMsg ¶ added in v0.22.0
type MoveEmailToFolderMsg struct {
UID uint32
AccountID string
SourceFolder string
DestFolder string
}
MoveEmailToFolderMsg signals that an email should be moved to a folder.
type OAuth2CompleteMsg ¶ added in v0.28.0
OAuth2CompleteMsg is sent when OAuth2 authorization completes.
type OpenDraftMsg ¶ added in v0.8.0
OpenDraftMsg signals that a specific draft should be opened in the composer.
type OpenEditorMsg ¶ added in v0.28.0
type OpenEditorMsg struct{}
OpenEditorMsg signals that the composer body should be opened in $EDITOR.
type PasswordPrompt ¶ added in v0.32.0
type PasswordPrompt struct {
// contains filtered or unexported fields
}
PasswordPrompt asks the user for their encryption password to unlock the app.
func NewPasswordPrompt ¶ added in v0.32.0
func NewPasswordPrompt() *PasswordPrompt
NewPasswordPrompt creates a new password prompt screen.
func (*PasswordPrompt) Init ¶ added in v0.32.0
func (m *PasswordPrompt) Init() tea.Cmd
func (*PasswordPrompt) View ¶ added in v0.32.0
func (m *PasswordPrompt) View() tea.View
type PasswordVerifiedMsg ¶ added in v0.32.0
type PasswordVerifiedMsg struct {
Key []byte // The derived encryption key (nil on failure)
Err error // Non-nil if verification failed
}
PasswordVerifiedMsg signals that the encryption password was verified (or failed).
type PluginInstalledMsg ¶ added in v0.31.0
PluginInstalledMsg signals that a plugin was installed from the marketplace.
type PluginKeyBinding ¶ added in v0.30.0
PluginKeyBinding describes a plugin-registered keyboard shortcut for display in the help bar.
type PluginNotifyMsg ¶ added in v0.28.0
PluginNotifyMsg signals that a plugin wants to show a notification.
type PluginPromptCancelMsg ¶ added in v0.31.0
type PluginPromptCancelMsg struct{}
PluginPromptCancelMsg signals that the user cancelled a plugin prompt input.
type PluginPromptSubmitMsg ¶ added in v0.31.0
type PluginPromptSubmitMsg struct {
Value string
}
PluginPromptSubmitMsg signals that the user submitted a plugin prompt input.
type PreviewBodyFetchedMsg ¶ added in v0.35.0
type RSVPResultMsg ¶ added in v0.33.0
type RefreshingEmailsMsg ¶ added in v0.8.0
type RefreshingEmailsMsg struct {
Mailbox MailboxKind
}
RefreshingEmailsMsg signals that a background refresh is in progress.
type RegistryFetchedMsg ¶ added in v0.31.0
type RegistryFetchedMsg struct {
Entries []plugins.PluginEntry
Err error
}
RegistryFetchedMsg signals that the plugin registry was fetched.
type ReplyToEmailMsg ¶
type RequestRefreshMsg ¶ added in v0.13.0
type RequestRefreshMsg struct {
Mailbox MailboxKind
Counts map[string]int
FolderName string
}
RequestRefreshMsg signals a request to refresh emails from the server.
type RestoreViewMsg ¶
type RestoreViewMsg struct{}
type SaveDraftMsg ¶ added in v0.8.0
SaveDraftMsg signals that the current draft should be saved to disk.
type SaveMailingListMsg ¶ added in v0.20.0
type SaveMailingListMsg struct {
Name string
Addresses string
EditIndex int // -1 means new, >= 0 means editing existing
}
SaveMailingListMsg signals that a new or edited mailing list should be saved.
type SearchOverlay ¶ added in v0.36.0
type SearchOverlay struct {
// contains filtered or unexported fields
}
func NewSearchOverlay ¶ added in v0.36.0
func NewSearchOverlay(width, height int) *SearchOverlay
func (*SearchOverlay) Init ¶ added in v0.36.0
func (o *SearchOverlay) Init() tea.Cmd
func (*SearchOverlay) Update ¶ added in v0.36.0
func (o *SearchOverlay) Update(msg tea.Msg, mailbox MailboxKind, accountID string) tea.Cmd
func (*SearchOverlay) View ¶ added in v0.36.0
func (o *SearchOverlay) View() string
type SearchRequestedMsg ¶ added in v0.36.0
type SearchRequestedMsg struct {
Query backend.SearchQuery
Mailbox MailboxKind
FolderName string
AccountID string
}
type SearchResultsMsg ¶ added in v0.36.0
type SearchResultsMsg struct {
Query backend.SearchQuery
Emails []fetcher.Email
Err error
}
type SecureModeDisabledMsg ¶ added in v0.32.0
type SecureModeDisabledMsg struct {
Err error
}
SecureModeDisabledMsg signals that encryption was disabled from settings.
type SecureModeEnabledMsg ¶ added in v0.32.0
type SecureModeEnabledMsg struct {
Err error
}
SecureModeEnabledMsg signals that encryption was enabled from settings.
type SendEmailMsg ¶
type SendEmailMsg struct {
To string
Cc string // Cc recipient(s)
Bcc string // Bcc recipient(s)
Subject string
Body string
AttachmentPaths []string
InReplyTo string
References []string
AccountID string // ID of the account to send from
FromOverride string // Custom From address (used when account is catch-all)
QuotedText string // Hidden quoted text appended when sending
Signature string // Signature to append to email body
SignSMIME bool // Whether to sign the email using S/MIME
EncryptSMIME bool // Whether to encrypt the email using S/MIME
SignPGP bool // Whether to sign the email using PGP
}
type SendRSVPMsg ¶ added in v0.33.0
type SendRSVPMsg struct {
OriginalICS []byte
Event *calendar.Event
Response string // "ACCEPTED", "DECLINED", "TENTATIVE"
AccountID string
InReplyTo string
References []string
}
SendRSVPMsg signals that user wants to send RSVP to calendar invite
type SetComposerCursorToStartMsg ¶
type SetComposerCursorToStartMsg struct{}
type Settings ¶ added in v0.8.0
type Settings struct {
// contains filtered or unexported fields
}
func NewSettings ¶ added in v0.8.0
func (*Settings) GetState ¶ added in v0.35.0
func (m *Settings) GetState() SettingsState
func (*Settings) RestoreState ¶ added in v0.35.0
func (m *Settings) RestoreState(state SettingsState)
func (*Settings) UpdateConfig ¶ added in v0.18.0
type SettingsCategory ¶ added in v0.34.0
type SettingsCategory int
const ( CategoryGeneral SettingsCategory = iota CategoryAccounts CategoryTheme CategoryMailingLists CategoryEncryption )
type SettingsPane ¶ added in v0.34.0
type SettingsPane int
const ( PaneMenu SettingsPane = iota PaneContent )
type SettingsState ¶ added in v0.18.0
type SettingsState struct {
ActivePane SettingsPane
ActiveCategory SettingsCategory
MenuCursor int
GeneralCursor int
AccountsCursor int
ThemeCursor int
ListsCursor int
}
type SignatureEditor ¶ added in v0.15.0
type SignatureEditor struct {
// contains filtered or unexported fields
}
SignatureEditor displays the signature editing screen.
func NewSignatureEditor ¶ added in v0.15.0
func NewSignatureEditor(accountID string) *SignatureEditor
NewSignatureEditor creates a new signature editor model.
func (*SignatureEditor) Init ¶ added in v0.15.0
func (m *SignatureEditor) Init() tea.Cmd
Init initializes the signature editor model.
func (*SignatureEditor) Update ¶ added in v0.15.0
Update handles messages for the signature editor model.
func (*SignatureEditor) View ¶ added in v0.15.0
func (m *SignatureEditor) View() tea.View
View renders the signature editor screen.
type StartOAuth2Msg ¶ added in v0.28.0
type StartOAuth2Msg struct {
Email string
}
StartOAuth2Msg is sent when the user requests OAuth2 authorization for a Gmail account.
type Status ¶
type Status struct {
// contains filtered or unexported fields
}
A simple model for showing a status message
type SwitchAccountMsg ¶ added in v0.8.0
type SwitchAccountMsg struct {
AccountID string // Empty string means "ALL" accounts
}
SwitchAccountMsg signals switching to view a specific account's inbox.
type SwitchFolderMsg ¶ added in v0.22.0
SwitchFolderMsg signals switching to a different IMAP folder.
type SwitchFromAccountMsg ¶ added in v0.8.0
type SwitchFromAccountMsg struct {
AccountID string
}
SwitchFromAccountMsg signals changing the "From" account in composer.
type UpdatePreviewMsg ¶ added in v0.35.0
type ViewEmailMsg ¶
Source Files
¶
- choice.go
- composer.go
- drafts.go
- email_view.go
- filepicker.go
- folder_inbox.go
- i18n_helper.go
- inbox.go
- login.go
- mailing_list.go
- marketplace.go
- messages.go
- password_prompt.go
- search.go
- settings.go
- settings_accounts.go
- settings_crypto.go
- settings_encryption.go
- settings_general.go
- settings_lists.go
- settings_theme.go
- signature.go
- styles.go
- theme.go