This wiki is still in active development, many areas of the site are unstable or broken.

In the meantime, consider adding content to pages you like!

MediaWiki:Timeless.js: Difference between revisions

From NBITTRPG Wiki
Created page with "→All JavaScript here will be loaded for users of the Timeless skin: →COLLAPSIBLE SIDEBAR HEADERS: var showTheseMenus = ['navigation']; $('#site-navigation > .sidebar-inner > .mw-portlet > .mw-portlet-body').addClass('collapse'); $(showTheseMenus.map(function (menuId) { return '#p-'+menuId; }).join(',')) .find('> .mw-portlet-body') .addClass('show'); $('#site-navigation > .sidebar-inner > .mw-portlet[id^=\'p-^\'] > h3') .text(function () { return $(t..."
 
mNo edit summary
Tag: Manual revert
 
(6 intermediate revisions by the same user not shown)
Line 1: Line 1:
/* All JavaScript here will be loaded for users of the Timeless skin */
/* All JavaScript here will be loaded for users of the Timeless skin */
 
mw.loader.load('https://dev.miraheze.org/w/index.php?title=User:Splatched/timelesssearchbar.js&action=raw&ctype=text/javascript');
/* COLLAPSIBLE SIDEBAR HEADERS */
var showTheseMenus = ['navigation'];
 
$('#site-navigation > .sidebar-inner > .mw-portlet > .mw-portlet-body').addClass('collapse');
$(showTheseMenus.map(function (menuId) { return '#p-'+menuId; }).join(','))
    .find('> .mw-portlet-body')
    .addClass('show');
$('#site-navigation > .sidebar-inner > .mw-portlet[id^=\'p-^\'] > h3')
    .text(function () { return $(this).text().replace(/^\^/, ''); });
$('#site-navigation > .sidebar-inner > .mw-portlet[id^=\'p-^\'] > .mw-portlet-body')
    .addClass('show');
$('#site-navigation > .sidebar-inner > .mw-portlet > h3').append( $('<div>').addClass('menu-btn') );
$('#site-navigation > .sidebar-inner > .mw-portlet > h3').on('click', function (event) {
$(this).next().toggleClass('show');
    event.preventDefault();
event.stopPropagation();
});

Latest revision as of 07:15, 27 October 2026

/* All JavaScript here will be loaded for users of the Timeless skin */
mw.loader.load('https://dev.miraheze.org/w/index.php?title=User:Splatched/timelesssearchbar.js&action=raw&ctype=text/javascript');