2
0
mirror of https://github.com/tenrok/bootstrap.git synced 2026-06-11 18:02:28 +03:00

redefine the grid to use attribute selectors with css regex, make previously fixed grid values use variables we use elsewhere

This commit is contained in:
Mark Otto
2011-08-27 15:30:18 -07:00
parent b552281558
commit 650251228b
6 changed files with 41 additions and 43 deletions
+11 -19
View File
@@ -9,28 +9,14 @@
.row {
.clearfix();
margin-left: -20px;
margin-left: -1 * @gridGutterWidth;
// Default columns
.span1,
.span2,
.span3,
.span4,
.span5,
.span6,
.span7,
.span8,
.span9,
.span10,
.span11,
.span12,
.span13,
.span14,
.span15,
.span16 {
// Find all .span# classes within .row and give them the necessary properties for grid columns (supported by all browsers back to IE7)
// Credit to @dhg for the idea
[class^="span"] {
display: inline;
float: left;
margin-left: 20px;
margin-left: @gridGutterWidth;
}
// Default columns
@@ -64,6 +50,12 @@
.offset10 { .offset(10); }
.offset11 { .offset(11); }
.offset12 { .offset(12); }
// Unique column sizes for 16-column grid
.span-one-third { width: 300px; }
.span-two-thirds { width: 620px; }
.offset-one-third { margin-left: 320px; }
.offset-two-thirds { margin-left: 640px; }
}