From d07217b747d262689d52becb7feaf9bc44cc3768 Mon Sep 17 00:00:00 2001 From: "dayuan.jiang" Date: Fri, 10 Apr 2026 13:25:56 +0900 Subject: [PATCH] fix: show all enabled panels on chat lobby instead of only templates --- components/chat/ChatLobby.tsx | 34 ++++++++++++++++++++-------------- 1 file changed, 20 insertions(+), 14 deletions(-) diff --git a/components/chat/ChatLobby.tsx b/components/chat/ChatLobby.tsx index f67281d..28f98ec 100644 --- a/components/chat/ChatLobby.tsx +++ b/components/chat/ChatLobby.tsx @@ -107,8 +107,8 @@ export function ChatLobby({ currentInput = "", dict, }: ChatLobbyProps) { - const [templatesExpanded, setTemplatesExpanded] = useState(false) - const [examplesExpanded, setExamplesExpanded] = useState(false) + const [templatesExpanded, setTemplatesExpanded] = useState(true) + const [examplesExpanded, setExamplesExpanded] = useState(true) const [panelVisibility, setPanelVisibility] = useState(getPanelVisibility) const [deleteDialogOpen, setDeleteDialogOpen] = useState(false) const [sessionToDelete, setSessionToDelete] = useState(null) @@ -125,19 +125,25 @@ export function ChatLobby({ const hasHistory = sessions.length > 0 if (!hasHistory) { - if (panelVisibility.myTemplates) { - return ( - - ) + if (!panelVisibility.myTemplates && !panelVisibility.quickExamples) { + return null } - if (panelVisibility.quickExamples) { - return - } - return null + return ( +
+ {panelVisibility.myTemplates && ( + + )} + {panelVisibility.quickExamples && ( +
+ +
+ )} +
+ ) } // Show history + collapsible examples when there are sessions