Skip to content

fix: open the composer's /, @ and $ menus on the phone - #582

Merged
Tryanks merged 1 commit into
mainfrom
fix/phone-composer-trigger-menu
Oct 3, 2026
Merged

Tryanks merged 1 commit into
mainfrom
fix/phone-composer-trigger-menu

Conversation

@Tryanks

@Tryanks Tryanks commented Oct 3, 2026 •

Copy link
Copy Markdown
Owner

Summary

Typing /, @ or $ in the composer on a phone now opens the same trigger menu as on the desktop, and /later schedules the turn instead of being sent to the agent as literal text.

Two guards from the first mobile client (#329) were responsible. Both are removed and nothing is added.

 Composer::recompute_trigger
-  if self.compact { clear active_trigger; return }
   compute trigger from the text before the cursor

 Composer::submit
-  if parse_later(text) && !self.compact
+  if parse_later(text)
     schedule the turn

compact is is_mobile && compact_for(width), so desktop builds were never affected. The menus' data was already protocol-backed (provider commands, Query::ListActiveWorkspace, Command::ScheduleTurn), so a remote phone needs nothing else.

Evidence

  • Before: on the phone, typing / showed nothing and /later … went to the agent as text.
    After: cargo run -p tcode-ui --example phone against a throwaway headless host: / lists the built-in commands, /plan switches mode, @ lists and inserts remote files.
  • Test: the_phone_composer_opens_the_same_trigger_menus builds the composer as the phone does at 393×852, types / and @ through the window input handler, draws, and asserts the first menu row is laid out. It fails with the guard restored. No test owned this contract before.
cargo fmt / clippy --workspace -D warnings     ✓
cargo nextest run -p tcode-ui --locked          288 passed

Merge Danger

Door: two-way

Two lines of guard removed; trivially revertible.

Blast Radius: phone-composer

Not exercised on a real device: iOS and Android soft keyboards (including CJK IME composition of /), menu placement with the keyboard up, touch taps on menu rows, and provider-native commands or $ skills on the phone. On mobile Return inserts a newline, so a row is accepted by tap.

The compact layout cleared the active trigger on every input change, so
typing / @ or $ on a phone never opened a menu, and /later was sent to the
agent as text instead of being scheduled. Both guards came with the first
mobile client; every data path behind the menus is protocol-backed, so the
phone uses the same trigger owner as the desktop.
@Tryanks
Tryanks merged commit 59785bc into main Oct 3, 2026
7 checks passed
@Tryanks
Tryanks deleted the fix/phone-composer-trigger-menu branch October 3, 2026 05:29
@Tryanks Tryanks changed the title fix: show the composer trigger menus on the phone fix: open the composer's /, @ and $ menus on the phone Oct 6, 2026
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