Make Enter insert newline on virtual keyboards#10
Merged
Conversation
On touch devices the Enter key now inserts a newline instead of submitting, forcing mobile users to tap the Send/Save button. Physical keyboard users keep the existing behavior (Enter sends, Shift+Enter newlines). Detection uses `pointer: coarse` media query as the default, with pointerdown events on textareas to dynamically override when the user switches input methods (e.g. tablet with Bluetooth keyboard). Also adds `enterkeyhint="send"` to both message and edit textareas so virtual keyboards label the Enter key accordingly. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
cbea9a9 to
dc42dea
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
pointer: coarsemedia query +pointerdownevent override for hybrid devices (e.g. tablet with Bluetooth keyboard)enterkeyhint="send"to message and edit textareas for better virtual keyboard UXTest plan
🤖 Generated with Claude Code