M4.2: Lutra-own shortcuts for the Changes window
vcs.commit moves from Mod+K (the public default keymap's Commit) to Mod+Alt+Shift+M, and vcs.openChanges from Mod+Alt+G (CodeMirror's go to line in basicSetup, which the global listener would swallow) to Mod+Alt+Shift+G. Both were checked against the public Windows and macOS default keymap pages, Lutra's registered shortcuts and CodeMirror's keys. Tests and docs follow. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
parent
f67f6b9f7c
commit
eb7e6376b7
8 changed files with 14 additions and 13 deletions
|
|
@ -576,7 +576,7 @@ Watched directories: the VFS watcher is non-recursive, so `project.children` wat
|
|||
### Changes tool window (M4.2)
|
||||
|
||||
- **Where:** a Changes tab in the bottom panel (`ui/src/components/vcs/changes/`): `changes.ts` is the Pinia store, `ChangesToolWindow.vue` the window. The main layout starts the store when it mounts, so the status is current before the tab opens, and supplies the UI commands.
|
||||
- **Commands** (UI commands, menu group Git): `vcs.openChanges` `Mod+Alt+G` shows the tab; `vcs.commit` `Mod+K` shows it and focuses the message box; `vcs.refresh` re-reads the status (enabled while `git.status` is).
|
||||
- **Commands** (UI commands, menu group Git): `vcs.openChanges` `Mod+Alt+Shift+G` shows the tab; `vcs.commit` `Mod+Alt+Shift+M` shows it and focuses the message box; `vcs.refresh` re-reads the status (enabled while `git.status` is). The shortcuts are Lutra's own: checked against the public default keymaps (Windows and macOS) so they copy no default there, and against Lutra's registered shortcuts and CodeMirror's `basicSetup` keys (`Mod+Alt+G` is its go to line, which the global listener would swallow).
|
||||
- **Status:** `git.status` through `runWaiting` on start, on `projectOpened`, on `gitChanged` and on `vcs.refresh`; calls are serialised and requests made during a round cause exactly one more round. `projectClosed` clears it. The result is untrusted: unknown states and malformed entries are dropped, at most 50,000 files. The event type `gitChanged` is now part of `EngineEventPayload` in `ui/src/ipc.ts`.
|
||||
- **Groups:** Staged (the index side changed), Changes (the work tree side changed, or conflicted), Untracked. A partly staged file is in Staged and Changes. Names are coloured with `--lt-vcs-*` (renamed and modified use `modified`, copied uses `added`); a deleted file is struck through. A staged rename shows "from <old path>".
|
||||
- **Staging:** a checkbox per file and per group header: checked in Staged (clearing it unstages), clear elsewhere (checking it stages). `git.stage {paths}` / `git.unstage {paths}`, both through `runWaiting`; unstaging a staged rename passes both paths, as M4.1 requires. Keyboard: Up/Down, Page Up/Down, Home, End move; Space stages or unstages; Enter opens. Failures toast git's message (`notification.command.failed`).
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue