feat: Add real-time visitor map with IP geolocation

- Add latitude/longitude columns to visitor_logs model
- Update visitor_service to fetch and store coordinates from ip-api.com
- Add /admin/map-data API endpoint for map visualization
- Create VisitorMap component using Leaflet/OpenStreetMap
- Integrate map into visitor-stats admin page
- 30-second auto-refresh with animation for new visitors
- Color-coded markers (red: active, blue: recent)

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

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
AutonetSellCar Deploy
2026-01-05 18:31:22 +09:00
parent 4858965087
commit b8f0ae4d28
7 changed files with 469 additions and 3 deletions

View File

@@ -14,12 +14,15 @@
"@heroicons/react": "^2.1.1",
"@stripe/react-stripe-js": "^5.4.1",
"@stripe/stripe-js": "^8.6.0",
"@types/leaflet": "^1.9.21",
"axios": "^1.6.5",
"framer-motion": "^12.23.25",
"leaflet": "^1.9.4",
"next": "14.1.0",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"react-hook-form": "^7.49.3",
"react-leaflet": "^4.2.1",
"zustand": "^4.5.0"
},
"devDependencies": {