Skip to content

feat(explorer): common hotkeys in the Explorer and the project tree (#330) - #331

Merged
Maxaubert merged 3 commits into
mainfrom
feat/330-explorer-hotkeys
Oct 8, 2026
Merged

Maxaubert merged 3 commits into
mainfrom
feat/330-explorer-hotkeys

Conversation

@Maxaubert

Copy link
Copy Markdown
Owner

The owner, 2026-10-07: "add common hotkeys to the explorer and project so that for example ctrl + A selects all".

One pure mapping, lib/listKeys.ts (unit-tested), for the Explorer's list and the project tree, so the same chord does the same thing on both. Every key is behind the typing guard, comes from the rows only, and is CLAIMED, because the player, the PDF and the archive panel listen on the window.

Keys

Key Explorer list Project tree
Ctrl+A marks every row marks every row shown (already there, kept)
Ctrl+Shift+A, Esc clears the marks (Esc only when something is marked and nothing nearer owns Escape) same
Shift+Up/Down/Home/End marks the run from the anchor, opens and plays nothing (#263) same
Ctrl+Up/Down/Home/End moves the keyboard, not the marks same
Ctrl+Space marks or unmarks the row the keyboard is on same
Ctrl+Shift+N "New folder" in the folder shown, then its rename in the folder row, or beside the file row, then its rename
Ctrl+D, Shift+Del Delete: the question, then the Recycle Bin (the marks decide) same
Alt+Up up a folder (already there) the parent row
Alt+Left/Right back / forward (already there) claimed, does nothing
F3 the folder search the tree filter
Alt+Enter Prism's Properties Prism's Properties
Ctrl+Shift+C the full paths as text, one per line same
Ctrl+Enter a folder in a new Explorer tab (a file: nothing) same
a letter (the list's own type-to-jump, unchanged) type-to-jump, taken only on a match, letters only

Not mapped: Ctrl+Left/Right (Left and Right are not navigation keys, 2026-09-01). Inside a zip, Ctrl+D, Ctrl+Shift+N and Alt+Enter do nothing.

The four decisions (owner, in the session)

  1. Shift+Del is NOT a permanent delete. It is Delete: the question, then the Recycle Bin. "Nothing is destroyed" still holds.
  2. Type-to-jump in the tree is taken only on a match; otherwise the letter still reaches the viewer (a film's k/j/l/m, a picture's f).
  3. F3: the folder search / tree filter from the rows; the PDF keeps F3 only with the focus in it.
  4. Alt+Enter opens Prism's own Properties, not Windows'.

A rule change: new folder

CLAUDE.md said "new folder" was a fresh decision, not a natural next step. The owner said yes to Ctrl+Shift+N: main names it "New folder", "(2)" and on, checks the place, never inside a zip; the rename starts at once; undo kind mkdir bins it only while it is still empty, and the rename that follows folds into it, so one Ctrl+Z takes it away.

Review fixes (second commit)

  • Alt+Up in the tree no longer opens or plays the row above on its way to the parent.
  • A folder row no longer looks selected when the keyboard sits on it apart from the marks.
  • Delete, Ctrl+D and Shift+Del take the marks in the tree too, never a row the Ctrl keys or Esc left unlit (the Explorer's rule).
  • Esc yields to a nearer closer (the sidebar peek, the PDF find bar, anything with data-owns-escape).
  • Type-to-jump takes letters only: digits and . , are the player's.
  • After a rename (Ctrl+Shift+N always ends in one) the keyboard follows the row to its new name.
  • AZERTY gets no extra binding from the physical key.
  • Shift+Del is Delete from the viewer too.

Rejected: an e2e for the archive panel's Ctrl+A stepping aside. ArchiveView renders only on the phone page now (#300), where there is no tree or Explorer list, so the guard cannot be reached on the desktop; it stays as a defensive line.

Tests

  • npm run typecheck, npm run lint (0 errors), npm test: 2604 passed.
  • e2e, locally: hotkeys (new; every key on both surfaces, a paused film under every claimed chord, a zip, the PDF, Esc yielding, the bin keys off the marks), sidebarPeek (Esc on a row puts the peek away), and treeNav, selection, markTint, rightClickSelect, treeVerbs, deleteAgain, arrowKeys, deleteLast, searchNav: all passed.

Version 0.97.0. Unsigned, as every release until the SignPath enrolment.

Closes #330

🤖 Generated with Claude Code

https://claude.ai/code/session_01FHHaWKR4M5QtW7Wecyuk4t

Maxaubert and others added 3 commits October 7, 2026 22:55
…330)

The owner, 2026-10-07: "add common hotkeys to the explorer and project so
that for example ctrl + A selects all". One pure mapping (lib/listKeys.ts)
for the Explorer's list and the project tree:

- Ctrl+A selects all; Ctrl+Shift+A and Esc clear.
- Shift+Up/Down/Home/End extend from the anchor (rangeSelect), quiet (#263).
- Ctrl+Up/Down/Home/End move the keyboard's place without marking;
  Ctrl+Space marks or unmarks it. Not Ctrl+Left/Right (2026-09-01 rule).
- Ctrl+Shift+N makes "New folder" ("(2)" and on, named in main, never in a
  zip) and starts its rename; undo kind mkdir bins it only while empty, and
  the rename that follows folds into it, so one Ctrl+Z takes it away.
- Ctrl+D and Shift+Delete are Delete: the question, then the Recycle Bin.
- Alt+Up is the tree's parent row; type-to-jump in the tree on a match only.
- F3 opens the folder search / tree filter; the PDF yields a claimed F3.
- Alt+Enter opens Properties; Ctrl+Shift+C copies the full paths;
  Ctrl+Enter opens a folder in a new Explorer tab.

Every key is behind the typing guard and claimed: App leaves Shift/Ctrl
arrows to the lists, the archive panel's and the tree's Ctrl+A step aside
for the other surface, tree rows ignore chords. New e2e scenario `hotkeys`.
Version 0.97.0.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01FHHaWKR4M5QtW7Wecyuk4t
- Alt+Up in the tree no longer walks to the row above first: App leaves
  Alt+Up/Down to the lists, as it does Shift and Ctrl, so the row above is
  never opened or played on the way to the parent.
- A folder row honours cursorMarks: after Ctrl+Up/Down, Esc or Ctrl+Space
  only the marks light it, as on a file row.
- The marks decide what Delete, Ctrl+D and Shift+Delete take in the tree, the
  Explorer list's rule: a row the Ctrl keys or Esc left unlit is never binned.
- Esc as "clear" yields to a nearer closer (lib/nearerEscape: anything with
  data-owns-escape, the sidebar peek), so the peek and the PDF find bar close.
- Type-to-jump takes letters only: a digit is the player's seek and . , its
  frame step, and a jump opens what it lands on.
- After a rename the keyboard follows the row to its new name, and Escape in
  the name keeps it on the row (Ctrl+Shift+N always ends in a rename).
- A letter chord matches the physical key only when the layout's own key is
  not a Latin letter (AZERTY's Ctrl+Q is not Ctrl+A).
- Shift+Delete is Delete from the viewer too (the tree's window listener and
  App's Explorer viewer).

The hotkeys e2e now covers a paused film under every claimed chord, Ctrl and
Shift+Home/End on both surfaces, Alt+Left/Right and a second Ctrl+Space in
the tree, Ctrl+Shift+N from a file row, Ctrl+Enter on a file, the inert keys
inside a zip, a letter the PDF would take, a digit that is not a jump, Esc
yielding to the PDF find bar, Alt+Up past a row that is not the parent, and
the bin keys off the marks. sidebarPeek: Esc on a row puts the peek away.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01FHHaWKR4M5QtW7Wecyuk4t
@Maxaubert
Maxaubert merged commit 952e309 into main Oct 8, 2026
3 checks passed
@Maxaubert
Maxaubert deleted the feat/330-explorer-hotkeys branch October 8, 2026 10:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(explorer): common hotkeys in the Explorer and the project tree

1 participant