mediocre-blog/_layouts/post.html

73 lines
2.1 KiB
HTML
Raw Normal View History

---
layout: default
---
<article itemscope itemtype="http://schema.org/BlogPosting" style="margin-bottom: 50vh;">
<header id="post-header">
<h1 id="post-headline" itemprop="name headline">
{{ page.title | escape }}
</h1>
<div class="light">
<span hidden itemprop="author" itemscope itemtype="http://schema.org/Person">
<span itemprop="name">{{ site.author }}</span>
</span>
<!---->
<time datetime="{{ page.date | date_to_xmlschema }}" itemprop="datePublished">
2018-09-06 16:19:29 +00:00
{{ page.date | date: site.date_format }}
</time>
2018-09-06 15:57:08 +00:00
{%- if page.updated %}
<time datetime="{{ page.updated | date_to_xmlschema }}" itemprop="dateModified">
2018-09-06 16:19:29 +00:00
(Updated {{ page.updated | date: site.date_format }})
2018-09-06 15:57:08 +00:00
</time>
{% endif -%}
<span itemprop="about"><em>{{ page.description }}</em></span>
</div>
</header>
{% if page.series %}
{% assign foundThis = false %}
{% for post in site.posts reversed %}
{% if post.series == page.series %}
{% if post.url == page.url %}
{% assign foundThis = true %}
{% elsif foundThis %}
{% assign next = post %}
{% break %}
{% else %}
{% assign prev = post %}
{% endif %}
{% endif %}
{% endfor %}
{% if prev or next %}
<p class="light"><em>
This post is part of a series<br/>
{% if prev %}
Previously: <a href="{{ prev.url | relative_url }}">{{ prev.title }}</a></br>
{% endif %}
{% if next %}
Next: <a href="{{ next.url | relative_url }}">{{ next.title }}</a></br>
{% endif %}
</em></p>
{% endif %}
{% endif %}
<div id="post-content" itemprop="articleBody">
{{ content }}
</div>
{% if prev or next %}
<p class="light"><em>
This post is part of a series<br/>
{% if prev %}
Previously: <a href="{{ prev.url | relative_url }}">{{ prev.title }}</a></br>
{% endif %}
{% if next %}
Next: <a href="{{ next.url | relative_url }}">{{ next.title }}</a></br>
{% endif %}
</em></p>
{% endif %}
</article>