FANDOM


This wiki uses collapsible tables in multiple places, mostly for spoilers or system specific content. These tables allow to hide their content.

This article describes how to automate the visible content, i.e. you could hide all PC specific content when playing on the XBOX. It only works for registered users.

Create the new page User:Username/monaco.js whereby you have to replace Username with your username, i.e. by typing it into the searchbox and clicking the red link on top of the page. Add the following content to the new page:

function selectSystem () {
  var tables = document.getElementsByTagName ("table");
  var index = 0;
  for (var i = 0; i < tables.length; i++) {
    if (hasClass (tables[i], "collapsible")) {
      // insert here
      index++;
    }
  }
}   
addOnloadHook (selectSystem);

You also have to add the filters after the line insert here. A filter has the following form:

      if (hasClass (tables[i], "XXXXX")) {
        collapseTable (index);
      }

Replace the XXXXX with one of the string listed below (case-sensitive!):

String What it does
xbox Hides most XBOX specific content.
pc Hides most PC specific content.
characterinfo Hides the "Other Information" area on the leader pages.
charactermorale Hides the "Morale & Resistance" area on the leader pages.
spoiler Shows all spoiler sections.

Please note that you'll have to clear the cache of you browser whenever you change something on this page.


The following example hides the PC specific content and shows all spoiler sections:

function selectSystem () {
  var tables = document.getElementsByTagName ("table");
  var index = 0;
  for (var i = 0; i < tables.length; i++) {
    if (hasClass (tables[i], "collapsible")) {
      if (hasClass (tables[i], "pc")) {
        collapseTable (index);
      }
      if (hasClass (tables[i], "spoiler")) {
        collapseTable (index);
      }
      index++;
    }
  }
}   
addOnloadHook (selectSystem);

Ad blocker interference detected!


Wikia is a free-to-use site that makes money from advertising. We have a modified experience for viewers using ad blockers

Wikia is not accessible if you’ve made further modifications. Remove the custom ad blocker rule(s) and the page will load as expected.