GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — feat(app): add a touch dock to the mobile composer by Hona · Pull Request #61773 · anomalyco/opencode

Conversation

@Hona

@Hona Hona commented Nov 4, 2026 •
edited by opencodejr Bot
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member

On phones and tablets the composer's send button was a 28px target, and the keyboard's Return either sent or added a line depending on iOS autocapitalization. This moves every composer action into a touch dock pinned to the bottom of the screen, which is the top of the keyboard while it is open. Return now only ever adds a line.

Before After

Every state on an iPhone-sized WebKit viewport:

What changes

  • Touch only: the composer switches on (hover: none) and (pointer: coarse), so phones and tablets get the dock at any width. A narrow desktop window with a mouse keeps the desktop toolbar and Enter to send.
  • The dock: + attach, / commands, @ context, ! shell, then the primary action. Every target is at least 44px, and taps keep the editor focused so the keyboard stays up.
  • Primary action by state: Send, Steer or Queue (by follow-up preference), Queue while editing a queued prompt, or Stop on an empty draft of a running session. The alternate delivery sits beside it, as on desktop's Mod+Enter.
  • Placement: the shell has a composer-touch-bar-mount slot below main, and the composer portals the dock into it. The dock pads itself for the home indicator, so main drops its safe-area padding while it is docked. Without a slot (stories), the dock renders under the composer.
  • Return: a touch keyboard's Return only adds a line, even over suggestions. Cmd+Return on a hardware keyboard (iPad) still sends the primary action.
  • Line breaks survive: a touch Return arrives as insertParagraph, which wrapped the next line in a <div> that the parser joined without a newline. beforeinput now converts it to the insertLineBreak that Shift+Enter produces, so the editor stays one flat run of text, mentions and <br>s.
  • IME on Safari: Safari delivers the Enter that confirms an IME candidate after compositionend, so isComposing is false. Its keyCode 229 now keeps that Enter from sending on any device.
flowchart LR
  K[keydown Enter] --> T{touch?}
  T -- "no" --> D[desktop: send, Mod+Enter alternate]
  T -- "yes, Cmd/Ctrl held" --> P[primary action]
  T -- "yes, plain" --> B[beforeinput insertParagraph]
  B --> L[execCommand insertLineBreak]
  Dock[dock button] --> P
Loading
onBeforeInput={(event) => {
  if (event.inputType !== "insertParagraph") return
  event.preventDefault()
  document.execCommand("insertLineBreak")
}}

Notes

  • Safari's own form bar (⌃ ⌄ ✓) still shows between the dock and the keyboard. A web page cannot remove it; only a native iOS wrapper can.
  • composer-touch.stories.tsx mounts the real composer in every state behind a native picker, for checking on a device.

Visual

<svg xmlns="http://www.w3.org/2000/svg" width="240" height="72" viewBox="0 0 240 72" fill="none">
  <style>
    .dock { animation: rise 3s ease-in-out infinite; }
    @keyframes rise { 0%, 15% { transform: translateY(26px); opacity: 0 } 35%, 85% { transform: none; opacity: 1 } 100% { transform: translateY(26px); opacity: 0 } }
    @media (prefers-reduced-motion: reduce) { .dock { animation: none } }
  </style>
  <rect x="16" y="6" width="208" height="30" rx="8" stroke="currentColor" stroke-opacity=".35"/>
  <rect x="26" y="15" width="96" height="4" rx="2" fill="currentColor" fill-opacity=".5"/>
  <rect x="26" y="24" width="44" height="4" rx="2" fill="currentColor" fill-opacity=".25"/>
  <g class="dock">
    <line x1="0" y1="44.5" x2="240" y2="44.5" stroke="currentColor" stroke-opacity=".25"/>
    <text x="16" y="62" font-family="ui-monospace,monospace" font-size="11" fill="currentColor" fill-opacity=".5">+  /  @  !</text>
    <rect x="128" y="50" width="44" height="18" rx="6" stroke="currentColor" stroke-opacity=".4"/>
    <text x="135" y="63" font-family="system-ui,sans-serif" font-size="10" fill="currentColor" fill-opacity=".8">Queue</text>
    <rect x="178" y="50" width="48" height="18" rx="6" fill="currentColor" fill-opacity=".85"/>
    <text x="185" y="63" font-family="system-ui,sans-serif" font-size="10" fill="currentColor" fill-opacity="1" style="mix-blend-mode:difference">Steer ↑</text>
  </g>
