Skip to content

fix : 500m 이내 타인 곡 상세 열람 허용 - #308

Merged
kim3360 merged 7 commits into
developfrom
feat/307-within-500m-track-detail-access
Aug 10, 2026
Merged

kim3360 merged 7 commits into
developfrom
feat/307-within-500m-track-detail-access

Conversation

@kim3360

@kim3360 kim3360 commented Aug 10, 2026 •

Copy link
Copy Markdown
Member

변경 내용

  • 지도에서 현재 위치 500m 이내 장소면 타인이 등록한 곡도 상세를 볼 수 있게 했습니다.
  • 상세 열람이 막힌 카드는 텍스트를 어두운 색으로 표시하고, 상하 패딩·재생 버튼 그라데이션도 함께 조정했습니다.

관련 이슈

Closes #307

변경 사항

  • 새로운 기능 추가
  • 버그 수정
  • UI/UX 개선
  • 리팩토링
  • 문서 업데이트

테스트

  • 브라우저에서 정상 동작 확인
  • 기존 기능에 영향 없음 확인

스크린샷 (UI 변경시)

체크리스트

  • 코드가 정상적으로 동작합니다
  • 새로운 에러나 경고가 없습니다
  • 필요시 문서를 업데이트했습니다
  • 코드 포맷팅을 실행했습니다 (pnpm format)
  • ESLint 검사를 통과했습니다 (pnpm lint:fix)

코드 품질 확인
PR 제출 전에 다음 명령어를 실행하여 코드 품질을 확인해주세요:

pnpm lint:fix
pnpm format

Summary by CodeRabbit

  • 새로운 기능

    • 장소에서 500m 이내에 있거나 내 장소인 경우, 별도 접근 허용 설정이 없어도 곡 상세 정보를 확인할 수 있습니다.
    • 접근이 제한된 경우 안내 문구에 500m 기준이 표시됩니다.
  • 개선 사항

    • 좋아요 영역과 좋아요 수가 일관되게 표시되며, 좋아요가 없을 때 0으로 표시됩니다.
    • 카드의 이동 안내와 아이콘 색상이 화면 상태에 맞게 변경됩니다.
    • 미리듣기 버튼에 네온 그라데이션 디자인이 적용되었습니다.
    • 위치 정보가 없을 때 잘못된 위치로 상세 화면이 열리지 않도록 개선되었습니다.

@kim3360
kim3360 requested review from JeongGyul, L0521 and onebone August 10, 2026 17:29
@kim3360 kim3360 self-assigned this Aug 10, 2026
@coderabbitai

coderabbitai Bot commented Aug 10, 2026 •

Copy link
Copy Markdown

Review Change Stack

📝 Walkthrough

Walkthrough

현재 위치 조회 결과를 기준으로 지도 상세 화면의 위치 전달을 변경했습니다. 현재 위치 500m 이내 장소의 곡 상세 접근 조건을 추가했습니다. showLike에 따른 핀 카드 표시와 미리듣기 버튼 배경을 조정했습니다.

Changes

핀 상세 접근 및 표시

Layer / File(s) Summary
위치 조회 및 상세 위치 전달
src/features/pin/hooks/useOpenPinPlaceOnMap.ts, src/pages/MapPage.tsx
위치 조회에 성공한 경우에만 사용자 좌표를 전달합니다. 위치 조회에 실패하면 장소 조회에는 핀 좌표를 사용하지만, 상세 화면에는 사용자 좌표를 전달하지 않습니다.
곡 상세 접근 조건
src/features/pin/components/PinListSheet.tsx, src/features/pin/types.ts
현재 위치 500m 이내, 찜한 곡 보유 장소, 내 장소, 피드 진입, 서버 허용 여부 중 하나를 만족하면 곡 상세를 열 수 있습니다. 접근 정책 설명과 차단 안내 문구를 갱신했습니다.
핀 카드 표시 스타일
src/features/pin/components/PinCard.tsx, src/features/pin/components/PinFeedCard.tsx
showLike에 따라 카드 여백, 텍스트 색상, 좋아요 영역, 이동 안내 색상을 변경합니다. 좋아요 수가 없으면 0을 표시합니다. 미리듣기 버튼에 bg-gradient-neon을 적용합니다.

Estimated code review effort: 3 (Moderate) | ~20 minutes

Sequence Diagram(s)

