screens

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Jan 28, 2026 License: MIT Imports: 25 Imported by: 0

Documentation

Overview

Package screens provides TUI screen implementations

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CleanScreen

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

CleanScreen is the release cleanup screen

func NewCleanScreen

func NewCleanScreen(ctx context.Context, client github.Client) *CleanScreen

NewCleanScreen creates a new clean screen

func (*CleanScreen) Init

func (c *CleanScreen) Init() tea.Cmd

Init initializes the clean screen

func (*CleanScreen) SetRepository

func (c *CleanScreen) SetRepository(owner, repo string) *CleanScreen

SetRepository sets the repository to clean

func (*CleanScreen) ShortHelp

func (c *CleanScreen) ShortHelp() []key.Binding

ShortHelp returns key bindings for the footer

func (*CleanScreen) Title

func (c *CleanScreen) Title() string

Title returns the screen title

func (*CleanScreen) Update

func (c *CleanScreen) Update(msg tea.Msg) (tea.Model, tea.Cmd)

Update handles messages

func (*CleanScreen) View

func (c *CleanScreen) View() string

View renders the clean screen

type ConfirmDeleteScreen

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

ConfirmDeleteScreen handles profile deletion confirmation

func NewConfirmDeleteScreen

func NewConfirmDeleteScreen(ctx context.Context, app *tui.App) *ConfirmDeleteScreen

NewConfirmDeleteScreen creates a new confirmation screen

func (*ConfirmDeleteScreen) Init

func (c *ConfirmDeleteScreen) Init() tea.Cmd

Init initializes the screen

func (*ConfirmDeleteScreen) SetProfile

func (c *ConfirmDeleteScreen) SetProfile(id, name string)

SetProfile sets the profile to be deleted

func (*ConfirmDeleteScreen) ShortHelp

func (c *ConfirmDeleteScreen) ShortHelp() []key.Binding

ShortHelp returns key bindings for the footer

func (*ConfirmDeleteScreen) Title

func (c *ConfirmDeleteScreen) Title() string

Title returns the screen title

func (*ConfirmDeleteScreen) Update

func (c *ConfirmDeleteScreen) Update(msg tea.Msg) (tea.Model, tea.Cmd)

Update handles messages

func (*ConfirmDeleteScreen) View

func (c *ConfirmDeleteScreen) View() string

View renders the confirmation screen

type DashboardAction

type DashboardAction int

DashboardAction represents available dashboard actions

const (
	ActionNewSync DashboardAction = iota
	ActionSyncAll
	ActionSyncPending
	ActionCleanReleases
	ActionViewHistory
)

type DashboardItem

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

DashboardItem represents a menu item in the dashboard

func (DashboardItem) Description

func (i DashboardItem) Description() string

func (DashboardItem) FilterValue

func (i DashboardItem) FilterValue() string

func (DashboardItem) Title

func (i DashboardItem) Title() string

type DashboardV2

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

DashboardV2 is the redesigned main dashboard screen

func NewDashboardV2

func NewDashboardV2(ctx context.Context, app *tui.App) *DashboardV2

NewDashboardV2 creates a new dashboard screen

func (*DashboardV2) Init

func (d *DashboardV2) Init() tea.Cmd

Init initializes the dashboard screen

func (*DashboardV2) ShortHelp

func (d *DashboardV2) ShortHelp() []key.Binding

ShortHelp returns key bindings for the footer

func (*DashboardV2) Title

func (d *DashboardV2) Title() string

Title returns the screen title

func (*DashboardV2) Update

func (d *DashboardV2) Update(msg tea.Msg) (tea.Model, tea.Cmd)

Update handles messages

func (*DashboardV2) View

func (d *DashboardV2) View() string

View renders the dashboard screen

type Onboarding

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

Onboarding is the first-run onboarding wizard screen

func NewOnboarding

func NewOnboarding(ctx context.Context, opts ...OnboardingOption) *Onboarding

NewOnboarding creates a new onboarding screen

func (*Onboarding) Init

func (o *Onboarding) Init() tea.Cmd

Init initializes the onboarding screen

func (*Onboarding) ShortHelp

func (o *Onboarding) ShortHelp() []key.Binding

ShortHelp returns key bindings for the footer

func (*Onboarding) Title

func (o *Onboarding) Title() string

Title returns the screen title

func (*Onboarding) Update

