Group Field
The Group Field allows Fields to be nested under a common property name. It also groups fields together visually in the Admin Panel.
To add a Group Field, set the type
to group
in your Field Config:
Config Options
Option | Description |
---|---|
| To be used as the property name when stored and retrieved from the database. More |
| Array of field types to nest within this Group. |
| Used as a heading in the Admin Panel and to name the generated GraphQL type. |
| Provide a custom validation function that will be executed on both the Admin Panel and the backend. More |
| If this field is top-level and nested in a config supporting Authentication, include its data in the user JWT. |
| Provide Field Hooks to control logic for this field. More details. |
| Provide Field Access Control to denote what users can see and do with this field's data. More details. |
| Restrict this field's visibility from all APIs entirely. Will still be saved to the database, but will not appear in any API or the Admin Panel. |
| Provide an object of data to be used for this field's default value. More |
| Enable localization for this field. Requires localization to be enabled in the Base config. If enabled, a separate, localized set of all data within this Group will be kept, so there is no need to specify each nested field as |
| Admin-specific configuration. More details. |
| Extension point for adding custom data (e.g. for plugins) |
| Create a top level, reusable Typescript interface & GraphQL type. |
| Override field type generation with providing a JSON schema |
| Provide |
* An asterisk denotes that a property is required.
Admin Options
The customize the appearance and behavior of the Group Field in the Admin Panel, you can use the admin
option:
The Group Field inherits all of the default options from the base Field Admin Config, plus the following additional options:
Option | Description |
---|---|
| Set this property to |
Example
collections/ExampleCollection.ts