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

Accessibility issue with lgPage component #427

Open
NemirStephan opened this issue Jun 22, 2021 · 2 comments
Open

Accessibility issue with lgPage component #427

NemirStephan opened this issue Jun 22, 2021 · 2 comments
Labels

Comments

@NemirStephan
Copy link
Contributor

I am getting a 'All page content should be contained by landmarks` error in axe dev tools when using the lgPage component

Element location

.lg-page__skip-link

Element source

<a class="lg-page__skip-link"> Skip to main content </a>

I think the issue is because the a tag is not wrapped inside the main content area which contains the main aria role
Screenshot 2021-06-22 at 17 01 08

The fix should be to either declare the main role at the component root, or add another role such as banner to the anchor tag

@elenagarrone
Copy link
Contributor

Yes, I agree. Ideally it should be in the header before the navigation.

@pauleustice
Copy link
Contributor

@Legal-and-General/canopy-regular-contributors This sounds like a legit issue that should be quite easy to fix. I'm not sure the best way to place it in the lg-header as per Elena's suggestion, though.

Will the header component always precede a [role=main]? Maybe it should be an input to toggle whether it's shown in the header?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants