Chat message date display#824
Conversation
|
@philon- is attempting to deploy a commit to the Meshtastic Team on Vercel. A member of the Team first needs to authorize it. |
There was a problem hiding this comment.
Pull Request Overview
This PR adds date grouping functionality to chat messages with visual date delimiters and chronological sorting. It introduces locale-aware date labels (Today, Yesterday, or formatted dates) and ensures messages are displayed in chronological order.
- Added date grouping logic with
DateDelimitercomponent for visual separation - Implemented chronological sorting to handle out-of-order stored messages
- Added internationalization support for "Today" and "Yesterday" labels
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| packages/web/src/components/PageComponents/Messages/ChannelChat.tsx | Added date grouping functions, DateDelimiter component, and chronological sorting logic |
| packages/web/public/i18n/locales/en/common.json | Added "today" and "yesterday" translation keys to the day unit object |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
|
@philon- looks awesome! You'll need to test what happens in the UI when the messages scroll off the top of the screen. Please provide a screenshot in this PR. |
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
|
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|

Description
This PR adds date labels to messages in chat, as well as a date sort on all messages.
Related Issues
Together with PR #818, hopefully addresses #717: Sorting performed before rendering after this PR, and missing date fallback is added in PR #818.
Fixes #639
Changes Made
DateDelimitercomponent with separators and locale-aware labels (Today, Yesterday, or formatted date).Testing Done
Screenshots (if applicable)
Checklist
CONTRIBUTING_I18N_DEVELOPER_GUIDE.md for more details)