web/_includes/post.njk

37 lines
No EOL
1.4 KiB
Text

---
layout: base.njk
title: Adrian Victor:Blog
---
{% set altLanguages = collections.post | alternateLanguages(postId, langKey) %}
<main>
<article>
<div id="postHeader">
<h1>{{ postTitle }}</h1>
<p>{{ authors or "Adrian Victor" }} - {{ date }}</p>
{% if altLanguages.length > 0 %}
{{ i18n[langKey].availableInOtherLanguages }}:
{% for alt in altLanguages %}
<li class="inlineList">
<a href="{{ alt.url }}" hreflang="{{ alt.lang }}">
{{ i18n[alt.lang].language }}
</a>
</li>
{% endfor %}
{% endif %}
</div>
{% if postVideoLink and postVideoImage and postVideoTitle and postVideoWebsite %}
<a href="{{ postVideoLink }}">
<div class="blogpostYoutubeVideo">
<img src="/static/images/thumbnails/{{ postVideoImage }}">
<div class="videoHeader">
<p class="alsoAvailable">{{ i18n[langKey].alsoAvailableAsVideo }}:</p>
<h2 class="videoTitle">{{ postVideoTitle }}</h2>
<p>{{ postVideoWebsite }}{% if postVideoDuration %} ({{ postVideoDuration }}){% endif %}</p>
</div>
<!-- <p class="goLabel">ir</p> -->
</div>
</a>
{% endif %}
{{ content | safe }}
</article>
</main>