IOS ipad and iphone jumping bug when focused on input (due to keyboard popingup)
Hey guys i have made the following demo
here.
basically when a user clicks on the input , the entire form goes out of view , this happens as the keyboard popups up , i have checked SO and other sites for solutions , and currently have the following solution applied in the live site:
- $('form input').on('focusin focus', function(e) {
- $this = $(this);
- $('html , body').animate({
- scrollTop: ($this.offset().top / 2)
- }, 0);
- });
ofcourse this works perfectly if applied on the desktop version of the site , but on IOS there is a huge jitter everytime the user tabs to a new input field. is there a workaround to this ??