fixed a few sorting, rpp and view persistence issues with grid view

This commit is contained in:
Art Lowel
2018-04-26 10:57:12 +02:00
parent 545145a759
commit 994c089925
23 changed files with 208 additions and 96 deletions

View File

@@ -11,14 +11,33 @@ ds-wrapper-grid-element ::ng-deep {
}
}
$gutter: ($grid-gutter-width / 2);
$min-width: 300px;
$max-cols: 3;
.card-columns {
@include media-breakpoint-only(lg) {
column-count: 3;
display: flex;
flex-wrap: wrap;
margin-left: -$gutter;
margin-top: -$gutter;
.card-column {
flex: 1 0 $min-width;
margin-left: $gutter;
margin-top: $gutter;
@for $i from 2 through $max-cols {
$screen-width: ($min-width*$i)+($gutter*$i);
$column-width: (100%/$i);
@media (min-width: $screen-width) {
max-width: calc(#{$column-width} - #{$gutter});
}
}
$column-width: (100%/$max-cols);
@media (min-width: $min-width*$max-cols) {
min-width: calc(#{$column-width} - #{$gutter});
}
}
@include media-breakpoint-only(sm) {
column-count: 2;
}
@include media-breakpoint-only(xs) {
column-count: 1;
}
}
}