{% macro render_menu(menu_root,current_view) -%} {% for item in menu_root -%} {% if item.is_category() -%} {% set children = item.get_children() %} {% if children %} {% set dropdown_class = "dropdown active" if item.is_active(current_view) else "dropdown" %} {% endif %} {% else -%} {% if item.is_accessible() -%} {% set nav_link_class = "nav-link" ~ (" active" if item.is_active(current_view) else "") -%} {% endif %} {%- endif %} {%- endfor %} {% endmacro %} {% macro render_menu_user(current_user) %} {% if current_user is defined %} {% if current_user.is_authenticated %} {% else %} {% endif %} {% endif %} {% endmacro %}