Open ogonkov opened 5 months ago
@ogonkov Images with empty strings in alt
attribute are not accessible. Why you want it?
It has presentation role, this is valid usage
It has presentation role, this is valid usage
Has it? We don't allow set this prop
Yes. In some cases you don't want to expose image to a11y technologies.
In case of avatar this could be the case when it followed by user name, for example and setting alt text for avatar is obsolete.
@ogonkov We decided to remove alt
prop entirely from the component props
I can't set
alt
to empty string, because it trying to fallback totitle
https://github.com/gravity-ui/uikit/blob/733c5b3bd425ee57d660ed176d15bc99084f6d9a/src/components/Avatar/Avatar.tsx#L43