Skip to content

Style#248 responsive job posting#251

Merged
hye410 merged 4 commits intodevfrom
Style#248-responsive-job-posting
Apr 30, 2025
Merged

Style#248 responsive job posting#251
hye410 merged 4 commits intodevfrom
Style#248-responsive-job-posting

Conversation

@hye410
Copy link
Copy Markdown
Collaborator

@hye410 hye410 commented Apr 29, 2025

💡 관련이슈

#248

🍀 작업 요약

  • 채용 공고 페이지 tablet, mobile 반응형 적용하였습니다.
  • 적절하지 않은 시멘틱 태그 요소가 다소 있어 살짝 리팩토링 하였습니다.

💬 리뷰 요구 사항

  • 반응형이 잘 작동하는지 확인 부탁드립니다.

💛 미리보기

2025-04-29.11.27.21.mov

✔️ 이슈 닫기

Closes #248
Ref #이슈번호 // 해당 이슈에 대한 작업이 완전히 끝나지 않은 경우

Summary by CodeRabbit

  • 신규 기능

    • 외부 사이트(사람인)로 이동하는 "데이터 출처: 취업 사람인" 버튼이 추가되었습니다. 이 버튼은 데스크톱과 모바일에서 각각 다르게 표시됩니다.
  • 스타일

    • 버튼 포커스 시 테두리가 사라지도록 스타일이 개선되었습니다.
    • 여러 컴포넌트의 레이아웃 및 타이포그래피가 반응형 및 접근성 측면에서 개선되었습니다.
  • 리팩터

    • 구직 카드와 목록 등에서 HTML 구조가 의미론적으로 개선되어 접근성이 향상되었습니다.
    • 일부 컴포넌트의 조건부 렌더링 및 코드 구조가 단순화되었습니다.

@hye410 hye410 added 🎨 Styles 마크업 & 스타일링 💎다혜 labels Apr 29, 2025
@hye410 hye410 self-assigned this Apr 29, 2025
@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Apr 29, 2025

Walkthrough

이 변경사항은 채용 공고 페이지와 관련 컴포넌트의 시맨틱 구조, 반응형 스타일링, 접근성, 버튼 컴포넌트 분리 등을 중심으로 이루어졌습니다. 주요 변경점으로는 JobPage와 JobPostingCard의 시맨틱 태그 개선, SaraminButton 컴포넌트의 신설 및 조건부 렌더링, 각종 타이포그래피 및 레이아웃 클래스의 반응형 적용, 불필요한 import 제거, 전역 버튼 스타일의 포커스 상태 개선 등이 포함됩니다. 컴포넌트의 공개 인터페이스는 변경되지 않았으며, 주로 내부 구조와 스타일링이 개선되었습니다.

Changes

파일/경로 요약 변경 요약
src/app/(with-nav)/(with-header)/job/page.tsx 최상위 컨테이너를 <div>에서 <article>로 변경, 헤더 구조 및 타이포그래피 반응형 스타일 적용, SaraminButton 컴포넌트 도입 및 조건부 렌더링, 기존 LinkButton 제거
src/app/(with-nav)/(with-header)/layout.tsx <main>의 클래스 순서 변경(기능 변화 없음)
src/features/job/job-posting-card.tsx 시맨틱 구조 개선: <dl>, <dt>, <dd>로 대체, 접근성 레이블 추가, 카드 레이아웃 반응형 스타일 적용, 불필요한 import 제거
src/features/job/job-posting-select-box.tsx <select>를 오른쪽 정렬하는 div로 래핑, 스타일링 목적의 구조 변경
src/features/job/job-postings-box.tsx 데이터 상태별 조건부 렌더링 간소화, SaraminButton 비데스크탑 조건부 렌더링, 그리드 레이아웃 반응형 적용, import 정리
src/features/job/saramin-button.tsx SaraminButton 컴포넌트 신설: 외부 링크 버튼 렌더링, 새 탭에서 열기
src/app/global-style.css .button-hover-focus 클래스에 focus 시 border 제거 스타일 추가

