feat: Re-style comment field to be inside comment box

This commit is contained in:
2025-09-03 06:28:13 +02:00
parent 21bd34c94d
commit 996bd7af67
2 changed files with 17 additions and 24 deletions

View File

@@ -1,19 +1,13 @@
{% load i18n %}
{% load widget_tweaks %}
<div class="card">
<div class="card-header">
<div class="card-header-title">
{% blocktrans %}
Als {{ user }} kommentieren
{% endblocktrans %}
</div>
<form method="POST">
{% csrf_token %}
<input type="hidden" name="action" value="comment">
<div class="field">
{{ comment_form.text |add_class:"input textarea"|attr:"rows:3"|attr:"placeholder:Neuer Kommentar" }}
</div>
<div class="card-content">
<form method="POST">
{% csrf_token %}
<input type="hidden" name="action" value="comment">
{{ comment_form }}
<input type="submit" class="button is-primary" value="{% trans 'Kommentieren' %}">
</form>
<div class="control">
<input type="submit" class="button is-primary" value="{% trans 'Kommentieren' %}">
</div>
</div>
</form>

View File

@@ -12,14 +12,13 @@
{% else %}
<p class="is-italic">{% translate 'Noch keine Kommentare' %}</p>
{% endif %}
{% if user.is_authenticated %}
<hr>
{% include "fellchensammlung/forms/form-comment.html" %}
{% else %}
<div class="card-footer-item">
{% translate 'Du musst dich einloggen um Kommentare zu hinterlassen' %}
</div>
{% endif %}
</div>
</div>
<div class="block">
{% if user.is_authenticated %}
{% include "fellchensammlung/forms/form-comment.html" %}
{% else %}
<p class="card-footer-item">
{% translate 'Du musst dich einloggen um Kommentare zu hinterlassen' %}
</p>
{% endif %}
</div>