Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cc-img: use text value as alt value for the inner <img> tag #726

Closed
florian-sanders-cc opened this issue Mar 15, 2023 · 0 comments · Fixed by #873 or #876
Closed

cc-img: use text value as alt value for the inner <img> tag #726

florian-sanders-cc opened this issue Mar 15, 2023 · 0 comments · Fixed by #873 or #876
Assignees
Labels
a11y Related to accessibility bug Something isn't working

Comments

@florian-sanders-cc
Copy link
Contributor

florian-sanders-cc commented Mar 15, 2023

Context

The cc-img component has a text prop that is used to display a text when the image is not loaded.
The alt attribute of the <img> tag inside the component is always empty and there is no way to set it from outside the component.

Solutions

Either use text value as alt value (when there is no error), or introduce a separate accessible-name prop.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
a11y Related to accessibility bug Something isn't working
Projects
None yet
2 participants