Skip to content

fix(tui): slash hijack, fork feedback, help geometry - #665

Merged
mohitranka merged 1 commit into
mainfrom
fix/major-pty-audit-issues
Sep 13, 2026
Merged

mohitranka merged 1 commit into
mainfrom
fix/major-pty-audit-issues

Conversation

@mohitranka

Copy link
Copy Markdown
Contributor

Fixes 4 MAJOR issues from PTY visual audit (artifacts/forge-visual-pty-test/report.md).

  • Typed exact slash commands beat fuzzy skill description matches: /refresh no longer fires skill:market-scan (was ~67k token burn). Unknown prefixes still complete to suggestions.
  • Palette now lists /refresh, /edit, /context-file, /approve-all (all parsed before, undiscoverable).
  • TaskStrip/Sidebar keystrokes no longer leak into chat via type-to-compose (was accidental model runs from :q/:e//quit).
  • Supervised /fork reports 'forking session…' feedback + toast (was zero feedback, hidden sessions).
  • Help modal uses cell-capped geometry (76x46, 2-cell margin) instead of 64%/58% percentages; readable at 80x24.

Tests: 4 new regression tests; forge-tui lib 1274 passed; fmt + clippy clean. Live PTY verified: /refresh ranks first and refreshes, /help framed at 80x24, /fork toasts.

Typed exact slash commands now beat fuzzy skill description matches
(/refresh no longer fires skill:market-scan). TaskStrip/Sidebar keys
no longer leak into chat. Supervised /fork reports progress. Help
modal uses cell-capped geometry readable at 80x24.
@mohitranka
mohitranka merged commit 212deec into main Sep 13, 2026
3 checks passed
mohitranka added a commit that referenced this pull request Sep 15, 2026
…693)

`type_to_compose` refused Footer, TaskStrip and Sidebar as control
surfaces, so a printable key with no local binding there was dropped: a
click on the transcript column (SIDEBAR) left the keystroke with nowhere
to go, and the composer stayed the only way in.

Only `Panel` keeps an unconsumed printable key now — its PTY owns every
byte the panel does not claim. Everywhere else the block's own bindings
are matched first, so a displayed shortcut never loses to a draft
(`n`/`s`/`d` in the session list, `x`/`a`/`d`/`i` in the transcript, the
footer chips), and focus moves with the character, so a draft is never
inserted behind a pane still painted as the keyboard owner.

This reverses two deliberate guards: 56deb92 kept the footer's keys so a
shell line typed after one Tab could not become a draft, and 212deec
(#665) kept `:q`/`/quit` out of chat from the session list and the
transcript. Both inputs are reachable again; they surface the text in the
composer instead of swallowing it.

Docs: the README keyboard table and FORGE-DESIGN 8.3 carry the rule and
its exception. The tests pinned to the old drop behavior are rewritten,
with new coverage for the terminal carve-out and for bound keys beating
type-to-chat. Paste is unchanged: bracketed paste still only reaches the
composer from the composer block.
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