</svg>

Added by the opencode bot (AI-generated).

Fixes #55549

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

simosentissi reacted with hooray emoji
All reactions
  • 🎉 1 reaction
@Hona
feat(app): add a touch dock to the mobile composer
06ddead
@Hona
Hona requested a review from Brendonovich as a code owner November 4, 2026 19:59
Copilot AI balanced review requested due to automatic review settings November 4, 2026 19:59
Copilot AI reviewed Nov 4, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota. Try requesting a review at a lower effort level.

An organization owner can choose the repository organization as the billing source for reviews requested by members with a paid Copilot license. Learn about Copilot code review billing.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
opencodejr[bot]
opencodejr Bot reviewed Nov 4, 2026
View reviewed changes

@opencodejr opencodejr Bot left a comment

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I found no blocking problems. I ran it in an emulated touch phone (390×844, hasTouch, isMobile). On the base branch, Return sends the first line. With this PR, Return adds a line and the dock's Send button sends the prompt with both lines. The new composer and session-queue touch tests, the IME test and mobile-composer-submit-focus.spec.ts pass. bun run typecheck doesn't run here (bun check isn't available on this bun version), but typecheck:tsc passes for packages/app.

Public API: unchanged. This only changes the app UI.

One concern, in an inline comment: where the dock goes when the mobile titlebar is set to the bottom.

Fixes #55549

Before

After

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread packages/app/src/shell/shell.tsx Outdated
<CollapsedSidebarToggle />
</div>
{/* On touch devices the active composer moves its actions here: the bottom edge, or the top of the keyboard. */}
<div data-slot="composer-touch-bar-mount" class="shrink-0" />

@opencodejr opencodejr Bot Nov 4, 2026

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

With mobileTitlebarPosition: "bottom", the titlebar is order-last, so this slot renders above it. The dock ends up between the session panel and the titlebar, and the titlebar sits between the dock and the keyboard. Both also pad for the home indicator, so with the keyboard closed the inset is added twice. I confirmed the placement with that setting on a 390px touch viewport. Could the dock either go below the titlebar or skip its own safe-area padding when the titlebar is at the bottom?

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@Hona Hona Nov 4, 2026

Copy link
Copy Markdown
Member Author

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed in f3fbf4e. The slot is now order-last after the titlebar, so the dock stays on the bottom edge (the top of the keyboard) below a bottom titlebar. While docked, the dock pads for the home indicator and sets --shell-safe-area-bottom: 0px, which main and the bottom titlebar now read, so the inset is no longer added twice. mobile-composer-submit-focus.spec.ts asserts the placement with the bottom titlebar and fails on the previous order.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

opencodejr[bot] reacted with eyes emoji
All reactions
  • 👀 1 reaction

@opencodejr opencodejr Bot Nov 4, 2026

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

f3fbf4e fixes the issue I raised.

  • Placement: composer-touch-bar-mount is order-last now. The bottom titlebar is also order-last, but it comes earlier in the DOM, so the dock ends up on the bottom edge, below the titlebar.
  • Inset: main's padding-bottom, the bottom titlebar's padding-bottom and its inner pb-[max(0px, 8px - inset)] all read --shell-safe-area-bottom now. When the dock is docked it sets that variable to 0px, so the titlebar drops to 28px of content plus 8px padding, and only the dock pads for the home indicator.

What I ran: mobile-composer-submit-focus.spec.ts on chromium at pr/head, in a throwaway worktree. All 4 tests passed. The first cold run failed once on the 390px LTR desktop-pointer case, then passed on the rerun, so it looks like dev-server warmup. With order-last removed from the slot, the touch test fails as you said: the dock's y is 750, expected ≥ 843. Headless Chromium reports a safe-area inset of 0, so the inset was checked only by reading the code, not on a device.

A remaining gap with the top titlebar (also present in 06ddead): --shell-bottom-inset in shell.tsx:221-223 still reads the raw safe area, as max(0px, 8px - inset). On a notched iPhone with the dock docked, main's padding is now 0 and that value also comes out to 0. The session panel's bottom border then sits directly against the dock with no gap. Making it read --shell-safe-area-bottom restores the 8px:

-          : "max(0px, calc(8px - var(--safe-area-inset-bottom, env(safe-area-inset-bottom, 0px))))",
+          : "max(0px, calc(8px - var(--shell-safe-area-bottom, var(--safe-area-inset-bottom, env(safe-area-inset-bottom, 0px)))))",

I didn't change anything in repo/, and I removed the temporary worktree.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@Hona
fix(app): dock the touch bar below a bottom titlebar
f3fbf4e
opencodejr[bot]
opencodejr Bot reviewed Nov 4, 2026
View reviewed changes

@opencodejr opencodejr Bot left a comment

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The earlier point about the bottom titlebar is fixed. The dock's mount is now order-last, below a bottom titlebar, and the titlebar stops padding for the home indicator while the dock is mounted. I checked this on a 390px touch viewport with the titlebar at the bottom: the dock now sits below the titlebar. mobile-composer-submit-focus.spec.ts (with its new placement check) and the touch and IME tests in the composer and session-queue specs pass. typecheck:tsc passes for packages/app.

Public API: unchanged. I found nothing new worth raising.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@Hona
Hona merged commit bbf71d6 into dev Nov 4, 2026
20 checks passed

Uh oh!

There was an error while loading. Please reload this page.

@Hona
Hona deleted the mobile-touch-dock branch November 4, 2026 20:37
@Hona Hona mentioned this pull request Nov 5, 2026
feat(plugin): add a slot below the new session composer #62155
Open
@amrkmn amrkmn mentioned this pull request Nov 7, 2026
opencode 2.2.6 amrkmn/homebrew-tap#1217
Closed
1 task
This was referenced Nov 7, 2026
feat: opencode release v2.2.6 sprisa/opencode-server#84
Merged
Tool release: OpenCode 2 v2.2.6 (was v2.2.5) agent-sh/agnix#1808
Closed
@wmfeht wmfeht mentioned this pull request Nov 7, 2026
Keep fields flat on OpenCode Desktop 2.2.6 wmfeht/omarchy-opencode-theme#3
Merged
@opencodejr opencodejr Bot mentioned this pull request Nov 7, 2026
Feedback on the desktop versions ui (windows) #62647
Open
@nasrun-ai nasrun-ai mentioned this pull request Nov 13, 2026
app: iOS Return key still submits the prompt instead of inserting a newline #63696
Closed
@aaronchan0

aaronchan0 commented Nov 15, 2026

Copy link
Copy Markdown

After updating to v2.3.0, I can no longer send messages using my phone’s on-screen Enter/Return key in the web UI. I now have to tap the webpage’s Send button, which interrupts my usual typing flow.

I understand the motivation to fix inconsistent iOS Return behavior, but could you add an “Enter to send” preference so users can restore the previous behavior? Enter-to-send was working well for me before this update.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

This was referenced Nov 16, 2026
desktop: Enter does not submit prompt; Ctrl+Enter required, keybind overrides ignored #64201
Closed
Web Mobile UI (v2.3.2): new bottom bar consumes ~8.5% of the viewport but adds no new capability #64712
Open
desktop: tablet composer on touch-primary 2-in-1 - Enter inserts newline instead of sending #64729
Closed
desktop: Enter inserts a newline instead of sending on touch devices (coarse pointer) #64828
Closed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

Copilot code review Copilot
Copilot review effort
Applies to this pull request for everyone.Learn more about Copilot code review.
Copilot left review comments
@opencodejr opencodejr[bot] opencodejr[bot] left review comments
@Brendonovich Brendonovich Awaiting requested review from Brendonovich

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

web: on mobile, Enter submits the prompt and no newline can be inserted

Uh oh!

There was an error while loading. Please reload this page.

3 participants

@Hona @aaronchan0
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.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.