Skip to content

Comments

[feature] 지원서 불합상태를 추가한다#705

Merged
suhyun113 merged 2 commits intodevelop-fefrom
feature/#704-add-declined-status-MOA-201
Aug 28, 2025
Merged

[feature] 지원서 불합상태를 추가한다#705
suhyun113 merged 2 commits intodevelop-fefrom
feature/#704-add-declined-status-MOA-201

Conversation

@suhyun113
Copy link
Collaborator

@suhyun113 suhyun113 commented Aug 26, 2025

#️⃣연관된 이슈

ex) #704

📝작업 내용

지원서 상세 페이지에 불합 상태를 추가했습니다.

image

지원 현황에 불합 상태를 추가했습니다.

image

중점적으로 리뷰받고 싶은 부분(선택)

리뷰어가 특별히 봐주었으면 하는 부분이 있다면 작성해주세요

ex) 메서드 XXX의 이름을 더 잘 짓고 싶은데 혹시 좋은 명칭이 있을까요?

논의하고 싶은 부분(선택)

논의하고 싶은 부분이 있다면 작성해주세요.

🫡 참고사항

Summary by CodeRabbit

  • 신규 기능

    • 관리자 지원자 상세 화면에 ‘불합격’ 상태를 추가해 선택 및 저장이 가능해졌습니다.
  • 스타일

    • 지원자 상태 배지에 ‘불합격’ 전용 배경색(#FFE8E8)을 적용해 상태 구분이 더 명확해졌습니다.
    • 기존 상태(서류검토, 면접예정, 합격) 배지 스타일은 그대로 유지됩니다.
  • 기타

    • 메모 편집 및 업데이트 흐름 등 기존 동작은 변경되지 않습니다.

@suhyun113 suhyun113 self-assigned this Aug 26, 2025
@suhyun113 suhyun113 added ✨ Feature 기능 개발 💻 FE Frontend labels Aug 26, 2025
@vercel
Copy link

vercel bot commented Aug 26, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Preview Comments Updated (UTC)
moadong Ready Ready Preview Comment Aug 26, 2025 10:18am

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Aug 26, 2025

Warning

.coderabbit.yaml has a parsing error

The CodeRabbit configuration file in this repository has a parsing error and default settings were used instead. Please fix the error(s) in the configuration file. You can initialize chat with CodeRabbit to get help with the configuration file.

💥 Parsing errors (1)
Validation error: Invalid regex pattern for base branch. Received: "**" at "reviews.auto_review.base_branches[0]"
⚙️ Configuration instructions
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Walkthrough

관리자 상세/목록 화면에서 지원서 상태 목록에 DECLINED(불합)을 추가하고, 상태별 색상 매핑에 불합 색상(#FFE8E8)을 반영했습니다. 기능 흐름 변경 없이 선택 옵션과 배지 배경색만 확장되었습니다.

Changes

Cohort / File(s) Summary
Applicant status DECLINED support
frontend/src/pages/AdminPage/tabs/ApplicantsTab/ApplicantDetailPage/ApplicantDetailPage.tsx, frontend/src/pages/AdminPage/tabs/ApplicantsTab/ApplicantsTab.styles.ts
상태 옵션에 ApplicationStatus.DECLINED 추가 및 getStatusColor에 '#FFE8E8' 매핑. 목록 배지 스타일에서 상태 '불합' 배경색 '#FFE8E8' 추가. 기타 로직 변경 없음.

Sequence Diagram(s)

sequenceDiagram
  autonumber
  actor Admin as Admin
  participant Detail as ApplicantDetailPage
  participant Styles as ApplicantsTab.styles (Badge)
  Admin->>Detail: 상태 선택(불합/DECLINED)
  Note right of Detail: AVAILABLE_STATUSES에 DECLINED 포함
  Detail-->>Detail: 기존 검증/업데이트 흐름 사용
  Detail->>Styles: 상태에 따른 배지 색상 조회
  Styles-->>Detail: '#FFE8E8' 반환(불합)
  Detail-->>Admin: UI에 불합 상태와 배경색 표시
Loading

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Assessment against linked issues

Objective Addressed Explanation
지원서 불합상태를 추가한다 (MOA-201)

Assessment against linked issues: Out-of-scope changes

(해당 없음)

Possibly related issues

Possibly related PRs

Suggested reviewers

  • lepitaaar
  • seongwon030
  • oesnuj
  • Zepelown

Tip

🔌 Remote MCP (Model Context Protocol) integration is now available!

Pro plan users can now connect to remote MCP servers from the Integrations page. Connect with popular remote MCPs such as Notion and Linear to add more context to your reviews and chats.

✨ Finishing Touches
  • 📝 Generate Docstrings
🧪 Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch feature/#704-add-declined-status-MOA-201

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

CodeRabbit Commands (Invoked using PR/Issue comments)

Type @coderabbitai help to get the list of available commands.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

Status, Documentation and Community

  • Visit our Status Page to check the current availability of CodeRabbit.
  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

🧹 Nitpick comments (3)
frontend/src/pages/AdminPage/tabs/ApplicantsTab/ApplicantDetailPage/ApplicantDetailPage.tsx (1)

25-35: 색상 상수의 단일 출처화 제안 — 파일 간 색상 값이 불일치합니다.

현재 이 파일의 색상과 목록 화면 배지(ApplicantsTab.styles.ts)의 색상이 일부 다릅니다.

  • 서류검토: 이 파일 '#E5F6FF' vs 목록 '#E6F4FB'
  • 면접예정: 이 파일 '#E9FFF1' vs 목록 '#E6FBF0'
  • 합격: 이 파일 'var(--f5, #F5F5F5)' vs 목록 '#F5F5F5'

시각적 일관성을 위해 상태→색상 매핑을 상수로 모아 두 컴포넌트가 동일 소스를 참조하도록 권장합니다. 또한 본 레포 가이드라인(frontend/**/*.{ts,tsx})의 “매직 넘버 상수화”와 “복잡한 분기 단순화”에도 부합합니다.

아래처럼 매핑 상수로 단순화할 수 있습니다.

+// 상태별 배경색 상수 (공유 상수 파일로 분리하는 것도 권장: e.g. src/constants/applicationStatusColors.ts)
+const STATUS_BG: Record<ApplicationStatus, string> = {
+  [ApplicationStatus.ACCEPTED]: 'var(--f5, #F5F5F5)',
+  [ApplicationStatus.SUBMITTED]: '#E6F4FB',           // 목록 배지와 통일
+  [ApplicationStatus.INTERVIEW_SCHEDULED]: '#E6FBF0',// 목록 배지와 통일
+  [ApplicationStatus.DECLINED]: '#FFE8E8',
+};
+
-const getStatusColor = (status: ApplicationStatus | undefined): string => {
-  switch (status) {
-    case ApplicationStatus.ACCEPTED:
-      return 'var(--f5, #F5F5F5)';
-    case ApplicationStatus.SUBMITTED:
-      return '#E5F6FF';
-    case ApplicationStatus.INTERVIEW_SCHEDULED:
-      return '#E9FFF1';
-    case ApplicationStatus.DECLINED:
-      return '#FFE8E8';
-    default:
-      return 'var(--f5, #F5F5F5)';
-  }
-};
+const getStatusColor = (status: ApplicationStatus | undefined): string =>
+  STATUS_BG[status ?? ApplicationStatus.ACCEPTED];

추가로, 이 매핑을 별도 공용 상수(예: src/constants/applicationStatusColors.ts)로 분리한 뒤 목록 배지에서도 동일 상수를 사용하면 불일치가 원천 차단됩니다.

frontend/src/pages/AdminPage/tabs/ApplicantsTab/ApplicantsTab.styles.ts (2)

312-323: 중첩 삼항 제거 및 상수화로 가독성·유지보수성 개선을 권장합니다.

상태 문자열 비교가 늘어날수록 삼항 체인이 길어져 오타/불일치 리스크가 커집니다. 상태→색상 매핑 상수를 사용하면 일관성과 변경 용이성이 좋아집니다. 레포 가이드라인(매직 넘버 상수화, 복잡한 분기 단순화)에도 부합합니다.

아래처럼 정리할 수 있습니다.

-  background: ${({ status }) =>
-    status === '서류검토'
-      ? '#E6F4FB'
-      : status === '면접예정'
-        ? '#E6FBF0'
-        : status === '합격'
-          ? '#F5F5F5'
-          : status === '불합'
-            ? '#FFE8E8'
-            : '#eee'};
+  background: ${({ status }) => BADGE_BG_BY_LABEL[status] ?? '#eee'};

파일 상단(또는 공용 상수 파일)에는 다음 상수를 두세요.

// 상단에 추가 (또는 src/constants/applicationStatusColors.ts로 이동 후 import)
const BADGE_BG_BY_LABEL: Record<string, string> = {
  '서류검토': '#E6F4FB',
  '면접예정': '#E6FBF0',
  '합격': '#F5F5F5',
  '불합': '#FFE8E8',
} as const;

가능하면 상세 화면의 getStatusColor도 같은 소스(공용 상수)를 사용하여 파일 간 색상 불일치를 제거해 주세요.


306-323: ‘불합’ 레이블 일관성 확인 및 주석 정리

src/utils/mapStatusToGroup.tscase ApplicationStatus.DECLINED는 레이블로 '불합'을 반환하고,
ApplicantsTab.styles.ts에서도 status === '불합' 분기로 색상을 지정하므로 기능상 불일치는 없습니다.
– 다만 ApplicantDetailPage.tsx 22행의 주석(// 불합격)이 실제 렌더링되는 레이블(불합)과 다르므로, 읽는 이의 혼동을 줄이려면
– 주석을 // 불합으로 수정하거나
– 더 나아가 styled component의 분기를 ApplicationStatus enum 값 기반으로 전환하여 레이블과 색상 분기를 완전히 분리하는 방식을 고려해 보세요.

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

💡 Knowledge Base configuration:

  • MCP integration is disabled by default for public repositories
  • Jira integration is disabled by default for public repositories
  • Linear integration is disabled by default for public repositories

You can enable these sources in your CodeRabbit configuration.

📥 Commits

Reviewing files that changed from the base of the PR and between a58ca36 and 380ff84.

📒 Files selected for processing (2)
  • frontend/src/pages/AdminPage/tabs/ApplicantsTab/ApplicantDetailPage/ApplicantDetailPage.tsx (2 hunks)
  • frontend/src/pages/AdminPage/tabs/ApplicantsTab/ApplicantsTab.styles.ts (1 hunks)
🧰 Additional context used
📓 Path-based instructions (2)
frontend/**/*.{ts,tsx}

📄 CodeRabbit inference engine (frontend/.cursorrules)

frontend/**/*.{ts,tsx}: Replace magic numbers with named constants for clarity.
Replace complex or nested ternary operators with if/else statements or IIFEs for readability.
Assign complex boolean conditions to named variables.
Use consistent return types for similar functions and hooks.
Avoid hidden side effects; functions should only perform actions implied by their signature (Single Responsibility Principle).
Use unique, descriptive names for custom wrappers and functions to avoid ambiguity.
Define constants near related logic or ensure names link them clearly.

Files:

  • frontend/src/pages/AdminPage/tabs/ApplicantsTab/ApplicantsTab.styles.ts
  • frontend/src/pages/AdminPage/tabs/ApplicantsTab/ApplicantDetailPage/ApplicantDetailPage.tsx
frontend/**/*.tsx

📄 CodeRabbit inference engine (frontend/.cursorrules)

frontend/**/*.tsx: Abstract complex logic/interactions into dedicated components or higher-order components (HOCs).
Separate significantly different conditional UI/logic into distinct components.
Colocate simple, localized logic or use inline definitions to reduce context switching.
Choose field-level or form-level cohesion based on form requirements.
Break down broad state management into smaller, focused hooks or contexts.
Use component composition instead of props drilling.

Files:

  • frontend/src/pages/AdminPage/tabs/ApplicantsTab/ApplicantDetailPage/ApplicantDetailPage.tsx
🔇 Additional comments (2)
frontend/src/pages/AdminPage/tabs/ApplicantsTab/ApplicantDetailPage/ApplicantDetailPage.tsx (1)

18-23: [검증 진행 중: useUpdateApplicant 파일 및 라벨 일관성 확인]

frontend/src/pages/AdminPage/tabs/ApplicantsTab/ApplicantsTab.styles.ts (1)

319-321: 불합 배경색 추가는 방향성 좋습니다.

목록 배지에 '#FFE8E8'을 적용해 상세 화면의 DECLINED 색상과 톤을 맞춘 점 좋습니다.

Copy link
Contributor

@lepitaaar lepitaaar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

처음인데 수고하셨습니다!! 더많은 기여하시길 바랍니다. 😆😆😆

Copy link
Member

@seongwon030 seongwon030 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

고생하셨습니다 ㅎㅎ

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants