diff --git a/uw_cfg_common.module b/uw_cfg_common.module index 10a21fb1b79a0e0450a62fd3d4b8c45582103ff8..45770f0d0b29e68ce5d7818c5bcb496c3cc14072 100644 --- a/uw_cfg_common.module +++ b/uw_cfg_common.module @@ -211,3 +211,13 @@ function uw_cfg_common_preprocess_node(&$variables) { $variables['uw_content_moderation_form'] = $render; } } + +/** + * Implements hook_form_FORM_ID_alter(). + * + * Set the default of preview mode disabled. + */ +function uw_cfg_common_form_node_type_add_form_alter(&$form, FormStateInterface $form_state, $form_id) { + $form['submission']['preview_mode']['#default_value'] = 0; + +}