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

Add base Axe accessibility checker integration within userbar, with error count #9850

Merged
merged 8 commits into from Jan 12, 2023

Conversation

albinazs
Copy link
Contributor

@albinazs albinazs commented Jan 5, 2023

  • Integrate Axe in the userbar, calling axe.run, logging its results to the console
  • Exclude shadowDOM from the testing context
  • Display the native error count next to the userbar toggle, and a very basic rendering of the results when clicking the new "Accessibility" menu item inside the userbar

image

@squash-labs
Copy link

squash-labs bot commented Jan 5, 2023

Manage this branch in Squash

Test this branch here: https://albinazsfeatureaxe-a11y-checke-wdoko.squash.io

@zerolab zerolab changed the title Draft to discuss Draft to discuss: Axe accessibility checker integration Jan 5, 2023
@albinazs albinazs changed the title Draft to discuss: Axe accessibility checker integration Axe accessibility checker integration: milestones 1,2 Jan 6, 2023
@albinazs albinazs marked this pull request as ready for review January 6, 2023 17:17
@thibaudcolas thibaudcolas self-requested a review January 12, 2023 11:27
@thibaudcolas thibaudcolas added this to the 4.2 milestone Jan 12, 2023
Copy link
Member

@thibaudcolas thibaudcolas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking good – minor refactorings needed, and we need to only initialise Axe if the menu item is configured.

wagtail/admin/userbar.py Show resolved Hide resolved
wagtail/admin/templatetags/wagtailuserbar.py Show resolved Hide resolved
wagtail/admin/static_src/wagtailadmin/scss/userbar.scss Outdated Show resolved Hide resolved
wagtail/admin/static_src/wagtailadmin/scss/userbar.scss Outdated Show resolved Hide resolved
wagtail/admin/static_src/wagtailadmin/scss/userbar.scss Outdated Show resolved Hide resolved
client/src/entrypoints/admin/userbar.js Show resolved Hide resolved
client/src/entrypoints/admin/userbar.js Outdated Show resolved Hide resolved
client/src/entrypoints/admin/userbar.js Outdated Show resolved Hide resolved
wagtail/admin/static_src/wagtailadmin/scss/userbar.scss Outdated Show resolved Hide resolved
client/src/entrypoints/admin/userbar.js Show resolved Hide resolved
Copy link
Member

@thibaudcolas thibaudcolas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice one! Tested in Firefox 108, Safari 16.2, Chrome 108 on macOS 13.1 – after the changes we made together.

@thibaudcolas thibaudcolas changed the title Axe accessibility checker integration: milestones 1,2 Add base Axe accessibility checker integration within userbar, with error count Jan 12, 2023
@thibaudcolas thibaudcolas merged commit 1e9f580 into wagtail:main Jan 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Development

Successfully merging this pull request may close these issues.

None yet

2 participants