“MediaWiki:Gadget-site-shared.js”的版本间差异

无编辑摘要
if (!hash || document.getElementById( hash )) { return; }
const header = $('.mw-headline').filter(function() {
returnconst this.textContenttext == hash || this.textContent == hash.replace(/\.(?=[\dA-Z]{2})/g, '%');
return text == hash || text == decodeURIComponent( hash.replace(/\.(?=[\dA-Z]{2})/g, '%') );
})[0];
if (header) { header.scrollIntoView({ behavior: 'smooth' }); }
16,874

个编辑