mirror of
https://github.com/twbs/bootstrap.git
synced 2025-02-21 18:54:30 +01:00
Remove libsass @media nesting bug workaround
https://github.com/sass/libsass/issues/185 has been fixed. Refs #48
This commit is contained in:
parent
5951647b1a
commit
d6a5ebf438
@ -68,21 +68,9 @@
|
|||||||
// No minimum for the smallest breakpoint, and no maximum for the largest one.
|
// No minimum for the smallest breakpoint, and no maximum for the largest one.
|
||||||
// Makes the @content apply only to the given breakpoint, not viewports any wider or narrower.
|
// Makes the @content apply only to the given breakpoint, not viewports any wider or narrower.
|
||||||
@mixin media-breakpoint-only($name, $breakpoints: $grid-breakpoints) {
|
@mixin media-breakpoint-only($name, $breakpoints: $grid-breakpoints) {
|
||||||
// Nested media query combination does not work in libsass yet
|
@include media-breakpoint-up($name, $breakpoints) {
|
||||||
// https://github.com/sass/libsass/issues/185
|
@include media-breakpoint-down($name, $breakpoints) {
|
||||||
// Work around until the issue is resolved:
|
|
||||||
$min: breakpoint-min($name, $breakpoints);
|
|
||||||
$max: breakpoint-max($name, $breakpoints);
|
|
||||||
@if $min and $max {
|
|
||||||
@media (min-width: $min) and (max-width: $max) {
|
|
||||||
@content;
|
@content;
|
||||||
}
|
}
|
||||||
} @else {
|
|
||||||
// One of min or max is a no-op, so this branch is not affected by libsass#185
|
|
||||||
@include media-breakpoint-up($name, $breakpoints) {
|
|
||||||
@include media-breakpoint-down($name, $breakpoints) {
|
|
||||||
@content;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user