tui

package
v1.11.0 Latest Latest
Warning

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

Go to latest
Published: Mar 24, 2026 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RunBrowser

func RunBrowser(issues []models.Issue) error

RunBrowser starts the interactive issue browser.

func RunSearchBrowser

func RunSearchBrowser(results []models.SearchResult) error

RunSearchBrowser starts the interactive search result browser.

func RunSelector

func RunSelector(title string, items []SelectItem) (string, error)

RunSelector presents a selection list and returns the chosen value.

Types

type BrowserModel

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

BrowserModel is the bubbletea model for the issue browser.

func NewBrowserModel

func NewBrowserModel(issues []models.Issue) BrowserModel

NewBrowserModel creates a new browser model.

func (BrowserModel) Init

func (m BrowserModel) Init() tea.Cmd

Init implements tea.Model.

func (BrowserModel) Update

func (m BrowserModel) Update(msg tea.Msg) (tea.Model, tea.Cmd)

Update implements tea.Model.

func (BrowserModel) View

func (m BrowserModel) View() string

View implements tea.Model.

type IssueFormData

type IssueFormData struct {
	Subject     string
	Description string
	TrackerID   string
	PriorityID  string
	AssigneeID  string
}

IssueFormData holds data collected from the issue creation form.

func RunIssueForm

func RunIssueForm(trackers, priorities, assignees []SelectItem) (*IssueFormData, error)

RunIssueForm runs an interactive form for creating an issue.

type KeyMap

type KeyMap struct {
	Up     key.Binding
	Down   key.Binding
	Enter  key.Binding
	Back   key.Binding
	Filter key.Binding
	Quit   key.Binding
	Help   key.Binding
}

KeyMap defines key bindings for the TUI.

func DefaultKeyMap

func DefaultKeyMap() KeyMap

DefaultKeyMap returns the default key bindings.

type SearchBrowserModel

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

SearchBrowserModel is the bubbletea model for the search result browser.

func NewSearchBrowserModel

func NewSearchBrowserModel(results []models.SearchResult) SearchBrowserModel

NewSearchBrowserModel creates a new search browser model.

func (SearchBrowserModel) Init

func (m SearchBrowserModel) Init() tea.Cmd

Init implements tea.Model.

func (SearchBrowserModel) Update

func (m SearchBrowserModel) Update(msg tea.Msg) (tea.Model, tea.Cmd)

Update implements tea.Model.

func (SearchBrowserModel) View

func (m SearchBrowserModel) View() string

View implements tea.Model.

type SelectItem

type SelectItem struct {
	Label string
	Value string
}

SelectItem represents an item for selection.

type TimeEntryFormData

type TimeEntryFormData struct {
	Hours    string
	Comment  string
	Activity string
	Date     string
}

TimeEntryFormData holds data collected from the time entry form.

func RunTimeEntryForm

func RunTimeEntryForm(activities []SelectItem) (*TimeEntryFormData, error)

RunTimeEntryForm runs an interactive form for logging time.

Jump to

Keyboard shortcuts

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