fix(i18n): stop warning on missing tool.name.* keys for proper-name tools (T-493)

Tool display names are open-ended (Bash, Grep, Glob, ScheduleWakeup, MCP tools,
…) — they intentionally have no catalog key and fall back to the raw name, so a
miss isn't a gap to fix. The conversation pane was logging an i18n "missing key"
warning for each, cluttering the output dock.

Adds a `warnIfMissing` flag to I18nService.string (default true, so fixed UI
strings still warn on a real gap) threaded through the ClideSettings facade;
_toolNameLabel passes false. Display is unchanged — the placeholder already
rendered the raw name.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-06-28 14:58:12 +02:00
co-authored by Claude Opus 4.8
parent e5976ad6b1
commit 066197c5e1
7 changed files with 55 additions and 8 deletions
@@ -1162,10 +1162,11 @@ class _ActivityCard extends StatelessWidget {
}
/// Localized display label for a tool name (T-462). File/web/task operations
/// have natural translations; command/proper-name tools (Bash, Grep, Glob, LS)
/// have no catalog key and fall back to the raw name via the placeholder.
/// have natural translations; command/proper-name tools (Bash, Grep, Glob,
/// ScheduleWakeup, MCP tools, …) have no catalog key by design and fall back to
/// the raw name — so `warnIfMissing: false` keeps a miss from logging (T-493).
String _toolNameLabel(BuildContext context, String name) =>
ClideSettings.i18n.string(context, 'tool.name.$name', namespace: 'builtin.claude', placeholder: name);
ClideSettings.i18n.string(context, 'tool.name.$name', namespace: 'builtin.claude', placeholder: name, warnIfMissing: false);
/// Localized "N steps" counter for a collapser header (T-462). Singular and
/// plural are distinct catalog keys; the English forms double as the fallback.