2,894
edits
m (Changed let to var) |
mNo edit summary |
||
Line 13: | Line 13: | ||
firstHeight = firstRow[0].offsetHeight; | firstHeight = firstRow[0].offsetHeight; | ||
const firstHeaders = firstRow[0].getElementsByTagName('th'); | const firstHeaders = firstRow[0].getElementsByTagName('th'); | ||
for ( | for (var j = 0; j < firstHeaders.length; j++) { | ||
firstHeaders[j].style.top = `${headHeight}px`; | firstHeaders[j].style.top = `${headHeight}px`; | ||
} | } | ||
if (secondRow.length > 0) { | if (secondRow.length > 0) { | ||
const secondHeaders = secondRow[0].getElementsByTagName('th'); | const secondHeaders = secondRow[0].getElementsByTagName('th'); | ||
for ( | for (var j = 0; j < secondHeaders.length; j++) { | ||
secondHeaders[j].style.top = `${headHeight + firstHeight}px`; | secondHeaders[j].style.top = `${headHeight + firstHeight}px`; | ||
} | } | ||
Line 24: | Line 24: | ||
} | } | ||
} | } | ||
}); | }); |