Skip to content

Commit 82b4b67

Browse files
authored
Chore: reformat all templates to 2 spaces (#2617)
2 parents dcc35ca + 7099452 commit 82b4b67

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

51 files changed

+485
-453
lines changed

.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ metadata.json
77
*.tfbackend
88
*.tmp
99
*.egg-info
10+
node_modules/
1011
static/
1112
!benefits/static
1213
benefits/static/sha.txt

.pre-commit-config.yaml

+1
Original file line numberDiff line numberDiff line change
@@ -62,4 +62,5 @@ repos:
6262
- repo: https://github.com/Riverside-Healthcare/djLint
6363
rev: v1.36.4
6464
hooks:
65+
- id: djlint-reformat-django
6566
- id: djlint-django

.vscode/settings.json

+2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,10 @@
11
{
22
"editor.defaultFormatter": "esbenp.prettier-vscode",
33
"editor.formatOnSave": true,
4+
"djlint.useEditorIndentation": false,
45
"[django-html][html]": {
56
"editor.defaultFormatter": "monosans.djlint",
7+
"editor.tabSize": 2,
68
"djlint.enableLinting": true,
79
"djlint.profile": "django"
810
},

benefits/core/templates/core/base.html

+10-2
Original file line numberDiff line numberDiff line change
@@ -55,8 +55,16 @@
5555
<div id="header-container" class="navbar navbar-expand-sm navbar-dark bg-primary justify-content-between">
5656
<div class="container">
5757
<span class="navbar-brand p-0">
58-
<img class="sm d-lg-none" src="{% static "img/logo-sm.svg" %}" width="90" height="51.3" alt="{% translate "California Integrated Travel Project: Benefits logo (small)" context "image alt text" %}" />
59-
<img class="lg d-none d-lg-block" src="{% static "img/logo-lg.svg" %}" width="220" height="50" alt="{% translate "California Integrated Travel Project: Benefits logo (large)" context "image alt text" %}" />
58+
<img class="sm d-lg-none"
59+
src="{% static "img/logo-sm.svg" %}"
60+
width="90"
61+
height="51.3"
62+
alt="{% translate "California Integrated Travel Project: Benefits logo (small)" context "image alt text" %}" />
63+
<img class="lg d-none d-lg-block"
64+
src="{% static "img/logo-lg.svg" %}"
65+
width="220"
66+
height="50"
67+
alt="{% translate "California Integrated Travel Project: Benefits logo (large)" context "image alt text" %}" />
6068
</span>
6169
<div class="form-inline">{% include "core/includes/lang-selector.html" %}</div>
6270
</div>
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
<p class="h4 mt-4 d-block">{{ agency_name | default:agency.long_name }}</p>
22
<ul class="ps-0 d-flex flex-column gap-1 mt-1">
3-
<li class="list-unstyled">
4-
<a href="tel:{{ phone | default:agency.phone }}">{{ phone | default:agency.phone }}</a>
5-
</li>
6-
<li class="list-unstyled">
7-
<a href="{{ info_url | default:agency.info_url }}" target="_blank" rel="noopener noreferrer">{{ info_url | default:agency.info_url }}</a>
8-
</li>
3+
<li class="list-unstyled">
4+
<a href="tel:{{ phone | default:agency.phone }}">{{ phone | default:agency.phone }}</a>
5+
</li>
6+
<li class="list-unstyled">
7+
<a href="{{ info_url | default:agency.info_url }}" target="_blank" rel="noopener noreferrer">{{ info_url | default:agency.info_url }}</a>
8+
</li>
99
</ul>
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
{% block alert-wrapper %}
2-
<div class="alert-box border-start p-3 text-body {{ alert_class }}">
3-
{% block alert-heading-wrapper %}
4-
<{{ heading_tag|default:"h3" }} class="alert-box--heading lh-base ls-base mb-1">
5-
{% block alert-heading %}
6-
{% endblock alert-heading %}
7-
</{{ heading_tag|default:"h3" }}>
8-
{% endblock alert-heading-wrapper %}
9-
{% block alert-body %}
10-
{% endblock alert-body %}
11-
</div>
2+
<div class="alert-box border-start p-3 text-body {{ alert_class }}">
3+
{% block alert-heading-wrapper %}
4+
<{{ heading_tag|default:"h3" }} class="alert-box--heading lh-base ls-base mb-1">
5+
{% block alert-heading %}
6+
{% endblock alert-heading %}
7+
</{{ heading_tag|default:"h3" }}>
8+
{% endblock alert-heading-wrapper %}
9+
{% block alert-body %}
10+
{% endblock alert-body %}
11+
</div>
1212
{% endblock alert-wrapper %}
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
<li>
2-
<h2 class="h3 pb-1">
3-
{% block heading %}
4-
{% endblock heading %}
5-
</h2>
6-
{% block body %}
7-
{% endblock body %}
2+
<h2 class="h3 pb-1">
3+
{% block heading %}
4+
{% endblock heading %}
5+
</h2>
6+
{% block body %}
7+
{% endblock body %}
88
</li>
Original file line numberDiff line numberDiff line change
@@ -1,41 +1,41 @@
11
{% load i18n %}
22

33
<h2 class="h2-sm pt-4 pt-lg-8" id="calfresh-transit-benefit">
4-
{% translate "How do I know if I’m eligible for the transit benefit for CalFresh Cardholders?" %}
4+
{% translate "How do I know if I’m eligible for the transit benefit for CalFresh Cardholders?" %}
55
</h2>
66
<p class="pt-2 pt-lg-4">
7-
{% blocktranslate trimmed %}
8-
We verify your eligibility as a CalFresh Cardholder by confirming you have received funds in your
9-
CalFresh account at any point in the last three months. This means you are eligible for a transit
10-
benefit even if you did not receive funds in your CalFresh account this month or last month.
11-
{% endblocktranslate %}
7+
{% blocktranslate trimmed %}
8+
We verify your eligibility as a CalFresh Cardholder by confirming you have received funds in your
9+
CalFresh account at any point in the last three months. This means you are eligible for a transit
10+
benefit even if you did not receive funds in your CalFresh account this month or last month.
11+
{% endblocktranslate %}
1212
</p>
1313

1414
<h2 class="h2-sm pt-4 pt-lg-8" id="calfresh-transit-benefit-no-account-changes">
15-
{% translate "Will this transit benefit change my CalFresh account?" %}
15+
{% translate "Will this transit benefit change my CalFresh account?" %}
1616
</h2>
1717
<p class="pt-2 pt-lg-4">
18-
{% blocktranslate trimmed %}
19-
No. Your monthly CalFresh allotment will not change.
20-
{% endblocktranslate %}
18+
{% blocktranslate trimmed %}
19+
No. Your monthly CalFresh allotment will not change.
20+
{% endblocktranslate %}
2121
</p>
2222

2323
<h2 class="h2-sm pt-4 pt-lg-8" id="calfresh-transit-benefit-enrollment">
24-
{% translate "Do I need my Golden State Advantage card to enroll?" %}
24+
{% translate "Do I need my Golden State Advantage card to enroll?" %}
2525
</h2>
2626
<p class="pt-2 pt-lg-4">
27-
{% blocktranslate trimmed %}
28-
No, you do not need your physical EBT card to enroll. We use information from Login.gov and the California
29-
Department of Social Services to enroll you in the benefit.
30-
{% endblocktranslate %}
27+
{% blocktranslate trimmed %}
28+
No, you do not need your physical EBT card to enroll. We use information from Login.gov and the California
29+
Department of Social Services to enroll you in the benefit.
30+
{% endblocktranslate %}
3131
</p>
3232

3333
<h2 class="h2-sm pt-4 pt-lg-8" id="calfresh-transit-benefit-payment">
34-
{% translate "Can I use my Golden State Advantage card to pay for transit rides?" %}
34+
{% translate "Can I use my Golden State Advantage card to pay for transit rides?" %}
3535
</h2>
3636
<p class="pt-2 pt-lg-4">
37-
{% blocktranslate trimmed %}
38-
No. You can not use your EBT or P-EBT card to pay for public transportation. When you tap to ride, use your personal
39-
contactless debit or credit card to pay for public transportation.
40-
{% endblocktranslate %}
37+
{% blocktranslate trimmed %}
38+
No. You can not use your EBT or P-EBT card to pay for public transportation. When you tap to ride, use your personal
39+
contactless debit or credit card to pay for public transportation.
40+
{% endblocktranslate %}
4141
</p>
Original file line numberDiff line numberDiff line change
@@ -1,37 +1,37 @@
11
{% load i18n %}
22

33
<h2 class="h2-sm pt-4 pt-lg-8" id="medicare-transit-benefit">
4-
{% translate "How do I know if I qualify for the Medicare Cardholder option?" %}
4+
{% translate "How do I know if I qualify for the Medicare Cardholder option?" %}
55
</h2>
66
<p class="pt-2 pt-lg-4">
7-
{% blocktranslate trimmed %}
8-
You qualify for this option if you have a Medicare card. To enroll you will need an account with Medicare.gov. You will need to sign up for a Medicare.gov account if you do not currently have one. Deceased Medicare cardholders do not qualify.
9-
{% endblocktranslate %}
7+
{% blocktranslate trimmed %}
8+
You qualify for this option if you have a Medicare card. To enroll you will need an account with Medicare.gov. You will need to sign up for a Medicare.gov account if you do not currently have one. Deceased Medicare cardholders do not qualify.
9+
{% endblocktranslate %}
1010
</p>
1111

1212
<h2 class="h2-sm pt-4 pt-lg-8" id="medicare-transit-benefit-enrollment">
13-
{% translate "Do I need my Medicare card to enroll?" %}
13+
{% translate "Do I need my Medicare card to enroll?" %}
1414
</h2>
1515
<p class="pt-2 pt-lg-4">
16-
{% blocktranslate trimmed %}
17-
No, you do not need your physical Medicare card to enroll in a transit benefit. You will need the information on your card to create an account at Medicare.gov if you do not currently have an online account.
18-
{% endblocktranslate %}
16+
{% blocktranslate trimmed %}
17+
No, you do not need your physical Medicare card to enroll in a transit benefit. You will need the information on your card to create an account at Medicare.gov if you do not currently have an online account.
18+
{% endblocktranslate %}
1919
</p>
2020

2121
<h2 class="h2-sm pt-4 pt-lg-8" id="medicare-transit-benefit-payment">
22-
{% translate "Do I need to bring my Medicare card when I ride public transportation?" %}
22+
{% translate "Do I need to bring my Medicare card when I ride public transportation?" %}
2323
</h2>
2424
<p class="pt-2 pt-lg-4">
25-
{% blocktranslate trimmed %}
26-
No, you do not need your physical Medicare card to use your transit benefit on public transportation. Once you have enrolled you can use your contactless debit or credit card to tap to ride with a reduced fare.
27-
{% endblocktranslate %}
25+
{% blocktranslate trimmed %}
26+
No, you do not need your physical Medicare card to use your transit benefit on public transportation. Once you have enrolled you can use your contactless debit or credit card to tap to ride with a reduced fare.
27+
{% endblocktranslate %}
2828
</p>
2929

3030
<h2 class="h2-sm pt-4 pt-lg-8" id="medicare-transit-benefit-recommended">
31-
{% translate "What if I qualify for more than one option?" %}
31+
{% translate "What if I qualify for more than one option?" %}
3232
</h2>
3333
<p class="pt-2 pt-lg-4">
34-
{% blocktranslate trimmed %}
34+
{% blocktranslate trimmed %}
3535
You can enroll in any option you qualify for. We recommend enrolling in the Medicare Cardholder option if you qualify for it.
36-
{% endblocktranslate %}
36+
{% endblocktranslate %}
3737
</p>

benefits/core/templates/core/includes/help--sbmtd-mobility-pass.html

+3-3
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
<h2 class="h2-sm pt-4 pt-lg-8" id="mst-courtesy-card">{% translate "What is a Reduced Fare Mobility ID?" %}</h2>
44
<p class="pt-2 pt-lg-4">
5-
{% blocktranslate trimmed %}
6-
The Santa Barbara Metropolitan Transit District issues Reduced Fare Mobility ID cards to eligible riders. This transit benefit may need to be renewed in the future based on the expiration date of the Reduced Fare Mobility ID. Learn more at the <a href="https://sbmtd.gov/fares-passes/" target="_blank" rel="noopener noreferrer">SBMTD Fares & Passes</a>.
7-
{% endblocktranslate %}
5+
{% blocktranslate trimmed %}
6+
The Santa Barbara Metropolitan Transit District issues Reduced Fare Mobility ID cards to eligible riders. This transit benefit may need to be renewed in the future based on the expiration date of the Reduced Fare Mobility ID. Learn more at the <a href="https://sbmtd.gov/fares-passes/" target="_blank" rel="noopener noreferrer">SBMTD Fares & Passes</a>.
7+
{% endblocktranslate %}
88
</p>

benefits/core/templates/core/includes/modal--agency-selector.html

+23-23
Original file line numberDiff line numberDiff line change
@@ -3,28 +3,28 @@
33
{% load static %}
44

55
{% block modal-content %}
6-
<div class="container text-center">
7-
<h3 id="{{ aria_labelledby_id }}" class="modal-title h1 p-0 mb-4 pb-lg-2s text-center">
8-
{% translate "Please choose your transit provider:" %}
9-
</h3>
10-
<div class="card-row row d-flex flex-column flex-lg-row text-start text-lg-center justify-content-center">
11-
{% for agency in active_agencies %}
12-
<a href="{{ agency.eligibility_index_url }}" class="card m-0 d-inline-block">
13-
<div class="card-body d-flex flex-row-reverse flex-lg-column justify-content-center align-items-center">
14-
<img class="sm d-lg-none ms-auto"
15-
src="{{ agency.logo_small_url }}"
16-
width="52"
17-
height="36"
18-
alt="{% blocktranslate with agency=agency.short_name %}{{ agency }} logo{% endblocktranslate %}">
19-
<img class="lg d-none d-lg-block"
20-
src="{{ agency.logo_large_url }}"
21-
width="148"
22-
height="72"
23-
alt="{% blocktranslate with agency=agency.short_name %}{{ agency }} logo{% endblocktranslate %}">
24-
<h4 class="mt-lg-2 mb-0">{{ agency.long_name }}</h4>
25-
</div>
26-
</a>
27-
{% endfor %}
28-
</div>
6+
<div class="container text-center">
7+
<h3 id="{{ aria_labelledby_id }}" class="modal-title h1 p-0 mb-4 pb-lg-2s text-center">
8+
{% translate "Please choose your transit provider:" %}
9+
</h3>
10+
<div class="card-row row d-flex flex-column flex-lg-row text-start text-lg-center justify-content-center">
11+
{% for agency in active_agencies %}
12+
<a href="{{ agency.eligibility_index_url }}" class="card m-0 d-inline-block">
13+
<div class="card-body d-flex flex-row-reverse flex-lg-column justify-content-center align-items-center">
14+
<img class="sm d-lg-none ms-auto"
15+
src="{{ agency.logo_small_url }}"
16+
width="52"
17+
height="36"
18+
alt="{% blocktranslate with agency=agency.short_name %}{{ agency }} logo{% endblocktranslate %}">
19+
<img class="lg d-none d-lg-block"
20+
src="{{ agency.logo_large_url }}"
21+
width="148"
22+
height="72"
23+
alt="{% blocktranslate with agency=agency.short_name %}{{ agency }} logo{% endblocktranslate %}">
24+
<h4 class="mt-lg-2 mb-0">{{ agency.long_name }}</h4>
25+
</div>
26+
</a>
27+
{% endfor %}
2928
</div>
29+
</div>
3030
{% endblock modal-content %}
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
<!-- Modal -->
22
{% with id|add:"-modal-label" as aria_labelledby_id %}
3-
<div class="modal fade" id="{{ id }}" tabindex="-1" aria-labelledby="{{ aria_labelledby_id }}" aria-hidden="true">
4-
<div class="modal-dialog w-auto h-auto {{ size }} modal-dialog-centered modal-dialog-scrollable">
5-
<div class="modal-content">
6-
<div class="modal-header border-0 {{ header }}">
7-
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
8-
</div>
9-
<div class="modal-body {{ body }}">
10-
{% block modal-content %}
11-
{% endblock modal-content %}
12-
</div>
13-
</div>
3+
<div class="modal fade" id="{{ id }}" tabindex="-1" aria-labelledby="{{ aria_labelledby_id }}" aria-hidden="true">
4+
<div class="modal-dialog w-auto h-auto {{ size }} modal-dialog-centered modal-dialog-scrollable">
5+
<div class="modal-content">
6+
<div class="modal-header border-0 {{ header }}">
7+
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
148
</div>
9+
<div class="modal-body {{ body }}">
10+
{% block modal-content %}
11+
{% endblock modal-content %}
12+
</div>
13+
</div>
1514
</div>
15+
</div>
1616
{% endwith %}

benefits/core/templates/core/index--sbmtd.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,5 @@
22
{% load i18n %}
33

44
{% block headline %}
5-
{% translate "Get a reduced fare on Santa Barbara MTD buses when you tap to ride" %}
5+
{% translate "Get a reduced fare on Santa Barbara MTD buses when you tap to ride" %}
66
{% endblock headline %}

benefits/core/templates/core/widgets/flow-radio-select-option.html

+2-2
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,11 @@
22
<input class="radio-input rounded-circle flex-grow-0 flex-shrink-0"
33
type="{{ widget.type }}"
44
name="{{ widget.name }}"
5-
{% if widget.value != None %} value="{{ widget.value|stringformat:'s' }}"{% endif %}
5+
{% if widget.value != None %}value="{{ widget.value|stringformat:'s' }}"{% endif %}
66
{% include "django/forms/widgets/attrs.html" %}>
77

88
{% if widget.wrap_label %}
9-
<label{% if widget.attrs.id %} for="{{ widget.attrs.id }}" class="radio-label"{% endif %}>
9+
<label {% if widget.attrs.id %}for="{{ widget.attrs.id }}" class="radio-label"{% endif %}>
1010
{% include widget.selection_label_template %}
1111
</label>
1212
{% endif %}

benefits/eligibility/templates/eligibility/includes/eligibility-item--contactless-card--start.html

+7-7
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,15 @@
22
{% load i18n %}
33

44
{% block heading %}
5-
{% translate "Your contactless card details" %}
5+
{% translate "Your contactless card details" %}
66
{% endblock heading %}
77

88
{% block body %}
9-
<p>
10-
{% translate "Your contactless card must be a debit or credit card by Visa or Mastercard." %}
11-
{% translate "Learn more about contactless cards" as text %}
12-
{% include "core/includes/modal-trigger.html" with modal="modal--contactless" text=text period=True %}
13-
</p>
9+
<p>
10+
{% translate "Your contactless card must be a debit or credit card by Visa or Mastercard." %}
11+
{% translate "Learn more about contactless cards" as text %}
12+
{% include "core/includes/modal-trigger.html" with modal="modal--contactless" text=text period=True %}
13+
</p>
1414

15-
{% include "eligibility/includes/modal--contactless.html" with id="modal--contactless" size="modal-lg" header="p-md-2 p-3" body="pb-md-3 mb-md-3 mx-md-3 py-0 pt-0 absolute-top" %}
15+
{% include "eligibility/includes/modal--contactless.html" with id="modal--contactless" size="modal-lg" header="p-md-2 p-3" body="pb-md-3 mb-md-3 mx-md-3 py-0 pt-0 absolute-top" %}
1616
{% endblock body %}

benefits/eligibility/templates/eligibility/includes/eligibility-item--identification--start--sbmtd-agency-card.html

+2-2
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@
33
{% load i18n %}
44

55
{% block heading %}
6-
{% translate "Your current Reduced Fare Mobility ID number" %}
6+
{% translate "Your current Reduced Fare Mobility ID number" %}
77
{% endblock heading %}
88

99
{% block body %}
10-
<p>{% translate "You do not need to have your physical card, but you will need to know the number." %}</p>
10+
<p>{% translate "You do not need to have your physical card, but you will need to know the number." %}</p>
1111
{% endblock body %}

0 commit comments

Comments
 (0)