Skip to content

spec: the dashboard widget TranslationData node needs a third member for the metric sub-caption — the #5428 ruling's "own key" mandate is unimplementable against the strict {title?, description?} node #7862

Description

@yinlianghui

Contract-first card filed by the objectui whole-repo PM seat (session session_017Qqyix2QcnpUC9XeYVDzx3), spun out of objectui#4032 / PR objectui#4358. Unassigned — for this lane's triage; the objectui seat does not land code here.

The conflict (measured in objectui#4358's implementation)

The #5428 maintainer ruling (2026-08-06), item 4, gives the metric widget's sub-caption (options.description — a DIFFERENT authored field from widget.description) its own translation convention segment, ⛔ explicitly not sharing widget.description's key ("两个作者字段两个 key").

The spec refuses every implementation of that: TranslationDataSchema.dashboards.<dash>.widgets.<id> is strict over exactly { title?, description? }. Measured:

+subCaption  → unrecognized_keys: "Unrecognized key(s) on this widget translation: `subCaption`. …"
+subtitle    → "… Did you mean `subtitle` → `description`? …"
+caption     → unrecognized_keys

— and the schema's own suggestion points the sub-caption AT description, i.e. at precisely the shared key the ruling forbids. objectui#4358 landed ruling items 1–3 and returned item 4 as a stop rather than a workaround; widget.description on a self-contained metric is deliberately still unrendered there, because the only available slot would conflate the two fields.

The ask

Either:

  • A — add an optional third member to the widget translation node (subCaption?, or the spelling this lane prefers) so the metric sub-caption keys dashboards.<d>.widgets.<id>.subCaption; objectui's renderer half then lands as a small follow-up (the resolution seam is already in place from console 记录详情页附件面板:沉在整页最底部不可发现(无位置配置)+ 文案未 i18n 中文界面裸奔英文 #4358), or
  • B — overturn ruling item 4's two-keys mandate (maintainer veto was reserved) and let the sub-caption share description. That conflates two authored fields under one key — the drift shape the ruling named — but it is the zero-vocabulary option and the schema's own hint currently points there.

A preserves the ruling; B preserves the vocabulary. Either unblocks objectui#4032's last item.

Refs objectui#4032, objectui PR #4358, objectstack#5428 (the ruling), ADR governing TranslationData strictness.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions