Commit c2dc414e authored by Konrad Mohrfeldt's avatar Konrad Mohrfeldt Committed by Robert

make conversation creation form a publish component. refs #534

In order for the data-publish-submit flag to work a publish component
must be defined somewhere up the tree.
parent 9940171f
......@@ -25,7 +25,7 @@
{% endblock %}
{% block content %}
<form method="post">
<form method="post" data-component="publish">
{% csrf_token %}
{% if form.author %}
<div class="disclaimer content-block">
......
......@@ -23,7 +23,7 @@ function addAuthorPinnedListener (el) {
}
function addPublishListener (el) {
const form = closest(el, 'form')
const form = closest(el, 'form', true)
const submitButton = $('[data-publish-submit]', el)
const submitListener = on(form, 'submit', () => {
toggleClass(submitButton, 'btn-progress', true)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment