summaryrefslogtreecommitdiff
path: root/themes/PaperMod/layouts
diff options
context:
space:
mode:
Diffstat (limited to 'themes/PaperMod/layouts')
-rw-r--r--themes/PaperMod/layouts/_default/list.html27
-rw-r--r--themes/PaperMod/layouts/partials/home_info.html6
2 files changed, 12 insertions, 21 deletions
diff --git a/themes/PaperMod/layouts/_default/list.html b/themes/PaperMod/layouts/_default/list.html
index 81aea6e..e0d0d40 100644
--- a/themes/PaperMod/layouts/_default/list.html
+++ b/themes/PaperMod/layouts/_default/list.html
@@ -30,14 +30,6 @@
</header>
{{- end }}
-{{- if .Content }}
-<div class="post-content">
- {{- if not (.Param "disableAnchoredHeadings") }}
- {{- partial "anchored_headings.html" .Content -}}
- {{- else }}{{ .Content }}{{ end }}
-</div>
-{{- end }}
-
{{- $pages := union .RegularPages .Sections }}
{{- if .IsHome }}
@@ -47,21 +39,22 @@
{{- $paginator := .Paginate $pages }}
-{{- if and .IsHome site.Params.homeInfoParams (eq $paginator.PageNumber 1) }}
+{{- if and .IsHome (eq $paginator.PageNumber 1) }}
{{- partial "home_info.html" . }}
{{- end }}
+{{- if and (not .IsHome) .Content }}
+<div class="post-content">
+ {{- if not (.Param "disableAnchoredHeadings") }}
+ {{- partial "anchored_headings.html" .Content -}}
+ {{- else }}{{ .Content }}{{ end }}
+</div>
+{{- end }}
+
{{- $term := .Data.Term }}
{{- range $index, $page := $paginator.Pages }}
-{{- $class := "post-entry" }}
-
-{{- $user_preferred := or site.Params.disableSpecial1stPost site.Params.homeInfoParams }}
-{{- if (and $.IsHome (eq $paginator.PageNumber 1) (eq $index 0) (not $user_preferred)) }}
-{{- $class = "first-entry" }}
-{{- else if $term }}
-{{- $class = "post-entry tag-entry" }}
-{{- end }}
+{{- $class := "post-entry tag-entry" }}
<article class="{{ $class }}">
{{- $isHidden := (.Param "cover.hiddenInList") | default (.Param "cover.hidden") | default false }}
diff --git a/themes/PaperMod/layouts/partials/home_info.html b/themes/PaperMod/layouts/partials/home_info.html
index 199dfb7..3d96145 100644
--- a/themes/PaperMod/layouts/partials/home_info.html
+++ b/themes/PaperMod/layouts/partials/home_info.html
@@ -1,13 +1,11 @@
-{{- with site.Params.homeInfoParams }}
<article class="first-entry home-info">
<header class="entry-header">
<h1>{{ .Title | markdownify }}</h1>
</header>
<div class="entry-content">
- {{ .Content | markdownify }}
+ {{ .Content }}
</div>
<footer class="entry-footer">
- {{ partial "social_icons.html" (dict "align" site.Params.homeInfoParams.AlignSocialIconsTo) }}
+ {{ partial "social_icons.html" }}
</footer>
</article>
-{{- end -}}