erblint: fix remaining single quoted strings

This commit is contained in:
Tom Hughes 2019-03-27 16:15:19 +00:00
parent 50091893d4
commit 3af16f6337
103 changed files with 666 additions and 685 deletions

View file

@ -1,6 +1,6 @@
<div class="clearfix diary-comment">
<%= user_thumbnail diary_comment.user %>
<p class="deemphasize comment-heading" id="comment<%= diary_comment.id %>"><%= raw(t('.comment_from', :link_user => (link_to h(diary_comment.user.display_name), user_path(diary_comment.user)), :comment_created_at => link_to(l(diary_comment.created_at, :format => :friendly), :anchor => "comment#{diary_comment.id}"))) %>
<p class="deemphasize comment-heading" id="comment<%= diary_comment.id %>"><%= raw(t(".comment_from", :link_user => (link_to h(diary_comment.user.display_name), user_path(diary_comment.user)), :comment_created_at => link_to(l(diary_comment.created_at, :format => :friendly), :anchor => "comment#{diary_comment.id}"))) %>
<% if current_user and diary_comment.user.id != current_user.id %>
| <%= report_link(t(".report"), diary_comment) %>
<% end %>
@ -9,7 +9,7 @@
<div class="richtext"><%= diary_comment.body.to_html %></div>
<% if current_user && current_user.administrator? %>
<span>
<%= link_to t('.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('.confirm') } %>
<%= link_to t(".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(".confirm") } %>
</span>
<% end %>
</div>

View file

@ -7,7 +7,7 @@
<h2><%= link_to h(diary_entry.title), diary_entry_path(diary_entry.user, diary_entry) %></h2>
<small class='deemphasize'>
<%= raw(t '.posted_by', :link_user => (link_to h(diary_entry.user.display_name), user_path(diary_entry.user)), :created => l(diary_entry.created_at, :format => :blog), :language_link => (link_to h(diary_entry.language.name), :controller => 'diary_entries', :action => 'index', :display_name => nil, :language => diary_entry.language_code)) %>
<%= raw(t ".posted_by", :link_user => (link_to h(diary_entry.user.display_name), user_path(diary_entry.user)), :created => l(diary_entry.created_at, :format => :blog), :language_link => (link_to h(diary_entry.language.name), :controller => "diary_entries", :action => "index", :display_name => nil, :language => diary_entry.language_code)) %>
</small>
</div>
@ -22,13 +22,13 @@
<ul class='secondary-actions clearfix'>
<% if params[:action] == 'index' %>
<li><%= link_to t('.comment_link'), diary_entry_path(diary_entry.user, diary_entry, :anchor => 'newcomment') %></li>
<li><%= link_to t('.reply_link'), new_message_path(diary_entry.user, :message => { :title => "Re: #{diary_entry.title}" }) %></li>
<li><%= link_to t('.comment_count', :count => diary_entry.visible_comments.count), diary_entry_path(diary_entry.user, diary_entry, :anchor => 'comments') %></li>
<li><%= link_to t(".comment_link"), diary_entry_path(diary_entry.user, diary_entry, :anchor => "newcomment") %></li>
<li><%= link_to t(".reply_link"), new_message_path(diary_entry.user, :message => { :title => "Re: #{diary_entry.title}" }) %></li>
<li><%= link_to t(".comment_count", :count => diary_entry.visible_comments.count), diary_entry_path(diary_entry.user, diary_entry, :anchor => "comments") %></li>
<% end %>
<% if current_user && current_user == diary_entry.user %>
<li><%= link_to t('.edit_link'), :action => 'edit', :display_name => diary_entry.user.display_name, :id => diary_entry.id %></li>
<li><%= link_to t(".edit_link"), :action => "edit", :display_name => diary_entry.user.display_name, :id => diary_entry.id %></li>
<% end %>
<% if current_user and diary_entry.user != current_user %>
@ -39,7 +39,7 @@
<% if current_user && current_user.administrator? %>
<li>
<%= link_to t('.hide_link'), hide_diary_entry_path(:display_name => diary_entry.user.display_name, :id => diary_entry.id), :method => :post, :data => { :confirm => t('.confirm') } %>
<%= link_to t(".hide_link"), hide_diary_entry_path(:display_name => diary_entry.user.display_name, :id => diary_entry.id), :method => :post, :data => { :confirm => t(".confirm") } %>
</li>
<% end %>
</ul>

View file

@ -1,6 +1,6 @@
<%= t '.location' %>
<%= t ".location" %>
<a href="<%= url_for :controller => 'site', :action => 'index', :anchor => "map=14/#{location.latitude}/#{location.longitude}" %>">
<a href="<%= url_for :controller => "site", :action => "index", :anchor => "map=14/#{location.latitude}/#{location.longitude}" %>">
<abbr class="geo" title="<%= number_with_precision(location.latitude, :precision => 4) %>; <%= number_with_precision(location.longitude, :precision => 4) %>">
<%= describe_location location.latitude, location.longitude, 14, location.language_code %>
</abbr>

View file

@ -1,24 +1,24 @@
<% content_for :heading do %>
<h1><%= t('.has_commented_on', :display_name => @user.display_name) %></h1>
<h1><%= t(".has_commented_on", :display_name => @user.display_name) %></h1>
<% end %>
<table class="messages" width="100%">
<tr>
<th width="25%"><%= t '.post' %></th>
<th width="25%"><%= t '.when' %></th>
<th width="50%"><%= t '.comment' %></th>
<th width="25%"><%= t ".post" %></th>
<th width="25%"><%= t ".when" %></th>
<th width="50%"><%= t ".comment" %></th>
</tr>
<% @comments.each do |comment| -%>
<% cl = cycle('table0', 'table1') %>
<% cl = cycle("table0", "table1") %>
<tr class="<%= cl %>">
<td width="25%"><%= link_to comment.diary_entry.title, diary_entry_path(comment.diary_entry.user, comment.diary_entry) %></td>
<td width="25%"><span title="<%= l comment.created_at, :format => :friendly %>"><%= t '.ago', :ago => time_ago_in_words(comment.created_at) %></span></td>
<td width="25%"><span title="<%= l comment.created_at, :format => :friendly %>"><%= t ".ago", :ago => time_ago_in_words(comment.created_at) %></span></td>
<td width="50%" class="richtext"><%= comment.body.to_html %></td>
</tr>
<% end -%>
</table>
<div class='secondary-actions clearfix'>
<span><%= link_to t('.older_comments'), :page => @comment_pages.current.next if @comment_pages.current.next %>
<%= link_to t('.newer_comments'), :page => @comment_pages.current.previous if @comment_pages.current.previous %></span>
<span><%= link_to t(".older_comments"), :page => @comment_pages.current.next if @comment_pages.current.next %>
<%= link_to t(".newer_comments"), :page => @comment_pages.current.previous if @comment_pages.current.previous %></span>
</div>

View file

@ -6,46 +6,46 @@
<h1><%= @title %></h1>
<% end %>
<%= error_messages_for 'diary_entry' %>
<%= error_messages_for "diary_entry" %>
<%= form_for :diary_entry do |f| %>
<div class="diary_entry standard-form">
<fieldset>
<div class='form-row'>
<label class="standard-label"><%= t '.subject' -%></label>
<label class="standard-label"><%= t ".subject" -%></label>
<%= f.text_field :title, :class => "richtext_title" %>
</div>
<div class='form-row'>
<label class="standard-label"><%= t '.body' -%></label>
<label class="standard-label"><%= t ".body" -%></label>
<%= richtext_area :diary_entry, :body, :cols => 80, :rows => 20, :format => @diary_entry.body_format %>
</div>
<div class='form-row'>
<label class="standard-label"><%= t '.language' -%></label>
<label class="standard-label"><%= t ".language" -%></label>
<%= f.collection_select :language_code, Language.order(:english_name), :code, :name %>
</div>
</fieldset>
<fieldset class='location'>
<label class="standard-label"><%= t '.location' -%></label>
<label class="standard-label"><%= t ".location" -%></label>
<%= content_tag "div", "", :id => "map", :data => { :lat => @lat, :lon => @lon, :zoom => @zoom } %>
<div class='form-row clearfix'>
<div class='form-column'>
<label class="secondary standard-label"><%= t '.latitude' -%></label>
<label class="secondary standard-label"><%= t ".latitude" -%></label>
<%= f.text_field :latitude, :size => 20, :id => "latitude" %>
</div>
<div class='form-column'>
<label class="secondary standard-label"><%= t '.longitude' -%></label>
<label class="secondary standard-label"><%= t ".longitude" -%></label>
<%= f.text_field :longitude, :size => 20, :id => "longitude" %>
</div>
<div class='form-column'>
<a href="#" id="usemap"><%= t '.use_map_link' -%></a>
<a href="#" id="usemap"><%= t ".use_map_link" -%></a>
</div>
</div>
</fieldset>
<% if action_name == 'new' %>
<%= submit_tag t('diary_entries.new.publish_button') %>
<%= submit_tag t("diary_entries.new.publish_button") %>
<% else %>
<%= submit_tag t('.save_button') %>
<%= submit_tag t(".save_button") %>
<% end %>
</div>
<% end %>

View file

@ -7,19 +7,19 @@
<ul class='secondary-actions clearfix'>
<% unless params[:friends] or params[:nearby] -%>
<li><%= rss_link_to :action => 'rss', :language => params[:language] %></li>
<li><%= rss_link_to :action => "rss", :language => params[:language] %></li>
<% end -%>
<% if @user %>
<% if @user == current_user %>
<div>
<li><%= link_to image_tag("new.png", :class => "small_icon", :border => 0) + t('.new'), diary_new_path, :title => t('.new_title') %></li>
<li><%= link_to image_tag("new.png", :class => "small_icon", :border => 0) + t(".new"), diary_new_path, :title => t(".new_title") %></li>
</div>
<% end %>
<% else %>
<% if current_user %>
<div>
<li><%= link_to image_tag("new.png", :class => "small_icon", :border => 0) + t('.new'), diary_new_path, :title => t('.new_title') %></li>
<li><%= link_to image_tag("new.png", :class => "small_icon", :border => 0) + t(".new"), diary_new_path, :title => t(".new_title") %></li>
</div>
<% end %>
<% end %>
@ -28,35 +28,35 @@
<% end %>
<% if @entries.empty? %>
<h4><%= t '.no_entries' %></h4>
<h4><%= t ".no_entries" %></h4>
<% else %>
<h4><%= t '.recent_entries' %></h4>
<h4><%= t ".recent_entries" %></h4>
<% if @user %>
<%= render :partial => 'diary_entry', :collection => @entries %>
<%= render :partial => "diary_entry", :collection => @entries %>
<% else %>
<%= render :partial => 'diary_index_entry', :collection => @entries %>
<%= render :partial => "diary_index_entry", :collection => @entries %>
<% end %>
<div class="pagination">
<% if @entries.size < @page_size -%>
<%= t('.older_entries') %>
<%= t(".older_entries") %>
<% else -%>
<%= link_to t('.older_entries'), @params.merge(:page => @page + 1) %>
<%= link_to t(".older_entries"), @params.merge(:page => @page + 1) %>
<% end -%>
|
<% if @page > 1 -%>
<%= link_to t('.newer_entries'), @params.merge(:page => @page - 1) %>
<%= link_to t(".newer_entries"), @params.merge(:page => @page - 1) %>
<% else -%>
<%= t('.newer_entries') %>
<%= t(".newer_entries") %>
<% end -%>
</div>
<% end %>
<% unless params[:friends] or params[:nearby] -%>
<% content_for :auto_discovery_link_tag do -%>
<%= auto_discovery_link_tag :rss, :action => 'rss', :language => params[:language] %>
<%= auto_discovery_link_tag :rss, :action => "rss", :language => params[:language] %>
<% end -%>
<% end -%>

View file

@ -1,5 +1,5 @@
<% content_for :heading do %>
<h2><%= t '.heading', :id => h(params[:id]) %></h2>
<h2><%= t ".heading", :id => h(params[:id]) %></h2>
<% end %>
<p><%= t '.body', :id => h(params[:id]) %></p>
<p><%= t ".body", :id => h(params[:id]) %></p>

View file

@ -1,35 +1,35 @@
<% content_for :heading do %>
<div id="userinformation" >
<%= user_image @entry.user %>
<h2><%= link_to t('.user_title', :user => h(@entry.user.display_name)), :action => :index %></h2>
<h2><%= link_to t(".user_title", :user => h(@entry.user.display_name)), :action => :index %></h2>
<p><%= rss_link_to :action => :rss, :display_name => @entry.user.display_name %></p>
</div>
<% end %>
<%= render :partial => 'diary_entry', :object => @entry %>
<%= render :partial => "diary_entry", :object => @entry %>
<a id="comments"></a>
<div class='comments'>
<%= render :partial => 'diary_comment', :collection => @entry.visible_comments %>
<%= render :partial => "diary_comment", :collection => @entry.visible_comments %>
</div>
<div>
<% if current_user %>
<h3 id="newcomment"><%= t '.leave_a_comment' %></h3>
<h3 id="newcomment"><%= t ".leave_a_comment" %></h3>
<%= error_messages_for 'diary_comment' %>
<%= error_messages_for "diary_comment" %>
<%= form_for :diary_comment, :url => { :action => 'comment' } do |f| %>
<%= form_for :diary_comment, :url => { :action => "comment" } do |f| %>
<%= richtext_area :diary_comment, :body, :cols => 80, :rows => 15 %>
<%= submit_tag t('.save_button') %>
<%= submit_tag t(".save_button") %>
<% end %>
<% if @entry.subscribers.exists?(current_user.id) %>
<div class="diary-subscribe-buttons"><%= link_to t('javascripts.changesets.show.unsubscribe'), diary_entry_unsubscribe_path(:display_name => @entry.user.display_name, :id => @entry.id), :method => :post, :class => :button %></div>
<div class="diary-subscribe-buttons"><%= link_to t("javascripts.changesets.show.unsubscribe"), diary_entry_unsubscribe_path(:display_name => @entry.user.display_name, :id => @entry.id), :method => :post, :class => :button %></div>
<% else %>
<div class="diary-subscribe-buttons"><%= link_to t('javascripts.changesets.show.subscribe'), diary_entry_subscribe_path(:display_name => @entry.user.display_name, :id => @entry.id), :method => :post, :class => :button %></div>
<div class="diary-subscribe-buttons"><%= link_to t("javascripts.changesets.show.subscribe"), diary_entry_subscribe_path(:display_name => @entry.user.display_name, :id => @entry.id), :method => :post, :class => :button %></div>
<% end %>
<% else %>
<h3 id="newcomment"><%= raw t(".login_to_leave_a_comment", :login_link => link_to(t(".login"), :controller => 'users', :action => 'login', :referer => request.fullpath)) %></h3>
<h3 id="newcomment"><%= raw t(".login_to_leave_a_comment", :login_link => link_to(t(".login"), :controller => "users", :action => "login", :referer => request.fullpath)) %></h3>
<% end %>
</div>