Add editorial layout for blog posts
This commit is contained in:
+35
-1
@@ -1,5 +1,39 @@
|
||||
{% extends "base.html" %}
|
||||
{% block body %}
|
||||
{% if this.parent._id == 'blog' %}
|
||||
<article class="blog-post-layout shell">
|
||||
<header class="blog-entry-header">
|
||||
<p class="eyebrow">{{ this.kicker }}</p>
|
||||
<h1>{{ this.title }}</h1>
|
||||
<p class="dek">{{ this.summary }}</p>
|
||||
</header>
|
||||
|
||||
<aside class="post-info" aria-label="Post information">
|
||||
<p class="post-info-title">Post information</p>
|
||||
<dl>
|
||||
<div class="post-info-row">
|
||||
<dt>Author</dt>
|
||||
<dd>{{ this.author }}</dd>
|
||||
</div>
|
||||
<div class="post-info-row">
|
||||
<dt>Published</dt>
|
||||
<dd><time datetime="{{ this.date }}">{{ this.date|dateformat('long') }}</time></dd>
|
||||
</div>
|
||||
<div class="post-info-row">
|
||||
<dt>Tags</dt>
|
||||
<dd class="post-tags">
|
||||
{% for tag in this.tags %}<span>{{ tag }}</span>{% endfor %}
|
||||
</dd>
|
||||
</div>
|
||||
</dl>
|
||||
</aside>
|
||||
|
||||
<div class="blog-entry-body prose">
|
||||
{{ this.body }}
|
||||
{% if this.external_url %}<p><a class="button-link" href="{{ this.external_url }}">Visit project →</a></p>{% endif %}
|
||||
</div>
|
||||
</article>
|
||||
{% else %}
|
||||
<article>
|
||||
<header class="hero compact entry-hero">
|
||||
<div class="shell narrow">
|
||||
@@ -15,5 +49,5 @@
|
||||
</div>
|
||||
</section>
|
||||
</article>
|
||||
{% endif %}
|
||||
{% endblock %}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user