From 03c53905c1fd4f0bb2c66c972bcd92633a1e38fd Mon Sep 17 00:00:00 2001 From: Arnas Donauskas Date: Fri, 17 Apr 2026 21:11:05 +0300 Subject: [PATCH] fix(dashboard): open the clicked conversation when deep-linking from dashboard Clicking a row in the dashboard's "Recent Conversations" routed to /inbox with no hint about which conversation to open, so the user landed on the empty center panel and had to find the thread again. - Dashboard now routes to /inbox?c= for per-row clicks. "View all" still goes to plain /inbox. - Inbox page reads ?c= and auto-selects the matching conversation in handleConversationsLoaded (event handler, not an effect, so react-hooks/set-state-in-effect stays happy). A ref guards against resnapping the selection on later realtime list refreshes. - Inbox also now replaces the URL with ?c= when the user picks a conversation, so a page refresh / shared link lands on the same thread. Co-Authored-By: Claude Opus 4.7 (1M context) --- src/app/(dashboard)/dashboard/page.tsx | 2 +- src/app/(dashboard)/inbox/page.tsx | 45 ++++++++++++++++++++++++-- 2 files changed, 43 insertions(+), 4 deletions(-) diff --git a/src/app/(dashboard)/dashboard/page.tsx b/src/app/(dashboard)/dashboard/page.tsx index 83c82f6..24fa91d 100644 --- a/src/app/(dashboard)/dashboard/page.tsx +++ b/src/app/(dashboard)/dashboard/page.tsx @@ -261,7 +261,7 @@ export default function DashboardPage() { recentConversations.map((conv) => (