pyfedi/app/templates/post/add_reply.html

48 lines
2.2 KiB
HTML
Raw Normal View History

{% if theme() and file_exists('app/templates/themes/' + theme() + '/base.html') %}
{% extends 'themes/' + theme() + '/base.html' %}
{% else %}
{% extends "base.html" %}
{% endif %} %}
2023-10-15 21:13:32 +13:00
{% from 'bootstrap/form.html' import render_form %}
{% block app_content %}
<script src="/static/js/coolfieldset.js"></script>
<div class="row">
2023-11-09 21:32:29 +13:00
<div class="col-12 col-md-8 position-relative add_reply main_pane">
2023-10-15 21:13:32 +13:00
<fieldset class="coolfieldset mt-4"><legend class="w-auto">Original post</legend>
<h3>{{ post.title }}</h3>
2024-02-26 21:26:19 +13:00
{{ post.body_html | safe if post.body_html else '' }}
2023-10-15 21:13:32 +13:00
</fieldset>
<fieldset class="coolfieldset mt-4"><legend class="w-auto">Comment you are replying to</legend>
{{ comment.body_html | safe}}
</fieldset>
2023-11-30 23:21:37 +13:00
<div class="position-relative">
2024-01-10 17:27:07 +13:00
{% if post.community.ap_id and '@beehaw.org' in post.community.ap_id %}
<p>{{ _('This post is hosted on beehaw.org which has <a href="https://docs.beehaw.org/docs/core-principles/what-is-beehaw/" target="_blank" rel="nofollow">higher standards of behaviour than most places. Be nice</a>.') }}</p>
{% endif %}
2023-11-30 23:21:37 +13:00
{{ render_form(form) }}
2024-02-28 20:12:57 +13:00
{% if not low_bandwidth %}
{% if markdown_editor %}
<script nonce="{{ session['nonce'] }}">
window.addEventListener("load", function () {
var downarea = new DownArea({
elem: document.querySelector('#body'),
resize: DownArea.RESIZE_VERTICAL,
hide: ['heading', 'bold-italic'],
});
setupAutoResize('body');
2023-12-26 10:49:08 +13:00
});
2024-02-28 20:12:57 +13:00
</script>
{% else %}
<!-- <a href="#" aria-hidden="true" id="post_reply_markdown_editor_enabler" class="markdown_editor_enabler" data-id="body">{{ _('Enable markdown editor') }}</a> -->
2024-02-28 20:12:57 +13:00
{% endif %}
2023-12-26 10:49:08 +13:00
{% endif %}
2023-11-30 23:21:37 +13:00
</div>
2023-10-15 21:13:32 +13:00
</div>
{% with community = post.community -%}
{% include "_side_pane.html" %}
{% endwith -%}
2023-10-15 21:13:32 +13:00
</div>
{% endblock %}