2018-05-09 21:09:52 +02:00
|
|
|
{% extends "base" %}
|
|
|
|
|
|
|
|
{% block title %}
|
|
|
|
{{ post.title }}
|
|
|
|
{% endblock title %}
|
|
|
|
|
2018-05-10 22:31:52 +02:00
|
|
|
{% block header %}
|
|
|
|
<a href="../">{{ blog.title }}</a>
|
|
|
|
{% endblock header %}
|
|
|
|
|
2018-05-09 21:09:52 +02:00
|
|
|
{% block content %}
|
2018-06-12 01:30:31 +02:00
|
|
|
{% if author.display_name %}
|
|
|
|
{% set name = author.display_name %}
|
|
|
|
{% else %}
|
|
|
|
{% set name = author.username %}
|
|
|
|
{% endif %}
|
2018-05-19 09:53:51 +02:00
|
|
|
<p>
|
2018-06-12 01:31:44 +02:00
|
|
|
<b>Written by <a href="/@/{{ author.fqn }}/">{{ name }}</a></b>
|
2018-05-19 09:53:51 +02:00
|
|
|
—
|
|
|
|
<span>{{ date | date(format="%B %e, %Y") }}</span>
|
|
|
|
</p>
|
2018-05-10 11:44:57 +02:00
|
|
|
<h1>{{ post.title }}</h1>
|
2018-05-10 22:31:52 +02:00
|
|
|
<article>
|
2018-05-10 11:44:57 +02:00
|
|
|
{{ post.content | safe }}
|
2018-05-10 22:31:52 +02:00
|
|
|
</article>
|
2018-05-10 18:38:03 +02:00
|
|
|
|
2018-05-10 22:31:52 +02:00
|
|
|
<div class="article-meta">
|
|
|
|
<p>This article is under the {{ post.license }} license.</p>
|
2018-05-10 18:38:03 +02:00
|
|
|
|
2018-05-10 22:31:52 +02:00
|
|
|
<div class="inline">
|
|
|
|
<p>
|
|
|
|
{{ n_likes }} like{{ n_likes | pluralize }}
|
|
|
|
</p>
|
2018-05-12 22:56:57 +02:00
|
|
|
<a class="button" href="like">
|
|
|
|
{% if has_liked %}
|
|
|
|
I don't like this anymore
|
|
|
|
{% else %}
|
|
|
|
Add yours
|
|
|
|
{% endif %}
|
|
|
|
</a>
|
2018-05-19 11:57:39 +02:00
|
|
|
|
|
|
|
<p>
|
|
|
|
{{ n_reshares }} reshare{{ n_reshares | pluralize }}
|
|
|
|
</p>
|
|
|
|
<a class="button" href="reshare">
|
|
|
|
{% if has_reshared %}
|
|
|
|
I don't want to reshare this anymore
|
|
|
|
{% else %}
|
|
|
|
Reshare
|
|
|
|
{% endif %}
|
|
|
|
</a>
|
2018-05-10 11:44:57 +02:00
|
|
|
</div>
|
2018-05-10 22:31:52 +02:00
|
|
|
|
|
|
|
<h2>Comments</h2>
|
2018-05-13 22:33:21 +02:00
|
|
|
<div class="list">
|
|
|
|
{% for comment in comments %}
|
2018-06-12 01:30:31 +02:00
|
|
|
{% if comment.author.display_name %}
|
2018-06-12 14:17:02 +02:00
|
|
|
{% set comment_author_name = comment.author.display_name %}
|
2018-06-12 01:30:31 +02:00
|
|
|
{% else %}
|
2018-06-12 14:17:02 +02:00
|
|
|
{% set comment_author_name = comment.author.username %}
|
2018-06-12 01:30:31 +02:00
|
|
|
{% endif %}
|
2018-05-13 22:33:21 +02:00
|
|
|
<div class="card" id="comment-{{ comment.id }}">
|
2018-06-12 14:17:02 +02:00
|
|
|
<b>{{ comment_author_name }}</b>
|
2018-05-13 22:33:21 +02:00
|
|
|
<div>{{ comment.content | safe }}</div>
|
|
|
|
<a href="comment?responding_to={{ comment.id }}">Respond</a>
|
|
|
|
</div>
|
|
|
|
{% endfor %}
|
|
|
|
</div>
|
2018-05-10 22:31:52 +02:00
|
|
|
<a class="button inline-block" href="comment?">Comment</a>
|
|
|
|
</div>
|
2018-05-09 21:09:52 +02:00
|
|
|
{% endblock content %}
|