diff options
Diffstat (limited to 'iss/templates/passes.html')
| -rw-r--r-- | iss/templates/passes.html | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/iss/templates/passes.html b/iss/templates/passes.html index d89dbef..39478d4 100644 --- a/iss/templates/passes.html +++ b/iss/templates/passes.html @@ -7,6 +7,7 @@ {% block content %} <div id="passes"> <p class="f3">Passes for {{ location.lat }}, {{ location.lng }}</p> + <p class="f4">Times localized for <span class="light-gray">[[ tz.name ]]</span> (UTC[[ tz.offset ]])</p> <table class="tl pa1 w-100"> <tr class="pa1 f3"> <th colspan="1">Total</th> @@ -67,6 +68,13 @@ hour12: false }, computed: { + tz: function() { + var offset = new Date().getTimezoneOffset() / -60; + return { + "name": Intl.DateTimeFormat().resolvedOptions().timeZone, + "offset": offset >= 0 ? "+" + offset : offset + } + }, localizedPredictions: function() { var hour12 = this.hour12; var preds = this.predictions.map(function(p) { |
