Repository navigation
Conversation
|
Verified on CMF Phone 2 Pro, Android 16, Gboard. Built from v0.4.15 tag + this PR merged, self-signed release APK, server is opencode serve on the same phone via Termux (http://127.0.0.1:4096). Before: composer fully hidden behind keyboard (issues #194/#156). After: full composer + send button stay visible above the keyboard, typing is readable. It sits flush with no bottom gap, which is fine. Dismissing the keyboard returns the composer cleanly to the bottom, no stuck padding after 3+ open/close cycles. One build note: |
…ianisv#156) Port of the live-IME-height mechanism from dzianisv#201 (Keyboard.metrics() + keyboardDidShow/Hide listeners, explicit reset to 0 on hide) plus the bounded multiline composer and scrollable QuestionPrompt from dzianisv#208. API-35 guard: the native IME-insets listener in MainActivity owns the IME height on Android 15+, so the JS padding applies only below API 35 — exactly one layer applies it on every API level. iOS keeps behavior="padding" with offset 90. dzianisv#208's static insets.top offset is deliberately not ported: it measured 56 dp short on a Pixel 11 Pro (see dzianisv#194).
Closes #194
Root cause
On edge-to-edge Android,
adjustResizeno longer moves the composer above the IME. TheKeyboardAvoidingViewchange proposed in #182 improves the layout, but a physical Pixel 11 Pro test still left the input partially covered.A larger
keyboardVerticalOffsetcan correct the open position, but React Native 0.81.5 handles AndroidkeyboardDidHideas another frame-change event. With a non-zero offset, that leaves stale bottom padding after the IME closes, so the composer does not return to the bottom.Change
KeyboardAvoidingViewpadding behavior and 90 dp offset.Keyboard.metrics(), subscribe tokeyboardDidShow/keyboardDidHide, and apply the IME-reported height directly as bottom padding.Physical-device verification
Pixel 11 Pro, Android 17:
Verification
npm test— 339 passednpm run typecheckThe change is limited to the session keyboard integration and its small pure helper/tests.