Sequence Diagram(s)

sequenceDiagram
    participant User
    participant JobPage
    participant JobPostingsBox
    participant SaraminButton

    User->>JobPage: 페이지 접속
    JobPage->>JobPostingsBox: 채용 공고 목록 렌더링
    JobPostingsBox-->>User: 상태별(로딩/에러/목록) UI 표시
    alt 데스크탑
        JobPage->>SaraminButton: SaraminButton 렌더링
    else 모바일/태블릿
        JobPostingsBox->>SaraminButton: SaraminButton 렌더링
    end
    User->>SaraminButton: "데이터 출처: 취업 사람인" 클릭
    SaraminButton-->>User: 새 탭에서 사라민 사이트 오픈
Loading

Assessment against linked issues

Objective Addressed Explanation
채용 공고 페이지 tablet, mobile 반응형 적용 (#248)

Possibly related PRs

Suggested reviewers

  • choichangyeon
  • parkminjo

Poem

🐰
반응형으로 변신한 채용의 숲,
시맨틱 태그로 토끼도 춤을 춥!
Saramin 버튼이 반짝반짝,
모바일·데스크탑 모두 반갑!
스타일도 구조도 한층 더,
개발자 토끼는 오늘도 행복해요!
🥕✨


📜 Recent review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 88335fc and c544921.

📒 Files selected for processing (7)
  • src/app/(with-nav)/(with-header)/job/page.tsx (1 hunks)
  • src/app/(with-nav)/(with-header)/layout.tsx (1 hunks)
  • src/app/global-style.css (1 hunks)
  • src/features/job/job-posting-card.tsx (1 hunks)
  • src/features/job/job-posting-select-box.tsx (1 hunks)
  • src/features/job/job-postings-box.tsx (2 hunks)
  • src/features/job/saramin-button.tsx (1 hunks)
✅ Files skipped from review due to trivial changes (1)
  • src/app/global-style.css
🚧 Files skipped from review as they are similar to previous changes (6)
  • src/features/job/job-posting-select-box.tsx
  • src/features/job/saramin-button.tsx
  • src/app/(with-nav)/(with-header)/job/page.tsx
  • src/features/job/job-postings-box.tsx
  • src/app/(with-nav)/(with-header)/layout.tsx
  • src/features/job/job-posting-card.tsx
⏰ Context from checks skipped due to timeout of 90000ms (1)
  • GitHub Check: build
✨ Finishing Touches
  • 📝 Generate Docstrings

🪧 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.
    • Generate unit testing code for this file.
    • 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. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • 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 src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

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.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • 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

Documentation and Community

  • 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
Copy Markdown

@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 (2)
src/features/job/saramin-button.tsx (1)

1-13: 외부 링크 보안 및 접근성 개선이 필요합니다.

외부 링크를 위한 컴포넌트를 생성한 것은 좋은 접근입니다. 그러나 target='_blank'를 사용할 때는 보안 및 접근성을 위해 다음과 같은 개선이 필요합니다:

'use client';
import LinkButton from '@/components/ui/link-button';
const SARAMIN_URL = 'http://www.saramin.co.kr';
const SaraminButton = () => {
  return (
-   <LinkButton href={SARAMIN_URL} target='_blank'>
+   <LinkButton 
+     href={SARAMIN_URL} 
+     target='_blank' 
+     rel="noopener noreferrer" 
+     aria-label="사람인 취업 정보 사이트로 이동합니다">
      데이터 출처: 취업 사람인
    </LinkButton>
  );
};

export default SaraminButton;
src/features/job/job-posting-select-box.tsx (1)

20-32: 정렬 개선은 좋으나 모바일 고려가 필요합니다.

select 요소를 div로 감싸고 우측 정렬을 적용한 것은 좋은 개선입니다. 하지만 모바일 환경에서의 사용성을 더 개선할 수 있습니다.

-    <div className='text-right'>
+    <div className='text-right'>
      <select
        value={sortOption}
        onChange={changeNewParams}
-       className='mb-4 rounded-md border px-2 py-1 text-sm shadow-sm'
+       className='mb-4 rounded-md border px-2 py-1 text-sm shadow-sm mobile:w-full tablet:py-2'
      >
        {JOB_SORT_OPTIONS.map(({ name, value }) => (
          <option key={value} value={value}>
            {name}
          </option>
        ))}
      </select>
    </div>
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 28d62b8 and c4b784f.

📒 Files selected for processing (7)
  • src/app/(with-nav)/(with-header)/job/page.tsx (1 hunks)
  • src/app/(with-nav)/(with-header)/layout.tsx (1 hunks)
  • src/features/job/job-posting-card.tsx (1 hunks)
  • src/features/job/job-posting-select-box.tsx (1 hunks)
  • src/features/job/job-postings-box.tsx (2 hunks)
  • src/features/job/saramin-button.tsx (1 hunks)
  • tailwind.config.ts (1 hunks)
🧰 Additional context used
🧬 Code Graph Analysis (2)
src/app/(with-nav)/(with-header)/job/page.tsx (1)
src/utils/auth-option.ts (2)
  • session (65-73)
  • authOptions (16-83)
src/features/job/job-postings-box.tsx (1)
src/features/job/job-posting-block-component.tsx (1)
  • JobPostingBlockComponent (17-56)
⏰ Context from checks skipped due to timeout of 90000ms (1)
  • GitHub Check: build
🔇 Additional comments (16)
tailwind.config.ts (1)

17-21: 반응형 디자인을 위한 좋은 구성 변경입니다.

화면 너비 정의를 간소화하고 최대 너비를 분리하여 구성한 것은 반응형 디자인 구현에 효과적인 접근법입니다.

src/app/(with-nav)/(with-header)/layout.tsx (1)

7-7: 적절한 최대 너비 클래스 적용입니다.

max-w-screen-desktop에서 max-w-max로 변경한 것은 Tailwind 구성 업데이트와 일관성을 유지하면서 더 유연한 반응형 레이아웃을 구현할 수 있게 해줍니다.

src/app/(with-nav)/(with-header)/job/page.tsx (5)

3-3: SaraminButton 컴포넌트 분리가 잘 되었습니다.

기존에 사용되던 링크 버튼을 별도의 컴포넌트로 분리하여 재사용성을 높였습니다.


11-11: 시맨틱 HTML 요소 사용이 개선되었습니다.

<div> 대신 <article> 태그를 사용하여 페이지의 의미론적 구조가 명확해졌습니다. 이는 웹 접근성과 SEO에 도움이 됩니다.


14-17: 반응형 타이포그래피 구현이 잘 되었습니다.

기존 사이즈 속성 대신 tailwind 클래스를 사용하여 모바일, 태블릿, 데스크톱에 맞게 텍스트 크기와 스타일이 조정되도록 개선했습니다.


21-26: 부제목에 대한 반응형 스타일링이 적절합니다.

모바일 화면에서는 색상이 변경되고 텍스트 크기가 조정되어 가독성이 향상되었습니다.


31-33: 화면 크기에 따른 조건부 렌더링이 잘 구현되었습니다.

데스크톱 화면에서만 Saramin 버튼이 보이도록 설정하여 모바일/태블릿 화면에서의 레이아웃이 개선되었습니다. 이는 job-postings-box.tsx에서 모바일용 버튼을 별도로 표시하는 방식과 상호 보완적입니다.

src/features/job/job-postings-box.tsx (5)

4-5: 필요한 임포트 추가 및 정리가 잘 되었습니다.

Typography, PATH, SaraminButton 등 필요한 컴포넌트와 상수를 추가하고, 타입과 유틸리티 함수도 적절히 구조화했습니다.

Also applies to: 12-17


61-68: 로딩 상태 UI가 개선되었습니다.

로딩 중 상태를 명확하게 표시하고, 사용자에게 적절한 피드백을 제공합니다. 이전 renderContent 함수 대신 직접 리턴으로 간결하게 처리했습니다.


70-80: 오류 및 데이터 없음 상태 처리가 명확해졌습니다.

다양한 상태(오류, 데이터 없음, 북마크 없음)에 대한 처리가 명확하게 분리되어 코드 가독성이 향상되었습니다.


83-89: 반응형 그리드 레이아웃이 적절히 구현되었습니다.

grid-cols-1, lg:grid-cols-3, desktop:grid-cols-3 클래스를 통해 화면 크기에 따라 카드 배치가 달라지도록 구현했습니다. 모바일에서는 한 열, 큰 화면에서는 세 열로 표시됩니다.


90-92: 모바일 화면용 SaraminButton 배치가 적절합니다.

데스크톱 외 화면에서만 보이도록 설정하여 page.tsx의 데스크톱 전용 버튼과 상호 보완적으로 작동합니다.

src/features/job/job-posting-card.tsx (4)

34-34: 카드 레이아웃의 반응형 개선이 훌륭합니다.

고정 너비(w-[380px])에서 유연한 너비(w-full min-w-0 flex-shrink-1)로 변경하여 다양한, 화면 크기에 맞게 자동으로 조정되도록 개선했습니다.


35-43: 시맨틱 HTML과 접근성이 크게 향상되었습니다.

<div> 대신 <dl>, <dt>, <dd> 요소를 사용하여 콘텐츠의 의미론적 구조를 명확히 했습니다. 스크린 리더용 sr-only 클래스를 추가하여 시각적으로는 보이지 않지만 접근성은 향상되었습니다.


44-61: 모든 콘텐츠 요소에 접근성 레이블이 적절히 추가되었습니다.

공고 제목, 채용 분야, 채용 조건 등 모든 항목에 스크린 리더용 레이블을 추가하여 접근성이 크게 향상되었습니다.


62-89: 하단 섹션의 구조가 시맨틱하게 개선되었습니다.

버튼과 남은 일자 표시 부분도 접근성을 고려한 구조로 변경되었습니다. 조건부 렌더링에도 접근성 요소가 일관되게 적용되었습니다.

Copy link
Copy Markdown
Collaborator

@choichangyeon choichangyeon left a comment

Choose a reason for hiding this comment

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

스크린샷 2025-04-30 오후 12 30 34

  • 해당 사이즈에서 겹쳐지는데 줄바꿈이 일어나지 않습니다!
    이 부분 확인해주세요!

스크린샷 2025-04-30 오후 12 31 10

  • 모바일에서 상단 부분 내용 글씨를 조금 크기를 키워주면 좋을것 같습니다!

Copy link
Copy Markdown
Collaborator

@ImJaeOne ImJaeOne left a comment

Choose a reason for hiding this comment

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

시멘틱 태그 적용....bb 고생하셨습니다!

Comment thread src/features/job/job-posting-card.tsx
@hye410 hye410 requested a review from choichangyeon April 30, 2025 07:46
Copy link
Copy Markdown
Collaborator

@parkminjo parkminjo left a comment

Choose a reason for hiding this comment

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

고생 많으셨습니다!

@hye410 hye410 force-pushed the Style#248-responsive-job-posting branch from 88335fc to c544921 Compare April 30, 2025 12:32
Copy link
Copy Markdown
Collaborator

@choichangyeon choichangyeon left a comment

Choose a reason for hiding this comment

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

수고하셨습니다!

@hye410 hye410 merged commit 3a60417 into dev Apr 30, 2025
2 checks passed
@hye410 hye410 deleted the Style#248-responsive-job-posting branch April 30, 2025 12:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

🎨 Styles 마크업 & 스타일링 💎다혜

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Style] 채용 공고 페이지 반응형 적용

4 participants