davvalent commited on 2021-11-15 05:21:26
Showing 6 changed files, with 71 additions and 0 deletions.
| ... | ... |
@@ -0,0 +1 @@ |
| 1 |
+node_modules/ |
| ... | ... |
@@ -0,0 +1,34 @@ |
| 1 |
+<!DOCTYPE html> |
|
| 2 |
+<html xmlns="http://www.w3.org/1999/xhtml" lang="fr-CA"> |
|
| 3 |
+ <head> |
|
| 4 |
+ <meta charset="utf-8"/> |
|
| 5 |
+ <meta name="viewport" content="width=device-width, initial-scale=1.0"/> |
|
| 6 |
+ <title>Plan - Faubourg à m'lasse</title> |
|
| 7 |
+ <link rel="stylesheet" href="node_modules/leaflet/dist/leaflet.css"/> |
|
| 8 |
+ <link rel="stylesheet" href="css/style.css"/> |
|
| 9 |
+ <script> |
|
| 10 |
+ h = window.innerHeight + "px"; |
|
| 11 |
+ document.styleSheets[1].cssRules[1].style.height = h; |
|
| 12 |
+ </script> |
|
| 13 |
+ <script src="node_modules/leaflet/dist/leaflet.js"></script> |
|
| 14 |
+ </head> |
|
| 15 |
+ <body> |
|
| 16 |
+ <div id="map"></div> |
|
| 17 |
+ <script> |
|
| 18 |
+ var mymap = L.map('map').setView([45.51823567357893, -73.55085910368373], 18);
|
|
| 19 |
+ L.tileLayer('https://api.mapbox.com/styles/v1/{id}/tiles/{z}/{x}/{y}?access_token={accessToken}', {
|
|
| 20 |
+ attribution: 'Map data © <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors, Imagery © <a href="https://www.mapbox.com/">Mapbox</a>', |
|
| 21 |
+ maxZoom: 20, |
|
| 22 |
+ id: 'mapbox/streets-v11', |
|
| 23 |
+ tileSize: 512, |
|
| 24 |
+ zoomOffset: -1, |
|
| 25 |
+ accessToken: 'pk.eyJ1IjoiZGF2dmFsZW50IiwiYSI6ImNrdmluZjh6cTBnYjkydXFna3lnOWRwM3oifQ.7qwZCUJ2JW2WFJ8JtDQfUg' |
|
| 26 |
+ }).addTo(mymap); |
|
| 27 |
+ var imageUrl = 'plan-fond-transparent-min.png', |
|
| 28 |
+ imageBounds = [[45.5155088875666, -73.55432183482827], [45.52127103906887, -73.54793549518355]]; |
|
| 29 |
+ L.imageOverlay(imageUrl, imageBounds, {
|
|
| 30 |
+ opacity: 0.75 |
|
| 31 |
+ }).addTo(mymap); |
|
| 32 |
+ </script> |
|
| 33 |
+ </body> |
|
| 34 |
+</html> |
| ... | ... |
@@ -0,0 +1,24 @@ |
| 1 |
+{
|
|
| 2 |
+ "name": "leaflet-test", |
|
| 3 |
+ "lockfileVersion": 2, |
|
| 4 |
+ "requires": true, |
|
| 5 |
+ "packages": {
|
|
| 6 |
+ "": {
|
|
| 7 |
+ "dependencies": {
|
|
| 8 |
+ "leaflet": "^1.7.1" |
|
| 9 |
+ } |
|
| 10 |
+ }, |
|
| 11 |
+ "node_modules/leaflet": {
|
|
| 12 |
+ "version": "1.7.1", |
|
| 13 |
+ "resolved": "https://registry.npmjs.org/leaflet/-/leaflet-1.7.1.tgz", |
|
| 14 |
+ "integrity": "sha512-/xwPEBidtg69Q3HlqPdU3DnrXQOvQU/CCHA1tcDQVzOwm91YMYaILjNp7L4Eaw5Z4sOYdbBz6koWyibppd8Zqw==" |
|
| 15 |
+ } |
|
| 16 |
+ }, |
|
| 17 |
+ "dependencies": {
|
|
| 18 |
+ "leaflet": {
|
|
| 19 |
+ "version": "1.7.1", |
|
| 20 |
+ "resolved": "https://registry.npmjs.org/leaflet/-/leaflet-1.7.1.tgz", |
|
| 21 |
+ "integrity": "sha512-/xwPEBidtg69Q3HlqPdU3DnrXQOvQU/CCHA1tcDQVzOwm91YMYaILjNp7L4Eaw5Z4sOYdbBz6koWyibppd8Zqw==" |
|
| 22 |
+ } |
|
| 23 |
+ } |
|
| 24 |
+} |