Skip to content

feat(composer): Enter is a new line on a phone - #672

Merged
viktormarinho merged 1 commit into
mainfrom
viktor/mobile-enter-newline
Nov 30, 2026
Merged

viktormarinho merged 1 commit into
mainfrom
viktor/mobile-enter-newline

Conversation

@viktormarinho

@viktormarinho viktormarinho commented Nov 30, 2026 •

Copy link
Copy Markdown
Collaborator

What

On a phone (a touch-only screen: coarse pointer and no fine pointer), Enter in the composer makes a new line and the send button sends. On a computer, a touch laptop or a tablet with a trackpad, Enter still sends and Shift+Enter is a new line.

Why

A phone keyboard has no Shift+Enter, so there was no way to write a message with more than one line. Follow-up asked in the room (#7079), approved (#7080).

Checks run

  • bun test scripts/composer.test.ts -t "Gimenes #7079" (new test): pass
  • bun run check:ui, test:ui, check:guidelines, format:check: pass
  • bun run screens -- --enter (new flag): pass. At 390 px Enter makes a new line and the send button sends; at 1440 px Enter sends.

Router bench

not touched

Deliberate decisions

  • docs/agents_deliberate_decisions.md: "2026-11-30 · viktor/mobile-enter-newline · Enter is a new line on a phone"

Screens

enter-newline-390.png
enter-sent-390.png
enter-sent-1440.png
room-390.png
room-1440.png


Summary by cubic

Makes Enter in the composer insert a new line on touch-only screens (phones), whose keyboards have no Shift+Enter, so multi-line messages were previously impossible. On computers, touch laptops, and tablets with a trackpad, Enter still sends the message and Shift+Enter stays the new line.

  • A "phone" is a screen with a coarse pointer and no fine pointer, so a narrow desktop window or an iPad with a keyboard keeps Enter to send.
  • Adds a --enter flag to the screen-capture script and a unit test covering both pointer profiles.

Written for commit f4e2a8a. Summary will update on new commits.

View guided diff Turn on auto-fix

On a touch-only screen (coarse pointer, no fine pointer) Enter in the
composer makes a new line and the send button sends. A computer, a touch
laptop or a tablet with a trackpad keeps Enter to send.
@viktormarinho
viktormarinho enabled auto-merge (squash) November 30, 2026 14:37
@viktormarinho
viktormarinho merged commit 1468f05 into main Nov 30, 2026
6 checks passed
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