Fix recent posts heading

This commit is contained in:
2021-05-04 18:19:29 +02:00
parent e7b3aea9ab
commit b1ce7f70df

View File

@@ -4,9 +4,9 @@ home: true
--- ---
{% include anchor_headings.html html=content anchorClass="anchor-head" beforeHeading=true h_min=1 h_max=4 %} {% include anchor_headings.html html=content anchorClass="anchor-head" beforeHeading=true h_min=1 h_max=4 %}
{%- if site.length > 0 -%} {%- if site.posts != empty -%}
<h3 class="posts-item-note" aria-label="Recent Posts">Recent Posts</h3> <h2 aria-label="Recent Posts">Recent Posts</h2>
{%- endif -%} <div>
{%- for post in site.posts limit: site.number_of_posts -%} {%- for post in site.posts limit: site.number_of_posts -%}
<article class="post-item"> <article class="post-item">
<span class="post-item-date">{{ post.date | date: "%b %d, %Y" }}</span> <span class="post-item-date">{{ post.date | date: "%b %d, %Y" }}</span>
@@ -15,3 +15,5 @@ home: true
</h4> </h4>
</article> </article>
{%- endfor -%} {%- endfor -%}
</div>
{%- endif -%}