layout ok

This commit is contained in:
naoufal zerai
2022-08-18 23:23:50 -04:00
parent 5dba10766d
commit 2e68ef8b45
40 changed files with 56 additions and 1388 deletions

View File

@@ -1,12 +1,6 @@
{{- $nav := . -}}
{{- if or $nav.showCategories $nav.showTags $nav.custom -}}
<div class="nav wrap"><nav class="nav">
{{- if $nav.showCategories -}}
<a class="nav item" href="{{- `/categories/` | relLangURL -}}">{{- T "Categories" -}}</a>
{{- end -}}
{{- if $nav.showTags -}}
<a class="nav item" href="{{- `/tags/` | relLangURL -}}">{{- T "Tags" -}}</a>
{{- end -}}
{{- range $nav.custom -}}
{{- $url := replace .url "#" "%23" -}}
{{- $url = replace $url "." "%2e" -}}
@@ -16,5 +10,11 @@
{{- if strings.HasPrefix $url "http" -}}target="_blank" rel="noopener noreferrer"
{{- end -}}>{{- .title -}}</a>
{{- end -}}
{{- if $nav.showCategories -}}
<a class="nav item" href="{{- `/categories/` | relLangURL -}}">{{- T "Categories" -}}</a>
{{- end -}}
{{- if $nav.showTags -}}
<a class="nav item" href="{{- `/tags/` | relLangURL -}}">{{- T "Tags" -}}</a>
{{- end -}}
</nav></div>
{{- end -}}