Skip to content

Commit 62b4085

Browse files
committed
style: commission card style
1 parent f17faa3 commit 62b4085

File tree

4 files changed

+41
-16
lines changed

4 files changed

+41
-16
lines changed

app/src/components/Card.tsx

+7-1
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,13 @@ export default function Card(
6262
props.background ? styles.background : ""
6363
}`}
6464
>
65-
<DirectusImage img={img} name={title || ""} className={styles.picture} />
65+
<div className={styles.imageDiv}>
66+
<DirectusImage
67+
img={img}
68+
name={title || ""}
69+
className={styles.picture}
70+
/>
71+
</div>
6672
<div className={styles.content}>
6773
<h4 className={styles.name}>{title}</h4>
6874
<p className={styles.description}>{description}</p>

app/src/styles/Card.module.scss

+32-14
Original file line numberDiff line numberDiff line change
@@ -2,20 +2,13 @@
22
@use "utilities/variables";
33

44
.card {
5-
@extend .glass;
6-
75
display: flex;
6+
align-items: center;
7+
overflow: hidden;
88

99
border-radius: 5rem;
1010

11-
color: variables.$text-color;
12-
13-
padding: 1rem;
14-
15-
align-items: center;
16-
1711
h4 {
18-
color: variables.$text-color;
1912
margin: 0;
2013
margin-bottom: 0.5rem;
2114
font-weight: lighter;
@@ -31,9 +24,6 @@
3124
}
3225

3326
.picture {
34-
border: 3px white solid;
35-
border-radius: 50%;
36-
3727
overflow: hidden;
3828
}
3929

@@ -48,29 +38,43 @@
4838
}
4939

5040
&.small {
41+
@extend .glass;
5142
flex-direction: row;
5243

44+
padding: 1rem;
45+
5346
width: 19rem;
5447
height: 6rem;
5548

49+
color: variables.$text-color;
50+
51+
h4 {
52+
color: variables.$text-color;
53+
}
54+
5655
.description {
5756
font-size: small;
5857
}
5958

6059
.picture {
6160
min-width: 6rem;
6261
min-height: 6rem;
62+
63+
border: 3px white solid;
64+
border-radius: 50%;
6365
}
6466
}
6567

6668
&.large {
69+
background-color: variables.$white-background-color;
6770
flex-direction: column;
6871

69-
gap: 0;
72+
height: 100%;
7073

71-
height: calc(100% - 2rem);
7274
border-radius: 4rem;
7375

76+
box-shadow: 0 4px 30px rgba(0, 0, 100, 0.3);
77+
7478
h4 {
7579
font-size: 2rem;
7680
margin-bottom: 1rem;
@@ -80,9 +84,23 @@
8084
font-size: medium;
8185
}
8286

87+
.content {
88+
margin: 2rem;
89+
}
90+
91+
.imageDiv {
92+
width: 100%;
93+
align-items: center;
94+
background-color: white;
95+
padding: 1rem;
96+
}
97+
8398
.picture {
8499
width: 10rem;
85100
height: 10rem;
101+
102+
margin: auto;
103+
86104
border-radius: 2rem;
87105
overflow: hidden;
88106
background-color: white;

app/src/styles/CommissionsPage.module.scss

+1-1
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
grid-template-columns: repeat(auto-fit, minmax(28rem, 1fr));
2828
grid-template-rows: auto auto auto;
2929

30-
gap: 4rem;
30+
gap: 2rem;
3131

3232
align-items: center;
3333
justify-items: center;

app/src/styles/utilities/_variables.scss

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
$background-color: #1c70ddff;
22
$white-background-color: #fafafa;
3+
$red-background-color: #e70060;
34

45
$text-color: #fafafa;
56
$dark-text-color: #273183;

0 commit comments

Comments
 (0)