fix: card grid grid gets streched if vertical space is not used fully
Fixed by adding a container for the card grid. That way the actual card grid has no height and is therefore not streched vertically.
This commit is contained in:
@@ -20,11 +20,14 @@
|
|||||||
<pdb-gallery-filter-view (valueChanged)="filterChanged($event)"></pdb-gallery-filter-view>
|
<pdb-gallery-filter-view (valueChanged)="filterChanged($event)"></pdb-gallery-filter-view>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<div
|
<div
|
||||||
*ngIf="show"
|
*ngIf="show"
|
||||||
id="gallery"
|
class="card-grid-container">
|
||||||
class="card-grid-300">
|
<div
|
||||||
<pdb-gallery-item-view
|
id="gallery"
|
||||||
*ngFor="let galleryItem of filteredSortedGalleryItems()" [data]="galleryItem">
|
class="card-grid-300">
|
||||||
</pdb-gallery-item-view>
|
<pdb-gallery-item-view
|
||||||
|
*ngFor="let galleryItem of filteredSortedGalleryItems()" [data]="galleryItem">
|
||||||
|
</pdb-gallery-item-view>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -6,13 +6,15 @@
|
|||||||
background-color: #f8f8f8;
|
background-color: #f8f8f8;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.card-grid-container {
|
||||||
|
overflow-y: auto;
|
||||||
|
height: calc(100% - 4.5em);
|
||||||
|
}
|
||||||
|
|
||||||
.card-grid-300 {
|
.card-grid-300 {
|
||||||
display: grid;
|
display: grid;
|
||||||
grid-template-columns: repeat(auto-fit, minmax(300px, 300px));
|
grid-template-columns: repeat(auto-fit, minmax(300px, 300px));
|
||||||
grid-gap: 10px;
|
grid-gap: 10px;
|
||||||
padding: 10px;
|
padding: 10px;
|
||||||
overflow-y: auto;
|
|
||||||
height: calc(100% - 4.5em);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user