User:Iritscen/vector.js: Difference between revisions

From OniGalore
Jump to navigation Jump to search
(remove XEB customization, as XEB is obsolete now)
(testing search-focus code, taken from https://en.wikipedia.org/wiki/MediaWiki:Gadget-searchFocus.js)
Line 5: Line 5:
}
}


// Place us in the Search box if we're on the Main Page so we can immediately start typing
if (mw.config.get('wgIsMainPage'))
{
  $(function()
  {
    $('#searchInput').focus();
  });
}
// This code is disabled but left in place since it is referred to on [[MediaWiki:Common]]
// Add handy links to my sidebar
// Add handy links to my sidebar
// This code is disabled but left in place since it is referred to on [[MediaWiki:Common]]
/*$(function()
/*$(function()
{
{

Revision as of 14:02, 2 October 2022

// Use test JS if we're on a test page
if (mw.config.get('wgPageName') === 'User:Iritscen/TestSpace' || mw.config.get('wgPageName') === 'User:Iritscen/TestSpace2')
{
   mw.loader.load('/w/index.php?title=User:Iritscen/TestSpace.js&action=raw&ctype=text/javascript');
}

// Place us in the Search box if we're on the Main Page so we can immediately start typing
if (mw.config.get('wgIsMainPage'))
{
  $(function()
  {
    $('#searchInput').focus();
  });
}

// This code is disabled but left in place since it is referred to on [[MediaWiki:Common]]
// Add handy links to my sidebar
/*$(function()
{
    ModifySidebar("sep", "navigation", "", "");
    ModifySidebar("add", "navigation", "Slaves of War", "http://wiki.oni2.net/Oni2:Slaves_of_War");
});*/