tui

package
v0.0.0-...-aeffa93 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 17, 2023 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	AppStateInvalid  = -1
	AppStatePodcasts = iota
	AppStateEpisodes
	AppStatePodEpisodes
)

Variables

This section is empty.

Functions

func CmdWithSpinnerMessage

func CmdWithSpinnerMessage(msg string, cmd tea.Cmd) tea.Cmd

func NewApp

func NewApp() tea.Model

func Run

func Run() error

func SelectPodcast

func SelectPodcast(d models.DetailList) tea.Cmd

Types

type App

type App struct {
	// contains filtered or unexported fields
}

func (App) AddFocused

func (app App) AddFocused() bool

func (App) Init

func (app App) Init() tea.Cmd

func (*App) SetDimensions

func (app *App) SetDimensions(msg tea.WindowSizeMsg) tea.WindowSizeMsg

func (App) Update

func (app App) Update(msg tea.Msg) (tea.Model, tea.Cmd)

func (*App) UpdateEpisodes

func (app *App) UpdateEpisodes(data []*db.Episode) (tea.Model, tea.Cmd)

func (App) UpdateFeeds

func (app App) UpdateFeeds(data *db.SubData) (tea.Model, tea.Cmd)

func (*App) UpdatePodcasts

func (app *App) UpdatePodcasts(data []db.Feed) (tea.Model, tea.Cmd)

func (App) UpdateSubModels

func (app App) UpdateSubModels(msg tea.Msg) (tea.Model, tea.Cmd)

func (App) View

func (app App) View() string

type AppState

type AppState int

func (AppState) Render

func (a AppState) Render() (string, error)

func (AppState) Update

func (a AppState) Update(menu models.Menu) (AppState, error)

type AppStateError

type AppStateError struct {
	// contains filtered or unexported fields
}

func (*AppStateError) Error

func (e *AppStateError) Error() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL