tui

package
v0.7.0 Latest Latest
Warning

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

Go to latest
Published: Jul 10, 2026 License: MIT Imports: 14 Imported by: 0

Documentation

Overview

actions.go — task operations shared between the board and list views.

board.go — kanban board sub-model for the North TUI.

The board renders the whole two-axis model on one screen: a draft column on the far left, the five status columns for active tasks in flow order, and an archive column on the far right. A task enters left, flows right.

The board holds navigation state only; action keys (c/e/m/s/d), search, and every modal live in the root Model so both views behave identically.

deps.go — the w link modal: a multi-select picker over the board's tasks that edits the selected task's depends_on.

The list shows every draft and active task plus the task's existing dependencies whatever their state, so applying can never silently drop a dep. Resolved candidates (done or archived) are selectable but marked ✓ — such a link is born satisfied and documents lineage rather than gating. Invalid choices (the task itself, anything that would create a cycle) are greyed with a reason instead of hidden; the picker never assembles an illegal set, at any deps_enforcement level. `/` filters in place with the same matcher as the main views.

editor.go — the $EDITOR flow for creating and editing tasks.

The editor buffer uses the real on-disk task-file format (YAML frontmatter + Markdown body), restricted to the editable fields: title, assignee, labels, depends_on, and the body. id/state/status are managed by their own keys and never appear in the buffer. Parsing reuses the same frontmatter code as the task files themselves.

list.go — list+detail sub-model for the North TUI.

The list holds navigation state only; action keys (c/e/m/s/d), search, and every modal live in the root Model so both views behave identically.

modal.go — the single modal layer shared by both views.

All modals (status picker, state picker, delete confirm) are owned by the root Model, so the board and list views behave identically for the same key and hold no modal state of their own.

Package tui provides the interactive terminal UI for North, built with Bubble Tea. It exposes a single entry point: NewModel.

The TUI is keyboard-only by design — no mouse support, anywhere.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Model

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

Model is the root Bubble Tea model. It owns the view-mode switch, the modal layer, the $EDITOR flow, the search filter, and the status bar; navigation and rendering are delegated to boardModel and listModel.

func NewModel

func NewModel(boardDir string, opts Options) Model

NewModel constructs a Model for the board at boardDir.

func (Model) Init

func (m Model) Init() tea.Cmd

Init loads initial data for both sub-models.

func (Model) Update

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

Update handles global events (resize, quit, help, modals, search, action keys) and delegates navigation to the active sub-model.

func (Model) View

func (m Model) View() string

View renders the active view, the help overlay, or the modal layer.

type Options added in v0.7.0

type Options struct {
	Theme        string // preset name; empty means default
	ThemeWarning string // pre-resolved warning to show at startup (e.g. unreadable user config)
	ConfigPath   string // user config file the theme came from, for warning context
}

Options configures the TUI at startup.

Jump to

Keyboard shortcuts

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