Difference between revisions of "MediaWiki:Common.js"
Jump to navigation
Jump to search
old>Realpsojed (testing automatic resize of image2x class) |
old>Realpsojed m |
||
Line 9: | Line 9: | ||
} | } | ||
window.onload = function() resizeAllTableImages(); | window.onload = function() { | ||
resizeAllTableImages(); | |||
}; |
Revision as of 20:47, 5 April 2021
/* Any JavaScript here will be loaded for all users on every page load. */ function resizeAllTableImages() { const imgs = document.querySelectorAll(".image2x"); imgs.forEach((img) => { img.width *= 2; img.height *= 2; }); } window.onload = function() { resizeAllTableImages(); };