Skip to content

Commit 6f5dee8

Browse files
style(ui): redesign card component and improve css
fix(ui): move inline styles to scss and fix spacing fix(ui): redesign card component, move inline styles to scss, and fix spacing
1 parent 1d0fa55 commit 6f5dee8

File tree

2 files changed

+70
-8
lines changed

2 files changed

+70
-8
lines changed

src/app/centers/centers-view/center-actions/manage-groups/manage-groups.component.html

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -33,14 +33,19 @@
3333
</div>
3434
</mat-card>
3535

36-
<mat-card class="flex-40">
36+
<mat-card class="flex-50">
3737
<h3 matSubheader>{{ 'labels.heading.Group Members' | translate }}</h3>
3838

3939
<mat-nav-list *ngIf="groupMembers?.length">
40-
<div mat-list-item *ngFor="let group of groupMembers; index as i">
40+
<div mat-list-item class="member-item center-gap" *ngFor="let group of groupMembers; index as i">
4141
<span matLine class="p-t-10">{{ group.name }}</span>
42-
<div class="flex-fill"></div>
43-
<button mat-icon-button color="warn" (click)="removeGroup(i, group)">
42+
<button
43+
mat-icon-button
44+
color="warn"
45+
class="delete-btn"
46+
aria-label="Remove group"
47+
(click)="removeGroup(i, group)"
48+
>
4449
<fa-icon icon="trash"></fa-icon>
4550
</button>
4651
</div>
Lines changed: 61 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,20 @@
11
.container {
2-
max-width: 50rem;
2+
max-width: 70rem;
33

44
.mat-table {
55
display: block;
6-
font-family: Tahoma, Verdana, sans-serif;
6+
font-family: Roboto, 'Helvetica Neue', sans-serif;
77
width: 100%;
8+
margin-top: -2rem;
9+
padding: 1.5rem;
810
}
911

1012
.mat-row,
1113
.mat-header-row {
1214
display: flex;
13-
border-bottom-width: 1px;
14-
border-bottom-style: solid;
15+
border-bottom: 1px solid var(--border-color-light, #eee);
16+
color: var(--text-color, inherit);
17+
font-weight: 500;
1518
align-items: center;
1619
min-height: 48px;
1720
padding: 0 24px;
@@ -22,14 +25,68 @@
2225
flex: 1;
2326
overflow: hidden;
2427
word-wrap: break-word;
28+
flex-direction: column;
2529
}
2630

2731
h3 {
2832
padding-left: 0;
2933
margin-bottom: 0;
34+
font-weight: 500;
35+
border-bottom: 2px solid var(--border-color-light, #eee);
36+
padding-bottom: 1rem;
3037
}
3138

3239
.group-card {
3340
max-height: 20rem;
41+
margin-bottom: 1rem;
42+
padding: 1.5rem;
43+
box-shadow: 0 2px 4px rgb(0 0 0 / 10%);
44+
border: 1px solid var(--border-color, #ddd);
45+
border-radius: 8px;
46+
transition:
47+
background-color 0.3s ease,
48+
border-color 0.3s ease;
49+
}
50+
51+
.p-t-10 {
52+
padding-top: 10px;
53+
font-weight: 500;
54+
margin-left: 1rem;
55+
}
56+
57+
.flex-50 {
58+
max-height: 20rem;
59+
margin-bottom: 1rem;
60+
padding: 1.5rem;
61+
box-shadow: 0 2px 4px rgb(0 0 0 / 10%);
62+
border: 1px solid var(--border-color, #ddd);
63+
border-radius: 8px;
64+
transition:
65+
background-color 0.3s ease,
66+
border-color 0.3s ease;
67+
68+
.mat-nav-list {
69+
.member-item {
70+
display: flex;
71+
align-items: center;
72+
gap: 0.5rem;
73+
padding: 0.25rem 0;
74+
}
75+
76+
.center-gap {
77+
display: flex;
78+
align-items: center;
79+
gap: 0.5rem;
80+
}
81+
82+
.member-item .p-t-10 {
83+
margin: 0;
84+
font-weight: 500;
85+
}
86+
87+
.delete-btn {
88+
margin-left: 0.25rem;
89+
}
90+
}
3491
}
3592
}

0 commit comments

Comments
 (0)