Fix tooltip positioning in older MediaWiki versions

Bug: T164052
Change-Id: I931dff9d027bf8d8b54ed87816e2cb23c8a25f00
This commit is contained in:
Niklas Laxström
2017-04-28 10:21:56 +02:00
committed by Nikerabbit
parent de49c437f2
commit 4f65980301

View File

@@ -193,7 +193,16 @@
}
function showTipsy( timeout ) {
var tipsyTimer = 0;
var offset, tipsyTimer = 0;
// BC for MW 1.27
if ( ulsPopup.setFloatableContainer === undefined ) {
offset = $ulsTrigger.offset();
ulsPopup.$element.css( {
top: offset.top + 24,
left: offset.left + $ulsTrigger.outerWidth() / 2
} );
}
ulsPopup.toggle( true );
ulsPopup.toggleClipping( false );