使用 Blueprint CSS,我们如何设置 3 列的样式,每列宽 300 像素,中间有 15 像素的边距或填充?

发布于 2024-10-02 04:51:01 字数 242 浏览 1 评论 0原文

内容区域的宽度为 960px,有 3 列,每列 300px,因此总共 900px,列之间的填充/边距为 15px,总共 30px, 最后,第一列的左侧应该有 15px 的填充/边距,第三列的右侧也应该有 15px 的填充/边距。所以总共也是 30px。

900 像素 + 30 像素 + 30 像素将是 960 像素。

如何在蓝图/CSS 中做到这一点?这可以使用简单的 CSS 来完成,但编码标准要求使用 Blueprint CSS。

The width of the content-area is 960px, with 3 columns, each 300px, so total 900px, and with padding / margin of 15px between columns, which is total 30px,
and finally, to the left of 1st column there should be 15px padding / margin, and to the right of the 3rd column, the same. So total is also 30px.

900px + 30px + 30px will be 960px.

How to do that in Blueprint / CSS? This can be done using simple CSS, but the coding standard requires using Blueprint CSS.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

暖风昔人 2024-10-09 04:51:01

您可以覆盖蓝图类,请参阅此处:

http://jsfiddle.net/JeaffreyGilbert/aznVd/

假设您使用的是 Blueprint 的 grid.css

You can override Blueprint classes, see here:

http://jsfiddle.net/JeaffreyGilbert/aznVd/

I assume you're using Blueprint's grid.css.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文