Skip to content

Commit 255b554

Browse files
committed
feat(portal-theme): improve a11y and add star to link highlights
1 parent 8b64261 commit 255b554

File tree

3 files changed

+6
-7
lines changed

3 files changed

+6
-7
lines changed

src/Themes/PortalTheme/Views/ContentCulturePickerContainer.liquid

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,8 @@
22
{% for culture in Model.SupportedCultures %}
33
{% if culture.Name != Model.CurrentCulture.Name %}
44
{% capture targetCultureLongName %}{% if culture.Name contains 'fr' %}Français{% else %}English{% endif %}{% endcapture %}
5-
{% capture targetCultureUrl %}{{ culture.Name | switch_culture_url}}{% endcapture %}
6-
<a class="dropdown-item d-lg-none d-flex" href="{{targetCultureUrl}}" aria-label="{{targetCultureLongName}}">{{targetCultureLongName}}</a>
7-
<a href="{{ targetCultureUrl }}" class="btn btn-primary is-circle language-toggle d-lg-flex d-none" aria-label="{{targetCultureLongName}}">{{ culture.Name }}</a>
5+
{% capture targetCultureUrl %}{{ culture.Name | switch_culture_url }}{% endcapture %}
6+
<a class="dropdown-item d-lg-none d-flex" href="{{targetCultureUrl}}" lang="{{culture.Name}}" aria-label="{{targetCultureLongName}}">{{targetCultureLongName}}</a>
7+
<a href="{{ targetCultureUrl }}" class="btn btn-primary is-circle language-toggle d-lg-flex d-none" lang="{{culture.Name}}" aria-label="{{targetCultureLongName}}">{{ culture.Name }}</a>
88
{% endif %}
9-
{% endfor %}
10-
9+
{% endfor %}

src/Themes/PortalTheme/Views/Widget-Section.liquid

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<section class="content-section">
2-
<div class="{{ Model.ContentItem.Content.Section.Section.Text }}">
2+
<div class="{{ Model.ContentItem.Content.Section.Section.Text | default: 'd-none' }}">
33
<h2 class="{{ Model.ContentItem.Content.Section.TitleLayout.Text }}">{{ Model.ContentItem | display_text }}</h2>
44
<div class="row {{ Model.ContentItem.Content.Section.ColumnLayout.Text }} {{ Model.ContentItem.Content.Section.JustifyContent.Text }}">
55
{% for item in Model.ContentItem.Content.SectionPanels.ContentItems %}

src/Themes/PortalTheme/Views/Widget-SectionPanel.liquid

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
{% endif %}
3030
</div>
3131
<div>
32-
<h3>{{ item.SectionPanelLink.Name.Text }}</h3>
32+
<h3>{{ item.SectionPanelLink.Name.Text }} {% if item.SectionPanelLink.HeroHighlight.Value == true %}<i class="fas fa-star ml-1"></i>{% endif %}</h3>
3333
<p class="text-secondary">{{ item.SectionPanelLink.Description.Text }}</p>
3434
</div>
3535
</div>

0 commit comments

Comments
 (0)