Skip to content

Commit

Permalink
Remove redundant h2 pt.1 (#1)
Browse files Browse the repository at this point in the history
* Remove `h2` from cart

* Remove `h2` from country label

* Remove `h2` from `sort_by_label`

* Remove more `h2`s
  • Loading branch information
dgopsq authored Sep 20, 2024
1 parent 6710336 commit c98a6d8
Show file tree
Hide file tree
Showing 10 changed files with 28 additions and 28 deletions.
4 changes: 2 additions & 2 deletions sections/announcement-bar.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@
<localization-form class="small-hide medium-hide">
{%- form 'localization', id: 'AnnouncementCountryForm', class: 'localization-form' -%}
<div>
<h2 class="visually-hidden" id="AnnouncementCountryLabel">{{ 'localization.country_label' | t }}</h2>
<span class="visually-hidden" id="AnnouncementCountryLabel">{{ 'localization.country_label' | t }}</span>
{%- render 'country-localization', localPosition: 'AnnouncementCountry' -%}
</div>
{%- endform -%}
Expand All @@ -154,7 +154,7 @@
<localization-form class="small-hide medium-hide">
{%- form 'localization', id: 'AnnouncementLanguageForm', class: 'localization-form' -%}
<div>
<h2 class="visually-hidden" id="AnnouncementLanguageLabel">{{ 'localization.language_label' | t }}</h2>
<span class="visually-hidden" id="AnnouncementLanguageLabel">{{ 'localization.language_label' | t }}</span>
{%- render 'language-localization', localPosition: 'AnnouncementLanguage' -%}
</div>
{%- endform -%}
Expand Down
2 changes: 1 addition & 1 deletion sections/footer.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -262,7 +262,7 @@
<localization-form>
{%- form 'localization', id: 'FooterCountryForm', class: 'localization-form' -%}
<div>
<h2 class="caption-large text-body" id="FooterCountryLabel">{{ 'localization.country_label' | t }}</h2>
<span class="caption-large text-body" id="FooterCountryLabel">{{ 'localization.country_label' | t }}</span>
{%- render 'country-localization', localPosition: 'FooterCountry' -%}
</div>
{%- endform -%}
Expand Down
2 changes: 1 addition & 1 deletion sections/header.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,7 @@
<localization-form class="small-hide medium-hide" data-prevent-hide>
{%- form 'localization', id: 'HeaderCountryForm', class: 'localization-form' -%}
<div>
<h2 class="visually-hidden" id="HeaderCountryLabel">{{ 'localization.country_label' | t }}</h2>
<span class="visually-hidden" id="HeaderCountryLabel">{{ 'localization.country_label' | t }}</span>
{%- render 'country-localization', localPosition: 'HeaderCountry' -%}
</div>
{%- endform -%}
Expand Down
2 changes: 1 addition & 1 deletion sections/main-cart-footer.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@
</div>

<div class="totals">
<h2 class="totals__total">{{ 'sections.cart.estimated_total' | t }}</h2>
<span class="totals__total">{{ 'sections.cart.estimated_total' | t }}</span>
<p class="totals__total-value">{{ cart.total_price | money_with_currency }}</p>
</div>

Expand Down
4 changes: 2 additions & 2 deletions sections/main-collection-product-grid.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -44,9 +44,9 @@
<form class="facets-vertical-form" id="FacetSortForm">
<div class="facet-filters sorting caption">
<div class="facet-filters__field">
<h2 class="facet-filters__label caption-large text-body">
<span class="facet-filters__label caption-large text-body">
<label for="SortBy">{{ 'products.facets.sort_by_label' | t }}</label>
</h2>
</span>
<div class="select">
{%- assign sort_by = collection.sort_by | default: collection.default_sort_by -%}
<select
Expand Down
4 changes: 2 additions & 2 deletions sections/main-search.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -154,9 +154,9 @@
<form class="facets-vertical-form" id="FacetSortForm">
<div class="facet-filters sorting caption">
<div class="facet-filters__field">
<h2 class="facet-filters__label caption-large text-body">
<span class="facet-filters__label caption-large text-body">
<label for="SortBy">{{ 'products.facets.sort_by_label' | t }}</label>
</h2>
</span>
<div class="select">
{%- assign sort_by = search.sort_by | default: search.default_sort_by -%}
<select
Expand Down
4 changes: 2 additions & 2 deletions sections/predictive-search.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -117,12 +117,12 @@
<div class="predictive-search__result-group">
{%- if predictive_search.resources.products.size > 0 -%}
<div>
<h2
<span
id="predictive-search-products"
class="predictive-search__heading text-body caption-with-letter-spacing"
>
{{- 'templates.search.products' | t -}}
</h2>
</span>
<ul
id="predictive-search-results-products-list"
class="predictive-search__results-list list-unstyled"
Expand Down
6 changes: 3 additions & 3 deletions snippets/cart-drawer.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
<div class="drawer__inner-empty">
<div class="cart-drawer__warnings center{% if settings.cart_drawer_collection != blank %} cart-drawer__warnings--has-collection{% endif %}">
<div class="cart-drawer__empty-content">
<h2 class="cart__empty-text">{{ 'sections.cart.empty' | t }}</h2>
<span class="cart__empty-text">{{ 'sections.cart.empty' | t }}</span>
<button
class="drawer__close"
type="button"
Expand Down Expand Up @@ -62,7 +62,7 @@
</div>
{%- endif -%}
<div class="drawer__header">
<h2 class="drawer__heading">{{ 'sections.cart.title' | t }}</h2>
<span class="drawer__heading">{{ 'sections.cart.title' | t }}</span>
<button
class="drawer__close"
type="button"
Expand Down Expand Up @@ -494,7 +494,7 @@
</div>

<div class="totals" role="status">
<h2 class="totals__total">{{ 'sections.cart.estimated_total' | t }}</h2>
<span class="totals__total">{{ 'sections.cart.estimated_total' | t }}</span>
<p class="totals__total-value">{{ cart.total_price | money_with_currency }}</p>
</div>

Expand Down
20 changes: 10 additions & 10 deletions snippets/facets.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,9 @@
{% endif %}
>
{%- if filter_type == 'horizontal' and results.filters != empty -%}
<h2 class="facets__heading caption-large text-body" id="verticalTitle" tabindex="-1">
<span class="facets__heading caption-large text-body" id="verticalTitle" tabindex="-1">
{{ 'products.facets.filter_by_label' | t }}
</h2>
</span>
{%- endif -%}
{% comment %} Pills are right below the title for filter type vertical {% endcomment %}
{%- if filter_type == 'vertical' -%}
Expand Down Expand Up @@ -388,9 +388,9 @@
{%- if enable_sorting -%}
<div class="facet-filters sorting caption">
<div class="facet-filters__field">
<h2 class="facet-filters__label caption-large text-body">
<span class="facet-filters__label caption-large text-body">
<label for="SortBy">{{ 'products.facets.sort_by_label' | t }}</label>
</h2>
</span>
<div class="select">
{%- assign sort_by = results.sort_by | default: results.default_sort_by -%}
<select
Expand Down Expand Up @@ -473,20 +473,20 @@
<div class="mobile-facets__inner gradient">
<div class="mobile-facets__header">
<div class="mobile-facets__header-inner">
<h2 class="mobile-facets__heading medium-hide large-up-hide">
<span class="mobile-facets__heading medium-hide large-up-hide">
{%- if enable_filtering and enable_sorting -%}
{{ 'products.facets.filter_and_sort' | t }}
{%- elsif enable_filtering -%}
{{ 'products.facets.filter_button' | t }}
{%- elsif enable_sorting -%}
{{ 'products.facets.sort_button' | t }}
{%- endif -%}
</h2>
<h2 class="mobile-facets__heading small-hide">
</span>
<span class="mobile-facets__heading small-hide">
{%- if enable_filtering -%}
{{ 'products.facets.filter_button' | t }}
{%- endif -%}
</h2>
</span>
<p class="mobile-facets__count">
{%- if results.results_count -%}
{{ 'templates.search.results_with_count' | t: terms: results.terms, count: results.results_count }}
Expand Down Expand Up @@ -824,9 +824,9 @@
<form id="FacetSortDrawerForm" class="facets__form">
<div class="facet-filters sorting caption small-hide">
<div class="facet-filters__field">
<h2 class="facet-filters__label caption-large text-body">
<span class="facet-filters__label caption-large text-body">
<label for="SortBy">{{ 'products.facets.sort_by_label' | t }}</label>
</h2>
</span>
<div class="select">
{%- assign sort_by = results.sort_by | default: results.default_sort_by -%}
<select
Expand Down
8 changes: 4 additions & 4 deletions snippets/header-drawer.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -172,9 +172,9 @@
<localization-form>
{%- form 'localization', id: 'HeaderCountryMobileForm', class: 'localization-form' -%}
<div>
<h2 class="visually-hidden" id="HeaderCountryMobileLabel">
<span class="visually-hidden" id="HeaderCountryMobileLabel">
{{ 'localization.country_label' | t }}
</h2>
</span>
{%- render 'country-localization', localPosition: 'HeaderCountryMobile' -%}
</div>
{%- endform -%}
Expand All @@ -185,9 +185,9 @@
<localization-form>
{%- form 'localization', id: 'HeaderLanguageMobileForm', class: 'localization-form' -%}
<div>
<h2 class="visually-hidden" id="HeaderLanguageMobileLabel">
<span class="visually-hidden" id="HeaderLanguageMobileLabel">
{{ 'localization.language_label' | t }}
</h2>
</span>
{%- render 'language-localization', localPosition: 'HeaderLanguageMobile' -%}
</div>
{%- endform -%}
Expand Down

0 comments on commit c98a6d8

Please sign in to comment.