[No QA] Add green dot in LHN when chat is unread with mention#18038
Conversation
|
@0xmiroslav @grgia One of you needs to 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] |
|
@0xmiroslav or @grgia do you happen to know how to post to the JS console on iOS and Android in the emulator (it's needed for the test steps)? I was able to figure it out for android chrome/ios safari, but couldn't figure it out for the native apps. |
Co-authored-by: Georgia Monahan <38015950+grgia@users.noreply.github.com>
Reviewer Checklist
Screenshots/VideosWebweb.movMobile Web - Chromemchrome.movMobile Web - Safarimsafari.movDesktopdesktop.moviOSios.movAndroidandroid.mov |
0xmiroslav
left a comment
There was a problem hiding this comment.
Looks good, tests well on all platforms.
@0xmiroslav or @grgia do you happen to know how to post to the JS console on iOS and Android in the emulator (it's needed for the test steps)? I was able to figure it out for android chrome/ios safari, but couldn't figure it out for the native apps.
I did it programatically when open the app. Please check how I set onyx value and tested on iOS video
|
Ahh, smart @0xmiroslav. @grgia any other comments? Otherwise, I would love to merge today! |
|
Thanks for the reviews. Gonna merge! |
|
✋ 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/puneetlath in version: 1.3.9-12 🚀
|
|
🚀 Deployed to production by https://github.com/roryabraham in version: 1.3.12-0 🚀
|
Details
This PR adds handling to the front-end to show the green dot in the LHN when a user's chat is unread and they have been mentioned. It goes with this back-end PR which handles setting the
lastMentionedTimefield on the report. The green dot should show up any time a chat is unread and the lastMentionedTime is after the lastReadTime on the chat. In other words, the green dot should show when the user has been mentioned in any of the unread messages.Fixed Issues
$ #17887
Tests
Onyx.merge('report_7152000805184733', {"lastMentionedTime": "2023-04-24 20:55:21.858"});Onyx.merge('report_7152000805184733', {"lastMentionedTime": ""});Offline tests
Same as regular tests. This behavior is purely based on the data available in Onyx.
QA Steps
There is nothing for QA to test yet because this field isn't yet being set by the back-end.
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectiontoggleReportand notonIconClick)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
2023-04-26_19-15-45.mp4
Mobile Web - Chrome
Mobile Web - Safari
Desktop
2023-04-26_19-20-26.mp4
iOS
Android