Documentation
¶
Overview ¶
Package statusbar renders the single-line footer: the mode, the diff's source and destination, and the keybinding hints for whatever the user is doing.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Context ¶
type Context struct {
Destination string
FocusedPanel string
Mode string
Source string
IsVisualMode bool
}
Context is what the footer describes. Destination is omitted from the render when empty, and FocusedPanel is "files" or the diff pane, which selects which hints are shown.
type Model ¶
type Model struct{}
Model is stateless: the footer is rendered entirely from the Context passed to each call.
func (Model) View ¶
View renders the footer with the file list treated as focused. Use ViewWithContext to say which panel has focus.
func (Model) ViewWithContext ¶
ViewWithContext renders the footer to exactly width columns. Hints that do not fit are dropped from the right and replaced by an ellipsis, and the help hint always survives because it is the only route to the rest of the keymap.