Skip to content

Show each message's time and a divider for each day - #28

Open
sousavf wants to merge 2 commits into
nikuscs:mainfrom
sousavf:feature/message-times
Open

sousavf wants to merge 2 commits into
nikuscs:mainfrom
sousavf:feature/message-times

Conversation

@sousavf

@sousavf sousavf commented Nov 8, 2026 •

Copy link
Copy Markdown
Contributor

Chats showed a time divider only after an hour of silence. Now every message has its time and each day is grouped, WhatsApp style, on web and iOS.

  • Each message shows its send time centred under it (<time dateTime> on web). Not shown for system notices, the live streaming message or messages still sending.
  • A divider starts each calendar day: Today, Yesterday, the weekday within the last week, otherwise a short date (with the year when not this year).
  • roomsTimeLabel is replaced by roomsDayLabel and roomsMessageTime; the media viewer caption uses both.
  • The "Sent ..." detail in the message actions is unchanged.

Testing

  • bun run check and bun run lint pass.
  • Checked in the running web app; iOS needs only a JS reload.

Screenshots

Taken from a local build with PRs 27 to 30 applied together, using a throwaway demo bot; other sidebar names and previews are replaced with demo text.

Today divider and centred message times

Every message gets its send time under it, and Today, Yesterday or the
date marks where a new day starts, on web and iOS.
@sousavf
sousavf requested a review from nikuscs as a code owner November 8, 2026 09:38
@nikuscs

nikuscs commented Nov 8, 2026

Copy link
Copy Markdown
Owner

Hey Vasco, pushed a fix on top (1b2b5b2) for a few edge cases in the times and dividers:

  • A merged bot reply kept the time of its first entry, which can be a tool call, so a reply at 00:15 after a tool call at 23:55 showed "Yesterday 23:55". It now uses the time of its last text entry (chat.utils.ts), which web, mobile, the pair view and the media viewer all pick up.
  • A silent NO_REPLY stays in the list as a message with no parts, so it could take that day's divider. New roomsMessageDay helper skips messages with no parts, used on web, mobile and the pair view. Same for mobile messages that are only hidden tool calls.
  • Silent replies also showed an orphan timestamp on web; the <time> now only renders when the message has parts.

Check and lint pass; not looked at in a running app yet.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants