Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
U
uw_cfg_common
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
WCMS
uw_cfg_common
Commits
c3d9092b
Commit
c3d9092b
authored
4 years ago
by
Eric Bremner
Browse files
Options
Downloads
Patches
Plain Diff
ISTWCMS-4053: adding one column layout
parent
f58a06b7
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/Plugin/Layout/UwOneColumnLayout.php
+37
-0
37 additions, 0 deletions
src/Plugin/Layout/UwOneColumnLayout.php
uw_cfg_common.layouts.yml
+11
-0
11 additions, 0 deletions
uw_cfg_common.layouts.yml
with
48 additions
and
0 deletions
src/Plugin/Layout/UwOneColumnLayout.php
0 → 100644
+
37
−
0
View file @
c3d9092b
<?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
;
}
}
This diff is collapsed.
Click to expand it.
uw_cfg_common.layouts.yml
+
11
−
0
View file @
c3d9092b
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'
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment