Skip to content

fix(console): improve interactive text input handling#2239

Open
xHeaven wants to merge 7 commits into
tempestphp:3.xfrom
xHeaven:console
Open

fix(console): improve interactive text input handling#2239
xHeaven wants to merge 7 commits into
tempestphp:3.xfrom
xHeaven:console

Conversation

@xHeaven

@xHeaven xHeaven commented Jul 25, 2026

Copy link
Copy Markdown
Member

This PR fixes a couple of bugs that were bugging me (ba dum ts):

  • Previously, if you had multiline help text, the cursor was drawn in the wrong place.
  • Previously, if you pressed multiple keys in very quick succession, only one of them would show up in the input... but the rest would reappear once you started deleting backwards.
  • Previously, Cmd+Backspace basically behaved like the Spacebar. Now it has a real purpose: deleting the whole line. Additionally, Option+Backspace is now wired up to the deletePreviousWord method.
  • Previously, multibyte characters and emojis would trip up the input entirely. Typing would (maybe) work, but deleting backwards was a s��tfest.
  • Previously, while you were typing into the input box, the cursor would cause a seizure to the viewer by flashing all over the place at the bottom of the rendered content.

@xHeaven
xHeaven requested a review from brendt as a code owner July 25, 2026 09:34
@github-actions

github-actions Bot commented Jul 25, 2026

Copy link
Copy Markdown

Benchmark Results

Comparison of console against 3.x (1f0085cda591d0c3e9b89d67b1b33849979c8ef1).

Open to see the benchmark results

No benchmark changes above ±5%.

Generated by phpbench against commit 6c1ae76

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant