如何在输入字段中正确地垂直放置占位符?
input[type='text']{
background-color: rgba(255,255,255,.4);
border:3px solid rgba(0,0,0,.5);
min-height: 45px;
border-radius: 6px;
color:#fff;
}
input[type='text']::-webkit-input-placeholder {
font-size: 30px;
color: rgba(255, 255, 255, 0.4);
line-height: 30px;
text-transform: uppercase;
vertical-align: middle;
}
您忘记将此添加css
到input
元素:
input[type='text']{
font-size: 30px;
color: rgba(255, 255, 255, 0.4);
line-height: 30px;
}
这是小提琴:小提琴链接
本文收集自互联网,转载请注明来源。
如有侵权,请联系 [email protected] 删除。
我来说两句