From 6e70581e58485282c935ea6c32e47f9a24f439b4 Mon Sep 17 00:00:00 2001 From: 12Koushik1 Date: Sat, 24 Jan 2026 22:07:33 -0500 Subject: [PATCH 1/7] Did the map component and map component testing page --- package-lock.json | 207 +++++++++++++++++++++++++++++-------- package.json | 4 + pnpm-lock.yaml | 120 +++++++++++++++++++++ src/app/map-test/page.tsx | 17 +++ src/components/MapComp.tsx | 38 +++++++ 5 files changed, 345 insertions(+), 41 deletions(-) create mode 100644 src/app/map-test/page.tsx create mode 100644 src/components/MapComp.tsx diff --git a/package-lock.json b/package-lock.json index 347d0c4..f092d67 100644 --- a/package-lock.json +++ b/package-lock.json @@ -19,15 +19,19 @@ "@mui/x-data-grid": "^8.10.0", "@mui/x-date-pickers": "^8.23.0", "@neondatabase/serverless": "^1.0.1", + "@react-google-maps/api": "^2.20.8", + "@types/leaflet": "^1.9.21", "dayjs": "^1.11.19", "dotenv": "^17.2.3", "drizzle-orm": "^0.44.4", - "next": "15.4.6", + "leaflet": "^1.9.4", + "next": "15.4.10", "next-auth": "^4.24.11", "notistack": "^3.0.2", "react": "19.1.0", "react-dom": "19.1.0", "react-hook-form": "^7.62.0", + "react-leaflet": "^5.0.0", "zod": "^4.0.17" }, "devDependencies": { @@ -1546,6 +1550,22 @@ "node": "^18.18.0 || ^20.9.0 || >=21.1.0" } }, + "node_modules/@googlemaps/js-api-loader": { + "version": "1.16.8", + "resolved": "https://registry.npmjs.org/@googlemaps/js-api-loader/-/js-api-loader-1.16.8.tgz", + "integrity": "sha512-CROqqwfKotdO6EBjZO/gQGVTbeDps5V7Mt9+8+5Q+jTg5CRMi3Ii/L9PmV3USROrt2uWxtGzJHORmByxyo9pSQ==", + "license": "Apache-2.0" + }, + "node_modules/@googlemaps/markerclusterer": { + "version": "2.5.3", + "resolved": "https://registry.npmjs.org/@googlemaps/markerclusterer/-/markerclusterer-2.5.3.tgz", + "integrity": "sha512-x7lX0R5yYOoiNectr10wLgCBasNcXFHiADIBdmn7jQllF2B5ENQw5XtZK+hIw4xnV0Df0xhN4LN98XqA5jaiOw==", + "license": "Apache-2.0", + "dependencies": { + "fast-deep-equal": "^3.1.3", + "supercluster": "^8.0.1" + } + }, "node_modules/@hookform/resolvers": { "version": "5.2.2", "resolved": "https://registry.npmjs.org/@hookform/resolvers/-/resolvers-5.2.2.tgz", @@ -2547,9 +2567,9 @@ } }, "node_modules/@next/env": { - "version": "15.4.6", - "resolved": "https://registry.npmjs.org/@next/env/-/env-15.4.6.tgz", - "integrity": "sha512-yHDKVTcHrZy/8TWhj0B23ylKv5ypocuCwey9ZqPyv4rPdUdRzpGCkSi03t04KBPyU96kxVtUqx6O3nE1kpxASQ==", + "version": "15.4.10", + "resolved": "https://registry.npmjs.org/@next/env/-/env-15.4.10.tgz", + "integrity": "sha512-knhmoJ0Vv7VRf6pZEPSnciUG1S4bIhWx+qTYBW/AjxEtlzsiNORPk8sFDCEvqLfmKuey56UB9FL1UdHEV3uBrg==", "license": "MIT" }, "node_modules/@next/eslint-plugin-next": { @@ -2563,9 +2583,9 @@ } }, "node_modules/@next/swc-darwin-arm64": { - "version": "15.4.6", - "resolved": "https://registry.npmjs.org/@next/swc-darwin-arm64/-/swc-darwin-arm64-15.4.6.tgz", - "integrity": "sha512-667R0RTP4DwxzmrqTs4Lr5dcEda9OxuZsVFsjVtxVMVhzSpo6nLclXejJVfQo2/g7/Z9qF3ETDmN3h65mTjpTQ==", + "version": "15.4.8", + "resolved": "https://registry.npmjs.org/@next/swc-darwin-arm64/-/swc-darwin-arm64-15.4.8.tgz", + "integrity": "sha512-Pf6zXp7yyQEn7sqMxur6+kYcywx5up1J849psyET7/8pG2gQTVMjU3NzgIt8SeEP5to3If/SaWmaA6H6ysBr1A==", "cpu": [ "arm64" ], @@ -2579,9 +2599,9 @@ } }, "node_modules/@next/swc-darwin-x64": { - "version": "15.4.6", - "resolved": "https://registry.npmjs.org/@next/swc-darwin-x64/-/swc-darwin-x64-15.4.6.tgz", - "integrity": "sha512-KMSFoistFkaiQYVQQnaU9MPWtp/3m0kn2Xed1Ces5ll+ag1+rlac20sxG+MqhH2qYWX1O2GFOATQXEyxKiIscg==", + "version": "15.4.8", + "resolved": "https://registry.npmjs.org/@next/swc-darwin-x64/-/swc-darwin-x64-15.4.8.tgz", + "integrity": "sha512-xla6AOfz68a6kq3gRQccWEvFC/VRGJmA/QuSLENSO7CZX5WIEkSz7r1FdXUjtGCQ1c2M+ndUAH7opdfLK1PQbw==", "cpu": [ "x64" ], @@ -2595,9 +2615,9 @@ } }, "node_modules/@next/swc-linux-arm64-gnu": { - "version": "15.4.6", - "resolved": "https://registry.npmjs.org/@next/swc-linux-arm64-gnu/-/swc-linux-arm64-gnu-15.4.6.tgz", - "integrity": "sha512-PnOx1YdO0W7m/HWFeYd2A6JtBO8O8Eb9h6nfJia2Dw1sRHoHpNf6lN1U4GKFRzRDBi9Nq2GrHk9PF3Vmwf7XVw==", + "version": "15.4.8", + "resolved": "https://registry.npmjs.org/@next/swc-linux-arm64-gnu/-/swc-linux-arm64-gnu-15.4.8.tgz", + "integrity": "sha512-y3fmp+1Px/SJD+5ntve5QLZnGLycsxsVPkTzAc3zUiXYSOlTPqT8ynfmt6tt4fSo1tAhDPmryXpYKEAcoAPDJw==", "cpu": [ "arm64" ], @@ -2611,9 +2631,9 @@ } }, "node_modules/@next/swc-linux-arm64-musl": { - "version": "15.4.6", - "resolved": "https://registry.npmjs.org/@next/swc-linux-arm64-musl/-/swc-linux-arm64-musl-15.4.6.tgz", - "integrity": "sha512-XBbuQddtY1p5FGPc2naMO0kqs4YYtLYK/8aPausI5lyOjr4J77KTG9mtlU4P3NwkLI1+OjsPzKVvSJdMs3cFaw==", + "version": "15.4.8", + "resolved": "https://registry.npmjs.org/@next/swc-linux-arm64-musl/-/swc-linux-arm64-musl-15.4.8.tgz", + "integrity": "sha512-DX/L8VHzrr1CfwaVjBQr3GWCqNNFgyWJbeQ10Lx/phzbQo3JNAxUok1DZ8JHRGcL6PgMRgj6HylnLNndxn4Z6A==", "cpu": [ "arm64" ], @@ -2627,9 +2647,9 @@ } }, "node_modules/@next/swc-linux-x64-gnu": { - "version": "15.4.6", - "resolved": "https://registry.npmjs.org/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-15.4.6.tgz", - "integrity": "sha512-+WTeK7Qdw82ez3U9JgD+igBAP75gqZ1vbK6R8PlEEuY0OIe5FuYXA4aTjL811kWPf7hNeslD4hHK2WoM9W0IgA==", + "version": "15.4.8", + "resolved": "https://registry.npmjs.org/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-15.4.8.tgz", + "integrity": "sha512-9fLAAXKAL3xEIFdKdzG5rUSvSiZTLLTCc6JKq1z04DR4zY7DbAPcRvNm3K1inVhTiQCs19ZRAgUerHiVKMZZIA==", "cpu": [ "x64" ], @@ -2643,9 +2663,9 @@ } }, "node_modules/@next/swc-linux-x64-musl": { - "version": "15.4.6", - "resolved": "https://registry.npmjs.org/@next/swc-linux-x64-musl/-/swc-linux-x64-musl-15.4.6.tgz", - "integrity": "sha512-XP824mCbgQsK20jlXKrUpZoh/iO3vUWhMpxCz8oYeagoiZ4V0TQiKy0ASji1KK6IAe3DYGfj5RfKP6+L2020OQ==", + "version": "15.4.8", + "resolved": "https://registry.npmjs.org/@next/swc-linux-x64-musl/-/swc-linux-x64-musl-15.4.8.tgz", + "integrity": "sha512-s45V7nfb5g7dbS7JK6XZDcapicVrMMvX2uYgOHP16QuKH/JA285oy6HcxlKqwUNaFY/UC6EvQ8QZUOo19cBKSA==", "cpu": [ "x64" ], @@ -2659,9 +2679,9 @@ } }, "node_modules/@next/swc-win32-arm64-msvc": { - "version": "15.4.6", - "resolved": "https://registry.npmjs.org/@next/swc-win32-arm64-msvc/-/swc-win32-arm64-msvc-15.4.6.tgz", - "integrity": "sha512-FxrsenhUz0LbgRkNWx6FRRJIPe/MI1JRA4W4EPd5leXO00AZ6YU8v5vfx4MDXTvN77lM/EqsE3+6d2CIeF5NYg==", + "version": "15.4.8", + "resolved": "https://registry.npmjs.org/@next/swc-win32-arm64-msvc/-/swc-win32-arm64-msvc-15.4.8.tgz", + "integrity": "sha512-KjgeQyOAq7t/HzAJcWPGA8X+4WY03uSCZ2Ekk98S9OgCFsb6lfBE3dbUzUuEQAN2THbwYgFfxX2yFTCMm8Kehw==", "cpu": [ "arm64" ], @@ -2675,9 +2695,9 @@ } }, "node_modules/@next/swc-win32-x64-msvc": { - "version": "15.4.6", - "resolved": "https://registry.npmjs.org/@next/swc-win32-x64-msvc/-/swc-win32-x64-msvc-15.4.6.tgz", - "integrity": "sha512-T4ufqnZ4u88ZheczkBTtOF+eKaM14V8kbjud/XrAakoM5DKQWjW09vD6B9fsdsWS2T7D5EY31hRHdta7QKWOng==", + "version": "15.4.8", + "resolved": "https://registry.npmjs.org/@next/swc-win32-x64-msvc/-/swc-win32-x64-msvc-15.4.8.tgz", + "integrity": "sha512-Exsmf/+42fWVnLMaZHzshukTBxZrSwuuLKFvqhGHJ+mC1AokqieLY/XzAl3jc/CqhXLqLY3RRjkKJ9YnLPcRWg==", "cpu": [ "x64" ], @@ -3039,6 +3059,47 @@ "url": "https://opencollective.com/popperjs" } }, + "node_modules/@react-google-maps/api": { + "version": "2.20.8", + "resolved": "https://registry.npmjs.org/@react-google-maps/api/-/api-2.20.8.tgz", + "integrity": "sha512-wtLYFtCGXK3qbIz1H5to3JxbosPnKsvjDKhqGylXUb859EskhzR7OpuNt0LqdLarXUtZCJTKzPn3BNaekNIahg==", + "license": "MIT", + "dependencies": { + "@googlemaps/js-api-loader": "1.16.8", + "@googlemaps/markerclusterer": "2.5.3", + "@react-google-maps/infobox": "2.20.0", + "@react-google-maps/marker-clusterer": "2.20.0", + "@types/google.maps": "3.58.1", + "invariant": "2.2.4" + }, + "peerDependencies": { + "react": "^16.8 || ^17 || ^18 || ^19", + "react-dom": "^16.8 || ^17 || ^18 || ^19" + } + }, + "node_modules/@react-google-maps/infobox": { + "version": "2.20.0", + "resolved": "https://registry.npmjs.org/@react-google-maps/infobox/-/infobox-2.20.0.tgz", + "integrity": "sha512-03PJHjohhaVLkX6+NHhlr8CIlvUxWaXhryqDjyaZ8iIqqix/nV8GFdz9O3m5OsjtxtNho09F/15j14yV0nuyLQ==", + "license": "MIT" + }, + "node_modules/@react-google-maps/marker-clusterer": { + "version": "2.20.0", + "resolved": "https://registry.npmjs.org/@react-google-maps/marker-clusterer/-/marker-clusterer-2.20.0.tgz", + "integrity": "sha512-tieX9Va5w1yP88vMgfH1pHTacDQ9TgDTjox3tLlisKDXRQWdjw+QeVVghhf5XqqIxXHgPdcGwBvKY6UP+SIvLw==", + "license": "MIT" + }, + "node_modules/@react-leaflet/core": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/@react-leaflet/core/-/core-3.0.0.tgz", + "integrity": "sha512-3EWmekh4Nz+pGcr+xjf0KNyYfC3U2JjnkWsh0zcqaexYqmmB5ZhH37kz41JXGmKzpaMZCnPofBBm64i+YrEvGQ==", + "license": "Hippocratic-2.1", + "peerDependencies": { + "leaflet": "^1.9.0", + "react": "^19.0.0", + "react-dom": "^19.0.0" + } + }, "node_modules/@rtsao/scc": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/@rtsao/scc/-/scc-1.1.0.tgz", @@ -3094,6 +3155,18 @@ "dev": true, "license": "MIT" }, + "node_modules/@types/geojson": { + "version": "7946.0.16", + "resolved": "https://registry.npmjs.org/@types/geojson/-/geojson-7946.0.16.tgz", + "integrity": "sha512-6C8nqWur3j98U6+lXDfTUWIfgvZU+EumvpHKcYjujKH7woYyLj2sUmff0tRhrqM7BohUw7Pz3ZB1jj2gW9Fvmg==", + "license": "MIT" + }, + "node_modules/@types/google.maps": { + "version": "3.58.1", + "resolved": "https://registry.npmjs.org/@types/google.maps/-/google.maps-3.58.1.tgz", + "integrity": "sha512-X9QTSvGJ0nCfMzYOnaVs/k6/4L+7F5uCS+4iUmkLEls6J9S/Phv+m/i3mDeyc49ZBgwab3EFO1HEoBY7k98EGQ==", + "license": "MIT" + }, "node_modules/@types/json-schema": { "version": "7.0.15", "resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.15.tgz", @@ -3108,6 +3181,15 @@ "dev": true, "license": "MIT" }, + "node_modules/@types/leaflet": { + "version": "1.9.21", + "resolved": "https://registry.npmjs.org/@types/leaflet/-/leaflet-1.9.21.tgz", + "integrity": "sha512-TbAd9DaPGSnzp6QvtYngntMZgcRk+igFELwR2N99XZn7RXUdKgsXMR+28bUO0rPsWp8MIu/f47luLIQuSLYv/w==", + "license": "MIT", + "dependencies": { + "@types/geojson": "*" + } + }, "node_modules/@types/node": { "version": "20.19.21", "resolved": "https://registry.npmjs.org/@types/node/-/node-20.19.21.tgz", @@ -5625,7 +5707,6 @@ "version": "3.1.3", "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz", "integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==", - "dev": true, "license": "MIT" }, "node_modules/fast-diff": { @@ -6221,6 +6302,15 @@ "node": ">= 0.4" } }, + "node_modules/invariant": { + "version": "2.2.4", + "resolved": "https://registry.npmjs.org/invariant/-/invariant-2.2.4.tgz", + "integrity": "sha512-phJfQVBuaJM5raOpJjSfkiD6BpbCE4Ns//LaXl6wGYtUBY83nWS6Rf9tXm2e8VaK60JEjYldbPif/A2B1C2gNA==", + "license": "MIT", + "dependencies": { + "loose-envify": "^1.0.0" + } + }, "node_modules/is-array-buffer": { "version": "3.0.5", "resolved": "https://registry.npmjs.org/is-array-buffer/-/is-array-buffer-3.0.5.tgz", @@ -6792,6 +6882,12 @@ "node": ">=4.0" } }, + "node_modules/kdbush": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/kdbush/-/kdbush-4.0.2.tgz", + "integrity": "sha512-WbCVYJ27Sz8zi9Q7Q0xHC+05iwkm3Znipc2XTlrnJbsHMYktW4hPhXUE8Ys1engBrvffoSCqbil1JQAa7clRpA==", + "license": "ISC" + }, "node_modules/keyv": { "version": "4.5.4", "resolved": "https://registry.npmjs.org/keyv/-/keyv-4.5.4.tgz", @@ -6907,6 +7003,12 @@ "node": ">=0.10" } }, + "node_modules/leaflet": { + "version": "1.9.4", + "resolved": "https://registry.npmjs.org/leaflet/-/leaflet-1.9.4.tgz", + "integrity": "sha512-nxS1ynzJOmOlHp+iL3FyWqK89GtNL8U8rvlMOsQdTTssxZwCXh8N2NB3GDQOL+YR3XnWyZAxwQixURb+FA74PA==", + "license": "BSD-2-Clause" + }, "node_modules/levn": { "version": "0.4.1", "resolved": "https://registry.npmjs.org/levn/-/levn-0.4.1.tgz", @@ -7092,12 +7194,12 @@ "license": "MIT" }, "node_modules/next": { - "version": "15.4.6", - "resolved": "https://registry.npmjs.org/next/-/next-15.4.6.tgz", - "integrity": "sha512-us++E/Q80/8+UekzB3SAGs71AlLDsadpFMXVNM/uQ0BMwsh9m3mr0UNQIfjKed8vpWXsASe+Qifrnu1oLIcKEQ==", + "version": "15.4.10", + "resolved": "https://registry.npmjs.org/next/-/next-15.4.10.tgz", + "integrity": "sha512-itVlc79QjpKMFMRhP+kbGKaSG/gZM6RCvwhEbwmCNF06CdDiNaoHcbeg0PqkEa2GOcn8KJ0nnc7+yL7EjoYLHQ==", "license": "MIT", "dependencies": { - "@next/env": "15.4.6", + "@next/env": "15.4.10", "@swc/helpers": "0.5.15", "caniuse-lite": "^1.0.30001579", "postcss": "8.4.31", @@ -7110,14 +7212,14 @@ "node": "^18.18.0 || ^19.8.0 || >= 20.0.0" }, "optionalDependencies": { - "@next/swc-darwin-arm64": "15.4.6", - "@next/swc-darwin-x64": "15.4.6", - "@next/swc-linux-arm64-gnu": "15.4.6", - "@next/swc-linux-arm64-musl": "15.4.6", - "@next/swc-linux-x64-gnu": "15.4.6", - "@next/swc-linux-x64-musl": "15.4.6", - "@next/swc-win32-arm64-msvc": "15.4.6", - "@next/swc-win32-x64-msvc": "15.4.6", + "@next/swc-darwin-arm64": "15.4.8", + "@next/swc-darwin-x64": "15.4.8", + "@next/swc-linux-arm64-gnu": "15.4.8", + "@next/swc-linux-arm64-musl": "15.4.8", + "@next/swc-linux-x64-gnu": "15.4.8", + "@next/swc-linux-x64-musl": "15.4.8", + "@next/swc-win32-arm64-msvc": "15.4.8", + "@next/swc-win32-x64-msvc": "15.4.8", "sharp": "^0.34.3" }, "peerDependencies": { @@ -7844,6 +7946,20 @@ "integrity": "sha512-x3Ax3kNSMIIkyVYhWPyO09bu0uttcAIoecO/um/rKGQ4EltYWVYtyiGkS/3xMynrbVQdS69Jhlv8FXUEZehlzA==", "license": "MIT" }, + "node_modules/react-leaflet": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/react-leaflet/-/react-leaflet-5.0.0.tgz", + "integrity": "sha512-CWbTpr5vcHw5bt9i4zSlPEVQdTVcML390TjeDG0cK59z1ylexpqC6M1PJFjV8jD7CF+ACBFsLIDs6DRMoLEofw==", + "license": "Hippocratic-2.1", + "dependencies": { + "@react-leaflet/core": "^3.0.0" + }, + "peerDependencies": { + "leaflet": "^1.9.0", + "react": "^19.0.0", + "react-dom": "^19.0.0" + } + }, "node_modules/react-transition-group": { "version": "4.4.5", "resolved": "https://registry.npmjs.org/react-transition-group/-/react-transition-group-4.4.5.tgz", @@ -8604,6 +8720,15 @@ "integrity": "sha512-Orov6g6BB1sDfYgzWfTHDOxamtX1bE/zo104Dh9e6fqJ3PooipYyfJ0pUmrZO2wAvO8YbEyeFrkV91XTsGMSrw==", "license": "MIT" }, + "node_modules/supercluster": { + "version": "8.0.1", + "resolved": "https://registry.npmjs.org/supercluster/-/supercluster-8.0.1.tgz", + "integrity": "sha512-IiOea5kJ9iqzD2t7QJq/cREyLHTtSmUT6gQsweojg9WH2sYJqZK9SswTu6jrscO6D1G5v5vYZ9ru/eq85lXeZQ==", + "license": "ISC", + "dependencies": { + "kdbush": "^4.0.2" + } + }, "node_modules/supports-color": { "version": "8.1.1", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz", diff --git a/package.json b/package.json index 6633fe5..e7cd88f 100644 --- a/package.json +++ b/package.json @@ -22,15 +22,19 @@ "@mui/x-data-grid": "^8.10.0", "@mui/x-date-pickers": "^8.23.0", "@neondatabase/serverless": "^1.0.1", + "@react-google-maps/api": "^2.20.8", + "@types/leaflet": "^1.9.21", "dayjs": "^1.11.19", "dotenv": "^17.2.3", "drizzle-orm": "^0.44.4", + "leaflet": "^1.9.4", "next": "15.4.10", "next-auth": "^4.24.11", "notistack": "^3.0.2", "react": "19.1.0", "react-dom": "19.1.0", "react-hook-form": "^7.62.0", + "react-leaflet": "^5.0.0", "zod": "^4.0.17" }, "devDependencies": { diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 8222b83..e0af538 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -41,6 +41,12 @@ importers: '@neondatabase/serverless': specifier: ^1.0.1 version: 1.0.1 + '@react-google-maps/api': + specifier: ^2.20.8 + version: 2.20.8(react-dom@19.1.0(react@19.1.0))(react@19.1.0) + '@types/leaflet': + specifier: ^1.9.21 + version: 1.9.21 dayjs: specifier: ^1.11.19 version: 1.11.19 @@ -50,6 +56,9 @@ importers: drizzle-orm: specifier: ^0.44.4 version: 0.44.4(@neondatabase/serverless@1.0.1)(@types/pg@8.15.5) + leaflet: + specifier: ^1.9.4 + version: 1.9.4 next: specifier: 15.4.10 version: 15.4.10(react-dom@19.1.0(react@19.1.0))(react@19.1.0) @@ -68,6 +77,9 @@ importers: react-hook-form: specifier: ^7.62.0 version: 7.62.0(react@19.1.0) + react-leaflet: + specifier: ^5.0.0 + version: 5.0.0(leaflet@1.9.4)(react-dom@19.1.0(react@19.1.0))(react@19.1.0) zod: specifier: ^4.0.17 version: 4.0.17 @@ -601,6 +613,12 @@ packages: resolution: {integrity: sha512-Z5kJ+wU3oA7MMIqVR9tyZRtjYPr4OC004Q4Rw7pgOKUOKkJfZ3O24nz3WYfGRpMDNmcOi3TwQOmgm7B7Tpii0w==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + '@googlemaps/js-api-loader@1.16.8': + resolution: {integrity: sha512-CROqqwfKotdO6EBjZO/gQGVTbeDps5V7Mt9+8+5Q+jTg5CRMi3Ii/L9PmV3USROrt2uWxtGzJHORmByxyo9pSQ==} + + '@googlemaps/markerclusterer@2.5.3': + resolution: {integrity: sha512-x7lX0R5yYOoiNectr10wLgCBasNcXFHiADIBdmn7jQllF2B5ENQw5XtZK+hIw4xnV0Df0xhN4LN98XqA5jaiOw==} + '@hookform/resolvers@5.2.1': resolution: {integrity: sha512-u0+6X58gkjMcxur1wRWokA7XsiiBJ6aK17aPZxhkoYiK5J+HcTx0Vhu9ovXe6H+dVpO6cjrn2FkJTryXEMlryQ==} peerDependencies: @@ -1145,6 +1163,25 @@ packages: '@popperjs/core@2.11.8': resolution: {integrity: sha512-P1st0aksCrn9sGZhp8GMYwBnQsbvAWsZAX44oXNNvLHGqAOcoVxmjZiohstwQ7SqKnbR47akdNi+uleWD8+g6A==} + '@react-google-maps/api@2.20.8': + resolution: {integrity: sha512-wtLYFtCGXK3qbIz1H5to3JxbosPnKsvjDKhqGylXUb859EskhzR7OpuNt0LqdLarXUtZCJTKzPn3BNaekNIahg==} + peerDependencies: + react: ^16.8 || ^17 || ^18 || ^19 + react-dom: ^16.8 || ^17 || ^18 || ^19 + + '@react-google-maps/infobox@2.20.0': + resolution: {integrity: sha512-03PJHjohhaVLkX6+NHhlr8CIlvUxWaXhryqDjyaZ8iIqqix/nV8GFdz9O3m5OsjtxtNho09F/15j14yV0nuyLQ==} + + '@react-google-maps/marker-clusterer@2.20.0': + resolution: {integrity: sha512-tieX9Va5w1yP88vMgfH1pHTacDQ9TgDTjox3tLlisKDXRQWdjw+QeVVghhf5XqqIxXHgPdcGwBvKY6UP+SIvLw==} + + '@react-leaflet/core@3.0.0': + resolution: {integrity: sha512-3EWmekh4Nz+pGcr+xjf0KNyYfC3U2JjnkWsh0zcqaexYqmmB5ZhH37kz41JXGmKzpaMZCnPofBBm64i+YrEvGQ==} + peerDependencies: + leaflet: ^1.9.0 + react: ^19.0.0 + react-dom: ^19.0.0 + '@rtsao/scc@1.1.0': resolution: {integrity: sha512-zt6OdqaDoOnJ1ZYsCYGt9YmWzDXl4vQdKTyJev62gFhRGKdx7mcT54V9KIjg+d2wi9EXsPvAPKe7i7WjfVWB8g==} @@ -1163,12 +1200,21 @@ packages: '@types/estree@1.0.8': resolution: {integrity: sha512-dWHzHa2WqEXI/O1E9OjrocMTKJl2mSrEolh1Iomrv6U+JuNwaHXsXx9bLu5gG7BUWFIN0skIQJQ/L1rIex4X6w==} + '@types/geojson@7946.0.16': + resolution: {integrity: sha512-6C8nqWur3j98U6+lXDfTUWIfgvZU+EumvpHKcYjujKH7woYyLj2sUmff0tRhrqM7BohUw7Pz3ZB1jj2gW9Fvmg==} + + '@types/google.maps@3.58.1': + resolution: {integrity: sha512-X9QTSvGJ0nCfMzYOnaVs/k6/4L+7F5uCS+4iUmkLEls6J9S/Phv+m/i3mDeyc49ZBgwab3EFO1HEoBY7k98EGQ==} + '@types/json-schema@7.0.15': resolution: {integrity: sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA==} '@types/json5@0.0.29': resolution: {integrity: sha512-dRLjCWHYg4oaA77cxO64oO+7JwCwnIzkZPdrrC71jQmQtlhM556pwKo5bUzqvZndkVbeFLIIi+9TC40JNF5hNQ==} + '@types/leaflet@1.9.21': + resolution: {integrity: sha512-TbAd9DaPGSnzp6QvtYngntMZgcRk+igFELwR2N99XZn7RXUdKgsXMR+28bUO0rPsWp8MIu/f47luLIQuSLYv/w==} + '@types/node@20.19.10': resolution: {integrity: sha512-iAFpG6DokED3roLSP0K+ybeDdIX6Bc0Vd3mLW5uDqThPWtNos3E+EqOM11mPQHKzfWHqEBuLjIlsBQQ8CsISmQ==} @@ -2119,6 +2165,9 @@ packages: resolution: {integrity: sha512-4gd7VpWNQNB4UKKCFFVcp1AVv+FMOgs9NKzjHKusc8jTMhd5eL1NqQqOpE0KzMds804/yHlglp3uxgluOqAPLw==} engines: {node: '>= 0.4'} + invariant@2.2.4: + resolution: {integrity: sha512-phJfQVBuaJM5raOpJjSfkiD6BpbCE4Ns//LaXl6wGYtUBY83nWS6Rf9tXm2e8VaK60JEjYldbPif/A2B1C2gNA==} + is-array-buffer@3.0.5: resolution: {integrity: sha512-DDfANUiiG2wC1qawP66qlTugJeL5HyzMpfr8lLK+jMQirGzNod0B12cFB/9q838Ru27sBwfw78/rdoU7RERz6A==} engines: {node: '>= 0.4'} @@ -2293,6 +2342,9 @@ packages: resolution: {integrity: sha512-ZZow9HBI5O6EPgSJLUb8n2NKgmVWTwCvHGwFuJlMjvLFqlGG6pjirPhtdsseaLZjSibD8eegzmYpUZwoIlj2cQ==} engines: {node: '>=4.0'} + kdbush@4.0.2: + resolution: {integrity: sha512-WbCVYJ27Sz8zi9Q7Q0xHC+05iwkm3Znipc2XTlrnJbsHMYktW4hPhXUE8Ys1engBrvffoSCqbil1JQAa7clRpA==} + keyv@4.5.4: resolution: {integrity: sha512-oxVHkHR/EJf2CNXnWxRLW6mg7JyCCUcG0DtEGmL2ctUo1PNTin1PUil+r/+4r5MpVgC/fn1kjsx7mjSujKqIpw==} @@ -2311,6 +2363,9 @@ packages: resolution: {integrity: sha512-MbjN408fEndfiQXbFQ1vnd+1NoLDsnQW41410oQBXiyXDMYH5z505juWa4KUE1LqxRC7DgOgZDbKLxHIwm27hA==} engines: {node: '>=0.10'} + leaflet@1.9.4: + resolution: {integrity: sha512-nxS1ynzJOmOlHp+iL3FyWqK89GtNL8U8rvlMOsQdTTssxZwCXh8N2NB3GDQOL+YR3XnWyZAxwQixURb+FA74PA==} + levn@0.4.1: resolution: {integrity: sha512-+bT2uH4E5LGE7h/n3evcS/sQlJXCpIp6ym8OWJ5eV6+67Dsql/LaaT7qJBAt2rzfoa/5QBGBhxDix1dMt2kQKQ==} engines: {node: '>= 0.8.0'} @@ -2626,6 +2681,13 @@ packages: react-is@19.2.3: resolution: {integrity: sha512-qJNJfu81ByyabuG7hPFEbXqNcWSU3+eVus+KJs+0ncpGfMyYdvSmxiJxbWR65lYi1I+/0HBcliO029gc4F+PnA==} + react-leaflet@5.0.0: + resolution: {integrity: sha512-CWbTpr5vcHw5bt9i4zSlPEVQdTVcML390TjeDG0cK59z1ylexpqC6M1PJFjV8jD7CF+ACBFsLIDs6DRMoLEofw==} + peerDependencies: + leaflet: ^1.9.0 + react: ^19.0.0 + react-dom: ^19.0.0 + react-transition-group@4.4.5: resolution: {integrity: sha512-pZcd1MCJoiKiBR2NRxeCRg13uCXbydPnmB4EOeRrY7480qNWO8IIgQG6zlDkm6uRMsURXPuKq0GWtiM59a5Q6g==} peerDependencies: @@ -2845,6 +2907,9 @@ packages: stylis@4.2.0: resolution: {integrity: sha512-Orov6g6BB1sDfYgzWfTHDOxamtX1bE/zo104Dh9e6fqJ3PooipYyfJ0pUmrZO2wAvO8YbEyeFrkV91XTsGMSrw==} + supercluster@8.0.1: + resolution: {integrity: sha512-IiOea5kJ9iqzD2t7QJq/cREyLHTtSmUT6gQsweojg9WH2sYJqZK9SswTu6jrscO6D1G5v5vYZ9ru/eq85lXeZQ==} + supports-color@7.2.0: resolution: {integrity: sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==} engines: {node: '>=8'} @@ -3402,6 +3467,13 @@ snapshots: '@eslint/core': 0.15.2 levn: 0.4.1 + '@googlemaps/js-api-loader@1.16.8': {} + + '@googlemaps/markerclusterer@2.5.3': + dependencies: + fast-deep-equal: 3.1.3 + supercluster: 8.0.1 + '@hookform/resolvers@5.2.1(react-hook-form@7.62.0(react@19.1.0))': dependencies: '@standard-schema/utils': 0.3.0 @@ -3832,6 +3904,27 @@ snapshots: '@popperjs/core@2.11.8': {} + '@react-google-maps/api@2.20.8(react-dom@19.1.0(react@19.1.0))(react@19.1.0)': + dependencies: + '@googlemaps/js-api-loader': 1.16.8 + '@googlemaps/markerclusterer': 2.5.3 + '@react-google-maps/infobox': 2.20.0 + '@react-google-maps/marker-clusterer': 2.20.0 + '@types/google.maps': 3.58.1 + invariant: 2.2.4 + react: 19.1.0 + react-dom: 19.1.0(react@19.1.0) + + '@react-google-maps/infobox@2.20.0': {} + + '@react-google-maps/marker-clusterer@2.20.0': {} + + '@react-leaflet/core@3.0.0(leaflet@1.9.4)(react-dom@19.1.0(react@19.1.0))(react@19.1.0)': + dependencies: + leaflet: 1.9.4 + react: 19.1.0 + react-dom: 19.1.0(react@19.1.0) + '@rtsao/scc@1.1.0': {} '@rushstack/eslint-patch@1.12.0': {} @@ -3849,10 +3942,18 @@ snapshots: '@types/estree@1.0.8': {} + '@types/geojson@7946.0.16': {} + + '@types/google.maps@3.58.1': {} + '@types/json-schema@7.0.15': {} '@types/json5@0.0.29': {} + '@types/leaflet@1.9.21': + dependencies: + '@types/geojson': 7946.0.16 + '@types/node@20.19.10': dependencies: undici-types: 6.21.0 @@ -4945,6 +5046,10 @@ snapshots: hasown: 2.0.2 side-channel: 1.1.0 + invariant@2.2.4: + dependencies: + loose-envify: 1.4.0 + is-array-buffer@3.0.5: dependencies: call-bind: 1.0.8 @@ -5115,6 +5220,8 @@ snapshots: object.assign: 4.1.7 object.values: 1.2.1 + kdbush@4.0.2: {} + keyv@4.5.4: dependencies: json-buffer: 3.0.1 @@ -5143,6 +5250,8 @@ snapshots: dependencies: language-subtag-registry: 0.3.23 + leaflet@1.9.4: {} + levn@0.4.1: dependencies: prelude-ls: 1.2.1 @@ -5453,6 +5562,13 @@ snapshots: react-is@19.2.3: {} + react-leaflet@5.0.0(leaflet@1.9.4)(react-dom@19.1.0(react@19.1.0))(react@19.1.0): + dependencies: + '@react-leaflet/core': 3.0.0(leaflet@1.9.4)(react-dom@19.1.0(react@19.1.0))(react@19.1.0) + leaflet: 1.9.4 + react: 19.1.0 + react-dom: 19.1.0(react@19.1.0) + react-transition-group@4.4.5(react-dom@19.1.0(react@19.1.0))(react@19.1.0): dependencies: '@babel/runtime': 7.28.4 @@ -5735,6 +5851,10 @@ snapshots: stylis@4.2.0: {} + supercluster@8.0.1: + dependencies: + kdbush: 4.0.2 + supports-color@7.2.0: dependencies: has-flag: 4.0.0 diff --git a/src/app/map-test/page.tsx b/src/app/map-test/page.tsx new file mode 100644 index 0000000..d2e44d0 --- /dev/null +++ b/src/app/map-test/page.tsx @@ -0,0 +1,17 @@ +"use client"; + +import dynamic from "next/dynamic"; + +const MapComponent = dynamic(() => import("../../components/MapComp"), { ssr: false }); + +// Making it fit 30 percent of the page +export default function MapTestPage() { + return ( +
+
+
+ +
+
+ ); +} diff --git a/src/components/MapComp.tsx b/src/components/MapComp.tsx new file mode 100644 index 0000000..3f0ac7a --- /dev/null +++ b/src/components/MapComp.tsx @@ -0,0 +1,38 @@ +"use client"; + +// Doing all the imports for the map componnent +import { MapContainer, TileLayer, Marker } from "react-leaflet"; + +import "leaflet/dist/leaflet.css"; +import { useEffect, useState } from "react"; + +type LatitudeLongitudeStore = { lat: number; lng: number }; + +// For future use, making it exportable (use mapComponent)) +export default function MapComponent() { + const [center, setCenter] = useState(null); + + useEffect(() => { + if (!navigator.geolocation) { + // Using New York location as default + setCenter({ lat: 40.7128, lng: -74.0060 }); + return; + } + + navigator.geolocation.getCurrentPosition( + (pos) => setCenter({ lat: pos.coords.latitude, lng: pos.coords.longitude }), + () => setCenter({ lat: 40.7128, lng: -74.0060 }) + ); + }, []); + + // Waiting time response + if (!center) return
Loading...
; + + return ( + // Entire map container details + + + + + ); +} \ No newline at end of file From 5b714c0f800ac835f65c827ee917f01ffe4d6fc7 Mon Sep 17 00:00:00 2001 From: 12Koushik1 Date: Sat, 24 Jan 2026 22:11:09 -0500 Subject: [PATCH 2/7] Updated the map component and map component testing page --- src/app/map-test/page.tsx | 10 +++++----- src/components/MapComp.tsx | 4 ++-- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/src/app/map-test/page.tsx b/src/app/map-test/page.tsx index d2e44d0..cbe1ff5 100644 --- a/src/app/map-test/page.tsx +++ b/src/app/map-test/page.tsx @@ -8,10 +8,10 @@ const MapComponent = dynamic(() => import("../../components/MapComp"), { ssr: fa export default function MapTestPage() { return (
-
-
- -
-
+
+
+ +
+
); } diff --git a/src/components/MapComp.tsx b/src/components/MapComp.tsx index 3f0ac7a..255f963 100644 --- a/src/components/MapComp.tsx +++ b/src/components/MapComp.tsx @@ -31,8 +31,8 @@ export default function MapComponent() { return ( // Entire map container details - - + + ); } \ No newline at end of file From e5ff6686ed1e9368e397b1790588d155d99bde0f Mon Sep 17 00:00:00 2001 From: 12Koushik1 Date: Sat, 24 Jan 2026 22:23:08 -0500 Subject: [PATCH 3/7] Update2 on the map components --- src/components/MapComp.tsx | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/src/components/MapComp.tsx b/src/components/MapComp.tsx index 255f963..2e5d5fc 100644 --- a/src/components/MapComp.tsx +++ b/src/components/MapComp.tsx @@ -20,7 +20,10 @@ export default function MapComponent() { } navigator.geolocation.getCurrentPosition( - (pos) => setCenter({ lat: pos.coords.latitude, lng: pos.coords.longitude }), + (pos) => setCenter({ + lat: pos.coords.latitude, + lng: pos.coords.longitude, + }), () => setCenter({ lat: 40.7128, lng: -74.0060 }) ); }, []); @@ -30,9 +33,15 @@ export default function MapComponent() { return ( // Entire map container details - - - + + + ); } \ No newline at end of file From 4df60da2f54559357185c83f5abd62c4cd6e8e58 Mon Sep 17 00:00:00 2001 From: 12Koushik1 Date: Sun, 25 Jan 2026 23:28:55 -0500 Subject: [PATCH 4/7] Updated in MapComp.tsx and page.tsx for that --- src/components/MapComp.tsx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/components/MapComp.tsx b/src/components/MapComp.tsx index 2e5d5fc..b1648a8 100644 --- a/src/components/MapComp.tsx +++ b/src/components/MapComp.tsx @@ -10,13 +10,13 @@ type LatitudeLongitudeStore = { lat: number; lng: number }; // For future use, making it exportable (use mapComponent)) export default function MapComponent() { - const [center, setCenter] = useState(null); + const [center, setCenter] = useState(null); useEffect(() => { if (!navigator.geolocation) { // Using New York location as default - setCenter({ lat: 40.7128, lng: -74.0060 }); - return; + setCenter({ lat: 40.7128, lng: -74.0060 }); + return; } navigator.geolocation.getCurrentPosition( @@ -35,7 +35,7 @@ export default function MapComponent() { // Entire map container details Date: Wed, 4 Feb 2026 19:30:47 -0500 Subject: [PATCH 5/7] Changed the files --- src/app/map-test/page.tsx | 2 +- src/components/MapComp.tsx | 44 ++++++++++++++++++++------------------ 2 files changed, 24 insertions(+), 22 deletions(-) diff --git a/src/app/map-test/page.tsx b/src/app/map-test/page.tsx index cbe1ff5..25aa608 100644 --- a/src/app/map-test/page.tsx +++ b/src/app/map-test/page.tsx @@ -5,7 +5,7 @@ import dynamic from "next/dynamic"; const MapComponent = dynamic(() => import("../../components/MapComp"), { ssr: false }); // Making it fit 30 percent of the page -export default function MapTestPage() { +export default function MapTestPage(): React.ReactElement { return (
diff --git a/src/components/MapComp.tsx b/src/components/MapComp.tsx index b1648a8..3f57297 100644 --- a/src/components/MapComp.tsx +++ b/src/components/MapComp.tsx @@ -1,30 +1,31 @@ "use client"; // Doing all the imports for the map componnent -import { MapContainer, TileLayer, Marker } from "react-leaflet"; - import "leaflet/dist/leaflet.css"; + import { useEffect, useState } from "react"; +import { MapContainer, Marker, TileLayer } from "react-leaflet"; type LatitudeLongitudeStore = { lat: number; lng: number }; // For future use, making it exportable (use mapComponent)) -export default function MapComponent() { - const [center, setCenter] = useState(null); +export default function MapComponent(): React.ReactElement { + const [center, setCenter] = useState(null); useEffect(() => { if (!navigator.geolocation) { - // Using New York location as default - setCenter({ lat: 40.7128, lng: -74.0060 }); - return; + // Using New York location as default + setCenter({ lat: 40.7128, lng: -74.006 }); + return; } navigator.geolocation.getCurrentPosition( - (pos) => setCenter({ - lat: pos.coords.latitude, - lng: pos.coords.longitude, + (pos) => + setCenter({ + lat: pos.coords.latitude, + lng: pos.coords.longitude, }), - () => setCenter({ lat: 40.7128, lng: -74.0060 }) + () => setCenter({ lat: 40.7128, lng: -74.006 }), ); }, []); @@ -33,15 +34,16 @@ export default function MapComponent() { return ( // Entire map container details - - - + + + ); -} \ No newline at end of file +} From def0230f29e50f31cde84b38fde392576250aaab Mon Sep 17 00:00:00 2001 From: 12Koushik1 Date: Mon, 23 Feb 2026 22:08:10 -0500 Subject: [PATCH 6/7] Made the icon and tab changes --- src/app/map-test/page.tsx | 12 ++++++------ src/components/MapComp.tsx | 16 +++++++++++++--- 2 files changed, 19 insertions(+), 9 deletions(-) diff --git a/src/app/map-test/page.tsx b/src/app/map-test/page.tsx index 25aa608..2356f3f 100644 --- a/src/app/map-test/page.tsx +++ b/src/app/map-test/page.tsx @@ -7,11 +7,11 @@ const MapComponent = dynamic(() => import("../../components/MapComp"), { ssr: fa // Making it fit 30 percent of the page export default function MapTestPage(): React.ReactElement { return ( -
-
-
- -
-
+
+
+
+ +
+
); } diff --git a/src/components/MapComp.tsx b/src/components/MapComp.tsx index 3f57297..3214223 100644 --- a/src/components/MapComp.tsx +++ b/src/components/MapComp.tsx @@ -1,10 +1,20 @@ "use client"; -// Doing all the imports for the map componnent -import "leaflet/dist/leaflet.css"; - import { useEffect, useState } from "react"; import { MapContainer, Marker, TileLayer } from "react-leaflet"; +import "leaflet/dist/leaflet.css"; + +import L from "leaflet"; + +delete (L.Icon.Default.prototype as any)._getIconUrl; +L.Icon.Default.mergeOptions({ + iconRetinaUrl: + "https://unpkg.com/leaflet@1.9.4/dist/images/marker-icon-2x.png", + iconUrl: + "https://unpkg.com/leaflet@1.9.4/dist/images/marker-icon.png", + shadowUrl: + "https://unpkg.com/leaflet@1.9.4/dist/images/marker-shadow.png", +}); type LatitudeLongitudeStore = { lat: number; lng: number }; From d36a8bb887e1a8a9fca9212456db92592ac9ab3f Mon Sep 17 00:00:00 2001 From: AgustinSV Date: Tue, 24 Feb 2026 12:40:02 -0500 Subject: [PATCH 7/7] added dependecies --- package.json | 2 +- pnpm-lock.yaml | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/package.json b/package.json index e7cd88f..6363c29 100644 --- a/package.json +++ b/package.json @@ -23,7 +23,6 @@ "@mui/x-date-pickers": "^8.23.0", "@neondatabase/serverless": "^1.0.1", "@react-google-maps/api": "^2.20.8", - "@types/leaflet": "^1.9.21", "dayjs": "^1.11.19", "dotenv": "^17.2.3", "drizzle-orm": "^0.44.4", @@ -41,6 +40,7 @@ "@eslint/eslintrc": "^3", "@eslint/js": "^9.33.0", "@next/eslint-plugin-next": "^15.4.6", + "@types/leaflet": "^1.9.21", "@types/node": "^20", "@types/react": "^19", "@types/react-dom": "^19", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index e0af538..48fadb5 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -44,9 +44,6 @@ importers: '@react-google-maps/api': specifier: ^2.20.8 version: 2.20.8(react-dom@19.1.0(react@19.1.0))(react@19.1.0) - '@types/leaflet': - specifier: ^1.9.21 - version: 1.9.21 dayjs: specifier: ^1.11.19 version: 1.11.19 @@ -93,6 +90,9 @@ importers: '@next/eslint-plugin-next': specifier: ^15.4.6 version: 15.4.6 + '@types/leaflet': + specifier: ^1.9.21 + version: 1.9.21 '@types/node': specifier: ^20 version: 20.19.10