Extend the sublabel to add an optinal link at the end

This commit is contained in:
rachidatecs 2023-08-01 19:02:09 -04:00
parent 7209e74f41
commit 3d94b71533
No known key found for this signature in database
GPG key ID: 3CEBBFA7325E5525
2 changed files with 15 additions and 2 deletions

View file

@ -3,7 +3,15 @@
{% block form_fields %}
{% input_with_errors forms.0.tribe_name %}
{% with sublabel_text="Please include the entire name of your tribe as recognized by the" %}
{% with link_text="Bureau of Indian Affairs" %}
{% with link_href="https://rachid.me" %}
{% input_with_errors forms.0.tribe_name %}
{% endwith %}
{% endwith %}
{% endwith %}
<fieldset class="usa-fieldset">
<legend class="usa-legend">
<p>Is your organization a federally-recognized tribe or a state-recognized tribe? Check all that apply.

View file

@ -29,7 +29,12 @@ error messages, if necessary.
{% endif %}
{% if sublabel_text %}
<p id="{{ widget.attrs.id }}__sublabel" class="text-base margin-top-2px margin-bottom-1">{{ sublabel_text }}</p>
<p id="{{ widget.attrs.id }}__sublabel" class="text-base margin-top-2px margin-bottom-1">
{{ sublabel_text }}
{% if link_text %}
<a href="{{ link_href }}">{{ link_text }}</a>.
{% endif %}
</p>
{% endif %}
{% if field.errors %}