colorfy-software / react-native-modalfy

🥞 Modal citizen of React Native.
https://colorfy-software.gitbook.io/react-native-modalfy
MIT License
1.06k stars 42 forks source link

Modal doesn't scroll up when keyboard is open on iOS #82

Closed nandha-kumar-hajari closed 2 years ago

nandha-kumar-hajari commented 2 years ago

I created a modal using react-native-modalfy with an input field in it. On android everything is working as expected(i.e., modal moving up when keyboard appears) but on iOS, whenever I try to type something the keyboard appears on the modal UI and doesn't allow me to see anything that happens on the modal UI. Is there any workaround to get past this issue? @CharlesMangwa

CharlesMangwa commented 2 years ago

Hi @nandha-kumar-hajari. As mentioned in my reply in #63 in which you posted your initial message: it is incumbent upon you to handle this.

You might want the modal to move up or down, but somebody else might want a completely different behavior (translate the modal, scale it, replace it with another component, etc). Because of all of this, we decided that Modalfy does not and will not interfere with this in the foreseeable future.

But once again, as mentioned in #63: you do have full control over how your modals are rendered. Modalfy only provides a wrapper for you, so to speak. Therefore, feel free to implement your desired behavior via the customary KeyboardAvoidingView. If you want something more fine-tuned: you can always use Keyboard.addListener and animate your modal as you please.