In the case we have a custom field like this:
function custom_wysiwyg(String $name,
bool $isRequired,
bool $hasQuicktags,
int $rows,
int $max_length,
String $tags_allowed,
String $formats_allowed
) {
return [
'name' => $name,
'id' => strtolower($name),
'type' => 'wysiwyg',
'required' => $isRequired,
'options' => [
'textarea_rows' => $rows,
'tinymce' => [
'block_formats' => $formats_allowed,
'toolbar1' => $tags_allowed,
],
'quicktags' => $hasQuicktags,
],
];
}
The validation would work? I did not understand the part of it not working with the Visual tab.