mirror of
https://github.com/BBaoVanC/bobatheme.git
synced 2024-12-22 12:13:19 -06:00
Deduplicate .Description and .Summary blocks
This commit is contained in:
parent
f77efb1843
commit
a11cc777bf
@ -23,13 +23,7 @@
|
|||||||
</h2>
|
</h2>
|
||||||
|
|
||||||
<div class="section-description">
|
<div class="section-description">
|
||||||
{{ if .Description }}
|
{{ partial "description-or-summary.html" . }}
|
||||||
<p>
|
|
||||||
{{ .Description | markdownify }}
|
|
||||||
</p>
|
|
||||||
{{ else }}
|
|
||||||
{{ .Summary }}
|
|
||||||
{{ end }}
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</a>
|
</a>
|
||||||
|
@ -23,11 +23,7 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="post-description">
|
<div class="post-description">
|
||||||
{{ with .Description }}
|
{{ partial "description-or-summary.html" . }}
|
||||||
<p>
|
|
||||||
{{ . | markdownify }}
|
|
||||||
</p>
|
|
||||||
{{ end }}
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="series-pages">
|
<div class="series-pages">
|
||||||
|
@ -14,13 +14,7 @@
|
|||||||
{{ end }}
|
{{ end }}
|
||||||
|
|
||||||
<div class="post-description">
|
<div class="post-description">
|
||||||
{{ if .Description }}
|
{{ partial "description-or-summary.html" . }}
|
||||||
<p>
|
|
||||||
{{ .Description | markdownify }}
|
|
||||||
</p>
|
|
||||||
{{ else }}
|
|
||||||
{{ .Summary }}
|
|
||||||
{{ end }}
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="readmore">
|
<div class="readmore">
|
||||||
|
5
layouts/partials/description-or-summary.html
Normal file
5
layouts/partials/description-or-summary.html
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
{{ with .Description }}
|
||||||
|
<p>{{ . | markdownify }}</p>
|
||||||
|
{{ else }}
|
||||||
|
{{ .Summary }}
|
||||||
|
{{ end }}
|
Loading…
Reference in New Issue
Block a user