I wanted to change the moderation state control box input to a textarea like the image below shows. Currently the input only supports 128 characters but I believe log messages can hold much more in the database.
1 Answer
I was able to achieve it with a hook. We can add the below PHP to a custom module. Make sure to change the name of MYMODULE
below.
/**
* Implements hook_form_FORM_ID_alter().
*/
function MYMODULE_form_content_moderation_entity_moderation_form_alter(&$form, FormStateInterface $form_state, $form_id) {
// Change log message input to textarea on content moderation control boxes.
$form['revision_log'] = [
'#type' => 'textarea',
'#title' => t('Log message'),
];
}