Pull merge.
[yaffs-website] / vendor / chi-teck / drupal-code-generator / templates / d8 / _layout / template.twig
1 {{ '{' }}#
2 /**
3  * @file
4  * Default theme implementation to display {{ layout_name|lower }} layout.
5  *
6  * Available variables:
7  * - content: The content for this layout.
8  * - attributes: HTML attributes for the layout wrapper.
9  *
10  * @ingroup themeable
11  */
12 #{{ '}' }}
13 {{ '{' }}%
14   set classes = [
15     'layout',
16     'layout--{{ layout_machine_name|u2h }}',
17   ]
18 %{{ '}' }}
19 {% verbatim %}
20 {% if content %}
21   <div{{ attributes.addClass(classes) }}>
22
23     {% if content.main %}
24       <div {{ region_attributes.main.addClass('layout__region', 'layout__region--main') }}>
25         {{ content.main }}
26       </div>
27     {% endif %}
28
29     {% if content.sidebar %}
30       <div {{ region_attributes.sidebar.addClass('layout__region', 'layout__region--sidebar') }}>
31         {{ content.sidebar }}
32       </div>
33     {% endif %}
34
35   </div>
36 {% endif %}
37 {% endverbatim %}