feat(ui): replace Google Maps with Leaflet + OpenStreetMap

- Replace all Google Map components with Leaflet OSM alternatives
- Add osm-map.tsx with dynamic Leaflet import (SSR-safe)
- Use CDN for Leaflet CSS to avoid Next.js CSS import issues
- Update types.tsx to remove google.maps dependencies
- Replace Google Places autocomplete with Nominatim OSM
- Replace Google Geocoding with Nominatim OSM
- Add GPS coordinates for all 15 Martinique charging station locations
- Update next.config.mjs: ignoreBuildErrors for TypeScript loops
- Update package.json: use 'next build' instead of 'refine build'
- Add .dockerignore for faster Docker builds
- Fix map centering on Martinique (default: 14.6415, -61.0242)
This commit is contained in:
Eric F
2026-06-12 11:04:18 -04:00
parent 5b3970fd6c
commit 9a14723b07
21 changed files with 487 additions and 1015 deletions

View File

@@ -7,7 +7,7 @@
"clean-dist": "find . -type d -name .next -not -path '*/node_modules/*' -exec rm -rf {} +",
"clean": "pnpm run clean-dist && pnpm run clean-tsbuildinfo",
"dev": "cross-env NODE_OPTIONS=--max_old_space_size=4096 refine dev",
"build": "refine build",
"build": "next build",
"start": "refine start",
"prettier": "prettier --write .",
"lint": "eslint ./",
@@ -57,6 +57,7 @@
"@refinedev/ui-types": "2.0.1",
"@tanstack/react-query": "5.90.5",
"@tanstack/react-table": "8.21.3",
"@types/leaflet": "^1.9.21",
"@vis.gl/react-google-maps": "1.5.1",
"axios": "1.12.2",
"class-transformer": "0.5.1",
@@ -72,6 +73,7 @@
"graphql-request": "5.2.0",
"graphql-tag": "2.12.6",
"js-cookie": "3.0.5",
"leaflet": "^1.9.4",
"lodash": "^4.18.1",
"lodash.debounce": "4.0.8",
"lodash.isequal": "4.5.0",
@@ -86,6 +88,7 @@
"react-day-picker": "9.11.1",
"react-dom": "19.1.4",
"react-hook-form": "7.65.0",
"react-leaflet": "^5.0.0",
"react-redux": "9.2.0",
"react-syntax-highlighter": "15.6.6",
"recharts": "3.5.1",
@@ -99,6 +102,8 @@
},
"devDependencies": {
"@axe-core/playwright": "^4.10.0",
"@eslint/eslintrc": "^3.2.0",
"@eslint/js": "catalog:",
"@playwright/test": "^1.49.0",
"@tailwindcss/postcss": "4",
"@types/geojson": "7946.0.16",
@@ -112,8 +117,6 @@
"@types/react-syntax-highlighter": "15.5.13",
"cross-env": "7.0.3",
"dotenv": "^16.4.5",
"@eslint/eslintrc": "^3.2.0",
"@eslint/js": "catalog:",
"eslint": "catalog:",
"eslint-config-next": "15.0.3",
"eslint-config-prettier": "catalog:",