Skip to content

[Due for payment 2026-04-23] Android - Chat - Different typing mode when rotating device from portrait to landscape #87310

Closed

Description

@mitarachim

If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!


Version Number: 9.3.54-0
Reproducible in staging?: Yes
Reproducible in production?: N/A - new feature, doesn't exist in prod
If this was caught during regression testing, add the test name, ID and link from BrowserStack: #85229
Email or phone of affected tester (no customers): jsdjosidjiojisojio3@gmail.com
Issue reported by: Applause Internal Team
Bug source: Exploratory - Significant User Experience Deterioration
Device used: Samsung Galaxy S25 FE / Android 16
App Component: Money Requests

Action Performed:

  1. Launch Expensify app in landscape mode.
  2. Go to workspace chat.
  3. Tap on the composer.
    → Typing takes place directly on the composer.
  4. Rotate the device to portrait, then back to landscape.
    → Typing takes place on a different modal.

Expected Result:

After rotating device from portrait to landscape, typing should take place inline on the composer.

Actual Result:

After rotating device from portrait to landscape, typing takes place on a different modal.

Workaround:

Unknown

Platforms:

  • Android: App
  • Android: mWeb Chrome
  • iOS: App
  • iOS: mWeb Safari
  • iOS: mWeb Chrome
  • Windows: Chrome
  • MacOS: Chrome / Safari

Screenshots/Videos

Bug7124269_1775609023501.06.mp4

View all open jobs on GitHub

Issue OwnerCurrent Issue Owner: @mallenexpensify

