search

Home  >  Q&A  >  body text

css - Android browser top and bottom centering problem

Writing a btn, in the WeChat Android version browser, the top and bottom centering will fail. The padding-top and padding-bottom set are obviously the same, and the line-height is used to make the text upward. How do everyone deal with this situation? What about the one that goes up and down?

PHPzPHPz2770 days ago1447

reply all(1)I'll reply

  • phpcn_u1582

    phpcn_u15822017-05-24 11:38:45

    During IOS and Android real-machine testing, the content displayed in INPUT will be a little higher if line-height is used to set it. I remember seeing that IOS has 1PX more content than Android, or something. You can try to adjust the padding-top to align it when displayed, but it will look uneven on the PC, and it will be centered on the mobile phone.

    reply
    0
  • Cancelreply