mirror of
https://git.rezel.net/LudoTech/traque.git
synced 2026-02-09 10:20:16 +01:00
added a form element and a map
This commit is contained in:
23
traque-front/components/team/map.jsx
Normal file
23
traque-front/components/team/map.jsx
Normal file
@@ -0,0 +1,23 @@
|
||||
'use client';
|
||||
import React from 'react'
|
||||
import { MapContainer, Marker, Popup, TileLayer } from 'react-leaflet'
|
||||
import 'leaflet-defaulticon-compatibility/dist/leaflet-defaulticon-compatibility.css'
|
||||
import "leaflet-defaulticon-compatibility";
|
||||
import "leaflet/dist/leaflet.css";
|
||||
|
||||
export default function LiveMap({...props}) {
|
||||
const position = [51.505, -0.09]
|
||||
return (
|
||||
<MapContainer {...props} center={position} zoom={13} scrollWheelZoom={true}>
|
||||
<TileLayer
|
||||
attribution='© <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'
|
||||
url="https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png"
|
||||
/>
|
||||
<Marker position={position}>
|
||||
<Popup>
|
||||
A pretty CSS3 popup. <br /> Easily customizable.
|
||||
</Popup>
|
||||
</Marker>
|
||||
</MapContainer>
|
||||
)
|
||||
}
|
||||
Reference in New Issue
Block a user