Fixed aria-hidden="true" set on focusable links

Kirby

Well-known member
Affected version
2.3.3
HTML:
<xf:macro id="attribution" arg-profilePost="!" arg-showTargetUser="{{ false }}">
    <xf:if is="$showTargetUser AND $profilePost.user_id != $profilePost.profile_user_id">
        <xf:username user="$profilePost.User" rich="true" defaultname="{$profilePost.username}" aria-hidden="true" />
        <xf:fa icon="{{ $xf.isRtl ? 'fa-caret-left' : 'fa-caret-right' }} u-muted" />
        <xf:username user="$profilePost.ProfileUser" rich="true" defaultname="{{ phrase('unknown') }}" aria-hidden="true" />

The links generated by xf:username are focusable so they probably shouldn't have aria-hidden="true" as per https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Attributes/aria-hidden:

Warning: Do not use aria-hidden="true" on focusable elements.
 
Thank you for reporting this issue, it has now been resolved. We are aiming to include any changes that have been made in a future XF release (2.3.4).

Change log:
Do not mark unhidden usernames as `aria-hidden`
There may be a delay before changes are rolled out to the XenForo Community.
 
Back
Top Bottom