forked from PSASCapstone2013/rttv
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
show mbtiles in browser with leaflet
- Loading branch information
Showing
9 changed files
with
562 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
*.mbtiles |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
class Map extends Widget | ||
constructor: (id, @node) -> | ||
super(id) | ||
|
||
update: (d) -> | ||
return |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
.map { padding: 20px; } | ||
.map h2 { margin-top: -5px; margin-bottom: 8px; font-weight: bold; color: #333; } | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
{% autoescape None %} | ||
<div class="map"> | ||
<h2>{{ name }}</h2> | ||
<div id="maptile" style="width:600px;height:500px;"></div> | ||
|
||
<script> | ||
var map = L.map('maptile').setView([43.798806, -120.650155], 13); | ||
|
||
L.tileLayer('/maps/brothers/{z}/{x}/{y}/', { | ||
maxZoom: 20, | ||
}).addTo(map); | ||
|
||
</script> | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
[ | ||
{ | ||
"type": "map", "name": "Tactical Map", | ||
"x": 1, "y": 1, "sx":5, "sy": 4 | ||
} | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.