Skip to content
This repository has been archived by the owner on Feb 16, 2023. It is now read-only.

Commit

Permalink
Merge pull request #141 from shamoon/document-list-layout-tweaks
Browse files Browse the repository at this point in the history
Document list small card layout adjustments
  • Loading branch information
Jonas Winkler committed Dec 17, 2020
2 parents 48796e6 + fbca412 commit 1947d67
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 4 deletions.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<div class="col p-2 h-100" style="width: 16rem;">
<div class="col p-2 h-100">
<div class="card h-100 shadow-sm">
<div class="border-bottom">
<img class="card-img doc-img" [src]="getThumbUrl()">
Expand All @@ -22,7 +22,7 @@
</div>
<div class="card-footer">

<div class="d-flex justify-content-between align-items-center ml-n2">
<div class="d-flex justify-content-between align-items-center mx-n2">
<div class="btn-group">
<a routerLink="/documents/{{document.id}}" class="btn btn-sm btn-outline-secondary" title="Edit">
<svg width="1em" height="1em" viewBox="0 0 16 16" class="bi bi-pencil" fill="currentColor" xmlns="http://www.w3.org/2000/svg">
Expand All @@ -42,7 +42,7 @@
</svg>
</a>
</div>
<small class="text-muted">{{document.created | date}}</small>
<small class="text-muted pl-1">{{document.created | date}}</small>
</div>

</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,6 @@
</table>


<div class=" m-n2 row" *ngIf="displayMode == 'smallCards'">
<div class="m-n2 row row-cols-paperless-cards" *ngIf="displayMode == 'smallCards'">
<app-document-card-small [document]="d" *ngFor="let d of list.documents" (clickTag)="clickTag($event)" (clickCorrespondent)="clickCorrespondent($event)"></app-document-card-small>
</div>
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
$paperless-card-breakpoints: (
0: 2, // xs
768px: 3, //md
992px: 4, //lg
1200px: 5, //xl
1400px: 6, // xxl
1600px: 7,
1800px: 8,
2000px: 9
);

.row-cols-paperless-cards {
@each $width, $n_cols in $paperless-card-breakpoints {
@media(min-width: $width) {
> * {
flex: 0 0 auto;
width: 100% / $n_cols;
}
}
}
}

0 comments on commit 1947d67

Please sign in to comment.