{# @var ea \EasyCorp\Bundle\EasyAdminBundle\Context\AdminContext #} {% macro render_html_attributes(item) %} {% for attribute_name, attribute_value in item.htmlAttributes %} {{ attribute_name }}="{{ attribute_value|e('html') }}" {% endfor %} {% endmacro %} {% macro render_menu_badge(badge) %} {%- set badge_attributes = badge.htmlStyle ? badge.htmlAttributes|merge({style: badge.htmlStyle}) : badge.htmlAttributes -%} {{ badge.content }} {%- endmacro %} {% macro render_menu_item(item) %} {% if item.isMenuSection %} {% if item.icon is not empty %}{% endif %} {{ item.label|trans|raw }} {% if item.badge %} {{ _self.render_menu_badge(item.badge) }} {% endif %} {% else %} {% if item.icon is not empty %}{% endif %} {{ item.label|trans|raw }} {% if item.hasSubItems %}{% endif %} {% if item.hasVisibleBadge %} {{ _self.render_menu_badge(item.badge) }} {% endif %} {% endif %} {% endmacro %}