Skip to content

Commit

Permalink
style(subjects): better avatars sizing
Browse files Browse the repository at this point in the history
  • Loading branch information
uatisdeproblem committed Mar 28, 2023
1 parent 1d03b47 commit efa3d8d
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 1 deletion.
4 changes: 4 additions & 0 deletions front-end/src/app/common/subject.component.scss
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
ion-item {
--border-radius: 4px;
ion-avatar {
width: var(--app-subject-avatar-size, 50px);
height: var(--app-subject-avatar-size, 50px);
}
}
7 changes: 6 additions & 1 deletion front-end/src/app/tabs/topics/topic.page.html
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,12 @@
</ion-card-header>
<ion-card-content>
<ion-list class="aList" lines="none">
<app-subject color="white" *ngFor="let subject of topic.subjects" [subject]="subject"></app-subject>
<app-subject
color="white"
*ngFor="let subject of topic.subjects"
[subject]="subject"
[class.single]="topic.subjects?.length === 1"
></app-subject>
<ion-row class="ion-margin-top" *ngIf="!topic.isArchived()">
<ion-col *ngIf="topic.willCloseAt">
<ion-item class="ion-text-right deadline">
Expand Down
3 changes: 3 additions & 0 deletions front-end/src/app/tabs/topics/topic.page.scss
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ ion-list.aList {
ion-list-header ion-label h2 {
margin-bottom: 0;
}
app-subject.single {
--app-subject-avatar-size: 100px;
}
ion-item.deadline {
ion-label {
font-size: 0.9em;
Expand Down

0 comments on commit efa3d8d

Please sign in to comment.