Skip to content

[Due for payment 2026-10-07] [$175] Landscape - Long scrollable confirmation modals can make content or actions unreachable #101333

Closed

Description

@NikkiWines

If you haven’t already, check out our contributing guidelines for onboarding. To join our Slack channel, fill out this form.


Version Number: 9.4.80-0
Reproducible in staging?: Yes
Reproducible in production?: Yes
If this was caught during regression testing, add the test name, ID and link from BrowserStack: N/A
Email or phone of affected tester (no customers): N/A
Logs: N/A
Expensify/Expensify Issue URL: N/A
Issue reported by: Internal
Slack conversation (hyperlinked to channel name): N/A

Action Performed:

This was identified in issue #101278.

Flow 1 - bulk submit:

  1. Create at least 8 reports with held expenses.
  2. In Search > Reports, select the reports.
  3. Select Submit from the bulk-action menu.
  4. Rotate the device to landscape.
  5. Try to scroll the long report-name list and reach the confirmation action.

Flow 2 - bulk export:

  1. Create or select at least 8 reports that trigger a bulk Export confirmation containing report names, such as an Export again or partial Export confirmation.
  2. In Search > Reports, select the reports.
  3. Select Export from the bulk-action menu.
  4. Rotate the device to landscape.
  5. Try to scroll the long report-name list and reach the confirmation action.

Expected Result:

Long, scrollable confirmation content in landscape remains usable: the report-name list can be scrolled and the confirmation actions remain reachable on iOS and Android.

Actual Result:

The landscape bottom-docked confirmation modal nests the scrollable prompt inside another ScrollView and uses a fixed prompt height. On iOS, the inner list captures scrolling and confirmation actions can be clipped and unreachable. On Android, the outer modal can scroll to the actions, but the inner report-name list cannot scroll.

Workaround:

Rotate to portrait before interacting with the confirmation modal.

Platforms:

Select the officially supported platforms where the issue was reproduced:

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

Screenshots/Videos

N/A

View all open jobs on GitHub

Issue OwnerCurrent Issue Owner: @TaduJR
Upwork Automation - Do Not Edit

