feat: Allow pasting newlines (#866)

Noticed that when pasting multi-line blocks, each newline was treated
like a new submission.
Update tui to handle Paste directly and map newlines to shift+enter.

# Test

Copied this into clipboard:
```
Do nothing.
Explain this repo to me.
```

Pasted in and saw multi-line input. Hitting Enter then submitted the
full block.
This commit is contained in:
jcoens-openai
2025-05-09 11:33:46 -07:00
committed by GitHub
parent 93817643ee
commit 78843c3940
3 changed files with 37 additions and 10 deletions

View File

@@ -21,7 +21,7 @@ codex-ansi-escape = { path = "../ansi-escape" }
codex-core = { path = "../core" }
codex-common = { path = "../common", features = ["cli", "elapsed"] }
color-eyre = "0.6.3"
crossterm = "0.28.1"
crossterm = { version = "0.28.1", features = ["bracketed-paste"] }
mcp-types = { path = "../mcp-types" }
ratatui = { version = "0.29.0", features = [
"unstable-widget-ref",