Skip to content

Keep Android new task composer above keyboard#4388

Open
colonelpanic8 wants to merge 1 commit into
pingdotgg:mainfrom
colonelpanic8:fix/android-composer-keyboard-positioning
Open

Keep Android new task composer above keyboard#4388
colonelpanic8 wants to merge 1 commit into
pingdotgg:mainfrom
colonelpanic8:fix/android-composer-keyboard-positioning

Conversation

@colonelpanic8

@colonelpanic8 colonelpanic8 commented Jul 23, 2026

Copy link
Copy Markdown

What Changed

  • Replace the Android new-task screen’s padding-based keyboard avoidance with a bottom-anchored KeyboardStickyView.
  • Keep the draft composer attached to the IME while its focused editor expands upward.
  • Preserve the existing iOS keyboard-avoidance behavior.

Why

The Android new-task composer changes height as focus expands the collapsed prompt pill into a multiline editor with toolbar controls. The padding-based keyboard relayout could race that height change, leaving part of the editor and toolbar underneath Gboard.

Anchoring the Android composer directly to the keyboard makes the expansion grow upward and keeps the complete composer accessible while typing.

UI Changes

Before: With Gboard open and a multiline prompt, the lower portion of the composer can remain hidden behind the keyboard.

After: The expanded editor and its model/configuration/action row remain fully above Gboard, including at the editor’s maximum height.

Verified on a physical Pixel 9 Pro XL through wireless debugging, plus an Android 35 emulator. On the phone, the toolbar bottom moved from 1628 (inside Gboard) to 1363 (fully above Gboard’s 1399 top edge).

Physical-device evidence

Before After
Before: composer obscured by Gboard After: complete composer above Gboard

Watch the wireless-debugging interaction recording

Validation

  • vp check
  • vp run typecheck
  • vp run lint:mobile
  • vp run --filter @t3tools/mobile test — 92 files, 538 tests passed
  • Android 35 emulator with Gboard and a maximum-height multiline prompt

Checklist

  • This PR is small and focused
  • I explained what changed and why
  • I included before/after screenshots for the UI change
  • I included a short video for the keyboard interaction change

Note

Low Risk
Android-only UI/layout change in one screen; iOS path unchanged and the pattern matches other mobile composers.

Overview
On Android, the new-task draft screen no longer uses KeyboardAvoidingView with padding and a flex spacer above the composer. The draft composer is wrapped in a bottom-anchored KeyboardStickyView (absolute positioning, zero keyboard offset) so it tracks the IME while the prompt expands on focus.

That avoids a race where padding-based avoidance could leave the multiline editor and toolbar under Gboard when height changes. iOS still uses the existing KeyboardAvoidingView layout.

Reviewed by Cursor Bugbot for commit 4e3aa7b. Bugbot is set up for automated code reviews on this repo. Configure here.

Note

Fix Android new task composer to stay above the keyboard

Replaces KeyboardAvoidingView with KeyboardStickyView in the Android render path of NewTaskDraftScreen.tsx. The composer is now absolutely positioned at the bottom and sticks above the IME as it opens, removing the previous padding-based relayout approach and the flex spacer view above the composer.

Macroscope summarized 4e3aa7b.

@coderabbitai

coderabbitai Bot commented Jul 23, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 471aba79-cef0-4f08-9026-ac2d6db3e6cf

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@github-actions github-actions Bot added vouch:unvouched PR author is not yet trusted in the VOUCHED list. size:S 10-29 changed lines (additions + deletions). labels Jul 23, 2026
@macroscopeapp

macroscopeapp Bot commented Jul 23, 2026

Copy link
Copy Markdown
Contributor

Approvability

Verdict: Approved

Straightforward Android UI bug fix that replaces one keyboard-handling component with another from the same library to keep the composer above the keyboard. Limited scope, clear intent, no broader runtime implications.

You can customize Macroscope's approvability policy. Learn more.

@colonelpanic8
colonelpanic8 force-pushed the fix/android-composer-keyboard-positioning branch 6 times, most recently from 2df4224 to 82eee6c Compare July 24, 2026 01:41
@colonelpanic8
colonelpanic8 force-pushed the fix/android-composer-keyboard-positioning branch from 82eee6c to 4e3aa7b Compare July 24, 2026 02:32

@cursor cursor Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes using high effort and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 4e3aa7b. Configure here.

) : null}
</View>
</KeyboardAvoidingView>
</KeyboardStickyView>

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Composer can cover Android header

Medium Severity

KeyboardStickyView is absolutely positioned in the same root as AndroidScreenHeader, so a tall focused composer (attachments plus max-height editor) can draw over the header and back control when space above the IME is tight. The prior KeyboardAvoidingView stayed in normal layout below the header, and ThreadRouteScreen / terminal keep sticky chrome inside a flex-1 region under the header for the same reason.

Additional Locations (1)
Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 4e3aa7b. Configure here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:S 10-29 changed lines (additions + deletions). vouch:unvouched PR author is not yet trusted in the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant