feat(desktop): keyboard shortcuts — ⌘⇧N new channel + ↑-to-edit last message#809
Merged
Conversation
…message - ⌘⇧N opens the new-channel flow from anywhere - ↑ in an empty composer opens edit mode for your most recent message, resolved per-surface (channel / DM / thread, >= tie-break) - Fix the WebView blur-on-send bug: the editable-toggle on `isSending` blurred the contenteditable in the app WebView, stranding focus on body so ↑ never reached the editor. Now record `isFocused` before disable and restore focus to that same editor on re-enable (scoped, won't steal focus from another composer). Confirmed via instrumented probes in the WebView. - 3 ArrowUp e2e cases in messaging.spec.ts (Chromium passes with/without the focus fix — the WebView regression needs a Tauri-webdriver harness; tracked as a follow-up). - check-file-sizes.mjs: documented overrides for useRichTextEditor.ts (560) and bump MessageComposer.tsx (800 → 820) for the edit-callback wiring. Signed-off-by: npub1yxv5wk0u0fh6dwt925wntn7h397jvteyj4r87ttcd9xae7n2t3lqqj9jmm <21994759fc7a6fa6b965551d35cfd7897d262f2495467f2d78694ddcfa6a5c7e@sprout-oss.stage.blox.sqprod.co>
Collaborator
Author
|
@codex please review |
tlongwell-block
pushed a commit
that referenced
this pull request
Jun 1, 2026
* origin/main: feat(desktop): keyboard shortcuts — ⌘⇧N new channel + ↑-to-edit last message (#809) fix(desktop): scope agent sweep to the owning app instance (#808) Signed-off-by: tlongwell-block <109685178+tlongwell-block@users.noreply.github.com> # Conflicts: # desktop/scripts/check-file-sizes.mjs
wpfleger96
added a commit
that referenced
this pull request
Jun 1, 2026
…s merge Main merged #809 (⌘⇧N shortcut) which added 23 lines to AppSidebar.tsx for the controlled create-channel dialog. Bump override from 810 to 830.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Two keyboard shortcuts for the desktop app:
>=tie-break on timestamp).The notable fix
The ↑-to-edit shortcut appeared broken in the packaged app: it only worked if you clicked out of the composer and back in first. Root cause was a focus bug, not a keymap bug.
On send,
isSendingflips true → the composer is passeddisabled→ the editor'seditablegoes false → the WebView blurs the contenteditable, stranding focus on<body>. When the send settles and the editor becomes editable again, nothing restores focus, so ↑ never reaches the editor's keydown handler.Fix: in the editable-toggle effect, record
editor.isFocusedbefore disabling, and calleditor.commands.focus()on re-enable if it had focus — scoped to that one editor so it can't steal focus from another composer.This reproduces only in the app's WebView; Chromium does not blur on the contenteditable toggle, so our existing "composer keeps focus after send" e2e passes in Chromium with or without this fix. A true regression guard needs a Tauri-webdriver harness that drives the real WebView — tracked as a follow-up rather than bolted on here as a false-safety Chromium test.
Tests / checks
messaging.spec.ts)Notes
useRichTextEditor.ts560,MessageComposer.tsx800→820), each with a rationale comment. The keymap-extraction split ofuseRichTextEditor.tsis the tracked follow-up.useRichTextEditor.ts.