MediaWiki:Common.js: Difference between revisions

Jump to navigation Jump to search
no edit summary
No edit summary
No edit summary
Line 2: Line 2:
/* Class Code */
/* Class Code */
(function () {
(function () {
     class colorContent {
     var colorContent = (text, color) => {return {text, color, xpath: "//td[contains(text(),'" + text + "')]"}}
        constructor(text, color) {
            this.text = text
            this.color = color
        }
        get xpath() {
            return "//td[contains(text(),'" + this.text + "')]"
        }
    }
     /* Active Code */
     /* Active Code */
     console.log("on page: " + mw.config.get('wgPageName'));
     console.log("on page: " + mw.config.get('wgPageName'));
     if (mw.config.get('wgPageName') === 'Mobile_Suits') {
     if (mw.config.get('wgPageName') === 'Mobile_Suits') {
         var colorList = [
         var colorList = [
             new ColorContent('Super High Tensile Steel', '#7b9095')
             colorContent('Super High Tensile Steel', '#7b9095')
         ]
         ]


EFF, ZEON, approveduser, Bureaucrats, Interface administrators, Administrators, uploadaccess
843

edits

Navigation menu