我稍微修改了 ui-button
类的高度,但文本按钮仍保留在它的底部。如何将它对齐到中间?
.ui-button {
display: inline-block;
position: relative;
padding: 0px;
margin-right: 0.1em;
cursor: pointer;
text-align: center;
overflow: visible;
// resize a bit the height
height: 20px;
}
vertical-align
无效。
最佳答案
.ui-button {line-height: 20px;}
关于jquery - 如何垂直对齐 jQuery 按钮文本?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/15062547/