mirror of
https://github.com/docmost/docmost.git
synced 2026-08-25 15:57:11 +08:00
feat: extend title-only search to attachments
The titleOnly flag now matches attachment file names via the separator-normalized trigram expression, and the toggle chip stays available in attachment mode as File name only.
This commit is contained in:
@@ -1309,5 +1309,6 @@
|
|||||||
"Read-only mode": "Read-only mode",
|
"Read-only mode": "Read-only mode",
|
||||||
"AI Chat can search and read workspace content, but cannot create or edit pages.": "AI Chat can search and read workspace content, but cannot create or edit pages.",
|
"AI Chat can search and read workspace content, but cannot create or edit pages.": "AI Chat can search and read workspace content, but cannot create or edit pages.",
|
||||||
"Toggle AI Chat read-only mode": "Toggle AI Chat read-only mode",
|
"Toggle AI Chat read-only mode": "Toggle AI Chat read-only mode",
|
||||||
"Title only": "Title only"
|
"Title only": "Title only",
|
||||||
|
"File name only": "File name only"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -255,7 +255,7 @@ export function SearchSpotlightFilters({
|
|||||||
</Menu.Dropdown>
|
</Menu.Dropdown>
|
||||||
</Menu>
|
</Menu>
|
||||||
|
|
||||||
{contentType !== "attachment" && !isAiMode && (
|
{!isAiMode && (
|
||||||
<Button
|
<Button
|
||||||
variant={titleOnly ? "light" : "subtle"}
|
variant={titleOnly ? "light" : "subtle"}
|
||||||
color={titleOnly ? "blue" : "gray"}
|
color={titleOnly ? "blue" : "gray"}
|
||||||
@@ -270,7 +270,9 @@ export function SearchSpotlightFilters({
|
|||||||
aria-pressed={titleOnly}
|
aria-pressed={titleOnly}
|
||||||
onClick={() => setTitleOnly(!titleOnly)}
|
onClick={() => setTitleOnly(!titleOnly)}
|
||||||
>
|
>
|
||||||
{t("Title only")}
|
{contentType === "attachment"
|
||||||
|
? t("File name only")
|
||||||
|
: t("Title only")}
|
||||||
</Button>
|
</Button>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
|
|||||||
+1
-1
Submodule apps/server/src/ee updated: 641346a5b8...1ab61e594f
Reference in New Issue
Block a user