修复火狐不兼容自动换行的问题

This commit is contained in:
sw 2014-08-28 17:30:08 +08:00
parent 2f1b6386f6
commit fbb19480f5
20 changed files with 24 additions and 23 deletions

View File

@ -4,5 +4,5 @@ $('#relation_file').html('<%=render_attachments_for_new_project(@project, nil)%>
<% elsif @course%>
$('#relation_file').html('<%=render_attachments_for_new_course(@course, nil)%>');
<% end%>
$('#attachments').children().css("width","100%").css("word-break","break-all");
$('#attachments').children().css("width","100%").css("word-break","break-all").css("word-wrap", "break-word");

View File

@ -53,7 +53,7 @@
</span>
<% end %>
</div>
<div style="width: 100%;word-break: break-all;">
<div style="width: 100%;word-break: break-all;word-wrap: break-word;">
<% if @topics.any? %>
<!-- <table class="list messages">
<thead><tr>

View File

@ -6,7 +6,7 @@
<p>
<strong><%= l(:label_bids_reward_method) %><span class="bonus"><%= @contest.budget%></span></strong>
</p>
<div class="bid_description" style="width: 100%;word-break:break-all;">
<div class="bid_description" style="width: 100%;word-break:break-all;word-wrap: break-word;">
<%= @contest.description %>
<!-- <%# if @contest.attachments.any?%>
<%# options = {:author => true} %>

View File

@ -29,7 +29,7 @@
<%= l(:label_new_activity) %> </span>
<%= link_to "#{eventToLanguageCourse(e.event_type, @course)}: "<< format_activity_title(e.event_title), (e.event_type.eql?("attachment")&&e.container.kind_of?(Course)) ? course_files_path(e.container) : e.event_url,:style => "word-break:break-all;" %>
<%= link_to "#{eventToLanguageCourse(e.event_type, @course)}: "<< format_activity_title(e.event_title), (e.event_type.eql?("attachment")&&e.container.kind_of?(Course)) ? course_files_path(e.container) : e.event_url,:style => "word-break:break-all;word-wrap: break-word;" %>
</td>
</tr>
<tr>

View File

@ -37,7 +37,7 @@
</ul>
<% end -%>
<ul class="list-group-item-meta">
<div class="wiki" style="width: 100%;word-break: break-all;">
<div class="wiki" style="width: 100%;word-break: break-all;word-wrap: break-word;">
<%= textilizable issue, :description %>
</div>
</ul>

View File

@ -1,7 +1,7 @@
<h3><%=h @issue.tracker %> #<%= @issue.id %></h3>
<p><%= authoring @journal.created_on, @journal.user, :label => :label_updated_time_by %></p>
<div class="text-diff" style="word-break: break-all;width: 100%;">
<div class="text-diff" style="word-break: break-all;width: 100%;word-wrap: break-word;">
<%= simple_format_without_paragraph @diff.to_html %>
</div>

View File

@ -191,7 +191,7 @@
<div style="padding-bottom: 8px">
<% if @course.description && @course.description.size>0 %>
<div class="font_lighter_sidebar" style="word-break:break-all; word-wrap:break-all;">
<div class="font_lighter_sidebar" style="word-break:break-all; word-wrap:break-word;">
<%= textilizable @course.description %>
</div>

View File

@ -112,7 +112,7 @@
</div>
<div style="padding-bottom: 8px">
<div class="font_lighter_sidebar" style="word-break:break-all">
<div class="font_lighter_sidebar" style="word-break:break-all;word-wrap: break-word;">
<%= textilizable @project.description %>
</div>
<div class="created_on_project">

View File

@ -116,7 +116,7 @@
</p>
<% end %>
<% unless @user.user_extensions.nil? %>
<p style="width: 100%;word-break: break-all">
<p style="width: 100%;word-break: break-all;word-wrap: break-word;">
<%= @user.user_extensions.brief_introduction %>
</p>
<% end %>

View File

@ -46,7 +46,7 @@
</div>
<div class="memo-title <%= @memo.sticky ? 'sticky' : '' %> <%= @memo.locked? ? 'locked' : '' %>" style="word-break: break-all;"><%= label_tag l(:field_subject) %>: <%=h @memo.subject %></div>
<div class="memo-title <%= @memo.sticky ? 'sticky' : '' %> <%= @memo.locked? ? 'locked' : '' %>" style="word-break: break-all;word-wrap: break-word;"><%= label_tag l(:field_subject) %>: <%=h @memo.subject %></div>
<div class="memo-content">
<%= textAreailizable(@memo,:content) %>
<p>

View File

@ -156,7 +156,7 @@
<tr>
<td class="comments">
<div class="wiki" style="width: 100%;word-break: break-all;">
<div class="wiki" style="width: 100%;word-break: break-all;word-wrap: break-word;">
<%= textAreailizable message,:content,:attachments => message.attachments %>
<%#= message.content.html_safe %>
</div>

View File

@ -32,7 +32,7 @@
<%= f.select :board_id, boards_options_for_select(@message.course.boards) %></p>
<% end %>
<% end %>
<div id="message_quote" class="wiki" style="width: 100%;word-break: break-all"></div>
<div id="message_quote" class="wiki" style="width: 100%;word-break: break-all;word-wrap: break-word;"></div>
<%= text_area :quote,:quote,:style => 'display:none' %>
<p>

View File

@ -37,6 +37,7 @@
background-color: #F6F6F6;
white-space: normal;
word-break: break-all;
word-wrap: break-word;
/*word-wrap: break-word;*/
}
.memo-timestamp {
@ -94,7 +95,7 @@
<%= link_to @topic.author, user_path(@topic.author) %>
</p>
</div>
<div class="memo-section" style="width: 100%;word-break: break-all;">
<div class="memo-section" style="width: 100%;word-break: break-all;word-wrap: break-word;">
<div class="memo-title <%= @topic.sticky? ? 'sticky' : '' %> <%= @topic.locked? ? 'locked' : '' %>" style="width: 83%;word-break: break-all;">
<% if @project %>
<%= label_tag l(:field_subject) %>: <%= link_to @topic.subject.truncate(24, omission: '...'), project_boards_path(@topic.project),title: @topic.subject.to_s %>
@ -161,7 +162,7 @@
</tr>
<tr>
<td class="comments">
<div class="wiki" style="width: 100%;word-break: break-all;">
<div class="wiki" style="width: 100%;word-break: break-all;word-wrap: break-word;">
<%= textAreailizable message,:content,:attachments => message.attachments %>
<%#= message.content.html_safe %>
</div>

View File

@ -4,7 +4,7 @@
<%= course_board_breadcrumb(@message) %>
<% end %>
<h3><%= avatar(@topic.author, :size => "24") %><span style = "width:100%;word-break:break-all;"><%=h @topic.subject %></span></h3>
<h3><%= avatar(@topic.author, :size => "24") %><span style = "width:100%;word-break:break-all;word-wrap: break-word;"><%=h @topic.subject %></span></h3>
<%= form_for @message, {
:as => :message,

View File

@ -7,7 +7,7 @@
<% @events_by_day.keys.sort.reverse.each do |day| %>
<% sort_activity_events(@events_by_day[day]).each do |e, in_group| -%>
<div class="activity-item underline-evreycontent" style="font-size: 14px;line-height:1.5em;width: 100%;word-break: break-all;">
<div class="activity-item underline-evreycontent" style="font-size: 14px;line-height:1.5em;width: 100%;word-wrap: break-word;word-break: break-all;">
<div class="activity-avatar" style="float: left; margin:3px; height: 100%;">
<%= image_tag(url_to_avatar(e.event_author), :class => "avatar") %>
</div>
@ -24,7 +24,7 @@
</span>
<%= link_to "#{eventToLanguageCourse(e.event_type, @project)}: "<< format_activity_title(e.event_title), (e.event_type.eql?("attachment")&&e.container.kind_of?(Project)) ? project_files_path(e.container) : e.event_url %>
<div class="activity_description info-break" style="font-size: 13px;width: 100%;word-break: break-all;">
<div class="activity_description info-break" style="font-size: 13px;width: 100%;word-break: break-all;word-wrap: break-word;">
<%= textAreailizable e,:event_description %>
<%#= h(truncate(strip_tags(e.event_description).gsub(/&nbsp;/, ' '), length: 30, omission: '...')) %>
</div>

View File

@ -30,7 +30,7 @@
</span></td>
</tr>
<tr>
<td colspan="2" width="580" style="word-break:break-all">
<td colspan="2" width="580" style="word-break:break-all;word-wrap: break-word;">
<p class="font_description">
<%= textilizable membership.course.short_description %>
</p>

View File

@ -28,7 +28,7 @@
<span class="font_lighter"> <%= l(:label_peoject_take_in) %></span> <%= link_to_project(membership.project) %></td>
</tr>
<tr>
<td colspan="2" width="580" style="word-break:break-all">
<td colspan="2" width="580" style="word-break:break-all;word-wrap: break-word;">
<p class="font_description">
<%= membership.project.short_description%>
</p></td>

View File

@ -158,7 +158,7 @@
<div class="d-p-projectlist">
<% find_all_hot_contest.map do |contest| break if(contest == find_all_hot_contest[5]) %>
<li style="overflow:auto;word-break:break-all;height:100%;" class='<%= cycle("odd", "even") %>'>
<li style="overflow:auto;word-break:break-all;height:100%;word-wrap: break-word;" class='<%= cycle("odd", "even") %>'>
<div class="avatar-4" style="float: left; margin-top: 7px">
<%= image_tag('/images/contest1.png')%>
</div>
@ -197,7 +197,7 @@
<span style="margin-top: -20px;float: right; display: block;"><%#= link_to l(:label_more_information), forums_path %></span>
<div style="height: 167px; padding-top:6px;">
<fieldset style="padding-left: 36px; margin-left: 13px; height: 150px; width:380px; border-radius:10px;">
<div style="font-size:14px; color: #1166AD;text-align:center;word-break: break-all; "><strong style="margin:auto;"><%= @contestNotification.title %></strong></div>
<div style="font-size:14px; color: #1166AD;text-align:center;word-break: break-all;word-wrap: break-word; "><strong style="margin:auto;"><%= @contestNotification.title %></strong></div>
<div class="underline-contests_four"></div>
<div id="up_zzjs">
<div id="marqueebox">

View File

@ -66,7 +66,7 @@
<% #projects = find_miracle_project(10, 3) %>
<% @projects.map do |project| %>
<!--<%# cache cache_key_for_project(project) do %> -->
<li style="overflow:auto;word-break:break-all;height:100%;" class='<%= cycle("odd", "even") %>'>
<li style="overflow:auto;word-break:break-all;height:100%;word-wrap: break-word;" class='<%= cycle("odd", "even") %>'>
<div style="float: left;">
<%= image_tag(get_project_avatar(project), :class => "avatar-4") %>
</div>

View File

@ -22,6 +22,6 @@
%>, <%= format_time(@diff.content_to.updated_on) %>)</em>
</p>
<div class="text-diff" style=" width: 100%;word-break: break-all;">
<div class="text-diff" style=" width: 100%;word-break: break-all;word-wrap: break-word;">
<%= simple_format_without_paragraph @diff.to_html %>
</div>