{% extends 'base.html.twig' %} {% import "macros/widgets.html.twig" as widgets %} {% block page_title %}{{ 'dashboard.title'|trans }}{% endblock %} {% block page_subtitle %}{{ 'dashboard.subtitle'|trans }}{% endblock %} {% block page_content_class %}{{ parent() }} dashboard{% endblock %} {% block main %} {% for row in widget_rows %} {% if row.title %} {{ widgets.page_header(row.title) }} {% endif %} {% set width = row.widgets|length %} {% set rawWidth = 12 / width %} {% set columnWidth = rawWidth|round(0, 'floor') %}
{% for widgetTemplate in row.widgets %}
{{ include( template_from_string( '{% import "macros/widgets.html.twig" as widgets %}' ~ widgetTemplate ) ) }}
{% endfor %}
{% endfor %} {% endblock %}