+ 4

How can I keep the same size on my div when the keyboard appears on my phone?

I wonder if I can use the same size and the same appearance when I type in a password so my "panda" can have the same appearance because when I use my phone to type something in the password form the "panda" looks very weird. I wonder if I can keep the same shape in some way. Any help would be appreciated :) Sorry for my bad English :) https://code.sololearn.com/WfHODuR8CZMo/?ref=app

10th Jun 2018, 1:48 PM
RedPeppe
7 Answers
+ 2
You are using % for width and height specification, which is why it scales when your soft keyboard occupies a portion of your screen. By replacing them with px of the appropriate size, for instance, would be a feasible fix.
10th Jun 2018, 1:53 PM
Fermi
Fermi - avatar
10th Jun 2018, 2:11 PM
Fermi
Fermi - avatar
+ 3
thank you for the help :)) Now it works :))
10th Jun 2018, 2:12 PM
RedPeppe
+ 2
thank you for the help but then if I replace everything with px then how can I make it compatible on all resolutions?
10th Jun 2018, 1:57 PM
RedPeppe
+ 2
Hmmmmm, If that's the case, try setting a min-height attribute for your divs in px and leave the height and width declarations in %.
10th Jun 2018, 2:05 PM
Fermi
Fermi - avatar
+ 2
ok thank you for the help. I will try it out :)
10th Jun 2018, 2:06 PM
RedPeppe
+ 2
you can use media queries for smaller devices
11th Jun 2018, 10:26 AM
NAVEEN SHARMA
NAVEEN SHARMA - avatar