This repository has been archived on 2023-09-24. You can view files and clone it, but cannot push or open issues or pull requests.
takahe/templates/activities/compose.html

41 lines
1.4 KiB
HTML
Raw Normal View History

2022-11-16 14:53:39 +01:00
{% extends "base.html" %}
{% block title %}Compose{% endblock %}
{% block content %}
<form action="." method="POST">
{% csrf_token %}
2022-11-18 01:43:00 +01:00
<fieldset>
<legend>Content</legend>
2022-11-24 23:17:32 +01:00
{% if reply_to %}
2022-11-26 00:34:45 +01:00
<label>Replying to</label>
{% include "activities/_mini_post.html" with post=reply_to %}
2022-11-24 23:17:32 +01:00
{% endif %}
{{ form.reply_to }}
2022-11-27 19:09:46 +01:00
{{ form.id }}
2022-11-18 01:43:00 +01:00
{% include "forms/_field.html" with field=form.text %}
{% include "forms/_field.html" with field=form.content_warning %}
{% include "forms/_field.html" with field=form.visibility %}
</fieldset>
2022-12-02 02:46:49 +01:00
<fieldset>
<legend>Images</legend>
{% if post %}
{% for attachment in post.attachments.all %}
{% include "activities/_image_uploaded.html" %}
{% endfor %}
{% endif %}
{% if not post or post.attachments.count < 4 %}
<a class="button add-image"
hx-get='{% url "compose_image_upload" %}'
hx-target="this"
hx-swap="outerHTML">
Add Image
</a>
{% endif %}
</fieldset>
2022-11-16 14:53:39 +01:00
<div class="buttons">
2022-12-02 02:46:49 +01:00
<button>{% if post %}Save Edits{% elif config_identity.toot_mode %}Toot!{% else %}Post{% endif %}</button>
2022-11-16 14:53:39 +01:00
</div>
</form>
{% endblock %}