-
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
core(autocomplete): add chrome suggestions, invalid warning #11342
Conversation
All (the pull request submitter and all commit authors) CLAs are signed, but one or more commits were authored or co-authored by someone other than the pull request submitter. We need to confirm that all authors are ok with their commits being contributed to this project. Please have them confirm that by leaving a comment that contains only Note to project maintainer: There may be cases where the author cannot leave a comment, or the comment is not properly detected as consent. In those cases, you can manually confirm consent of the commit author(s), and set the ℹ️ Googlers: Go here for more info. |
CLAs look good, thanks! ℹ️ Googlers: Go here for more info. |
@connorjclark @paulirish example page with incorrect attributes: example page example page with only off autocomplete: example page example page where it passes: example page |
Here is some important documentation that will give more context about autocomplete prefix tokens, and their ordering https://cloudfour.com/thinks/autofill-what-web-devs-should-know-but-dont/#all-the-tokens Edit: Now switching to calling them "optional tokens" not "prefix tokens" |
tweak quotes in the form expecations file
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.
Last things then LGTM!
@@ -25,10 +25,161 @@ const UIStrings = { | |||
'effort, consider enabling autocomplete by setting the `autocomplete` ' + | |||
'attribute to a valid value.' + | |||
' [Learn more](https://developers.google.com/web/fundamentals/design-and-ux/input/forms#use_metadata_to_enable_auto-complete)', | |||
/** Label for a column in a data table; entries will be the autocomplete token suggestions based on heuristics. */ | |||
columnAutocompleteSuggestions: 'Autocomplete Suggested Token', |
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.
Can you remove Autocomplete
from both of these column header strings?
Summary
This pull request improves the autocomplete audit by suggesting correct attributes using chrome heuristics and pointing out incorrect autocomplete prefixes.
refactoring
Formerly, autocomplete enforced on every input type, now it is only enforced on input types that chrome heruristics determines needs an autofill attribute.
https://docs.google.com/document/d/1yiulNnV8uEy1jPaAEmWeHxHcQOzxpqvAV4hOFpXLJ1M/edit#heading=h.gjgriz8s7dlc
https://docs.google.com/document/d/1uu3rs3vX8tBhosnXTFvvZn6-UvE1lkd48WVbjbsd4Ds/edit
Related Issues/PRs
Issue #10450
Pull request #11062
Pull request #11186