Skip to content

버그들 수정#42

Merged
roode1017 merged 7 commits intomainfrom
dev
Aug 21, 2025
Merged

버그들 수정#42
roode1017 merged 7 commits intomainfrom
dev

Conversation

@roode1017
Copy link
Collaborator

@roode1017 roode1017 commented Aug 21, 2025

Summary by CodeRabbit

  • New Features

    • Real-time chatrooms with dynamic room URLs, live messaging, read receipts, infinite scroll history, and in-chat search.
    • Left panel with Participants and Formation tabs, including rankings and formation view.
    • Connection status indicator and recent alerts.
    • “Enter Chatroom” button on the main page with login-aware navigation.
  • UI

    • Complete Chatroom redesign: two-panel layout, animations, responsive behavior, custom scrollbars, and enhanced search/alerts styling.
  • Chores

    • Environment-based API endpoints enabled during builds.
    • Added dependencies for dates, debouncing, intersection/virtualization, and UUIDs.
    • Build config updated for broader runtime compatibility.

jaehyeok-code and others added 7 commits August 21, 2025 15:47
- Chatroom.jsx 파일의 채팅방이 제대로 구현되어 있는가?
[Feat] ChatRoom 페이지 채팅방을 구현 및 환경세팅
- Chatroom.jsx 파일의 채팅방이 제대로 구현되어 있는가?
@roode1017 roode1017 self-assigned this Aug 21, 2025
@roode1017 roode1017 added the bug Something isn't working label Aug 21, 2025
@roode1017 roode1017 merged commit d966542 into main Aug 21, 2025
1 check was pending
@coderabbitai
Copy link

coderabbitai bot commented Aug 21, 2025

Caution

Review failed

The pull request is closed.

Walkthrough

Adds environment variables to deployment, new dependencies, routing for dynamic chat rooms, a configured Axios client, a major Chatroom feature rewrite with WebSocket/STOMP, search, read receipts, infinite scroll, formation/participants tabs, a Main page chat entry flow, CSS overhaul, and a Vite define change to use globalThis.

Changes

Cohort / File(s) Summary
CI/CD env exposure
.github/workflows/deploy.yml
Build step injects VITE_API_BASE_URL and VITE_API_WS_URL from secrets for frontend build-time access.
Dependencies
package.json
Adds date-fns, lodash.debounce, react-intersection-observer, react-virtualized-auto-sizer, react-window, uuid; sockjs-client presence unchanged.
Routing
src/App.jsx
Adds dynamic route /chatroom/:roomId alongside existing /chatroom.
API client (new + existing)
src/api/axiosConfig.js, src/api/axiosInstance.js
New axiosConfig exports configured Axios with baseURL from env and auth header via interceptor; axiosInstance formatting only.
Chatroom feature overhaul
src/pages/Chatroom.jsx
Replaces mock UI with real-time chat using SockJS/STOMP, token-aware API calls, roomId param handling, message/search/history, read receipts, infinite scroll, alerts, formation/participants tabs, connection status, and improved input handling.
Chatroom styling rewrite
src/pages/Chatroom.css
Introduces two-panel layout, tabs, formation field, participant list, chat search/results, animations, alerts, loading states, responsive rules, and custom scrollbars.
Main page chat entry
src/pages/Main.jsx
Adds “chatroom enter” flow: checks login, fetches current room, navigates to /chatroom/{roomId} or prompts; adds corresponding button. Minor formatting elsewhere.
Build config
vite.config.js
Changes define.global from window to globalThis.

Sequence Diagram(s)

sequenceDiagram
  autonumber
  participant U as User
  participant Main as Main.jsx
  participant API as axiosInstance (REST)
  participant Router as Router
  participant Chat as Chatroom.jsx
  participant WS as STOMP/SockJS

  U->>Main: Click "채팅방 입장"
  Main->>API: GET /api/user/current-room (Authorization)
  alt roomId exists
    Main->>Router: navigate /chatroom/{roomId}
    Router->>Chat: mount with roomId
  else not in room
    Main-->>U: Alert: no chatroom joined
  end

  Chat->>API: GET current user, scoreboard, initial messages, read state
  Chat->>WS: STOMP connect to VITE_API_WS_URL
  WS-->>Chat: connected
  Chat->>WS: SUBSCRIBE /topic/chat/{roomId}
  WS-->>Chat: MESSAGE (new chat/alert)
  Chat->>Chat: format + append, update unread/read (debounced)
  U->>Chat: Scroll up hits sentinel
  Chat->>API: GET older messages (page)
  API-->>Chat: Older messages
  Chat->>Chat: Prepend, preserve scroll
Loading
sequenceDiagram
  autonumber
  participant U as User
  participant Chat as Chatroom.jsx
  participant WS as STOMP/SockJS
  participant API as axiosInstance (REST)

  U->>Chat: Type and press Enter
  Chat->>WS: SEND /app/chat/{roomId}/send {text}
  WS-->>Chat: (Echo via topic) MESSAGE
  Chat->>Chat: Append, mark read if at bottom (debounced)
  U->>Chat: Search query
  Chat->>API: GET /api/chat/{roomId}/search?q=...
  API-->>Chat: Results
  Chat-->>U: Show filtered results
Loading

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~60 minutes

Possibly related PRs

Suggested labels

enhancement

Suggested reviewers

  • hwichoi0317
  • Kim-Jaehyun0328
  • wjkim9

Poem

A rabbit taps code in a moonlit room,
WebSockets hum, messages bloom.
Tabs hop left, chat flows right—
Formation fields in verdant light.
With globalThis and secrets neat,
I thump approval with bounding feet.
Send, scroll, search—what a treat! 🐇💬


📜 Recent 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 3359e86 and a8c894e.

⛔ Files ignored due to path filters (1)
  • package-lock.json is excluded by !**/package-lock.json
📒 Files selected for processing (9)
  • .github/workflows/deploy.yml (1 hunks)
  • package.json (1 hunks)
  • src/App.jsx (1 hunks)
  • src/api/axiosConfig.js (1 hunks)
  • src/api/axiosInstance.js (1 hunks)
  • src/pages/Chatroom.css (1 hunks)
  • src/pages/Chatroom.jsx (1 hunks)
  • src/pages/Main.jsx (5 hunks)
  • vite.config.js (1 hunks)
✨ Finishing Touches
  • 📝 Generate Docstrings
🧪 Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch dev

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.

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

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.

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

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants