Skip to content

refactor: 이벤트 카드/상세 리팩토링#173

Merged
xaexunxang merged 4 commits intodevelopfrom
refact/#171/event-refactoring
Jun 10, 2025
Merged

refactor: 이벤트 카드/상세 리팩토링#173
xaexunxang merged 4 commits intodevelopfrom
refact/#171/event-refactoring

Conversation

@xaexunxang
Copy link
Copy Markdown
Contributor

@xaexunxang xaexunxang commented Jun 10, 2025

이벤트 카드 제목 말줄임표 처리 및 이미지 크기 오류 해결

default.mov

이벤트 카드 주소 말줄임표 처리

이벤트주소말줄임표

이벤트 상세 미로그인 시 alert 및 메시지 수정

로그인이필요한서비스1 로그인이필요한서비스2

이벤트 상세 링크 첨부 URL을 제목에 하이퍼링크로 수정

title을 url하이퍼링크로 만들기

Summary by CodeRabbit

  • 버그 수정

    • 이벤트 카드의 위치 정보가 온라인 유형에서 실제 주소로 변경되어 보다 정확한 위치가 표시됩니다.
    • 이벤트 카드와 위치 텍스트가 한 줄로 잘려 보이도록 스타일이 개선되었습니다.
  • 기능 개선

    • 이벤트 상세 페이지에서 참고 링크의 제목이 직접적으로 표시되어 가독성이 향상되었습니다.
    • 티켓 정보에서 비로그인 사용자가 주문 시 로그인 필요 알림이 표시되고, 티켓 정보 로딩 실패 시에도 로그인 필요 메시지가 안내됩니다.
  • 환경 설정

    • API 기본 포트가 8080에서 8081로 변경되었습니다.

@xaexunxang xaexunxang requested review from Yejiin21 and hyeeuncho June 10, 2025 11:45
@xaexunxang xaexunxang self-assigned this Jun 10, 2025
@xaexunxang xaexunxang added the 🪄 Refactoring 코드 리팩토링 label Jun 10, 2025
@xaexunxang xaexunxang linked an issue Jun 10, 2025 that may be closed by this pull request
@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Jun 10, 2025

Walkthrough

이 변경사항은 이벤트 카드 및 관련 UI의 스타일과 데이터 표시 방식을 수정하고, 티켓 구매 시 로그인 여부를 확인하는 로직을 추가합니다. 또한, 이벤트 상세 페이지의 링크 표시 방식을 개선하고, Vite 설정의 기본 API 포트가 8081로 변경되었습니다.

Changes

파일/경로 변경 요약
src/features/home/ui/EventSliderSection.tsx, src/shared/ui/EventCard.tsx 이벤트 카드의 스타일 변경, 위치 정보 데이터 소스 변경, 텍스트 줄임 처리 방식 수정
src/pages/event/ui/EventDetailsPage.tsx 이벤트 상세 페이지에서 링크 제목을 URL 대신 앵커 텍스트로 표시
src/widgets/event/ui/TicketInfo.tsx 티켓 주문 시 로그인 확인 추가, 미로그인 시 경고 및 에러 메시지 변경
vite.config.ts API 기본 포트 8080 → 8081로 변경

Sequence Diagram(s)

sequenceDiagram
    participant User
    participant TicketInfo
    participant AuthStore

    User->>TicketInfo: "티켓 주문" 버튼 클릭
    TicketInfo->>AuthStore: isLoggedIn 확인
    alt 로그인 안됨
        TicketInfo-->>User: "로그인이 필요한 서비스입니다." 알림 표시
    else 로그인됨
        TicketInfo->>TicketInfo: 주문 처리 로직 진행
    end
Loading

Poem

토끼가 말해요, 변화가 왔죠!
이벤트 카드가 더 깔끔해졌고,
로그인 안 하면 티켓은 못 사요.
링크엔 제목이 반짝이고,
API 포트도 살짝 바뀌었죠!
🐰✨
변화의 바람, 오늘도 고고!


📜 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 6a47e5c and 56079b5.

