From 546dec67a1a9172b6f8b3483122d635eafc138ca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=90=89=E9=91=AB=E5=8D=87?= Date: Wed, 10 Jun 2026 11:24:52 +0800 Subject: [PATCH] =?UTF-8?q?fix(agents):=20=E7=A7=81=E6=9C=89=20tab=20?= =?UTF-8?q?=E6=9C=AA=E8=A7=A3=E9=94=81=E6=97=B6=E9=9A=90=E8=97=8F=E6=90=9C?= =?UTF-8?q?=E7=B4=A2=E6=A0=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 私有广场只有在功能可用且校验过密码后才解锁;未解锁时展示门禁/解锁提示并 隐藏关键词/标签搜索栏(此时没有可筛选的列表)。TagSearchBar 按 tab key 重挂载, 切 tab 时内部关键词输入与展开状态随父级筛选一起重置。 Co-Authored-By: Claude Opus 4.8 (1M context) --- .../workspace/agents/agent-gallery.tsx | 68 +++++++++++-------- 1 file changed, 39 insertions(+), 29 deletions(-) diff --git a/frontend-web/src/components/workspace/agents/agent-gallery.tsx b/frontend-web/src/components/workspace/agents/agent-gallery.tsx index 6d099a18..ff0e453d 100644 --- a/frontend-web/src/components/workspace/agents/agent-gallery.tsx +++ b/frontend-web/src/components/workspace/agents/agent-gallery.tsx @@ -112,6 +112,12 @@ export function AgentGallery() { } }, [privateError, privatePassword]); + // The private tab is only "unlocked" once the feature is usable and a + // password has been verified. Until then we show the gate (or the lock + // prompt) and hide the keyword/tag search bar — there is no list to filter. + const privateUnlocked = privateFeatureUsable && !!privatePassword; + const showSearchBar = activeTab !== "private" || privateUnlocked; + const activeTotal = activeTab === "private" ? privateTotal : mainTotal; const setTabPage = (tab: "all" | "mine" | "private", page: number) => setPages((prev) => ({ ...prev, [tab]: page })); @@ -359,35 +365,39 @@ export function AgentGallery() { )} - setSort(v as AgentSort)}> - - - - - - 最新创建 - 最早创建 - 最近更新 - 最早更新 - 名称 A-Z - 名称 Z-A - - - } - /> + {showSearchBar && ( + setSort(v as AgentSort)}> + + + + + + 最新创建 + 最早创建 + 最近更新 + 最早更新 + 名称 A-Z + 名称 Z-A + + + } + /> + )} {publisher && (
筛选发布者: