From: Andy Allan Date: Wed, 6 Mar 2019 09:50:33 +0000 (+0100) Subject: Whitespace fixes for users erb files X-Git-Tag: live~2635^2~13 X-Git-Url: https://git.openstreetmap.org/rails.git/commitdiff_plain/5029db24fa9a5b67cdbc52cb97fc359463785dc5 Whitespace fixes for users erb files --- diff --git a/app/views/users/_contact.html.erb b/app/views/users/_contact.html.erb index 5c3afaa89..1eef86b87 100644 --- a/app/views/users/_contact.html.erb +++ b/app/views/users/_contact.html.erb @@ -3,10 +3,10 @@ :lon => contact.home_lon, :lat => contact.home_lat, :icon => image_path(type == "friend" ? "marker-blue.png" : "marker-green.png"), - :description => render(:partial => "popup", :object => contact, :locals => {:type => type}) + :description => render(:partial => "popup", :object => contact, :locals => { :type => type }) } %> -<%= content_tag :div, :class => "contact-activity clearfix", :data => {:user => user_data} do %> +<%= content_tag :div, :class => "contact-activity clearfix", :data => { :user => user_data } do %> <%= user_thumbnail contact %>

@@ -26,11 +26,10 @@ <%= t('users.show.latest edit', :ago => t('users.show.ago', :time_in_words_ago => time_ago_in_words(changeset.created_at))) %> <% comment = changeset.tags['comment'].to_s != '' ? changeset.tags['comment'] : t('browse.no_comment') %> "<%= link_to(comment, - {:controller => 'browse', :action => 'changeset', :id => changeset.id}, - {:title => t('changesets.changeset.view_changeset_details')}) - %>" + { :controller => 'browse', :action => 'changeset', :id => changeset.id }, + { :title => t('changesets.changeset.view_changeset_details') }) %>" <% else %> - <%= t'changesets.changeset.no_edits' %> + <%= t 'changesets.changeset.no_edits' %> <% end %>

diff --git a/app/views/users/_user.html.erb b/app/views/users/_user.html.erb index b9b7bc963..ae8b96383 100644 --- a/app/views/users/_user.html.erb +++ b/app/views/users/_user.html.erb @@ -8,15 +8,13 @@

<% if user.creation_ip %> <%= raw t 'users.index.summary', - :name => link_to(h(user.display_name), user_path(user)), - :ip_address => link_to(user.creation_ip, :ip => user.creation_ip), - :date => l(user.creation_time, :format => :friendly) - %> + :name => link_to(h(user.display_name), user_path(user)), + :ip_address => link_to(user.creation_ip, :ip => user.creation_ip), + :date => l(user.creation_time, :format => :friendly) %> <% else %> <%= raw t 'users.index.summary_no_ip', - :name => link_to(h(user.display_name), user_path(user)), - :date => l(user.creation_time, :format => :friendly) - %> + :name => link_to(h(user.display_name), user_path(user)), + :date => l(user.creation_time, :format => :friendly) %> <% end %>

<%= user.description.to_html %>
diff --git a/app/views/users/account.html.erb b/app/views/users/account.html.erb index 233f2629f..d2db19ea6 100644 --- a/app/views/users/account.html.erb +++ b/app/views/users/account.html.erb @@ -36,12 +36,12 @@
- <%= f.password_field :pass_crypt, {:value => '', :autocomplete => :off} %> + <%= f.password_field :pass_crypt, { :value => '', :autocomplete => :off } %>
- <%= f.password_field :pass_crypt_confirmation, {:value => '', :autocomplete => :off} %> + <%= f.password_field :pass_crypt_confirmation, { :value => '', :autocomplete => :off } %>
@@ -149,7 +149,7 @@
-
class="nohome"<%end%> > +
class="nohome"<% end %> >

<%= t '.no home location' %>

diff --git a/app/views/users/confirm.html.erb b/app/views/users/confirm.html.erb index 7b8d78d3f..167801cbb 100644 --- a/app/views/users/confirm.html.erb +++ b/app/views/users/confirm.html.erb @@ -26,5 +26,5 @@

<%= t ".reconfirm_html", - :reconfirm => url_for(:action => 'confirm_resend')%>

+ :reconfirm => url_for(:action => 'confirm_resend') %>

<% end %> diff --git a/app/views/users/index.html.erb b/app/views/users/index.html.erb index 960cf1128..deb0eab4c 100644 --- a/app/views/users/index.html.erb +++ b/app/views/users/index.html.erb @@ -17,12 +17,11 @@ <%= t '.showing', - :page => @user_pages.current_page.number, - :first_item => @user_pages.current_page.first_item, - :last_item => @user_pages.current_page.last_item, - :items => @user_pages.item_count, - :count => @user_pages.current_page.last_item - @user_pages.current_page.first_item + 1 - %> + :page => @user_pages.current_page.number, + :first_item => @user_pages.current_page.first_item, + :last_item => @user_pages.current_page.last_item, + :items => @user_pages.item_count, + :count => @user_pages.current_page.last_item - @user_pages.current_page.first_item + 1 %> <% if @user_pages.page_count > 1 %> | <%= raw pagination_links_each(@user_pages, {}) { |n| link_to n, @params.merge(:page => n) } %> <% end %> diff --git a/app/views/users/lost_password.html.erb b/app/views/users/lost_password.html.erb index 6f50526d9..d57f03ed9 100644 --- a/app/views/users/lost_password.html.erb +++ b/app/views/users/lost_password.html.erb @@ -7,7 +7,7 @@ <%= form_tag :action => 'lost_password' do %>
- <%= text_field('user', 'email', { :tabindex => 1} ) %> + <%= text_field('user', 'email', { :tabindex => 1 }) %> <%= submit_tag t('.new password button'), :tabindex => 2 %>
<% end %> diff --git a/app/views/users/reset_password.html.erb b/app/views/users/reset_password.html.erb index 51983b94a..4138bf90d 100644 --- a/app/views/users/reset_password.html.erb +++ b/app/views/users/reset_password.html.erb @@ -9,11 +9,11 @@
- <%= password_field(:user, :pass_crypt, {:value => '', :tabindex => 4}) %> + <%= password_field(:user, :pass_crypt, { :value => '', :tabindex => 4 }) %>
- <%= password_field(:user, :pass_crypt_confirmation, {:value => '', :tabindex => 5}) %> + <%= password_field(:user, :pass_crypt_confirmation, { :value => '', :tabindex => 5 }) %>
<%= submit_tag t('.reset'), :tabindex => 6 %>
diff --git a/app/views/users/show.html.erb b/app/views/users/show.html.erb index f62550928..4f08b6351 100644 --- a/app/views/users/show.html.erb +++ b/app/views/users/show.html.erb @@ -11,7 +11,7 @@ <%= number_with_delimiter(current_user.changesets.size) %>
  • - <%= link_to t('.my notes'), :controller => 'notes', :action=> 'mine' %> + <%= link_to t('.my notes'), :controller => 'notes', :action => 'mine' %>
  • <%= link_to t('.my traces'), :controller => 'traces', :action => 'mine' %> @@ -22,7 +22,7 @@ <%= number_with_delimiter(current_user.diary_entries.size) %>
  • - <%= link_to t('.my comments' ), :controller => 'diary_entries', :action => 'comments', :display_name => current_user.display_name %> + <%= link_to t('.my comments'), :controller => 'diary_entries', :action => 'comments', :display_name => current_user.display_name %>
  • <%= link_to t('.my settings'), :controller => 'users', :action => 'account', :display_name => current_user.display_name %> @@ -53,7 +53,7 @@ <%= number_with_delimiter(@user.changesets.size) %>
  • - <%= link_to t('.notes'), :controller => 'notes', :action=> 'mine' %> + <%= link_to t('.notes'), :controller => 'notes', :action => 'mine' %>
  • <%= link_to t('.traces'), :controller => 'traces', :action => 'index', :display_name => @user.display_name %> @@ -190,10 +190,10 @@ :lon => current_user.home_lon, :lat => current_user.home_lat, :icon => image_path("marker-red.png"), - :description => render(:partial => "popup", :object => current_user, :locals => {:type => "your location"}) + :description => render(:partial => "popup", :object => current_user, :locals => { :type => "your location" }) } %> - <%= content_tag "div", "", :id => "map", :class => "content_map", :data => {:user => user_data} %> + <%= content_tag "div", "", :id => "map", :class => "content_map", :data => { :user => user_data } %> <% end %> <% friends = @user.friends.collect { |f| f.befriendee } %> @@ -210,7 +210,7 @@
  • <%= link_to t('.friends_diaries'), friend_diaries_path %>
  • - <%= render :partial => "contact", :collection => friends, :locals => {:type => "friend"} %> + <%= render :partial => "contact", :collection => friends, :locals => { :type => "friend" } %>
    <% end %>
    @@ -226,7 +226,7 @@
  • <%= link_to t('.nearby_diaries'), nearby_diaries_path %>
  • - <%= render :partial => "contact", :collection => nearby, :locals => {:type => "nearby mapper"} %> + <%= render :partial => "contact", :collection => nearby, :locals => { :type => "nearby mapper" } %>
    <% end %>
    diff --git a/app/views/users/terms.html.erb b/app/views/users/terms.html.erb index a836c8590..acd617653 100644 --- a/app/views/users/terms.html.erb +++ b/app/views/users/terms.html.erb @@ -7,7 +7,7 @@
    <% end %> -<%= form_tag({:action => "save"}, { :class => " inner22 standard-form fillL" }) do %> +<%= form_tag({ :action => "save" }, { :class => " inner22 standard-form fillL" }) do %>
    - (<%= link_to(t('.consider_pd_why'), t('.consider_pd_why_url'), :target => :new)%>) + (<%= link_to(t('.consider_pd_why'), t('.consider_pd_why_url'), :target => :new) %>) <%= hidden_field_tag('referer', h(params[:referer])) unless params[:referer].nil? %>