diff --git a/package.json b/package.json
index 0e8daac..b35068a 100644
--- a/package.json
+++ b/package.json
@@ -23,6 +23,7 @@
"@next/bundle-analyzer": "^12.1.0",
"aos": "^3.0.0-beta.6",
"axios": "^0.26.0",
+ "dayjs": "^1.11.10",
"editorjs-html": "^3.4.3",
"lodash-es": "^4.17.21",
"lottie-web": "^5.9.1",
diff --git a/pages/index.tsx b/pages/index.tsx
index ccd07f2..a7b0453 100644
--- a/pages/index.tsx
+++ b/pages/index.tsx
@@ -6,7 +6,6 @@ import {
RecruitingOpenHero,
RecruitingPeriod,
RecruitingRemainder,
- NotRecruitmentPeriod,
} from '@/components';
import { useAOS } from '@/hooks';
@@ -17,7 +16,6 @@ import { useEffect, useState } from 'react';
const Home = () => {
useAOS();
- const [isOpenNotRecruitMentModal, setIsOpenNotRecruitmentModal] = useState(true);
const [recruitingProgressStatus, setRecruitingProgressStatus] = useState<
RecruitingProgressStatus | 'NOT_INITIALIZED'
>('NOT_INITIALIZED');
@@ -36,9 +34,6 @@ const Home = () => {
- {isOpenNotRecruitMentModal && (
-
- )}
)}
>
diff --git a/src/components/common/Footer/Footer.component.tsx b/src/components/common/Footer/Footer.component.tsx
index 0225c3a..9c4081f 100644
--- a/src/components/common/Footer/Footer.component.tsx
+++ b/src/components/common/Footer/Footer.component.tsx
@@ -19,7 +19,7 @@ const Footer = () => {
- © Mash-Up 2023. Made in Seoul.
+ © Mash-Up 2024. Made in Seoul.
{
@@ -18,7 +18,7 @@ const RecruitingOpenHero = () => {
data-aos="fade-up"
data-aos-duration={AOS_DEFAULT_DURATION + AOS_BASE_DURATION_DISTANCE}
>
- 13th
+ {CURRENT_GENERATION}th
{
+ const { RECRUITMENT_START_KST_DATE, RECRUITMENT_END_KST_DATE } = RECRUIT_DATE;
+
+ const DAYJS_RECRUITMENT_START_KST_DATE = dayjs(RECRUITMENT_START_KST_DATE);
+ const DAYJS_RECRUITMENT_END_KST_DATE = dayjs(RECRUITMENT_END_KST_DATE);
+
return (
Start Date
- 2023년 1월 11일
-
@@ -24,9 +32,11 @@ const RecruitingPeriod = () => {
data-aos-duration={AOS_DEFAULT_DURATION + AOS_BASE_DURATION_DISTANCE}
>
End Date
- 2023년 1월 25일
-
- 01.25
+
+ {DAYJS_RECRUITMENT_END_KST_DATE.format('YYYY년 M월 D일')}
+
+
+ {DAYJS_RECRUITMENT_END_KST_DATE.format('MM.DD')}
diff --git a/src/components/home/RecruitingPeriodDesktop/RecruitingPeriodDesktop.component.tsx b/src/components/home/RecruitingPeriodDesktop/RecruitingPeriodDesktop.component.tsx
index f071787..a1d2bb8 100644
--- a/src/components/home/RecruitingPeriodDesktop/RecruitingPeriodDesktop.component.tsx
+++ b/src/components/home/RecruitingPeriodDesktop/RecruitingPeriodDesktop.component.tsx
@@ -1,18 +1,26 @@
-import { AOS_BASE_DURATION_DISTANCE, AOS_DEFAULT_DURATION } from '@/constants';
+import { AOS_BASE_DURATION_DISTANCE, AOS_DEFAULT_DURATION, RECRUIT_DATE } from '@/constants';
import { Lottie, ScreenReaderOnly } from '@/components';
import computerLottie from '@/assets/lottie/computer.json';
import PeriodArrow from '@/assets/svg/period-arrow.svg';
import fireLottie from '@/assets/lottie/fire.json';
+import dayjs from 'dayjs';
import * as Styled from './RecruitingPeriodDesktop.styled';
const RecruitingPeriodDesktop = () => {
+ const { RECRUITMENT_START_KST_DATE, RECRUITMENT_END_KST_DATE } = RECRUIT_DATE;
+
+ const DAYJS_RECRUITMENT_START_KST_DATE = dayjs(RECRUITMENT_START_KST_DATE);
+ const DAYJS_RECRUITMENT_END_KST_DATE = dayjs(RECRUITMENT_END_KST_DATE);
+
return (
Start Date
- 2023년 1월 11일
-
- 01.11
+
+ {DAYJS_RECRUITMENT_START_KST_DATE.format('YYYY년 M월 D일')}
+
+
+ {DAYJS_RECRUITMENT_START_KST_DATE.format('MM.DD')}
{
data-aos-duration={AOS_DEFAULT_DURATION + 3 * AOS_BASE_DURATION_DISTANCE}
>
End Date
- 2023년 1월 25일
-
- 01.25
+
+ {DAYJS_RECRUITMENT_END_KST_DATE.format('YYYY년 M월 D일')}
+
+
+ {DAYJS_RECRUITMENT_END_KST_DATE.format('MM.DD')}
diff --git a/src/components/home/RecruitingProcess/RecruitingProcess.component.tsx b/src/components/home/RecruitingProcess/RecruitingProcess.component.tsx
index a9c5703..77b4c35 100644
--- a/src/components/home/RecruitingProcess/RecruitingProcess.component.tsx
+++ b/src/components/home/RecruitingProcess/RecruitingProcess.component.tsx
@@ -1,8 +1,27 @@
import { ScreenReaderOnly } from '@/components';
-import { CURRENT_GENERATION } from '@/constants';
+import { CURRENT_GENERATION, DAYS, RECRUIT_DATE } from '@/constants';
+import dayjs from 'dayjs';
import * as Styled from './RecruitingProcess.styled';
const RecruitingProcess = () => {
+ const {
+ RECRUITMENT_START_KST_DATE,
+ RECRUITMENT_END_KST_DATE,
+ SCREENING_RESULT_ANNOUNCED_KST_DATE,
+ INTERVIEW_START_KST_DATE,
+ INTERVIEW_END_KST_DATE,
+ INTERVIEW_RESULT_ANNOUNCED_KST_DATE,
+ AFTER_FIRST_SEMINAR_JOIN_KST_DATE,
+ } = RECRUIT_DATE;
+
+ const DAYJS_RECRUITMENT_START_KST_DATE = dayjs(RECRUITMENT_START_KST_DATE);
+ const DAYJS_RECRUITMENT_END_KST_DATE = dayjs(RECRUITMENT_END_KST_DATE);
+ const DAYJS_SCREENING_RESULT_ANNOUNCED_KST_DATE = dayjs(SCREENING_RESULT_ANNOUNCED_KST_DATE);
+ const DAYJS_INTERVIEW_START_KST_DATE = dayjs(INTERVIEW_START_KST_DATE);
+ const DAYJS_INTERVIEW_INTERVIEW_END_KST_DATE = dayjs(INTERVIEW_END_KST_DATE);
+ const DAYJS_INTERVIEW_RESULT_ANNOUNCED_KST_DATE = dayjs(INTERVIEW_RESULT_ANNOUNCED_KST_DATE);
+ const DAYJS_AFTER_FIRST_SEMINAR_JOIN_KST_DATE = dayjs(AFTER_FIRST_SEMINAR_JOIN_KST_DATE);
+
return (
@@ -12,48 +31,99 @@ const RecruitingProcess = () => {
서류 접수
- 2023년 1월 11일 수요일부터 2023년 1월 25일 수요일
+ {`${DAYJS_RECRUITMENT_START_KST_DATE.format('YYYY년 M월 D일')} ${
+ DAYS[DAYJS_RECRUITMENT_START_KST_DATE.day()]
+ }요일부터 ${DAYJS_RECRUITMENT_END_KST_DATE.format('YYYY년 M월 D일')} ${
+ DAYS[DAYJS_RECRUITMENT_END_KST_DATE.day()]
+ }요일`}
- 01.11(수) ~
- 01.25(수)
+
+ {`${DAYJS_RECRUITMENT_START_KST_DATE.format('MM.DD')}(${
+ DAYS[DAYJS_RECRUITMENT_START_KST_DATE.day()]
+ })`}
+
+ ~
+ {`${DAYJS_RECRUITMENT_END_KST_DATE.format('MM.DD')}(${
+ DAYS[DAYJS_RECRUITMENT_END_KST_DATE.day()]
+ })`}
- 23:59:59 마감
+ {`${DAYJS_RECRUITMENT_END_KST_DATE.format('HH:mm:ss')} 마감`}
서류 결과 발표
- 2023년 1월 30일 월요일
-
- 01.30(월)
+ {`${DAYJS_SCREENING_RESULT_ANNOUNCED_KST_DATE.format(
+ 'YYYY년 M월 D일',
+ )} ${DAYS[DAYJS_SCREENING_RESULT_ANNOUNCED_KST_DATE.day()]}요일`}
+
+ {`${DAYJS_SCREENING_RESULT_ANNOUNCED_KST_DATE.format('MM.DD')}(${
+ DAYS[DAYJS_SCREENING_RESULT_ANNOUNCED_KST_DATE.day()]
+ })`}
- 오후 9시
+ {`${DAYJS_SCREENING_RESULT_ANNOUNCED_KST_DATE.format(
+ 'HH',
+ )}시`}
온/오프라인 면접
- 2023년 2월 4일 토요일에서 2023년 2월 5일 일요일
+ {`${DAYJS_INTERVIEW_START_KST_DATE.format('YYYY년 M월 D일')} ${
+ DAYS[DAYJS_INTERVIEW_START_KST_DATE.day()]
+ }요일에서 ${DAYJS_INTERVIEW_INTERVIEW_END_KST_DATE.format('YYYY년 M월 D일')} ${
+ DAYS[DAYJS_INTERVIEW_INTERVIEW_END_KST_DATE.day()]
+ }요일`}
- 02.04(토) ~
- 02.05(일)
+ {`${DAYJS_INTERVIEW_START_KST_DATE.format('MM.DD')}(${
+ DAYS[DAYJS_INTERVIEW_START_KST_DATE.day()]
+ })`}
+ ~
+ {`${DAYJS_INTERVIEW_INTERVIEW_END_KST_DATE.format('MM.DD')}(${
+ DAYS[DAYJS_INTERVIEW_INTERVIEW_END_KST_DATE.day()]
+ })`}
- 추후 연락
+ 상세일정 이메일로 전달
최종 합격 발표
- 2023년 2월 7일 화요일
-
- 02.07(화)
+ {`${DAYJS_INTERVIEW_RESULT_ANNOUNCED_KST_DATE.format(
+ 'YYYY년 M월 D일',
+ )} ${DAYS[DAYJS_INTERVIEW_RESULT_ANNOUNCED_KST_DATE.day()]}요일`}
+
+ {`${DAYJS_INTERVIEW_RESULT_ANNOUNCED_KST_DATE.format('MM.DD')}(${
+ DAYS[DAYJS_INTERVIEW_RESULT_ANNOUNCED_KST_DATE.day()]
+ })`}
- 오후 9시
+ {`${DAYJS_INTERVIEW_RESULT_ANNOUNCED_KST_DATE.format(
+ 'HH',
+ )}시`}
{CURRENT_GENERATION}기 OT
- 2023년 2월 11일 토요일
-
- 02.11(토)
+ {`${DAYJS_AFTER_FIRST_SEMINAR_JOIN_KST_DATE.format(
+ 'YYYY년 M월 D일',
+ )} ${DAYS[DAYJS_AFTER_FIRST_SEMINAR_JOIN_KST_DATE.day()]}요일`}
+
+ {`${DAYJS_AFTER_FIRST_SEMINAR_JOIN_KST_DATE.format('MM.DD')}(${
+ DAYS[DAYJS_AFTER_FIRST_SEMINAR_JOIN_KST_DATE.day()]
+ })`}
diff --git a/src/components/home/RecruitingRemainder/RecruitingRemainder.component.tsx b/src/components/home/RecruitingRemainder/RecruitingRemainder.component.tsx
index f8a3e95..4fb0cab 100644
--- a/src/components/home/RecruitingRemainder/RecruitingRemainder.component.tsx
+++ b/src/components/home/RecruitingRemainder/RecruitingRemainder.component.tsx
@@ -1,17 +1,17 @@
import { useRouter } from 'next/router';
import { useInterval } from '@/hooks';
-import { getDifferenceOfDates, RECRUITMENT_START_KST_DATE } from '@/utils/date';
+import { getDifferenceOfDates } from '@/utils/date';
import type { DateDifference } from '@/utils/date';
import { useState, useEffect } from 'react';
-import { CURRENT_GENERATION } from '@/constants';
+import { CURRENT_GENERATION, RECRUIT_DATE } from '@/constants';
import * as Styled from './RecruitingRemainder.styled';
const RecruitingRemainder = () => {
const router = useRouter();
const [difference, setDifference] = useState(() =>
- getDifferenceOfDates(new Date(), RECRUITMENT_START_KST_DATE),
+ getDifferenceOfDates(new Date(), RECRUIT_DATE.RECRUITMENT_START_KST_DATE),
);
const [isPreviousDayOfRecruitingStart, isRunOutTimeOfRecruitingStart] = [
@@ -21,7 +21,10 @@ const RecruitingRemainder = () => {
useInterval(
() => {
- const currentDifference = getDifferenceOfDates(new Date(), RECRUITMENT_START_KST_DATE);
+ const currentDifference = getDifferenceOfDates(
+ new Date(),
+ RECRUIT_DATE.RECRUITMENT_START_KST_DATE,
+ );
setDifference(currentDifference);
},
isPreviousDayOfRecruitingStart ? 1000 : null,
diff --git a/src/components/recruit/RecruitDate/RecruitDate.component.tsx b/src/components/recruit/RecruitDate/RecruitDate.component.tsx
index 39b8ccb..d28d76f 100644
--- a/src/components/recruit/RecruitDate/RecruitDate.component.tsx
+++ b/src/components/recruit/RecruitDate/RecruitDate.component.tsx
@@ -1,10 +1,22 @@
+import { RECRUIT_DATE } from '@/constants';
+import dayjs from 'dayjs';
import * as Styled from './RecruitDate.styled';
const RecruitDate = () => {
+ const { RECRUITMENT_START_KST_DATE, RECRUITMENT_END_KST_DATE } = RECRUIT_DATE;
+
+ const DAYJS_RECRUITMENT_START_KST_DATE = dayjs(RECRUITMENT_START_KST_DATE);
+ const DAYJS_RECRUITMENT_END_KST_DATE = dayjs(RECRUITMENT_END_KST_DATE);
+
return (
- 2023.01.11 ~
- 01.25
+
+ {DAYJS_RECRUITMENT_START_KST_DATE.format('MM.DD')}
+
+ ~
+
+ {DAYJS_RECRUITMENT_END_KST_DATE.format('MM.DD')}
+
);
};
diff --git a/src/constants/application.ts b/src/constants/application.ts
index 0735b8f..9ee5a61 100644
--- a/src/constants/application.ts
+++ b/src/constants/application.ts
@@ -1,4 +1,4 @@
-export const CURRENT_GENERATION = 13;
+export const CURRENT_GENERATION = 14;
export const ERROR_CODE = {
APPLICATION_MODIFICATION_NOT_ALLOWED: 'APPLICATION_MODIFICATION_NOT_ALLOWED', // 지원 기간 마감
diff --git a/src/constants/date.ts b/src/constants/date.ts
new file mode 100644
index 0000000..77fc143
--- /dev/null
+++ b/src/constants/date.ts
@@ -0,0 +1 @@
+export const DAYS = ['일', '월', '화', '수', '목', '금', '토'];
diff --git a/src/constants/index.ts b/src/constants/index.ts
index 4892ebc..e66198d 100644
--- a/src/constants/index.ts
+++ b/src/constants/index.ts
@@ -4,3 +4,5 @@ export * from './team';
export * from './platform';
export * from './aos';
export * from './application';
+export * from './recruit';
+export * from './date';
diff --git a/src/constants/recruit.ts b/src/constants/recruit.ts
new file mode 100644
index 0000000..b1bf055
--- /dev/null
+++ b/src/constants/recruit.ts
@@ -0,0 +1,9 @@
+export const RECRUIT_DATE = {
+ RECRUITMENT_START_KST_DATE: new Date('2024-01-29T01:00:00+09:00'), // 서류 접수 시작
+ RECRUITMENT_END_KST_DATE: new Date('2024-02-14T23:59:59+09:00'), // 서류 접수 종료
+ SCREENING_RESULT_ANNOUNCED_KST_DATE: new Date('2024-02-20T21:00:00+09:00'), // 서류 결과 발표
+ INTERVIEW_START_KST_DATE: new Date('2024-02-24T00:00:00+09:00'), // 인터뷰 시작
+ INTERVIEW_END_KST_DATE: new Date('2024-02-25T23:59:59+09:00'), // 인터뷰 종료
+ INTERVIEW_RESULT_ANNOUNCED_KST_DATE: new Date('2024-02-28T21:00:00+09:00'), // 최종 합격 발표
+ AFTER_FIRST_SEMINAR_JOIN_KST_DATE: new Date('2024-03-09T17:00:00+09:00'), // 첫번째 세미나 끝나는 시각
+} as const;
diff --git a/src/constants/team.ts b/src/constants/team.ts
index 3930c13..f104eb0 100644
--- a/src/constants/team.ts
+++ b/src/constants/team.ts
@@ -36,6 +36,15 @@ export const teamIds = {
[teamNames.node]: 15,
[teamNames.spring]: 16,
},
+ // TODO: 14기 팀 id 확정되면 수정
+ 14: {
+ [teamNames.design]: 17,
+ [teamNames.web]: 18,
+ [teamNames.android]: 19,
+ [teamNames.ios]: 20,
+ [teamNames.node]: 21,
+ [teamNames.spring]: 22,
+ },
} as const;
export const TEAM_NICK_NAME: Record = {
diff --git a/src/utils/date.ts b/src/utils/date.ts
index 87c86e1..f95ba32 100644
--- a/src/utils/date.ts
+++ b/src/utils/date.ts
@@ -1,22 +1,7 @@
import { KeyOf } from '@/types';
+import { DAYS, RECRUIT_DATE } from '@/constants';
import { objectKeys } from './object';
-const DAYS = ['일', '월', '화', '수', '목', '금', '토'];
-
-export const [
- RECRUITMENT_START_KST_DATE, // 서류 접수 시작
- RECRUITMENT_END_KST_DATE, // 서류 접수 종료
- SCREENING_RESULT_ANNOUNCED_KST_DATE, // 서류 결과 발표
- INTERVIEW_RESULT_ANNOUNCED_KST_DATE, // 최종 합격 발표
- AFTER_FIRST_SEMINAR_JOIN_KST_DATE, // 첫번째 세미나 끝나는 시각
-] = [
- new Date('2023-01-11T01:00:00+09:00'),
- new Date('2023-01-25T23:59:59+09:00'),
- new Date('2023-01-30T21:00:00+09:00'),
- new Date('2023-02-07T21:00:00+09:00'),
- new Date('2023-02-11T17:00:00+09:00'),
-];
-
export type RecruitingProgressStatus =
| 'PREVIOUS'
| 'IN-RECRUITING' // 지원하기 버튼 enabled
@@ -38,28 +23,34 @@ export const getRecruitingProgressStatusFromRecruitingPeriod = (
const kstDate = getKSTDateFromDate(date);
const currentDate = date.getTime() === kstDate.getTime() ? date : kstDate;
- if (currentDate < RECRUITMENT_START_KST_DATE) {
+ if (currentDate < RECRUIT_DATE.RECRUITMENT_START_KST_DATE) {
return 'PREVIOUS';
}
- if (RECRUITMENT_START_KST_DATE <= currentDate && currentDate <= RECRUITMENT_END_KST_DATE) {
+ if (
+ RECRUIT_DATE.RECRUITMENT_START_KST_DATE <= currentDate &&
+ currentDate <= RECRUIT_DATE.RECRUITMENT_END_KST_DATE
+ ) {
return 'IN-RECRUITING';
}
- if (RECRUITMENT_END_KST_DATE < currentDate && currentDate < SCREENING_RESULT_ANNOUNCED_KST_DATE) {
+ if (
+ RECRUIT_DATE.RECRUITMENT_END_KST_DATE < currentDate &&
+ currentDate < RECRUIT_DATE.SCREENING_RESULT_ANNOUNCED_KST_DATE
+ ) {
return 'END-RECRUITING';
}
if (
- SCREENING_RESULT_ANNOUNCED_KST_DATE <= currentDate &&
- currentDate < INTERVIEW_RESULT_ANNOUNCED_KST_DATE
+ RECRUIT_DATE.SCREENING_RESULT_ANNOUNCED_KST_DATE <= currentDate &&
+ currentDate < RECRUIT_DATE.INTERVIEW_RESULT_ANNOUNCED_KST_DATE
) {
return 'AFTER-SCREENING-ANNOUNCED';
}
if (
- INTERVIEW_RESULT_ANNOUNCED_KST_DATE <= currentDate &&
- currentDate < AFTER_FIRST_SEMINAR_JOIN_KST_DATE
+ RECRUIT_DATE.INTERVIEW_RESULT_ANNOUNCED_KST_DATE <= currentDate &&
+ currentDate < RECRUIT_DATE.AFTER_FIRST_SEMINAR_JOIN_KST_DATE
) {
return 'AFTER-INTERVIEWING-ANNOUNCED';
}
- if (AFTER_FIRST_SEMINAR_JOIN_KST_DATE <= currentDate) {
+ if (RECRUIT_DATE.AFTER_FIRST_SEMINAR_JOIN_KST_DATE <= currentDate) {
return 'AFTER-FIRST-SEMINAR';
}
return 'INVALID';
diff --git a/yarn.lock b/yarn.lock
index 937f6c1..dc08040 100644
--- a/yarn.lock
+++ b/yarn.lock
@@ -5309,6 +5309,11 @@ damerau-levenshtein@^1.0.7:
resolved "https://registry.npmjs.org/damerau-levenshtein/-/damerau-levenshtein-1.0.8.tgz"
integrity sha512-sdQSFB7+llfUcQHUQO3+B8ERRj0Oa4w9POWMI/puGtuf7gFywGmkaLCElnudfTiKZV+NvHqL0ifzdrI8Ro7ESA==
+dayjs@^1.11.10:
+ version "1.11.10"
+ resolved "https://registry.yarnpkg.com/dayjs/-/dayjs-1.11.10.tgz#68acea85317a6e164457d6d6947564029a6a16a0"
+ integrity sha512-vjAczensTgRcqDERK0SR2XMwsF/tSvnvlv6VcF2GIhg6Sx4yOIt/irsr1RDJsKiIyBzJDpCoXiWWq28MqH2cnQ==
+
debug@2.6.9, debug@^2.2.0, debug@^2.3.3, debug@^2.6.0, debug@^2.6.9:
version "2.6.9"
resolved "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz"