fix(mobile): move the newline button into the quick-key row
The newline button sat in the composer's bottom row beside the attachment button, where it reads as a send-adjacent action. It belongs with esc / tab / arrows — the keys the soft keyboard doesn't have.
| before | after |
|---|---|
bottom row, circular, next to + | quick-key row, chip-shaped, beside esc |
Three details:
- Shaped like the keys it sits with — bordered rounded rectangle at the same size, not the circular treatment used for send and mic.
- Pinned left of the scrolling row, so it stays reachable however far the keys are scrolled.
- Not a quick key. Those write raw bytes into the PTY; this appends to the draft. It's rendered beside them rather than added to
QUICK_KEYS, which would have sent a carriage return to the terminal and submitted instead of inserting a line break.
Surfaces with no key row — the home composer — keep it in the bottom row, since there's nothing else to put it with.
Typecheck and lint pass. Not exercised on a simulator; it's a layout move within an existing SwiftUI stack, but worth a glance on device before merge if you want certainty.
Summary by cubic
Moves the newline button from the composer’s bottom row (next to the attachment button) into the quick-key row beside esc. This clarifies that it inserts a line break rather than a send-adjacent action; surfaces without a key row keep it in the bottom row.
- Renders as a bordered rounded-rectangle chip matching the quick keys, not the circular send/mic style.
- Pinned to the left edge of the horizontally scrolling quick-key row so it stays reachable.
- Not a quick key: appends "\n" to the draft; does not write raw bytes to the PTY or submit.
- Preserves light haptic feedback and the "New line" accessibility label; give the layout a quick on‑device glance for spacing during the animated insertion.
Summary by CodeRabbit
-
New Features
- Added a compact rounded newline control to the composer’s upper action row.
- The control inserts a newline and provides haptic feedback.
-
Improvements
- Prevented duplicate newline controls when upper-row content is present.