-
-
Notifications
You must be signed in to change notification settings - Fork 5.3k
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
[AutocompleteInput]: Chrome Address Autofill should be disabled by default #5620
Comments
AutocompleteInput
s
Can you try the following? <AutocompleteInput
optionText={ownerRenderer}
options={AutocompleteOptions}
/> Where const AutocompleteOptions = { InputProps: { autoComplete: 'no' } } |
Yeah, then it works. Thanks @djhi Although it would still be nice to make it a default. I wanted to submit a PR, but I was hard for me to tell what would be the place to put it. |
I agree, I faced the same and it seems that |
…fInSearchInput Revert "Fix for autocomplete off #5620"
FYI it has to be |
Jesus, Chrome is terrible. See https://stackoverflow.com/questions/30053167/autocomplete-off-vs-false . If it's a If it's a Seriously. I think in the simpleform, it treats it as address autocomplete, and chrome forces autocomplete even if the input has And in the filters, it uses some different autocomplete mechanism, which you have to simply turn off with the way it should be disabled, using |
We can't do that in the AutocompleteInput, so I guess this boils down to documenting the solution. @jtomaszewski would you mind opening a PR for that? |
I'm sure we could provide at least one default, that works in at least some of the cases? Also, are you sure we can't tell from the So we could do the following inside of https://github.com/marmelab/react-admin/blob/master/packages/ra-ui-materialui/src/input/AutocompleteInput.tsx#L525 :
That would make it work out of the box in:
Which is already better than, work nowhere by default. WDYT? Would u accept a PR for that? @fzaninotto |
I can't reproduce the bug. Could you explain how to reproduce it? |
@jtomaszewski, could you explain how to reproduce this bug? |
No news for some time, closing. |
We have AutocompleteInput defined in such a way:
which now ends up in two autocomplete dropdowns being shown at the same time (one of them being the chrome adress autofill dropdown):
This is because the
<input />
hasautocomplete="off"
when it should beautocomplete="no"
(see this for reasoning):If I change it manually in Chrome dev tools to
autocomplete="no"
, then the issue is resolved.IMO Native autocomplete should be turned off for such fields by default. (I don't even know how to turn it off myself - passing
inputProps={{ autocomplete: "no", autoComplete: "no" }}
toAutocompleteInput
does nothing.Environment
The text was updated successfully, but these errors were encountered: