Стили от 0 до max-width
Применить стили для экранов не более указанного размера.
Примесь обовачивает переданные стили в media-запрос вида max-width.
Код примеси:
.to(@max_width, @content){
@media screen and (max-width: @max_width){
@content();
}
}
@mixin to($max_width){
@media screen and (max-width: $max_width){
@content;
}
}
=to($max_width)
@media screen and (max-width: $max_width)
@content
to($max_width)
@media screen and (max-width: $max_width)
{block}