Prevent keyboard from covering IonInput

I am using @ionic/react 5.0.7.

My app looks like this:

  • IonContent
    • Other content
    • IonList
      • IonItem
        • IonInput

When I click on the IonInput on an iPhone with Safari, the keyboard covers up the input box. How can I prevent this? I tried to use .scrollIntoView() on the input element in onIonFocus but it did not work.

If I put an IonButton next to the IonInput, the input is focused when the button is clicked and the input is properly put into view. I have no idea why this occurs because clicking the button should not trigger the next field.

Add Comment
0 Answer(s)

Your Answer

By posting your answer, you agree to the privacy policy and terms of service.