You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This would be a destructive change in code, but I think it would be worse if accessibility checks such as Lighthouse and axe had something in aria-label that on the surface looks fine and goes unnoticed.
I think we should let the developers who use the library think about the button description.
Add notes on aria-label to README.
If it is difficult to make changes to the code, I think it would be a good idea to add a note in the README that aria-label is already set.
If the existing service name aria-label is not enough to explain, you may need to override it with aria-label.
The text was updated successfully, but these errors were encountered:
Nice to meet you! I just found out about this library today 👍🏼
The share button in this library has an
aria-label
, but I feel that this response doesn't explain enough about what the button is supposed to do.For example, the Twitter share button is converted to the following in demo page.
This seems to be the minimum way to ensure accessibility.
But what if you use it in the following way?
This would translate to the following.
What I'm trying to tell you is that the button description exists separately in the button's
aria-label
and in the internal text.To make matters worse, the button only reads "twitter" when read out loud by assistive technologies (For example, a screen reader).
My suggestions for improvement on this issue are as follows
Remove
aria-label
fromShareButton.tsx
.Specifically, remove this part.
react-share/src/ShareButton.tsx
Line 221 in 2f8e906
This would be a destructive change in code, but I think it would be worse if accessibility checks such as Lighthouse and axe had something in
aria-label
that on the surface looks fine and goes unnoticed.I think we should let the developers who use the library think about the button description.
Add notes on
aria-label
to README.If it is difficult to make changes to the code, I think it would be a good idea to add a note in the README that
aria-label
is already set.If the existing service name
aria-label
is not enough to explain, you may need to override it witharia-label
.The text was updated successfully, but these errors were encountered: