Skip to content
Snippets Groups Projects
Commit c3d9092b authored by Eric Bremner's avatar Eric Bremner
Browse files

ISTWCMS-4053: adding one column layout

parent f58a06b7
No related branches found
No related tags found
No related merge requests found
<?php
namespace Drupal\uw_cfg_common\Plugin\Layout;
use Drupal\Core\Form\FormStateInterface;
use Drupal\Core\Layout\LayoutDefault;
use Drupal\Core\Plugin\PluginFormInterface;
/**
* A UW one column layout.
*
* @Layout(
* id = "uw_one_column",
* label = @Translation("One column"),
* category = @Translation("UW layouts"),
* template = "templates/layout/layout--uwonecol",
* regions = {
* "first" = {
* "label" = @Translation("Column 1"),
* },
* }
* )
*/
class UwOneColumnLayout extends LayoutDefault implements PluginFormInterface {
/**
* {@inheritdoc}
*/
public function build(array $regions) {
// Build the render array as usual.
$build = parent::build($regions);
return $build;
}
}
uw_one_column:
label: 'UW One column'
category: 'UW layouts'
class: '\Drupal\uw_cfg_common\Plugin\Layout\UwOneColumnLayout'
template: uw_fdsu_theme_resp/templates/layout/layout--uwonecol
default_region: first
regions:
first:
label: One
icon_map:
- [first]
uw_two_column:
label: 'UW Two columns'
category: 'UW layouts'
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment