Atlas Forms
Default Visibility
When modeVisibilitySettings is omitted entirely from a control, or when a specific mode flag is omitted from the object, the control defaults to visible in that mode. The safe default is always visible — you opt in to hiding, not opt in to showing.
Omitting the Property
// No modeVisibilitySettings at all — visible in all five modes
{
"id": "first-name",
"type": "text",
"label": "First Name"
// modeVisibilitySettings omitted → visible in edit, view, design, admin, preview
}
Omitting Individual Mode Flags
// Only 'preview' is false — all other modes default to true (visible)
{
"id": "email",
"type": "email",
"label": "Email Address",
"modeVisibilitySettings": {
"preview": false // hidden in preview
// edit, view, design, admin all default to true → visible
}
}
Effective Visibility Table
| modeVisibilitySettings | edit | view | design | admin | preview |
|---|---|---|---|---|---|
| Omitted entirely | true | true | true | true | true |
{} (empty object) | true | true | true | true | true |
{ preview: false } | true | true | true | true | false |
{ edit: true, view: false } | true | false | true | true | true |
{ edit: false, view: false, preview: false } | false | false | true | true | false |
The Opt-In-to-Hiding Philosophy
Defaults to visible is intentional. When you add a new control to a form, it works immediately in all modes without any extra configuration. You only need to configure modeVisibilitySettings when you want to deviate from universal visibility. This keeps simple forms simple.
parseSchema Normalisation
When parseSchema() processes a control, it fills in any missing mode flags with true — so the engine always works with a fully-specified object internally:
// Input schema (as authored):
{ "modeVisibilitySettings": { "preview": false } }
// After parseSchema() normalisation (internal representation):
{
"modeVisibilitySettings": {
"edit": true,
"view": true,
"design": true,
"admin": true,
"preview": false
}
}
// Your code in a custom player can always safely read any mode flag:
const isVisibleInEdit = control.modeVisibilitySettings?.edit ?? true;
// → true (because parseSchema filled it in)
Design Mode Always Visible by Default
Controls default to visible in
design mode even when you hide them in other modes. This allows form authors to see and configure all controls in Studio. If you want a control to be invisible even in design mode, explicitly set "design": false.