Skip to content

Commit

Permalink
Merge pull request #592 from yannicka/accessibility-aria
Browse files Browse the repository at this point in the history
Accessibility: add some "aria-label"
  • Loading branch information
Hlavtox authored Feb 23, 2024
2 parents 4025c22 + 0dc1dc7 commit 733a70c
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
3 changes: 2 additions & 1 deletion modules/ps_customersignin/ps_customersignin.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@
id="userMenuButton"
data-bs-toggle="dropdown"
aria-haspopup="true"
aria-expanded="false">
aria-expanded="false"
aria-label="{l s='View my account (%s)' d='Shop.Theme.Customeraccount' sprintf=[$customerName]}">
<i class="material-icons header-block__icon" aria-hidden="true">&#xE7FD;</i>
<span class="header-block__title d-lg-inline d-none">{$customerName|truncate:22:"..":true}</span>
</a>
Expand Down
7 changes: 3 additions & 4 deletions modules/ps_imageslider/views/templates/hook/slider.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -33,13 +33,12 @@
{/foreach}
</div>

<button class="carousel-control-prev" type="button" data-bs-target="#home-slider .carousel" data-bs-slide="prev">
<button class="carousel-control-prev" type="button" data-bs-target="#home-slider .carousel" data-bs-slide="prev" aria-label="{l s='Previous' d='Shop.Theme.Actions'}">
<span class="carousel-control-prev-icon" aria-hidden="true"></span>
<span class="visually-hidden">{l s='Previous' d='Shop.Theme.Actions'}</span>
</button>
<button class="carousel-control-next" type="button" data-bs-target="#home-slider .carousel" data-bs-slide="next">

<button class="carousel-control-next" type="button" data-bs-target="#home-slider .carousel" data-bs-slide="next" aria-label="{l s='Next' d='Shop.Theme.Actions'}">
<span class="carousel-control-next-icon" aria-hidden="true"></span>
<span class="visually-hidden">{l s='Next' d='Shop.Theme.Actions'}</span>
</button>
</div>
</div>
Expand Down
2 changes: 1 addition & 1 deletion modules/ps_shoppingcart/ps_shoppingcart.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<div id="_desktop_cart">
<div class="header-block blockcart cart-preview {if $cart.products_count> 0}header-block--active{else}inactive{/if}" data-refresh-url="{$refresh_url}">
{if $cart.products_count> 0}
<a class="header-block__action-btn" rel="nofollow" href="{$cart_url}">
<a class="header-block__action-btn" rel="nofollow" href="{$cart_url}" aria-label="{l s='View cart (%d products)' d='Shop.Theme.Checkout' sprintf=[$cart.products_count]}">
{else}
<span class="header-block__action-btn">
{/if}
Expand Down
2 changes: 1 addition & 1 deletion templates/_partials/header.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
<div class="search__mobile d-md-none col-auto">

<div class="header-block">
<a class="header-block__action-btn" href="#" role="button" data-bs-toggle="offcanvas" data-bs-target="#searchCanvas" aria-controls="searchCanvas">
<a class="header-block__action-btn" href="#" role="button" data-bs-toggle="offcanvas" data-bs-target="#searchCanvas" aria-controls="searchCanvas" aria-label="{l s='Show search bar' d='Shop.Theme.Global'}">
<span class="material-icons header-block__icon">search</span>
</a>
</div>
Expand Down

0 comments on commit 733a70c

Please sign in to comment.