-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[✨Feature] 세미나 반응형, 스타일 수정, 오픈 세미나 페이지 생성 #42
Merged
Merged
Changes from all commits
Commits
Show all changes
10 commits
Select commit
Hold shift + click to select a range
a2044d8
💄 Style - 세미나 헤더, 메뉴바, 토글 스타일 양식대로 변경 #40
bianbbc87 f35911d
💄 Style - 세미나 썸네일 반응형, 스타일 양식 맞춤 #40
bianbbc87 5b548a7
💄 Style - 세미나 디테일 스타일 양식 수정 #40
bianbbc87 2526e3b
💄Design-오픈세미나 css 구현 #41
bianbbc87 6a52530
💄Design-오픈세미나용 presenter image 추가 #41
bianbbc87 f1ae457
✨ Feat-세미나 디테일, 오픈 세미나 이동-id에 따른 데이터 값 분리 #41
bianbbc87 dbf5f19
♻️Refactor-토글 메뉴 gap 변경, seminar data id 순서 변경 #41
bianbbc87 b97019a
💄 Style - 배경 블랙으로 변경 #40
bianbbc87 a9f53d2
💄 Style - 불필요한 border 제거 #40
bianbbc87 f6f37ff
♻️Refactor - 오픈세미나 data set 변경 #41
bianbbc87 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
'use client'; | ||
|
||
import React from 'react'; | ||
import { usePathname } from 'next/navigation'; | ||
import OpenSeminarDetailHeader from '@/components/seminar/openSeminarDetail/header/OpenSeminarDetailHeader'; | ||
import OpenSeminarDetailBanner from '@/components/seminar/openSeminarDetail/banner/OpenSeminarDetailBanner'; | ||
import OpenSeminarDetailSeminars from '@/components/seminar/openSeminarDetail/kindOfSeminar/OpenSeminarDetailSeminars'; | ||
import OpenSeminarDetailInformation from '@/components/seminar/openSeminarDetail/information/OpenSeminarDetailInformation'; | ||
import { OPEN_SEMINAR_DATA } from '@/constants/seminar/openSeminarData'; | ||
import NotFoundPage from '@/app/not-found'; | ||
import { changeOpenPathtoNumber } from '@/hooks/seminar/changePathtoNumber'; | ||
|
||
const OpenSeminarDetailPage = () => { | ||
const pathname = usePathname(); | ||
// 숫자 추출 | ||
var id = changeOpenPathtoNumber(pathname); | ||
|
||
// 객체 찾기 | ||
const seminar = OPEN_SEMINAR_DATA.find(seminar => Number(seminar.id) === id); | ||
|
||
if (!seminar) { | ||
// 세미나를 찾지 못한 경우 | ||
return <NotFoundPage />; | ||
} | ||
|
||
return <section className="flex justify-center"> | ||
<div className="max-w-[1200px] desktop:px-10 tablet:px-10 px-4 bg-mono_black"> | ||
<div className="w-full"> | ||
{/* header */} | ||
<OpenSeminarDetailHeader key={`${seminar.id}_header`} data={seminar}/> | ||
{/* banner */} | ||
<OpenSeminarDetailBanner key={`${seminar.id}_banner`} data={seminar}/> | ||
{/* seminars */} | ||
<OpenSeminarDetailSeminars key={`${seminar.id}_seminars`} data={seminar}/> | ||
{/* information */} | ||
<OpenSeminarDetailInformation key={`${seminar.id}_information`} data={seminar}/> | ||
</div> | ||
<div className="h-[120px]"></div> | ||
</div> | ||
</section>; | ||
}; | ||
|
||
export default OpenSeminarDetailPage; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
72 changes: 72 additions & 0 deletions
72
src/components/seminar/openSeminarDetail/banner/OpenSeminarDetailBanner.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,72 @@ | ||
import React from 'react'; | ||
import Image from 'next/image'; | ||
import { SeminarThumnail } from '@/interfaces/seminar/seminarThumbnail'; | ||
import TranslateImg from '@/svg/seminar/translate_img.png'; | ||
import { OpenSeminar } from '@/interfaces/seminar/openSeminar'; | ||
|
||
|
||
/** | ||
* @description | ||
* 오픈 세미나 상세 페이지 배너 컴포넌트 | ||
* @component OpenSeminarDetailBanner | ||
* @returns {JSX.Element} OpenSeminarDetailBanner | ||
* @since 2024.04.18 | ||
*/ | ||
/** | ||
* Renders the header component for the recruitment section. | ||
* @returns The rendered header component. | ||
*/ | ||
const OpenSeminarDetailBanner = ({ data }: { data: OpenSeminar }) => { | ||
return ( | ||
<div className="w-full mt-8 flex desktop:flex-row tablet:flex-col flex-col flex-col gap-8"> | ||
{/* 왼쪽 컨텐츠 */} | ||
<div className="desktop:min-w-[544px] tablet:w-full w-full aspect-w-16 aspect-h-9"> | ||
<Image | ||
src={data.image_url} | ||
alt={`${data.seminar_month_date}'s open_seminarimage`} | ||
width={1600} | ||
height={900} | ||
quality={100} | ||
priority | ||
/> | ||
</div> | ||
{/* 오른쪽 컨텐츠 */} | ||
<div className="flex desktop:items-end desktop:mt-0 tablet:mt-8 mt-8"> | ||
<div className="w-full flex flex-col gap-6 py-3 whitespace-nowrap"> | ||
<div className='desktop:flex tablet:hidden hidden'> | ||
<Image | ||
src={TranslateImg.src} | ||
alt="translate_img" | ||
width={352} | ||
height={56} | ||
quality={100} | ||
priority | ||
/> | ||
</div> | ||
<div> | ||
<p className="H6 font-medium"> | ||
Date | ||
</p> | ||
<p className="B1 font-normal"> | ||
{data.seminar_opening_date} | ||
</p> | ||
</div> | ||
<div> | ||
<p className="H6 font-medium"> | ||
Location | ||
</p> | ||
<p className="B1 font-normal"> | ||
{data.location} | ||
</p> | ||
</div> | ||
<div> | ||
<button className={`w-full rounded py-4 text-[0.75rem] font-medium ${data.status === false ? "text-mono_500 border border-mono_500 pointer-events-none" : "text-mono_black bg-white"}`}> | ||
{data.status === false ? '모집 기간이 아니에요.' : '모집 신청하기'} | ||
</button> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
); | ||
}; | ||
export default OpenSeminarDetailBanner; |
41 changes: 41 additions & 0 deletions
41
src/components/seminar/openSeminarDetail/header/OpenSeminarDetailHeader.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
'use client'; | ||
|
||
import { OpenDetailSeminar, OpenSeminar } from '@/interfaces/seminar/openSeminar'; | ||
import React, { useState } from 'react'; | ||
|
||
/** | ||
* @description | ||
* 오픈 세미나 상세 페이지 헤더 컴포넌트 | ||
* @component OpenSeminarDetailHeader | ||
* @returns {JSX.Element} OpenSeminarDetailHeader | ||
* @since 2024.05.01 | ||
*/ | ||
/** | ||
* Renders the header component for the recruitment section. | ||
* @returns The rendered header component. | ||
*/ | ||
const OpenSeminarDetailHeader = ({ data }: { data: OpenSeminar }) => { | ||
const [categoryData, setCategoryData] = useState([data.type, `${data.flag}st`]); | ||
|
||
return ( | ||
<> | ||
<div className="mt-10 px-3 flex gap-3" > | ||
{categoryData.map((category, index) => ( | ||
<button | ||
className={`text-[0.75rem] font-medium py-2 px-3 border border-solid rounded-lg ${index === 0 ? "mono_white" : "border-mono_500 text-mono_500"}`} | ||
key={index} | ||
> | ||
{category} | ||
</button> | ||
))} | ||
</div> | ||
<p className="w-full px-3 pt-8 H3 font-normal"> | ||
{data.seminar_month_date}{" "}{data.type} | ||
</p> | ||
<p className="w-full px-3 pt-3 H6 font-medium"> | ||
{data.description} | ||
</p> | ||
</> | ||
); | ||
}; | ||
export default OpenSeminarDetailHeader; |
34 changes: 34 additions & 0 deletions
34
src/components/seminar/openSeminarDetail/information/OpenSeminarDetailInformation.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
import React from 'react'; | ||
import { OpenSeminar } from '@/interfaces/seminar/openSeminar'; | ||
|
||
/** | ||
* @description | ||
* 오픈 세미나 정보 컴포넌트 | ||
* @component OpenSeminarDetailInformation | ||
* @returns {JSX.Element} OpenSeminarDetailInformation | ||
* @since 2024.04.18 | ||
*/ | ||
/** | ||
* Renders the header component for the recruitment section. | ||
* @returns The rendered header component. | ||
*/ | ||
const OpenSeminarDetailInformation = ({ data }: { data: OpenSeminar }) => { | ||
|
||
return ( | ||
<div className="w-full flex mt-10 pt-6 flex-col inline-flex min-h-fit relative"> | ||
<p className="H4 font-normal px-2 pb-4"> | ||
Information | ||
</p> | ||
<p className="mb-3 border border-solid text-mono_700 h-0"/> | ||
<div className='text-[1rem] font-normal w-full mt-8 text-mono_white'> | ||
{data.information.split('<br>').map((line, index) => ( | ||
<React.Fragment key={index}> | ||
{line} | ||
<br /> | ||
</React.Fragment> | ||
))} | ||
</div> | ||
</div> | ||
); | ||
}; | ||
export default OpenSeminarDetailInformation; |
37 changes: 37 additions & 0 deletions
37
src/components/seminar/openSeminarDetail/kindOfSeminar/OpenSeminarDetailSeminars.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
import React from 'react'; | ||
import OpenSeminarsDetailBox from './OpenSeminarsDetailBox'; | ||
import { OpenSeminar } from '@/interfaces/seminar/openSeminar'; | ||
import { OPEN_SEMINAR_DATA } from '@/constants/seminar/openSeminarData'; | ||
import Link from 'next/link'; | ||
|
||
/** | ||
* @description | ||
* 오픈 세미나 상세 페이지 세미나 종류 컴포넌트 | ||
* @component OpenSeminarDetailSeminars | ||
* @returns {JSX.Element} OpenSeminarDetailSeminars | ||
* @since 2024.04.18 | ||
*/ | ||
/** | ||
* Renders the header component for the recruitment section. | ||
* @returns The rendered header component. | ||
*/ | ||
const OpenSeminarDetailSeminars = ({ data }: { data: OpenSeminar }) => { | ||
|
||
return ( | ||
<div className="w-full mt-10 pt-6 flex-col inline-flex min-h-fit relative"> | ||
<p className="H4 font-normal px-2 pb-4"> | ||
Seminars | ||
</p> | ||
<p className="mb-3 border border-solid text-mono_700 h-0"/> | ||
<div className='mt-5 flex grid desktop:grid-cols-2 tablet:grid-cols-1 gap-8'> | ||
{data.seminars.map((seminar, index) => ( | ||
<OpenSeminarsDetailBox | ||
key={`${seminar.id}_${index}_seminar`} | ||
data={seminar} | ||
/> | ||
))} | ||
</div> | ||
</div> | ||
); | ||
}; | ||
export default OpenSeminarDetailSeminars; |
39 changes: 39 additions & 0 deletions
39
src/components/seminar/openSeminarDetail/kindOfSeminar/OpenSeminarsDetailBox.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
import { OpenDetailSeminar, OpenSeminar } from '@/interfaces/seminar/openSeminar'; | ||
import Image from 'next/image'; | ||
import React from 'react'; | ||
|
||
/** | ||
* @description | ||
* 세미나 상세 페이지 리뷰 디테일 컴포넌트 | ||
* @component SeminarDetailReviewDetail | ||
* @returns {JSX.Element} SeminarDetailReviewDetail | ||
* @since 2024.04.18 | ||
*/ | ||
/** | ||
* Renders the header component for the recruitment section. | ||
* @returns The rendered header component. | ||
*/ | ||
const OpenSeminarsDetailBox = ({ data }: { data: OpenDetailSeminar }) => { | ||
|
||
return ( | ||
<div className="w-full flex flex-row p-4 bg-mono_900 rounded gap-4"> | ||
<div className='rounded overflow-hidden'> | ||
<Image | ||
src={data.presenter_image_url} | ||
alt="translate_img" | ||
width={64} | ||
height={64} | ||
quality={100} | ||
priority | ||
/> | ||
</div> | ||
<div className='flex flex-col justify-center'> | ||
<div className="B1 font-medium flex gap-2"> | ||
{data.presenter} <p className="B1 font-normal text-mono_200">{data.presenter_role}</p> | ||
</div> | ||
<p className='className="B1 font-normal'>{data.seminar_title}</p> | ||
</div> | ||
</div> | ||
); | ||
}; | ||
export default OpenSeminarsDetailBox; |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
px rem으로 바꾸면 좋을듯 합니당
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
넵!