📒 Files selected for processing (5)
  • src/features/home/ui/EventSliderSection.tsx (2 hunks)
  • src/pages/event/ui/EventDetailsPage.tsx (1 hunks)
  • src/shared/ui/EventCard.tsx (2 hunks)
  • src/widgets/event/ui/TicketInfo.tsx (4 hunks)
  • vite.config.ts (1 hunks)
🧰 Additional context used
🧬 Code Graph Analysis (1)
src/widgets/event/ui/TicketInfo.tsx (3)
src/features/ticket/hooks/useTicketHook.ts (1)
  • useTickets (7-13)
src/features/ticket/hooks/useOrderHook.ts (1)
  • useOrderTicket (36-43)
src/app/provider/authStore.ts (1)
  • useAuthStore (17-36)
⏰ Context from checks skipped due to timeout of 90000ms (1)
  • GitHub Check: storybook
🔇 Additional comments (10)
vite.config.ts (1)

11-11: API 기본 포트 변경이 올바르게 적용되었습니다.

환경 변수가 설정되지 않은 경우 8081 포트로 대체되도록 변경이 잘 적용되었습니다.

src/pages/event/ui/EventDetailsPage.tsx (1)

151-151: 링크 표시 방식 개선이 사용자 경험을 향상시킵니다.

URL 대신 링크 제목을 표시하도록 변경하여 사용자가 링크의 내용을 더 쉽게 파악할 수 있게 되었습니다.

src/features/home/ui/EventSliderSection.tsx (2)

57-57: 최소 너비 설정으로 레이아웃 일관성이 개선되었습니다.

min-w-[200px] 추가로 이벤트 카드의 최소 너비를 보장하여 슬라이더 레이아웃이 더욱 안정적이 되었습니다.


66-66: 위치 정보 데이터 소스 변경이 적절합니다.

event.onlineType에서 event.address로 변경하여 더 정확한 위치 정보를 표시하게 되었습니다.

src/shared/ui/EventCard.tsx (2)

62-62: 제목 텍스트 truncate 적용이 일관된 레이아웃을 제공합니다.

line-clamp-2에서 max-w-[130px] truncate로 변경하여 긴 제목이 한 줄로 표시되고 말줄임표가 적용되어 카드 레이아웃이 더욱 일관되었습니다.


79-79: 위치 텍스트 truncate 적용으로 오버플로우 처리가 개선되었습니다.

line-clamp-2에서 w-full truncate로 변경하여 긴 주소가 한 줄로 표시되고 말줄임표가 적용되어 UI가 더욱 깔끔해졌습니다.

src/widgets/event/ui/TicketInfo.tsx (4)

8-8: 인증 상태 관리를 위한 store 가져오기가 적절합니다.

useAuthStore 가져오기로 티켓 주문 전 사용자 로그인 상태를 확인할 수 있게 되었습니다.


16-16: 로그인 상태 추출이 올바르게 구현되었습니다.

인증 store에서 isLoggedIn 상태를 추출하여 컴포넌트에서 사용할 수 있도록 설정되었습니다.


61-64: 티켓 주문 전 인증 확인 로직이 보안을 강화합니다.

티켓 주문 함수 시작 부분에서 로그인 상태를 확인하고, 비로그인 사용자에게는 명확한 안내 메시지를 제공하여 사용자 경험과 보안이 모두 개선되었습니다.


80-80: 에러 메시지가 사용자 안내를 명확하게 제공합니다.

티켓 정보 로딩 실패 시 "로그인이 필요한 서비스입니다."라는 메시지로 변경하여 사용자가 취해야 할 행동을 명확하게 안내합니다.

✨ Finishing Touches
  • 📝 Generate Docstrings

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.
    • Explain this complex logic.
    • 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 explain this code block.
    • @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 explain its main purpose.
    • @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.

Support

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

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.

@github-actions
Copy link
Copy Markdown

@xaexunxang xaexunxang merged commit 61d3acb into develop Jun 10, 2025
2 checks passed
@xaexunxang xaexunxang deleted the refact/#171/event-refactoring branch June 10, 2025 13:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

🪄 Refactoring 코드 리팩토링

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[refactor] 이벤트 카드/상세 리팩토링

2 participants