more cleanup

This commit is contained in:
Luke Smith
2022-07-11 09:15:28 -04:00
parent 43ff3f0921
commit 58e91fcee3
5 changed files with 51 additions and 53 deletions

View File

@@ -6,7 +6,7 @@
{{- range $k, $v := .Params.tags -}}
{{- $url := printf "tags/%s" (. | urlize | lower) -}}
<a id="tag_{{ . | lower }}" href="{{ $url | absURL }}">{{ . | title }}</a>
{{- if lt $k (sub $tagsLen 1) }}&middot;{{ end -}}
{{- if lt $k (sub $tagsLen 1) }} &middot; {{ end -}}
{{- end -}}
</div>
{{- end -}}
@@ -14,7 +14,7 @@
</main>
<footer>
<a href="{{ .Site.BaseURL }}">{{ .Site.BaseURL }}</a><br>
{{ if .Site.Params.showrss }}<a href="/index.xml"><img src="/pix/rss.svg" style="max-height:.9em;display:inline" alt=""> Subscribe via RSS for Updates.</a>{{ end }}
{{ if .Site.Params.showrss }}<a href="/index.xml"><img src="/rss.svg" style="max-height:.9em;display:inline" alt=""> Subscribe via RSS for Updates.</a>{{ end }}
</footer>
</body>
</html>

View File

@@ -9,11 +9,14 @@
{{ with .Site.Params.favicon }}<link rel="icon" href="{{ . }}">
{{ end -}}
<meta name="description" content="{{ with .Params.description }}{{ . }}{{ else }}{{ .Summary }}{{ end }}">
<meta name="keywords" content="{{ with .Params.tags }}{{ delimit . ", " }}{{ end }}">
{{ if isset .Params "tags" }}<meta name="keywords" content="{{ with .Params.tags }}{{ delimit . ", " }}{{ end }}">
{{ end -}}
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="robots" content="index, follow">
<meta charset="utf-8">
</head>
<body>
{{- partial "nav.html" . -}}
{{ if .Site.Menus.main -}}
{{ partial "nav.html" . }}
{{ end -}}
<main>

View File

@@ -1,10 +1,8 @@
{{- if .Site.Menus.main }}
<nav>
<ul>
{{- $sec := .Page.Section }}{{ $file := .File.TranslationBaseName -}}
{{ range.Site.Menus.main.ByWeight }}{{ $base := path.Base .URL }}
<a {{ if or ( eq $sec $base ) ( eq $file $base ) ( and (eq $sec "") ( eq $file "_index") (eq $base "/") ) }}class="menuactive" {{ end }}href="{{ .URL }}"><li><span class=pre>{{ .Pre }}</span><span class=menuname>{{ .Name }}</span></li></a>
<li><a {{ if or ( eq $sec $base ) ( eq $file $base ) ( and (eq $sec "") ( eq $file "_index") (eq $base "/") ) }}class="menuactive" {{ end }}href="{{ .URL }}"><span class=pre>{{ .Pre }}</span><span class=menuname>{{ .Name }}</span></a></li>
{{- end }}
</ul>
</nav>
{{- end }}