Add support for hiding a links icon. Hide all object menu links' icons.

Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com>
This commit is contained in:
Roberto Rosario
2018-08-15 03:19:19 -04:00
parent d63a133852
commit c384b137a3
2 changed files with 3 additions and 1 deletions

View File

@@ -99,8 +99,10 @@
{% get_menu_links 'object menu' source=object as resolved_links %}
{% for object_navigation_links in resolved_links %}
{% with 'true' as horizontal %}
{% with 'true' as hide_icon %}
{% include 'navigation/generic_navigation.html' %}
{% endwith %}
{% endwith %}
{% endfor %}
</td>
{% endif %}

View File

@@ -13,6 +13,6 @@
{% endfor %}
href="{{ link.url }}"
>{% if link.icon %}<i class="hidden-xs hidden-sm hidden-md {{ link.icon }}"></i>{% endif %}{% if link.icon_class %}{{ link.icon_class.render }}{% endif %} {{ link.text }}{% if link.error %} - {{ link.error }}{% endif %}</a>{% if horizontal %}{% if not forloop.last %}&nbsp;{% endif %}{% endif %}
>{% if link.icon %}{% if not hide_icon %}<i class="hidden-xs hidden-sm hidden-md {{ link.icon }}"></i>{% endif %}{% endif %}{% if link.icon_class and not hide_icon %}{{ link.icon_class.render }}{% endif %} {{ link.text }}{% if link.error %} - {{ link.error }}{% endif %}</a>{% if horizontal %}{% if not forloop.last %}&nbsp;{% endif %}{% endif %}
{% endif %}
{% endif %}