Fix expense rule selection being cancelled when opened via the Concierge link - #99717
Open
mukhrr wants to merge 1 commit into
Open
Fix expense rule selection being cancelled when opened via the Concierge link#99717mukhrr wants to merge 1 commit into
mukhrr wants to merge 1 commit into
Conversation
Mobile selection mode is a single global Onyx flag. Opening Expense rules via the Concierge link from an expense pushes a fullscreen tab entry, so the report screen stays mounted underneath and clears the flag as soon as the Rules page sets it. Focus-gate both clears: the mount cleanup in useMobileSelectionMode, and the single-transaction auto-exit in MoneyReportHeader.
mukhrr
marked this pull request as ready for review
August 28, 2026 01:09
melvin-bot
Bot
requested review from
ChavdaSachin
and removed request for
a team
August 28, 2026 01:09
|
@ChavdaSachin Please copy/paste the Reviewer Checklist from here into a new comment on this PR and complete it. If you have the K2 extension, you can simply click: [this button] |
melvin-bot
Bot
requested review from
heyjennahay
and removed request for
a team
August 28, 2026 01:09
7 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Explanation of Change
Mobile selection mode is a single global Onyx flag. The Concierge rules link pushes a fullscreen tab entry rather than an RHP, so the report you came from stays mounted underneath, and two of its subscribers clear the flag as soon as the Rules page sets it:
MoneyReportHeaderclears it in its render body when the report has one visible transactionuseMobileSelectionModeclears it on mount, andSelectionToolbarGatemountsSelectionToolbarexactly when the flag flipsFocus-gating both clears fixes it, verified red/green on iOS. The hook cleanup is deferred rather than skipped, so the existing stale-selection cleanup still runs once the screen is focused.
Known follow-up, not fixed here: iOS swipe-back out of selection mode leaves a stale
Select multipleheader on the report for about half a second.Fixed Issues
$ #95132
PROPOSAL: #95132 (comment)
Tests
Precondition: two or more personal expense rules, and an expense created through a rule so the Concierge message with the
personal expense ruleslink exists.personal expense ruleslink in the Concierge messageSelectSelect multipleheader,1 selected, and checkboxes visibleOffline tests
Selection mode is a RAM-only Onyx value and the flows above make no API calls, so behaviour is identical offline.
QA Steps
Same as Tests.
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectioncanBeMissingparam foruseOnyxtoggleReportand notonIconClick)src/languages/*files and using the translation methodSTYLE.md) were followedAvatar, I verified the components usingAvatarare working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))npm run compress-svg)Avataris modified, I verified thatAvataris working as expected in all cases)Designlabel and/or tagged@Expensify/designso the design team can review the changes.ScrollViewcomponent to make it scrollable when more elements are added to the page.mainbranch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTeststeps.Screenshots/Videos
Android: Native
Android: mWeb Chrome
android_web.mp4
iOS: Native
IOS_app.mp4
iOS: mWeb Safari
ios_web.mp4
MacOS: Chrome / Safari
web.mp4