Ei muokkausyhteenvetoa |
Ei muokkausyhteenvetoa |
||
| Rivi 120: | Rivi 120: | ||
iceautumnbrcolor = [ '#64c1cb', '#fff', '#64c1cb' ]; | iceautumnbrcolor = [ '#64c1cb', '#fff', '#64c1cb' ]; | ||
icespringbrcolor = [ '#64c1cb', '#64c1cb', '#fff' ]; | icespringbrcolor = [ '#64c1cb', '#64c1cb', '#fff' ]; | ||
if ( now.getMonth() > 2 && now.getMonth() < 7 ) { | if ( now.getMonth() > 2 && now.getMonth() < 7 ) { | ||
bgcolor = icespringbgcolor[ icecatmean ]; | bgcolor = icespringbgcolor[ icecatmean ]; | ||
| Rivi 133: | Rivi 131: | ||
out += '<div style="height: 40px; display: flex; justify-content: center; align-items: center; flex-direction: column;"><span style="margin: 0;">' + jw.obstype[ 'ice' ].newest.inRelationToToday() + '</span></div>'; | out += '<div style="height: 40px; display: flex; justify-content: center; align-items: center; flex-direction: column;"><span style="margin: 0;">' + jw.obstype[ 'ice' ].newest.inRelationToToday() + '</span></div>'; | ||
out += '<div style="width: 84px; height: 84px; margin: auto; border-radius: 50%; border: | out += '<div style="width: 84px; height: 84px; margin: auto; border-radius: 50%; border: 10px solid ' + brcolor + '; background-color: ' + bgcolor + '; display: flex; justify-content: center; align-items: center; flex-direction: column;">'; | ||
out += '<div style="font-size: 36px;">' + Math.round( jw.obstype[ 'ice' ].mean ) + '</div>'; | |||
out += '<div style="font-size: 24px; margin-top: -20px;">cm</div>'; | if ( icecatmean == 3 ) { | ||
out += '<div style="font-size: 36px;">' + Math.round( jw.obstype[ 'ice' ].mean ) + '</div>'; | |||
out += '<div style="font-size: 24px; margin-top: -20px;">cm</div>'; | |||
} | |||
out += '</div>'; | out += '</div>'; | ||
out += '<div style="height: 60px; display: flex; justify-content: center; align-items: center; flex-direction: column;"><span class="h6" style="margin: 0;">' + icetxt[ icecatmean ] + '</span></div>'; | out += '<div style="height: 60px; display: flex; justify-content: center; align-items: center; flex-direction: column;"><span class="h6" style="margin: 0;">' + icetxt[ icecatmean ] + '</span></div>'; | ||


