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 — desktop: tablet composer on touch-primary 2-in-1 - Enter inserts newline instead of sending · Issue #64729 · anomalyco/opencode

desktop: tablet composer on touch-primary 2-in-1 - Enter inserts newline instead of sending #64729

New issue
Copy link
New issue
Copy link
Closed as duplicate
Closed as duplicate
desktop: tablet composer on touch-primary 2-in-1 - Enter inserts newline instead of sending#64729
Copy link
Labels
area/desktopDesktop appplatform/windowsWindowstype/bugSomething is brokenversion/v2OpenCode 2.x

Description

@nitesh28688
nitesh28688
opened on Nov 18, 2026
Issue body actions

Summary

On Windows touch-capable 2-in-1 devices without a fine pointing device (keyboard-only input, touchscreen present), the V2 desktop app composes in the touch layout: plain Enter inserts a newline instead of submitting, and there is no way to force the desktop composer back. Submission falls to Ctrl/Cmd+Enter or the touch bar's Send button.

Environment

  • opencode version: 2.3.2 (desktop, latest channel; released 2026-11-18; bundled opencode-cli v2.3.2)
  • OS: Microsoft Windows [Version 10.0.26300.9974] (win32 x64)
  • Terminal: Unavailable: terminal environment variables not set
  • Shell: C:\WINDOWS\system32\cmd.exe
  • Install/channel: desktop app, latest
  • Active plugins: none configured (config has model/provider/MCP entries; no plugins)

Reproduction

  1. On a Windows touch-capable 2-in-1 with a detachable keyboard (Surface-class), use it with a wireless keyboard and no mouse/trackpad attached (touch screen and pen present; Windows tablet mode = 0).
  2. Open the desktop app, focus the composer, and type a message.
  3. Press Enter — a line break is inserted; the message is not submitted.
  4. Note the touch composer layout (touch bar with a Send button at the bottom). Enter always inserts a line break; Ctrl/Cmd+Enter submits using the "Subsequent message behavior" setting (Queue = waits for the running turn; Steer = injects); Alt+Enter behaves like Ctrl+Enter on this layout.

Expected Behavior

On a machine with a physical keyboard and no active touch interaction, the desktop composer should behave as it does on a desktop: Enter submits (subject to the configured follow-up behavior), Shift+Enter inserts a newline.

Actual Behavior

The app switches the composer to the touch layout via a (hover: none) and (pointer: coarse) media query. Verified in the shipped bundle (app.asar, v2.3.2): the composer keydown handler early-returns for plain Enter when a createMediaQuery("(hover: none) and (pointer: coarse)") matcher is true, and the beforeinput insertParagraph handler turns it into a line break. Ctrl/Cmd+Enter and Alt+Enter both call submit(undefined) (normal delivery = the configured "Subsequent message behavior"), so on this layout neither triggers the alternate (Steer) delivery. There is no settings or experiments toggle to force the desktop composer.

Additional Context

  • A wireless keyboard is not a pointing device, so with no mouse/trackpad present the touchscreen is the only pointer and both hover and pointer coarse-match.
  • Related: [FEATURE]: Make App prompt action shortcuts configurable #43088 (configurable prompt submit/newline shortcuts). This report is adjacent but distinct — even ignoring rebinding, a keyboard-driven 2-in-1 in laptop posture should not land in the tablet composer.
  • Workaround: attach/enable a fine pointing device (a mouse, or the detachable keyboard's trackpad); behavior may flip live or after an app restart. Otherwise use the touch bar's Send button or Ctrl/Cmd+Enter.
  • Consistent, every launch.

Activity

  1. opencodejr commented on Nov 18, 2026

    @opencodejr
    opencodejrBot
    on Nov 18, 2026
    Contributor
    More actions

    Thanks for the detailed report and for tracing it to the media query, @nitesh28688! I think this is a duplicate of #62647.

    Possible duplicates and related issues, ordered by likelihood:

    • Feedback on the desktop versions ui (windows) #62647: the same problem. The Windows desktop app shows the touch composer, Enter adds a new line, only Ctrl+Enter sends, and there is no way to switch back. desktop: Enter does not submit prompt; Ctrl+Enter required, keybind overrides ignored #64201 (on 2.3.0) was already closed as a duplicate of it.
    • [FEATURE]: Make App prompt action shortcuts configurable #43088: a request to make the desktop app's submit and newline shortcuts configurable. PR feat(app): make prompt action keybinds configurable #55313 is working on it.
    • feat(app): add a touch dock to the mobile composer #61773: the change that added the touch dock to the composer.
    • web: on mobile, Enter submits the prompt and no newline can be inserted #55549 and app: iOS Return key still submits the prompt instead of inserting a newline #63696: the opposite problem, Return/Enter on mobile.

    What I found in the code matches what you saw in the bundle. The composer turns on its touch mode from (hover: none) and (pointer: coarse), and the comment there says it is meant for phones and tablets. In that mode, a plain Enter without Ctrl or Cmd doesn't send the message.

    Your case is a good addition to #62647. A 2-in-1 with a touchscreen and pen, a keyboard and no mouse or trackpad really does match that query, unlike the remote-desktop machine reported there.

    I'm closing this issue now as a duplicate of #62647. Please add your details there: the device, the keyboard-only setup, the 2.3.2 version, and the mouse/trackpad workaround. If you think this is a different problem, reply here and the issue will reopen.

  2. opencodejr
    closed this as a duplicateof Feedback on the desktop versions ui (windows) #62647 on Nov 18, 2026
  3. opencodejr
    added
    area/desktopDesktop app
    platform/windowsWindows
    type/bugSomething is broken
    version/v2OpenCode 2.x
    on Nov 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area/desktopDesktop appplatform/windowsWindowstype/bugSomething is brokenversion/v2OpenCode 2.x

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      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.