func (o *Onboarding) Update(msg tea.Msg) (tea.Model, tea.Cmd)

Update handles messages

func (*Onboarding) View

func (o *Onboarding) View() string

View renders the onboarding screen

type OnboardingOption

type OnboardingOption func(*Onboarding)

OnboardingOption configures the Onboarding screen

func WithEmbeddedMode

func WithEmbeddedMode() OnboardingOption

WithEmbeddedMode sets the onboarding to run in embedded mode (within unified app)

func WithSkipToSyncConfig

func WithSkipToSyncConfig(username string) OnboardingOption

WithSkipToSyncConfig skips auth steps and goes directly to sync config Used when auth is already complete but onboarding wasn't finished

func WithStorage

func WithStorage(storage *state.Storage) OnboardingOption

WithStorage sets the storage instance for persisting settings

type OnboardingResult

type OnboardingResult struct {
	LaunchDashboard bool
	Username        string
}

OnboardingResult contains the result of the onboarding flow

func RunOnboardingProgram

func RunOnboardingProgram(ctx context.Context) (*OnboardingResult, error)

RunOnboardingProgram runs the onboarding as a standalone program

type OnboardingStep

type OnboardingStep int

OnboardingStep represents the current step in onboarding

const (
	StepAuthMethod OnboardingStep = iota
	StepOAuthFlow
	StepTokenInput
	StepSyncConfig
	StepComplete
)

type ReleaseItem

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

ReleaseItem represents a release in the list

func (ReleaseItem) Description

func (i ReleaseItem) Description() string

func (ReleaseItem) FilterValue

func (i ReleaseItem) FilterValue() string

func (ReleaseItem) Title

func (i ReleaseItem) Title() string

type SyncProgressScreen

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

SyncProgressScreen shows sync operation progress for a profile or multiple profiles

func NewSyncProgress

func NewSyncProgress(ctx context.Context, app *tui.App) *SyncProgressScreen

NewSyncProgress creates a new sync progress screen

func (*SyncProgressScreen) Init

func (s *SyncProgressScreen) Init() tea.Cmd

Init initializes the sync progress screen

func (*SyncProgressScreen) ShortHelp

func (s *SyncProgressScreen) ShortHelp() []key.Binding

ShortHelp returns key bindings for the footer

func (*SyncProgressScreen) Title

func (s *SyncProgressScreen) Title() string

Title returns the screen title

func (*SyncProgressScreen) Update

func (s *SyncProgressScreen) Update(msg tea.Msg) (tea.Model, tea.Cmd)

Update handles messages

func (*SyncProgressScreen) View

func (s *SyncProgressScreen) View() string

View renders the sync progress screen

type SyncWizard

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

SyncWizard is the multi-step sync configuration wizard

func NewSyncWizard

func NewSyncWizard(ctx context.Context, app *tui.App) *SyncWizard

NewSyncWizard creates a new sync wizard screen

func (*SyncWizard) Init

func (w *SyncWizard) Init() tea.Cmd

Init initializes the sync wizard

func (*SyncWizard) ShortHelp

func (w *SyncWizard) ShortHelp() []key.Binding

ShortHelp returns key bindings for the footer

func (*SyncWizard) Title

func (w *SyncWizard) Title() string

Title returns the screen title

func (*SyncWizard) Update

func (w *SyncWizard) Update(msg tea.Msg) (tea.Model, tea.Cmd)

Update handles messages

func (*SyncWizard) View

func (w *SyncWizard) View() string

View renders the sync wizard screen

type SyncWizardStep

type SyncWizardStep int

SyncWizardStep represents the current step in the sync wizard

const (
	WizardStepSelectSource SyncWizardStep = iota
	WizardStepLoadingOrgs
	WizardStepSelectOrg
	WizardStepFetchRepos
	WizardStepRepoMode // Choose: sync all or select specific
	WizardStepSelectRepos
	WizardStepSetTarget
	WizardStepConfirm
	WizardStepExecute
	WizardStepComplete
)

type WizardRepoItem

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

WizardRepoItem represents a repository in the selection list

func (WizardRepoItem) Description

func (r WizardRepoItem) Description() string

func (WizardRepoItem) FilterValue

func (r WizardRepoItem) FilterValue() string

func (WizardRepoItem) Title

func (r WizardRepoItem) Title() string

Jump to

Keyboard shortcuts

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