MediaWiki talk:Live EriCSSon.js

Latest comment: 9 years ago by TheDJ in topic More updates

Live EriCSSon (pun-named after Leif Ericsson) is a JavaScript tool by Magnus Manske (talk) that allows for quick and easy application of individual CSS on Wikipedia. It can be used to experimentally or permanently change the CSS-based style and layout of a user's Wikipedia experience.

Setup

edit

Go to your common.js user page, and add the following line:

importScript('MediaWiki:Live EriCSSon.js');

You may have to clear your browser cache afterwards.

Now, you can use any Wikipedia page as a CSS source (example CSS), like this. Following that link will then look like this:

 .

A link in the sidebar Toolbox opens a dialog which allows entry of a CSS page to try out, to make the current custom CSS permanent (via cookies), and to remove the permanent CSS.

Protected edit request on 15 July 2014

edit

Since gerrit:90569, mw.util.wikiGetlink is deprecated and should be replaced by mw.util.getUrl. Could you make replace "wikiGetlink" by "getUrl" on this script? This will make the warning "Use of "wikiGetlink" is deprecated. Use mw.util.getUrl instead." to go away from the console. Helder.wiki 13:27, 15 July 2014 (UTC)Reply

  Done --Krenair (talkcontribs) 13:41, 15 July 2014 (UTC)Reply

More updates

edit

Please remove the line

if ( typeof ( $ ) === 'undefined' ) $ = $j ;

because window.$j is deprecated and window.$ is always available. Helder.wiki 14:06, 15 July 2014 (UTC)Reply

I saved an updated version of the script in the sandbox, with a few other changes. @Magnus Manske, Krenair, Matma Rex, and TheDJ: Could someone review and apply this patch? Helder.wiki 15:21, 15 July 2014 (UTC)Reply
All look like sane changes to me, but I'd rather have Magnus sign off on it. —TheDJ (talkcontribs) 16:08, 15 July 2014 (UTC)Reply