tju-yxq opened a new issue, #5516:
URL: https://github.com/apache/rocketmq-dashboard/issues/5516
## Problem
Following the topic (#5507) and DLQ (#5512) localizations, a sweep of the
remaining pages shows seven more with hardcoded strings that bypass the i18n
layer. Each page already imports (or sits next to pages that use) `useLang()`'s
`t()`, and every other page of the console renders fully localized — these
seven are the stragglers:
| Page | Hardcoded strings |
| --- | --- |
| K8s certificates (`cluster/certs.tsx`) | the whole page: ~30 strings —
column titles (`K8s 集群名称`, `签发者`, `剩余天数`, `状态`), status tags
(`有效`/`即将过期`/`已过期`), the create modal (labels, required messages, PEM hints),
the local-storage notice, search placeholder, delete confirm, and toasts
(`证书「{id}」已添加/已删除`) |
| About tab (`settings/AboutTab.tsx`) | all description labels (`版本`,
`构建提交`, `构建时间`, `RocketMQ 支持版本`, `前端框架`, `后端框架`), `相关链接`, `文档中心`, `RocketMQ 社区`
|
| Audit log (`ops/audit.tsx`) | four failure toasts (`审计日志加载失败…`,
`审计概览加载失败…`, `清理审计日志失败…`, `导出审计日志失败…`) and the cleanup modal's `天之前的日志` suffix |
| Client connections (`cluster/clients.tsx`) | the load-failure default
(`客户端连接加载失败,请稍后重试`) and the `重试` button |
| ACL (`instance/acl.tsx`) | the secret reveal placeholder `加载中…` |
| Dashboard (`home/dashboard.tsx`) | the load-failure alert (`仪表盘加载失败` +
description) and the `重试` button |
| AI composer (`ai/components/Composer.tsx`) | the six quick-prompt chips
(`查看集群状态`, `Topic 堆积 Top10`, `诊断消费延迟`, `创建 Topic`, `消息轨迹查询`, `扩缩容评估`) |
An operator who switches the console to English gets mixed-language output
on exactly these pages — including the failure toasts, where understanding the
message matters most.
## Expected behavior
All user-facing strings on these pages go through `t()` + `translations.ts`,
completing the console-wide localization sweep (the two large pages, consumer
and topic detail flows, are the remaining outliers and are tracked separately).
## Notes
- Reusable `common.*` keys already exist for several of these
(`common.actions`, `common.delete`, `common.cancel`, `common.all`,
`common.retry`).
- The K8s certs page needs a full `certs.*` section (~30 keys); the About
tab needs an `about.*` section; the others extend their existing namespaces.
- The AI quick prompts are inserted into the draft when clicked, so both the
chip label and the inserted text should follow the display language.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]