MediaWiki:Common.js: Difference between revisions
MediaWiki interface page
More actions
Created page with "→Any JavaScript here will be loaded for all users on every page load.: →SK: Pin D pad on phones: (function () { function isPhoneWidth() { return window.matchMedia && window.matchMedia("(max-width: 759px)").matches; } function ensurePinned() { var dpad = document.getElementById("sk-dpad"); if (!dpad) return; if (!isPhoneWidth()) { dpad.style.position = ""; dpad.style.top = ""; dpad.style.right = ""; dpad.style.zInde..." |
No edit summary |
||
| (9 intermediate revisions by the same user not shown) | |||
| Line 1: | Line 1: | ||
(function(){ | |||
var w = window; | |||
var d = document; | |||
function handler(e){ | |||
var k = e.key; | |||
if (!k) return; | |||
k = k.toLowerCase(); | |||
} | } | ||
d.addEventListener("keydown", handler); | |||
})(); | })(); | ||
Latest revision as of 09:52, 20 December 2025
(function(){
var w = window;
var d = document;
function handler(e){
var k = e.key;
if (!k) return;
k = k.toLowerCase();
}
d.addEventListener("keydown", handler);
})();