Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ENH: Switch to stamen basemaps #148

Merged
merged 2 commits into from
Jun 7, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

- added support for specifying host IP address to listen on using the `--host`
option (#138).
- switched basemaps to [Stamen map tiles](http://maps.stamen.com/) (#148)

## 0.8.2

Expand Down
30 changes: 10 additions & 20 deletions handlers/templates/map.html
Original file line number Diff line number Diff line change
Expand Up @@ -54,42 +54,32 @@

var basemaps = [
L.tileLayer(
"//{s}.arcgisonline.com/ArcGIS/rest/services/World_Topo_Map/MapServer/tile/{z}/{y}/{x}",
"https://stamen-tiles.a.ssl.fastly.net/toner-lite/{z}/{x}/{y}.png",
{
attribution:
"Tiles © Esri — Esri, DeLorme, NAVTEQ, TomTom, Intermap, iPC, USGS, FAO, NPS, NRCAN, GeoBase, Kadaster NL, Ordnance Survey, Esri Japan, METI, Esri China (Hong Kong), and the GIS User Community",
'Map tiles by <a href="http://stamen.com">Stamen Design</a>, under <a href="http://creativecommons.org/licenses/by/3.0">CC BY 3.0</a>. Data by <a href="http://openstreetmap.org">OpenStreetMap</a>, under <a href="http://www.openstreetmap.org/copyright">ODbL</a>.',
subdomains: ["server", "services"],
label: "ESRI Topo"
label: "Stamen Toner Lite"
}
),
L.tileLayer(
"//server.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer/tile/{z}/{y}/{x}",
"https://stamen-tiles.a.ssl.fastly.net/toner/{z}/{x}/{y}.png",
{
attribution:
"Tiles &copy; Esri &mdash; Source: Esri, i-cubed, USDA, USGS, AEX, GeoEye, Getmapping, Aerogrid, IGN, IGP, UPR-EGP, and the GIS User Community",
label: "ESRI Imagery"
}
),
L.tileLayer(
"//{s}.arcgisonline.com/ArcGIS/rest/services/Canvas/World_Light_Gray_Base/MapServer/tile/{z}/{y}/{x}",
{
attribution:
"Tiles &copy; Esri &mdash; Esri, DeLorme, NAVTEQ",
maxZoom: 16,
'Map tiles by <a href="http://stamen.com">Stamen Design</a>, under <a href="http://creativecommons.org/licenses/by/3.0">CC BY 3.0</a>. Data by <a href="http://openstreetmap.org">OpenStreetMap</a>, under <a href="http://www.openstreetmap.org/copyright">ODbL</a>.',
subdomains: ["server", "services"],
label: "ESRI Gray"
label: "Stamen Toner Lite"
}
),
L.tileLayer(
"//{s}.arcgisonline.com/arcgis/rest/services/Elevation/World_Hillshade/MapServer/tile/{z}/{y}/{x}",
"https://stamen-tiles.a.ssl.fastly.net/terrain/{z}/{x}/{y}.png",
{
attribution:
"Esri, USGS, NGA, NASA, CGIAR, N Robinson, NCEAS, NLS, OS, NMA, Geodatastyrelsen, Rijkswaterstaat, GSA, Geoland, FEMA, Intermap and the GIS user community",
maxZoom: 23,
'Map tiles by <a href="http://stamen.com">Stamen Design</a>, under <a href="http://creativecommons.org/licenses/by/3.0">CC BY 3.0</a>. Data by <a href="http://openstreetmap.org">OpenStreetMap</a>, under <a href="http://www.openstreetmap.org/copyright">ODbL</a>.',
subdomains: ["server", "services"],
label: "ESRI Elevation"
label: "Stamen Toner Lite"
}
)
),
];

var map = L.map("Map", {});
Expand Down
4 changes: 2 additions & 2 deletions handlers/templates/map_gl.html
Original file line number Diff line number Diff line change
Expand Up @@ -31,11 +31,11 @@
var basemapSource = {
type: "raster",
tiles: [
"//server.arcgisonline.com/ArcGIS/rest/services/World_Topo_Map/MapServer/tile/{z}/{y}/{x}"
"https://stamen-tiles.a.ssl.fastly.net/toner-lite/{z}/{x}/{y}.png"
],
tileSize: 256,
attribution:
"Tiles &copy; Esri &mdash; Source: USGS, Esri, TANA, DeLorme, and NPS"
'Map tiles by <a href="http://stamen.com">Stamen Design</a>, under <a href="http://creativecommons.org/licenses/by/3.0">CC BY 3.0</a>. Data by <a href="http://openstreetmap.org">OpenStreetMap</a>, under <a href="http://www.openstreetmap.org/copyright">ODbL</a>.',
};
var basemapStyle = {
id: "basemap",
Expand Down