Jump to content

User:Tcncv/monobook.js

From Wikipedia, the free encyclopedia
Note: After saving, you have to bypass your browser's cache to see the changes. Google Chrome, Firefox, Microsoft Edge and Safari: Hold down the ⇧ Shift key and click the Reload toolbar button. For details and instructions about other browsers, see Wikipedia:Bypass your cache.
// Disable refToolbar (per instructions at [[MediaWiki:Common.js/edit.js]]
refToolbarInstalled = 'bypass';


//importScript('User:Lightmouse/monobook.js/script.js');

importScript('User:Tcncv/sorttables.js');
//importScript('User:Tcncv/sorttablesdebug.js');

//importScript('User:Tcncv/sorttablesdev.js');
//importScript('User:Franamax/sortable2.js');

//importScript('User:Gary King/localize comments.js'); // Localize Comments

importScript('User:AzaToth/twinkle.js');
//importScript('User:Tcncv/twinkleTest.js');  // ################## for testing #####################
//Array.prototype.uniq = null;
//Array.prototype.dups = null;
//Array.prototype.chunk = null;

TwinkleConfig = {
        revertMaxRevisions              :       50,
        userTalkPageMode                :       'tab',
        showSharedIPNotice              :       false,
        openTalkPage                    :       [ 'agf', 'norm', 'vand' ],
        openTalkPageOnAutoRevert        :       false,
        summaryAd                       :       " ([[WP:TWINKLE|TW]])",
        deletionSummaryAd               :       " ([[WP:TWINKLE|TW]])",
        protectionSummaryAd             :       " ([[WP:TWINKLE|TW]])",
        watchSpeedyPages                :       [ 'g3', 'g5', 'g10', 'g11', 'g12' ],
        watchProdPages                  :       true,
        openUserTalkPageOnSpeedyDelete  :       [ 'g1', 'g2', 'g10', 'g11', 'g12', 'a1', 'a7', 'i3', 'i4', 'i5', 'i6', 'i7', 'u3', 't1' ],
        watchRevertedPages              :       [],
        markRevertedPagesAsMinor        :       [ 'agf', 'norm', 'vand', 'torev' ],
        deleteTalkPageOnDelete          :       false,
        watchWarnings                   :       true,
        markAIVReportAsMinor            :       true,
        markSpeedyPagesAsMinor          :       true,
        offerReasonOnNormalRevert       :       true,
        orphanBacklinksOnSpeedyDelete   :       {orphan:true, exclude:['g6']}
};

/* Disable revision-delete buttons, so we can get back default diff behavior on history pages. */
//addOnloadHook(function() {
//    var buttons = document.getElementsByTagName('button');
//    for (var i = 0; i < buttons.length; i++)
//        if (buttons[i].name == 'revisiondelete')
//            buttons[i].parentNode.removeChild(buttons[i]);
//});

/* Move search to top */
/* adapted from User:Happy-melon/monobook.js */
$(function() {
    document.getElementById("column-one").insertBefore(document.getElementById("p-search"), document.getElementById("p-navigation"))
});

/* Hide languages */
/*
$(function() {
    document.getElementById("p-lang").style.cssText = "display: none";
});
*/