You are here

ds-3col-stacked-fluid.html.twig in Display Suite 8.3

Display Suite 3 column stacked template.

Available variables:

  • outer_wrapper: outer wrapper element
  • header_wrapper: wrapper element around header region
  • left_wrapper: wrapper element around left region
  • middle_wrapper: wrapper element around middle region
  • right_wrapper: wrapper element around right region
  • footer_wrapper: wrapper element around footer region
  • attributes: layout attributes
  • header_attributes: attributes for header region
  • left_attributes: attributes for left region
  • middle_attributes: attributes for middle region
  • right_attributes: attributes for right region
  • footer_attributes: attributes for footer region
  • header: content of header region
  • left: content of left region
  • middle: content of middle region
  • right: content of right region
  • footer: content of footer region

File

templates/ds-3col-stacked-fluid.html.twig
View source
  1. {#
  2. /**
  3. * @file
  4. * Display Suite 3 column stacked template.
  5. *
  6. * Available variables:
  7. * - outer_wrapper: outer wrapper element
  8. * - header_wrapper: wrapper element around header region
  9. * - left_wrapper: wrapper element around left region
  10. * - middle_wrapper: wrapper element around middle region
  11. * - right_wrapper: wrapper element around right region
  12. * - footer_wrapper: wrapper element around footer region
  13. * - attributes: layout attributes
  14. * - header_attributes: attributes for header region
  15. * - left_attributes: attributes for left region
  16. * - middle_attributes: attributes for middle region
  17. * - right_attributes: attributes for right region
  18. * - footer_attributes: attributes for footer region
  19. * - header: content of header region
  20. * - left: content of left region
  21. * - middle: content of middle region
  22. * - right: content of right region
  23. * - footer: content of footer region
  24. */
  25. #}
  26. {% set left = left|render %}
  27. {% set middle = middle|render %}
  28. {% set right = right|render %}
  29. {% if (left and not right) or (right and not left) %}
  30. {% set layout_class = 'group-one-sidebar' %}
  31. {% elseif (left and right) %}
  32. {% set layout_class = 'group-two-sidebars' %}
  33. {% elseif (left) %}
  34. {% set layout_class = 'group-sidebar-left' %}
  35. {% elseif (right) %}
  36. {% set layout_class = 'group-sidebar-right' %}
  37. {% endif %}
  38. <{{ outer_wrapper }}{{ attributes.addClass(layout_class, 'ds-3col-stacked-fluid', 'clearfix') }}>
  39. {{ title_suffix.contextual_links }}
  40. <{{ header_wrapper }}{{ header_attributes.addClass('group-header') }}>
  41. {{ header }}
  42. </{{ header_wrapper }}>
  43. {% if left %}
  44. <{{ left_wrapper }}{{ left_attributes.addClass('group-left') }}>
  45. {{ left }}
  46. </{{ left_wrapper }}>
  47. {% endif %}
  48. {% if middle %}
  49. <{{ middle_wrapper }}{{ middle_attributes.addClass('group-middle') }}>
  50. {{ middle }}
  51. </{{ middle_wrapper }}>
  52. {% endif %}
  53. {% if right %}
  54. <{{ right_wrapper }}{{ right_attributes.addClass('group-right') }}>
  55. {{ right }}
  56. </{{ right_wrapper }}>
  57. {% endif %}
  58. <{{ footer_wrapper }}{{ footer_attributes.addClass('group-footer') }}>
  59. {{ footer }}
  60. </{{ footer_wrapper }}>
  61. </{{ outer_wrapper }}>