summaryrefslogtreecommitdiffstats
path: root/layouts/partials/post-class.html
diff options
context:
space:
mode:
Diffstat (limited to 'layouts/partials/post-class.html')
-rw-r--r--layouts/partials/post-class.html8
1 files changed, 8 insertions, 0 deletions
diff --git a/layouts/partials/post-class.html b/layouts/partials/post-class.html
new file mode 100644
index 0000000..1d32a8a
--- /dev/null
+++ b/layouts/partials/post-class.html
@@ -0,0 +1,8 @@
+{{- $postClass := "page" -}}
+{{- if .IsPage -}}
+ {{- $postClass = .Type | lower | singularize -}}
+ {{- if eq $postClass "poem" -}}
+ {{- $postClass = "poem poetry" -}}
+ {{- end -}}
+{{- end -}}
+{{- $postClass -}}