| 123456789101112131415161718192021222324252627282930313233343536373839404142 |
- {{ $page := .Page -}}
- {{ with .Site.Params.copyright -}}
- {{ $fromYear := "" -}}
- {{ $toYear := "" -}}
- {{ $authors := "" -}}
- {{ if reflect.IsMap . -}}
- {{ $fromYear = .from_year -}}
- {{ $toYear = .to_year -}}
- {{ $authors = .authors -}}
- {{ else -}}
- {{ $authors = . -}}
- {{ end -}}
- <span class="td-footer__copyright">©
- {{ with $fromYear -}}
- {{ . }}–
- {{- end -}}
- {{ $toYear | default now.Year }}
- <span class="td-footer__authors">
- {{- $authors
- | default (printf "%s Authors" ($.Site.Title | default "Site"))
- | $page.RenderString -}}
- </span>
- {{- /* Trim WS */ -}}
- </span>
- {{- with T "footer_all_rights_reserved" -}}
- <span class="td-footer__all_rights_reserved">
- {{- . -}}
- </span>
- {{- end }}
- {{- else -}}
- {{ with .Site.Copyright -}}
- {{/* For historical reasons we process this as HTML rather than markdown. */ -}}
- <span class="td-footer__copyright">
- {{- . | safeHTML -}}
- </span>
- {{- end -}}
- {{ end -}}
|