feat(map): 식당 선택 시 지도 자동 줌인/이동

- 리스트/검색결과에서 식당 클릭 → setRegionFlyTo로 그 좌표 + zoom 16
- NaverMap/GoogleMap dispatcher 둘 다 panTo + setZoom
- 마커 selected 강조(1.15× 파란 박스)와 함께 동작

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
joungmin
2026-06-16 17:29:28 +09:00
parent 78f7e83a0e
commit 1164139312
2 changed files with 9 additions and 0 deletions

View File

@@ -385,6 +385,10 @@ export default function Home() {
const handleSelectRestaurant = useCallback((r: Restaurant) => {
setSelected(r);
setShowDetail(true);
// 지도가 선택 식당으로 이동/줌인 — 객체 새로 만들어 flyTo effect 매번 트리거
if (r.latitude != null && r.longitude != null) {
setRegionFlyTo({ lat: r.latitude, lng: r.longitude, zoom: 16 });
}
}, []);
const handleCloseDetail = useCallback(() => {