function LayoutBuilder::prepareLayout

Same name in other branches
  1. 9 core/modules/layout_builder/src/Element/LayoutBuilder.php \Drupal\layout_builder\Element\LayoutBuilder::prepareLayout()
  2. 8.9.x core/modules/layout_builder/src/Element/LayoutBuilder.php \Drupal\layout_builder\Element\LayoutBuilder::prepareLayout()
  3. 11.x core/modules/layout_builder/src/Element/LayoutBuilder.php \Drupal\layout_builder\Element\LayoutBuilder::prepareLayout()

Prepares a layout for use in the UI.

Parameters

\Drupal\layout_builder\SectionStorageInterface $section_storage: The section storage.

1 call to LayoutBuilder::prepareLayout()
LayoutBuilder::layout in core/modules/layout_builder/src/Element/LayoutBuilder.php
Renders the Layout UI.

File

core/modules/layout_builder/src/Element/LayoutBuilder.php, line 136

Class

LayoutBuilder
Defines a render element for building the Layout Builder UI.

Namespace

Drupal\layout_builder\Element

Code

protected function prepareLayout(SectionStorageInterface $section_storage) {
    $event = new PrepareLayoutEvent($section_storage);
    $this->eventDispatcher
        ->dispatch($event, LayoutBuilderEvents::PREPARE_LAYOUT);
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.