-1
A
回答
1
这有点乱,但你在找这样的东西吗?
HTML:
<div class="button-panel">
<div class="row button-row">
<div class="col-xs-3 button-container">
<input type="button" class="btn btn-primary btn-responsive" value="Button 1">
</div>
<div class="col-xs-3 button-container">
<input type="button" class="btn btn-primary btn-responsive" value="Button 2">
</div>
<div class="col-xs-3 button-container">
<input type="button" class="btn btn-primary btn-responsive" value="Button 3">
</div>
<div class="col-xs-3 button-container">
<input type="button" class="btn btn-primary btn-responsive" value="Button 4">
</div>
</div>
<div class="row button-row">
<div class="col-xs-3 button-container">
<input type="button" class="btn btn-primary btn-responsive" value="Button 5">
</div>
<div class="col-xs-3 button-container">
<input type="button" class="btn btn-primary btn-responsive" value="Button 6">
</div>
<div class="col-xs-3 button-container">
<input type="button" class="btn btn-primary btn-responsive" value="Button 7">
</div>
<div class="col-xs-3 button-container">
<input type="button" class="btn btn-primary btn-responsive" value="Button 8">
</div>
</div>
<div class="row button-row">
<div class="col-xs-3 button-container">
<input type="button" class="btn btn-primary btn-responsive" value="Button 9">
</div>
<div class="col-xs-3 button-container">
<input type="button" class="btn btn-primary btn-responsive" value="Button 10">
</div>
<div class="col-xs-3 button-container">
<input type="button" class="btn btn-primary btn-responsive" value="Button 11">
</div>
<div class="col-xs-3 button-container">
<input type="button" class="btn btn-primary btn-responsive" value="Button 12">
</div>
</div>
</div>
CSS:
.button-panel {
height: 100vh;
}
.button-row {
height: calc(100%/3);
}
.button-container {
padding: 0;
height: 100%;
}
.btn-responsive {
width: 100%;
height: 100%;
}
相关问题
- 1. jssor更改缩略图宽度高度
- 2. 按钮宽度,高度
- 3. 按钮宽度和高度不正确
- 4. 获取图像的高度和宽度,如果它的响应
- 5. 设置按钮的高度与宽度
- 6. 如何让我的图片响应宽度和高度?
- 7. 在高度和宽度内的响应式图像<figure>
- 8. Svg高度可调的响应宽度
- 9. 无收缩的宽度和高度
- 10. 使用缩略图,我可以使相同的高度和宽度的缩略图无论图像的大小
- 11. 图像自动高度缩放宽度
- 12. 响应式缩略图网格调整宽度
- 13. 布局宽度和高度被忽略
- 14. CGAffineTransform仅缩放宽度和高度
- 15. 已解决作物在不同宽度和高度的中心缩略图
- 16. 减小图像的宽度/高度以适合给定的宽高比。怎么样? - Python图像缩略图
- 17. php imgcopyresampled - 改变缩略图的宽度
- 18. Firefox忽略输入类型的宽度和高度=“图像”
- 19. 高度和宽度
- 20. 如何获得按钮的高度和宽度
- 21. 如何增加Facebook的高度,宽度和字体like按钮
- 22. 通过代码更改按钮的宽度和高度
- 23. 具有相同宽度和高度的Android按钮?
- 24. 更改buttonset中按钮的高度和宽度jquery
- 25. 设置按钮高度等于按钮宽度
- 26. pygtk缩放图像的宽度和高度
- 27. 从压缩文件中获取图像的高度和宽度
- 28. 试图按固定的宽度/高度用PHP生成按比例裁剪的缩略图GD
- 29. 使用CSS或jQuery的响应宽度和高度布局
- 30. 如何制作响应屏幕宽度和高度的div/box?
你看着引导媒体查询:http://getbootstrap.com/css/#grid -media-queries ??? – Ryan
你能告诉我们你们中的一个人吗? 按钮是图标,文字还是图标文字? 如果是文本,你是否想让文字变大? –
我想做3行4列。在这个单元格内,evry会有相同大小的按钮(矩形按钮)。按照按钮的分辨率大小将会改变。 –