function MultiWidthLayoutBase::build
Same name in other branches
- 9 core/modules/layout_builder/src/Plugin/Layout/MultiWidthLayoutBase.php \Drupal\layout_builder\Plugin\Layout\MultiWidthLayoutBase::build()
- 8.9.x core/modules/layout_builder/src/Plugin/Layout/MultiWidthLayoutBase.php \Drupal\layout_builder\Plugin\Layout\MultiWidthLayoutBase::build()
- 10 core/modules/layout_builder/src/Plugin/Layout/MultiWidthLayoutBase.php \Drupal\layout_builder\Plugin\Layout\MultiWidthLayoutBase::build()
Overrides LayoutDefault::build
File
-
core/
modules/ layout_builder/ src/ Plugin/ Layout/ MultiWidthLayoutBase.php, line 49
Class
- MultiWidthLayoutBase
- Base class of layouts with configurable widths.
Namespace
Drupal\layout_builder\Plugin\LayoutCode
public function build(array $regions) {
$build = parent::build($regions);
$build['#attributes']['class'] = [
'layout',
$this->getPluginDefinition()
->getTemplate(),
$this->getPluginDefinition()
->getTemplate() . '--' . $this->configuration['column_widths'],
];
return $build;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.