Add a .Render view for subsection summary too

This commit is contained in:
BBaoVanC 2021-11-22 02:07:48 -06:00
parent f77c61b561
commit e1e211a42a
Signed by: bbaovanc
GPG Key ID: 18089E4E3CCF1D3A
2 changed files with 14 additions and 19 deletions

View File

@ -14,20 +14,7 @@
{{ with .Sections }} {{ with .Sections }}
<div class="sections"> <div class="sections">
{{ range . }} {{ range . }}
{{ .Render "summary/section" }}
<a class="section-anchor" href="{{ .Permalink }}">
<div class="section">
<h2 class="section-title">
{{ with .Params.icon }}{{ partial "icon.html" . }}{{ end }}
{{ .Title | markdownify }}
</h2>
<div class="section-description">
{{ partial "description-or-summary.html" . }}
</div>
</div>
</a>
{{ end }} {{ end }}
</div> </div>
{{ end }} {{ end }}
@ -45,10 +32,6 @@
</div> </div>
</div> </div>
{{ if gt .Paginator.TotalPages 1 }} {{ partial "pagination.html" . }}
<div class="pagination">
{{ template "_internal/pagination.html" . }}
</div>
{{ end }}
{{ end }} {{ end }}

View File

@ -0,0 +1,12 @@
<a class="section-anchor" href="{{ .Permalink }}">
<div class="section">
<h2 class="section-title">
{{ with .Params.icon }}{{ partial "icon.html" . }}{{ end }}
{{ .Title | markdownify }}
</h2>
<div class="section-description">
{{ partial "description-or-summary.html" . }}
</div>
</div>
</a>