Plume/templates/posts/details.html.tera

66 lines
2.1 KiB
Plaintext

{% extends "base" %}
{% block title %}
{{ post.title }}
{% endblock title %}
{% block header %}
<a href="../">{{ blog.title }}</a>
{% endblock header %}
{% block content %}
<h1 class="article">{{ post.title }}</h1>
<p class="article-info">
<span class="author">Written by <a href="/@/{{ author.fqn }}/">{{ author.display_name }}</a></span>
&mdash;
<span class="date">{{ date | date(format="%B %e, %Y") }}</span>
</p>
<article>
{{ post.content | safe }}
</article>
<div class="article-meta">
<p>This article is under the {{ post.license }} license.</p>
<div class="likes">
<p>
{{ n_likes }} like{{ n_likes | pluralize }}
</p>
{% if has_liked %}
<a class="button liked" href="like">I don't like this anymore</a>
{% else %}
<a class="button" href="like">Like</a>
{% endif %}
<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>
</div>
<div class="comments">
<h2>Comments</h2>
<a class="button" href="comment?">Comment</a>
<div class="list">
{% for comment in comments %}
<div class="comment" id="comment-{{ comment.id }}">
<a class="author" href="{{ comment.author.ap_url }}">
<span class="display-name">{{ comment.author.display_name }}</span>
<span class="username">@{{ comment.author.username }}</span>
</a>
<div class="text">{{ comment.content | safe }}</div>
<a class="button" href="comment?responding_to={{ comment.id }}">Respond</a>
</div>
{% endfor %}
</div>
</div>
</div>
{% endblock content %}