{% spaceless %}
<form{% include "formset/form_attrs.html" %} df-transient="true"></form>
{% if form.modal_title %}
<div class="dialog-header">
	<div class="modal-title">{{ form.modal_title }}</div>
</div>
{% endif %}
{% if form.fields %}
<div class="dialog-body">
	{% for field in form %}
		{% if field.is_hidden %}
			{{ field }}
		{% else %}
			{% include "formset/default/field_group.html" %}
		{% endif %}
	{% endfor %}
	{% if help_text %}{% include help_text_template %}{% endif %}
</div>
{% endif %}
<div class="dialog-footer">
	<button class="btn btn-outline-secondary" name="close" type="button" form="{{ form.form_id }}">Close</button>
	<button class="btn btn-danger" name="remove" type="button" form="{{ form.form_id }}">Remove</button>
	<button class="btn btn-primary" name="save" value="save" type="submit" form="{{ form.form_id }}">Save</button>
</div>
{% endspaceless %}