mirror of
https://github.com/twbs/bootstrap.git
synced 2024-12-01 13:24:25 +01:00
Add map-name param to _assert-starts-at-zero (#24986)
* Add map-name param to _assert-starts-at-zero * Set default value for backwards compatibility
This commit is contained in:
parent
eb1313d213
commit
b647dd0565
@ -21,12 +21,12 @@
|
||||
}
|
||||
|
||||
// Starts at zero
|
||||
// Another grid mixin that ensures the min-width of the lowest breakpoint starts at 0.
|
||||
@mixin _assert-starts-at-zero($map) {
|
||||
// Used to ensure the min-width of the lowest breakpoint starts at 0.
|
||||
@mixin _assert-starts-at-zero($map, $map-name: "$grid-breakpoints") {
|
||||
$values: map-values($map);
|
||||
$first-value: nth($values, 1);
|
||||
@if $first-value != 0 {
|
||||
@warn "First breakpoint in `$grid-breakpoints` must start at 0, but starts at #{$first-value}.";
|
||||
@warn "First breakpoint in #{$map-name} must start at 0, but starts at #{$first-value}.";
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -196,7 +196,7 @@ $grid-breakpoints: (
|
||||
) !default;
|
||||
|
||||
@include _assert-ascending($grid-breakpoints, "$grid-breakpoints");
|
||||
@include _assert-starts-at-zero($grid-breakpoints);
|
||||
@include _assert-starts-at-zero($grid-breakpoints, "$grid-breakpoints");
|
||||
|
||||
|
||||
// Grid containers
|
||||
|
Loading…
Reference in New Issue
Block a user