Merge "vector.js: Use idle callback (not rAF) for computed style read"

This commit is contained in:
jenkins-bot 2019-09-11 19:16:35 +00:00 committed by Gerrit Code Review
commit b5b5b3c5e3
1 changed files with 1 additions and 2 deletions

View File

@ -9,7 +9,6 @@ $( function () {
*/
var $cactions = $( '#p-cactions' ),
$tabContainer = $( '#p-views ul' ),
rAF = window.requestAnimationFrame || setTimeout,
// Avoid forced style calculation during page load
initialCactionsWidth = function () {
var width = $cactions.width();
@ -19,7 +18,7 @@ $( function () {
return width;
};
rAF( initialCactionsWidth );
mw.requestIdleCallback( initialCactionsWidth );
/**
* Focus search input at the very end