hugo-theme-even/layouts/partials/post/copyright.html

31 lines
1.3 KiB
HTML
Raw Normal View History

{{ if or .Params.contentCopyright (and .Site.Params.contentCopyright (ne .Params.contentCopyright false)) }}
2017-08-27 14:38:42 +00:00
{{ $lang := .Site.Data.even.default -}}
<div class="post-copyright">
<p class="copyright-item">
<span class="item-title">{{ $lang.copyright.author }}</span>
<span class="item-content">{{ if .Params.author }}{{ .Params.author | safeHTML }}{{ else }}{{ .Site.Author.name | safeHTML }}{{ end }}</span>
2017-08-27 14:38:42 +00:00
</p>
<p class="copyright-item">
<span class="item-title">{{ $lang.copyright.lastMod }}</span>
<span class="item-content">{{ .Lastmod.Format (.Site.Params.dateFormatToUse | default "2006-01-02") }}</span>
2017-08-27 14:38:42 +00:00
</p>
{{ if $.Site.Params.linkToMarkDown -}}
{{ with $.OutputFormats.Get "markdown" -}}
<p class="copyright-item">
<span class="item-title">{{ $lang.copyright.markdown }}</span>
<span class="item-content"><a class="link-to-markdown" href="{{ .Permalink }}" target="_blank">{{ $lang.posts.seeMarkDown }}</a></span>
2017-08-27 14:38:42 +00:00
</p>
{{- end }}
{{- end }}
<p class="copyright-item">
<span class="item-title">{{ $lang.copyright.license }}</span>
<span class="item-content">
{{- if .Params.contentCopyright -}}
{{ .Params.contentCopyright | safeHTML }}
{{- else -}}
{{ .Site.Params.contentCopyright | safeHTML }}
{{- end -}}
</span>
2017-08-27 14:38:42 +00:00
</p>
</div>
{{- end }}