Skip to content

Commit

Permalink
Fixes issue 10357: "Using .container as a mixin is impossible"
Browse files Browse the repository at this point in the history
Attempts to solve the problem based on feedback in
twbs/bootstrap#10357 (comment)
  • Loading branch information
dminkovsky committed Sep 5, 2013
1 parent 8651180 commit e9c27fa
Show file tree
Hide file tree
Showing 4 changed files with 32 additions and 22 deletions.
2 changes: 1 addition & 1 deletion assets/js/raw-files.js

Large diffs are not rendered by default.

27 changes: 18 additions & 9 deletions dist/css/bootstrap.css
Original file line number Diff line number Diff line change
Expand Up @@ -782,6 +782,24 @@ pre code {
clear: both;
}

@media (min-width: 768px) {
.container {
width: 750px;
}
}

@media (min-width: 992px) {
.container {
width: 970px;
}
}

@media (min-width: 1200px) {
.container {
width: 1170px;
}
}

.row {
margin-right: -15px;
margin-left: -15px;
Expand Down Expand Up @@ -924,9 +942,6 @@ pre code {
}

@media (min-width: 768px) {
.container {
width: 750px;
}
.col-sm-1,
.col-sm-2,
.col-sm-3,
Expand Down Expand Up @@ -1078,9 +1093,6 @@ pre code {
}

@media (min-width: 992px) {
.container {
width: 970px;
}
.col-md-1,
.col-md-2,
.col-md-3,
Expand Down Expand Up @@ -1241,9 +1253,6 @@ pre code {
}

@media (min-width: 1200px) {
.container {
width: 1170px;
}
.col-lg-1,
.col-lg-2,
.col-lg-3,
Expand Down
2 changes: 1 addition & 1 deletion dist/css/bootstrap.min.css

Large diffs are not rendered by default.

23 changes: 12 additions & 11 deletions less/grid.less
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,18 @@
// Set the container width, and override it for fixed navbars in media queries
.container {
.container-fixed();

@media (min-width: @screen-sm) {
width: @container-sm;
}

@media (min-width: @screen-md) {
width: @container-md;
}

@media (min-width: @screen-lg-min) {
width: @container-lg;
}
}

// mobile first defaults
Expand Down Expand Up @@ -115,10 +127,6 @@
// it's full-width.

@media (min-width: @screen-sm) {
.container {
width: @container-sm;
}

.col-sm-1,
.col-sm-2,
.col-sm-3,
Expand Down Expand Up @@ -193,9 +201,6 @@
// it's full-width.

@media (min-width: @screen-md) {
.container {
width: @container-md;
}
.col-md-1,
.col-md-2,
.col-md-3,
Expand Down Expand Up @@ -273,10 +278,6 @@
// it's full-width.

@media (min-width: @screen-lg-min) {
.container {
width: @container-lg;
}

.col-lg-1,
.col-lg-2,
.col-lg-3,
Expand Down

0 comments on commit e9c27fa

Please sign in to comment.