Skip to content

Commit 4f490d8

Browse files
committed
docs(skills): the i18n skill names fields.{field}.inlineTitle and a joined report's block headings
The objectstack-i18n group table did not name two keys the 18.2 bundle accepts and the runtime serves: a master-detail field's `inlineTitle` (addressed on the child object that owns the field; untranslated it keeps its authored text, no fallback to the child's plural label) and a joined report's `blocks.{block_name}.{label,description}` (keyed by the block's required `name`). Both are now in the table, with one example row each spelled as the shipped app-crm and app-showcase bundles spell them, and the hand-written author page under content/docs/ui gains the same two rows. The eval file gains one prompt for both keys; its ratchet row is pinned at the measurement after the duplicate `--no-objects-only` pin was cut, under the standing ruling. Claude-Session: https://claude.ai/code/session_01ADHkmPqouEb6yELnSqBwRY Co-authored-by: Claude <noreply@anthropic.com>
1 parent 0ea90c7 commit 4f490d8

5 files changed

Lines changed: 44 additions & 7 deletions

File tree

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
---
2+
'@objectstack/skills': patch
3+
---
4+
5+
docs(skills): the i18n skill's group table names `fields.{field}.inlineTitle` and `reports.{report}.blocks.{block}.{label,description}`
6+
7+
Clause-②: no
8+
Metadata-protocol: none
9+
10+
`skills/objectstack-i18n/SKILL.md` did not name two keys the 18.2 translation bundle already accepts and the runtime already serves, so an AI author writing a bundle from the skill left a master-detail field's inline child-grid heading and a joined report's block headings in the authoring language. The `fields.{field_name}` row now names `inlineTitle` (addressed on the child object that owns the field; untranslated it keeps its authored text, with no fallback to the child's plural label), the `reports` sentence names `reports.{report}.blocks.{block_name}.{label,description}` (keyed by the block's required `name`), and one example row each, spelled as the shipped `app-crm` and `app-showcase` bundles spell them, follows the group table. The eval file gains one prompt covering both keys.

‎content/docs/ui/translations.mdx‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,7 @@ export default defineStack({
6969
|:---|:---|
7070
| Object label / plural / description | `objects.<name>.label` / `pluralLabel` / `description` |
7171
| Field labels, help text, placeholders | `objects.<name>.fields.<field>.label` / `help` / `placeholder` |
72+
| Inline child-grid heading of a master-detail field (drawn on the parent's form) | `objects.<child>.fields.<field>.inlineTitle` — keyed on the child object that owns the field; untranslated it keeps its authored text, with no fallback to the child's plural label |
7273
| Picklist option labels | `objects.<name>.fields.<field>.options.<value>` |
7374
| View titles, descriptions, empty states | `objects.<name>._views.<view>` |
7475
| Bulk-action copy on a list view (button, confirm prompt, dialog fields) | `objects.<name>._views.<view>.bulkActions.<def>.label` / `.confirmText` / `.confirmLabel` / `.params.<param>.label` / `.help` / `.placeholder` — a bulk param's hint is `help`, not `helpText` |
@@ -82,7 +83,7 @@ export default defineStack({
8283
| Dashboard global-filter label and static option labels | `dashboards.<name>.globalFilters.<filterName>.label` / `.options.<value>` — the key is the filter's `name`, or its `field` when it authors no `name`; an option is keyed by its `value` spelled as a string |
8384
| Analytics dataset label / description | `datasets.<name>.label` / `description` |
8485
| Dataset dimension and measure labels | `datasets.<name>.dimensions.<dimension>.label` / `datasets.<name>.measures.<measure>.label` |
85-
| Report label / description | `reports.<name>.label` / `description` — keyed by the report's `name`; overlaid on every served report, which is what the console's report index lists and the report page is headed by. A label or description an org re-authored on a packaged report is served as edited |
86+
| Report label / description | `reports.<name>.label` / `description` — keyed by the report's `name`; overlaid on every served report, which is what the console's report index lists and the report page is headed by. A label or description an org re-authored on a packaged report is served as edited; a joined report's block headings are `reports.<name>.blocks.<block>.label` / `description`, keyed by the block's required `name` |
8687
| Page labels and `page:header` copy | `pages.<name>.label` / `description` / `title` / `subtitle` — on a `kind: 'slotted'` page the header under `slots.header` is the page's header |
8788
| Page component copy, by component id | `pages.<name>.components.<id>.title` / `description` / `label` / `placeholder` / `emptyText` — reached under `regions[].components[]` and `slots.<slot>`, through `properties.children` and a `page:tabs` / `page:accordion` panel's `items[].children` |
8889
| Page tab labels (`page:tabs` items) | `pages.<name>.components.<tabsId>.items.<value>.label` — keyed by the tabs component's `id` and the item's `value`; an item without a `value` has no key (localize it with an inline locale map), and `page:accordion` panels have none |

‎scripts/check-skills-token-ratchet.mjs‎

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -874,7 +874,15 @@ export const CEILINGS = new Map([
874874
// content to delete (five prompts, five distinct surfaces), so the remainder
875875
// is the whole addition; pinned AT the measurement, zero headroom. The
876876
// raising PR's body carries the same arithmetic.
877-
['skills/objectstack-i18n/evals/bundles-locales-coverage.json', 1451],
877+
// 1451 -> 1642 (2026-10-27, the owed Skills-docs follow-up of the spec PR that
878+
// made a master-detail field's `inlineTitle` and a joined report's block
879+
// `label` / `description` translatable): one eval prompt for both keys. Same
880+
// ruling as the row above, tap label verbatim and untranslated:
881+
// 「A:先削重复,余额按实测提高」. PAID DOWN FIRST: case 6's `--no-objects-only`
882+
// pin duplicated case 5's (77 bytes cut, 20 tokens); the remainder is the new
883+
// case; pinned AT the measurement, zero headroom. The raising PR's body carries
884+
// the same arithmetic.
885+
['skills/objectstack-i18n/evals/bundles-locales-coverage.json', 1642],
878886
// 1211 -> 1458 (card #26302): one eval for a demo whose seed names people —
879887
// expected: both in `demoStaff` with a declared `position` /
880888
// `permissionSets`, created by `os dev`; NO `role:` alias and NO platform

‎skills/objectstack-i18n/SKILL.md‎

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,7 @@ All translatable content for a single object is aggregated under
159159
| Sub-key | Holds |
160160
|:--------|:------|
161161
| `label` / `pluralLabel` / `description` | Object-level text (every key optional) |
162-
| `fields.{field_name}` | `label`, `help`, `placeholder`, `options` (option value → label) per field |
162+
| `fields.{field_name}` | `label`, `help`, `placeholder`, `options` (option value → label), `inlineTitle` (the heading of the inline child grid a `master_detail` field draws on its parent's form — the field lives on the child object, so the key is the child's; untranslated it keeps its authored text, never the child's plural label) per field |
163163
| `_views.{view_name}` | `label`, `description`, `title` (a form view's own heading — only a form that authors one is translated; a list view has none), `emptyState.title` / `emptyState.message`, `bulkActions.{def_name}` (`label`, `confirmText`, `confirmLabel`, `params`) |
164164
| `_actions.{action_name}` | `label`, `description`, `confirmText`, `successMessage`, `params.{param_name}` (and `.options.{value}` beneath it — an option's stored `value` in that param's inline `options`), `outcomeMessages.{outcome}` (an outcome the action's own `outcomeMessages` declares), `resultDialog.title` / `.description` / `.acknowledge` (only under an action that declares a `resultDialog`), `resultDialog.fields.{path}` (the literal `path` of a field in `resultDialog.fields[]`, dots included — `client.secret` is one key); the same keys hold under `globalActions.{action_name}` |
165165
| `_sections.{section_name}` | Form section `label`, `description`; `fields.{field_name}` — the `label`, `placeholder`, `helpText` an entry overrides for that form alone (`helpText` here, `help` under `fields.{field_name}` above: each spells what its source does) |
@@ -172,12 +172,20 @@ an **error** whose message names the `objects.{owner}._actions.{action_name}` ke
172172
instead), `picklists` (`label`, `options` by stored value — every field referencing the
173173
picklist inherits them), `dashboards`, `datasets`, `reports`, `pages`, `flows`, `positions`,
174174
`permissions` (permission sets, spelled as the stack's `permissions[]`), `metadataForms`,
175-
`settingsCommon`; `reports`, `positions` and `permissions` hold `label` + `description` by name.
175+
`settingsCommon`; `reports`, `positions` and `permissions` hold `label` + `description` by name,
176+
and a joined report's block headings sit at `reports.{report}.blocks.{block_name}.{label,description}`,
177+
keyed by the block's required `name`.
176178
Two keys sit deeper than their group's `label`: a `page:tabs` item at
177179
`pages.{page}.components.{tabs_id}.items.{value}.label` (by the item's `value`; an item without
178180
one has no key) and an approval step at `flows.{flow}.approvals.{node_id}.label`.
179181
`os i18n extract --no-objects-only` scaffolds every group above but `messages` and
180-
`settingsCommon`, both keys included.
182+
`settingsCommon`, both keys included. Both deeper keys, as the shipped `app-crm` and
183+
`app-showcase` bundles spell them for `zh-CN`:
184+
185+
```typescript
186+
objects: { crm_opportunity_line_item: { fields: { opportunity: { inlineTitle: '产品明细' } } } },
187+
reports: { showcase_task_overview: { blocks: { open_block: { label: '未完成任务' } } } },
188+
```
181189
`settings` is **platform-only** — it is keyed by a settings manifest's namespace and only
182190
the platform declares one, so an app bundle carrying it is refused by name.
183191

‎skills/objectstack-i18n/evals/bundles-locales-coverage.json‎

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,10 +54,10 @@
5454
{
5555
"id": 6,
5656
"prompt": "Add zh-CN for the `pipeline_by_stage` report, the `sales_manager` permission set, the `regional_lead` position and the `deal_stage` picklist's option labels.",
57-
"expected_output": "Top-level groups keyed by name: `reports.pipeline_by_stage` and `positions.regional_lead` (`label`, `description`), `permissions.sales_manager` (the same, spelled as the stack's `permissions[]`, never `permissionSets`), `picklists.deal_stage.options` by stored value, inherited by every field referencing the picklist. `os i18n extract --no-objects-only` scaffolds all four.",
57+
"expected_output": "Top-level groups keyed by name: `reports.pipeline_by_stage` and `positions.regional_lead` (`label`, `description`), `permissions.sales_manager` (the same, spelled as the stack's `permissions[]`, never `permissionSets`), `picklists.deal_stage.options` by stored value, inherited by every field referencing the picklist.",
5858
"files": [],
5959
"assertions": {
60-
"must_contain": ["reports", "permissions", "positions", "picklists", "--no-objects-only"],
60+
"must_contain": ["reports", "permissions", "positions", "picklists"],
6161
"must_not_contain": ["permissionSets", "report: {"]
6262
}
6363
},
@@ -70,6 +70,16 @@
7070
"must_contain": ["_views", "title", "_sections", "fields", "items", "approvals"],
7171
"must_not_contain": ["stepLabel", "_tabs.overview"]
7272
}
73+
},
74+
{
75+
"id": 8,
76+
"prompt": "In zh-CN the `Products` grid heading on the `crm_opportunity` form and the `Open Tasks` block heading of the joined `showcase_task_overview` report are still English.",
77+
"expected_output": "`objects.crm_opportunity_line_item.fields.opportunity.inlineTitle` — the field lives on the child object, so the key is the child's, and an untranslated `inlineTitle` keeps its authored text (no fallback to the child's plural label); `reports.showcase_task_overview.blocks.open_block.label`, keyed by the block's required `name`. Neither is a `pages.*.components` key.",
78+
"files": [],
79+
"assertions": {
80+
"must_contain": ["inlineTitle", "crm_opportunity_line_item", "blocks", "open_block"],
81+
"must_not_contain": ["fields.opportunity_line_item", "components.open_block"]
82+
}
7383
}
7484
]
7585
}

0 commit comments

Comments
 (0)