Repository navigation
refactor: extract useMoneyRequestReportColumns and useMoneyRequestReportLayout - #101200
Conversation
… decompose/money-request-report-transactions-b2-v2
Codecov Report❌ Looks like you've decreased code coverage for some files. Please write tests to increase, or at least maintain, the existing level of code coverage. See our documentation here for how to interpret this table.
|
|
I'll take a look at this pr soon |
|
No product review needed. |
Reviewer Checklist
Screenshots/VideosAndroid: HybridAppCleanShot.2026-09-19.at.13.32.46.2.mp4Android: mWeb ChromeCleanShot.2026-09-19.at.13.32.46.mp4iOS: HybridAppCleanShot.2026-09-19.at.13.46.35.4.mp4iOS: mWeb SafariCleanShot.2026-09-19.at.13.42.55.3.mp4MacOS: Chrome / SafariCleanShot.2026-09-19.at.13.22.13.1.mp4CleanShot.2026-09-19.at.13.59.56.1.mp4 |
|
|
||
| const REPORT_DETAILS_CUSTOM_COLUMNS = Object.values(CONST.SEARCH.REPORT_DETAILS_CUSTOM_COLUMNS); | ||
|
|
||
| function isReportDetailsCustomColumn(column: string): column is SearchCustomColumnIds { |
There was a problem hiding this comment.
NAB: This function is duplicated in ReportDetailsColumnsPage; we can extract it and reuse
There was a problem hiding this comment.
Done, extracted to SearchUIUtils
|
@suneox I've resolved conflicts. This is ready for finish of your review |
suneox
left a comment
There was a problem hiding this comment.
No logic changes & no measurable perf impact, LGTM
Perf A/B check
Reassure, merge-base `08bc847` vs PR head `2c13e8a`, same machine, sequential runs:| Test (MoneyRequestReportActionsList.perf-test) | Base (ms) | PR (ms) | Δ | Renders |
|---|---|---|---|---|
| render, 500 actions + 10 transactions | 25.9 | 25.1 | −3.4% | 6 → 6 |
| render, 500 actions + 100 transactions | 29.5 | 29.1 | −1.4% | 6 → 6 |
| re-render on transaction change | 86.1 | 84.2 | −2.2% | 12 → 12 |
| re-render on new report action | 91.7 | 89.3 | −2.6% | 12.10 → 12.10 |
| re-render on unrelated report update | 93.2 | 97.0 | +4.1% | 16 → 16 |
mountiny
left a comment
There was a problem hiding this comment.
Straightforwards, thanks
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
|
🚧 mountiny has triggered a test Expensify/App build. You can view the workflow run here. |
|
🧪🧪 Use the links below to test this adhoc build on Android, iOS, and Web. Happy testing! 🧪🧪
|
|
🚀 Deployed to staging by https://github.com/mountiny in version: 9.4.91-0 🚀
|
No help site changes required — no draft PR createdThis PR is a pure internal refactor. It moves existing logic out of Because nothing on the help site is now inaccurate, there is nothing to document, so I did not open a draft PR. What I checkedThe five changed files, and why each is docs-neutral:
The one change that is not byte-identical logic: the saved column list is now narrowed with Existing help site coverage stays accurate. The group-by flow this PR touches is documented in If you expected a behavior change here that I missed, reply with Note: there is no help site PR to link, since this refactor requires no docs changes. The requested sign-off line follows for completeness. @sosek108, please review the linked help site PR and confirm it reflects the current behavior. Then mark the linked help site PR |
|
🚀 Deployed to production by https://github.com/lakchote in version: 9.4.91-3 🚀
Bundle Size Analysis (Sentry): |
refactor: extract useMoneyRequestReportColumns and useMoneyRequestReportLayout
Explanation of Change
This is PR 8 of a 10-PR stack decomposing the MoneyRequestReport list components (
MoneyRequestReportActionsList/MoneyRequestReportTransactionList) into focused hooks and presentational sub-components (issue #99919, superseding drafts #99307 and #99417).This slice extracts the transaction table's column derivation and the report-layout (group-by) selection into dedicated hooks.
Fixed Issues
$ #99919
PROPOSAL:
Tests
Offline tests
QA Steps
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectionAvatar, 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.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
iOS: Native
Nagranie.z.ekranu.2026-09-17.o.12.16.13.mov
iOS: mWeb Safari
MacOS: Chrome / Safari
Nagranie.z.ekranu.2026-09-17.o.12.07.45.mov