-
-
Notifications
You must be signed in to change notification settings - Fork 70
fix: fix bug with no refreshing date in chat on visibillity event #863
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
base: dev
Are you sure you want to change the base?
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
Deployed to https://msg-adamant-pr-863.surge.sh 🚀 |
f496cf9 to
078039e
Compare
|
Can we merge it? |
|
@dev-adamant-im |
|
@Linhead @dev-adamant-im need to test it |
|
@Linhead check conflicts |
cd4c099 to
d30c84d
Compare
|
@S-FrontendDev Done |
al-onyxprotocol
left a comment
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.
Test environment
App: https://adamant-9z47o72u4-adamant-team.vercel.app/chats/U15712150778664855297
Test ADM account
Browser: Vivaldi | 7.3.3635.14 (Stable channel) (arm64)
OS | macOS Version 15.5 (Build 24F74)
JavaScript | V8 13.4.114.21
User Agent | Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/134.0.0.0 Safari/537.36
Test results: Failed
Test instructions
- Change the system time to 23:55
- Send any message in a chat
- Verify that the message time in the chat is displayed as Today
- Minimize the browser
- After midnight (according to the system clock), return to the browser
- The message time in the chat is still displayed as Today
Switching tabs: Works partly. In chat, date is "Yesterday". But in chat list, it's still "Today".
To fix:
- Listen "Minimize Browser/app" event, and update on restoring from background.
- Update date not only in chat, but also in chat list
|
Fixed |
al-onyxprotocol
left a comment
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.
Test passed ✅
Fixes #862
Fix: Dates in chats not refreshing when day changes while app is in background
Problem
When user opens a chat late at night (e.g., 23:55) and messages display "Today", then switches to another tab/app, and returns after midnight (e.g., 00:05), the dates still incorrectly show "Today" instead of "Yesterday" in chat page and in chat preview section as well . The dates only refresh when opening another chat and coming back or reload the page
Solution
Test instructions