Skip to content

Field conditions

Field conditions allow you to show or hide fields based on the value of another field. This is useful when you want to show a field only when a specific value is selected or provided.

To show or hide a field, you need to add the when property to the field.

{
"title": "Show or hide field",
"name": "showOrHideField",
"type": "string",
"when": {
"fieldRef": "title",
"operator": "contains",
"value": "<the value to validate>",
"caseSensitive": false
}
}
PropertyDescription
fieldRefThe name of the field to validate
operatorThe operator to use to validate the field value. See Supported operators
valueThe value to validate
caseSensitiveIf the validation should be case sensitive. Default: true
TypeValue
Equalseq
Not equalsneq
Containscontains
Not containsnotContains
Starts withstartsWith
Ends withendsWith
Greater thangt
Greater than or equalgte
Less thanlt
Less than or equallte