Skip to content

feat: implement real-time unread badges, presence tracking, and chat seen status - #374

Merged
trtajim merged 3 commits into
mainfrom
feat/realtime-chat-notifications-presence
Oct 5, 2026
Merged

trtajim merged 3 commits into
mainfrom
feat/realtime-chat-notifications-presence

Conversation

@trtajim

@trtajim trtajim commented Oct 5, 2026 •

Copy link
Copy Markdown
Member

Summary of Changes

  • User Activity & Seen Schema: Added migrations for notifications_last_seen_at, chat_last_seen_at, and last_active_at columns on the users table.
  • Unread Badge Synchronization: Shared accurate unread_notifications_count and unread_chat_count in HandleInertiaRequests and updated Navigation.tsx to show unread badges on desktop and mobile.
  • Presence Channel Metadata: Updated broadcast channel authorizations in routes/channels.php to return image_url and is_verified for online users.
  • Live Chat UX Improvements: Implemented auto mark-seen on chat view, presence sidebar with user avatars and verification badges, and responsive layout polish.

Summary by CodeRabbit

  • New Features
    • Chat navigation now displays unread-message badges, with counts above nine shown as “9+”.
    • The online-member count opens a list of active members with profile details and links to their profiles.
    • Presence information now reflects whether a member was active within the last five minutes.
  • Improvements
    • Notification pages show 10 items at a time. Opening the notification menu clears its unread indicator.
    • Unread notification and chat counts reflect activity since you last viewed each section.

@coderabbitai

coderabbitai Bot commented Oct 5, 2026 •

Copy link
Copy Markdown

Review in Change Stack →

Navigate logical layers of code changes, visualize relationships, and explore their blast radius.

Note

Currently processing new changes in this PR. This may take a few minutes, please wait...

⚙️ Run configuration
  • Configuration used: Repository: hscstack/platform/.coderabbit.yaml
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 1e3dcac8-f3af-4ad4-b4e2-746ba50dcf83
📥 Commits

Reviewing files that changed from the base of the PR and between a0beb56 and 511b5fd.

📒 Files selected for processing (11)
  • app/Http/Controllers/ChatController.php
  • app/Http/Controllers/NotificationController.php
  • app/Http/Middleware/HandleInertiaRequests.php
  • app/Models/User.php
  • database/migrations/2026_10_05_080443_add_notifications_last_seen_at_to_users_table.php
  • database/migrations/2026_10_05_174110_add_chat_last_seen_at_to_users_table.php
  • database/migrations/2026_10_05_190800_add_last_active_at_to_users_table.php
  • resources/js/components/NotificationDropdown.vue
  • resources/js/components/navigation/Navigation.tsx
  • resources/js/pages/Chat/Index.vue
  • routes/channels.php
✨ Finishing Touches
📝 Generate docstrings
  • Commit to this branch
  • Create a new PR
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR
  • Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@trtajim
trtajim force-pushed the feat/realtime-chat-notifications-presence branch from 501cba1 to 511b5fd Compare October 5, 2026 15:28
@trtajim
trtajim merged commit dd218dd into main Oct 5, 2026
5 checks passed
@trtajim
trtajim deleted the feat/realtime-chat-notifications-presence branch October 5, 2026 15:38
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.

1 participant