场景
当文字字体在12px时,文字相对于单选框和复选框的位置是偏下的!(谷歌浏览器)
截图

解决方案
- 方案一
input[type="radio"], input[type="checkbox"] {
vertical-align: middle;
margin-top:-2px;
margin-bottom:1px;
}
- 方案二
input[type="radio"], input[type="checkbox"] {
vertical-align:-2px;
}
我在浏览器测试中 “-2px”看起来更舒服点。
网友评论