From: Catalin Zalog Date: Fri, 17 Apr 2020 17:18:51 +0000 (+0300) Subject: feat: checks for `$grid-breakpoints` map list (#30609) X-Git-Tag: v4.5.0~62 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=4853c5b5272ab3fbea5212028d7cedc05bad0281;p=thirdparty%2Fbootstrap.git feat: checks for `$grid-breakpoints` map list (#30609) Co-authored-by: Martijn Cuppens --- diff --git a/scss/_functions.scss b/scss/_functions.scss index ea02aa48ca..eb2471d753 100644 --- a/scss/_functions.scss +++ b/scss/_functions.scss @@ -23,10 +23,12 @@ // Starts at zero // 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 #{$map-name} must start at 0, but starts at #{$first-value}."; + @if length($map) > 0 { + $values: map-values($map); + $first-value: nth($values, 1); + @if $first-value != 0 { + @warn "First breakpoint in #{$map-name} must start at 0, but starts at #{$first-value}."; + } } }