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

Handle key press of the input #15

Merged
merged 1 commit into from
Jul 6, 2024

Conversation

josejulio
Copy link
Collaborator

@josejulio josejulio commented Jul 5, 2024

We were missing this functionality in the extension, basically being able to press Enter key to send a message.
I was thinking whether we should pass the keypress handler and do it from our virtual assistant or in the extension.
Since this is a similar functionality as other chat clients, it makes sense to have it here directly.

I didn't add any way to override, but if we feel that this is a need in the future we could accept the keypress handler.

  • Allow to send the messages when pressing enter key
  • Behaves like it does on chat clients, pressing shift + enter will jump to the next line instead of sending the message
  • Adding tests

  - Allow to send the messages when pressing enter key
  - Behaves like it does on chat clients, pressing shift + enter
  will jump to the next line instead of sending the message

  - Adding tests
@josejulio josejulio requested a review from fhlavac July 5, 2024 17:07
@patternfly-build
Copy link

patternfly-build commented Jul 5, 2024

@fhlavac fhlavac merged commit 8c03ad8 into patternfly:main Jul 6, 2024
7 checks passed
Copy link

github-actions bot commented Jul 8, 2024

🎉 This PR is included in version 1.0.0-prerelease.2 🎉

The release is available on:

Your semantic-release bot 📦🚀

Copy link

github-actions bot commented Aug 2, 2024

🎉 This PR is included in version 2.0.0-alpha.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

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.

3 participants