thematdevdotorg/app/static/js/projects.js
2021-01-12 22:07:54 +03:00

14 lines
395 B
JavaScript

function alignHeadersByHeight(table) {
var maxHeight = 0;
table.querySelectorAll('h1').forEach(
element => maxHeight = Math.max(maxHeight, element.clientHeight)
)
table.querySelectorAll('h1').forEach(
element => element.style.height = maxHeight + 'px'
)
console.log(maxHeight);
}
var table = document.getElementById("pbic");
alignHeadersByHeight(table);