Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Viewport receives keystrokes from textarea #1106

Closed
rchaganti opened this issue Aug 22, 2024 · 2 comments · Fixed by #1108
Closed

Viewport receives keystrokes from textarea #1106

rchaganti opened this issue Aug 22, 2024 · 2 comments · Fixed by #1108

Comments

@rchaganti
Copy link

Describe the bug
When combining viewport and textarea, and when textarea is in focus, typing characters like b and d, scrolls the viewport content.

Setup

  • OS : Windows 11/WSL 2
  • bash

To Reproduce
Run the example: https://github.com/charmbracelet/bubbletea/tree/master/examples/chat

Expected behavior
When textarea is in focus, the keystrokes such as b and d should not be sent to the viewport.

@meowgorithm
Copy link
Member

Good call. We've fixed this and cleaned up the example all around. Thanks for raising this issue!

@rchaganti
Copy link
Author

The changes in the example prevent keys being routed to the viewport. However, it removes the functionality of viewport scrolling. @meowgorithm

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 a pull request may close this issue.

2 participants