Update comments
This commit is contained in:
parent
ba7c831013
commit
4ca2733199
@ -1,10 +1,8 @@
|
||||
:root {
|
||||
/*
|
||||
Colors
|
||||
Colors - pulled from https://nipponcolors.com
|
||||
|
||||
Values pulled from https://nipponcolors.com
|
||||
|
||||
HSL(a) is used for better control over colors.
|
||||
HSL(a) is used for better control.
|
||||
https://css-tricks.com/hsl-hsla-is-great-for-programmatic-color-control/
|
||||
https://css-tricks.com/color-alpha-anywhere/
|
||||
*/
|
||||
|
||||
@ -14,7 +14,7 @@ function weatherBalloon(cityID) {
|
||||
})
|
||||
.then(function(data) {
|
||||
let weatherIcon = data.weather[0].icon;
|
||||
let tempK = parseFloat(data.main.temp);
|
||||
let tempK = parseFloat(data.main.temp);
|
||||
let tempC = Math.round(tempK - 273.15);
|
||||
let tempF = Math.round((tempK - 273.15) * 1.8) + 32;
|
||||
document.getElementById('weather').innerHTML = '<p id="location">' + data.name + '</p><p id="details" ' + 'title="' + tempF + '°F">' + '<img src="http://openweathermap.org/img/wn/' + weatherIcon + '@2x.png">' + data.weather[0].description + '<span class="separator">|</span>' + tempC + '°C</p>';
|
||||
|
||||
Loading…
Reference in New Issue
Block a user