mirror of
https://github.com/MichMich/MagicMirror.git
synced 2025-06-27 03:39:55 +00:00
commit
067ef7ecba
@ -84,14 +84,14 @@ weather.updateCurrentWeather = function () {
|
||||
|
||||
$(this.temperatureLocation).updateWithText(_newTempHtml, this.fadeInterval);
|
||||
|
||||
var _now = moment(),
|
||||
var _now = moment().format('HH:mm'),
|
||||
_sunrise = moment(data.sys.sunrise*1000).format('HH:mm'),
|
||||
_sunset = moment(data.sys.sunset*1000).format('HH:mm');
|
||||
|
||||
var _newWindHtml = '<span class="wi wi-strong-wind xdimmed"></span> ' + this.kmh2Beaufort(_wind),
|
||||
_newSunHtml = '<span class="wi wi-sunrise xdimmed"></span> ' + _sunrise;
|
||||
|
||||
if (_sunrise < _now && _sunset > now) {
|
||||
if (_sunrise < _now && _sunset > _now) {
|
||||
_newSunHtml = '<span class="wi wi-sunset xdimmed"></span> ' + _sunset;
|
||||
}
|
||||
|
||||
@ -165,4 +165,4 @@ weather.init = function () {
|
||||
this.updateWeatherForecast();
|
||||
}.bind(this), this.updateInterval);
|
||||
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user