Skip to content

fix(i18n): 补全剩余用户界面中文文案#22

Merged
zerx-lab merged 5 commits intozerx-lab:mainfrom
LeoYoung-code:feature/i18n-zh-cn-remaining-surfaces
May 4, 2026
Merged

fix(i18n): 补全剩余用户界面中文文案#22
zerx-lab merged 5 commits intozerx-lab:mainfrom
LeoYoung-code:feature/i18n-zh-cn-remaining-surfaces

Conversation

@LeoYoung-code
Copy link
Copy Markdown

Description

补全 OpenWarp 当前分支中真实用户界面仍可见的英文固定文案国际化,覆盖终端输入区、Agent/会话界面、设置、Code Review、Drive 分享、Notebook/Workflow、workspace/onboarding 等界面文案,并同步补齐 enzh-CN Fluent 资源。

主要改动:

  • 将用户可见英文文案迁移到 crate::t! / crate::t_static! / t_or 等本地化入口。
  • crates/onboarding 增加 app 注入的本地化回调,使 onboarding callout 能复用 app i18n 资源。
  • 修复 OpenWarp 启动弹窗 render 路径使用 t_static! 的泄漏风险,改为运行时 crate::t! 字符串。
  • 修复 FTL 文案中的显式空格,避免 trailing whitespace 检查失败。

说明:当前 PR 仍包含部分非功能性 rustfmt churn,后续 review 如需可以继续清理成更窄的 i18n-only diff。

Testing

  • git diff --check origin/main
  • cargo fmt --check
  • FTL key 对齐脚本:en=2620zh=2620,无重复、无缺失、无额外 key
  • ./script/run --dont-open 生成 app bundle
  • 打开本地构建 /Users/staff/project/AI/warp/target/debug/current-OpenWarp.app
  • 验证启动进程来自当前仓库:target/debug/current-OpenWarp.app/Contents/MacOS/warp-oss
  • 验证窗口状态:frontmost=true, visible=true, windows=1

未运行完整 ./script/presubmit,因为本次改动面较大且本地完整 presubmit 成本较高;先以 draft PR 收集 review。

Server API dependencies

  • Is this change necessary to make the client compatible with a desired server API breaking change?
  • Does this change rely on a new server API?
    • If so, is the use of this API restricted to client channels that rely on the staging server (e.g. WarpDev)?
  • Is this change enabling the use of a server API on client channels that rely on the production server (e.g. WarpStable)?
    • If so, has the new server API been stable on production for at least one server release cycle? See here for more details.

Agent Mode

  • Warp Agent Mode - This PR was created via Warp's AI Agent Mode

Co-Authored-By: Warp [email protected]

@LeoYoung-code
Copy link
Copy Markdown
Author

image 编译测试通过

@LeoYoung-code LeoYoung-code marked this pull request as ready for review May 4, 2026 15:46
@zerx-lab zerx-lab merged commit 7742171 into zerx-lab:main May 4, 2026
@LeoYoung-code LeoYoung-code deleted the feature/i18n-zh-cn-remaining-surfaces branch May 5, 2026 02:06
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.

2 participants