Support reprint statement (#89)

This commit is contained in:
Alfred 2020-08-20 00:41:09 +08:00 committed by GitHub
parent 402c34e9bb
commit a78d0ea2ff
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 16 additions and 4 deletions

View File

@ -36,6 +36,8 @@ post:
copyright:
author: Post author
link: Post link
post_author: Written by
post_link: This article originally appeared on
license_title: Copyright Notice
license_content: "All articles in this blog are licensed under %s unless stating additionally."

View File

@ -4,12 +4,22 @@
<div class="post-copyright">
<ul>
<li class="post-copyright-author">
{%- if page.author %}
<strong>{{ __('post.copyright.post_author') + __('symbol.colon') }} </strong>
{{- page.author }}
{%- elif author %}
<strong>{{ __('post.copyright.author') + __('symbol.colon') }} </strong>
{{- page.author or author }}
{{- author }}
{%- endif %}
</li>
<li class="post-copyright-link">
{%- if page.post_link %}
<strong>{{ __('post.copyright.post_link') + __('symbol.colon') }}</strong>
{{ next_url(page.post_link, page.post_link, {title: page.title}) }}
{%- else %}
<strong>{{ __('post.copyright.link') + __('symbol.colon') }}</strong>
{{ next_url(page.permalink, page.permalink, {title: page.title}) }}
{%- endif %}
</li>
<li class="post-copyright-license">
<strong>{{ __('post.copyright.license_title') + __('symbol.colon') }} </strong>