Activity

  1. added
    DeployBlockerCashThis issue or pull request should block deployment
    BugSomething is broken. Auto assigns a BugZero manager.
    DeployBlockerIndicates it should block deploying the API
    on Apr 8, 2026
  2. melvin-bot commented on Apr 8, 2026

    @melvin-bot

    You have been assigned to this deploy blocker because you recently merged this PR: #85229

  3. melvin-bot commented on Apr 8, 2026

    @melvin-bot

    💬 A slack conversation has been started in #expensify-open-source

  4. github-actions commented on Apr 8, 2026

    @github-actions
    Contributor

    👋 Friendly reminder that deploy blockers are time-sensitive ⏱ issues! Check out the open `StagingDeployCash` deploy checklist to see the list of PRs included in this release, then work quickly to do one of the following:

    1. Identify the pull request that introduced this issue and revert it.
    2. Find someone who can quickly fix the issue.
    3. Fix the issue yourself.
  5. MelvinBot commented on Apr 8, 2026

    @MelvinBot
    Contributor

    Proposal

    What is the root cause of that problem?

    Android's IME (keyboard) reads the IME_FLAG_NO_FULLSCREEN flag only once — during onCreateInputConnection(), when the keyboard first connects to the text field. PR #85229 added disableFullscreenUI={isInLandscapeMode} to the Composer (src/components/Composer/implementation/index.native.tsx:139), which correctly sets this flag on rotation. However, React Native's ReactEditText.kt updates imeOptions on the view object but never calls InputMethodManager.restartInput(), so the already-connected IME never re-reads the updated flags.

    Flow:

    1. Portrait: disableFullscreenUI=false → onCreateInputConnection() creates connection without IME_FLAG_NO_FULLSCREEN
    2. Rotate to landscape: React re-renders with disableFullscreenUI=true → updateImeOptions() sets the flag on the view, but the IME has already cached its connection
    3. Android's IME, now in landscape without the no-fullscreen flag, switches to extract/fullscreen (modal) editing

    When starting directly in landscape, the flag is set before onCreateInputConnection(), so the IME respects it from the start.

    What changes do you think we should make in order to solve the problem?

    Add a key={String(isInLandscapeMode)} prop to the MarkdownTextInput in src/components/Composer/implementation/index.native.tsx so the component remounts on orientation change, forcing a fresh onCreateInputConnection() call with the correct disableFullscreenUI value.

    The same fix should be applied to the RNMarkdownTextInput in src/components/TextInput/BaseTextInput/implementation/index.native.tsx:435 which also sets disableFullscreenUI={isInLandscapeMode}.

    What alternative solutions did you explore?

    1. Patch ReactEditText.kt to call restartInput() after updating imeOptions — this is the proper upstream fix but requires a React Native patch, which is heavier.
    2. Dismiss and re-show the keyboard on orientation change — more complex, introduces UX flicker, and harder to get right across devices.
    3. Blur the input on orientation change and let the user re-tap — poor UX, especially for a deploy blocker.

    The key prop approach is the simplest, app-level fix that guarantees a fresh input connection with the correct flags.

    Investigation details

    Evidence chain:

    • src/components/Composer/implementation/index.native.tsx:139 — sets disableFullscreenUI={isInLandscapeMode} reactively
    • src/components/TextInput/BaseTextInput/implementation/index.native.tsx:435 — same pattern
    • node_modules/react-native/ReactAndroid/src/main/java/com/facebook/react/views/textinput/ReactEditText.kt:176-181 — disableFullscreenUI setter calls updateImeOptions() but does NOT call restartInput()
    • ReactEditText.kt:957-976 — updateImeOptions() sets imeOptions with IME_FLAG_NO_FULLSCREEN on the view, but the IME doesn't re-read it
    • ReactEditText.kt:355-373 — onCreateInputConnection() is where the IME reads imeOptions, and it's only called when the IME first connects
    • No occurrences of restartInput found in React Native's TextInput implementation
    • AndroidManifest.xml:40 — configChanges includes orientation|screenSize, so the activity is NOT recreated (React Native handles it via dimension updates)
    • AndroidManifest.xml:45 — windowSoftInputMode=adjustResize makes the visible area very small in landscape, triggering Android's extract mode

    Why Android-only: iOS doesn't have an equivalent "extract mode" — fullscreen text editing is an Android IME behavior specific to landscape + small visible area.


    Next Steps for Contributor+ team: Reply with @MelvinBot implement this to create a draft PR, @MelvinBot <your feedback> to refine this analysis, or explain why you are rejecting Melvin's proposal.

  6. rushatgabhane commented on Apr 8, 2026

    @rushatgabhane
    Member

    I'd say this is not a blocker because landscape mode is a new feature. Let's fix it as a regular issue

  7. 13 remaining items

  8. changed the title [-]Android - Chat - Different typing mode when rotating device from portrait to landscape[/-] [+][Due for payment 2026-04-23] Android - Chat - Different typing mode when rotating device from portrait to landscape[/+] on Apr 16, 2026
  9. melvin-bot commented on Apr 16, 2026

    @melvin-bot

    Reviewing label has been removed, please complete the "BugZero Checklist".

  10. melvin-bot commented on Apr 16, 2026

    @melvin-bot

    The solution for this issue has been 🚀 deployed to production 🚀 in version 9.3.59-4 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve this issue:

    If no regressions arise, payment will be issued on 2026-04-23. 🎊

    For reference, here are some details about the assignees on this issue:

    • @GCyganek does not require payment (Contractor)
    • @truph01 requires payment through NewDot Manual Requests
  11. melvin-bot commented on Apr 16, 2026

    @melvin-bot

    @truph01 The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed. Please copy/paste the BugZero Checklist from here into a new comment on this GH and complete it. If you have the K2 extension, you can simply click: [this button]

  12. melvin-bot commented on Apr 21, 2026

    @melvin-bot

    @truph01 Huh... This is 4 days overdue. Who can take care of this?

  13. melvin-bot commented on Apr 22, 2026

    @melvin-bot

    Triggered auto assignment to @mallenexpensify (Awaiting Payment)

  14. melvin-bot commented on Apr 23, 2026

    @melvin-bot

    Payment Summary

    Upwork Job

    • Contributor: @GCyganek does not require payment (Contractor)
    • Reviewer: @truph01 owed $250 via NewDot

    BugZero Checklist (@mallenexpensify)

    • (if NewFeature) I have created a PR for any necessary HelpDot updates, or I confirmed no updates are necessary.
    • I have verified the correct assignees and roles are listed above and updated the necessary manual offers
    • I have verified that there are no duplicate or incorrect contracts on Upwork for this job (https://www.upwork.com/ab/applicants//hired)
    • I have verified the PR was not reverted
    • I have applied any discounts due to bugs/regressions introduced by this PR
    • I have paid out the Upwork contracts or cancelled the ones that are incorrect
    • I have verified the payment summary above is correct
  15. mallenexpensify commented on Apr 23, 2026

    @mallenexpensify
    Contributor

    Payment Summary

    Contributor+: @truph01 due $125 via NewDot

    regression

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

Metadata

Metadata

Labels

Awaiting PaymentAuto-added when associated PR is deployed to productionBugSomething is broken. Auto assigns a BugZero manager.DailyKSv2Engineering

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions