tui

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Feb 26, 2026 License: MIT Imports: 44 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PrintDebugJSON

func PrintDebugJSON(debugInfo *DebugInfo)

PrintDebugJSON formats and prints DebugInfo as JSON to stdout. Used by the debug command to output debug information.

func ReadFromClipboard

func ReadFromClipboard(svc clipboard.Service, cfg *config.Config) (string, error)

ReadFromClipboard reads content from the system clipboard

Types

type App

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

func NewApp

func NewApp(providerMap map[providers.MediaType]providers.Provider, db *gorm.DB, cfg interface{}, logger *slog.Logger, audioPreference string) *App

func (*App) Init

func (a *App) Init() tea.Cmd

func (*App) Update

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

func (*App) View

func (a *App) View() string

type DebugInfo

type DebugInfo struct {
	MediaTitle    string
	EpisodeTitle  string
	EpisodeNumber int
	StreamURL     string
	Quality       providers.Quality
	Type          providers.StreamType
	Referer       string
	Headers       map[string]string
	Subtitles     []providers.Subtitle
	Error         error
}

DebugInfo holds the debug information for media

func Start

func Start(providers map[providers.MediaType]providers.Provider, trackerMgr interface{}, db *gorm.DB, cfg interface{}, logger *slog.Logger, audioPreference string) *DebugInfo

Start is the entry point for the TUI. Returns debug information if in debug mode, otherwise nil.

func StartDebugLinks(providers map[providers.MediaType]providers.Provider, trackerMgr interface{}, db *gorm.DB, cfg interface{}, logger *slog.Logger, audioPreference string) *DebugInfo

StartDebugLinks is the entry point for the TUI in debug links mode. Returns debug information that should be printed after TUI exit.

Jump to

Keyboard shortcuts

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