FIX: Disable third party keyboard on iOS

FIX: Disable suggestions on android
This commit is contained in:
Marcos Rodriguez Vélez 2019-02-27 19:45:44 -05:00 committed by Igor Korsakov
parent e93bfa656b
commit b9b94011c4
2 changed files with 19 additions and 0 deletions

View file

@ -339,6 +339,17 @@ export class BlueFormInput extends Component {
}
export class BlueFormMultiInput extends Component {
constructor(props) {
super(props);
this.state = {
selection: { start: 0, end: 0 },
};
}
onSelectionChange = ({ nativeEvent: { selection, text } }) => {
this.setState({ selection: { start: selection.end, end: selection.end } });
};
render() {
return (
<TextInput
@ -360,6 +371,10 @@ export class BlueFormMultiInput extends Component {
autoCapitalize="none"
spellCheck={false}
{...this.props}
selectTextOnFocus={false}
onSelectionChange={this.onSelectionChange}
selection={this.state.selection}
keyboardType={Platform.OS === 'android' ? 'visible-password' : 'default'}
/>
);
}

View file

@ -42,4 +42,8 @@
return [RCTLinkingManager application:app openURL:url options:options];
}
- (BOOL)application:(UIApplication *)application shouldAllowExtensionPointIdentifier:(UIApplicationExtensionPointIdentifier)extensionPointIdentifier {
return NO;
}
@end