From fc9595e99cbff8cb3297ab36033fa918bb7eda2b Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Sat, 14 Dec 2019 06:47:21 +0100 Subject: improve wagon output in journey details --- public/service-worker.js | 26 +++++++++++++------------- public/static/css/local.css | 19 +++++++++++++++++++ public/static/css/material-icons.css | 8 ++++---- public/static/manifest.json | 12 ++++++------ public/static/v30 | 1 - public/static/v32 | 1 + templates/journey.html.ep | 8 ++++---- templates/layouts/default.html.ep | 2 +- 8 files changed, 48 insertions(+), 29 deletions(-) delete mode 120000 public/static/v30 create mode 120000 public/static/v32 diff --git a/public/service-worker.js b/public/service-worker.js index 8268bd0..1302609 100644 --- a/public/service-worker.js +++ b/public/service-worker.js @@ -1,19 +1,19 @@ -const CACHE_NAME = 'static-cache-v31'; +const CACHE_NAME = 'static-cache-v32'; const FILES_TO_CACHE = [ '/favicon.ico', '/offline.html', - '/static/v31/css/light.min.css', - '/static/v31/css/dark.min.css', - '/static/v31/css/material-icons.css', - '/static/v31/css/local.css', - '/static/v31/fonts/MaterialIcons-Regular.woff2', - '/static/v31/fonts/MaterialIcons-Regular.woff', - '/static/v31/fonts/MaterialIcons-Regular.ttf', - '/static/v31/js/jquery-3.4.1.min.js', - '/static/v31/js/materialize.min.js', - '/static/v31/js/travelynx-actions.min.js', - '/static/v31/js/autocomplete.min.js', - '/static/v31/js/geolocation.min.js', + '/static/v32/css/light.min.css', + '/static/v32/css/dark.min.css', + '/static/v32/css/material-icons.css', + '/static/v32/css/local.css', + '/static/v32/fonts/MaterialIcons-Regular.woff2', + '/static/v32/fonts/MaterialIcons-Regular.woff', + '/static/v32/fonts/MaterialIcons-Regular.ttf', + '/static/v32/js/jquery-3.4.1.min.js', + '/static/v32/js/materialize.min.js', + '/static/v32/js/travelynx-actions.min.js', + '/static/v32/js/autocomplete.min.js', + '/static/v32/js/geolocation.min.js', ]; self.addEventListener('install', (evt) => { diff --git a/public/static/css/local.css b/public/static/css/local.css index 7bb16a3..2eb14f0 100644 --- a/public/static/css/local.css +++ b/public/static/css/local.css @@ -11,6 +11,25 @@ td.cancelled { text-decoration: line-through; } +.wagons span { + margin-right: 0.5ex; + color: #808080; +} + +.wagons .wagonclass { + font-weight: bold; + color: inherit; +} + +.wagons .wagonnum { + margin-right: 0; + color: inherit; +} + +.wagons .checksum:before { + content: "-"; +} + h1 { font-size: 2.92rem; margin: 1.9466666667rem 0 1.168rem 0; diff --git a/public/static/css/material-icons.css b/public/static/css/material-icons.css index d2806ec..07005de 100644 --- a/public/static/css/material-icons.css +++ b/public/static/css/material-icons.css @@ -2,12 +2,12 @@ font-family: 'Material Icons'; font-style: normal; font-weight: 400; - src: url(/static/v31/fonts/MaterialIcons-Regular.eot); /* For IE6-8 */ + src: url(/static/v32/fonts/MaterialIcons-Regular.eot); /* For IE6-8 */ src: local('Material Icons'), local('MaterialIcons-Regular'), - url(/static/v31/fonts/MaterialIcons-Regular.woff2) format('woff2'), - url(/static/v31/fonts/MaterialIcons-Regular.woff) format('woff'), - url(/static/v31/fonts/MaterialIcons-Regular.ttf) format('truetype'); + url(/static/v32/fonts/MaterialIcons-Regular.woff2) format('woff2'), + url(/static/v32/fonts/MaterialIcons-Regular.woff) format('woff'), + url(/static/v32/fonts/MaterialIcons-Regular.ttf) format('truetype'); } .material-icons { diff --git a/public/static/manifest.json b/public/static/manifest.json index 8e67133..5a44a3f 100644 --- a/public/static/manifest.json +++ b/public/static/manifest.json @@ -3,27 +3,27 @@ "short_name": "Travelynx", "scope": "/", "icons": [{ - "src": "/static/v31/icons/icon-128x128.png", + "src": "/static/v32/icons/icon-128x128.png", "sizes": "128x128", "type": "image/png" }, { - "src": "/static/v31/icons/icon-144x144.png", + "src": "/static/v32/icons/icon-144x144.png", "sizes": "144x144", "type": "image/png" }, { - "src": "/static/v31/icons/icon-152x152.png", + "src": "/static/v32/icons/icon-152x152.png", "sizes": "152x152", "type": "image/png" }, { - "src": "/static/v31/icons/icon-192x192.png", + "src": "/static/v32/icons/icon-192x192.png", "sizes": "192x192", "type": "image/png" }, { - "src": "/static/v31/icons/icon-256x256.png", + "src": "/static/v32/icons/icon-256x256.png", "sizes": "256x256", "type": "image/png" }, { - "src": "/static/v31/icons/icon-512x512.png", + "src": "/static/v32/icons/icon-512x512.png", "sizes": "512x512", "type": "image/png" }], diff --git a/public/static/v30 b/public/static/v30 deleted file mode 120000 index 945c9b4..0000000 --- a/public/static/v30 +++ /dev/null @@ -1 +0,0 @@ -. \ No newline at end of file diff --git a/public/static/v32 b/public/static/v32 new file mode 120000 index 0000000..945c9b4 --- /dev/null +++ b/public/static/v32 @@ -0,0 +1 @@ +. \ No newline at end of file diff --git a/templates/journey.html.ep b/templates/journey.html.ep index ff5bc12..976dc4d 100644 --- a/templates/journey.html.ep +++ b/templates/journey.html.ep @@ -179,7 +179,7 @@ <%= $station->[0] %> % } % else { - <%= $station->[0] %> + <%= $station->[0] %> % } % if ($journey->{edited} & 0x0010) { ∗ @@ -191,12 +191,12 @@ % if ($journey->{user_data} and $journey->{user_data}{wagons}) { Rollmaterial - + % for my $wagongroup (@{$journey->{user_data}{wagongroups} // []}) { - Gruppe <%= $wagongroup %>
+ Wagenverbund <%= $wagongroup %>
% } % for my $wagon (@{$journey->{user_data}{wagons}}) { - <%= substr($wagon->{id}, 0, 2) %><%= substr($wagon->{id}, 2, 2) %><%= substr($wagon->{id}, 4, 1) %><%= substr($wagon->{id}, 5, 3) %><%= substr($wagon->{id}, 8, 3) %><%= substr($wagon->{id}, 11) %> + <%= substr($wagon->{id}, 0, 2) %><%= substr($wagon->{id}, 2, 2) %><%= substr($wagon->{id}, 4, 1) %><%= substr($wagon->{id}, 5, 3) %><%= substr($wagon->{id}, 8, 3) %><%= substr($wagon->{id}, 11) %> %= $wagon->{type} % if ($wagon->{number}) { – Wagen <%= $wagon->{number} %> diff --git a/templates/layouts/default.html.ep b/templates/layouts/default.html.ep index 51ffc46..bd9bf8d 100644 --- a/templates/layouts/default.html.ep +++ b/templates/layouts/default.html.ep @@ -10,7 +10,7 @@ % while (my ($key, $value) = each %{stash('twitter') // {}}) { % } - % my $av = 'v31'; # asset version + % my $av = 'v32'; # asset version -- cgit v1.2.3