feat : 지도 화면에 실제 핀 데이터 연결 - #182
Conversation
- MapPage.tsx에 useMapPins(viewport) 연결, onViewportChanged로 idle마다 갱신
- selectedMapPinId state 추가, 탭 시 갱신되도록 onSelectMapPin 연결
- 하드코딩돼 있던 mapPins={[]} / selectedMapPinId={null} 제거
- 개발 환경에서 실 API 응답이 비어있을 때 서울시청 근처 고정 좌표에
목데이터 4개를 띄워 배선/렌더링 확인 가능하게 함 (프로덕션 빌드 미포함)
그 외: MapPinMarker의 선택 시 scale(1.2)가 말풍선까지 같이 확대시키던
버그 수정 (아이콘 전용 wrapper로 분리) - feat/170 PR 리뷰에서 나왔던
수정사항이 머지 전에 누락돼 있어서 같이 반영
|
Warning Review limit reached
Next review available in: 50 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthrough
Changes지도 핀 흐름
Estimated code review effort: 3 (Moderate) | ~20 minutes Sequence Diagram(s)sequenceDiagram
participant MapPage
participant useMapPins
participant MapViewer
participant MapPinMarker
MapPage->>useMapPins: viewport로 핀 데이터 조회
useMapPins-->>MapPage: 조회된 mapPins 반환
MapPage->>MapViewer: mapPins와 selectedMapPinId 전달
MapViewer->>MapPinMarker: 핀 데이터와 선택 상태 전달
MapViewer-->>MapPage: viewport 변경 및 핀 선택 이벤트 전달
Possibly related PRs
Suggested labels: Suggested reviewers: 🚥 Pre-merge checks | ✅ 4✅ Passed checks (4 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
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. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@src/pages/MapPage.tsx`:
- Around line 59-65: Update the DEV_MOCK_MAP_PINS fallback condition in
MapPage’s mapPins calculation so it activates only when mapPinsData exists and
its pins array is actually empty. Do not treat undefined mapPinsData as an empty
response; preserve the empty array fallback for unavailable data so loading,
disabled low-zoom viewports, and API errors do not display mock pins.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro Plus
Run ID: b150fc4d-1bb6-4f0d-b552-5424b528bec0
📒 Files selected for processing (3)
src/features/map/components/MapPinMarker.tsxsrc/features/map/constants/devMockMapPins.tssrc/pages/MapPage.tsx
mapPinsData가 undefined(로딩 중/줌 제한으로 비활성/API 에러)인 경우를 빈 응답으로 오인해 개발용 목데이터를 띄우던 문제 수정. 실제로 응답이 도착했는데 pins가 빈 배열인 경우에만 목데이터를 사용하도록 조건 변경
변경 내용
그 외: MapPinMarker의 선택 시 scale(1.2)가 말풍선까지 같이 확대시키던 버그 수정 (아이콘 전용 wrapper로 분리) - feat/170 PR 리뷰에서 나왔던
수정사항이 머지 전에 누락돼 있어서 같이 반영
관련 이슈
Closes #179
변경 사항
테스트
스크린샷 (UI 변경시)
체크리스트
pnpm format)pnpm lint:fix)코드 품질 확인
PR 제출 전에 다음 명령어를 실행하여 코드 품질을 확인해주세요:
Summary by CodeRabbit