mirror of
https://github.com/Leaflet/Leaflet.git
synced 2025-12-08 21:26:14 +00:00
Signed-off-by: Jon Koops <jonkoops@gmail.com> Co-authored-by: Florian Bischof <design.falke@gmail.com>
39 lines
948 B
HTML
39 lines
948 B
HTML
<!doctype html>
|
|
<html>
|
|
<head>
|
|
<meta charset="utf-8" />
|
|
<title>Leaflet debug page - RTL</title>
|
|
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=0" />
|
|
<link rel="stylesheet" href="../../dist/leaflet.css" />
|
|
<link rel="stylesheet" href="../css/screen.css" />
|
|
<style>
|
|
body {
|
|
direction: rtl;
|
|
}
|
|
</style>
|
|
<script type="importmap">
|
|
{
|
|
"imports": {
|
|
"leaflet": "../../dist/leaflet-src.js"
|
|
}
|
|
}
|
|
</script>
|
|
</head>
|
|
<body>
|
|
<p>Click the map to place a popup at the mouse location</p>
|
|
<div id="map"></div>
|
|
<script type="module">
|
|
import {Map, TileLayer, Popup} from 'leaflet';
|
|
|
|
const osm = new TileLayer('https://tile.openstreetmap.org/{z}/{x}/{y}.png');
|
|
const map = new Map('map')
|
|
.setView([50.5, 30.51], 15)
|
|
.addLayer(osm);
|
|
|
|
map.on('click', (e) => {
|
|
new Popup().setLatLng(e.latlng).setContent('Hello').openOn(map);
|
|
});
|
|
</script>
|
|
</body>
|
|
</html>
|