Commit b45b1c90 authored by ∞'s avatar 💻

Indent sub menus

parent 6c77c941
......@@ -26,6 +26,9 @@ header, main, footer
.sidenav-trigger
display: none
ul.sidenav .collapsible-body ul li a
padding-left: 3rem !important
@media only screen and (max-width : 992px)
header, main, footer
padding-left: 0
......
<ul id="slide-out" class="sidenav sidenav-fixed">
<li class="no-padding {% if request.path == crudlfap_site.views['home'].url %}active{% endif %}"><a href="{{ crudlfap_site.views['home'].url }}">{% if crudlfap_site.views['home'].material_icon %}<i class="material-icons">{{ crudlfap_site.views['home'].material_icon }}</i>{% endif %}{{ _('Home') }}</a></li>
<li class="no-padding">
<ul class="collapsible collapsible-accordion">
{% for app, routers in crudlfap_site.get_app_menus('main', request).items() %}
{% for router in routers %}
{% set views = router.get_menu('model', request) %}
......@@ -21,33 +19,35 @@
>{% if router.material_icon %}<i class="material-icons">{{ router.material_icon }}</i>{% endif %}{{ router.model._meta.verbose_name_plural.capitalize() }}</a>
</li>
{% else %}
<li class="{% if router == view.router %}active{% endif %}">
<a class="collapsible-header waves-effect waves-teal">{% if router.material_icon %}<i class="material-icons">{{ router.material_icon }}</i>{% endif %} {{ router.model._meta.verbose_name_plural.capitalize() }}</a>
<div class="collapsible-body">
<ul>
{% for v in router.get_menu('model', request) %}
<li>
<a
class="waves-effect"
href="{{ v.url }}"
title="{% if v.title_link %}{{ v.title_link }}{% endif %}"
{%- for key, value in (v.link_attributes|default({})).items() %}
{{ key }}="{{ value.replace('"', '\\"') }}"
{%- endfor %}
{%- if not v.turbolinks|default(True) %}
data-turbolinks="false"
{%- endif %}
>{% if v.material_icon %}<i class="material-icons">{{ v.material_icon }}</i>{% endif %}{{ v.title_menu.capitalize() }}</a>
</li>
{% endfor %}
</ul>
</div>
</li>
<li class="no-padding">
<ul class="collapsible collapsible-accordion">
<li class="{% if router == view.router %}active{% endif %}">
<a class="collapsible-header waves-effect waves-teal">{% if router.material_icon %}<i class="material-icons">{{ router.material_icon }}</i>{% endif %} {{ router.model._meta.verbose_name_plural.capitalize() }}</a>
<div class="collapsible-body">
<ul>
{% for v in router.get_menu('model', request) %}
<li>
<a
class="waves-effect"
href="{{ v.url }}"
title="{% if v.title_link %}{{ v.title_link }}{% endif %}"
{%- for key, value in (v.link_attributes|default({})).items() %}
{{ key }}="{{ value.replace('"', '\\"') }}"
{%- endfor %}
{%- if not v.turbolinks|default(True) %}
data-turbolinks="false"
{%- endif %}
>{% if v.material_icon %}<i class="material-icons">{{ v.material_icon }}</i>{% endif %}{{ v.title_menu.capitalize() }}</a>
</li>
{% endfor %}
</ul>
</div>
</li>
</ul>
</li>
{% endif %}
{% endfor %}
{% endfor %}
</ul>
</li>
{% with liclass="no-padding" %}
{% include 'crudlfap/_menu_auth.html' %}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment