0
0
mirror of https://github.com/twbs/bootstrap.git synced 2024-11-28 10:24:19 +01:00

Fix mixin media-breakpoint-only

Prevent mixin media-breakpoint-only from breaking when supplying the
first or last entry in $grid-breakpoints.
This commit is contained in:
Ken Paulsen 2017-05-04 10:54:59 +02:00 committed by Mark Otto
parent 72a0093200
commit a47f373e82

View File

@ -93,7 +93,13 @@
$min: breakpoint-min($name, $breakpoints);
$max: breakpoint-max($name, $breakpoints);
@media (min-width: $min) and (max-width: $max) {
@content;
@if $min != null and $max != null {
@media (min-width: $min) and (max-width: $max) {
@content;
}
} @else if $max == null {
@include media-breakpoint-up($name)
} @else if $min == null {
@include media-breakpoint-down($name)
}
}