From 59ca35dc34b3d5f66eb3ec3d951012507222fe62 Mon Sep 17 00:00:00 2001 From: ozhozh Date: Sun, 7 Nov 2010 20:36:59 +0000 Subject: [PATCH] Implement .hide-if-*js classes git-svn-id: http://yourls.googlecode.com/svn/trunk@535 12232710-3e20-11de-b438-597f59cd7555 --- css/style.css | 3 ++- js/common.js | 6 ++++++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/css/style.css b/css/style.css index 021dd20..6709f21 100644 --- a/css/style.css +++ b/css/style.css @@ -22,6 +22,7 @@ body { -webkit-border-radius:20px; border-radius:20px; } +.hide-if-no-js {display: none;} div, p, td { font-family: Verdana, Arial; font-size: 12px; @@ -325,4 +326,4 @@ a.bookmarklet:hover { } tr.plugin.active a{ font-weight:bolder;} body.desktop tr.plugin td.plugin_desc small{ visibility:hidden;} -tr:hover.plugin td.plugin_desc small{ visibility:visible;} \ No newline at end of file +tr:hover.plugin td.plugin_desc small{ visibility:visible;} diff --git a/js/common.js b/js/common.js index 8021354..5f0b34e 100644 --- a/js/common.js +++ b/js/common.js @@ -1,3 +1,9 @@ +// Handle .hide-if-no-js and .hide-if-js styles +$(document).ready(function(){ + $('.hide-if-no-js').removeClass('hide-if-no-js'); + $('.hide-if-js').hide(); +}); + // Change an element text an revert in a smooth pulse. el is an element id like '#copybox h2' function html_pulse( el, newtext ){ var oldtext = $(el).html(); -- 2.45.0