我正在使用骨架框架 (http://getsculpture.com),并且我想要一个具有背景颜色和白色容器页面的页面。
如果我添加 .container {padding:0 10px;}
,则在为小型设备调整窗口大小时布局会中断。希望我在这里遗漏了一些非常明显的东西。如何在不破坏响应式设计的情况下向容器添加填充?
最佳答案
找到了我的解决方案 here ,如果我正确理解你的帖子。
Since this has a white background, I want some padding inside the box. Simple enough: I added a inside the parent one and styled it appropriately with padding: 10px and a white background.
CSS
div.inner {
padding: 4px 4px 8px 12px;
overflow:auto;
}
HTML
<div id="what_you_think" class="realm eight columns alpha">
<div class="inner">
<h3>You are <font style="color:black;">not</font>...</h3>
</div>
</div>
结果
关于css - 如何向骨架框架中的容器添加填充?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/13936670/