Skip to content

feat(tui): type into custom form answers - #41079

Closed
kitlangton wants to merge 2 commits into
v2from
typing-custom
Closed

kitlangton wants to merge 2 commits into
v2from
typing-custom

Conversation

@kitlangton

@kitlangton kitlangton commented Aug 7, 2026 •

Copy link
Copy Markdown
Contributor

What

Typing while Type your own answer is highlighted now opens the custom-answer editor and preserves the complete typed input. This removes the extra Enter press before entering a custom form answer.

Closes #34476.

How

  • packages/tui/src/routes/session/form.tsx intercepts unmodified printable input while the custom row is active, then buffers characters until the textarea is focused.
  • packages/tui/src/mini/footer.form.tsx applies the same behavior to the direct-run form footer.
  • Navigation and shortcuts keep their existing behavior unless the custom row is highlighted.
  • Focus handoff preserves burst input, including digits and navigation-letter characters typed as answer text.

Scope

This PR covers printable typing only. Pasting from any selected option into the custom answer is handled separately in #41080.

Testing

  • bun run test test/cli/tui/form.test.tsx test/mini/footer.view.test.tsx from packages/tui: 44 passed, 4 skipped
  • bun typecheck from packages/tui
  • Pre-push bun turbo typecheck --concurrency=3: 32 tasks passed
  • OpenCode Drive end-to-end recording against this worktree

Demo

The recording uses an isolated OpenCode Drive TUI with a simulated question response. It highlights Type your own answer, then types a complete custom value without pressing Enter first.

recording-d0a54941-1462-4f45-8177-29dba8116086.mp4

@github-actions

github-actions Bot commented Sep 7, 2026

Copy link
Copy Markdown
Contributor

Automated PR Cleanup

Thank you for contributing to opencode.

Due to the high volume of PRs from users and AI agents, we periodically close older PRs using automated criteria so maintainers can focus review time on the most active and community-supported contributions.

This PR was closed because it matched the following cleanup criteria:

  • The PR was created more than 1 month ago
  • The PR had fewer than 2 positive reactions
  • Positive reactions are counted as thumbs-up, heart, celebration, or rocket reactions on the PR

PRs created within the last month are not affected by this cleanup.

If you believe this PR was closed incorrectly, or if you are still actively working on it, please leave a comment explaining why it should be reopened. A maintainer can review and reopen it if appropriate.

Thanks again for taking the time to contribute.

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant