help

package
v0.7.11 Latest Latest
Warning

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

Go to latest
Published: May 1, 2026 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const ID = "help"

ID is the focus identifier for the help component.

Variables

This section is empty.

Functions

This section is empty.

Types

type Component

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

Component renders the application help screen.

func New

func New(nav Navigator, width, height *int, elemPos *map[string]int) *Component

New creates a help Component.

func (*Component) Blur

func (h *Component) Blur()

Blur removes focus from the component.

func (*Component) Focus

func (h *Component) Focus() tea.Cmd

Focus marks the component as focused.

func (*Component) Focusables

func (h *Component) Focusables() map[string]focus.Focusable

Focusables exposes focusable elements for the help component.

func (*Component) Focused

func (h *Component) Focused() bool

Focused reports whether the component is focused.

func (*Component) Init

func (h *Component) Init() tea.Cmd

Init implements tea.Model.

func (*Component) SetSize

func (h *Component) SetSize(width, height int)

SetSize configures the viewport dimensions.

func (*Component) Update

func (h *Component) Update(msg tea.Msg) tea.Cmd

Update handles key events and viewport updates.

func (*Component) View

func (h *Component) View() string

View renders the help content.

type Focusable

type Focusable = focus.Focusable

Focusable re-exports the focus.Focusable interface.

type Navigator interface {
	SetMode(mode constants.AppMode) tea.Cmd
	PreviousMode() constants.AppMode
	Width() int
	Height() int
}

Navigator provides navigation control for the help component.

Jump to

Keyboard shortcuts

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