Skip to content

Commit

Permalink
fix hidden pages
Browse files Browse the repository at this point in the history
  • Loading branch information
marioortizmanero committed Aug 13, 2024
1 parent 489680b commit 3e51c1f
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions layouts/_default/list.html
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,8 @@ <h1>
{{- end }}

{{- $pages := union .RegularPages .Sections }}
{{- /* CUSTOM: hidden articles */}}
{{- $pages = where $pages "Params.hidden" "!=" "true" -}}

{{- if .IsHome }}
{{- $pages = where site.RegularPages "Type" "in" site.Params.mainSections }}
Expand Down Expand Up @@ -83,8 +85,6 @@ <h1>
{{- $class = "post-entry tag-entry" }}
{{- end }}

{{- /* CUSTOM: hidden articles */}}
{{- if not .Params.hidden }}
<article class="{{ $class }}">
{{- /* CUSTOM: this adds post previews */}}
{{- $isPreviewHidden := (site.Params.cover.hidden | default site.Params.cover.hiddenInList) }}
Expand Down Expand Up @@ -126,7 +126,6 @@ <h2>
</div>
</article>
{{- end }}
{{- end }}

{{- if gt $paginator.TotalPages 1 }}
<footer class="page-footer">
Expand Down

0 comments on commit 3e51c1f

Please sign in to comment.