mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-02-16 00:14:18 -05:00
29 lines
736 B
HTML
29 lines
736 B
HTML
{% macro form_wrapper(
|
|
method="post",
|
|
action=None,
|
|
autocomplete=False,
|
|
class=None,
|
|
id=None,
|
|
module=None,
|
|
data_kwargs={},
|
|
data_force_focus=False
|
|
) %}
|
|
<form
|
|
method="{{ method }}"
|
|
{% if action %}action="{{ action }}"{% endif %}
|
|
{% if not autocomplete %}autocomplete="off"{% endif %}
|
|
{% if class %}class="{{ class }}"{% endif %}
|
|
{% if id %}id="{{ id }}"{% endif %}
|
|
{% if module %}data-module="{{ module }}"{% endif %}
|
|
{% for key, val in data_kwargs.items() %}
|
|
{% if val %}
|
|
data-{{ key }}="{{ val }}"
|
|
{% endif %}
|
|
{% endfor %}
|
|
{% if data_force_focus %}data-force-focus="{{ data_force_focus }}"{% endif %}
|
|
novalidate
|
|
>
|
|
{{ caller() }}
|
|
</form>
|
|
{% endmacro %}
|