M7: editor keyboard + one-click card toolbars (live-pass fixes)
CI & Build / Python lint (push) Successful in 2s
CI & Build / TypeScript typecheck (push) Successful in 5s
CI & Build / Python tests (push) Successful in 9s
CI & Build / Build & push image (push) Successful in 30s

From the unified-editor live pass (task 1922):

- Esc now returns to the base Notes board from any view (AppShell); an open editor consumes Esc first (its handler stops propagation) so it closes before navigating.

- Ctrl/Cmd+Enter = finish & close in BOTH frames — it already closed the modal editor; now it also commits+collapses the board composer (matches the email/chat 'send' convention). Shift+Enter still saves & starts a new note.

- Fix: the inline composer committed on document mousedown, collapsing and shifting the board before a click landed — so clicking another card's pin/archive/trash took two clicks. Commit on click (bubble phase) instead; the target's action fires first, then the composer closes.

Pure frontend.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01FRgehjoz7Yv8LkUfADxACm
This commit is contained in:
2026-07-22 14:53:18 -04:00
co-authored by Claude Opus 4.8
parent 261d8fcac5
commit 47974f62ee
2 changed files with 18 additions and 7 deletions
+8 -2
View File
@@ -36,9 +36,9 @@ const shortcuts = [
{ label: "Move card focus", keys: ["j", "k"] },
{ label: "Open focused card", keys: ["Enter"] },
{ label: "Pin / archive / trash card", keys: ["#", "e", "x"] },
{ label: "Save & close (editor)", keys: ["⌘/Ctrl", "Enter"] },
{ label: "Finish & close note", keys: ["⌘/Ctrl", "Enter"] },
{ label: "Save & new (composer)", keys: ["Shift", "Enter"] },
{ label: "Dismiss / close", keys: ["Esc"] },
{ label: "Close / back to Notes", keys: ["Esc"] },
{ label: "This help", keys: ["?"] },
];
@@ -84,6 +84,12 @@ function onKeydown(e: KeyboardEvent) {
drawer.value = false;
return;
}
// Esc with nothing open = back to the base Notes board. (An open editor gets Esc
// first via its own handler, which stops propagation so it doesn't also navigate.)
if (e.key === "Escape") {
if (route.name !== "board") void router.push("/");
return;
}
if (e.metaKey || e.ctrlKey || e.altKey) return;
if (gPending) {
gPending = false;