1
0
mirror of https://github.com/twbs/bootstrap.git synced 2025-08-19 20:02:34 +02:00

Add RFS to utility API (#30050)

This commit is contained in:
Martijn Cuppens
2020-02-15 12:01:32 +01:00
committed by GitHub
parent 22062ed9d7
commit 1d8a3a9597
4 changed files with 40 additions and 5 deletions

View File

@@ -16,6 +16,24 @@
}
}
// RFS rescaling
@media (min-width: $rfs-mq-value) {
@each $breakpoint in map-keys($grid-breakpoints) {
$infix: breakpoint-infix($breakpoint, $grid-breakpoints);
@if (map-get($grid-breakpoints, $breakpoint) < $rfs-breakpoint) {
// Loop over each utility property
@each $key, $utility in $utilities {
// The utility can be disabled with `false`, thus check if the utility is a map first
// Only proceed if responsive media queries are enabled or if it's the base media query
@if type-of($utility) == "map" and map-get($utility, rfs) {
@include generate-utility($utility, $infix, true);
}
}
}
}
}
// Print utilities
@media print {