Skip to content
This repository was archived by the owner on Jul 10, 2024. It is now read-only.

Commit 5229086

Browse files
committed
Use rentina r, wikimedia maps as default out of box, update lib momentjs & build tools
1 parent a0bbcdd commit 5229086

File tree

5 files changed

+629
-463
lines changed

5 files changed

+629
-463
lines changed

app.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,11 @@
11
'use strict';
22

33
require.config({
4-
baseUrl: 'lib',
54
paths: {
65
'polyglot': '../node_modules/node-polyglot/build/polyglot',
76
'Navigo': '../node_modules/navigo/lib/navigo',
87
'leaflet': '../node_modules/leaflet/dist/leaflet',
9-
'moment': '../node_modules/moment/moment',
8+
'moment': '../node_modules/moment/min/moment.min',
109
// d3 modules indirect dependencies
1110
// by d3-zoom: d3-drag
1211
'd3-ease': '../node_modules/d3-ease/dist/d3-ease',

config.js

Lines changed: 3 additions & 53 deletions
Original file line numberDiff line numberDiff line change
@@ -49,65 +49,15 @@ module.exports = function () {
4949
'siteName': 'Freifunk Regensburg',
5050
'mapLayers': [
5151
{
52-
'name': 'Freifunk Regensburg',
52+
'name': 'Wikimedia OSM Map',
5353
// Please ask Freifunk Regensburg before using its tile server c- example with retina tiles
54-
'url': 'https://{s}.tiles.ffrgb.net/{z}/{x}/{y}{retina}.png',
54+
'url': 'https://maps.wikimedia.org/osm-intl/{z}/{x}/{y}{r}.png',
5555
'config': {
5656
'maxZoom': 20,
5757
'subdomains': '1234',
58-
'attribution': '<a href="http://www.openmaptiles.org/" target="_blank">&copy; OpenMapTiles</a> <a href="http://www.openstreetmap.org/about/" target="_blank">&copy; OpenStreetMap contributors</a>',
58+
'attribution': '<a href="https://wikimediafoundation.org/wiki/Maps_Terms_of_Use" rel="noopener" target="_blank">Wikimedia maps</a><a href="http://www.openmaptiles.org/" target="_blank">&copy; OpenMapTiles</a> <a href="http://www.openstreetmap.org/about/" target="_blank" rel="noopener">&copy; OpenStreetMap contributors</a>',
5959
'start': 6
6060
}
61-
},
62-
{
63-
'name': 'Freifunk Regensburg Night',
64-
// Please ask Freifunk Regensburg before using its tile server - example with retina and dark tiles
65-
'url': 'https://{s}.tiles.ffrgb.net/n/{z}/{x}/{y}{retina}.png',
66-
'config': {
67-
'maxZoom': 20,
68-
'subdomains': '1234',
69-
'attribution': ' <a href="http://www.openmaptiles.org/" target="_blank">&copy; OpenMapTiles</a> <a href="http://www.openstreetmap.org/about/" target="_blank">&copy; OpenStreetMap contributors</a>',
70-
'mode': 'night',
71-
'start': 19,
72-
'end': 7
73-
}
74-
},
75-
{
76-
'name': 'OpenStreetMap.HOT',
77-
'url': 'https://{s}.tile.openstreetmap.fr/hot/{z}/{x}/{y}.png',
78-
'config': {
79-
'maxZoom': 19,
80-
'attribution': '&copy; Openstreetmap France | &copy; <a href="http://www.openstreetmap.org/copyright">OpenStreetMap</a>'
81-
}
82-
},
83-
{
84-
'name': 'HERE',
85-
// Please use your own API key - Free plan is on right side after the pay plans
86-
'url': 'https://{s}.base.maps.api.here.com/maptile/2.1/maptile/newest/normal.day/{z}/{x}/{y}/256/png8?app_id=YOUR_KEY&app_code=YOUR_CODE&lg=deu',
87-
'config': {
88-
'attribution': 'Map &copy; 1987-2014 <a href="http://developer.here.com">HERE</a>',
89-
'subdomains': '1234',
90-
'maxZoom': 20
91-
}
92-
},
93-
{
94-
'name': 'Esri.WorldImagery',
95-
'url': '//server.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer/tile/{z}/{y}/{x}',
96-
'config': {
97-
'maxZoom': 20,
98-
'attribution': 'Tiles &copy; Esri &mdash; Source: Esri, i-cubed, USDA, USGS, AEX, GeoEye, Getmapping, Aerogrid, IGN, IGP, UPR-EGP, and the GIS User Community'
99-
}
100-
},
101-
{
102-
'name': 'HERE.hybridDay',
103-
// Please use your own API key - Free plan is on right side after the pay plans
104-
'url': 'https://{s}.aerial.maps.api.here.com/maptile/2.1/maptile/newest/{variant}/{z}/{x}/{y}/256/png8?app_id=YOUR_KEY&app_code=YOUR_CODE&lg=deu',
105-
'config': {
106-
'attribution': 'Map &copy; 1987-2014 <a href="http://developer.here.com">HERE</a>',
107-
'subdomains': '1234',
108-
'variant': 'hybrid.day',
109-
'maxZoom': 20
110-
}
11161
}
11262
],
11363
// Set a visible frame

lib/map.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ define(['map/clientlayer', 'map/labellayer', 'map/button', 'leaflet', 'map/activ
6363
var layers = config.mapLayers.map(function (d) {
6464
return {
6565
'name': d.name,
66-
'layer': L.tileLayer(d.url.replace('{retina}', L.Browser.retina ? '@2x' : ''), d.config)
66+
'layer': L.tileLayer(d.url, d.config)
6767
};
6868
});
6969

package.json

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,14 +13,14 @@
1313
"babel-eslint": "^10.0.1",
1414
"browser-sync": "^2.26.5",
1515
"del": "^5.1.0",
16-
"eslint": "^6.8.0",
16+
"eslint": "^7.1.0",
1717
"eslint-config-airbnb-es5": "^1.2.0",
1818
"eslint-config-defaults": "^9.0.0",
19-
"eslint-plugin-react": "^7.17.0",
19+
"eslint-plugin-react": "^7.20.0",
2020
"gulp": "^4.0.1",
2121
"gulp-autoprefixer": "^7.0.1",
2222
"gulp-cache-bust": "^1.4.0",
23-
"gulp-cli": "^2.2.0",
23+
"gulp-cli": "^2.2.1",
2424
"gulp-environments": "^1.0.0",
2525
"gulp-eslint": "^6.0.0",
2626
"gulp-htmlmin": "^5.0.1",
@@ -30,11 +30,11 @@
3030
"gulp-load-plugins": "^2.0.1",
3131
"gulp-real-favicon": "^0.3.2",
3232
"gulp-requirejs-optimize": "^1.3.0",
33-
"gulp-sass": "^4.0.2",
33+
"gulp-sass": "^4.1.0",
3434
"gulp-sourcemaps": "^2.6.5",
3535
"gulp-stylelint": "^13.0.0",
3636
"gulp-uglify": "^3.0.2",
37-
"stylelint": "^13.3.2",
37+
"stylelint": "^13.5.0",
3838
"stylelint-config-standard": "^20.0.0"
3939
},
4040
"eslintConfig": {
@@ -52,7 +52,7 @@
5252
"d3-selection": "^1.4.0",
5353
"d3-zoom": "^1.8.3",
5454
"leaflet": "^1.5.1",
55-
"moment": "^2.24.0",
55+
"moment": "^2.26.0",
5656
"navigo": "^7.1.2",
5757
"node-polyglot": "2.2.2",
5858
"promise-polyfill": "^8.1.3",

0 commit comments

Comments
 (0)