mirror of
https://github.com/BBaoVanC/bobatheme.git
synced 2024-12-22 04:13:17 -06:00
Deduplicate .Description and .Summary blocks
This commit is contained in:
parent
f77efb1843
commit
a11cc777bf
@ -23,13 +23,7 @@
|
||||
</h2>
|
||||
|
||||
<div class="section-description">
|
||||
{{ if .Description }}
|
||||
<p>
|
||||
{{ .Description | markdownify }}
|
||||
</p>
|
||||
{{ else }}
|
||||
{{ .Summary }}
|
||||
{{ end }}
|
||||
{{ partial "description-or-summary.html" . }}
|
||||
</div>
|
||||
</div>
|
||||
</a>
|
||||
|
@ -23,11 +23,7 @@
|
||||
</div>
|
||||
|
||||
<div class="post-description">
|
||||
{{ with .Description }}
|
||||
<p>
|
||||
{{ . | markdownify }}
|
||||
</p>
|
||||
{{ end }}
|
||||
{{ partial "description-or-summary.html" . }}
|
||||
</div>
|
||||
|
||||
<div class="series-pages">
|
||||
|
@ -14,13 +14,7 @@
|
||||
{{ end }}
|
||||
|
||||
<div class="post-description">
|
||||
{{ if .Description }}
|
||||
<p>
|
||||
{{ .Description | markdownify }}
|
||||
</p>
|
||||
{{ else }}
|
||||
{{ .Summary }}
|
||||
{{ end }}
|
||||
{{ partial "description-or-summary.html" . }}
|
||||
</div>
|
||||
|
||||
<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