public function LayoutParagraphsPlugin::validateConfigurationForm in Layout Paragraphs 1.0.x
File
- src/
Plugin/ paragraphs/ Behavior/ LayoutParagraphsPlugin.php, line 99
Class
- LayoutParagraphsPlugin
- Provides a way to define grid based layouts.
Namespace
Drupal\layout_paragraphs\Plugin\paragraphs\BehaviorCode
public function validateConfigurationForm(array &$form, FormStateInterface $form_state) {
if (empty($form_state
->getValue('available_layouts'))) {
$form_state
->setErrorByName('available_layouts', $this
->t('You must select at least one layout.'));
}
}