You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat(cli): validate action visible/disabled predicates at build time (ADR-0032) (#2185)
Extends the build-time expression check to UI action `visible`/`disabled`
predicates (stack-level + object-attached), record-scoped like validation rules.
A record-header/row action's `visible` is evaluated by ActionEngine against
`{ record, recordId, objectName, user, … }` with fail-closed semantics, so a
bare field ref (`!done` instead of `!record.done`) throws at runtime and the
action is silently hidden on every record — the trap behind the #2183
"Mark Done never hides" hunt. `os build` now flags it as an error with the
corrective `record.<field>` message instead of shipping a dead control.
@objectstack/formula: add `ctx` and `features` to the record-scope namespace
roots so ambient globals real action predicates use (`record.id == ctx.user.id`,
`features.multiOrgEnabled`) aren't false-positives. Verified against the full
monorepo build (76 tasks) — every example + platform bundle still compiles
clean; formula (201) + cli (496, incl. 5 new) tests pass.
Co-authored-by: Jack Zhuang <277994282+os-zhuang@users.noreply.github.com>
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
0 commit comments