From 6daab27ec036303663de22ff712fec42befd5dc8 Mon Sep 17 00:00:00 2001 From: toothlessdev Date: Tue, 9 Sep 2025 19:20:22 +0900 Subject: [PATCH] =?UTF-8?q?feat:=20=20=EC=88=9C=EC=9C=84=20=EB=A1=9C?= =?UTF-8?q?=EC=A7=81=20=EA=B0=9C=EC=84=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/widgets/competition/InfoSection.tsx | 8 ++++---- .../widgets/competition/RankTableSection.tsx | 20 +++++++++++++++---- 2 files changed, 20 insertions(+), 8 deletions(-) diff --git a/mosu-app/src/widgets/competition/InfoSection.tsx b/mosu-app/src/widgets/competition/InfoSection.tsx index 9f655aba..99502f9b 100644 --- a/mosu-app/src/widgets/competition/InfoSection.tsx +++ b/mosu-app/src/widgets/competition/InfoSection.tsx @@ -13,7 +13,7 @@ export const InfoSection = () => {
-

우리 학교에서 신청자가 제일 많으면,

+

우리 학교에서 신청수가 제일 많으면,

우리 학교 전원 전액 환급

@@ -38,10 +38,10 @@ export const InfoSection = () => { />
diff --git a/mosu-app/src/widgets/competition/RankTableSection.tsx b/mosu-app/src/widgets/competition/RankTableSection.tsx index 75cbf957..3b96d72b 100644 --- a/mosu-app/src/widgets/competition/RankTableSection.tsx +++ b/mosu-app/src/widgets/competition/RankTableSection.tsx @@ -34,16 +34,28 @@ export const RankTableSection = ({ topRatedSchools }: RankTableSectionProps) => ); } - const prevSchoolCount = topRatedSchools[index - 1].paidApplicationCount; - const gap = prevSchoolCount - school.paidApplicationCount; - const prevRank = index; + let targetRank: number; + let targetSchoolCount: number; + + if (rank >= 2 && rank <= 5) { + targetRank = 1; + targetSchoolCount = topRatedSchools[0].paidApplicationCount; + } else if (rank >= 6 && rank <= 20) { + targetRank = 5; + targetSchoolCount = topRatedSchools[4]?.paidApplicationCount || 0; + } else { + targetRank = 20; + targetSchoolCount = topRatedSchools[19]?.paidApplicationCount || 0; + } + + const gap = targetSchoolCount - school.paidApplicationCount; return ( );