diff options
| author | Jacob Thornton <[email protected]> | 2012-01-29 19:07:14 -0800 |
|---|---|---|
| committer | Jacob Thornton <[email protected]> | 2012-01-29 19:07:14 -0800 |
| commit | 0de951f4f41c798dead8525e78153fc6c5da1479 (patch) | |
| tree | 4bd75bf2531609e23d743416a9bee7ac7338769c /less | |
| parent | fae04c8ac1da675338c1cfaf3922223980667281 (diff) | |
| parent | 2ba1b01f8d9a0410d9cf45532d8924d858af74cd (diff) | |
| download | bootstrap-0de951f4f41c798dead8525e78153fc6c5da1479.tar.xz bootstrap-0de951f4f41c798dead8525e78153fc6c5da1479.zip | |
Merge branch '2.0-wip' of https://github.com/twitter/bootstrap into 2.0-wip
Conflicts:
docs/assets/bootstrap.zip
Diffstat (limited to 'less')
| -rw-r--r-- | less/grid.less | 25 | ||||
| -rw-r--r-- | less/mixins.less | 15 | ||||
| -rw-r--r-- | less/variables.less | 11 |
3 files changed, 26 insertions, 25 deletions
diff --git a/less/grid.less b/less/grid.less index 4493d0b95..2ef767a4a 100644 --- a/less/grid.less +++ b/less/grid.less @@ -2,31 +2,6 @@ // ----------- -// Default grid sizing -// ------------------- -@gridColumns: 12; -@gridColumnWidth: 60px; -@gridGutterWidth: 20px; - -@gridRowWidth: (@gridColumns * @gridColumnWidth) + (@gridGutterWidth * (@gridColumns - 1)); -@gridTotalWidth: @gridRowWidth; - - -// Columns and offseting mixins -// ---------------------------- -.columns(@columns: 1) { - //width: (@gridColumnWidth * @columns) + (@gridGutterWidth * (@columns - 1)); - width: @gridTotalWidth * ((((@gridGutterWidth+@gridColumnWidth)*@columns)-@gridGutterWidth)/@gridRowWidth); -} -.offset(@columns: 1) { - margin-left: (@gridColumnWidth * @columns) + (@gridGutterWidth * (@columns - 1)) + (@gridGutterWidth * 2); -} -// Necessary grid styles for every column to make them appear next to each other horizontally -.gridColumn() { - float: left; - margin-left: @gridGutterWidth; -} - // Grid rows and columns // --------------------- .row { diff --git a/less/mixins.less b/less/mixins.less index 2d0e2d4c0..cba2670db 100644 --- a/less/mixins.less +++ b/less/mixins.less @@ -139,6 +139,21 @@ .clearfix(); } +// Columns and offseting mixins +// ---------------------------- +.columns(@columns: 1) { + //width: (@gridColumnWidth * @columns) + (@gridGutterWidth * (@columns - 1)); + width: @gridTotalWidth * ((((@gridGutterWidth+@gridColumnWidth)*@columns)-@gridGutterWidth)/@gridRowWidth); +} +.offset(@columns: 1) { + margin-left: (@gridColumnWidth * @columns) + (@gridGutterWidth * (@columns - 1)) + (@gridGutterWidth * 2); +} +// Necessary grid styles for every column to make them appear next to each other horizontally +.gridColumn() { + float: left; + margin-left: @gridGutterWidth; +} + // CSS3 PROPERTIES diff --git a/less/variables.less b/less/variables.less index c1e21978c..f09a88cdb 100644 --- a/less/variables.less +++ b/less/variables.less @@ -40,6 +40,17 @@ +// GRID SYSTEM VARIABLES +// -------------------------------------------------- + +@gridColumns: 12; +@gridColumnWidth: 60px; +@gridGutterWidth: 20px; +@gridRowWidth: (@gridColumns * @gridColumnWidth) + (@gridGutterWidth * (@gridColumns - 1)); +@gridTotalWidth: @gridRowWidth; + + + // COMPONENT VARIABLES // -------------------------------------------------- |
