Skip to content

API Reference

Full API documentation is available on pkg.go.dev.

Core

Type Description
App Application container configured via functional options
Component Interface all components implement (Init, Update, View, KeyBindings, SetSize, Focused, SetFocused)
Context Per-update context carrying Theme, Size, Focus, Hotkeys, Clock, Logger
Option Functional option for NewApp configuration
Theme Semantic color tokens (Positive, Negative, Accent, Muted, etc.)
Themed Interface for components that accept a theme via SetTheme
Registry Keybinding registry with conflict detection
KeyBind Keybinding definition (key, label, group, handler)
KeyGroup Named group of keybindings for the help overlay
SlotName Named layout slot (Main, Sidebar, Footer)
Size Width/height pair
Focus Focus state for components

Interfaces

Type Description
Activatable Components that can be activated/deactivated (overlays)
Overlay Full-screen overlay (IsActive, Close)
InlineOverlay Single-line overlay (e.g., CommandBar)
FloatingOverlay Positioned overlay composited over background (e.g., Tooltip)
Layout Layout container interface
Sized Components that accept size via SetSize
InputCapture Components that capture keyboard input
Clock Time provider for animations and ticks
Module Lifecycle module interface (Init, Start, Stop, Status)
ModuleWithKeybinds Module that registers keybindings
ModuleWithProviders Module that provides debug data
DebugProvider Dev console data provider
DebugDataProvider Dev console data source
StringSource Reactive string value source
BackoffStrategy Retry backoff strategy
TableRowProvider Virtual table data source for large datasets

Components

Type Description
Table Adaptive table with sorting, filtering, custom rendering, virtualization
ListView Generic scrollable list with cursor navigation
Tabs Tabbed container with horizontal/vertical orientation
Form Multi-field form with validation and wizard mode
Picker Fuzzy-search selection list
Tree Expandable tree view
FilePicker File system browser with tree navigation and preview
LogViewer Streaming log viewer with level filtering
Viewport Scrollable content pane
StatusBar Left/right footer driven by closures or signals
Help Auto-generated keybinding overlay
Accordion Collapsible sections with exclusive mode
Breadcrumb Navigable path display with Push/Pop API
Breadcrumbs Navigation breadcrumb trail
ChartPanel Switchable container for chart components
CommandBar Inline command palette with tab completion
ConfigEditor Settings overlay with grouped fields and validation
CollapsibleSection Toggleable content section
Kanban Multi-column board with card movement
ProgressBar Value-based progress indicator with label and percentage
Spinner Animated loading indicator cycling through glyph frames
Stepper Multi-step progress indicator with navigation
Timeline Vertical/horizontal event sequence with status icons

Overlays

Type Description
Dialog Modal dialog with button navigation
Menu Popup menu with separators and shortcuts
Tooltip Floating hint composited over background
DetailOverlay Generic detail view overlay
ReleaseNotesOverlay Release notes display overlay
ForcedUpdateScreen Forced update prompt screen
ToastMsg Toast notification message

Layout

Type Description
DualPane Main + collapsible sidebar layout
SinglePane Single component layout
HBox Horizontal flex container
VBox Vertical flex container
Flex Flexible layout container
Split Resizable split pane

Form Fields

Type Description
Field Interface for form field types
TextField Single-line text input
PasswordField Masked password input
NumberField Numeric input with validation
SelectField Single-select dropdown
MultiSelectField Multi-select checkbox list
ConfirmField Boolean yes/no toggle
Validator Field validation function

Configuration Types

