improve menu template

This commit is contained in:
L3D 2022-10-28 21:57:57 +02:00
parent 5e7107dafc
commit 5cbb126c61
Signed by: l3d
GPG key ID: CD08445BFF4313D1

View file

@ -6,9 +6,12 @@
{% if not mapping.list_childs %}
<li>
<a
{% if this._path == mapping.href %} class="active"
{% endif %} {{- ' ' -}}
href="{{ mapping.href|url }}">
{% if this._path == mapping.href %} class="active" {% endif %}
{% if mapping.external | default(false) %}
href="{{ mapping.href }}" target="_blank" rel="noopener noreferrer"
{% else %}
href="{{ mapping.href | url }}"
{% endif %}>
{{- title -}}
</a>
{% else %}