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

missing alt text #463

Closed
CBID2 opened this issue Jan 11, 2024 · 10 comments · Fixed by #465
Closed

missing alt text #463

CBID2 opened this issue Jan 11, 2024 · 10 comments · Fixed by #465
Assignees
Labels
2024-tidb-docs-dash contribution Indicates that the issue or PR was contributed by an external member. tidb-docs-dash-bonus Indicates that the issue or PR with bonus points

Comments

@CBID2
Copy link
Contributor

CBID2 commented Jan 11, 2024

Describe the bug
I did an accessibility test on the website, and the results showed that most of the images/icons were missing alt text. Without them, the content of an image will not be available to screen reader users or when the image is unavailable. This can cause these users to have a harder time navigating the site.
To Reproduce
N/A

Expected behavior
N/A

Screenshots
screenshot of accessibility issue

Desktop (please complete the following information):

  • OS: [e.g. iOS]
  • Browser [e.g. chrome, safari]
  • Version [e.g. 22]

Smartphone (please complete the following information):

  • Device: Mac
  • OS: N/A
  • Browser N/A
  • Version N/A

Additional context
Add any other context about the problem here.

@CBID2
Copy link
Contributor Author

CBID2 commented Jan 11, 2024

Hi @rpaik! :) I raised the issue per your suggestion! :)

@dveeden
Copy link

dveeden commented Jan 11, 2024

@CBID2 pingcap/docs#4389 might also be somewhat related. This would replace images with ebnf text that than gets rendered. See https://github.com/pingcap/docs/pull/16050/files for an example.

@dveeden
Copy link

dveeden commented Jan 11, 2024

This is https://wave.webaim.org/ right?

@CBID2
Copy link
Contributor Author

CBID2 commented Jan 11, 2024

@CBID2 pingcap/docs#4389 might also be somewhat related. This would replace images with ebnf text that than gets rendered. See https://github.com/pingcap/docs/pull/16050/files for an example.

Thanks for pointing this out @dveeden! :) So...does this mean I should not do a PR for this one?

@dveeden
Copy link

dveeden commented Jan 11, 2024

@CBID2 pingcap/docs#4389 might also be somewhat related. This would replace images with ebnf text that than gets rendered. See https://github.com/pingcap/docs/pull/16050/files for an example.

Thanks for pointing this out @dveeden! :) So...does this mean I should not do a PR for this one?

No what I was trying to say is that fixing this issue and the issue I mentioned both help with improving accessibility. Both are needed.

The ebnf diagrams are only replacing a small portion of the total set of images.

@CBID2
Copy link
Contributor Author

CBID2 commented Jan 11, 2024

@CBID2 pingcap/docs#4389 might also be somewhat related. This would replace images with ebnf text that than gets rendered. See https://github.com/pingcap/docs/pull/16050/files for an example.

Thanks for pointing this out @dveeden! :) So...does this mean I should not do a PR for this one?

No what I was trying to say is that fixing this issue and the issue I mentioned both help with improving accessibility. Both are needed.

Ohh thanks for clarifying @dveeden! :)

@CBID2
Copy link
Contributor Author

CBID2 commented Jan 11, 2024

/assign

@qiancai qiancai added the contribution Indicates that the issue or PR was contributed by an external member. label Jan 11, 2024
@Yuiham
Copy link
Collaborator

Yuiham commented Jan 12, 2024

@CBID2 Thanks a lot for reporting this issue.

I found there's no problem with images in markdown. The problem occurs on those image component written in JSX.
For example, the alt prop is missing on the following image component.

So we need to add an alt prop to the image component and assign alt a value using the label variable. Can you try it this way?

@CBID2
Copy link
Contributor Author

CBID2 commented Jan 12, 2024

@CBID2 Thanks a lot for reporting this issue.

I found there's no problem with images in markdown. The problem occurs on those image component written in JSX.

For example, the alt prop is missing on the following image component.

So we need to add an alt prop to the image component and assign alt a value using the label variable. Can you try it this way?

Sure @Yuiham! :) Can you also put the 2024-tidb-docs-dash label on my PR too? For some odd reason, it got removed.

@Yuiham
Copy link
Collaborator

Yuiham commented Jan 13, 2024

@CBID2 Done😀

@qiancai qiancai added the tidb-docs-dash-bonus Indicates that the issue or PR with bonus points label Jan 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
2024-tidb-docs-dash contribution Indicates that the issue or PR was contributed by an external member. tidb-docs-dash-bonus Indicates that the issue or PR with bonus points
Development

Successfully merging a pull request may close this issue.

4 participants