sequenceDiagram
  participant MapPage
  participant useOpenPinPlaceOnMap
  participant PinListSheet
  participant TrackDetail
  MapPage->>useOpenPinPlaceOnMap: 장소 및 사용자 위치 조회
  useOpenPinPlaceOnMap-->>MapPage: 장소 정보와 userCoordinate 반환
  MapPage->>PinListSheet: detailLocation 및 사용자 좌표 전달
  PinListSheet->>PinListSheet: 접근 조건 확인
  PinListSheet->>TrackDetail: 조건 충족 시 곡 상세 화면 이동
  PinListSheet-->>MapPage: 조건 불충족 시 차단 안내 표시
Loading

Possibly related PRs

Suggested labels: feature

Suggested reviewers: l0521, onebone, jeonggyul

🚥 Pre-merge checks | ✅ 4
✅ Passed checks (4 passed)
Check name Status Explanation
Linked Issues check ✅ Passed PinListSheet와 위치 전달 로직에 500m 이내 조건을 반영하여 이슈 #307의 열람 허용 요구사항을 충족합니다.
Out of Scope Changes check ✅ Passed UI 조정과 위치 처리 변경은 500m 이내 상세 열람 기능 및 관련 사용자 경험 개선 범위에 포함됩니다.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed 제목은 현재 위치 기준 500m 이내 타인 곡의 상세 열람을 허용하는 주요 변경 사항을 명확하게 요약합니다.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/307-within-500m-track-detail-access

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

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

@github-actions

Copy link
Copy Markdown

https://pr-308.plimap.kr

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

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/features/pin/components/PinListSheet.tsx`:
- Around line 427-431: Update useOpenPinPlaceOnMap and the PinListSheet
canOpenTrackDetail flow to track whether getCurrentPosition() succeeded, avoid
using the target pin coordinates as the userCoordinate or detailLocation
fallback, and only honor placeDetailQuery.data?.withinAccessRange when a real
user location is available; preserve access through allowTrackDetailAccess and
resolvedPlace.isMine.
🪄 Autofix

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: 9532eee8-a75a-464f-bfea-3373c892d52f

📥 Commits

Reviewing files that changed from the base of the PR and between 2125bc6 and f0ed8e5.

📒 Files selected for processing (4)
  • src/features/pin/components/PinCard.tsx
  • src/features/pin/components/PinFeedCard.tsx
  • src/features/pin/components/PinListSheet.tsx
  • src/features/pin/types.ts

Comment thread src/features/pin/components/PinListSheet.tsx Outdated

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

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/features/pin/hooks/useOpenPinPlaceOnMap.ts`:
- Around line 78-81: 위치 조회 상태와 장소 곡 목록 조회에 사용할 좌표를 별도 계약으로 분리하세요.
src/features/pin/hooks/useOpenPinPlaceOnMap.ts의 useOpenPinPlaceOnMap 반환값에 목록 조회용
좌표 키를 추가하고, src/pages/MapPage.tsx 537-567 및 596-614의 지도 핀·피드/내 장소 선택 경로가 위치 실패
시에도 해당 좌표를 사용해 PinSearchPlace를 생성하도록 수정하세요. PinListSheet의 detailLocation은 위치 성공
여부를 계속 반영하되, usePlaceDetail·usePlaceTrack이 비활성화되지 않도록 목록 조회 좌표는 별도 키로 전달해야 합니다.
🪄 Autofix

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: c8d4d1ea-4560-4feb-9fd7-485e0f13d3bb

📥 Commits

Reviewing files that changed from the base of the PR and between f0ed8e5 and d284b5e.

📒 Files selected for processing (3)
  • src/features/pin/components/PinListSheet.tsx
  • src/features/pin/hooks/useOpenPinPlaceOnMap.ts
  • src/pages/MapPage.tsx

Comment thread src/features/pin/hooks/useOpenPinPlaceOnMap.ts
@kim3360 kim3360 closed this Aug 10, 2026
@kim3360 kim3360 reopened this Aug 10, 2026
@kim3360
kim3360 deployed to preview-maintenance August 10, 2026 19:04 — with GitHub Actions Active
@kim3360 kim3360 changed the title 500m 이내 타인 곡 상세 열람 허용 fix : 500m 이내 타인 곡 상세 열람 허용 Aug 10, 2026
@kim3360
kim3360 merged commit e661ccc into develop Aug 10, 2026
7 of 9 checks passed
@kim3360
kim3360 deployed to preview-maintenance August 10, 2026 19:05 — with GitHub Actions Active

This branch was successfully deployed

1 active deployment
preview-maintenance — 738526a0 Deployed Aug 10, 2026 by kim3360 via cleanup #511
preview — 738526a0 Deployed Aug 10, 2026 by kim3360 via deploy #508
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

500m 이내 타인 곡 상세 열람 허용

1 participant