12

I am having a hard time figuring out how to do this.

I am using google.map.places.Autocomplete and its all working fine, but due to app/screen sizes the pac-container with the returned search listings is behind the devices virtual keyboard - and thus on about half of the devices I have tested the user can't see the returned address list. Obviously you don't want the pac-container in front of the keyboard because then various keyboard keys will be hidden.

How can I force the pac-container to appear above (and scroll up) the search/input box?

2
  • Maybe you can provide some code, test case to start helping you, because everyone can imagine and create scenario he want ! Commented Oct 18, 2015 at 11:11
  • You could try to detect when the keyboard is active, and limit the height of the pac-container to the new window.innerHeight, while making it scrollable so that overflowing results can be found. See this stackoverflow.com/questions/11600040/… Commented Oct 20, 2015 at 20:59

1 Answer 1

1

The simplest way is to check when the keyboard opens and then minus margin the page a bit.

body.keyboardopen {
     margin-top: -@keyboardheight;
}

Not the answer you're looking for? Browse other questions tagged or ask your own question.