MediaWiki:Mobile.js

// extension req //v2.0, 2017, user:fngplg. //set active tab: https://jojowiki.com/page#activeTab (function ($){   var nstarget = window.location.hash.replace('#', );    if (nstarget === ) return;    //convert wiki-utf 2 ansi    nstarget = nstarget.replace(/\./g, '%');    nstarget = decodeURIComponent(nstarget).replace(/_/g, ' ');    //console.log('trgt:'+nstarget);    $(function{ setTimeout(function {           var $nt2a = $('.tabberlive>.tabbernav>Li>a[title="' + nstarget + '"]');            $nt2a.click;            $nt2a.get(0).scrollIntoView;        }, 100);//settimeout });//doc.rdy   })(jQuery);

/* Tooltip */ $(".popup").click(function {    var $title = $(this).find(".title");    if (!$title.length) {        $(this).append(' ' + $(this).attr("title") + ' ');    } else {        $title.remove;    } });

// Creates action=raw links for JS or CSS gadgets // Useful for mw.loader.load, which doesn't accept page titles function rawPageLink( pageName ) { return mw.config.get( 'wgServer' ) + mw.config.get( 'wgScript' ) + '?title=' + mw.util.wikiUrlencode(pageName) + '&action=raw&ctype=text/javascript'; }

// Overwriting deprecated functions that don't have an exact followup but can be easily mapped: window.importScript = function ( page ) { if ( typeof page === 'string' && page.length ) { mw.loader.load( rawPageLink( page ) ); } };