mirror of
https://github.com/getcompanion-ai/co-mono.git
synced 2026-04-20 22:02:38 +00:00
feat(tui): improve editor Ctrl/Alt word and line deletion shortcuts
- Add Ctrl+W for word deletion (stops at whitespace/punctuation) - Add Ctrl+U for delete to start of line (merges with previous line at col 0) - Change Ctrl+K from delete entire line to delete to end of line (merges with next line at EOL) - Add Option+Backspace support in Ghostty (maps to Ctrl+W via ESC+DEL sequence) - Cmd+Backspace in Ghostty works as Ctrl+U (terminal sends same control code) - Update README and CHANGELOG with new keyboard shortcuts Fixes #2, Fixes #3
This commit is contained in:
parent
508d1bb2d6
commit
a686f61c1d
6 changed files with 215 additions and 36 deletions
|
|
@ -2,6 +2,15 @@
|
|||
|
||||
## [Unreleased]
|
||||
|
||||
### Changed
|
||||
|
||||
- Editor: updated keyboard shortcuts to follow Unix conventions:
|
||||
- **Ctrl+W** deletes the previous word (stopping at whitespace or punctuation)
|
||||
- **Ctrl+U** deletes from cursor to start of line (at line start, merges with previous line)
|
||||
- **Ctrl+K** deletes from cursor to end of line (at line end, merges with next line)
|
||||
- **Option+Backspace** in Ghostty now behaves like **Ctrl+W** (delete word backwards)
|
||||
- **Cmd+Backspace** in Ghostty now behaves like **Ctrl+U** (delete to start of line)
|
||||
|
||||
## [0.7.8] - 2025-11-13
|
||||
|
||||
### Changed
|
||||
|
|
|
|||
|
|
@ -131,7 +131,11 @@ Paste multiple lines of text (e.g., code snippets, logs) and they'll be automati
|
|||
|
||||
### Keyboard Shortcuts
|
||||
|
||||
- **Ctrl+K**: Delete current line
|
||||
- **Ctrl+W**: Delete word backwards (stops at whitespace or punctuation)
|
||||
- **Option+Backspace** (Ghostty): Delete word backwards (same as Ctrl+W)
|
||||
- **Ctrl+U**: Delete to start of line (at line start: merge with previous line)
|
||||
- **Cmd+Backspace** (Ghostty): Delete to start of line (same as Ctrl+U)
|
||||
- **Ctrl+K**: Delete to end of line (at line end: merge with next line)
|
||||
- **Ctrl+C**: Clear editor (first press) / Exit pi (second press)
|
||||
- **Tab**: Path completion
|
||||
- **Enter**: Send message
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue