---
url: /documentation/input-types/visualtext.md
description: >-
  Configure a WYSIWYG rich-text input with length validation and conditional
  visibility.
---

# Visual Text Input

A WYSIWYG text editor input.

```js
{
  input: {
    type: 'visualtext' // [!code focus]
  }
}
```

## Input Options

| Option | Values | Default | Description |
| - | - | - | - |
| `required` | `boolean` | `false` | Whether filling the field is mandatory. |
| `minLength` | `number` | - | Minimum length for the content to be valid. |
| `maxLength` | `number` | - | Maximum length for the content. |

## Conditions

The `visualtext` input type supports the following conditions for [dynamic visibility](/documentation/concepts/elements/definition#dynamic-visibility):

| Condition | Payload | Description |
| - | - | - |
| `isEmpty` | `boolean`defaults to `true` | Checks whether the input is empty or not. |
| `equals` | `string` | Checks whether the input value equals the `payload` string. |
| `matches` | `RegExp` | Checks whether the input value matches the `payload` regular expression. |
