Bootstrap面板中的位置按钮

时间:2015-10-01 01:22:43

标签: jquery html css twitter-bootstrap

大家好我在页面上使用引导程序面板,我想在panel-heading

中对齐按钮

我尝试使用padding,但它不起作用只是拉伸了button

以下是panel-group的图片,您可以看到checkin按钮未正确对齐

让我知道我可以使用哪种属性

谢谢

enter image description here

以下是html

panel元素

enter image description here

2 个答案:

答案 0 :(得分:1)

尝试使用margin代替padding

更新: - 尝试将您的属性位置设置为绝对值并使用保证金。它会工作。问候。

不建议使用绝对位置。取决于更多信息可以在这里查看。

Is it considered bad practice to use absolute positioning?

这只是一个例子

DEMO

答案 1 :(得分:0)

尝试将面板标题显示设置为flex,将项目对齐到中心。包装标题文本并将包装器的flex值设置为1,就是这样。尽量避免使用绝对定位。

相关问题