Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/uPagge/uBlogger.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoruPagge <upagge@mail.ru>2020-11-30 12:31:51 +0300
committeruPagge <upagge@mail.ru>2020-11-30 12:31:51 +0300
commit6b8831850f26e2b9d2799f2d1563b1778d8f8cc7 (patch)
tree73c470b7417dae4f98f23592503fbf68431e603c /layouts/posts
parent7326a20130a3fcda2325fc973b5d74ae770c9733 (diff)
Добавлен новый функционал, комментарий автора
Diffstat (limited to 'layouts/posts')
-rw-r--r--layouts/posts/single.html13
1 files changed, 13 insertions, 0 deletions
diff --git a/layouts/posts/single.html b/layouts/posts/single.html
index 39522c1..e996e40 100644
--- a/layouts/posts/single.html
+++ b/layouts/posts/single.html
@@ -108,6 +108,19 @@
{{- $comment := .Site.Params.Page.Comment -}}
{{- if $comment.enable -}}
<div class="page single comments">
+ {{- $authorComment := $params.authorComment -}}
+ {{ $author := index .Site.Data.authors (.Params.author | default "default") }}
+ {{- if $author -}}
+ {{- if $authorComment -}}
+ <div class="author-comment">
+ <div class="author-avatar" style="float: left"><a href="{{ with $author.site }} {{- . | safeHTML -}}{{ end }}" target="_blank"><img alt="" src="{{ with $author.avatar }} {{- . | safeHTML -}}{{ end }}" border="0"></a></div>
+ <div class="author-info" style="width: 80%;">
+ <div class="name">{{ $author.name }}</div>
+ <div class="author-comment-text">{{ $authorComment }}</span></div>
+ </div>
+ </div>
+ {{- end -}}
+ {{- end -}}
{{- /* Comment */ -}}
{{- partial "comment.html" . -}}
</div>