feat(search): inline filters, and translate the search UI

The filters themselves already existed end to end — the server takes q, from,
has, before and after, the API client passes them, and the popover has fields
for each. What it lacked was discovery: the panel sits behind a button, so the
capability was invisible.

Typing 'de:fulano' or 'has:image' straight into the search box now applies the
same filters. Keys are accepted in both languages, since the app is bilingual,
and an unrecognised token falls back to being search text — otherwise a message
containing a URL or 'algo:coisa' would become unfindable.

Inline filters win over the panel's: whoever just typed one is expressing the
more recent intent.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
2026-09-01 17:49:05 -03:00
co-authored by Claude Opus 5
parent 4ceb5cd66a
commit 50a8f12c77
6 changed files with 148 additions and 17 deletions
+14
View File
@@ -56,6 +56,20 @@ export const en = {
'accountMenu.copyId': 'Copy User ID',
'accountMenu.copied': 'Copied',
// Search
'search.placeholder': 'Search messages…',
'search.filters': 'Filters',
'search.from': 'From',
'search.fromPlaceholder': 'username',
'search.has': 'Has',
'search.hasAny': 'Any',
'search.hasFile': 'File',
'search.hasImage': 'Image',
'search.hasLink': 'Link',
'search.before': 'Before',
'search.after': 'After',
'search.hint': 'Tip: type from:name, has:image, before:2026-01-31 straight into the search box.',
// Pinned messages
'pins.pin': 'Pin Message',
'pins.unpin': 'Unpin Message',