diff options
Diffstat (limited to 'layouts/partials')
| -rw-r--r-- | layouts/partials/post-meta/author.html | 3 | ||||
| -rw-r--r-- | layouts/partials/post-meta/date.html | 21 |
2 files changed, 14 insertions, 10 deletions
diff --git a/layouts/partials/post-meta/author.html b/layouts/partials/post-meta/author.html new file mode 100644 index 0000000..1b56004 --- /dev/null +++ b/layouts/partials/post-meta/author.html @@ -0,0 +1,3 @@ +{{ with .Params.author }} + <span class="author">{{ i18n "by" . }}</span> +{{ end }} diff --git a/layouts/partials/post-meta/date.html b/layouts/partials/post-meta/date.html index 92401e7..04a814a 100644 --- a/layouts/partials/post-meta/date.html +++ b/layouts/partials/post-meta/date.html @@ -1,10 +1,11 @@ -{{- if not .Date.IsZero }} -<time datetime="{{ .Date.Format "2006-01-02T15:04:05Z07:00" }}"> - {{- .Date | time.Format (site.Params.dateformat | default "January 02, 2006") -}} -</time> -{{- if ne .Date .Lastmod }} -<time datetime="{{ .Lastmod.Format "2006-01-02T15:04:05Z07:00" }}"> - ({{ i18n "updated_at" }} {{ .Lastmod | time.Format (site.Params.dateformat | default "January 02, 2006") -}}) -</time> -{{- end -}} -{{- end }} +{{ if not .Date.IsZero }} + <time datetime="{{ .Date.Format "2006-01-02T15:04:05Z07:00" }}"> + {{ .Date | time.Format (site.Params.dateformat | default "January 02, 2006") }} + </time> + + {{ if ne .Date .Lastmod }} + <time datetime="{{ .Lastmod.Format "2006-01-02T15:04:05Z07:00" }}"> + ({{ i18n "updated_at" }} {{ .Lastmod | time.Format (site.Params.dateformat | default "January 02, 2006") }}) + </time> + {{ end }} +{{ end }} |
