User:Joshua Scott/Scripts/pendingchanges

From Wikipedia, the free encyclopedia

This script will put a "Pending changes" menu in the sidebar. By default, it is collapsed, and thus inactive. In the Vector skin, clicking on "Pending changes" will activate it. If you are using Monobook, click "enable" underneath "Pending Changes". You will see a list of pages that are waiting for approval. Pages highlighted in yellow are "Under Review". My understanding is that this means that someone else has viewed the diff recently, but has not yet clicked 'approve'.

This script is optimized for the Vector & Monobook skins, but works with the following skins:

  • Vector (If you don't know which you have, likely you have Vector)
  • Monobook (If you clicked 'take me back', you likely have Monobook)
  • Chick
  • MySkin
  • Simple

It does not work with:

  • Classic
  • Cologne Blue
  • Modern
  • Nostalgia

Installation[edit]

Add the following line to your skin script (found at Special:Mypage/skin.js):

importScript('User:Joshua Scott/Scripts/pendingchanges.js');

You can also view the source code here.

Customizing[edit]

You can customize the operation of the script by setting certain parameters, like:

parameter = value; (make sure of the semicolon at the end)

Parameters[edit]

  • pendch_enabled - whether the menu starts open & enabled
    • possible values: true or false. default: false
  • pendch_refresh - how often the list is refreshed (in seconds).
    • possible values: numbers greater than 2. default: 10.
  • pendch_num_pages - how many pages are listed in the menu
    • possible values: numbers between 1 and 50. default: 10.
  • pendch_num_idle_req - how many refreshes will happen before it turns itself off.
    • possible values: numbers between 5 and 1000. default: 50
  • pendch_diffonly - show only the diff, without the full page below.
    • possible values: 1 (show only the diff), 0 (show the full page). default: 1
    • Note: When diffonly is turned on, there is a link at the top of the page which allows you to see the full page content below when needed.

Examples[edit]

Turn the menu on by default, refresh every 30 seconds, list a maximum of 5 pages at a time, and shut off after 20 requests: pendch_enabled = true;
pendch_refresh = 30;
pendch_num_pages = 5;
pendch_num_idle_req = 20;

Problems?[edit]

Please ask for help.

Thanks[edit]

Thanks to User:TheJosh, who wrote the New Page Patrol script at User:TheJosh/Scripts/NewPagePatrol.js. This script is largely based on that excellent script.