Open huytdps13400 opened 1 year ago
Hi! π
Firstly, thanks for your work on this project! π
Today I used patch-package to patch @twotalltotems/react-native-otp-input@1.3.11 for the project I'm working on.
@twotalltotems/react-native-otp-input@1.3.11
Here is the diff that solved my problem:
diff --git a/node_modules/@twotalltotems/react-native-otp-input/dist/index.js b/node_modules/@twotalltotems/react-native-otp-input/dist/index.js index 71580b8..6c591d6 100644 --- a/node_modules/@twotalltotems/react-native-otp-input/dist/index.js +++ b/node_modules/@twotalltotems/react-native-otp-input/dist/index.js @@ -155,7 +155,7 @@ export default class OTPInputView extends Component { } componentDidMount() { this.copyCodeFromClipBoardOnAndroid(); - this.bringUpKeyBoardIfNeeded(); + setTimeout(() => this.bringUpKeyBoardIfNeeded(), 100); this.keyboardDidHideListener = Keyboard.addListener('keyboardDidHide', this.handleKeyboardDidHide); } componentWillUnmount() {
This issue body was partially generated by patch-package.
It worked to me.
There is a PR raised to fix this issue. If this gets merged, we would not have to patch anymore. https://github.com/tttstudios/react-native-otp-input/pull/220
Hi! π
Firstly, thanks for your work on this project! π
Today I used patch-package to patch
@twotalltotems/react-native-otp-input@1.3.11
for the project I'm working on.Here is the diff that solved my problem:
This issue body was partially generated by patch-package.