Skip to content
Snippets Groups Projects
post.html 2.12 KiB
{% extends "page.html" %}

{% block rdfa_type %}schema:BlogPosting{% endblock %}

{% block content %}
  {% set blog_section = get_section(path="blog/_index.md") %}
  {% set post = page -%}
  <div class="columns mt-4">
	  <meta property="schema:isPartOf" href="{{ blog_section.permalink }}" />
    {% if post.extra.microdata.about %}
    {% for about in post.extra.microdata.about %}
      <meta property="schema:about" href="{{ about }}" />
    {% endfor %}
    {% endif %}
    <div class="column is-three-quarters">
      <div class="content" property="schema:articleBody">
        {{ page.content | safe }}
      </div>
    </div>
    <div class="column is-one-quarter">
      <div class="card">
        <div class="card-image">
          <figure class="image is-4by3">
            {% set image = resize_image(path="@/" ~ post.colocated_path ~ "/" ~ post.extra.depiction.image, width=800, height=600) -%}
              <img src="{{ image.url }}" alt="{{ post.extra.depiction.alt }}" />
            {% if post.extra.depiction.credits %}
              <figcaption class="p-1 has-text-white has-background-black is-size-7 is-italic">{{ post.extra.depiction.credits }}</figcaption>
            {% endif %}
          </figure>
        </div>
        <div class="card-content">
          {% include "blog/author_media.html" %}
        </div>
        <div class="card-footer">
          <div class="card-footer-item">
            {% include "blog/meta_line.html" -%}
          </div>
        </div>
      </div>
      <nav class="panel is-light mt-6">
        <p class="panel-heading">Weitere Posts dazu</p>
          {% for kind, terms in page.taxonomies %}
            {% for term in terms %}
	      {% set taxonomy = get_taxonomy_term(kind=kind, term=term) %}
	      {% set posts = taxonomy.pages | filter(attribute="date") %}
	      {% if posts %}
                <p class="panel-block subtitle is-7">{{ kind | title }}: {{ term }}</p>
		{% for post in posts | slice(end=5) %}
		  <a class="panel-block" href="{{ post.permalink }}">{{ post.title}}</a>
		{% endfor %}
	      {% endif %}
            {% endfor %}
	  {% endfor %}
      </div>
    </div>
  </div>
{% endblock %}