From: Brion Vibber Date: Thu, 3 Nov 2011 19:18:49 +0000 (+0000) Subject: bug 32183: remove the client-* classes added from user-agent-sniffing onto the element. Browser sniffing is bad, and having these here encourages unpleasantness. Keeping the js/nojs ones as those are useful and non-evil (they're an example of feature detection, exposed via CSS here rather than through JS.) --- diff --git a/resources/mediawiki.page/mediawiki.page.startup.js b/resources/mediawiki.page/mediawiki.page.startup.js index c601c290f2..6217070a78 100644 --- a/resources/mediawiki.page/mediawiki.page.startup.js +++ b/resources/mediawiki.page/mediawiki.page.startup.js @@ -3,15 +3,10 @@ mw.page = {}; /* Client profile classes for */ + /* Allows for easy hiding/showing of JS or no-JS-specific UI elements */ - var prof = $.client.profile(); $( 'html' ) - .addClass( - 'client-' + prof.name - + ' client-' + prof.name + '-' + prof.versionBase - + ' client-' + prof.layout - + ' client-' + prof.platform - + ' client-js' ) + .addClass('client-js' ) .removeClass( 'client-nojs' ); } )( jQuery );