v3.17.0
Highlights
-
@byline/core/@byline/admin— Added conditional field visibility: every schema field now acceptscondition?: (data, siblingData) => boolean. When present, the admin form renders the field only while the predicate returnstrue, re-evaluated on every form edit.siblingDatais the field's immediate scope (the enclosing group or array item), so a condition inside an array item observes its own item — one field definition drives per-item behaviour across an entire array, e.g.condition: (_data, siblingData) => Boolean(siblingData.generateThumbnail). LikereadOnly,conditionis a rendering hint only: the hidden field's stored value is retained (no clearing write is emitted), condition-hidden fields are exempt from client-side validation, and server-side schema validation is unaffected — pair conditionally-hidden required fields withoptional: trueor adefaultValue. -
@byline/core/@byline/admin— Field hooks can now write across fields:FieldHookContext(received bybeforeValidate/beforeChange) carriessetFieldValue(path, value). It is a raw store write — the target field's own hooks do not run, which forecloses hook recursion — but it is otherwise a normal form edit: it emits afield.setpatch (so it persists on save), marks the form dirty, and store-subscribed widgets re-render immediately. Combined withcondition, this composes radio-group behaviour across array items: checking one item's checkbox unchecks its siblings and swaps which item's dependent field is visible. The new "Conditional visibility" and "Field hooks and cross-field writes" sections indocs/04-collections/01-fields.mddocument both features, including a server-sidebeforeCreate/beforeUpdatebackstop recipe for enforcing such invariants beyond the editor.
Chores
@byline/admin— Commented out the dev-timeFormContext.appendPatchconsole tracing that logged every accumulated patch to the dev console during editing.
All other @byline/* packages bumped to 3.17.0 in lockstep with no behavioural changes this cycle.