storm-1.x-dev/modules/storm_content_types/modules/storm_landing_page/storm_landing_page.module
modules/storm_content_types/modules/storm_landing_page/storm_landing_page.module
<?php
/**
* @file
* Provide Storm landing page content type.
*/
use Drupal\Core\Form\FormStateInterface;
/**
* Implements hook_form_BASE_FORM_ID_alter().
*/
function storm_landing_page_form_node_form_alter(&$form, FormStateInterface $form_state, $form_id) {
/** @var Drupal\Core\Entity\FieldableEntityInterface $node */
$node = $form_state->getFormObject()->getEntity();
if ($node->getType() === 'landing_page') {
$form['layout_selection']['widget']['#default_value'] = 'default_one_col';
}
}
