mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-07-25 02:19:12 -04:00
Submit form was - a confusing name in itself - not descriptive, because it also has an optional ‘back’ link This commit also puts this component in as many pages as possible, stripping out any hard-coded buttons and links. It replaces any usage of buttons for ‘back’, because these are links, not buttons (ie they don’t change any data).
12 lines
523 B
HTML
12 lines
523 B
HTML
{% macro page_footer(button_text=None, back_link=False, back_link_text="Back", destructive=False) %}
|
|
<div class="page-footer">
|
|
{% if button_text %}
|
|
<input type="hidden" name="csrf_token" value="{{ csrf_token() }}" />
|
|
<input type="submit" class="button{% if destructive %}-destructive{% endif %}" value="{{ button_text }}" />
|
|
{% endif %}
|
|
{% if back_link %}
|
|
<a class="page-footer-back-link" role="button" href="{{ back_link }}">{{ back_link_text }}</a>
|
|
{% endif %}
|
|
</div>
|
|
{% endmacro %}
|