-
Notifications
You must be signed in to change notification settings - Fork 2.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
27456 Chat - The green line is displayed chaotically at the recipient #29860
Conversation
CLA Assistant Lite bot All contributors have signed the CLA ✍️ ✅ |
I have read the CLA Document and I hereby sign the CLA |
128fd1e
to
1ea93f7
Compare
shouldDisplay = isCurrentMessageUnread && isNextMessageRead && isWithinVisibleThreshold; | ||
|
||
if (shouldDisplay && !messageManuallyMarkedUnread) { | ||
shouldDisplay = reportAction.actorAccountID !== Report.getCurrentUserAccountID(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we ignore this condition if shoudlDisplay was set as false before? What is the purpose?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@barttom Yes, the previous logic worked the same (if shoudlDisplay was false before, it was also false for this condition as well), the code was like that:
App/src/pages/home/report/ReportActionsList.js
Lines 292 to 294 in 39d2a84
if (!messageManuallyMarkedUnread) { | |
shouldDisplay = shouldDisplay && reportAction.actorAccountID !== Report.getCurrentUserAccountID(); | |
} |
@Santhosh-Sellavel 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] |
Will get to it today eve. Sorry for the delay. |
No worries, thanks for the update! |
@Santhosh-Sellavel could you please share an update here, thank you |
Looks like Santhosh-Sellavel is ooo https://expensify.slack.com/archives/C02NK2DQWUX/p1698333756531649 |
I can help review today if needed |
Thanks, that would be great |
Code looks good. One doubt if it's expected.
Screen.Recording.2023-10-30.at.11.38.15.PM.mov |
Ha ha, a good case. Yes, that's expected. Assuming the message arrived on both devices at same time, and was marked as read on Mobile since user was scrolled down. We still want to make sure user sees the new message on web since they were scrolled up |
Tests well on all platforms. @MonilBhavsar shall I complete reviewer checklist? |
Yes please, so we can ship it!! |
Reviewer Checklist
Screenshots/VideosAndroid: NativeIncluded in web video Android: mWeb ChromeIncluded in desktop video iOS: NativeIncluded in web video iOS: mWeb SafariIncluded in desktop video MacOS: Chrome / Safariwhen scrolled to latest message: web-ios-android.movwhen scrolled to old message: web-ios-android2.movMacOS: Desktopdesktop-mweb.mov |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
✋ 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/MonilBhavsar in version: 1.3.94-0 🚀
|
1 similar comment
🚀 Deployed to staging by https://github.com/MonilBhavsar in version: 1.3.94-0 🚀
|
We reverted the PR as it introduced two issues/blockers #30712 (comment) Not taking visibiliity into account for manual unread case fixed one issue, but not the one with deleted case - shouldDisplay = isCurrentMessageUnread && (!nextMessage || isNextMessageRead) && (messageManuallyMarkedUnread || isWithinVisibleThreshold); We can update the approach and make a new PR cc @roksanaz |
🚀 Deployed to production by https://github.com/Beamanator in version: 1.3.94-2 🚀
|
🚀 Deployed to staging by https://github.com/MonilBhavsar in version: 1.3.95-0 🚀
|
🚀 Deployed to production by https://github.com/puneetlath in version: 1.3.95-9 🚀
|
Details
This PR implements logic not to display the green line for any new messages provided that the thread is scrolled to the latest message. It was achieved by taking into account the vertical offset of the user. The green line should still appear when the thread is scrolled to oldest messages.
Fixed Issues
$ #27456
PROPOSAL: #27456 (comment)
Tests
Offline tests
Same as Tests
QA Steps
Same as Tests
PR Author Checklist
### Fixed Issues
section aboveTests
sectionOffline steps
sectionQA steps
sectiontoggleReport
and notonIconClick
)myBool && <MyComponent />
.src/languages/*
files and using the translation methodWaiting for Copy
label for a copy review on the original GH to get the correct copy.STYLE.md
) were followedAvatar
, I verified the components usingAvatar
are working as expected)/** comment above it */
this
properly so there are no scoping issues (i.e. foronClick={this.submit}
the methodthis.submit
should be bound tothis
in the constructor)this
are necessary to be bound (i.e. avoidthis.submit = this.submit.bind(this);
ifthis.submit
is never passed to a component event handler likeonClick
)StyleUtils.getBackgroundAndBorderStyle(themeColors.componentBG)
)Avatar
is modified, I verified thatAvatar
is working as expected in all cases)ScrollView
component to make it scrollable when more elements are added to the page.main
branch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTest
steps.Screenshots/Videos
Android: Native
27456_android_native.mp4
Android: mWeb Chrome
27456_android_web.mp4
iOS: Native
27456_iOS_native.mp4
iOS: mWeb Safari
27456_iOS_web.mp4
MacOS: Chrome / Safari
27456_web.mp4
MacOS: Desktop
27456_desktop.mp4