You are here

layout--onecol.html.twig in Drupal 10

Theme override to display a one-column layout.

Available variables:

  • content: The content for this layout.
  • attributes: HTML attributes for the layout <div>.

File

core/themes/stable9/layouts/layout_discovery/onecol/layout--onecol.html.twig
View source
  1. {#
  2. /**
  3. * @file
  4. * Theme override to display a one-column layout.
  5. *
  6. * Available variables:
  7. * - content: The content for this layout.
  8. * - attributes: HTML attributes for the layout <div>.
  9. */
  10. #}
  11. {%
  12. set classes = [
  13. 'layout',
  14. 'layout--onecol',
  15. ]
  16. %}
  17. {% if content %}
  18. <div{{ attributes.addClass(classes) }}>
  19. <div {{ region_attributes.content.addClass('layout__region', 'layout__region--content') }}>
  20. {{ content.content }}
  21. </div>
  22. </div>
  23. {% endif %}