MediaWiki:Gadget-popups.js: Difference between revisions

remove sections relying on red-link templates - will hopefully make this page slightly faster
m (1 revision)
 
(remove sections relying on red-link templates - will hopefully make this page slightly faster)
Line 3,942: Line 3,942:
this.kill(RegExp('[{][{][^{}\\s|]*?(infobox|elementbox|frame)[_ ]', 'i'), /[}][}]\s*/, '{{');
this.kill(RegExp('[{][{][^{}\\s|]*?(infobox|elementbox|frame)[_ ]', 'i'), /[}][}]\s*/, '{{');


};
/**
  @private
*/
Previewmaker.prototype.killTemplates = function () {
this.kill('{{', '}}', '{', '}', ' ');
};
};
/**
/**
Line 4,308: Line 4,302:
this.html=this.html.split('\n').join(' '); // workaround for <pre> templates
this.html=this.html.split('\n').join(' '); // workaround for <pre> templates
this.html=this.html.replace(RegExp('[{][{][^}]*<pre>[^}]*[}][}]','gi'), '');
this.html=this.html.replace(RegExp('[{][{][^}]*<pre>[^}]*[}][}]','gi'), '');
};
/**
  @private
*/
Previewmaker.prototype.killMultilineTemplates = function() {
this.kill('{{{', '}}}');
this.kill(RegExp('\\s*[{][{][^{}]*\\n'), '}}', '{{');
};
};
// ENDFILE: previewmaker.js
// ENDFILE: previewmaker.js