{% extends "base.html" %}

{% block page_title %}
{{ config.title | default("bckt") }}
{% endblock page_title %}

{% block page_meta %}
{% set canonical = base_url ~ post.permalink %}
<meta name="description" content="{{ post.excerpt | trim }}">
<meta property="og:site_name" content="{{ config.title | default("bckt") }}">
<meta property="og:type" content="article">
<meta property="og:title" content="{{ config.title | default("bckt") | trim }}">
<meta property="og:url" content="{{ canonical | safe }}">
<meta property="og:description" content="{{ post.excerpt | trim}}">
<link rel="canonical" href="{{ canonical | safe }}">
<meta name="twitter:card" content="summary">
<meta name="twitter:title" content="{{ config.title | default("bckt") | trim }}">
<meta name="twitter:description" content="{{ post.excerpt | trim }}">
{% if post.image %}
<meta property="og:image" content="{{ canonical | safe}}{{ post.image }}"/>
<meta name="twitter:image" content="{{ canonical | safe}}{{ post.image }}"/>
{% endif %}
{% endblock page_meta %}

{% block content %}
<article>
<time datetime="{{ post.date_iso }}">{{ post.date }}</time>
{% if post.tags %}
<p>Tags: {% for tag in post.tags %}<a href="/tags/{{ tag | replace(' ', '-') | lower }}/">{{ tag }}</a>{% if not loop.last %}, {% endif %}{% endfor %}</p>
{% endif %}
{{ post.body | safe }}
</article>
{% endblock content %}
