2025-07-30 11:16:21 -07:00
|
|
|
import React from "react";
|
|
|
|
|
import { MapContainer, TileLayer, Marker, Popup } from "react-leaflet";
|
|
|
|
|
import 'leaflet/dist/leaflet.css';
|
|
|
|
|
|
|
|
|
|
const position = [51.505, -0.09]; // [latitude, longitude]
|
2025-07-23 12:03:06 -07:00
|
|
|
|
|
|
|
|
export default function GlobalMapCanvas() {
|
2025-07-30 11:16:21 -07:00
|
|
|
return (
|
|
|
|
|
<MapContainer center={position} zoom={13} style={{ height: "100%", width: "100%" }}>
|
|
|
|
|
<TileLayer
|
|
|
|
|
url="https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png"
|
|
|
|
|
attribution='© OpenStreetMap contributors'
|
|
|
|
|
/>
|
|
|
|
|
<Marker position={position}>
|
|
|
|
|
<Popup>
|
|
|
|
|
A sample popup!
|
|
|
|
|
</Popup>
|
|
|
|
|
</Marker>
|
|
|
|
|
</MapContainer>
|
|
|
|
|
);
|
2025-07-23 12:03:06 -07:00
|
|
|
}
|