fix(mobile): route terminal taps without opening the keyboard - #186
Draft
Lint111 wants to merge 4 commits into
Draft
fix(mobile): route terminal taps without opening the keyboard#186Lint111 wants to merge 4 commits into
Lint111 wants to merge 4 commits into
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Summary
Make terminal touches behave predictably on mobile without opening the software keyboard for TUI-owned content.
This PR is the focused tap/gesture slice extracted from the larger mobile-experience branch. It is intentionally limited to
terminal-ui.jsand its unit/browser regressions.Behavior
Working/ background-agent status rows as TUI content.Audit Fixes
The original classifier relied too heavily on visible prompt glyphs. During promptless Claude redraws, a live row could be classified as content,
touchstartwould suppress browser focus, and the mobile keyboard became unreachable.The final commit gives precedence to known menus and working rows, then treats the live cursor and a four-row lower-screen fallback band as input. The browser regression verifies both required outcomes:
document.activeElementThe split also removes a hidden dependency on the separate history-anchor feature by using the existing local-scroll operations directly.
Commit Structure
fix(mobile): keep keyboard focus taps non-activatingfix(mobile): route terminal content taps to the CLIfix(mobile): route Claude terminal gesturesfix(mobile): keep promptless terminal input focusableVerification
npx vitest run --config config/vitest.config.ts test/terminal-touch-tap.test.tsnpx vitest run --config test/mobile/vitest.config.ts test/mobile/keyboard.test.ts -t "focuses the live Claude cursor|prevents Claude subagent status taps|focuses the terminal helper textarea when the visible prompt is tapped"npm run check:frontend-syntaxnpm run check:public-assetsnpx prettier --check test/mobile/keyboard.test.ts test/terminal-touch-tap.test.tsnpm run buildNon-Goals