Documentation
¶
Index ¶
- func DeleteItem(sender tab.Tab, itemName string) tea.Cmd
- func DownloadItem(feedName string, index int) tea.Cmd
- func EditItem(sender tab.Tab, fields []string) tea.Cmd
- func MakeChoice(question string, defaultChoice bool) tea.Cmd
- func MarkAsRead(url string) tea.Cmd
- func MarkAsUnread(url string) tea.Cmd
- func NewItem(sender tab.Tab) tea.Cmd
- func SetEnableKeybind(enable bool) tea.Cmd
- func ShowError(msg string) tea.Cmd
- func StartQuitting() tea.Cmd
- type ArticleFetcher
- type ArticleItem
- type Backend
- func (b Backend) Close(urlsReadOnly bool) error
- func (b Backend) DownloadItem(feedName string, index int) tea.Cmd
- func (b Backend) FetchAllArticles(_ string, refresh bool) tea.Cmd
- func (b Backend) FetchArticles(feedname string, refresh bool) tea.Cmd
- func (b Backend) FetchCategories(_ string) tea.Cmd
- func (b Backend) FetchDownloadedArticles(_ string, _ bool) tea.Cmd
- func (b Backend) FetchFeeds(catname string) tea.Cmd
- type DeleteItemMsg
- type DownloadItemMsg
- type EditItemMsg
- type FetchArticleSuccessMsg
- type FetchErrorMsg
- type FetchSuccessMsg
- type Fetcher
- type MakeChoiceMsg
- type MarkAsReadMsg
- type MarkAsUnreadMsg
- type NewItemMsg
- type SetEnableKeybindMsg
- type ShowErrorMsg
- type StartQuittingMsg
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DeleteItem ¶
DeleteItem is called from a tab to tell the browser that an item needs to be deleted.
func DownloadItem ¶ added in v1.1.0
DownloadItem is called from a tab to tell the browser that an item needs to be downloaded.
func EditItem ¶ added in v1.5.1
EditItem is called from a tab to tell the browser that an item needs to be edited.
func MakeChoice ¶ added in v1.3.0
MakeChoice is called from a tab to tell the browser that a binary choice prompt needs to be created.
func MarkAsRead ¶ added in v1.5.0
MarkAsRead is called from a tab to tell the browser that an item needs to be marked as read.
func MarkAsUnread ¶ added in v1.5.0
MarkAsUnread is called from a tab to tell the browser that an item needs to be marked as unread.
func SetEnableKeybind ¶ added in v1.5.1
SetEnableKeybind is called from a tab to tell the broswer that keybinds should be enabled/disabled.
func ShowError ¶ added in v1.7.0
ShowError is called from a tab to tell the browser to show an error msg
func StartQuitting ¶ added in v1.5.1
StartQuitting is called from a tab to tell the browser to start quitting.
Types ¶
type ArticleFetcher ¶ added in v1.5.2
ArticleFetcher fetches the article data, it is used by tabs to query data.
type ArticleItem ¶ added in v1.6.2
type ArticleItem struct { list.Item ArtTitle string Desc string RawDesc string MarkdownContent string FeedURL string }
ArticleItem is an item that contains article data.
func (ArticleItem) Description ¶ added in v1.6.2
func (a ArticleItem) Description() string
Description fulfills the list.DefaultItem interface
func (ArticleItem) FilterValue ¶ added in v1.6.2
func (a ArticleItem) FilterValue() string
FilterValue fulfills the list.Item interface
func (ArticleItem) Title ¶ added in v1.6.2
func (a ArticleItem) Title() string
Title fulfills the list.DefaultItem interface
type Backend ¶
Backend provides a way of fetching data from the cache and the RSS feed.
func (Backend) DownloadItem ¶ added in v1.1.0
DownloadItem downloads an article.
func (Backend) FetchAllArticles ¶ added in v1.0.2
FetchAllArticles gets all the articles from all the feeds.
func (Backend) FetchArticles ¶
FetchArticles gets the articles from a feed.
func (Backend) FetchCategories ¶
FetchCategories gets the categories.
func (Backend) FetchDownloadedArticles ¶ added in v1.1.0
FetchDownloaded gets the downloaded articles.
type DeleteItemMsg ¶ added in v1.3.0
DeleteItemMsg contains info the browser needs to know to delete an item.
type DownloadItemMsg ¶ added in v1.3.0
DownloadItemMsg contains info the browser needs to know to download an item.
type EditItemMsg ¶ added in v1.5.1
EditItemMsg contains info the browser needs to know to edit an item.
type FetchArticleSuccessMsg ¶ added in v1.3.0
FetchArticleSuccessMsg is sent on article fetch success.
type FetchErrorMsg ¶ added in v1.3.0
FetchErrorMsg is sent on fetch error.
type FetchSuccessMsg ¶ added in v1.3.0
FetchSuccessMsg is sent on fetch success.
type MakeChoiceMsg ¶ added in v1.3.0
MakeChoiceMsg contains info needed to create a binary choice prompt.
type MarkAsReadMsg ¶ added in v1.5.0
type MarkAsReadMsg string
MarkAsReadMsg contains info needed to mark an item as read.
type MarkAsUnreadMsg ¶ added in v1.5.0
type MarkAsUnreadMsg string
MarkAsUnreadMsg contains info needed to mark an item as unread.
type NewItemMsg ¶ added in v1.3.0
NewItemMsg contains info the browser needs to know to add a new item.
type SetEnableKeybindMsg ¶ added in v1.5.1
type SetEnableKeybindMsg bool
SetEnableKeybindMsg contains the desired state of the keybinds.
type ShowErrorMsg ¶ added in v1.7.0
type ShowErrorMsg struct {
Msg string
}
ShowErrorMsg is an error message "thrown" by a tab
type StartQuittingMsg ¶ added in v1.5.1
type StartQuittingMsg struct{}
StartQuittingMsg prompts the browser to start quitting (and perform a last browser redraw).