-
Notifications
You must be signed in to change notification settings - Fork 1
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
fix: Minor accessibility warnings #141
base: main
Are you sure you want to change the base?
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
Preview is readyThis pull request generated a Preview👀 Preview: https://sfj-64fb2f8--nextjs.preview.vtex.app |
Lighthouse ReportsHere are the Lighthouse reports of this Pull Request📝 Based on commit 38b5f7f
|
We already print the description of the violation, but it's not immediately clear which element is causing it. e.g. in https://github.com/vtex-sites/nextjs.store/pull/141/checks?check_run_id=7010437942 we had a color contrast violation but no pointer which element is causing it.
Attempt to fix [this][1] flaky axe's accessibility issue of color contrast. Apparently because the input is not totally hidden, it's getting picked up by axe and failing the color contrast check because there's no text and due the small dimension (0 width). Setting the opacity to 0 seems to fix and there seems to be no visual/functional drawback. dequelabs/axe-core#3514 [1]: https://github.com/vtex-sites/nextjs.store/runs/7015698254#:~:text=description%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%E2%94%82%20nodes%20%E2%94%82%0A%E2%94%9C%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%BC%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%BC%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%BC%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%BC%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%80%E2%94%A4%0A%E2%94%82%20%20%20%200%20%20%20%20%E2%94%82%20%27-,color%2Dcontrast,-%27%20%E2%94%82%20%27serious%27%20%E2%94%82%20%27Ensures%20the
@@ -37,6 +37,15 @@ function logToTerminal(violations) { | |||
nodes: nodes.length, | |||
})) | |||
) | |||
for (const violation of violations) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
😍 thank youu!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Terrific work, Filipe. I tried really hard to read the table you linked on item 2, but I couldn't understand it. I tried reading the description of the table above it, but still, I couldn't figure out what each column means and how this affects what you did here. Maybe we can meet to discuss this later on?
Our Hero component makes use of a header element with an aria-labelledby attribute, but that's not a valid combination because the header has no role when it's a descendant of an article.
Welll doneee! This will be so helpful @filipewl 😍😍😍 Regarding the 2 warning left:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good Job! 👏
What's the purpose of this pull request?
Fix some minor accessibility warnings reported by axe DevTools:
nav
elements that are used in the footer's links are considered landmarks and all landmarks must have a unique accessible name.Hero
component makes use of aheader
element with anaria-labelledby
attribute, but that's not a valid combination because theheader
has no role when it's a descendant of anarticle
.There are still going to be 2 warnings left being reported by axe:
PaymentMethods
component inside@faststore/ui
.Incentives
component.References