Миксин для быстрого использования запросов @media (max-width....
$screen-xs-min: 767px;
$screen-sm-min: 768px;
$screen-md-min: 992px;
$screen-lg-min: 1200px;
@mixin media($class) {
@if $class == xs {
@media (max-width: $screen-xs-min) { @content; }
}
@else if $class == sm {
@media (min-width: $screen-sm-min) { @content; }
}
@else if $class == md {
@media (min-width: $screen-md-min) { @content; }
}
@else if $class == lg {
@media (min-width: $screen-lg-min) { @content; }
}
@else {
@warn "Breakpoint mixin supports: xs, sm, md, lg";
}
}
//пример
footer {
display: none;
@include media(sm) {
display: block;
}
}