【CSS】移动端下 input placeholder 不垂直
2017-03-15 本文已影响2302人
izhongxia
PC端chrome设备模拟器里面

iphone7里面

区别
- iphone7 下 placeholder 字体变成12px
- 移动端下,placeholder 不垂直居中
解决方案:
input::-webkit-input-placeholder{
font-size: 14px ; //解决iphone下字体大小为12的问题(和input大小不一致)
line-height: 1em; //解决不垂直居中的问题
}