« MediaWiki:Common.js » : différence entre les versions
Aller à la navigation
Aucun résumé des modifications |
Aucun résumé des modifications |
||
Ligne 1 : | Ligne 1 : | ||
$(document).mousemove(function(e){ | $(document).mousemove(function(e){ | ||
console.log(e); | console.log(e); | ||
var width = e.clientX + 20; | var width = e.clientX + 20 - $('#content').offset().left; | ||
var height = e.clientY + 20; | var height = e.clientY + 20 - - $('#content').offset().height; | ||
$('.popup_window:visible').css({top: height, left: width}); | $('.popup_window:visible').css({top: height, left: width}); | ||
}); | }); |
Version du 14 juillet 2016 à 09:56
$(document).mousemove(function(e){ console.log(e); var width = e.clientX + 20 - $('#content').offset().left; var height = e.clientY + 20 - - $('#content').offset().height; $('.popup_window:visible').css({top: height, left: width}); });