summaryrefslogtreecommitdiff
path: root/resources/mediawiki.action/mediawiki.action.edit.preview.js
diff options
context:
space:
mode:
authorPierre Schmitz <pierre@archlinux.de>2013-08-12 09:28:15 +0200
committerPierre Schmitz <pierre@archlinux.de>2013-08-12 09:28:15 +0200
commit08aa4418c30cfc18ccc69a0f0f9cb9e17be6c196 (patch)
tree577a29fb579188d16003a209ce2a2e9c5b0aa2bd /resources/mediawiki.action/mediawiki.action.edit.preview.js
parentcacc939b34e315b85e2d72997811eb6677996cc1 (diff)
Update to MediaWiki 1.21.1
Diffstat (limited to 'resources/mediawiki.action/mediawiki.action.edit.preview.js')
-rw-r--r--resources/mediawiki.action/mediawiki.action.edit.preview.js6
1 files changed, 6 insertions, 0 deletions
diff --git a/resources/mediawiki.action/mediawiki.action.edit.preview.js b/resources/mediawiki.action/mediawiki.action.edit.preview.js
index cddf6ccf..602aadb0 100644
--- a/resources/mediawiki.action/mediawiki.action.edit.preview.js
+++ b/resources/mediawiki.action/mediawiki.action.edit.preview.js
@@ -102,6 +102,12 @@
}
$( document ).ready( function () {
+ // Do not enable on user .js/.css pages, as there's no sane way of "previewing"
+ // the scripts or styles without reloading the page.
+ if ( $( '#mw-userjsyoucanpreview' ).length || $( '#mw-usercssyoucanpreview' ).length ) {
+ return;
+ }
+
// The following elements can change in a preview but are not output
// by the server when they're empty until the preview reponse.
// TODO: Make the server output these always (in a hidden state), so we don't