Fix lists in rich text to display properly
Add a "richtext" class to anything which contains text rendered by our rich text library, and move styles which were only being applied to diary entries to apply to all rich text.
This commit is contained in:
parent
f430d2c6e1
commit
1f7dd79daf
10 changed files with 34 additions and 23 deletions
|
@ -1,8 +1,8 @@
|
|||
<div class='clearfix diary-comment'>
|
||||
<div class="clearfix diary-comment">
|
||||
<%= user_thumbnail diary_comment.user %>
|
||||
<p class='deemphasize comment-heading' id="comment<%= diary_comment.id %>"><%= raw(t('diary_entry.diary_comment.comment_from', :link_user => (link_to h(diary_comment.user.display_name), :controller => 'user', :action => 'view', :display_name => diary_comment.user.display_name), :comment_created_at => l(diary_comment.created_at, :format => :friendly))) %></p>
|
||||
<%= diary_comment.body.to_html %>
|
||||
<p class="deemphasize comment-heading" id="comment<%= diary_comment.id %>"><%= raw(t('diary_entry.diary_comment.comment_from', :link_user => (link_to h(diary_comment.user.display_name), :controller => 'user', :action => 'view', :display_name => diary_comment.user.display_name), :comment_created_at => l(diary_comment.created_at, :format => :friendly))) %></p>
|
||||
<div class="richtext"><%= diary_comment.body.to_html %></div>
|
||||
<%= if_administrator(:span) do %>
|
||||
<%= link_to t('diary_entry.diary_comment.hide_link'), hide_diary_comment_path(:display_name => diary_comment.diary_entry.user.display_name, :id => diary_comment.diary_entry.id, :comment => diary_comment.id), :method => :post, :data=> { :confirm => t('diary_entry.diary_comment.confirm') } %>
|
||||
<% end %>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
@ -6,7 +6,8 @@
|
|||
|
||||
<h2><%= link_to h(diary_entry.title), :action => 'view', :display_name => diary_entry.user.display_name, :id => diary_entry.id %></h2>
|
||||
</div>
|
||||
<div xml:lang="<%= diary_entry.language_code %>" lang="<%= diary_entry.language_code %>">
|
||||
|
||||
<div class="richtext" xml:lang="<%= diary_entry.language_code %>" lang="<%= diary_entry.language_code %>">
|
||||
<%= diary_entry.body.to_html %>
|
||||
</div>
|
||||
|
||||
|
|
|
@ -13,7 +13,7 @@
|
|||
<tr class="<%= cl %>">
|
||||
<td width="25%"><%= link_to comment.diary_entry.title, :action => :view, :display_name => comment.diary_entry.user.display_name, :id => comment.diary_entry.id %></td>
|
||||
<td width="25%"><span title="<%= l comment.created_at, :format => :friendly %>"><%= t 'diary_entry.comments.ago', :ago => time_ago_in_words(comment.created_at) %></span></td>
|
||||
<td width="50%"><%= comment.body.to_html %></td>
|
||||
<td width="50%" class="richtext"><%= comment.body.to_html %></td>
|
||||
</tr>
|
||||
<% end -%>
|
||||
</table>
|
||||
|
@ -21,4 +21,4 @@
|
|||
<ul class='secondary-actions clearfix'>
|
||||
<li><%= link_to t('diary_entry.comments.older_comments') , { :page => @comment_pages.current.next} if @comment_pages.current.next %></li>
|
||||
<li><%= link_to t('diary_entry.comments.newer_comments'), { :page => @comment_pages.current.previous } if @comment_pages.current.previous %></li>
|
||||
</ul>
|
||||
</ul>
|
||||
|
|
|
@ -13,7 +13,7 @@
|
|||
</div>
|
||||
</div>
|
||||
|
||||
<%= @message.body.to_html %></td>
|
||||
<div class="richtext"><%= @message.body.to_html %></div>
|
||||
|
||||
<%= link_to t('message.read.back_to_inbox'), :controller => 'message', :action => 'inbox', :display_name => @user.display_name %>
|
||||
|
||||
|
@ -29,8 +29,8 @@
|
|||
</div>
|
||||
</div>
|
||||
|
||||
<%= @message.body.to_html %></td>
|
||||
<div class="richtext"><%= @message.body.to_html %></div>
|
||||
|
||||
<%= link_to t('message.read.back_to_outbox'), :controller => 'message', :action => 'outbox', :display_name => @user.display_name %>
|
||||
|
||||
<% end %>
|
||||
<% end %>
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
<b><%= t 'redaction.show.user' %></b>
|
||||
<%= link_to(@redaction.user.display_name, {:controller => 'user', :action => 'view', :display_name => @redaction.user.display_name}) %>
|
||||
</p>
|
||||
<p>
|
||||
<p class="richtext">
|
||||
<b><%= t 'redaction.show.description' %></b>
|
||||
<%= @redaction.description.to_html %>
|
||||
</p>
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
%>
|
||||
<% end %>
|
||||
</p>
|
||||
<%= user.description.to_html %>
|
||||
<div class="richtext"><%= user.description.to_html %></div>
|
||||
</td>
|
||||
<td>
|
||||
<%= check_box_tag "user_#{user.id}", "", false, :name => "user[#{user.id}]" %>
|
||||
|
|
|
@ -146,7 +146,7 @@
|
|||
</p>
|
||||
</div>
|
||||
|
||||
<div class='user-description'><%= @this_user.description.to_html %></div>
|
||||
<div class="user-description richtext"><%= @this_user.description.to_html %></div>
|
||||
|
||||
</div>
|
||||
|
||||
|
|
|
@ -33,4 +33,4 @@
|
|||
<p><b><%= t'user_block.show.status' %></b>: <%= block_status(@user_block) %></p>
|
||||
|
||||
<p><b><%= t'user_block.show.reason' %></b></p>
|
||||
<%= @user_block.reason.to_html %>
|
||||
<div class="richtext"><%= @user_block.reason.to_html %></div>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue