gtfs-to-html 2.9.14 → 2.10.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +3 -1
- package/config-sample.json +0 -1
- package/dist/app/index.js +104 -55
- package/dist/app/index.js.map +1 -1
- package/dist/bin/gtfs-to-html.js +29 -17
- package/dist/bin/gtfs-to-html.js.map +1 -1
- package/dist/index.d.ts +3 -3
- package/dist/index.js +29 -17
- package/dist/index.js.map +1 -1
- package/package.json +10 -11
- package/views/default/css/overview_styles.css +11 -9
- package/views/default/css/timetable_styles.css +17 -15
- package/views/default/formatting_functions.pug +2 -1
- package/views/default/js/system-map.js +492 -400
- package/views/default/js/timetable-map.js +390 -286
- package/views/default/overview.pug +3 -4
- package/views/default/overview_full.pug +4 -4
- package/views/default/timetablepage.pug +1 -1
- package/views/default/timetablepage_full.pug +2 -4
|
@@ -21,7 +21,6 @@ include formatting_functions.pug
|
|
|
21
21
|
|
|
22
22
|
//- Use !{variable} format to inject values from pug to client side js
|
|
23
23
|
script.
|
|
24
|
-
(
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
})();
|
|
24
|
+
const geojson = !{JSON.stringify(geojson) || '\'\''};
|
|
25
|
+
const mapStyleUrl = '#{config.mapStyleUrl}';
|
|
26
|
+
createSystemMap();
|
|
@@ -6,11 +6,11 @@ block extraHeader
|
|
|
6
6
|
if config.showMap
|
|
7
7
|
script(src="https://unpkg.com/jquery@3.7.1/dist/jquery.min.js" crossorigin="anonymous")
|
|
8
8
|
script(src="https://unpkg.com/lodash@4.17.21/lodash.min.js" crossorigin="anonymous")
|
|
9
|
-
script(src="https://
|
|
10
|
-
script.
|
|
11
|
-
mapboxgl.accessToken = '#{config.mapboxAccessToken}';
|
|
9
|
+
script(src="https://unpkg.com/maplibre-gl@^4.7.1/dist/maplibre-gl.js")
|
|
10
|
+
script(src="https://unpkg.com/@maplibre/maplibre-gl-geocoder@1.5.0/dist/maplibre-gl-geocoder.min.js")
|
|
12
11
|
script(src=`${config.assetPath}js/system-map.js`)
|
|
13
12
|
|
|
14
|
-
link(href="https://
|
|
13
|
+
link(href="https://unpkg.com/maplibre-gl@^4.7.1/dist/maplibre-gl.css" rel="stylesheet")
|
|
14
|
+
link(href="https://unpkg.com/@maplibre/maplibre-gl-geocoder@1.5.0/dist/maplibre-gl-geocoder.css" rel="stylesheet")
|
|
15
15
|
|
|
16
16
|
link(rel="stylesheet" href=`${config.assetPath}css/overview_styles.css`)
|
|
@@ -68,5 +68,5 @@ include formatting_functions.pug
|
|
|
68
68
|
|
|
69
69
|
if config.showMap
|
|
70
70
|
script.
|
|
71
|
-
const { routeData, stopData, pageData: { routeIds, tripIds, stopIds, geojsons
|
|
71
|
+
const { gtfsRealtimeUrls, mapStyleUrl, routeData, stopData, pageData: { routeIds, tripIds, stopIds, geojsons } } = !{JSON.stringify(prepareMapData(timetablePage, config))};
|
|
72
72
|
createMaps();
|
|
@@ -13,10 +13,8 @@ block extraHeader
|
|
|
13
13
|
script(src=`${config.assetPath}js/gtfs-realtime.browser.proto.js`)
|
|
14
14
|
|
|
15
15
|
if config.showMap
|
|
16
|
-
link(href="https://
|
|
17
|
-
script(src="https://
|
|
18
|
-
script.
|
|
19
|
-
mapboxgl.accessToken = '#{config.mapboxAccessToken}';
|
|
16
|
+
link(href="https://unpkg.com/maplibre-gl@^4.7.1/dist/maplibre-gl.css" rel="stylesheet")
|
|
17
|
+
script(src="https://unpkg.com/maplibre-gl@^4.7.1/dist/maplibre-gl.js")
|
|
20
18
|
script(src=`${config.assetPath}js/timetable-map.js`)
|
|
21
19
|
|
|
22
20
|
if config.hasGtfsRealtimeAlerts
|