feat(index): 2023 & footer links

This commit is contained in:
Pavel Korytov 2023-01-01 17:56:40 +03:00
parent 5f0178d5ff
commit e1782cd204
2 changed files with 18 additions and 6 deletions

View file

@ -9,9 +9,16 @@ staticDir = ["static"]
favicon = "favicon.ico" # path to a .ico to use as favicon
# logo = "logo.svg"
[params.footer]
text = "Pavel Korytov, 2022"
license = "Licensed under CC-BY 4.0"
text = "Pavel Korytov, 2023"
license = ""
licenseURL = "https://creativecommons.org/licenses/by/4.0/legalcode"
[[params.footer.links]]
text = "Licensed under CC-BY 4.0"
url = "https://creativecommons.org/licenses/by/4.0/legalcode"
[[params.footer.links]]
text = "Uses Plausible Analytics"
url = "https://plausible.io/"
mainSections = ['posts']
[permalinks]

View file

@ -7,11 +7,16 @@
</div>
{{ with .Site.Params.footer }}
<div class="container text-center">
<a href="{{ .url | absURL }}" title="{{ .text }}"><small>{{ .text | safeHTML }}</small></a>
{{ if .license }}
{{ if .links }}
{{ range $i, $item := .links }}
<a href="{{ $item.url }}" title="{{ $item.text }}"><small>{{ $item.text }}</small></a>
{{ if not (eq $i (sub (len $.Site.Params.footer.links) 1)) }}
|
{{ end }}
{{ end }}
<br>
<a href="{{ .licenseURL }}" title="{{ .license }}"><small>{{ .license }}</small></a>
{{ end }}
<a href="{{ .url | absURL }}" title="{{ .text }}"><small>{{ .text | safeHTML }}</small></a>
</div>
{{ end }}
</div>