react-native-cn-quill icon indicating copy to clipboard operation
react-native-cn-quill copied to clipboard

Keyboard.dismiss() doesn't work

Open za01br opened this issue 2 years ago • 5 comments

Hey! First of all, thanks for this library. It saved me a lot of time so far. :) I'm facing an issue with Keyboard.dismiss() not working using the editor. It works if the keyboard appeared due to a TextInput field, but not for the editor since it's wrapped in a WebView. Any suggestions on how to handle this case?

Thanks!

za01br avatar Sep 11 '22 06:09 za01br

KeyboardAvoidingView and related components also don't work.

mannby avatar Oct 06 '22 19:10 mannby

_editor.current.blur() can be used to dismiss the keyboard

mannby avatar Oct 06 '22 19:10 mannby

_editor.current.blur() can be used to dismiss the keyboard

But how do you dismiss the keyboard when you tap outside of the editor? Basically like a react-native TextInput... For example in iOS there is no way to dismiss the keyboard

stesvis avatar Mar 10 '23 20:03 stesvis

In my experience, if you tap in a TextInput control, that control now gets input from the keyboard.

To dismiss the keyboard anywhere else, you can intercept taps there with a Pressable over the rest of the views and call blur() on the quill editor component.

mannby avatar Mar 10 '23 20:03 mannby