Skip to content

Commit 8e38b5e

Browse files
authored
chore(curriculum): unify some spacing (#10872)
* feat(curriculum): adjust spacing + group label Adjust spacing for module cards. Move group label on top of heading. * fix moduels list list spacing * fix
1 parent 52bda8f commit 8e38b5e

File tree

2 files changed

+12
-12
lines changed

2 files changed

+12
-12
lines changed

Diff for: client/src/curriculum/module.scss

-5
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,6 @@
1010
"icon heading"
1111
"icon category";
1212
justify-content: flex-start;
13-
@media screen and (min-width: $screen-md) {
14-
grid-template-areas:
15-
"icon heading group"
16-
"icon category .";
17-
}
1813

1914
.topic-icon {
2015
--background-primary: var(--curriculum-bg-color-topic);

Diff for: client/src/curriculum/modules-list.scss

+12-7
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,7 @@
6565
> label {
6666
color: var(--text-inactive);
6767
cursor: pointer;
68+
width: max-content;
6869
}
6970

7071
&#modules-0 {
@@ -146,6 +147,8 @@
146147
}
147148

148149
li.module-list-item {
150+
--spacing: 1rem;
151+
--icon-size: 4rem;
149152
display: block;
150153

151154
> a {
@@ -178,12 +181,15 @@
178181
background-color: var(--curriculum-bg-color-list-item-header);
179182
display: flex;
180183
flex-direction: column;
181-
height: 10rem;
182-
padding: 1rem;
184+
font-weight: var(--font-body-strong-weight);
185+
height: 10.5rem;
186+
height: calc(3 * var(--spacing) + var(--icon-size) + 2lh);
187+
padding: var(--spacing);
188+
row-gap: var(--spacing);
183189

184190
svg.topic-icon {
185-
height: 4rem;
186-
width: 4rem;
191+
height: var(--icon-size);
192+
width: var(--icon-size);
187193

188194
circle {
189195
fill: var(--curriculum-bg-color-list-item-icon);
@@ -196,8 +202,7 @@
196202

197203
> span {
198204
color: var(--text-primary);
199-
font-weight: var(--font-body-strong-weight);
200-
margin: auto;
205+
margin: 0 auto;
201206
text-align: center;
202207
}
203208
}
@@ -209,7 +214,7 @@
209214
font-size: var(--type-smaller-font-size);
210215
height: 11rem;
211216
justify-content: space-between;
212-
padding: 1rem 1.5rem;
217+
padding: var(--spacing);
213218

214219
p {
215220
color: var(--text-secondary);

0 commit comments

Comments
 (0)