Skip to content

[$175] Expense - Unable to dismiss report RHP by clicking outside RHP #108579

Todo

Description

@applause-bot

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


Version Number: 9.5.57-0
Reproducible in staging?: Yes
Reproducible in production?: No
If this was caught during regression testing, add the test name, ID and link from BrowserStack: #107110
Email or phone of affected tester (no customers): sodjnosdjonjsjon@gmail.com
Issue reported by: Applause Internal Team
Bug source: Exploratory - Significant User Experience Deterioration
Device used: Mac 26.5 / Chrome
App Component: Money Requests

Action Performed:

  1. Go to staging.new.expensify.com
  2. Go to workspace chat.
  3. Create an expense.
  4. Open the report.
  5. Click outside report RHP.

Expected Result:

Report RHP can be dismissed by clicking outside RHP.

Actual Result:

Report RHP cannot be dismissed by clicking outside RHP.

Workaround:

Unknown

Platforms:

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

Screenshots/Videos

Bug7328834_1796167259384.1.mp4

View all open jobs on GitHub

Applause Internal Information
Exported by: Mita Rachim
Bug ID: 7328834

Upwork Automation - Do Not Edit

Activity

  1. added
    DeployBlockerCash
    Bug
    on Dec 1, 2026
  2. applause-bot commented on Dec 1, 2026

    @applause-bot
    Author

    While Applause doesn't embed attachments for this bug, here are the links for quick view:
    https://platform.applause.com/services/links/v1/external/8ebad67f260504ebfa6f2cf61e8e838ff4c92b1c1dbaa7010aa8c896ac6cbcb2

  3. expensify-chore-bot commented on Dec 1, 2026

    @expensify-chore-bot

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

  4. expensify-chore-bot commented on Dec 1, 2026

    @expensify-chore-bot

    @grgia @ZhenjaHorbach you have been assigned to this deploy blocker because you reviewed the offending PR: #107110

  5. expensify-chore-bot commented on Dec 1, 2026

    @expensify-chore-bot

    @adamgrzybowski you have been assigned to this deploy blocker because you authored the offending PR: #107110

  6. expensify-chore-bot commented on Dec 1, 2026

    @expensify-chore-bot

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

  7. github-actions commented on Dec 1, 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.
  8. MelvinBot commented on Dec 1, 2026

    @MelvinBot
    Contributor

    🤖 Web test steps verification results: ⚠️ partial

    The deploy-blocker investigator identified “Open report to-dos in the RHP and auto-advance between reports”, included in staging 9.5.57-0, as the likely cause: its shared RHP wrapper change replaces View with Reanimated.View, whose style copying bypasses React Native Web’s identity-based box-none handling, allowing the full-screen wrapper to intercept outside clicks even outside the Home flow. Recommendation: revert that PR before deployment; source attribution is strong but runtime confirmation remains blocked, and the narrower alternative—an explicit pointerEvents="box-none" prop, following this existing App precedent—needs validation of outside dismissal, internal controls, and Home transitions.

    Workspace chat with expense action menu at the interaction blocker

    Step Status
    Open the web AppConfirmed the signed-in development web App.
    ✅
    Go to a workspace chatCreated a workspace for the prepared account and reached its expense chat.
    ✅
    Create an expenseThe Create expense action was blocked by the device tool’s covered-element safety check; no bypass was attempted.
    Workspace chat with expense action menu at the interaction blocker
    ❌
    Open the expense report RHPNot reached because expense creation was blocked.
    ⚠️
    Click outside the report RHPNot reached; neither the reported failure nor the proposed correction was browser-verified.
    ⚠️

    view run · view recording

  9. ZhenjaHorbach commented on Dec 2, 2026

    @ZhenjaHorbach
    Contributor

    Strange
    I'm pretty sure that this issue already existed in staging before, and I didn't mention this in the PR because of this
    But I will check

  10. ZhenjaHorbach commented on Dec 2, 2026

    @ZhenjaHorbach
    Contributor

    @MelvinBot
    Implement these changes and mention in the PR 2 issues
    #108579
    #108587

    diff --git a/src/components/MoneyReportHeaderActions/index.tsx b/src/components/MoneyReportHeaderActions/index.tsx
    index 41ecce9a059e..0450851d6e73 100644
    --- a/src/components/MoneyReportHeaderActions/index.tsx
    +++ b/src/components/MoneyReportHeaderActions/index.tsx
    @@ -13,6 +13,7 @@ import useResponsiveLayoutOnWideRHP from '@hooks/useResponsiveLayoutOnWideRHP';
     import useThemeStyles from '@hooks/useThemeStyles';
     
     import getNonEmptyStringOnyxID from '@libs/getNonEmptyStringOnyxID';
    +import {isHomeTodoResultAnimation} from '@libs/HomeTodoReviewUtils';
     
     import CONST from '@src/CONST';
     import ONYXKEYS from '@src/ONYXKEYS';
    @@ -72,9 +73,10 @@ function MoneyReportHeaderActions({reportID, primaryAction, isReportInSearch, ba
         const narrowedPrimaryAction = narrowPrimaryAction(primaryAction);
     
         // A Home to-do review shows the action's result in place of the button, right before it moves on.
    -    const {isInHomeTodoReview} = useHomeTodoReview(reportID, backTo);
    +    const {homeTodoReview, isInHomeTodoReview} = useHomeTodoReview(reportID, backTo);
         const {isApprovedAnimationRunning, isPaidAnimationRunning, isSubmittingAnimationRunning} = usePaymentAnimationsContext();
    -    const shouldShowHomeTodoResult = isInHomeTodoReview && (isApprovedAnimationRunning || isPaidAnimationRunning || isSubmittingAnimationRunning);
    +    const shouldShowHomeTodoResult =
    +        isInHomeTodoReview && isHomeTodoResultAnimation(homeTodoReview?.searchKey, {isApprovedAnimationRunning, isPaidAnimationRunning, isSubmittingAnimationRunning});
         const [primaryActionWidth, setPrimaryActionWidth] = useState(0);
     
         // A wide layout acts on the selection through the bulk action bar floating over the list instead, so the report's own
    diff --git a/src/libs/HomeTodoReviewUtils.ts b/src/libs/HomeTodoReviewUtils.ts
    index 7310eaa9ecfc..2026f9d09a88 100644
    --- a/src/libs/HomeTodoReviewUtils.ts
    +++ b/src/libs/HomeTodoReviewUtils.ts
    @@ -90,4 +90,26 @@ function getHomeTodoReportRoute(reportID: string, isNarrowLayout: boolean): Rout
         return isNarrowLayout ? ROUTES.REPORT_WITH_ID.getRoute(reportID, undefined, undefined, ROUTES.HOME) : ROUTES.EXPENSE_REPORT_RHP.getRoute({reportID, backTo: ROUTES.HOME});
     }
     
    -export {isHomeTodoActionComplete, getLatestHomeTodoReportAction, getNextHomeTodoReportID, getHomeTodoReportRoute};
    +/**
    + * Whether the running button animation is for an action that finishes the row's to-do on the report, so the review
    + * can show the action's result before moving on. Other actions, such as submitting a retracted report during an
    + * approve review, keep their own animation because the report stays on the row.
    + */
    +function isHomeTodoResultAnimation(
    +    searchKey: HomeTodoSearchKey | undefined,
    +    {isApprovedAnimationRunning, isPaidAnimationRunning, isSubmittingAnimationRunning}: {isApprovedAnimationRunning: boolean; isPaidAnimationRunning: boolean; isSubmittingAnimationRunning: boolean},
    +): boolean {
    +    switch (searchKey) {
    +        case CONST.SEARCH.SEARCH_KEYS.SUBMIT:
    +            return isSubmittingAnimationRunning;
    +        case CONST.SEARCH.SEARCH_KEYS.APPROVE:
    +            // Paying elsewhere approves the report too, which also takes it off the row.
    +            return isApprovedAnimationRunning || isPaidAnimationRunning;
    +        case CONST.SEARCH.SEARCH_KEYS.PAY:
    +            return isPaidAnimationRunning;
    +        default:
    +            return false;
    +    }
    +}
    +
    +export {isHomeTodoActionComplete, isHomeTodoResultAnimation, getLatestHomeTodoReportAction, getNextHomeTodoReportID, getHomeTodoReportRoute};
    diff --git a/src/libs/Navigation/AppNavigator/Navigators/RightModalNavigator.tsx b/src/libs/Navigation/AppNavigator/Navigators/RightModalNavigator.tsx
    index 074a4d390210..1a9d5357fced 100644
    --- a/src/libs/Navigation/AppNavigator/Navigators/RightModalNavigator.tsx
    +++ b/src/libs/Navigation/AppNavigator/Navigators/RightModalNavigator.tsx
    @@ -155,6 +155,9 @@ function RightModalDialogFrame({hasDialogSemantics, style, contentStyle, onConta
                 aria-label={isOuterDialog && hasName ? dialogAriaLabel : undefined}
                 // Focusable so SRs / claimDialogFocus can land on the dialog when it has no nested controls.
                 tabIndex={isOuterDialog ? -1 : undefined}
    +            // Reanimated copies style objects on web, so react-native-web no longer recognizes the `box-none` style and
    +            // the full-screen box would catch clicks meant for the overlay behind it. The prop keeps clicks passing through.
    +            pointerEvents="box-none"
                 style={[resizeHandle?.dialogStyle ?? [StyleSheet.absoluteFill, styles.pointerEventsBoxNone], isHomeTodoPanelMovingNow && homeTodoPanelStyle]}
             >
                 <Animated.View
    diff --git a/tests/unit/HomeTodoReviewUtilsTest.ts b/tests/unit/HomeTodoReviewUtilsTest.ts
    index 7b49d48f431d..44d69d82bcce 100644
    --- a/tests/unit/HomeTodoReviewUtilsTest.ts
    +++ b/tests/unit/HomeTodoReviewUtilsTest.ts
    @@ -1,4 +1,4 @@
    -import {getLatestHomeTodoReportAction, getNextHomeTodoReportID, isHomeTodoActionComplete} from '@libs/HomeTodoReviewUtils';
    +import {getLatestHomeTodoReportAction, getNextHomeTodoReportID, isHomeTodoActionComplete, isHomeTodoResultAnimation} from '@libs/HomeTodoReviewUtils';
     import {sortTodoReportsBySearchOrder} from '@libs/TodosUtils';
     
     import CONST from '@src/CONST';
    @@ -20,6 +20,55 @@ function buildReportActions(reportActions: ReportAction[]): ReportActions {
     }
     
     describe('HomeTodoReviewUtils', () => {
    +    describe('isHomeTodoResultAnimation', () => {
    +        const NO_ANIMATION = {isApprovedAnimationRunning: false, isPaidAnimationRunning: false, isSubmittingAnimationRunning: false};
    +
    +        it('shows the result when the approve row approves the report', () => {
    +            // Given the approve animation started during an approve review
    +            const animations = {...NO_ANIMATION, isApprovedAnimationRunning: true};
    +
    +            // When the review decides whether to replace the button with the result
    +            // Then it shows the result, because approving takes the report off the row
    +            expect(isHomeTodoResultAnimation(CONST.SEARCH.SEARCH_KEYS.APPROVE, animations)).toBe(true);
    +        });
    +
    +        it('keeps the submit animation when the approve row submits a retracted report', () => {
    +            // Given the user retracted the report and submitted it again during an approve review
    +            const animations = {...NO_ANIMATION, isSubmittingAnimationRunning: true};
    +
    +            // When the review decides whether to replace the button with the result
    +            // Then it keeps the submit button's own spinner and animation, because the report still needs approval
    +            expect(isHomeTodoResultAnimation(CONST.SEARCH.SEARCH_KEYS.APPROVE, animations)).toBe(false);
    +        });
    +
    +        it('shows the result when the approve row pays the report elsewhere', () => {
    +            // Given the paid animation started during an approve review
    +            const animations = {...NO_ANIMATION, isPaidAnimationRunning: true};
    +
    +            // When the review decides whether to replace the button with the result
    +            // Then it shows the result, because paying elsewhere approves the report too
    +            expect(isHomeTodoResultAnimation(CONST.SEARCH.SEARCH_KEYS.APPROVE, animations)).toBe(true);
    +        });
    +
    +        it('shows the result when the submit row submits the report', () => {
    +            // Given the submit animation started during a submit review
    +            const animations = {...NO_ANIMATION, isSubmittingAnimationRunning: true};
    +
    +            // When the review decides whether to replace the button with the result
    +            // Then it shows the result, because submitting takes the report off the row
    +            expect(isHomeTodoResultAnimation(CONST.SEARCH.SEARCH_KEYS.SUBMIT, animations)).toBe(true);
    +        });
    +
    +        it('keeps the approve animation when the pay row approves the report', () => {
    +            // Given the approve animation started during a pay review, which leaves the report to be paid
    +            const animations = {...NO_ANIMATION, isApprovedAnimationRunning: true};
    +
    +            // When the review decides whether to replace the button with the result
    +            // Then it keeps the button's own animation, because the report still needs payment
    +            expect(isHomeTodoResultAnimation(CONST.SEARCH.SEARCH_KEYS.PAY, animations)).toBe(false);
    +        });
    +    });
    +
         describe('isHomeTodoActionComplete', () => {
             it('treats a submitted report as submitted', () => {
                 // Given a report the user just submitted
    
    
  11. MelvinBot commented on Dec 2, 2026

    @MelvinBot
    Contributor

    🤖 Web test steps verification results: ⚠️ partial

    Implemented the requested changes in draft PR Fix report RHP dismissal and Home review action animations, linking both issues. The 20 focused tests and static checks passed; full Jest timed out, and browser verification was blocked by a blank page and suspended session—not a confirmed product failure.

    Blank dev web App

    Step Status
    Open dev web AppBlank page; snapshots returned no nodes.
    Blank dev web App
    ⚠️
    Go to workspace chatNot executed: App unavailable.
    ⚠️
    Create an expenseNot executed: App unavailable.
    ⚠️
    Open report RHPNot executed: App unavailable.
    ⚠️
    Click outside RHP and confirm dismissalNot executed: App unavailable.
    ⚠️
    Submit reportNot executed: App unavailable.
    ⚠️
    Go to HomeNot executed: App unavailable.
    ⚠️
    Open Approve 1 reportNot executed: App unavailable.
    ⚠️
    More > RetractNot executed: App unavailable.
    ⚠️
    Submit shows spinner, animates to Approve, and stays in approval reviewNot executed: App unavailable.
    ⚠️
    Inside-RHP controls remain usableNot executed: App unavailable.
    ⚠️

    view run · no recording available

  12. added
    Reviewing
    on Dec 2, 2026
  13. changed the title [-]Expense - Unable to dismiss report RHP by clicking outside RHP[/-] [+][$175] Expense - Unable to dismiss report RHP by clicking outside RHP[/+] on Dec 2, 2026
  14. melvin-bot commented on Dec 2, 2026

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

Metadata

Metadata

Labels

BugDeployBlockerCashEngineeringHourlyReviewing

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions