Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions components/recruit/RecruitBanner/index.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import {
LINK_BY_STATUS,
RECRUITING_DEADLINE,
RECRUITING_EXTRA_DEADLINE,
RECRUITING_START,
RECRUITING_STATUS,
RecruitStatus,
Expand Down Expand Up @@ -36,6 +37,8 @@ function RecruitBanner() {
return new Date(RECRUITING_START);
case RecruitStatus.ACTIVE:
return new Date(RECRUITING_DEADLINE);
case RecruitStatus.EXTRA:
return new Date(RECRUITING_EXTRA_DEADLINE);
default:
return new Date();
}
Expand Down
5 changes: 4 additions & 1 deletion components/recruit/RecruitField/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,10 @@ function RecruitField(): ReactElement {
key={field.name}
variants={itemVariants}
onClick={() => {
if (status === RecruitStatus.ACTIVE && field.url) {
if (
(status === RecruitStatus.ACTIVE && field.url) ||
(field.name === 'iOS' && status === RecruitStatus.EXTRA)
) {
window.open(field.url, '_blank');
}
}}
Expand Down
7 changes: 6 additions & 1 deletion constants/status.ts
Original file line number Diff line number Diff line change
@@ -1,21 +1,25 @@
import Yapp from './yapp';

/* 리크루팅 상태: PRE(모집 오픈 전), ACTIVE(모집 중), POST(모집 마감) */
/* 리크루팅 상태: PRE(모집 오픈 전), ACTIVE(모집 중), POST(모집 마감), EXTRA(추가 모집) */
export enum RecruitStatus {
PRE = 'PRE',
ACTIVE = 'ACTIVE',
POST = 'POST',
EXTRA = 'EXTRA',
}

export const RECRUITING_START = '2026-04-17T00:00:00';
export const RECRUITING_DEADLINE = '2026-04-26T23:59:59';
export const RECRUITING_EXTRA_DEADLINE = '2026-04-28T23:59:59';

export const RECRUITING_STATUS = (): RecruitStatus => {
const now = new Date();
const start = new Date(RECRUITING_START);
const deadline = new Date(RECRUITING_DEADLINE);
const extraDeadline = new Date(RECRUITING_EXTRA_DEADLINE);

if (now < start) return RecruitStatus.PRE;
if (now > deadline && now <= extraDeadline) return RecruitStatus.EXTRA;
if (now > deadline) return RecruitStatus.POST;
return RecruitStatus.ACTIVE;
};
Expand All @@ -24,4 +28,5 @@ export const LINK_BY_STATUS: Record<RecruitStatus, string> = {
[RecruitStatus.PRE]: Yapp.PREVIOUS_GENERATION_RECRUIT_LINK,
[RecruitStatus.ACTIVE]: Yapp.YAPP_RECRUIT_ALL,
[RecruitStatus.POST]: Yapp.NEXT_GENERATION_RECRUIT_LINK,
[RecruitStatus.EXTRA]: Yapp.YAPP_RECRUIT_ALL,
};
1 change: 1 addition & 0 deletions constants/yapp.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ const Yapp = {

// 공고 링크
YAPP_RECRUIT_ALL: 'https://yapp-recruit.career.greetinghr.com/ko/apply',
YAPP_RECRUIT_EXTRA: 'https://yapp-recruit.career.greetinghr.com/ko/apply',
YAPP_RECRUIT_PROJECT_MANAGER:
'https://yapp-recruit.career.greetinghr.com/o/210447',
YAPP_RECRUIT_DESIGNER: 'https://yapp-recruit.career.greetinghr.com/o/210451',
Expand Down
8 changes: 8 additions & 0 deletions database/home.ts
Original file line number Diff line number Diff line change
Expand Up @@ -217,8 +217,16 @@ export const HOME_BANNER_POST = {
buttonName: `${Number(Yapp.YAPP_GENERATION) + 1}기 모집 알림 신청하기`,
};

export const HOME_BANNER_EXTRA = {
title: 'MOMENT OF DISCOVERY',
subTitle: `YAPP ${Number(Yapp.YAPP_GENERATION)}기 iOS 추가 모집중`,
date: '4.27(월) - 4.28(화)',
buttonName: `${Number(Yapp.YAPP_GENERATION)}기 iOS 지원하기`,
};

export const HOME_BANNER_BY_STATUS: Record<RecruitStatus, RecruitBannerInfo> = {
[RecruitStatus.PRE]: HOME_BANNER_PRE,
[RecruitStatus.ACTIVE]: HOME_BANNER_ACTIVE,
[RecruitStatus.POST]: HOME_BANNER_POST,
[RecruitStatus.EXTRA]: HOME_BANNER_EXTRA,
};
6 changes: 6 additions & 0 deletions database/recruit.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,11 @@ const RECRUIT_BANNER_ACTIVE: RecruitBannerInfo = {
buttonName: `${Yapp.YAPP_GENERATION}기 지원하기`,
};

const RECRUIT_BANNER_EXTRA: RecruitBannerInfo = {
title: '28기 iOS 추가 모집',
buttonName: `${Yapp.YAPP_GENERATION}기 iOS 지원하기`,
};

const RECRUIT_BANNER_POST: RecruitBannerInfo = {
title: '지금은 모집기간이 아닙니다',
buttonName: `${Number(Yapp.YAPP_GENERATION) + 1}기 모집 알림 신청하기`,
Expand All @@ -32,6 +37,7 @@ export const RECRUIT_BANNER_BY_STATUS: Record<
[RecruitStatus.PRE]: RECRUIT_BANNER_PRE,
[RecruitStatus.ACTIVE]: RECRUIT_BANNER_ACTIVE,
[RecruitStatus.POST]: RECRUIT_BANNER_POST,
[RecruitStatus.EXTRA]: RECRUIT_BANNER_EXTRA,
};

/** 세션일정 개요 */
Expand Down
Loading