leaflet-ui

esm Styles
Leaflet presets for common user interface customizations
Version 0.6.0 License GPL-3.0
Keywords
leafletmapdefault-uicontrolslayers
INSTALL
Type:
Version:
- Static
- Latest Patch
- Latest Minor
- Latest Major
- 0.6.0
- 0.5.9
- 0.5.8
- 0.5.7
- 0.5.6
- 0.5.5
- 0.5.4
- 0.5.3
- 0.5.2
- 0.5.1
- 0.5.0
- 0.4.8
- 0.4.7
- 0.4.6
- 0.4.5
- 0.4.4
- 0.4.3
- 0.4.2
- 0.4.1
- 0.4.0
- 0.3.9
- 0.3.7
- 0.3.6
- 0.3.5
- 0.3.4
- 0.3.3
- 0.3.2
- 0.3.1
- 0.3.0
- 0.2.9
- 0.2.8
- 0.2.7
- 0.2.6
- 0.2.5
- 0.2.4
- 0.2.3
- 0.2.2
- 0.2.1
- 0.2.0
- 0.1.9
- 0.1.8
- 0.1.7
- 0.1.6
- 0.1.5
- 0.1.4
- 0.1.3
- 0.1.2
- 0.1.1
- 0.1.0
- 0.0.9
- 0.0.7
- 0.0.6
- 0.0.5
- 0.0.4
- 0.0.3
- 0.0.2
- 0.0.1
<link href=" https://cdn.jsdelivr.net/npm/leaflet-ui@0.6.0/dist/leaflet-ui.min.css " rel="stylesheet">
No default CSS file set by the package author so the URL is guessed. You can always browse all package files to use another one.
leaflet-ui
Leaflet presets for common user interface customizations
For a working example see demo
How to use
- include CSS & JavaScript
<head> ... <style> html, body, #map { height: 100%; width: 100%; padding: 0; margin: 0; } </style> <!-- Leaflet --> <script src="https://unpkg.com/leaflet@1.6.0/dist/leaflet.js"></script> <!-- Leaflet-UI --> <script src="https://unpkg.com/leaflet-ui@latest/dist/leaflet-ui.js"></script> ... </head>
- choose a div container used for the slippy map
<body> ... <div id="map"></div> ... </body>
- create your first simple “leaflet-ui” slippy map
<script> var map = L.map('map', { center: [41.4583, 12.7059], zoom: 5, // Optional customizations mapTypeId: 'topo', mapTypeIds: ['streets', 'terrain', 'satellite', 'topo'], gestureHandling: true, zoomControl: true, pegmanControl: true, locateControl: true, fullscreenControl: true, layersControl: true, minimapControl: true, editInOSMControl: true, loadingControl: true, searchControl: true, disableDefaultUI: false, // Experimental feature rotate: true, }); map.once('idle',function(){ /* Waiting for map init */}); </script>
Compatibile with: leaflet@1.6.0
Contributors: Raruto