barebones/assets/styles/base/_grid.scss

21 lines
534 B
SCSS
Raw Normal View History

2019-10-01 13:17:53 +02:00
.grid {
display: grid;
grid-gap: $base-spacing-unit;
@include resp-max($breakpoint-sm) {
2023-08-03 13:57:13 +02:00
grid-gap: $base-spacing-unit * 0.5;
2019-10-01 13:17:53 +02:00
}
@each $breakpoint in $breakpoints {
$name: nth($breakpoint, 1);
$declaration: nth($breakpoint, 2);
@media only screen and #{$declaration} {
@for $i from 1 through 6 {
&.grid--#{$name}-#{$i}x {
2020-02-27 17:25:56 +01:00
grid-template-columns: repeat(#{$i}, minmax(0, 1fr));
2019-10-01 13:17:53 +02:00
}
}
}
}
2020-02-27 17:25:56 +01:00
}