-
Notifications
You must be signed in to change notification settings - Fork 9.4k
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
[SEO Audits] Tap targets are sized appropriately #4358
Comments
When this issue is resolved let's also remove the manual audit for mobile friendly test. |
I finished the audit, but after testing had to add couple of tweaks:
@rviscomi let me know if these SGTY As mentioned, I started testing on real websites (some of the Alexa's top500). Unfortunately, the results are similar to the font-size v1. Everyone fails and they fail bad 😢 See: https://imgur.com/a/0YoNY (tap targets are marked with: red - too small, yellow - good size but too close, green - OK) Some thoughts:
@rviscomi We may want to lax this audit a bit not to fail everyone. I don't know what was PSI team's algorithm for this, but they sure were not reporting that many failures. BTW PSI doesn't seem to report these issues anymore, nor does mobile-friendly test 🤔 |
Chatted offline about this. Some notes for posterity:
|
UpdateI adjusted the algorithm as discussed and now it boils down to:
Caveats identified
ResultsBlue square represents a finger. Red rectangles are failing tap targets, green rectangles are passing tap targets. Wikipedia main page - 9% of tap targets are too closeWikipedia article - 43% of tap targets are too closeApple main page - 17% of tap targets are too closeGoogle main page - 7% of tap targets are too closeYahoo main page - 50% of tap targets are too closeWAPO article page - 28% of tap targets are too closeNYT article page - 36% of tap targets are too closehuffpost article page - 18% of tap targets are too close |
Hey folks. We're currently evaluating what UX audits Lighthouse should be prioritizing and I recall tap-targets being pretty high in prio (and overlapped nicely with PSI parity). I'm aware @kdzwinel and @rviscomi had put a lot of time into researching efficacy of the implementation here - is there a status update on where we're at with this work? |
Hey @addyosmani, I think we're very close and just need to resolve a few of the questions/caveats noted in the previous comments. We're still prioritizing v1 of the structured data audit, which we expect to ramp down by the end of the month, so we should pick this audit back up by then. |
SG. Thanks for the update, @rviscomi! |
Just to update, the SD audit is still being worked on so this hasn't been finished yet. @kdzwinel what is left to do for this audit and what's your ETA? |
+1 to including the inner text if possible. Another idea is to link the node in the Elements panel. Some targets may be The repeated "Target is too small" text is also redundant so I think we can just include the target's dimensions. |
Is it possible to have two tables in the same audit, one for each failure reason? Otherwise maybe we can add more columns, for example:
|
We don't check for minimum size anymore, just tap targets being too close. I wasn't part of the original discussion, but I imagine that already detects a lot of tap targets that are too small, and if there are no other tap targets nearby maybe that's not a problem because the phone knows which one the user meant to tap on? |
Ok, that makes the messaging easier if we're just focusing on one thing. When showing the elements, are we able to make them linkable to the Elements panel in CDT when available? Anything to provide more context to the elements so developers can more easily identify and fix the issues. Do we have any checks in place to limit the character length of the elements' HTML? I can imagine some elements having lots of children and making the table illegible. When communicating how close the elements are, we should also be careful to say that the page was tested with specific viewport dimensions. The page may be laid out differently for different viewport sizes and the elements may change. |
Yeah we have code to link the outerHTML to the DOM node, but that feature is broken at the moment. I don't think we do any truncation for the accessibility audit. Cutting off the text risks hiding important info like the text content, but limiting it to a high value like 1000 characters can't hurt. |
To illustrate the outstanding edge cases: Title is broken over two lines, giving two finger areas which cause an overlap, even though clicking on the link is fine. (And in this case it would be a failure anyway because the content below is very close.) Content overflows. Client rects/bounding client rects only cover original area. We can get the correct rect by selecting the contents and getting client rects on the selection. But in some cases selections can cover unexpected areas of the page. Might be fixable if we spend more time on it, but don't think it's essential initially. Two things here:
|
Thanks for documenting these @mattzeunert. These would be good to include in any Lighthouse docs (cc @kaycebasques) but not necessarily launch-blocking v1 of the audit. As discussed in the meeting today, let's move this forward adding tests and accounting for paragraph targets per WCAG. |
Status
New edge cases Multiple finger areas are causing a lot of problems. Proposed solution:
Another issue is how we handle This CNN article has a nav at the top that's outside the viewport, but the nav contains lots of scrollable content reaching down into the viewport. To fix that I marked tap targets that are within an Now France24 puts almost all page content in a scrollable container, so most tap targets on that page are marked as invisible. I think that's fine for now? Better to avoid penalizing than penalizing too much. |
Audit group: Mobile friendly
Description: Tap targets are sized appropriately
Failure description: Tap targets are not sized appropriately
Help text: Interactive elements like buttons and links should be large enough, and have enough space around them, to be easy enough to tap without overlapping onto other elements. Learn more.
Success conditions:
If possible, the weighting for this audit should be proportional to the number of interactive element failures.
Interactive elements:
For reference, see: https://developers.google.com/web/fundamentals/accessibility/accessible-styles#multi-device_responsive_design
The text was updated successfully, but these errors were encountered: