Add API to control spell checkers and other platform-provided text input assistants #2805
Labels
enhancement
New features, or improvements to existing features.
good first issue
Is this your first time contributing? This could be a good place to start!
What is the problem or limitation you are having?
It is common for test input fields to have spellcheck helpers, especially on mobile platforms. This is extremely useful when the input is human-readable text, but if an input is something like an input of a family name, or ID number, or anything else that is decidedly not a natural language word, red underlined words and spell check corrections can be something between an annoyance and an active hindrance.
Describe the solution you'd like
TextInput and MultilineTextInput should have a mechanism to disable auto spell check.
A boolean flag to the TextInput constructor (
spell_checking=False
) would be sufficient to control spelling specifically.Describe alternatives you've considered
It may be worth investigating if there are other input features that we might want to turn off (e.g., autocorrect, autocomplete, autocapitalisation, predictive text). Depending on how many of these features exist, and how common they are across platforms, it might be worthwhile considering adding support for those features as well.
If a platform doesn't provide the feature at all, the feature should be ignored (and documented as such as a platform quirk).
Additional context
Originally reported as #2801.
In that ticket, @rmartin16 provided the functional implementation for Android:
The
InputType
enum seems to have a number of other options that can be disabled.iOS provides
spellCheckingType
,autocorrectionType
and a number of other properties for configuration automated tools.The text was updated successfully, but these errors were encountered: