From 480f0c7017f2941415bebff14909035695cebd16 Mon Sep 17 00:00:00 2001 From: John Du Hart Date: Mon, 21 Nov 2011 22:53:24 +0000 Subject: [PATCH] Followup r95318, move client-(no)js classes to the body tag per discussion in bug 30497 --- includes/OutputPage.php | 4 ++-- resources/mediawiki.page/mediawiki.page.startup.js | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/includes/OutputPage.php b/includes/OutputPage.php index 398cddedac..30cb9b7927 100644 --- a/includes/OutputPage.php +++ b/includes/OutputPage.php @@ -2335,7 +2335,7 @@ $templates $this->addModuleStyles( 'mediawiki.legacy.wikiprintable' ); } - $ret = Html::htmlHeader( array( 'lang' => $this->getLanguage()->getCode(), 'dir' => $userdir, 'class' => 'client-nojs' ) ); + $ret = Html::htmlHeader( array( 'lang' => $this->getLanguage()->getCode(), 'dir' => $userdir ) ); if ( $this->getHTMLTitle() == '' ) { $this->setHTMLTitle( $this->msg( 'pagetitle', $this->getPageTitle() ) ); @@ -2368,7 +2368,7 @@ $templates $bodyAttrs = array(); # Classes for LTR/RTL directionality support - $bodyAttrs['class'] = "mediawiki $userdir sitedir-$sitedir"; + $bodyAttrs['class'] = "mediawiki $userdir sitedir-$sitedir client-nojs"; if ( $this->getLanguage()->capitalizeAllNouns() ) { # A class is probably not the best way to do this . . . diff --git a/resources/mediawiki.page/mediawiki.page.startup.js b/resources/mediawiki.page/mediawiki.page.startup.js index 6217070a78..d3bc94274a 100644 --- a/resources/mediawiki.page/mediawiki.page.startup.js +++ b/resources/mediawiki.page/mediawiki.page.startup.js @@ -5,7 +5,7 @@ /* Client profile classes for */ /* Allows for easy hiding/showing of JS or no-JS-specific UI elements */ - $( 'html' ) + $( 'body' ) .addClass('client-js' ) .removeClass( 'client-nojs' ); -- 2.20.1