Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

VACMS-12082 Fix service accordions headers #2401

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
103 changes: 53 additions & 50 deletions src/site/facilities/health_service.drupal.liquid
Original file line number Diff line number Diff line change
@@ -1,52 +1,55 @@
{% assign serviceTaxonomy = healthService.fieldServiceNameAndDescripti.entity %}
<va-accordion-item
{% if serviceTaxonomy.fieldAlsoKnownAs %}
subheader="{{ serviceTaxonomy.fieldAlsoKnownAs }}"
data-childlabel="{{ serviceTaxonomy.fieldAlsoKnownAs }}"
{% endif %}
class="va-accordion-item"
data-label="{{ serviceTaxonomy.name }}"
data-template="facilities/health_service"
id="item-{{ serviceTaxonomy.name | hashReference: 60 }}"
uswds="true"
>
<h3 slot="headline">
{{ serviceTaxonomy.name }}
</h3>
<div id="{{ serviceTaxonomy.entityBundle }}-{{ serviceTaxonomy.entityId }}">
{% if serviceTaxonomy.fieldCommonlyTreatedCondition %}
<p class="vads-u-margin-bottom--2">
Common conditions: {{ serviceTaxonomy.fieldCommonlyTreatedCondition }}
</p>
{% endif %}
{% if section.name == "Lovell - TRICARE" and serviceTaxonomy.fieldTricareDescription %}
<description>{{ serviceTaxonomy.fieldTricareDescription | phoneLinks }}</description>
{% elsif serviceTaxonomy.description.processed %}
<description>{{ serviceTaxonomy.description.processed | phoneLinks }}</description>
{% endif %}
{% assign serviceTaxonomy = healthService.fieldServiceNameAndDescripti.entity %}
<va-accordion-item
{% if serviceTaxonomy.fieldAlsoKnownAs %}
subheader="{{ serviceTaxonomy.fieldAlsoKnownAs }}"
data-childlabel="{{ serviceTaxonomy.fieldAlsoKnownAs }}"
{% endif %}
class="va-accordion-item"
data-label="{{ serviceTaxonomy.name }}"
data-template="facilities/health_service"
id="item-{{ serviceTaxonomy.name | hashReference: 60 }}"
uswds="true"
>
<h3 slot="headline">
{{ serviceTaxonomy.name }}
</h3>
<div id="{{ serviceTaxonomy.entityBundle }}-{{ serviceTaxonomy.entityId }}">
{% if serviceTaxonomy.fieldCommonlyTreatedCondition %}
<p class="vads-u-margin-bottom--2">
Common conditions: {{ serviceTaxonomy.fieldCommonlyTreatedCondition }}
</p>
{% endif %}

{% if healthService.fieldLocalHealthCareService.length > 0 %}
<h3>Available at these {{ regionOrOffice }} locations</h3>
<ul class="usa-unstyled-list" role="list">
{% assign orderedHealthServices = healthService.fieldLocalHealthCareService | orderFieldLocalHealthCareServices %}
{% for location in orderedHealthServices %}
{% assign facility = location.entity.fieldFacilityLocation.entity %}
{% if location.entity.status and facility != empty %}
<li class="vads-u-margin-bottom--2">
<va-link
href="{{ facility.entityUrl.path }}/#{{serviceTaxonomy.name | hashReference: 60}}"
text="{{ facility.title }}"
>
</va-link>
</li>
{% endif %}
{% endfor %}
</ul>
{% endif %}
{% if section.name == "Lovell - TRICARE" and serviceTaxonomy.fieldTricareDescription %}
<description>{{ serviceTaxonomy.fieldTricareDescription | phoneLinks }}</description>
{% elsif serviceTaxonomy.description.processed %}
<description>{{ serviceTaxonomy.description.processed | phoneLinks }}</description>
{% endif %}

{% if healthService.fieldBody.processed %}
<h3>Care we provide at {{ fieldOffice.entity.entityLabel }}</h3>
<description>{{ healthService.fieldBody.processed | phoneLinks }}</description>
{% endif %}
</div>
</va-accordion-item>
{% if healthService.fieldLocalHealthCareService.length > 0 %}
<h4 class="vads-u-font-size--h3">Available at these {{ regionOrOffice }} locations</h3>
<ul class="usa-unstyled-list" role="list">
{% assign orderedHealthServices = healthService.fieldLocalHealthCareService | orderFieldLocalHealthCareServices %}

{% for location in orderedHealthServices %}
{% assign facility = location.entity.fieldFacilityLocation.entity %}

{% if location.entity.status and facility != empty %}
<li class="vads-u-margin-bottom--2">
<va-link
href="{{ facility.entityUrl.path }}/#{{serviceTaxonomy.name | hashReference: 60}}"
text="{{ facility.title }}"
>
</va-link>
</li>
{% endif %}
{% endfor %}
</ul>
{% endif %}

{% if healthService.fieldBody.processed %}
<h4 class="vads-u-font-size--h3">Care we provide at {{ fieldOffice.entity.entityLabel }}</h3>
<description>{{ healthService.fieldBody.processed | phoneLinks }}</description>
{% endif %}
</div>
</va-accordion-item>
Loading