aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorolOwOlo <26087907+olOwOlo@users.noreply.github.com>2017-08-30 22:32:17 +0800
committerolOwOlo <26087907+olOwOlo@users.noreply.github.com>2017-08-30 22:32:17 +0800
commit553d15e15f3affdfda48686469309e01f2b994f7 (patch)
treeaa246f7aa92a6deb8117dbeadbb4e1895108f650
parentf24f847bacf0e4aeb2c45ec89fd24aa99dfa77da (diff)
refactor: copyright -> contentCopyright
-rw-r--r--archetypes/default.md4
-rw-r--r--layouts/partials/footer.html2
-rw-r--r--layouts/partials/post/copyright.html8
3 files changed, 7 insertions, 7 deletions
diff --git a/archetypes/default.md b/archetypes/default.md
index 7464e07..4df8284 100644
--- a/archetypes/default.md
+++ b/archetypes/default.md
@@ -12,8 +12,8 @@ author: ""
# you can close something for this content if you open it in config.toml.
comment: false
toc: false
-# you can define another copyright. e.g. copyright: "This is an another copyright."
-copyright: false
+# you can define another contentCopyright. e.g. contentCopyright: "This is an another copyright."
+contentCopyright: false
reward: false
mathjax: false
---
diff --git a/layouts/partials/footer.html b/layouts/partials/footer.html
index 6c98f51..4004d7b 100644
--- a/layouts/partials/footer.html
+++ b/layouts/partials/footer.html
@@ -32,6 +32,6 @@
<span class="heart">
<i class="iconfont icon-heart"></i>
</span>
- <span class="author">{{ .Site.Author.name }}</span>
+ <span class="author">{{if .Site.Copyright }}{{ .Site.Copyright | safeHTML }}{{ else }}{{ .Site.Author.name | safeHTML }}{{ end }}</span>
</span>
</div> \ No newline at end of file
diff --git a/layouts/partials/post/copyright.html b/layouts/partials/post/copyright.html
index 6908b10..0768d36 100644
--- a/layouts/partials/post/copyright.html
+++ b/layouts/partials/post/copyright.html
@@ -1,4 +1,4 @@
-{{ if and .Site.Copyright (ne .Params.copyright false) }}
+{{ if and .Site.Params.contentCopyright (ne .Params.contentCopyright false) }}
{{ $lang := .Site.Data.even.default -}}
<div class="post-copyright">
<p class="copyright-item">
@@ -23,10 +23,10 @@
{{- end }}
<p class="copyright-item lincese">
<span class="item-title">{{ $lang.copyright.lincese }}: </span>
- {{ if .Params.copyright -}}
- {{ .Params.copyright | safeHTML }}
+ {{ if .Params.contentCopyright -}}
+ {{ .Params.contentCopyright | safeHTML }}
{{ else -}}
- {{ .Site.Copyright | safeHTML }}
+ {{ .Site.Params.contentCopyright | safeHTML }}
{{- end }}
</p>
</div>