diff options
author | Georg Brandl <georg@python.org> | 2010-11-21 21:07:20 +0100 |
---|---|---|
committer | Georg Brandl <georg@python.org> | 2010-11-21 21:07:20 +0100 |
commit | 9a3a3df917ce1fd513b874e974f0e4f21bff6229 (patch) | |
tree | c36d26f7b63cbe487c414a075227e44677b31877 /sphinx/themes/basic/static/websupport.js | |
parent | 27f937867068703d15242d5b65e82d755575cbd2 (diff) | |
download | sphinx-git-9a3a3df917ce1fd513b874e974f0e4f21bff6229.tar.gz |
Highligh comments to moderate.
Diffstat (limited to 'sphinx/themes/basic/static/websupport.js')
-rw-r--r-- | sphinx/themes/basic/static/websupport.js | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/sphinx/themes/basic/static/websupport.js b/sphinx/themes/basic/static/websupport.js index bf8a85d58..dc4cf6ac9 100644 --- a/sphinx/themes/basic/static/websupport.js +++ b/sphinx/themes/basic/static/websupport.js @@ -548,12 +548,14 @@ /** Create a div to display a comment in. */ function createCommentDiv(comment) { if (!comment.displayed && !opts.moderator) { - return $('<div>Thank you! Your comment will show up once it is has ' - + ' been approved by a moderator.</div>'); + return $('<div class="moderate">Thank you! Your comment will show up ' + + 'once it is has been approved by a moderator.</div>'); } // Prettify the comment rating. comment.pretty_rating = comment.rating + ' point' + (comment.rating == 1 ? '' : 's'); + // Make a class (for displaying not yet moderated comments differently) + comment.css_class = comment.displayed ? '' : ' moderate'; // Create a div for this comment. var context = $.extend({}, opts, comment); var div = $(renderTemplate(commentTemplate, context)); @@ -714,7 +716,7 @@ </div>'; var commentTemplate = '\ - <div id="cd<%id%>" class="sphinx-comment">\ + <div id="cd<%id%>" class="sphinx-comment<%css_class%>">\ <div class="vote">\ <div class="arrow">\ <a href="#" id="uv<%id%>" class="vote" title="vote up">\ |