Type Description
Column Table column definition
Row Table row (string slice)
TableOpts Table configuration options
TabItem Tab definition with label and content
TabsOpts Tabs configuration options
FormOpts Form configuration options
FormGroup Form field group
TreeOpts Tree configuration options
Node Tree node with children
PickerItem Picker entry with label and metadata
PickerOpts Picker configuration options
FilePickerOpts FilePicker configuration options
LogLine Log entry with level, timestamp, and message
LogLevel Log severity level (Debug, Info, Warn, Error)
StatusBarOpts StatusBar configuration options
AccordionSection Accordion section with title and content
AccordionOpts Accordion configuration options
BreadcrumbItem Breadcrumb entry with label and data
BreadcrumbOpts Breadcrumb configuration options
Command CommandBar command definition
ConfigField ConfigEditor field definition
DialogButton Dialog action button
DialogOpts Dialog configuration options
MenuItem Menu entry with label, shortcut, and action
MenuOpts Menu configuration options
KanbanCard Kanban card with title, description, and tag
KanbanColumn Kanban column with cards
KanbanOpts Kanban configuration options
ProgressBarOpts ProgressBar configuration options
SpinnerOpts Spinner configuration options
Step Stepper step definition
StepperOpts Stepper configuration options
StepStatus Step state (Pending, Active, Done)
TimelineEvent Timeline event with time, title, and status
TimelineOpts Timeline configuration options
TooltipOpts Tooltip configuration options
ChartPanelOpts ChartPanel configuration options
ToastAction Toast notification action button
ToastManagerOpts Toast system configuration
ToastSeverity Toast level (Info, Success, Warning, Error)
DetailOverlayOpts Detail overlay configuration
DetailRenderer Custom detail view renderer function

Theme & Styling

Type Description
Glyphs Custom cursor/flash/spinner glyphs
StyleSet Named style collection on a theme
BorderSet Border character set
Gradient Color gradient for text rendering
ViewportGlyphs Scrollbar track/thumb characters
ThemeHotReload File-watching theme reloader
ThemeHotReloadMsg Theme reload success message
ThemeHotReloadErrMsg Theme reload error message

Animation

Type Description
Ease Easing function type (func(float64) float64)
Tween Time-based animation tween

Reactive State

Type Description
Signal Generic reactive value with subscriber notifications
AnySignal Type-erased signal interface
Unsubscribe Callback to remove a signal subscription
Config Generic configuration manager with file persistence
ConfigOption Configuration loading option

Self-Update

Type Description
UpdateConfig Self-update configuration
UpdateResult Result of checking for updates
UpdateCache Cached update check data
UpdateMode Update behavior mode (Notify, Blocking, Forced, Silent)
UpdateProgress Download progress display component
UpdateProgressMsg Progress update message
Release GitHub release metadata
ReleaseAsset Release binary asset
Version Parsed semantic version
InstallMethod Detected installation method (binary, Homebrew, Scoop)
RateLimitError GitHub API rate limit error

Data & Polling

Type Description
Poller Background data fetcher with tick-driven refresh
PollerOpts Poller configuration options
PollerStats Poller runtime statistics
PollerSuccessMsg Successful poll result message
PollerErrorMsg Poll error message
PollerStartMsg Poller started message
PollerRateLimitedMsg Rate-limited poll message
RetryOpts Retry command configuration
RetryErrorMsg Retry exhaustion error message

Table Helpers

Type Description
CellRenderer Custom table cell render function
RowStyler Custom row background styler
RowClickHandler Mouse click handler for table rows
CursorChangeHandler Callback for cursor movement
FilterFunc Custom table filter function
SortFunc Custom table sort function
TableRowProviderFunc Function-based virtual table provider
NodeRenderFunc Custom tree node render function

Enums

Type Description
Alignment Text alignment (Left, Center, Right)
Orientation Layout orientation (Horizontal, Vertical)
CursorStyle Cursor rendering style
SelectionMode Tree selection mode (None, Single, Multi)
FlexAlign Flex cross-axis alignment
FlexJustify Flex main-axis justification
ForcedChoice Forced update user choice

Messages

Type Description
TickMsg Periodic tick message
SetThemeMsg Theme change message
NotifyMsg User notification message
LogAppendMsg LogViewer append message
FormSubmitMsg Form submission message
CopyToClipboardMsg Clipboard copy message

SSH Serve

Type Description
ServeConfig SSH server configuration for hosting TUI apps

Packages

Package Description
cli Interactive CLI prompts (Confirm, Select, Input, Spinner, Progress)
charts Chart components (Bar, Line, Ring, Gauge, Heatmap)
btest Virtual terminal testing framework