design: LearningLecturesPage 카드 크기 수정
This commit is contained in:
parent
b34273992c
commit
b948fbde88
@ -1,5 +1,5 @@
|
||||
import { ClassCard } from '../../components/ClassCard';
|
||||
import { ClassGrid } from '../../components/ClassGrid';
|
||||
import styles from './LearningLecturesPage.module.css';
|
||||
import { Link } from 'react-router-dom';
|
||||
|
||||
export default function LearningLecturesPage() {
|
||||
const { data: onGoingClasses } = {
|
||||
@ -11,15 +11,20 @@ export default function LearningLecturesPage() {
|
||||
};
|
||||
|
||||
return (
|
||||
<ClassGrid title="수강중인 강의">
|
||||
<section>
|
||||
<h2 className={styles.title}>수강중인 강의</h2>
|
||||
<div className={styles.grid}>
|
||||
{onGoingClasses.map((lecture) => (
|
||||
<ClassCard
|
||||
<Link
|
||||
key={lecture.lecture_id}
|
||||
path={`/lecture/${lecture.lecture_id}`}
|
||||
to={`/lecture/${lecture.lecture_id}`}
|
||||
className={styles.card}
|
||||
>
|
||||
{lecture.title}
|
||||
</ClassCard>
|
||||
<div className={styles.thumbnail} />
|
||||
<div>{lecture.title}</div>
|
||||
</Link>
|
||||
))}
|
||||
</ClassGrid>
|
||||
</div>
|
||||
</section>
|
||||
);
|
||||
}
|
||||
|
@ -0,0 +1,32 @@
|
||||
.title {
|
||||
font-size: 32px;
|
||||
line-height: 1.2;
|
||||
font-weight: 700;
|
||||
color: var(--text-color);
|
||||
margin: 0 0 20px;
|
||||
}
|
||||
|
||||
.grid {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(auto-fill, minmax(285px, auto));
|
||||
gap: 20px;
|
||||
justify-content: start;
|
||||
margin-bottom: 40px;
|
||||
}
|
||||
|
||||
.card {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 12px;
|
||||
font-size: 16px;
|
||||
line-height: 1.4;
|
||||
font-weight: 400;
|
||||
}
|
||||
|
||||
.thumbnail {
|
||||
width: 286.66px;
|
||||
height: 220px;
|
||||
border-radius: 20px;
|
||||
background-color: var(--background-secondary);
|
||||
box-sizing: border-box;
|
||||
}
|
Loading…
Reference in New Issue
Block a user