From 882af0656327476b523e0d6538b29ae9ad6eda28 Mon Sep 17 00:00:00 2001 From: Serghei Iakovlev Date: Tue, 31 May 2022 00:19:18 +0200 Subject: Mior reformatting of posts layout --- layouts/_default/single.html | 17 ++++++++++++++--- layouts/dramas/single.html | 14 +++++++++++--- layouts/narratives/single.html | 14 +++++++++++--- layouts/page/single.html | 10 +++++++--- layouts/partials/post-meta/author.html | 3 +++ layouts/partials/post-meta/date.html | 21 +++++++++++---------- layouts/poems/single.html | 14 +++++++++++--- 7 files changed, 68 insertions(+), 25 deletions(-) create mode 100644 layouts/partials/post-meta/author.html (limited to 'layouts') diff --git a/layouts/_default/single.html b/layouts/_default/single.html index 90bb5b5..6b2c851 100644 --- a/layouts/_default/single.html +++ b/layouts/_default/single.html @@ -1,6 +1,17 @@ {{ define "main" }} -
-

{{ .Params.caption | default .Title }}

- {{ .Content }} +
+
+

+ {{ .Params.caption | default .Title }} +

+
+ + + +
+ {{ .Content }} +
{{ end }} diff --git a/layouts/dramas/single.html b/layouts/dramas/single.html index 865a07b..e47e531 100644 --- a/layouts/dramas/single.html +++ b/layouts/dramas/single.html @@ -1,7 +1,15 @@ {{ define "main" }} -
-

{{ .Params.caption | default .Title }}

- {{ with .Params.author }}{{ end }} +
+
+

+ {{ .Params.caption | default .Title }} +

+
+ + + {{ .Content }}
{{ end }} diff --git a/layouts/narratives/single.html b/layouts/narratives/single.html index e3dc1b9..c941bc2 100644 --- a/layouts/narratives/single.html +++ b/layouts/narratives/single.html @@ -1,7 +1,15 @@ {{ define "main" }} -
-

{{ .Params.caption | default .Title }}

- {{ with .Params.author }}{{ end }} +
+
+

+ {{ .Params.caption | default .Title }} +

+
+ + + {{ .Content }}
{{ end }} diff --git a/layouts/page/single.html b/layouts/page/single.html index d31cbe7..fef0cf5 100644 --- a/layouts/page/single.html +++ b/layouts/page/single.html @@ -1,7 +1,11 @@ {{ define "main" }} -
-

{{ .Params.caption | default .Title }}

+
+
+

+ {{ .Params.caption | default .Title }} +

+
+ {{ .Content }}
{{ end }} - 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 }} + {{ i18n "by" . }} +{{ 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 }} - -{{- if ne .Date .Lastmod }} - -{{- end -}} -{{- end }} +{{ if not .Date.IsZero }} + + + {{ if ne .Date .Lastmod }} + + {{ end }} +{{ end }} diff --git a/layouts/poems/single.html b/layouts/poems/single.html index d61a185..58038d1 100644 --- a/layouts/poems/single.html +++ b/layouts/poems/single.html @@ -1,7 +1,15 @@ {{ define "main" }} -
-

{{ .Params.caption | default .Title }}

- {{ with .Params.author }}{{ end }} +
+
+

+ {{ .Params.caption | default .Title }} +

+
+ + + {{ .Content }}
{{ end }} -- cgit v1.2.3