Fix: IOU thread not bold in LHN after expense edit message#88251
Fix: IOU thread not bold in LHN after expense edit message#88251marufsharifi wants to merge 1 commit intoExpensify:mainfrom
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 53a95d037f
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| const lastReadTime = report.lastReadTime ?? ''; | ||
| const reportLastReadTime = report.lastReadTime ?? ''; | ||
| const threadLastReadTime = oneTransactionThreadReport?.lastReadTime ?? ''; | ||
| const lastReadTime = reportLastReadTime > threadLastReadTime ? reportLastReadTime : threadLastReadTime; |
There was a problem hiding this comment.
Compare parent and thread read state independently
Using max(report.lastReadTime, thread.lastReadTime) can hide unread updates in the parent report because read times are tracked per report, not globally. readNewestAction() only updates the currently opened report’s lastReadTime (see src/libs/actions/Report/index.ts), so if the thread is read later than the parent, this line can make isUnread() return false even when report.lastVisibleActionCreated > report.lastReadTime. In LHN paths that call isUnread(report, oneTransactionThreadReport, ...), this can suppress bold/unread for real unread parent activity.
Useful? React with 👍 / 👎.
Explanation of Change
This change makes the Left Hand Navigation unread state more accurate for one-transaction expense threads.
Before, the app only looked at the parent expense report’s read time when deciding whether to show the thread in bold. That caused two confusing cases: the person who edited an expense could still see their own thread as unread, and the other participant might not see the thread bolded even though there was clearly new activity inside it. With this update, we use the most recent read time from either the parent report or the linked transaction thread, so the bold state better matches what the user has actually seen.
Fixed Issues
$ #76677
PROPOSAL: #76677 (comment)
Tests
Preconditions: User A and User B have a chat
Offline tests
QA Steps
// TODO: These must be filled out, or the issue title must include "[No QA]."
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))npm run compress-svg)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
REC-2026041851536.PM.mp4
Android: mWeb Chrome
REC-2026041852237.PM.mp4
iOS: Native
REC-2026041843846.PM.mp4
iOS: mWeb Safari
REC-2026041844639.PM.mp4
MacOS: Chrome / Safari
REC-2026041843352.PM.mp4