Files
gridcraft/crates
Lord-Taw 31abf075b7 Translate and standardizes UI error feedback by locale
### Summary
This change centralizes the translation of user-facing error messages in the UI layer while preserving the original error payloads for machine consumption and AI-agent integrations.

### What changed
- Added a centralized error-translation path in `i18n.rs`.
- The UI now translates only the final display text, instead of altering the underlying engine or protocol error payload.
- If a translated string is not available, the original message is kept as a fallback, avoiding broken or overly-simplified output.
- The translation logic is applied at the presentation layer, not at the source of the error.

### Updated call sites
- Error and alert rendering in `widgets.rs`
- Dialog error presentation in `dialogs.rs`
- Print and feedback failures in `printing.rs`
- Top-level UI error handling in `lib.rs`

### Design intent
- Keep the raw engine errors intact for scripts, control channels, and AI/agent integrations.
- Present a clearer, localized message only to end users.
- Avoid modifying dictionary files or adding new translation entries to the global catalog unnecessarily.
- Keep the behavior consistent with the project’s accessibility and internationalization goals.

### Validation
- The focused i18n test passed successfully.
- The relevant UI test suite passed successfully.
- The repository-required CI gate was run and completed without failures according to the latest verification output.
2026-10-19 11:33:07 -03:00
..
2026-10-13 00:49:39 -04:00
2026-10-13 01:40:22 -04:00