-
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
Introduce "Mark as unread" functionality in Expensify.cash #2433
Conversation
// `ReportActionContextMenuItem` with `successText` and `successIcon` which will fallback to | ||
// the `text` and `icon` | ||
onPress: () => { | ||
const message = _.last(lodashGet(this.props.reportAction, 'message', null)); |
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.
I feel like this should be a class method so that it prevents this constructor from turning into a monolithic block of logic and functions.
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.
I see this is being discussed in the delete comments
PR, so I'll wait for the resolution over there
Comments addressed! |
All addressed! |
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.
I think this looks much better and the comments do a good job of explaining the +/- 1
s that are left.
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.
Yes changes are looking much better to me thanks @Gonals !!
All yours, @roryabraham |
Forgot to mention that I came across this in testing. I'm not sure if it's a blocker but if a chat has an Also, we should update the test steps to remove the part about waiting for 3 seconds since the change looks to happen instantly now and QA will ask if it's expected or not. |
Ah! Nice catch! Fixed |
Made a small fix, so this needs re-approval @marcaaron, @tgolen, @roryabraham Thanks! |
// first unread sequence. If there are no unread actions, there's no need to display it. | ||
if (lastReadSequenceNumber > 0) { | ||
setNewMarkerPosition(this.props.reportID, lastReadSequenceNumber + 1); | ||
} |
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.
If there are no unread actions, there's no need to display it.
So should we set it to 0
instead of 0 + 1
?
This change didn't resolve the issue I was seeing.
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.
You are completely right. Should be fixed now. I moved the +1 upwards so we only add it when != 0
All comments addressed again! |
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 is looking great!
It... merged 😮 ✨ |
WE 👏 DID 👏 IT 👏 |
I'm going to cry 🤣 |
Wait, I'm confused about the +1. Can we revert this? |
j/k |
🚀 Deployed to staging in version: 1.0.37-2🚀
|
🚀 Deployed to production in version: 1.0.39-5🚀
|
@tgolen @marcaaron @roryabraham, this is the new PR!
Fixed Issues
Fixes https://github.com/Expensify/Expensify/issues/147475
Tests
3. The `new` marker should show up over that message and the chat in the LHN should become bolded:
new
marker should be correctly in place and the chat in the LHN should unbold instantly. Thenew
marker should remain in place after that.Tested On
Testing on mobile soon (I pretty much destroyed my repository, so it is being a pain to get it to work in mobile again)!
Screenshots
Desktop
iOS
Android