Always show travel time and energy

Always show the entries for travel time and energy in the statistics
bar, so the layout does not suddenly change when starting to draw a route.
This commit is contained in:
Henrik Fehlauer 2019-07-01 20:46:41 +02:00
parent 929d6bf523
commit 632e094fb3
2 changed files with 2 additions and 8 deletions

View file

@ -966,7 +966,7 @@
>
</p>
</li>
<li hidden>
<li>
<div
class="text-muted small d-none d-sm-block"
data-i18n="footer.travel-time"
@ -982,7 +982,7 @@
>
</p>
</li>
<li hidden>
<li>
<div class="text-muted small d-none d-sm-block">
<span data-i18n="footer.total-energy"
>Total Energy</span

View file

@ -56,12 +56,6 @@ BR.TrackStats = L.Class.extend({
$('#totaltime').html(formattedTime);
$('#totalenergy').html(formattedEnergy);
$('#meanenergy').html(meanEnergy);
document.getElementById(
'totaltime'
).parentElement.parentElement.hidden = !stats.totalTime;
document.getElementById(
'totalenergy'
).parentElement.parentElement.hidden = !stats.totalEnergy;
},
calcStats: function(polyline, segments) {