Skip to content
Snippets Groups Projects
Commit bf923ed9 authored by Steven Wittens's avatar Steven Wittens
Browse files

Slightly tweak the JS timing for sticky tableheader resizing.

parent b0676cf3
No related branches found
No related tags found
2 merge requests!7452Issue #1797438. HTML5 validation is preventing form submit and not fully...,!789Issue #3210310: Adjust Database API to remove deprecated Drupal 9 code in Drupal 10
......@@ -79,8 +79,7 @@ if (Drupal.jsEnabled) {
var resize = function () {
// Ensure minimum time between adjustments.
if (time) {
clearTimeout(time);
time = null;
return;
}
time = setTimeout(function () {
......@@ -103,6 +102,9 @@ if (Drupal.jsEnabled) {
$(this).css('width', parseInt($(ref).width())
- parseInt($(this).css('paddingLeft')) +'px');
});
// Reset timer
time = null;
}, 250);
};
$(window).resize(resize);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment