Wikipédia:LiveRC/Documentation/Extensions/UserWarningsExtension/en

Une page de Wikipédia, l'encyclopédie libre.
(fr)(en)(it)[edit]

UserWarningsExtension.js is an extension for LiveRC. It permit to identify with an icon the users that have received a warning on their talk page and provide an editcount of the users.

The extension is available in the LiveRC config panel, through the (Un)install extensions tab.

In the standard configuration, the users who get a warning message are identified with the following icons:

Furthermore, an icon is added to figure the (undeleted) contributions number of the user :

  •  : less than 10 contributions
  •  : less than 50 contributions
  •  : less than 500 contributions
  •  : more than 500 contributions

Customization[modifier le code]

Received messages[modifier le code]

A new tab named UserWarnings permit to define comments to detect for adding an icon before the user name.

For each items, three elements are needed:

  • image : the ID of the icon added when the comment is detected (can be customized throught the Icons tab of the config panel)
  • class : the CSS class linked to the message received by the user (can be added or modified through the CSS styles tab of the config panel)
  • regex : the RegExp used to check the edit comment (case insensitive)

Example :

    { image: "SpamIcon"    , class: "RcUWSpam"    , regex: /(S|s)pammeur/                 },
    { image: "Test0Icon"   , class: "RcUWTest0"   , regex: /(T|t)est ?0/                  },
    { image: "Test1Icon"   , class: "RcUWTest1"   , regex: /(T|t)est ?1/                  },
    { image: "Test2Icon"   , class: "RcUWTest2"   , regex: /(T|t)est ?2/                  },
    { image: "Test3Icon"   , class: "RcUWTest3"   , regex: /(T|t)est ?3/                  },
    { image: "SalebotIcon" , class: "RcUWSalebot" , regex: /^bot : annonce de révocation/ }

Icons[modifier le code]

The icons used by the extension can be customized throught the Icons tab of the config panel.

CSS classes[modifier le code]

The CSS styles linked to the message received by the user can be added or modified through the CSS styles tab of the config panel.

Texts[modifier le code]

The texts used by the extension can be customized through the Texts 1 and Texts 2 tabs of the config panel.

Params[modifier le code]

Several options can be customized through the Params tab of the config panel:

  • the activation of the user talk page history request to get received messages (default is true)
  • the activation of the user editcount request (default is true)
  • The user link color when the talk page doesn't exists (HTML code like « #C0C0C0 » or « blue »)
  • The user link color when the talk page has been edited but no messages detected (HTML code like « #C0C0C0 » or « blue »)
  • The user link color when a message has been detected (HTML code like « #C0C0C0 » or « blue »)
  • The number of hours of history to get from an IP talk page (default is 24)
  • The number of hours of history to get from a registred user talk page (default is 24)