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

Small accessibility improvements #104772

Merged

Conversation

GuillaumeGomez
Copy link
Member

From this reddit post, I started to check a bit how to improve accessibility and how we could add test for it.

So these two fixes come from the use of the pa11y tool. To make it work, I had to update its puppeteer version to the last one but otherwise it seems to be quite nice. I didn't fix all the errors it reported because they were about colors. To get the same result as mine, you can use this config:

{
    "ignore": [
	"WCAG2AA.Principle1.Guideline1_4.1_4_3.G18.Fail",
	"WCAG2AA.Principle3.Guideline3_2.3_2_2.H32.2"
     ]
}

I think trying to improve accessibility is something we should definitely aim for. I'll try to integrate a tool to enforce this check (very likely pa11y) directly into the CI.

cc @jsha
r? @notriddle

 * Set aria-label attribute on search input
 * Put anchor text directly into the DOM and not in the CSS
@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. labels Nov 23, 2022
@rustbot
Copy link
Collaborator

rustbot commented Nov 23, 2022

Some changes occurred in HTML/CSS/JS.

cc @GuillaumeGomez, @Folyd, @jsha

@notriddle
Copy link
Contributor

These look okay to me (though this change probably doesn't address the issue of not being able to read the function signatures character-by-character).

@bors r+ rollup

@bors
Copy link
Contributor

bors commented Nov 23, 2022

📌 Commit aa73e29 has been approved by notriddle

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Nov 23, 2022
@GuillaumeGomez
Copy link
Member Author

These look okay to me (though this change probably doesn't address the issue of not being able to read the function signatures character-by-character).

It absolutely doesn't. For this issue I'm waiting for more information (mostly on the testing part).

Dylan-DPC added a commit to Dylan-DPC/rust that referenced this pull request Nov 24, 2022
…-improvement, r=notriddle

Small accessibility improvements

From this [reddit post](https://www.reddit.com/r/rust/comments/z1gyz7/accessible_documentation/), I started to check a bit how to improve accessibility and how we could add test for it.

So these two fixes come from the use of the [pa11y tool](https://github.com/pa11y/pa11y). To make it work, I had to update its puppeteer version to the last one but otherwise it seems to be quite nice. I didn't fix all the errors it reported because they were about colors. To get the same result as mine, you can use this config:

```json
{
    "ignore": [
	"WCAG2AA.Principle1.Guideline1_4.1_4_3.G18.Fail",
	"WCAG2AA.Principle3.Guideline3_2.3_2_2.H32.2"
     ]
}
```

I think trying to improve accessibility is something we should definitely aim for. I'll try to integrate a tool to enforce this check (very likely `pa11y`) directly into the CI.

cc `@jsha`
r? `@notriddle`
bors added a commit to rust-lang-ci/rust that referenced this pull request Nov 24, 2022
…iaskrgr

Rollup of 9 pull requests

Successful merges:

 - rust-lang#103908 (Suggest `.clone()` or `ref binding` on E0382)
 - rust-lang#104517 (Throw error on failure in loading llvm-plugin)
 - rust-lang#104594 (Properly handle `Pin<&mut dyn* Trait>` receiver in codegen)
 - rust-lang#104742 (Make `deref_into_dyn_supertrait` lint the impl and not the usage)
 - rust-lang#104753 (Pass `InferCtxt` to `DropRangeVisitor` so we can resolve vars)
 - rust-lang#104771 (Add regression test for issue rust-lang#99938)
 - rust-lang#104772 (Small accessibility improvements)
 - rust-lang#104775 (Use ObligationCtxt::normalize)
 - rust-lang#104778 (:arrow_up: rust-analyzer)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit a337156 into rust-lang:master Nov 24, 2022
@rustbot rustbot added this to the 1.67.0 milestone Nov 24, 2022
@GuillaumeGomez GuillaumeGomez deleted the small-accessibility-improvement branch November 24, 2022 12:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants