dokka icon indicating copy to clipboard operation
dokka copied to clipboard

Accessibility violations

Open lauzadis opened this issue 1 year ago • 2 comments

Is your feature request related to a problem? Please describe We were recently made aware that the documentation generated by Dokka violates various accessibility standards.

  1. Ensure all interactive functionality is operable with the keyboard: W3C's SC 2.1.1
    • Arrow icons to expand/collapse side menu sections
    • "X" button to clear the search field
  2. Ensure custom controls provide proper textual name, role, and state information: W3C's SC 4.1.2
    • X button to clear the search field
    • Arrow icons to expand/collapse side menu sections lack name, role, state information
  3. Provide a mechanism for skipping past repetitive content W3C's SC 2.4.1
    • Side menu items can not be skipped. Our package has over 300 modules and navigating with the Tab key means touching each of these items before reaching the main content.
  4. Ensure keyboard focus is indicated visually W3C's SC 2.4.7
    • "Types" and "Functions" filter buttons don't have an outline.
    • I will submit a PR for this
  5. Ensure pages reflow without requiring two-dimensional scrolling without loss of content or functionality W3C's SC 1.4.10
    • Links and code blocks are not properly wrapped, leading to two-dimensional scrollbar appearing on small screens. Reflow style can be added to make this wrap properly.
    • I will submit a PR for this

Describe the solution you'd like It would be great if these violations could be addressed, it's especially useful for screen reader users.

Describe alternatives you've considered None

Additional context AWS SDK for Kotlin has fixed a variety of these accessibility issues by customizing Dokka's HTML / CSS files, but it would be good to get this upstreamed. I will be submitting a number of PRs which address these violations, you can take them if you like, or come up with your own solutions.

Here is a link to our docs where you can see the various violations listed: https://sdk.amazonaws.com/kotlin/api/1.0.17/index.html

Are you willing to provide a PR? For some of them, yes. Some are more difficult to solve (such as skipping past repetitive content) and would require design discussion.

lauzadis avatar Dec 15 '23 19:12 lauzadis

Thank you for the report and the contributions, Matas! Much appreciated!

The team is now actually working on addressing a bunch of UI/UX-related issues at large for the stable release of Dokka, so some if these might be covered in the updated design, but if they are not - we should definitely consider it and keep it in mind. cc @paveluxd, @d-ambatenne

IgnatBeresnev avatar Dec 18 '23 23:12 IgnatBeresnev

@IgnatBeresnev is there an update on when the new UI designs will be released and the WCAG violations noted above will be fixed?

ianbotsf avatar Mar 19 '24 18:03 ianbotsf