feat: add bulma comment section

This commit is contained in:
moanos [he/him] 2025-05-10 12:02:11 +02:00
parent 23e154bce6
commit d9ebee1e07
2 changed files with 28 additions and 1 deletions

View File

@ -7,7 +7,7 @@
<div class="card-content">
{% if adoption_notice.comments %}
{% for comment in adoption_notice.comments %}
{% include "fellchensammlung/partials/partial-comment.html" %}
{% include "fellchensammlung/partials/bulma-partial-comment.html" %}
{% endfor %}
{% else %}
<p class="is-italic">{% translate 'Noch keine Kommentare' %}</p>

View File

@ -0,0 +1,27 @@
{% load i18n %}
{% load custom_tags %}
<div class="card">
<div class="card-header">
<div class="card-header-title content">
<b class="">{{ comment.user }}</b> <span class="tag"><time class="">{{ comment.created_at }}</time></span>
</div>
</div>
<div class="card-content">
<p class="content">
{{ comment.text | render_markdown }}
</p>
</div>
<div class="card-footer">
<a class="card-footer-item is-danger" href="{{ comment.get_report_url }}">
<span class="icon-text">
<span class="icon">
<i class="fa-solid fa-flag"></i>
</span>
<span>{% trans 'Melden' %}</span>
</span>
</a>
</div>
</div>