Documentation
¶
Overview ¶
Package tui implements the interactive terminal dashboard for monitoring the aetherflow daemon. It provides a k9s/btop-style interface with a dashboard overview, agent detail panels, and log streaming.
The TUI communicates with the daemon via the existing Unix socket RPC protocol and polls for updates on a configurable interval.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Config ¶
type Config struct {
// SocketPath is the Unix socket path for the daemon RPC.
SocketPath string
}
Config holds the configuration needed to run the TUI.
type LogStreamModel ¶
type LogStreamModel struct {
// contains filtered or unexported fields
}
LogStreamModel is the full-screen event log viewer. It reads events from the daemon's in-memory buffer via the events.list RPC, formats them, and renders in a scrollable viewport. New events are polled on each tick (every 2s from the parent).
func NewLogStreamModel ¶
func NewLogStreamModel(agentID string, c *client.Client, width, height int) LogStreamModel
NewLogStreamModel creates a new log stream viewer for the given agent.
func (LogStreamModel) Init ¶
func (m LogStreamModel) Init() tea.Cmd
Init returns the initial fetch command.
func (LogStreamModel) Update ¶
func (m LogStreamModel) Update(msg tea.Msg) (LogStreamModel, tea.Cmd)
Update handles messages for the log stream screen.
func (LogStreamModel) View ¶
func (m LogStreamModel) View() string
View renders the full-screen log stream.
type Model ¶
type Model struct {
// contains filtered or unexported fields
}
Model is the top-level bubbletea model for the TUI.
func (Model) Init ¶
Init implements tea.Model. Kicks off the first status poll and tick. Agent details for all running agents are fetched once the first statusMsg arrives.
type PanelModel ¶
type PanelModel struct {
// contains filtered or unexported fields
}
PanelModel holds the state for the agent master panel screen.
func NewPanelModel ¶
func NewPanelModel(agent client.AgentStatus, width, height int) PanelModel
NewPanelModel creates a new panel for the given agent.
func (PanelModel) Init ¶
func (m PanelModel) Init() tea.Cmd
Init returns the command to fetch task detail.
func (PanelModel) Update ¶
func (m PanelModel) Update(msg tea.Msg) (PanelModel, tea.Cmd)
Update handles messages for the panel screen.
type TaskDetail ¶
type TaskDetail struct {
ID string `json:"id"`
Title string `json:"title"`
Type string `json:"type"`
Status string `json:"status"`
Priority int `json:"priority"`
Project string `json:"project"`
Parent string `json:"parent"`
Description string `json:"description"`
DefinitionOfDone *string `json:"definition_of_done"`
Labels []string `json:"labels"`
Dependencies []string `json:"dependencies"`
Logs []TaskLog `json:"logs"`
}
TaskDetail holds the parsed output from `prog show --json <task_id>`.