Update currentweather.js

This commit is contained in:
roxasvalor 2016-04-24 17:40:18 -05:00
parent 77cb8530e5
commit 8d29bd5c32

View File

@ -19,7 +19,7 @@ Module.register("currentweather",{
timeFormat: config.timeFormat, timeFormat: config.timeFormat,
showPeriod: true, showPeriod: true,
showPeriodUpper: false, showPeriodUpper: false,
showDirection: false, showDirection: true,
lang: config.language, lang: config.language,
initialLoadDelay: 0, // 0 seconds delay initialLoadDelay: 0, // 0 seconds delay
@ -110,15 +110,17 @@ Module.register("currentweather",{
var windIcon = document.createElement("span"); var windIcon = document.createElement("span");
windIcon.className = "wi wi-strong-wind dimmed"; windIcon.className = "wi wi-strong-wind dimmed";
small.appendChild(windIcon); small.appendChild(windIcon);
var windSpeed = document.createElement("span"); var windSpeed = document.createElement("span");
windSpeed.innerHTML = " " + this.windSpeed; windSpeed.innerHTML = " " + this.windSpeed;
small.appendChild(windSpeed); small.appendChild(windSpeed);
var windDirection = document.createElement("span"); if (this.showDirection) {
windDirection.innerHTML = " " + this.windDirection; var windDirection = document.createElement("span");
small.appendChild(windDirection); windDirection.innerHTML = " " + this.windDirection;
small.appendChild(windDirection);
}
var spacer = document.createElement("span"); var spacer = document.createElement("span");
spacer.innerHTML = " "; spacer.innerHTML = " ";
small.appendChild(spacer); small.appendChild(spacer);
@ -318,7 +320,7 @@ Module.register("currentweather",{
}else{ }else{
return "N"; return "N";
} }
} },
roundValue: function(temperature) { roundValue: function(temperature) {