Make the left position number fixed to 2 digits

This commit is contained in:
Lim Chee Aun 2013-12-04 22:45:33 +08:00
parent 83facc6f4a
commit e8f102c6f1

View File

@ -246,7 +246,7 @@ h1{
var days = 0;
for (var y=firstYear, age = 0; y<=nowYear+1; y++, age++){
html += '<section class="year" style="left: ' + (days*dayLength) + 'px">' +
html += '<section class="year" style="left: ' + (days*dayLength).toFixed(2) + 'px">' +
y + ' (' + age + ')' +
'</section>';
days += (y % 4 == 0) ? 366 : 365;