Activity

  1. added
    BugSomething is broken. Auto assigns a BugZero manager.
    ExternalAdded to denote the issue can be worked on by a contributor
    ImprovementItem broken or needs improvement.
    on Sep 16, 2026
  2. melvin-bot commented on Sep 16, 2026

    @melvin-bot

    Triggered auto assignment to Contributor-plus team member for initial proposal review - @TaduJR (External)

  3. melvin-bot commented on Sep 16, 2026

    @melvin-bot

    Unable to auto-create job on Upwork. The BZ team member should create it manually for this issue.

  4. added
    BugSomething is broken. Auto assigns a BugZero manager.
    and removed
    BugSomething is broken. Auto assigns a BugZero manager.
    on Sep 16, 2026
  5. MelvinBot commented on Sep 16, 2026

    @MelvinBot
    Contributor

    Updated 2026-09-25: Revised based on feedback from TaduJR.

    Proposal

    Please re-state the problem that we are trying to solve in this issue.

    In landscape, the bulk Submit and Export confirmation modals with a long report-name list can't be fully used. On iOS, the last report names and the confirm button are cut off. On Android, the report-name list won't scroll.

    What is the root cause of that problem?

    Two vertical ScrollViews are nested, and the inner one is taller than the space the modal has in landscape.

    1. On small screens ConfirmModal renders as BOTTOM_DOCKED (src/components/ConfirmModal.tsx:182).
    2. In landscape, BaseModal wraps all bottom-docked children in an outer ScrollView (src/components/Modal/BaseModal.tsx:315, :421).
    3. ConfirmContent wraps the prompt in a second ScrollView when shouldEnablePromptScroll is set (src/components/ConfirmContent.tsx:212), with maxHeight: 300 (src/styles/index.ts:3004-3007).
    4. The landscape sheet is capped at windowHeight * 0.75 (BaseModal.tsx:403). On a phone that is about 290–320pt, so the 300pt list alone nearly fills the sheet.

    Nested vertical scrollers can't share a drag:

    • iOS: the inner list keeps the gesture, so the outer scroller never moves. The bottom ~90pt of the list sits below the edge of the sheet, so the last few report names are hidden, and the buttons are clipped too.
    • Android: the outer scroller gets the gesture, so you can reach the buttons, but the inner report-name list can't scroll.

    This also explains iOS - Submit reports modal cannot be scrolled to the bottom when list is long in landscape.

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

    Make sure there is only ever one vertical scroll. BaseModal already decides whether to wrap its children in a ScrollView, so it passes that decision down through ModalContext, and ConfirmContent skips its own ScrollView when it is already inside one.

    1. Add isContentWrappedInScrollView?: boolean to ModalContextType (src/components/Modal/ModalContext.ts:5-10).
    2. In BaseModal, move modalContextValue (BaseModal.tsx:295-298) below shouldWrapChildrenInScrollView and set isContentWrappedInScrollView: shouldWrapChildrenInScrollView.
    3. In ConfirmContent, read the flag with useContext(ModalContext) and render the prompt ScrollView only when shouldEnablePromptScroll && !isContentWrappedInScrollView.

    Result:

    • Portrait: nothing changes. The list scrolls, and the title and buttons stay in place.
    • Landscape: the whole sheet scrolls as one block, so every report name and the buttons can be reached.

    No hardcoded heights are needed. The fix does not depend on the title, subtitle, button count, or safe area of each flow, so it covers Submit and both Export modals.

    Diff
    diff --git a/src/components/Modal/ModalContext.ts b/src/components/Modal/ModalContext.ts
    @@ -6,6 +6,9 @@ type ModalContextType = {
         // The type of the currently displayed modal, or undefined if there is no currently displayed modal.
         // Note that React Native can only display one modal at a time.
         activeModalType?: ModalType;
    +
    +    // Whether the modal already wraps its children in a vertical ScrollView, so children must not nest another vertical scroller.
    +    isContentWrappedInScrollView?: boolean;
         default: boolean;
     };
    diff --git a/src/components/Modal/BaseModal.tsx b/src/components/Modal/BaseModal.tsx
    @@ -292,11 +292,6 @@ function BaseModal({
         const modalPaddingStyles = shouldUseModalPaddingStyle ? paddings : {paddingLeft: paddings.paddingLeft, paddingRight: paddings.paddingRight};
     
    -    const modalContextValue = {
    -        activeModalType: isVisible ? type : undefined,
    -        default: false,
    -    };
    -
         const {isInNarrowPane} = useContext(NarrowPaneContext);
    @@ -313,6 +308,13 @@ function BaseModal({
         const shouldWrapChildrenInScrollView = shouldWrapModalChildrenInScrollViewIfBottomDockedInLandscapeMode && isBottomDockedModalInLandscapeMode;
    +
    +    const modalContextValue = {
    +        activeModalType: isVisible ? type : undefined,
    +        isContentWrappedInScrollView: shouldWrapChildrenInScrollView,
    +        default: false,
    +    };
    +
         const shouldShowBottomDockedDismissButton = isSmallScreenWidth && type === CONST.MODAL.MODAL_TYPE.BOTTOM_DOCKED && !!(onBackdropPress ?? onClose);
    diff --git a/src/components/ConfirmContent.tsx b/src/components/ConfirmContent.tsx
    @@ -14,7 +14,7 @@
    -import React from 'react';
    +import React, {useContext} from 'react';
     import {View} from 'react-native';
    @@ -22,6 +22,7 @@
     import ImageSVG from './ImageSVG';
    +import ModalContext from './Modal/ModalContext';
     import {PressableWithoutFeedback} from './Pressable';
    @@ -140,6 +141,10 @@ function ConfirmContent({
         const bottomSafeAreaPaddingStyle = useBottomSafeSafeAreaPaddingStyle({addBottomSafeAreaPadding: true});
    +    const {isContentWrappedInScrollView} = useContext(ModalContext);
    +
    +    // Nested vertical ScrollViews can't share a drag: iOS keeps it in the inner one, Android gives it to the outer one.
    +    const shouldScrollPrompt = shouldEnablePromptScroll && !isContentWrappedInScrollView;
    @@ -209,7 +214,7 @@ function ConfirmContent({
                         {subtitleContent}
    -                    {shouldEnablePromptScroll ? <ScrollView style={styles.confirmModalPromptScrollable}>{promptContent}</ScrollView> : promptContent}
    +                    {shouldScrollPrompt ? <ScrollView style={styles.confirmModalPromptScrollable}>{promptContent}</ScrollView> : promptContent}
                     </View>

    TaduJR tested this on iOS in landscape with 27 blocked reports: the sheet scrolls all the way down, and the last report name and the Got it button are both visible.

    What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?

    A ConfirmContent render test with shouldEnablePromptScroll:

    • Given ModalContext with isContentWrappedInScrollView: true, the prompt is not wrapped in its own ScrollView.
    • Given isContentWrappedInScrollView: false or no provider, the prompt is wrapped in a ScrollView, as today.

    What alternative solutions did you explore? (Optional)

    Alternatives and why they are worse
    • Opt ConfirmModal out of BaseModal's wrapper and size the prompt from windowHeight (previous proposal). The height has to subtract the title, subtitle, buttons, and safe area, which change per flow and device, so the numbers drift. Even when correct, the list shrinks to about 5 lines for Submit and about 2 for the Export modals in landscape. FeatureTrainingModal doesn't shrink an inner list either: it turns off the wrapper only because it scrolls all of its own content as one block.
    • Add nestedScrollEnabled to the inner ScrollView. Lets the Android list scroll, but leaves the iOS gesture conflict and the clipped rows and buttons.

    Next Steps for Contributor+ team:
    To accept: @MelvinBot implement [this](https://github.com/Expensify/App/issues/101333#issuecomment-5698351358) to create a draft PR.
    To refine: @MelvinBot <your feedback>
    To reject: Explain why you are rejecting Melvin's proposal.

  6. TaduJR commented on Sep 16, 2026

    @TaduJR
    Contributor

    Reviewing...

  7. melvin-bot commented on Sep 21, 2026

    @melvin-bot

    @TaduJR Eep! 4 days overdue now. Issues have feelings too...

  8. melvin-bot commented on Sep 23, 2026

    @melvin-bot

    @TaduJR 6 days overdue. This is scarier than being forced to listen to Vogon poetry!

  9. 29 remaining items

  10. changed the title [-][Due for payment 2026-09-28] [$175] Landscape - Long scrollable confirmation modals can make content or actions unreachable[/-] [+][Due for payment 2026-10-07] [$175] Landscape - Long scrollable confirmation modals can make content or actions unreachable[/+] on Sep 30, 2026
  11. melvin-bot commented on Sep 30, 2026

    @melvin-bot

    @TaduJR @mallenexpensify

    The solution for this issue has been 🚀 deployed to production 🚀 in version 9.4.95-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-10-07. 🎊

    The following checklist (instructions) will need to be completed before the issue can be closed. Please copy/paste the Contributor+ 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]. If no checklist is needed for this issue, you can click: [no checklist button]

  12. TaduJR commented on Sep 30, 2026

    @TaduJR
    Contributor

    @mallenexpensify

    Contributor+: @TaduJR due $250 via Upwork

    The External label was applied 2026-09-16. I think this should be $250 right? Also the upwork offer is $175

    Offer Accepted since pricing can be fixed on Upwork

  13. TaduJR commented on Sep 30, 2026

    @TaduJR
    Contributor

    Contributor+ Checklist:

    Regression Test Proposal

    Precondition:

    • Have at least 15 expense reports on a workspace, each with one expense, and hold every expense.

    Test:

    1. Open the Expensify app on iOS or Android.
    2. Go to Spend > Reports.
    3. Select all the reports with held expenses.
    4. Tap the dropdown button > Submit.
    5. Rotate the device to landscape.
    6. Swipe up on the list of report names in the "Submit reports" modal.
    7. Verify the whole modal scrolls and the last report name and the "Got it" button are fully visible at the bottom.

    Do we agree 👍 or 👎

  14. added and removed on Oct 5, 2026
  15. TaduJR commented on Oct 7, 2026

    @TaduJR
    Contributor

    Friendly Bump here @mallenexpensify

    Thanks

  16. melvin-bot commented on Oct 12, 2026

    @melvin-bot

    @TaduJR Eep! 4 days overdue now. Issues have feelings too...

  17. mallenexpensify commented on Oct 14, 2026

    @mallenexpensify
    Contributor

    Payment Summary

    Contributor+: @TaduJR due $250 via NewDot

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.DailyKSv2ExternalAdded to denote the issue can be worked on by a contributorImprovementItem broken or needs improvement.

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions