Skip to content

feat(spec): model action-param translations (_actions.params) - #1860

Merged
xuyushun441-sys merged 2 commits into
mainfrom
feat/i18n-action-params
Jun 15, 2026
Merged

xuyushun441-sys merged 2 commits into
mainfrom
feat/i18n-action-params

Conversation

@xuyushun441-sys

Copy link
Copy Markdown
Collaborator

Adds an optional params record to the action translation schema so action param label/helpText/placeholder/options can be localized via the existing keys+bundles path: objects.<obj>._actions.<action>.params.<param>.{label,helpText,placeholder,options}. All optional/additive — existing bundles unaffected. objectui's useObjectLabel().actionParamText() already reads this key path; this unblocks the bundle entries (cloud follow-up) + the renderer wiring (objectui follow-up). 1149 spec tests pass; DTS build green.

🤖 Generated with Claude Code

…ons.params)

Action labels localize via `objects.<obj>._actions.<action>.label` bundle keys,
but action PARAMS (the dialog form fields) had no translation path — the
`_actions` translation schema only modeled label/confirmText/successMessage, so
a param's label/helpText/placeholder/options could not be localized and rendered
English in a zh UI.

Add an optional `params` record to the action translation schema (in
ObjectTranslationDataSchema._actions, globalActions, and the secondary
ObjectTranslationNodeSchema._actions):

  _actions.<action>.params.<param>.{ label?, helpText?, placeholder?, options? }

`options` maps a select value → translated label. All optional and additive, so
existing bundles are unaffected. objectui's `useObjectLabel().actionParamText()`
already reads this exact key path; this unblocks authoring the bundle entries.

Tests: 1149 spec tests pass (translation/i18n-resolver/typegen); DTS build green.
@vercel

vercel Bot commented Jun 15, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
spec Ready Ready Preview, Comment Jun 15, 2026 3:46am

Request Review

@github-actions github-actions Bot added documentation Improvements or additions to documentation tooling labels Jun 15, 2026
@xuyushun441-sys
xuyushun441-sys merged commit d1e930a into main Jun 15, 2026
13 checks passed
@xuyushun441-sys
xuyushun441-sys deleted the feat/i18n-action-params branch June 15, 2026 03:51
xuyushun441-sys added a commit that referenced this pull request Jun 21, 2026
…2125)

* feat(spec,showcase): lookup record-picker authoring metadata + demo

The objectui record picker can present multi-column, scoped, dependent lookup
results, but FieldSchema exposed none of the authoring surface for it — so the
props were silently dropped by defineStack's Zod parse (cf. the FieldSchema
property-liveness audit, which flags referenceFilters reaching the renderer
under a different key). Authors had no supported way to curate or scope a picker.

spec (FieldSchema, packages/spec/src/data/field.zod.ts):
- Add forward record-picker props to the lookup/master_detail surface:
  `displayField`, `descriptionField`, `lookupColumns`, `lookupPageSize`,
  `lookupFilters` (structured, picker-honoured form of referenceFilters),
  and `dependsOn` (dependent/cascading lookups). All are genuinely wired —
  the objectui renderer reads them (camelCase + snake_case aliases). They flow
  through Field.lookup() automatically via FieldInput.
- Tests: assert the props survive FieldSchema.parse (not stripped) and that
  Field.lookup() carries them through.

showcase (examples/app-showcase):
- Expand the account seed from 3 → 13 (varied industry / revenue / lifecycle,
  incl. churned) so the picker exercises search, sort, pagination and scoping.
- Configure showcase_invoice.account with curated `lookupColumns`
  (name / industry / lifecycle / revenue), a `descriptionField`, and a
  `lookupFilters` rule that hides churned accounts — a rep can't invoice a
  churned customer. Demonstrates the new authoring surface end-to-end.

Pairs with objectui PR #1860 (renderer: auto-derive columns + i18n + accept
both key casings + apply lookupFilters in the popover).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

* chore(spec): classify new lookup picker props in the liveness ledger

The spec liveness gate requires every authorable FieldSchema property to be
classified. Mark displayField/descriptionField/lookupColumns/lookupPageSize/
lookupFilters/dependsOn as live (consumed by the objectui record picker, cited
as prose per the ledger convention) and sharpen the referenceFilters authorHint
to point at the structured lookupFilters key.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

---------

Co-authored-by: Jack Zhuang <277994282+os-zhuang@users.noreply.github.com>
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>

This branch was successfully deployed

1 active deployment
Preview — f399acc3 Deployed Jun 15, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation size/s tooling

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants