feat: support hidden post

This commit is contained in:
SerKo 2023-05-12 15:44:41 +08:00
parent 3f1d91875c
commit b7b0699b3e
1 changed files with 10 additions and 8 deletions

View File

@ -8,14 +8,16 @@
</article>
<ul>
{{- range where site.RegularPages "Type" "in" site.Params.mainSections }}
<li>
<div class="mb:16 py:24 f:fade-30 f:fade-10:hover transition:150ms;ease-in">
<a class="f:24 font:semibold" href="{{ .Permalink }}">
<div>{{ .Title }}</div>
</a>
<div class="mt:12 f:fade-70"><time>{{ .Date | time.Format (":date_medium") }}</time></div>
</div>
</li>
{{- if not .Params.hidden }}
<li>
<div class="mb:16 py:24 f:fade-30 f:fade-10:hover transition:150ms;ease-in">
<a class="f:24 font:semibold" href="{{ .Permalink }}">
<div>{{ .Title }}</div>
</a>
<div class="mt:12 f:fade-70"><time>{{ .Date | time.Format (":date_medium") }}</time></div>
</div>
</li>
{{- end }}
{{- end }}
</ul>
</div>