mirror of
https://github.com/BBaoVanC/bobatheme.git
synced 2025-09-02 01:37:33 -05:00
Move article.page wrapping to summary.html instead of at list template
I am trying to make various templates and partials act more like self-contained components. This is in preparation for #113.
This commit is contained in:
@@ -1,16 +1,18 @@
|
||||
<h2 class="page-title">
|
||||
<a href="{{ .Permalink }}">{{ .Title | markdownify }}</a>
|
||||
{{ if .Draft }}{{ partial "icon.html" "write" }}{{ end }}
|
||||
</h2>
|
||||
<article class="page">
|
||||
<h2 class="page-title">
|
||||
<a href="{{ .Permalink }}">{{ .Title | markdownify }}</a>
|
||||
{{ if .Draft }}{{ partial "icon.html" "write" }}{{ end }}
|
||||
</h2>
|
||||
|
||||
{{ partial "page-metadata/author.html" . }}
|
||||
{{ partial "page-metadata/author.html" . }}
|
||||
|
||||
{{ with .Summary }}
|
||||
<div class="page-description">
|
||||
{{ . }}
|
||||
{{ with .Summary }}
|
||||
<div class="page-description">
|
||||
{{ . }}
|
||||
</div>
|
||||
{{ end }}
|
||||
|
||||
<div class="readmore">
|
||||
<a href="{{ .Permalink }}">{{ i18n "read_more" }} →</a>
|
||||
</div>
|
||||
{{ end }}
|
||||
|
||||
<div class="readmore">
|
||||
<a href="{{ .Permalink }}">{{ i18n "read_more" }} →</a>
|
||||
</div>
|
||||
</article>
|
||||
|
@@ -11,9 +11,7 @@
|
||||
<div class="page-list">
|
||||
{{ with .Paginator.Pages }}
|
||||
{{ range . }}
|
||||
<article class="page">
|
||||
{{ .Render "summary" }}
|
||||
</article>
|
||||
{{ .Render "summary" }}
|
||||
{{ end }}
|
||||
{{ else }}
|
||||
<div>
|
||||
|
Reference in New Issue
Block a user