mirror of
https://github.com/farion1231/cc-switch.git
synced 2026-05-04 01:52:00 +08:00
Fully internationalized the usage query feature to support both Chinese and English. Frontend changes: - Refactored UsageScriptModal to use i18n translation keys - Replaced hardcoded Chinese template names with constants - Implemented dynamic template generation with i18n support - Internationalized all labels, placeholders, and code comments - Added template name mapping for translation Backend changes: - Replaced all hardcoded Chinese error messages in usage_script.rs - Converted 33 error instances from AppError::Message to AppError::localized - Added bilingual error messages for runtime, parsing, HTTP, and validation errors Translation updates: - Added 11 new translation key pairs to zh.json and en.json - Covered template names, field labels, placeholders, and code comments Impact: - 100% i18n coverage for usage query functionality - All user-facing text and error messages now support language switching - Better user experience for English-speaking users