Add active style to theme switcher buttons, style tweaks
This commit is contained in:
@ -7,13 +7,19 @@
|
||||
{%- for link in config.extra.footer.links %}
|
||||
{%- if link.url is matching('https?://') %}
|
||||
<li>
|
||||
<a href="{{ link.url }}" rel="{{ rel_attributes }}">
|
||||
<a href="{{ link.url }}" rel="{{ rel_attributes }}"
|
||||
{%- if current_url | default(value='/') | trim_end_matches(pat='/') | safe == link.url | trim_end_matches(pat='/') | safe -%}
|
||||
class="active"
|
||||
{%- endif -%}>
|
||||
{{- macros_translate::translate(key=link.name, default=link.name, language_strings=language_strings) -}}
|
||||
</a>
|
||||
</li>
|
||||
{%- else %}
|
||||
<li>
|
||||
<a href="{{ get_url(path=link.url, lang=lang)}}">
|
||||
<a href="{{ get_url(path=link.url, lang=lang)}}"
|
||||
{%- if current_url | default(value='/') | trim_end_matches(pat='/') | safe == get_url(path=link.url, lang=lang) | trim_end_matches(pat='/') | safe -%}
|
||||
class="active"
|
||||
{%- endif -%}>
|
||||
{{- macros_translate::translate(key=link.name, default=link.name, language_strings=language_strings) -}}
|
||||
</a>
|
||||
</li>
|
||||
|
Reference in New Issue
Block a user