Show reply in thread for IOU and Task.#24412
Conversation
|
@situchan PR is ready for review, please have a look. Ty 😄 |
There was a problem hiding this comment.
I don't write a util function here because we're using ReportUtils in our condition, if I move this to util function of ReportActionsUtils it will cause the dependency cycle.
There was a problem hiding this comment.
Because we're showing the detail page when clicking on Split IOU, we shouldn't show the thread for split IOU as well.
|
Bump @situchan |
Reviewer Checklist
Screenshots/VideosWebweb1.movweb2.movMobile Web - Chromemchrome.movMobile Web - Safarimsafari.movDesktopdesktop.moviOSios.movAndroid |
There was a problem hiding this comment.
Can we split this into a separate bool to make it easier to read please
There was a problem hiding this comment.
if (type !== CONTEXT_MENU_TYPES.REPORT_ACTION) return earlier
There was a problem hiding this comment.
isNormalAction -> isCommentAction
isPreviewAction -> isReportPreviewAction (as task preview is also preview)
There was a problem hiding this comment.
| return; | |
| return false; |
|
CLA Assistant Lite bot All contributors have signed the CLA ✍️ ✅ |
b165148 to
7e2e668
Compare
|
@hungvu193 what happened with signature? @benjaminbennet is this your account? |
I've just borrowed my friend laptop to commit because my laptop was broken 🤦 , brb in couple of minutes. |
|
Should be working now. Hmm, not sure why, my laptop was hang when I tried to run npm 🤦 , sorry for this inconvenience @situchan |
add condition for split bill action makes iou repliable, sign commit. add condition for split bill action Update src/pages/home/report/ContextMenu/ContextMenuActions.js Co-authored-by: Situ Chandra Shil <108292595+situchan@users.noreply.github.com> optimize variable name update sign commit, var name and early return sign commit email
situchan
left a comment
There was a problem hiding this comment.
LGTM
@Julesssss all yours
|
✋ 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/Julesssss in version: 1.3.55-0 🚀
|
|
🚀 Deployed to staging by https://github.com/Julesssss in version: 1.3.56-0 🚀
|
|
🚀 Deployed to production by https://github.com/roryabraham in version: 1.3.56-24 🚀
|
| const isCommentAction = reportAction.actionName === CONST.REPORT.ACTIONS.TYPE.ADDCOMMENT && !ReportUtils.isThreadFirstChat(reportAction, reportID); | ||
| const isReportPreviewAction = reportAction.actionName === CONST.REPORT.ACTIONS.TYPE.REPORTPREVIEW; | ||
| const isIOUAction = reportAction.actionName === CONST.REPORT.ACTIONS.TYPE.IOU && !ReportActionUtils.isSplitBillAction(reportAction); | ||
| return isCommentAction || isReportPreviewAction || isIOUAction; |
There was a problem hiding this comment.
Coming from #29342, "paid elsewhere" message had a "reply in thread message"
We resolved this by moving ReportUtils.isThreadFirstChat
- const isCommentAction = reportAction.actionName === CONST.REPORT.ACTIONS.TYPE.ADDCOMMENT && !ReportUtils.isThreadFirstChat(reportAction, reportID);
+ const isCommentAction = reportAction.actionName === CONST.REPORT.ACTIONS.TYPE.ADDCOMMENT;
- return isCommentAction || isReportPreviewAction || isIOUAction;
+ return (isCommentAction || isReportPreviewAction || isIOUAction) && !ReportUtils.isThreadFirstChat(reportAction, reportID);
Details
Show reply in thread for IOU and Task.
Fixed Issues
$ #23377
PROPOSAL: #23377 (comment)
Tests
From...in header to go to parent report.Offline tests
Same as Tests.
QA Steps
From...in header to go to parent report.PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectiontoggleReportand notonIconClick)myBool && <MyComponent />.src/languages/*files and using the translation methodWaiting for Copylabel for a copy review on the original GH to get the correct copy.STYLE.md) were followedAvatar, I verified the components usingAvatarare working as expected)/** comment above it */thisproperly so there are no scoping issues (i.e. foronClick={this.submit}the methodthis.submitshould be bound tothisin the constructor)thisare necessary to be bound (i.e. avoidthis.submit = this.submit.bind(this);ifthis.submitis never passed to a component event handler likeonClick)StyleUtils.getBackgroundAndBorderStyle(themeColors.componentBG))Avataris modified, I verified thatAvataris working as expected in all cases)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
Web
Screen.Recording.2023-08-11.at.17.14.19.mov
Mobile Web - Chrome
crhome.mov
Mobile Web - Safari
safa.mov
Desktop
Screen.Recording.2023-08-11.at.17.14.19.mov
iOS
Screen.Recording.2023-08-11.at.17.46.57.mov
Android
trim.mov
Screen.Recording.2023-08-11.at.18.01.38.mov