feat(search-dialog): show active folder in search popup header

This commit is contained in:
xintaofei
2026-04-23 14:11:54 +08:00
parent c7cd94a01b
commit 7aec93e922
11 changed files with 25 additions and 1 deletions

View File

@@ -175,11 +175,25 @@ export function SearchCommandDialog({
return (
<CommandDialog
title={t("dialogTitle")}
title={
folder
? t("dialogTitleWithFolder", { name: folder.name })
: t("dialogTitle")
}
open={open}
onOpenChange={onOpenChange}
shouldFilter={activeTab === "conversations"}
>
{/* Folder context header */}
{folder && (
<div className="flex items-center gap-2 border-b px-4 py-2.5">
<Folder className="w-4 h-4 shrink-0 text-muted-foreground" />
<span className="text-sm font-medium truncate">
{t("dialogTitleWithFolder", { name: folder.name })}
</span>
</div>
)}
{/* Tabs */}
<div className="flex items-center gap-0 border-b px-3">
<button

View File

@@ -881,6 +881,7 @@
},
"search": {
"dialogTitle": "بحث",
"dialogTitleWithFolder": "بحث — {name}",
"tabConversations": "المحادثات",
"tabFiles": "الملفات",
"placeholder": "البحث في المحادثات...",

View File

@@ -881,6 +881,7 @@
},
"search": {
"dialogTitle": "Suchen",
"dialogTitleWithFolder": "Suchen — {name}",
"tabConversations": "Konversationen",
"tabFiles": "Dateien",
"placeholder": "Konversationen suchen...",

View File

@@ -881,6 +881,7 @@
},
"search": {
"dialogTitle": "Search",
"dialogTitleWithFolder": "Search — {name}",
"tabConversations": "Conversations",
"tabFiles": "Files",
"placeholder": "Search conversations...",

View File

@@ -881,6 +881,7 @@
},
"search": {
"dialogTitle": "Buscar",
"dialogTitleWithFolder": "Buscar — {name}",
"tabConversations": "Conversaciones",
"tabFiles": "Archivos",
"placeholder": "Buscar conversaciones...",

View File

@@ -881,6 +881,7 @@
},
"search": {
"dialogTitle": "Rechercher",
"dialogTitleWithFolder": "Rechercher — {name}",
"tabConversations": "Conversations",
"tabFiles": "Fichiers",
"placeholder": "Rechercher des conversations...",

View File

@@ -881,6 +881,7 @@
},
"search": {
"dialogTitle": "検索",
"dialogTitleWithFolder": "検索 — {name}",
"tabConversations": "会話",
"tabFiles": "ファイル",
"placeholder": "会話を検索...",

View File

@@ -881,6 +881,7 @@
},
"search": {
"dialogTitle": "검색",
"dialogTitleWithFolder": "검색 — {name}",
"tabConversations": "대화",
"tabFiles": "파일",
"placeholder": "대화 검색...",

View File

@@ -881,6 +881,7 @@
},
"search": {
"dialogTitle": "Buscar",
"dialogTitleWithFolder": "Buscar — {name}",
"tabConversations": "Conversas",
"tabFiles": "Arquivos",
"placeholder": "Buscar conversas...",

View File

@@ -881,6 +881,7 @@
},
"search": {
"dialogTitle": "搜索",
"dialogTitleWithFolder": "搜索 — {name}",
"tabConversations": "会话",
"tabFiles": "文件",
"placeholder": "搜索会话...",

View File

@@ -881,6 +881,7 @@
},
"search": {
"dialogTitle": "搜尋",
"dialogTitleWithFolder": "搜尋 — {name}",
"tabConversations": "會話",
"tabFiles": "檔案",
"placeholder": "搜尋會話...",