mirror of
https://github.com/l0ng-ai/tty7.git
synced 2026-09-22 08:02:24 +00:00
Renames `RightPanelTab::Changes` to `Scm` in place. `#[serde(rename = "changes")]` works in both directions, so what lands on disk is unchanged and a build from before this commit reads the config back without kicking anyone off the panel they left open — a fourth variant could not do that, and 260px has no room for a fourth tab tile anyway. The action name `ShowRightPanelChanges` stays put because `Config::keybindings` is keyed by it, and every existing custom binding would otherwise be orphaned. The panel body moves to `src/ui/scm/panel.rs` byte for byte; it still renders the flat `git diff HEAD` list. Alongside it the module gets the pieces the rest of the feature is built from: the shared status glyph and colour tables (one definition instead of three that drift), the path and timestamp helpers a 260px column needs, and the panel's state types. Also wires the whole surface: fourteen actions, their key bindings, ten palette commands in a `Git` group of their own, and the translations. `ScmCommit` takes `secondary-enter`, which macOS already gives `ToggleFullscreen`; the two coexist because the commit binding is scoped to the commit box, and `every_default_chord_is_claimed_by_exactly_one_action` now checks uniqueness per context instead of globally, which is the actual invariant gpui enforces. `Config` gains `diff_view` and `scm_graph_expanded`. Both default to what happens today. Two new icons. `git-sync.svg` is deliberately not `refresh.svg`: the panel header already carries a refresh tile, and the same glyph meaning two different things one row apart reads as a bug. Adds `every_action_has_a_binding_arm`, which walks every action in `default_bindings` rather than only the ones shipping a default keystroke. The gap it closes is an action listed in Settings with no `make_binding` arm behind it: the user assigns a key and the key silently does nothing.
399 B
399 B