summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGeorg Brandl <georg@python.org>2010-11-20 18:00:23 +0100
committerGeorg Brandl <georg@python.org>2010-11-20 18:00:23 +0100
commitdae3933e87edad48dd0b03cb308345daba2db6a2 (patch)
treeee258e54d4cc5458ccbb4f0cc3e57fcebd828ec4
parentfbaae8b740da42ddcff7ee419545ec9457339806 (diff)
downloadsphinx-git-dae3933e87edad48dd0b03cb308345daba2db6a2.tar.gz
Add a "nocomment" class to be able to hide bubbles.
-rw-r--r--sphinx/themes/basic/static/websupport.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/sphinx/themes/basic/static/websupport.js b/sphinx/themes/basic/static/websupport.js
index f545b5716..ac87c3e2c 100644
--- a/sphinx/themes/basic/static/websupport.js
+++ b/sphinx/themes/basic/static/websupport.js
@@ -614,11 +614,12 @@
var count = COMMENT_METADATA[id];
var title = count + ' comment' + (count == 1 ? '' : 's');
var image = count > 0 ? opts.commentBrightImage : opts.commentImage;
+ var addcls = count == 0 ? ' nocomment' : '';
$(this)
.append(
$(document.createElement('a')).attr({
href: '#',
- 'class': 'sphinx-comment',
+ 'class': 'sphinx-comment' + addcls,
id: 'ao' + id
})
.append($(document.createElement('img')).attr({