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

Prevent corrections and completions in search field #9307

Merged
merged 1 commit into from Jun 13, 2021

Commits on Jun 7, 2021

  1. Prevent corrections and completions in search field

    In particular mobile browsers use correction mechanisms on input fields.
    Search will often be done with technical terms or even class/method/etc
    names that these correction mechanisms do not know, resulting in unwanted
    changes. This PR deactivates these correction mechanisms.
    
    While I haven't been able to find official reference documentation on
    these input attributes, there are multiple sources, describing this, e.g.
    
    References:
    
    - Autocomplete: https://www.w3schools.com/howto/howto_html_autocomplete_off.asp
    - Spellckeck: https://www.w3schools.com/howto/howto_html_spellcheck_disable.asp
    
    I did not find official reference docs on autocorrect and autocapitalize, but
    they are mentioned in various sources, e.g.
    
    - https://mgearon.com/html/disable-autocomplete-autocapitalize-and-autocorrect/
    - https://stackoverflow.com/questions/35513968/disable-auto-correct-in-safari-text-input
    - https://davidwalsh.name/disable-autocorrect
    
    and it works, as can easily be checked with a mobile device on the demos in the above
    links.
    timhoffm committed Jun 7, 2021
    Copy the full SHA
    488df3f View commit details
    Browse the repository at this point in the history