You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Payment Due 26Feb] [$250] Android - Reports - Tap on expands shows nothing in selection mode #78111
Version Number: v9.2.82-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:#76175 Email or phone of affected tester (no customers):ndk.2303+150@gmail.com Issue reported by: Applause Internal Team Bug source: Pull Request QA execution Device used: Pixel 7a/ Android 16 App Component: Search
Action Performed:
Preconditions: New log in to account which has expenses from atleast 2 other users
changed the title [-]Android - Reports - Tap on expands shows nothing in selection mode[/-][+][$250] Android - Reports - Tap on expands shows nothing in selection mode[/+]on Dec 19, 2025
Please re-state the problem that we are trying to solve in this issue.
On Android, when viewing the Reports page with group-by: from enabled and entering selection mode (by long-pressing any row), tapping the expand button on other rows does nothing.
The expenses that should appear under the expanded row remain hidden, preventing users from viewing or selecting nested transactions.
What is the root cause of that problem?
The expand button is implemented as a PressableWithFeedback component inside the AnimatedCollapsible component, which is nested within another PressableWithFeedback component that wraps the entire row in TransactionGroupListItem.
When a user taps the expand button in mobile selection mode on Android, the touch event propagates to the parent row's PressableWithFeedback, triggering its onPress handler instead of (or in addition to) the expand button's onExpandIconPress handler.
The parent row's onPress handler executes logic that either calls onSelectRow() for expense reports or handleToggle() for grouped transactions. However, in mobile selection mode, this behavior is incorrect because:
Row presses in selection mode should not trigger navigation or selection actions
Only explicit checkbox interactions and expand button presses should be handled
The parent row's onPress interferes with the expand button's functionality
This handler doesn't check for mobile selection mode, so it always executes when the row (or any nested element) is pressed.
What changes do you think we should make in order to solve the problem?
Add a check for mobile selection mode in the parent row's onPress handler to prevent it from executing when users are in selection mode on mobile devices. This will allow the expand button's own onPress handler to work properly without interference.
Add isMobileSelectionModeEnabled check from Onyx in TransactionGroupListItem.tsx
Modify the onPress callback to return early when in mobile selection mode on narrow layouts
This ensures the expand button press only triggers its own handler (onExpandIconPress)
Updated code:
// Add the Onyx subscriptionconst[isMobileSelectionModeEnabled]=useOnyx(ONYXKEYS.MOBILE_SELECTION_MODE,{canBeMissing: true});// Update the onPress handlerconstonPress=useCallback(()=>{// In mobile selection mode, row presses should not trigger selection or expansion// Users should only interact via checkboxes and the expand buttonif(isMobileSelectionModeEnabled&&!isLargeScreenWidth){return;}if(isExpenseReportType||transactions.length===0){onSelectRow(item,transactionPreviewData);}if(!isExpenseReportType){handleToggle();}},[isMobileSelectionModeEnabled,isLargeScreenWidth,isExpenseReportType,transactions.length,onSelectRow,transactionPreviewData,item,handleToggle]);
What alternative solutions did you explore?
The chosen solution is a minimal, focused fix that addresses the root cause directly. By checking the selection mode state in the parent's onPress handler, we maintain the existing component structure while properly handling the selection mode behavior. The fix is isolated to one component, easy to test, and doesn't affect desktop or non-selection mode behavior.
Please re-state the problem that we are trying to solve in this issue.
Taps on expand button in selection mode shows nothing.
What is the root cause of that problem?
In onExpandIconPress, when isEmpty && !shouldDisplayEmptyView is true (group-by mode with no loaded transactions), the else if prevents searchTransactions() from being called. Additionally, onPress (which handles row taps) doesn't call searchTransactions() at all when toggling expansion:
[Contributor] The offending PR has been commented on, pointing out the bug it caused and why, so the author and reviewers can learn from the mistake.
No offending PR identified: This is a long-standing bug from the original implementation and the same solution to refetch transaction when expanding at PR is missed handling logic would cause the expanded state to change twice when clicking the icon.
[Contributor] If the regression was CRITICAL (e.g. interrupts a core flow) A discussion in #expensify-open-source has been started about whether any other steps should be taken (e.g. updating the PR review checklist) in order to catch this type of bug sooner.
N/A
[Contributor] If it was decided to create a regression test for the bug, please propose the regression test steps using the template below to ensure the same bug will not reach production again.
Regression Test Proposal
Test:
Navigate to Reports
Enter 'group-by: from' in Search input field
Hold any row to trigger selection mode
Tab on icon chevron down icon (or item) to expand other rows
Activity
melvin-bot commentedon Dec 19, 2025
Triggered auto assignment to @brianlee-expensify (
Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details. Please add this bug to a GH project, as outlined in the SO.[-]Android - Reports - Tap on expands shows nothing in selection mode[/-][+][$250] Android - Reports - Tap on expands shows nothing in selection mode[/+]melvin-bot commentedon Dec 19, 2025
Job added to Upwork: https://www.upwork.com/jobs/~022002016164090131181
melvin-bot commentedon Dec 19, 2025
Triggered auto assignment to Contributor-plus team member for initial proposal review - @suneox (
External)btkcodedev commentedon Dec 19, 2025
Proposal
Please re-state the problem that we are trying to solve in this issue.
On Android, when viewing the Reports page with
group-by: fromenabled and entering selection mode (by long-pressing any row), tapping the expand button on other rows does nothing.The expenses that should appear under the expanded row remain hidden, preventing users from viewing or selecting nested transactions.
What is the root cause of that problem?
The expand button is implemented as a
PressableWithFeedbackcomponent inside theAnimatedCollapsiblecomponent, which is nested within anotherPressableWithFeedbackcomponent that wraps the entire row inTransactionGroupListItem.When a user taps the expand button in mobile selection mode on Android, the touch event propagates to the parent row's
PressableWithFeedback, triggering itsonPresshandler instead of (or in addition to) the expand button'sonExpandIconPresshandler.The parent row's
onPresshandler executes logic that either callsonSelectRow()for expense reports orhandleToggle()for grouped transactions. However, in mobile selection mode, this behavior is incorrect because:onPressinterferes with the expand button's functionalityCurrent problematic code:
This handler doesn't check for mobile selection mode, so it always executes when the row (or any nested element) is pressed.
What changes do you think we should make in order to solve the problem?
Add a check for mobile selection mode in the parent row's
onPresshandler to prevent it from executing when users are in selection mode on mobile devices. This will allow the expand button's ownonPresshandler to work properly without interference.Changes: (
src/components/SelectionListWithSections/Search/TransactionGroupListItem.tsx)isMobileSelectionModeEnabledcheck from Onyx in TransactionGroupListItem.tsxonPresscallback to return early when in mobile selection mode on narrow layoutsonExpandIconPress)Updated code:
What alternative solutions did you explore?
The chosen solution is a minimal, focused fix that addresses the root cause directly. By checking the selection mode state in the parent's
onPresshandler, we maintain the existing component structure while properly handling the selection mode behavior. The fix is isolated to one component, easy to test, and doesn't affect desktop or non-selection mode behavior.mohammadjafarinejad commentedon Dec 19, 2025
Proposal
Please re-state the problem that we are trying to solve in this issue.
Taps on expand button in selection mode shows nothing.
What is the root cause of that problem?
In
onExpandIconPress, whenisEmpty && !shouldDisplayEmptyViewis true (group-by mode with no loaded transactions), theelse ifpreventssearchTransactions()from being called. Additionally,onPress(which handles row taps) doesn't callsearchTransactions()at all when toggling expansion:App/src/components/SelectionListWithSections/Search/TransactionGroupListItem.tsx
Lines 214 to 221 in 7406d2e
App/src/components/SelectionListWithSections/Search/TransactionGroupListItem.tsx
Lines 184 to 191 in 7406d2e
So when expanding in selection mode, transactions are never fetched.
What changes do you think we should make in order to solve the problem?
onPress: AddsearchTransactions()call when expanding non-expense-report typesonExpandIconPress: Changeelse iftoifso both conditions execute independently (Optionally)What alternative solutions did you explore? (Optional)
None
40 remaining items
suneox commentedon Feb 25, 2026
BugZero Checklist
[Contributor] The offending PR has been commented on, pointing out the bug it caused and why, so the author and reviewers can learn from the mistake.
No offending PR identified: This is a long-standing bug from the original implementation and the same solution to refetch transaction when expanding at PR is missed handling logic would cause the expanded state to change twice when clicking the icon.
[Contributor] If the regression was CRITICAL (e.g. interrupts a core flow) A discussion in #expensify-open-source has been started about whether any other steps should be taken (e.g. updating the PR review checklist) in order to catch this type of bug sooner.
N/A
[Contributor] If it was decided to create a regression test for the bug, please propose the regression test steps using the template below to ensure the same bug will not reach production again.
Regression Test Proposal
Test:
Verify: Expenses will be shown
Do we agree 👍 or 👎
melvin-bot commentedon Feb 26, 2026
Current assignee @suneox is eligible for the External assigner, not assigning anyone new.
laurenreidexpensify commentedon Feb 26, 2026
Payment Summary
laurenreidexpensify commentedon Feb 26, 2026
Payment Summary
trjExpensify commentedon Mar 2, 2026
approved $250 for @suneox.