Skip to content

refactor(i18n): show find, copy mode, and terminal notes through Fluent - #963

Merged
penso merged 4 commits into
mainfrom
i18n/window-find
Nov 1, 2026
Merged

penso merged 4 commits into
mainfrom
i18n/window-find

Conversation

@penso

@penso penso commented Nov 1, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

Part of Phase 2 of docs/i18n.md, following #880, #926/#928, and #941. This PR covers the main window's find bar, copy mode, copying a selection, and notes on terminal text, plus the notes text other views share from agent_notes. It is independent of #954 and #959, which cover other parts of window/.

  • Messages: new window-find.ftl (find, copy mode, selection), window-annotate.ftl (the note card, its offer, and its flashes), and agent-notes.ftl (the Send button, the queued line, and where a batch went).
  • Marked // i18n: migrated: window/find, window/copy_mode, window/selection, window/annotate (and annotate/render), agent_notes, and the state modules they show from: copy_mode, find, and scrollback. The search count ("3 of 17", "17 found", "No results") that find and copy mode share is in scrollback::match_count, and is now messages.
  • Errors: every {error} these lines show uses localize() instead of Display.
  • Fragments and plurals:
    • "Copy mode motion/search not sent" was a word picked in Rust. It is now a selector.
    • The four reasons notes were "kept for browser feedback" were glued to a shared suffix. Each is now its own sentence, picked by a new Kept enum.
    • "N note(s) queued" and the queue-full flash are plural selectors.
  • Placeholders: the find, copy-mode search, and note fields use set_placeholder_with, so they follow a language change.
  • Tests: tests that compared the count or the Send label verbatim strip the isolation marks. New tests:
    • en-XA leak tests:
      • window/find/tests/en_xa.rs: the empty bar, a count, "No results", and copy mode's label.
      • window/annotate/tests/en_xa.rs: the note card, and the card with a queued note and its flash.
      • agent_notes/tests/en_xa.rs: the Send labels and queued lines.
    • A test that each Kept reason picks its own sentence.
  • Docs: none. docs/i18n.md is left as on main, because every open i18n PR edits its "What is left" list. One PR updates the list after they all merge.

No visible change in English.

Screenshots

Native macOS captures, debug build, against an isolated sandbox herdr server. The find bar and copy mode were opened with herdr-gpui run find and run copy_mode, and the language was switched with herdr-gpui language set, so no synthetic input was used. The bottom edge with the status bar is cropped. A search count and the note card need typing, so they're covered by the leak tests and the manual checks below.

en-XA (accented, longer) en-XB (right to left)
find and copy mode en-XA find and copy mode en-XB

The find field's placeholder and copy mode's corner label are messages. Under en-XB both mirror.

QA

  • just format
  • just ci on 6709be511 (macOS arm64, after merging main): passed, 16,406 tests, 0 failed
  • en-XA leak tests: the find bar (empty, a count, no results), copy mode, the note card with and without queued notes, and the notes labels
  • Native en-XA and en-XB check of the find bar and copy mode (screenshots above)
  • Select terminal text in an agent's pane under en-XA and annotate it: the card, hint, Queue and Send, and the flash after Queue read in en-XA
  • Browser tab notes panel under en-XA with an agent: the Send button ("Send to agent", "Send N new", "Resend all") and "Queued until the agent is idle"
  • English: these read as before

just lint-linux and just lint-windows were not run: no cfg gate changed.

penso added 2 commits October 31, 2026 21:52
Part of Phase 2 of docs/i18n.md. The find bar, copy mode, copying a
selection, notes on terminal text, and the notes text other views share
(agent_notes: the Send button, the queued line, and where a batch went)
now come from window-find.ftl, window-annotate.ftl, and agent-notes.ftl.
Errors there use localize(), the search fields' placeholders follow a
language change, and the queued-notes counts are selectors.

The reasons notes were kept for `browser feedback` were glued to a
shared suffix in Rust; each is now its own sentence, picked by a Kept
enum. The search count ("3 of 17", "No results") that find and copy mode
share in scrollback::match_count is a message too.
@netlify

netlify Bot commented Nov 1, 2026 •

Copy link
Copy Markdown

✅ Deploy Preview for herdr-ui canceled.

Name Link
🔨 Latest commit 6709be5
🔍 Latest deploy log https://app.netlify.com/projects/herdr-ui/deploys/6ae79b6bf697d784605d4d2c

@penso

penso commented Nov 1, 2026 •

Copy link
Copy Markdown
Collaborator Author

just ci ran locally and passed on 6709be511 (macOS arm64): 16,406 tests, 0 failed. No extra recipes: no cfg gate changed.

@greptile-apps

greptile-apps Bot commented Nov 1, 2026 •

Copy link
Copy Markdown

RetriggerView in GreptileConfidence Score: 5/5

[Medium impact] The PR appears safe to merge; no new actionable issues were found.

Summary

Moves find, copy-mode, selection, and terminal-note text into Fluent messages.

  • Find and copy mode show text from Fluent messages.
  • The terminal note card shows its text through Fluent.
  • Shared agent-note buttons and delivery messages use Fluent.

The earlier unnumbered finding is fixed: Search::send_failed and Search::answer now use localize(), and the leak test covers a failed search. No new actionable issues were found.

Reviews (3) · Last reviewed commit: "Merge remote-tracking branch 'origin/mai..." · Reviewed by Greptile

Comment thread crates/herdr-gpui/src/find.rs Resolved
…nguage

The find migration left Search::send_failed and Search::answer saving
the client error's Display text, which the find bar shows as is, so a
full command queue or a dropped connection still read in English. Both
now save its localized message, and the en-XA leak test draws a failed
search.
@penso

penso commented Nov 1, 2026

Copy link
Copy Markdown
Collaborator Author

@greptileai review

@penso

penso commented Nov 1, 2026

Copy link
Copy Markdown
Collaborator Author

@greptileai review

@penso
penso merged commit 60127c7 into main Nov 1, 2026
18 of 22 checks passed
@penso
penso deleted the i18n/window-find branch November 1, 2026 21:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant