Documentation
¶
Overview ¶
Package keys is the binding registry (doc 02 section 12). Every keystroke the UI acts on is a semantic Action bound in one scope; config rebinds by Action name, the help line reads the live binding, and a collision inside a scope is a load error rather than a silent winner.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Action ¶
type Action int
Action names a semantic action, not a key.
const ( // Global scope. Quit Action = iota HelpToggle Palette ThemePick Cancel FocusNext // Editor scope. Submit Newline ExternalEditor // Chat scope. ScrollUp ScrollDown PageUp PageDown GotoBottom // Dialog scope. Confirm NextChoice PrevChoice // Diff scope: the edit-result and approval diff view. NextHunk PrevHunk ToggleDiff DiffLeft DiffRight )
type Map ¶
type Map struct {
// contains filtered or unexported fields
}
Map is the full live keymap. The zero value is unusable; start from Default and overlay config with Apply.
func (Map) Apply ¶
Apply overlays user bindings, keyed by action name, then validates. A rebind replaces the whole key set for that action; the first key listed becomes the one help shows. Unknown action names and same- scope collisions are errors, listed exhaustively so one config pass fixes them all.