0

I have tried a few options available in the following links. 1. Disable speech to text button (Micro phone) on soft input keyboard in android programmatically 2. How to disable displaying "suggestions" on the Soft Keyboard

doesn't seem to work.

<TextField fieldFocusClass returnKeyType="done" autocorrect="false" formControlName="pin" > </TextField>

1 Answers1

0

Well privateImeOptions doesn't seem to work with current version of Android. You could set input type to TYPE_TEXT_VARIATION_VISIBLE_PASSWORD

HTML

<TextField (loaded)="onLoaded($event)"></TextField>

TS

onLoaded(event) {
    const textField = event.object;
    if (textField.android) {
        setTimeout(() => {
            textField.android.setInputType(android.text.InputType.TYPE_TEXT_VARIATION_VISIBLE_PASSWORD);
        }, 500);
    }
}

Note: If you like to avoid timeout, you might want to extend existing textfield to create your own that applies custom input type.

Manoj
  • 21,753
  • 3
  • 20
  • 41