- Add ActionBar component with expandable toolbar for mobile - Add @mention functionality with autocomplete dropdown - Add browser notification system (push, sound, vibration) - Add NotificationSettings modal for user preferences - Add mention badges on room list cards - Add ReportPreview with Markdown rendering and copy/download - Add message copy functionality with hover actions - Add backend mentions field to messages with Alembic migration - Add lots field to rooms, remove templates - Optimize WebSocket database session handling - Various UX polish (animations, accessibility) 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
1.7 KiB
1.7 KiB
realtime-messaging Specification
ADDED Requirements
Requirement: Message Sender Display Name
The system SHALL include the sender's display name in message responses and broadcasts, enabling the UI to show user-friendly names instead of email addresses.
Scenario: Message response includes display name
- WHEN a message is retrieved via REST API or WebSocket
- THEN the response SHALL include
sender_display_namefield - AND the display name SHALL be obtained by joining with the
tr_userstable - AND if the sender does not exist in
tr_users, the field SHALL fallback tosender_id
Scenario: WebSocket broadcast includes display name
- WHEN a new message is broadcast via WebSocket
- THEN the broadcast SHALL include
sender_display_namefield - AND the value SHALL be the sender's display name from
tr_userstable
Scenario: Historical messages include display name
- WHEN a client requests message history via
GET /api/rooms/{room_id}/messages - THEN each message in the response SHALL include
sender_display_name - AND messages from unknown users SHALL show their
sender_idas fallback
Requirement: GMT+8 Timezone Display
The frontend SHALL display all timestamps in GMT+8 (Asia/Taipei) timezone for consistent user experience across all browsers.
Scenario: Message timestamp in GMT+8
- WHEN a message is displayed in the chat room
- THEN the timestamp SHALL be formatted in GMT+8 timezone
- AND use format "HH:mm" for today's messages
- AND use format "MM/DD HH:mm" for older messages
Scenario: Room list timestamps in GMT+8
- WHEN the room list is displayed
- THEN the "last updated" time SHALL be formatted in GMT+8 timezone