[Better Expense Report View] Add missing touch handlers to new report preview#61057
Conversation
|
@DylanDylann 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] |
DylanDylann
left a comment
There was a problem hiding this comment.
The expense preview carousel could scroll smoothly now
Reviewer Checklist
Screenshots/VideosAndroid: NativeScreen.Recording.2025-05-01.at.17.08.09.movAndroid: mWeb ChromeScreen.Recording.2025-05-01.at.17.14.53.moviOS: NativeScreen.Recording.2025-05-01.at.17.13.12.moviOS: mWeb SafariScreen.Recording.2025-05-01.at.17.16.17.movMacOS: Chrome / SafariScreen.Recording.2025-05-01.at.17.15.36.movMacOS: Desktop |
|
@JakubKorytko One minor concern, why do you add shouldDisplayContextMenu prop to transactionPreview? It is unnecessary because this change will allow the user to show the context menu in every child transaction in the carousel |
|
The rest looks fine to me |
Because TransactionPreview has its own touch handlers. Don't we want to enable long-press on long-pressing children? If we remove it, user would not be able to long-press on red squares in carousel because children have no handler of this: Is this the desired result? |
|
@JakubKorytko I am not sure this change is expected and this isn't related to this PR. If we keep it, I think we need to verify the expectation to move forward Before this changeScreen.Recording.2025-05-01.at.23.16.30.movAfter this changeScreen.Recording.2025-05-01.at.23.11.11.movThe difference thing is that when long press on the child transaction we will not display the context menu cc @mountiny Could you help to confirm the expectation? |
|
@DylanDylann is the question:
If so, then I think the answer is CC: @shawnborton for a second opinion on that. |
|
Yup, that makes sense to me. |
|
@JakubKorytko We need to display the same context menu when clicking anywhere on carousel |
Screen.Recording.2025-05-05.at.10.04.11.movDone in a recent commit. |
|
Agreed with the most recent discussion! |
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
|
🚀 Deployed to staging by https://github.com/mountiny in version: 9.1.40-0 🚀
|
|
🚀 Deployed to production by https://github.com/yuwenmemon in version: 9.1.40-7 🚀
|

Explanation of Change
In commit 65dd1d
onPreviewPressedwas removed from theTransactionPreviewbecause it was empty, but it should have been replaced with the same method that the parent uses so that it doesn't blockonPress.I've also added context menu on long press because it was missing.
Fixed Issues
$ #60803
PROPOSAL: N/A
Tests
Offline tests
Same as tests
QA Steps
Same as tests
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectiontoggleReportand notonIconClick)src/languages/*files and using the translation methodSTYLE.md) were followedAvatar, I verified the components usingAvatarare working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))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.mp4
Android: mWeb Chrome
iOS: Native
iOS: mWeb Safari
MacOS: Chrome / Safari
MacOS: Desktop