Keyboard shortcuts
Wired up in one place — useEditorKeyboardShortcuts(containerRef) — at the container level, so every block gets the same behavior for free.
Formatting
| Shortcut | Action |
|---|---|
| Ctrl/Cmd+B | Toggle bold on the current selection |
| Ctrl/Cmd+I | Toggle italic |
| Ctrl/Cmd+U | Toggle underline |
Mark toggling resolves a same-block selection first (one or more runs within one block), falling back to a cross-block resolver for a selection spanning sibling blocks. A selection spanning non-sibling blocks (different nesting depths) isn't supported.
History
| Shortcut | Action |
|---|---|
| Ctrl/Cmd+Z | Undo |
| Ctrl/Cmd+Shift+Z or Ctrl/Cmd+Y | Redo |
Undo/redo are no-ops if your store is a plain EditorStore rather than wrapped in History.
Selection
Ctrl/Cmd+A is two-stage, matching Notion/Google Docs: the first press uses the browser's native select-all within the focused block (no code needed). Pressing it again while the whole current block is already selected promotes to a custom "whole document selected" state — browsers don't reliably support a script-constructed selection spanning multiple independent contentEditable regions, which is exactly why this editor uses one region per block in the first place.
While the whole document is selected this way: Backspace/Delete clears it (falling back to one blank paragraph), typing a printable character replaces it with that character, Escape or any other key cancels the mode, and Ctrl/Cmd+C/Ctrl/Cmd+X copy/cut it via the same clipboard handlers as an ordinary selection.
Structure & navigation
| Shortcut | Action |
|---|---|
| Enter | Split the current block at the caret (behavior varies by block type — see each block's own doc page) |
| Backspace at start of block | Merge into the previous block, or delete it if empty |
| Tab / Shift+Tab | Indent / un-indent a list item or toggle heading |
| ↑ / ↓ | Move focus to the adjacent block |
| Backspace/Delete on a selected contentless block | A divider/embed/etc. selects on the first press, deletes on the second — same two-stage convention as Notion |
Trigger menus
| Key | Opens |
|---|---|
| / | Block menu (insert any block, or a select/date/checkbox inline widget) |
| @ | Mention/field menu — only for inline types that opted in with triggers: ['at'] |
| : | Emoji picker |
Inside any of these menus: ↑/↓ to move, Enter to select, Escape to close.