From a25b149f6543042ca81f2bad3aa9d40b7a17c2e4 Mon Sep 17 00:00:00 2001 From: Xin Wang Date: Mon, 13 Jul 2026 07:18:22 +0800 Subject: [PATCH] Refactor AssistantPage and DebugVoicePanel for improved view management - Remove the SegmentedIconGroup for view selection and streamline view handling in DebugDrawer. - Introduce DebugVisionWorkspace component to manage video and chat views more effectively. - Update DebugVoicePanel to accept onViewChange prop for better view state management. - Enhance video handling with dynamic positioning and drag functionality for the floating video panel. --- .../src/components/pages/AssistantPage.tsx | 167 +++++++++++++++--- 1 file changed, 139 insertions(+), 28 deletions(-) diff --git a/frontend/src/components/pages/AssistantPage.tsx b/frontend/src/components/pages/AssistantPage.tsx index b46fcb5..7545f5d 100644 --- a/frontend/src/components/pages/AssistantPage.tsx +++ b/frontend/src/components/pages/AssistantPage.tsx @@ -2243,22 +2243,6 @@ function DebugDrawer({ )} - - setView("chat")} - > - - - setView("video")} - > - -
@@ -2268,6 +2252,7 @@ function DebugDrawer({
void; showTranscript: boolean; vizStyle: VizStyle; assistantId: string | null; @@ -2672,7 +2659,16 @@ function DebugVoicePanel({
{/* 后端 TTS 音频经 WebRTC 媒体流过来,挂这里播放 */}