From 722c86f2b1a0c4bfab67dba7f38a06615bb61dfe Mon Sep 17 00:00:00 2001 From: nakyong82 Date: Mon, 13 May 2024 22:59:39 +0900 Subject: [PATCH] =?UTF-8?q?=E2=9C=A8Feat:=20=EA=B9=83=ED=97=88=EB=B8=8C=20?= =?UTF-8?q?=EC=9C=A0=ED=8A=9C=EB=B8=8C=20=EB=A7=81=ED=81=AC=20=EC=A0=81?= =?UTF-8?q?=EC=9A=A9=20#31?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../project/introduction/ProjectIntroduction.tsx | 15 ++++++++++++--- src/hooks/project/notionProjectDataRefactor.ts | 4 ++++ src/interfaces/project/projectData.ts | 2 ++ 3 files changed, 18 insertions(+), 3 deletions(-) diff --git a/src/components/project/introduction/ProjectIntroduction.tsx b/src/components/project/introduction/ProjectIntroduction.tsx index 3ba45be..5442140 100644 --- a/src/components/project/introduction/ProjectIntroduction.tsx +++ b/src/components/project/introduction/ProjectIntroduction.tsx @@ -8,6 +8,7 @@ import { ProjectData } from '@/interfaces/project/projectData'; import ProjectIntroductionBand from './ProjectIntroductionBand'; import { motion } from 'framer-motion'; import { slideUpVariants } from '@/constants/project/slideUpVariants'; +import Link from 'next/link'; /** * @description @@ -44,9 +45,17 @@ const ProjectIntroduction = ({ projectData }: { projectData: ProjectData }) => { className="flex flex-col justify-end my-3" >
- - - + {projectData?.github && ( + + + + )} + {/* */} + {projectData?.youtube && ( + + + + )}
{projectData?.title}
{projectData?.introduce}
diff --git a/src/hooks/project/notionProjectDataRefactor.ts b/src/hooks/project/notionProjectDataRefactor.ts index 868ba4f..9b19b4b 100644 --- a/src/hooks/project/notionProjectDataRefactor.ts +++ b/src/hooks/project/notionProjectDataRefactor.ts @@ -34,6 +34,10 @@ export function refactorProjectData(item: any, memberList: any[]): ProjectData { ), content: '', date: '', + youtube: + item?.properties['유튜브 링크']?.rich_text[0]?.plain_text ?? undefined, + github: + item?.properties['깃허브 링크']?.rich_text[0]?.plain_text ?? undefined, }; } diff --git a/src/interfaces/project/projectData.ts b/src/interfaces/project/projectData.ts index 0593026..22c8394 100644 --- a/src/interfaces/project/projectData.ts +++ b/src/interfaces/project/projectData.ts @@ -10,4 +10,6 @@ export interface ProjectData { team: ProjectMemberData[]; content: string; date: string; // 일단은 연도값만 넣기 + youtube?: string; + github?: string; }