Merge pull request #76 from TeamBNBN/FE/design-fix

[Front-End] design: Fe/design fix
This commit is contained in:
Jo Hyeonsoo 2024-07-22 13:08:24 +09:00 committed by GitHub
commit 56d2d775e6
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 9 additions and 4 deletions

View File

@ -1,13 +1,13 @@
import { Link } from 'react-router-dom';
import styles from './ArticlePreview.module.css';
export default function ArticlePreview({ title, contents = [] }) {
export default function ArticlePreview({ to, title, contents = [] }) {
// TODO:
return (
<div className={styles.wrapper}>
<div className={styles.header}>
<div className={styles.title}>{title}</div>
<Link to="/">ICON</Link>
<Link to={to}>ICON</Link>
</div>
<div className={styles.main}>
{contents.map((content) => {

View File

@ -1,4 +1,5 @@
import ArticlePreview from '../../components/Article/ArticlePreview/ArticlePreview';
import styles from './LearningLectureDetailPage.module.css';
export default function LearningLectureDetailPage() {
const { data: notices } = {
@ -19,16 +20,18 @@ export default function LearningLectureDetailPage() {
],
};
return (
<>
<main className={styles.previews}>
<ArticlePreview
to="notice"
title="공지사항"
contents={notices}
/>
<ArticlePreview
to="qna"
title="Q&A"
contents={questions}
/>
<ArticlePreview title="커리큘럼" />
</>
</main>
);
}

View File

@ -24,10 +24,12 @@ export default function TeacherLectureDetailPage() {
<main className={styles.previews}>
{/* FIXME: 밑에 ArticlePreview 바꿔야함. 공지사항 Q&A 커리큘럼 으로 나눠서 작성할 수 있게 바꾸고 링크 상위 3개만 받고 링크 줄 수 있게 할지 말지. 이거 바꾸면 LearningLectureDetailPage도 똑같이 바꾸면 될듯*/}
<ArticlePreview
to="notice"
title="공지사항"
contents={notices}
/>
<ArticlePreview
to="qna"
title="Q&A"
contents={questions}
/>