layout--threecol-section.html.twig

Same filename in this branch
  1. 9 core/themes/stable9/layouts/layout_builder/threecol_section/layout--threecol-section.html.twig
  2. 9 core/modules/layout_builder/layouts/threecol_section/layout--threecol-section.html.twig
Same filename in other branches
  1. 8.9.x core/themes/stable/layouts/threecol_section/layout--threecol-section.html.twig
  2. 8.9.x core/modules/layout_builder/layouts/threecol_section/layout--threecol-section.html.twig
  3. 10 core/themes/stable9/layouts/layout_builder/threecol_section/layout--threecol-section.html.twig
  4. 10 core/modules/layout_builder/layouts/threecol_section/layout--threecol-section.html.twig
  5. 11.x core/themes/stable9/layouts/layout_builder/threecol_section/layout--threecol-section.html.twig
  6. 11.x core/modules/layout_builder/layouts/threecol_section/layout--threecol-section.html.twig

Theme override for a three-column layout.

Available variables:

  • in_preview: Whether the plugin is being rendered in preview mode.
  • content: The content for this layout.
  • attributes: HTML attributes for the layout <div>.

File

core/themes/stable/layouts/threecol_section/layout--threecol-section.html.twig

View source
  1. {#
  2. /**
  3. * @file
  4. * Theme override for a three-column layout.
  5. *
  6. * Available variables:
  7. * - in_preview: Whether the plugin is being rendered in preview mode.
  8. * - content: The content for this layout.
  9. * - attributes: HTML attributes for the layout <div>.
  10. */
  11. #}
  12. {% if content %}
  13. <div{{ attributes.addClass(classes) }}>
  14. {% if content.first %}
  15. <div {{ region_attributes.first.addClass('layout__region', 'layout__region--first') }}>
  16. {{ content.first }}
  17. </div>
  18. {% endif %}
  19. {% if content.second %}
  20. <div {{ region_attributes.second.addClass('layout__region', 'layout__region--second') }}>
  21. {{ content.second }}
  22. </div>
  23. {% endif %}
  24. {% if content.third %}
  25. <div {{ region_attributes.third.addClass('layout__region', 'layout__region--third') }}>
  26. {{ content.third }}
  27. </div>
  28. {% endif %}
  29. </div>
  30. {% endif %}

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