remove redundant layout, add showSummary switch

This commit is contained in:
loikein 2023-04-25 15:45:22 +01:00
parent c5e3a781e9
commit fa6bda5448
4 changed files with 6 additions and 22 deletions

View file

@ -131,6 +131,7 @@ section {
.page-list .content-title {
margin-top: 4.2rem;
margin-bottom: 1.4rem;
}
.page-list .content-title:first-child {

View file

@ -39,8 +39,10 @@ params:
# copyrightHolder: Copyright Holder
# Show the "Powered by Hugo-Tufte and Hugo."
showPoweredBy: false
# Site wide kill switch
# Site wide kill switch for date in pages
hidedate: false
# Site wide kill switch for post summary on home page
showSummary: true
# Site wide kill switch for LaTeX support
math: true
KaTeXVersion: 0.16.4

View file

@ -1,21 +0,0 @@
{{ .Title }}
<!-- {{ template "_internal/pagination.html" }} -->
Hello this is a list of content.
{{ .TableOfContents }}
{{ $paginator := .Paginate ( (.Data.Pages.GroupByDate "2006") ) }}
<ul>
<li>PageNumber: {{ $paginator.PageNumber }}</li>
<li>URL: {{ $paginator.URL}}</li>
<li>Pages: {{ $paginator.Pages }}</li>
<li>TotalPages: {{ $paginator.TotalPages }}</li>
</ul>
{{ range $paginator.PageGroups }}
<h2>{{ .Key }}</h2>
{{ range .Pages }}
<br/>
<a href="{{ .RelPermalink }}">{{.Title}}</a>
{{ end }}
{{ end }}

View file

@ -22,8 +22,10 @@
{{ if .Description }}
<p>{{ .Description }}</p>
{{ else }}
{{ if .Site.Params.showSummary }}
<p>{{ truncate 140 .Summary }}</p>
{{ end }}
{{ end }}
{{ end }}
</section>