feat(chat): implement WebSocket chat client with useChatSocket hook

Replace the stubbed chat API with a real WebSocket hook that
connects to /ws/chat and supports DM creation, messaging,
session join/leave, and history retrieval. Keep REST stub
functions for backward compatibility with existing pages
that require listChatSessions/getChatSessionById imports.
This commit is contained in:
zetaloop
2026-05-01 04:25:56 +08:00
parent 1f20198f23
commit a3f0b49112
8 changed files with 426 additions and 215 deletions
+4
View File
@@ -14,6 +14,10 @@ const nextConfig: NextConfig = {
source: "/api/:path*",
destination: `${backendUrl}/api/:path*`,
},
{
source: "/healthz",
destination: `${backendUrl}/healthz`,
},
]
},
}