RFR: JDK-8299718: JavaDoc: Buttons to copy specific documentation URL are not accessible
Hannes Wallnöfer
hannesw at openjdk.org
Fri Mar 24 15:37:49 UTC 2023
Please review a change to address accessibility issues with the copy-to-clipboard buttons in JavaDoc-generated documentation. The most important change is to make these button work for keyboard users, which means buttons must exist in the DOM regardless of mouse position, be visible and readable on keyboard focus (via tab key) and show feedback after keyboard activation (via space or enter key).
It also includes a few smaller improvements. The buttons for headings now show a "Copy" label when directly hovered above, and there is a slightly more helpful "Copy URL" or "Copy snippet" label as `aria-label` attribute.
Incidentally I discovered that the regex pattern in `CheckStylesheetClasses.java` did not pick up all CSS classes, so I simplified the pattern and added a few previously undetected classes to the test.
-------------
Commit messages:
- JDK-8299718: JavaDoc: Buttons to copy specific documentation URL are not accessible
Changes: https://git.openjdk.org/jdk/pull/13176/files
Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=13176&range=00
Issue: https://bugs.openjdk.org/browse/JDK-8299718
Stats: 107 lines in 10 files changed: 28 ins; 32 del; 47 mod
Patch: https://git.openjdk.org/jdk/pull/13176.diff
Fetch: git fetch https://git.openjdk.org/jdk.git pull/13176/head:pull/13176
PR: https://git.openjdk.org/jdk/pull/13176
More information about the javadoc-dev
mailing list