Commit 708f1c56d68c466ca60e2d3219933312c72aba82

Authored by Aurelio A. Heckert
1 parent 5f4b212f

ActionItem692: the text "no comments yet" is smaller and low opac. Also the comm…

…ents counting was removed where comments are not acepted.
app/views/content_viewer/view_page.rhtml
... ... @@ -76,14 +76,18 @@
76 76 </div>
77 77 <% end %>
78 78  
79   - <h3>
80   - <%= @comments.size == 0 ? _('No comments yet') : (n_('One comment', '%{comments} comments', @comments.size)) % { :comments => @comments.size} %>
81   - </h3>
82   - <%= render :partial => 'comment', :collection => @comments %>
83   -<% if !@page.accept_comments? %>
84   - <h3><%= _('This article does not accept comments')%></h3>
85   -<% else %>
86   - <%= render :partial => 'comment_form' %>
87   -<% end %>
  79 +
  80 +<div class="comments">
  81 + <% if !@page.accept_comments? %>
  82 + <i class="do-not-comment"><%= _('This article does not accept comments')%></i>
  83 + <% else %>
  84 + <h3 <%= 'class="no-comments-yet"' if @comments.size == 0 %>>
  85 + <%= @comments.size == 0 ? _('No comments yet') :
  86 + (n_('One comment', '%{comments} comments', @comments.size)) % { :comments => @comments.size}
  87 + %></h3>
  88 + <%= render :partial => 'comment', :collection => @comments %>
  89 + <%= render :partial => 'comment_form' %>
  90 + <% end %>
  91 +</div><!-- end class="comments" -->
88 92  
89 93 </div><!-- end id="article" -->
... ...
public/stylesheets/article.css
... ... @@ -29,6 +29,24 @@
29 29  
30 30 /* * * Comments * * */
31 31  
  32 +.comments { }
  33 +
  34 +#content .no-comments-yet {
  35 + text-align: center;
  36 + font-size: 80%;
  37 + opacity: 0.5;
  38 + filter: alpha(opacity=50);
  39 +}
  40 +
  41 +.do-not-comment {
  42 + display: block;
  43 + text-align: right;
  44 + padding-top: 15px;
  45 + font-size: 80%;
  46 + opacity: 0.5;
  47 + filter: alpha(opacity=50);
  48 +}
  49 +
32 50 .article-comment {
33 51 position: relative;
34 52 border: 1px solid #B8CFE7;
... ...