Closed MaddHatters closed 1 year ago
Thanks for the issue. Can you provide a repo with the code required to reproduce this issue?
@liamdebeasi Unfortunately I cannot as it is proprietary software. Will you be able to look into the issue without a repository?
Webviews + Keyboards are always a little tricky to work with, so having a repo makes it significantly easier for us to fix. Are you able to reproduce the issue in a blank Ionic starter app with just the ion-input
?
@liamdebeasi
I've created the following repository which you can use to reproduce the issue.
https://github.com/MaddHatters/ion-input-jump-ios
I use the following steps:
Thanks for the follow up. In order to get around some native browser behaviors when it comes to inputs, we do a few tricks including cloning the input.
It looks like the styles on that cloned input are incorrect. As a workaround, you can place the following CSS in your global.scss
file:
.cloned-input {
top: unset !important;
}
Thank you for your help @liamdebeasi.
Thanks for the report. This appears to have been resolved in https://github.com/ionic-team/ionic-framework/pull/27253, so I am going to close this.
Thanks for the issue! This issue is being locked to prevent comments that are not relevant to the original issue. If this is still an issue with the latest version of Ionic, please create a new issue and ensure the template is fully filled out.
Ionic version:
[] 4.x [x] 5.x
I'm submitting a ...
[x] bug report [ ] feature request
Current behavior:
When clicking on the input field, the native-input is pushed to the top of the ion-input container briefly before the keyboard is displayed. It appears as though the input jumps. I also noticed that this occurs only when I set a height on the ion-input element. If I remove the height, and min-height this is no longer an issue. Also, if I am debugging and I manually set the native-input element to have the same height as the ion-input element, this issue is resolved. This only occurs for me on iOS. I did not see this on Andriod.
Expected behavior:
The input field would adjust smoothly with the view as the keyboard is shown regardless of the height of the ion-input.
Steps to reproduce:
Related code:
Other information:
Ionic info: