Skip to content

Commit a2e1a0a

Browse files
authored
Merge pull request #44 from BonfaceKilz/main
Prefer page.description over summary in post macro
2 parents 1611bb8 + 84e53ca commit a2e1a0a

1 file changed

Lines changed: 7 additions & 3 deletions

File tree

templates/macros/post_macros.html

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,13 @@ <h2 itemprop="name">
2323
</h2>
2424
<data class="muted">{{ self::meta(page=page) }}</data>
2525
</header>
26-
{% if page.summary %}
27-
<section itemprop="summary">
28-
{{ page.summary | safe }}
26+
{% if page.description or page.summary %}
27+
<section itemprop="summary">
28+
{% if page.description %}
29+
{{ page.description | safe }}
30+
{% else %}
31+
{{ page.summary | safe }}
32+
{% endif %}
2933
<nav class="readmore"><a itemprop="url" href="{{ page.permalink | safe }}">Read More&nbsp;&raquo;</a></nav>
3034
</section>
3135
{% endif %}

0 commit comments

Comments
 (0)