Skip to content

i18n(dashboards): complete zh-CN dashboard titles & descriptions - #66

Merged
os-zhuang merged 1 commit into
mainfrom
chore/dashboard-i18n
Jun 18, 2026
Merged

os-zhuang merged 1 commit into
mainfrom
chore/dashboard-i18n

Conversation

@os-zhuang

Copy link
Copy Markdown
Contributor

Dashboard widget strings are keyed by widget id in the per-template translation bundles (en.ts is the source of truth). Several widgets were missing from the bundles entirely — so they fell back to the def's hardcoded English title even under the zh-CN UI — and many zh-CN metric cards had a translated title but no translated description, rendering half-Chinese-half-English.

Filled every gap so en.ts and zh-CN.ts mirror each dashboard def exactly. 14 files, +96 lines.

template added
compliance chart assessments_by_month + 4 metric descriptions
content chart published_by_month
contracts charts signed_by_month, exposure_by_counterparty
hr expired_docs + charts headcount_by_dept, hires_by_month
procurement 6 metric/table descriptions + charts po_value_by_month, top_vendors_by_spend
project both dashboards had NO dashboards block at all — added complete en + zh-CN (13 widgets, labels, descriptions, create_project action)
todo chart throughput_by_week

Verification

  • A script cross-checking every dashboard def's widget ids against both bundles now reports zero missing keys (was 21 across 6 dashboards).
  • pnpm typecheck / build / format:check clean.
  • Browser-verified (login admin@objectos.ai):
    • Compliance dashboard now fully Chinese — descriptions ("最近一次评估通过的控制项"…) and chart title ("按月完成的评估(近 12 个月)"), previously English.
    • PMO Overview dashboard now fully Chinese (title "PMO 总览", KPI titles, chart titles "按健康度的项目"/"按类别的未关闭风险"/"按状态的计划预算") — was 100% English before.

Out of scope

KPI unit captions (Controls / Projects / Total Value) are dataset measure labels, not dashboard widget titles, and are localized through a separate mechanism.

🤖 Generated with Claude Code

Dashboard widget strings are keyed by widget id in the per-template
translation bundles; en.ts is the source of truth. Several widgets were
missing from the bundles entirely (so they fell back to the def's hardcoded
English title), and many zh-CN metric cards had a translated title but no
translated description — rendering half-Chinese-half-English under a zh-CN UI.

Filled every gap so en.ts and zh-CN.ts mirror each dashboard def exactly:

- compliance: chart `assessments_by_month` + 4 metric descriptions
- content: chart `published_by_month`
- contracts: charts `signed_by_month`, `exposure_by_counterparty`
- hr: `expired_docs` + charts `headcount_by_dept`, `hires_by_month`
- procurement: 6 metric/table descriptions + charts `po_value_by_month`,
  `top_vendors_by_spend`
- project: both dashboards (pmo_overview, pm_workbench) had NO dashboards
  translation block at all — added complete en + zh-CN blocks (13 widgets,
  labels, descriptions, the create_project action)
- todo: chart `throughput_by_week`

Verified: a script cross-checking every dashboard def's widget ids against
both bundles now reports zero missing keys. Browser-verified the compliance
and PMO dashboards render fully in Chinese (titles, descriptions, chart
titles) where they previously showed English.

Note: KPI unit captions (Controls / Projects / Total Value) are dataset
measure labels, not dashboard widget titles, and are localized through a
separate mechanism — out of scope here.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@os-zhuang
os-zhuang merged commit 401c676 into main Jun 18, 2026
3 checks passed
@os-zhuang
os-zhuang deleted the chore/dashboard-i18n branch June 18, 2026 05:50
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.

1 participant