From c3b8897c44531788f06a51e24470e97a3abfb7b8 Mon Sep 17 00:00:00 2001 From: Saman Bemel-Benrud Date: Tue, 11 Jun 2013 17:57:10 -0700 Subject: [PATCH] Improve layout and styling of forms --- app/assets/stylesheets/common.css.scss | 120 +++++++--- app/helpers/application_helper.rb | 4 +- app/views/diary_entry/comments.html.erb | 4 +- app/views/diary_entry/edit.html.erb | 51 ++-- app/views/export/start.html.erb | 14 +- app/views/message/_message_summary.html.erb | 2 +- .../message/_sent_message_summary.html.erb | 2 +- app/views/message/new.html.erb | 29 +-- app/views/message/read.html.erb | 13 +- app/views/oauth_clients/_form.html.erb | 52 ++-- app/views/oauth_clients/edit.html.erb | 1 - app/views/oauth_clients/new.html.erb | 12 +- app/views/oauth_clients/show.html.erb | 51 ++-- app/views/trace/create.html.erb | 37 +-- app/views/trace/edit.html.erb | 60 +++-- app/views/user/account.html.erb | 222 ++++++++++-------- app/views/user/login.html.erb | 6 +- app/views/user/new.html.erb | 23 +- 18 files changed, 410 insertions(+), 293 deletions(-) diff --git a/app/assets/stylesheets/common.css.scss b/app/assets/stylesheets/common.css.scss index 4c1345eaa..148d4368a 100644 --- a/app/assets/stylesheets/common.css.scss +++ b/app/assets/stylesheets/common.css.scss @@ -4,6 +4,7 @@ $typeheight: 14px; $offwhite: #f4f4ff; $blue: #7092FF; +$lightblue: #B8C5F0; $grey: #AAA; $keyline: #CCC; $hovercolor: 20%; @@ -12,7 +13,7 @@ $hovercolor: 20%; /* Minimal CSS reset */ -html, body, ul, ol, li, form, fieldset, legend, h1, h2, h3, h4, h5, h6, p { +html, body, ul, ol, li, form, fieldset, legend, h1, h2, h3, h4, h5, h6, p, input { margin: 0; padding: 0; border: 0; @@ -488,7 +489,7 @@ table { .count-number { padding: 2px $lineheight/4; - border-radius: 3px; + border-radius: 2px; background: #d7d7ff; margin: 0 2px; font-size: 11px; @@ -738,6 +739,10 @@ ul.results-list li { border-bottom: 1px solid #ccc; } .export_area_inputs { margin-bottom: $lineheight/2; + input[type="text"] { + width: 60px; + margin-bottom: 5px; + } } .export_bound { @@ -1285,8 +1290,16 @@ ul.results-list li { border-bottom: 1px solid #ccc; } border: 1px solid #ccc; } -.accountImage-options p { - margin-bottom: 0px; +#accountForm .user_image { + margin-bottom: 0; +} + +#accountForm #user_image { + margin-left: 20px; +} + +#accountForm ul.accountImage-options { + margin-left: 120px; } .nohome .location { @@ -1306,12 +1319,18 @@ ul.results-list li { border-bottom: 1px solid #ccc; } float: none; } -/* Rules for message in/out box page */ +/* Rules for the oauth settings page */ -.message #content { - max-width: 740px; +.oauth_clients .buttons .oauth-edit { + border-radius: 2px 0 0 2px; } +.oauth_clients .buttons .oauth-delete { + border-radius: 0 2px 2px 0; +} + +/* Rules for messages pages */ + .messages { width: 100%; border: 1px solid #ddd; @@ -1340,6 +1359,7 @@ ul.results-list li { border-bottom: 1px solid #ccc; } padding: $lineheight/4; } tr td { + height: 30px; border-right: 1px solid $keyline; } } @@ -1362,10 +1382,26 @@ ul.results-list li { border-bottom: 1px solid #ccc; } vertical-align: middle; } +.inbox-mark-unread, +.inbox-mark-read, +.inbox-delete { + width: 1%; +} + .inbox-row-unread .inbox-mark-unread { display: none; } +.message-read .message-buttons { + margin-top: $lineheight; + padding-top: $lineheight; + border-top: 1px solid $keyline; +} + +.message-read .buttons .mark-unread-button { + border-radius: 0; +} + /* Rules for "flash" notice boxes shown at the top of the content area */ .flash { @@ -1426,15 +1462,25 @@ ul.results-list li { border-bottom: 1px solid #ccc; } fieldset { margin-bottom: $lineheight; } - label { + label.standard-label { display: block; - width: 300px; margin-bottom: $lineheight/4; font-size: $typeheight; font-weight: bold; line-height: 1.5; } - .form-section { + label.standard-label.secondary { + display: inline-block; + font-weight: normal; + } + .form-help { + font-weight: normal; + } + .form-column { + float: left; + margin-right: 20px; + } + .form-divider { margin-top: $lineheight; padding-top: $lineheight; border-top: 1px solid $keyline; @@ -1442,9 +1488,17 @@ ul.results-list li { border-bottom: 1px solid #ccc; } .form-row { margin-bottom: $lineheight/2; } - input[name=remember_me], - input[name=remember_me_openid] { + .form-list { + margin-bottom: 0; + } + .form-list li { + margin-bottom: 5px; + } + input[type="checkbox"], + input[type="radio"] { float: left; + margin-top: 5px; + margin-right: 5px; } } @@ -1465,6 +1519,8 @@ textarea { textarea { padding: 5px; + width: 100%; + height: 100% !important; } /* Rules for user images */ @@ -1553,8 +1609,9 @@ input[type="reset"], a.button { cursor: pointer; border: 0; - display: block; - padding: $lineheight/4; + display: inline-block; + line-height: 20px; + padding: $lineheight/4 $lineheight/2; min-width: 120px; margin: 0 0 $lineheight/2 0; color: white; @@ -1566,31 +1623,28 @@ a.button { background: darken($blue, $hovercolor); text-decoration: none; } + &.deemphasize { + background: $lightblue; + &:hover { + background: darken($lightblue, $hovercolor); + } + } &:last-child { margin-bottom: 0; } } -a.button.submit { - background-color: #cbeea7; - &:hover { - background-color: #9ed485; - } -} - .buttons { min-width: 200px; - input[type="submit"], + input[type="button"], + input[type="reset"], .button { box-sizing: border-box; - display: inline-block; + float: left; margin-bottom:0; - width:50%; - min-width: 0; + min-width: 100px; max-width: 150px; - margin-left: 2px; - margin-right: 2px; } input:first-child, .button:first-child { @@ -1603,6 +1657,12 @@ a.button.submit { border-radius:0 2px 2px 0; margin-right: 0px; } + input:only-child, + .button:only-child { + border-radius:2px; + margin-right: 0px; + } + } /* Rules for doing distinct colour of alternate table rows */ @@ -1626,7 +1686,8 @@ a.button.submit { /* Rules for rich text */ -.richtext { +.richtext, +.prose { h1, h2 { padding-bottom: $lineheight/2; border-bottom: 1px dashed #cccccc; @@ -1704,7 +1765,10 @@ a.button.submit { /* Rules for rich text editors */ .richtext_container { + margin-bottom: $lineheight; + .richtext_content { + width: 50%; display: inline-block; vertical-align: top; diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb index fa7ef3daa..3a0ad084b 100644 --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@ -84,8 +84,8 @@ module ApplicationHelper output_buffer << content_tag(:div, :id => "#{id}_help", :class => "richtext_help") do output_buffer << render("site/#{format}_help") output_buffer << content_tag(:div, :class => "buttons") do - output_buffer << submit_tag(I18n.t("site.richtext_area.edit"), :id => "#{id}_doedit", :class => "richtext_doedit", :disabled => true) - output_buffer << submit_tag(I18n.t("site.richtext_area.preview"), :id => "#{id}_dopreview", :class => "richtext_dopreview") + output_buffer << submit_tag(I18n.t("site.richtext_area.edit"), :id => "#{id}_doedit", :class => "richtext_doedit deemphasize", :disabled => true) + output_buffer << submit_tag(I18n.t("site.richtext_area.preview"), :id => "#{id}_dopreview", :class => "richtext_dopreview deemphasize") end end end diff --git a/app/views/diary_entry/comments.html.erb b/app/views/diary_entry/comments.html.erb index b55eecf76..971993a9b 100644 --- a/app/views/diary_entry/comments.html.erb +++ b/app/views/diary_entry/comments.html.erb @@ -2,7 +2,7 @@

<%= t('diary_entry.comments.has_commented_on', :display_name => @this_user.display_name) %>

<% end %> - +
@@ -13,7 +13,7 @@ - + <% end -%>
<%= t 'diary_entry.comments.post' %> <%= t 'diary_entry.comments.when' %>
<%= link_to comment.diary_entry.title, :action => :view, :display_name => comment.diary_entry.user.display_name, :id => comment.diary_entry.id %> <%= t 'diary_entry.comments.ago', :ago => time_ago_in_words(comment.created_at) %><%= comment.body.to_html %><%= comment.body %>
diff --git a/app/views/diary_entry/edit.html.erb b/app/views/diary_entry/edit.html.erb index 940389c83..93e7631ed 100644 --- a/app/views/diary_entry/edit.html.erb +++ b/app/views/diary_entry/edit.html.erb @@ -11,30 +11,37 @@ <%= form_for :diary_entry do |f| %>
- - <%= f.text_field :title, :size => 60 %> -
-
- - <%= richtext_area :diary_entry, :body, :cols => 80, :format => @diary_entry.body_format %> -
-
- - <%= f.collection_select :language_code, Language.order(:english_name), :code, :name %> +
+ + <%= f.text_field :title %> +
+
+ + <%= richtext_area :diary_entry, :body, :format => @diary_entry.body_format %> +
+
+ + <%= f.collection_select :language_code, Language.order(:english_name), :code, :name %> +
-
-

<%= t 'diary_entry.edit.location' -%>

+
+ <%= content_tag "div", "", :id => "map", :data => {:lat => @lat, :lon => @lon, :zoom => @zoom} %> -
- - <%= f.text_field :latitude, :size => 20, :id => "latitude" %> -
-
- - <%= f.text_field :longitude, :size => 20, :id => "longitude" %> -
-

<%= t 'diary_entry.edit.use_map_link' -%>

-
+
+
+ + <%= f.text_field :latitude, :size => 20, :id => "latitude" %> +
+
+ + <%= f.text_field :longitude, :size => 20, :id => "longitude" %> +
+ +
+ + <%= submit_tag t('diary_entry.edit.save_button') %> <%# TODO: button should say 'publish' or 'save changes' depending on new/edit state %>
diff --git a/app/views/export/start.html.erb b/app/views/export/start.html.erb index 7c733ab7f..cdb16970f 100644 --- a/app/views/export/start.html.erb +++ b/app/views/export/start.html.erb @@ -17,9 +17,17 @@

<%= t'export.start.format_to_export' %>

diff --git a/app/views/message/_message_summary.html.erb b/app/views/message/_message_summary.html.erb index ffdfd6c38..6e692ab2c 100644 --- a/app/views/message/_message_summary.html.erb +++ b/app/views/message/_message_summary.html.erb @@ -4,5 +4,5 @@ <%= l message_summary.sent_on, :format => :friendly %> <%= button_to t('message.message_summary.unread_button'), {:controller => 'message', :action => 'mark', :message_id => message_summary.id, :mark => 'unread'}, { :remote => true } %> <%= button_to t('message.message_summary.read_button'), {:controller => 'message', :action => 'mark', :message_id => message_summary.id, :mark => 'read'}, { :remote => true } %> - <%= button_to t('message.message_summary.delete_button'), {:controller => 'message', :action => 'delete', :message_id => message_summary.id, :referer => request.fullpath}, { :remote => true } %> + <%= button_to t('message.message_summary.delete_button'), {:controller => 'message', :action => 'delete', :message_id => message_summary.id, :referer => request.fullpath}, { :remote => true } %> diff --git a/app/views/message/_sent_message_summary.html.erb b/app/views/message/_sent_message_summary.html.erb index 3580822ae..de21e8cd3 100644 --- a/app/views/message/_sent_message_summary.html.erb +++ b/app/views/message/_sent_message_summary.html.erb @@ -2,5 +2,5 @@ <%= link_to h(sent_message_summary.recipient.display_name), :controller => 'user', :action => 'view', :display_name => sent_message_summary.recipient.display_name %> <%= link_to h(sent_message_summary.title), :controller => 'message', :action => 'read', :message_id => sent_message_summary.id %> <%= l sent_message_summary.sent_on, :format => :friendly %> - <%= button_to t('message.sent_message_summary.delete_button'), :controller => 'message', :action => 'delete', :message_id => sent_message_summary.id, :referer => request.fullpath %> + <%= button_to t('message.sent_message_summary.delete_button'), :controller => 'message', :action => 'delete', :message_id => sent_message_summary.id, :referer => request.fullpath %> diff --git a/app/views/message/new.html.erb b/app/views/message/new.html.erb index ea9c510f9..3dc16acc0 100644 --- a/app/views/message/new.html.erb +++ b/app/views/message/new.html.erb @@ -5,21 +5,18 @@ <%= error_messages_for 'message' %> <%= form_for :message, :html => { :class => 'standard-form' }, :url => { :action => "new", :display_name => @this_user.display_name } do |f| %> -
- - <%= f.text_field :title, :size => 60, :value => @subject %> -
- -
- - <%= richtext_area :message, :body, :cols => 80, :value => @body %> -
- -
- <%= submit_tag t('message.new.send_button') %> +
+
+ + <%= f.text_field :title, :size => 60, :value => @subject %> +
+
+ + <%= richtext_area :message, :body, :cols => 80, :value => @body %> +
+
+ <%= submit_tag t('message.new.send_button') %> + <%= link_to t('message.new.back_to_inbox'), { :controller => 'message', :action => 'inbox', :display_name => @user.display_name }, :class => 'deemphasize button' %> +
<% end %> - -
- -<%= link_to t('message.new.back_to_inbox'), :controller => 'message', :action => 'inbox', :display_name => @user.display_name %> diff --git a/app/views/message/read.html.erb b/app/views/message/read.html.erb index 98584cc9a..eeacd5b39 100644 --- a/app/views/message/read.html.erb +++ b/app/views/message/read.html.erb @@ -8,16 +8,14 @@ <%= link_to h(@message.sender.display_name), :controller => 'user', :action => 'view', :display_name => @message.sender.display_name %>
<%= l @message.sent_on, :format => :friendly %> -
- <%= button_to t('message.read.reply_button'), :controller => 'message', :action => 'reply', :message_id => @message.id %> - <%= button_to t('message.read.unread_button'), :controller => 'message', :action => 'mark', :message_id => @message.id, :mark => 'unread' %> -
<%= @message.body.to_html %>
- <%= link_to t('message.read.back_to_inbox'), :controller => 'message', :action => 'inbox', :display_name => @user.display_name %> +
+ <%= button_to t('message.read.reply_button'), {:controller => 'message', :action => 'reply', :message_id => @message.id}, :class => 'reply-button' %> + <%= button_to t('message.read.unread_button'), {:controller => 'message', :action => 'mark', :message_id => @message.id, :mark => 'unread'}, :class => 'mark-unread-button' %> <% else %> @@ -33,6 +31,9 @@
<%= @message.body.to_html %>
- <%= link_to t('message.read.back_to_outbox'), :controller => 'message', :action => 'outbox', :display_name => @user.display_name %> +
<% end %> + + <%= link_to t('message.read.back_to_outbox'), {:controller => 'message', :action => 'outbox', :display_name => @user.display_name }, :class => "button deemphasize" %> +
diff --git a/app/views/oauth_clients/_form.html.erb b/app/views/oauth_clients/_form.html.erb index dc8f8e3d9..96ab68ad7 100644 --- a/app/views/oauth_clients/_form.html.erb +++ b/app/views/oauth_clients/_form.html.erb @@ -1,23 +1,29 @@ -
-
- <%= f.text_field :name %> -
-
-
- <%= f.text_field :url %> -
-
-
- <%= f.text_field :callback_url %> -
-
-
- <%= f.text_field :support_url %> -
-

<%= t'oauth_clients.form.requests' %>

-<% ClientApplication.all_permissions.each do |perm| %> -
- <%= f.check_box perm %> -
-
-<% end %> +
+
+
+ + <%= f.text_field :name %> +
+
+ + <%= f.text_field :url %> +
+
+ + <%= f.text_field :callback_url %> +
+
+ + <%= f.text_field :support_url %> +
+
+
+

<%= t'oauth_clients.form.requests' %>

+ <% ClientApplication.all_permissions.each do |perm| %> +
+ <%= f.check_box perm %> + +
+ <% end %> +
+
\ No newline at end of file diff --git a/app/views/oauth_clients/edit.html.erb b/app/views/oauth_clients/edit.html.erb index 99aab0ed0..397849c44 100644 --- a/app/views/oauth_clients/edit.html.erb +++ b/app/views/oauth_clients/edit.html.erb @@ -4,6 +4,5 @@ <%= form_for @client_application, :url => oauth_client_path(@client_application.user.display_name, @client_application), :html => { :method => :put } do |f| %> <%= render :partial => "form", :locals => { :f => f } %> -
<%= submit_tag t'oauth_clients.edit.submit' %> <% end %> diff --git a/app/views/oauth_clients/new.html.erb b/app/views/oauth_clients/new.html.erb index 1c18857b1..a931cffe5 100644 --- a/app/views/oauth_clients/new.html.erb +++ b/app/views/oauth_clients/new.html.erb @@ -2,8 +2,10 @@

<%= t'oauth_clients.new.title' %>

<% end %> -<%= form_for :client_application, :url => { :action => :create } do |f| %> - <%= render :partial => "form", :locals => { :f => f } %> -
- <%= submit_tag t('oauth_clients.new.submit') %> -<% end %> \ No newline at end of file +
+ <%= form_for :client_application, :url => { :action => :create } do |f| %> + <%= render :partial => "form", :locals => { :f => f } %> + <%= submit_tag t('oauth_clients.new.submit') %> +
+ +<% end %> diff --git a/app/views/oauth_clients/show.html.erb b/app/views/oauth_clients/show.html.erb index 131696ed3..a23ce082d 100644 --- a/app/views/oauth_clients/show.html.erb +++ b/app/views/oauth_clients/show.html.erb @@ -1,32 +1,33 @@ <% content_for :heading do %>

<%= t('oauth_clients.show.title', :app_name => @client_application.name) %>

<% end %> -

- <%= t'oauth_clients.show.key' %> <%=@client_application.key %> -

-

- <%= t'oauth_clients.show.secret' %> <%=@client_application.secret %> -

-

- <%= t'oauth_clients.show.url' %> http<%='s' if request.ssl? %>://<%= request.host_with_port %><%=@client_application.oauth_server.request_token_path %> -

-

- <%= t'oauth_clients.show.access_url' %> http<%='s' if request.ssl? %>://<%= request.host_with_port %><%=@client_application.oauth_server.access_token_path %> -

-

- <%= t'oauth_clients.show.authorize_url' %> http<%='s' if request.ssl? %>://<%= request.host_with_port %><%=@client_application.oauth_server.authorize_path %> -

+
+

+ <%= t'oauth_clients.show.key' %> <%=@client_application.key %> +

+

+ <%= t'oauth_clients.show.secret' %> <%=@client_application.secret %> +

+

+ <%= t'oauth_clients.show.url' %> http<%='s' if request.ssl? %>://<%= request.host_with_port %><%=@client_application.oauth_server.request_token_path %> +

+

+ <%= t'oauth_clients.show.access_url' %> http<%='s' if request.ssl? %>://<%= request.host_with_port %><%=@client_application.oauth_server.access_token_path %> +

+

+ <%= t'oauth_clients.show.authorize_url' %> http<%='s' if request.ssl? %>://<%= request.host_with_port %><%=@client_application.oauth_server.authorize_path %> +

-

<%= t'oauth_clients.show.requests' %>

-
    <% @client_application.permissions.each do |perm| %> -
    -
  • <%= t('oauth_clients.form.' + perm.to_s) %>
  • -
    -<% end %>
- -

<%= t'oauth_clients.show.support_notice' %>

+

<%= t'oauth_clients.show.requests' %>

+
    <% @client_application.permissions.each do |perm| %> +
    +
  • <%= t('oauth_clients.form.' + perm.to_s) %>
  • +
    + <% end %>
+

<%= t'oauth_clients.show.support_notice' %>

+
- <%= button_to t('oauth_clients.show.edit'), edit_oauth_client_path(@client_application.user.display_name, @client_application), :method => :get %> - <%= button_to t('oauth_clients.show.delete'), oauth_client_path(@client_application.user.display_name, @client_application), :method => :delete, :data => { :confirm => t('oauth_clients.show.confirm') } %> + <%= button_to t('oauth_clients.show.edit'), edit_oauth_client_path(@client_application.user.display_name, @client_application), :method => :get, :class=> "oauth-edit" %> + <%= button_to t('oauth_clients.show.delete'), oauth_client_path(@client_application.user.display_name, @client_application), :method => :delete, :data => { :confirm => t('oauth_clients.show.confirm') }, :class=> "oauth-delete deemphasize" %>
diff --git a/app/views/trace/create.html.erb b/app/views/trace/create.html.erb index bfdbf37b4..43d4eff37 100644 --- a/app/views/trace/create.html.erb +++ b/app/views/trace/create.html.erb @@ -7,24 +7,27 @@ <%= form_for @trace, :url => { :action => "create" }, :html => { :multipart => true } do |f| %>
- - <%= f.file_field :gpx_file %> -
-
- - <%= f.text_field :description %> -
-
- - <%= f.text_field :tagstring %> -

(<%= t'trace.trace_form.tags_help' %>)

-
-
- - <%= f.select :visibility, [[t('trace.visibility.private'),"private"],[t('trace.visibility.public'),"public"],[t('trace.visibility.trackable'),"trackable"],[t('trace.visibility.identifiable'),"identifiable"]] %> -

(<%= t'trace.trace_form.visibility_help' %>)

+
+ + <%= f.file_field :gpx_file %> +
+
+ + <%= f.text_field :description %> +
+
+ + <%= f.text_field :tagstring %> + (<%= t'trace.trace_form.tags_help' %>) +
+
+ + <%= f.select :visibility, [[t('trace.visibility.private'),"private"],[t('trace.visibility.public'),"public"],[t('trace.visibility.trackable'),"trackable"],[t('trace.visibility.identifiable'),"identifiable"]] %> + (<%= t'trace.trace_form.visibility_help' %>) +
+ <%= submit_tag t('trace.trace_form.upload_button') %> -

<%= t'trace.trace_form.help' %>

+ <%= t'trace.trace_form.help' %>
<% end %> diff --git a/app/views/trace/edit.html.erb b/app/views/trace/edit.html.erb index 36b5ee90e..d9ec9f14b 100644 --- a/app/views/trace/edit.html.erb +++ b/app/views/trace/edit.html.erb @@ -8,40 +8,54 @@
- -

<%= @trace.name %> (<%= link_to t('trace.edit.download'), :controller => 'trace', :action => 'data', :id => @trace.id %>)

-
-
- -

<%= l @trace.timestamp, :format => :friendly %>

+
+ +

<%= @trace.name %> (<%= link_to t('trace.edit.download'), :controller => 'trace', :action => 'data', :id => @trace.id %>)

+
+
+ +

<%= l @trace.timestamp, :format => :friendly %>

+
+ <% if @trace.inserted? %> +
- -

<%= @trace.size.to_s.gsub(/(\d)(?=(\d{3})+$)/,'\1,') %>

-
- +
+ +

<%= @trace.size.to_s.gsub(/(\d)(?=(\d{3})+$)/,'\1,') %>

+
+
+ +
<%= @trace.latitude %>; <%= @trace.longitude %>
- (<%=link_to t('trace.edit.map'), :controller => 'site', :action => 'index', :lat => @trace.latitude, :lon => @trace.longitude, :zoom => 14 %> / <%=link_to t('trace.edit.edit'), :controller => 'site', :action => 'edit', :lat => @trace.latitude, :lon => @trace.longitude, :gpx=> @trace.id, :zoom => 14 %>) + (<%=link_to t('trace.edit.map'), :controller => 'site', :action => 'index', :lat => @trace.latitude, :lon => @trace.longitude, :zoom => 14 %> / <%=link_to t('trace.edit.edit'), :controller => 'site', :action => 'edit', :lat => @trace.latitude, :lon => @trace.longitude, :gpx=> @trace.id, :zoom => 14 %>)
+ <% end %> +
- -

<%= link_to h(@trace.user.display_name), {:controller => 'user', :action => 'view', :display_name => @trace.user.display_name} %>

-
- - <%= f.text_field :description %> -
-
- - <%= f.text_field :tagstring %> (<%= t'trace.edit.tags_help' %>) +
+ +

<%= link_to h(@trace.user.display_name), {:controller => 'user', :action => 'view', :display_name => @trace.user.display_name} %>

+
+
+ + <%= f.text_field :description %> +
+
+ + <%= f.text_field :tagstring %> (<%= t'trace.edit.tags_help' %>) +
+
+ + <%= f.select :visibility, [[t('trace.visibility.private'),"private"],[t('trace.visibility.public'),"public"],[t('trace.visibility.trackable'),"trackable"],[t('trace.visibility.identifiable'),"identifiable"]] %> (<%= t'trace.edit.visibility_help' %>) +
-
- - <%= f.select :visibility, [[t('trace.visibility.private'),"private"],[t('trace.visibility.public'),"public"],[t('trace.visibility.trackable'),"trackable"],[t('trace.visibility.identifiable'),"identifiable"]] %> (<%= t'trace.edit.visibility_help' %>) +
<%= submit_tag t'trace.edit.save_button' %> diff --git a/app/views/user/account.html.erb b/app/views/user/account.html.erb index d8a63bde6..a0979d5ae 100644 --- a/app/views/user/account.html.erb +++ b/app/views/user/account.html.erb @@ -8,150 +8,164 @@ <%= error_messages_for 'user' %> <%= form_for :user, :html => { :multipart => true, :id => 'accountForm',:class => 'standard-form' } do |f| %> -
- - <%= f.text_field :display_name %> +
+
+ + <%= f.text_field :display_name %> +
-
- - -

<%= t 'user.account.email never displayed publicly' %>

-
+
+
+ + + <%= t 'user.account.email never displayed publicly' %> +
-
- - <%= f.email_field :new_email %> -

<%= t 'user.account.email never displayed publicly' %>

+
+ + <%= f.email_field :new_email %> + <%= t 'user.account.email never displayed publicly' %> +
-
- - <%= 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} %> +
-
- +
+
+ <%= f.url_field :openid_url, {:id => "openid_url", :class => "openid_url"} %> -

(<%= t 'user.account.openid.link text' %>)

+ (<%= t 'user.account.openid.link text' %>) +
-
- -

- <% if @user.data_public? %> - <%= t 'user.account.public editing.enabled' %> - (<%= t 'user.account.public editing.enabled link text' %>) - <% else %> - <%= t 'user.account.public editing.disabled' %> - (<%= t 'user.account.public editing.disabled link text' %>) - <% end %> -

-
- -
- -

- <% if @user.terms_agreed? %> - <%= t 'user.account.contributor terms.agreed' %> - (<%= t 'user.account.contributor terms.link text' %>) - <% if @user.consider_pd? %> - <%= t 'user.account.contributor terms.agreed_with_pd' %> +

+
+ + + <% if @user.data_public? %> + <%= t 'user.account.public editing.enabled' %> + (<%= t 'user.account.public editing.enabled link text' %>) + <% else %> + <%= t 'user.account.public editing.disabled' %> + (<%= t 'user.account.public editing.disabled link text' %>) <% end %> - <% else %> - <%= t 'user.account.contributor terms.not yet agreed' %> - <%= link_to t('user.account.contributor terms.review link text'), :controller => 'user', :action => 'terms' %> - <% end %> -

-
+ +
-
- - <%= richtext_area :user, :description, :rows => '15', :cols => '80' %> +
+ + + <% if @user.terms_agreed? %> + <%= t 'user.account.contributor terms.agreed' %> + (<%= t 'user.account.contributor terms.link text' %>) + <% if @user.consider_pd? %> + <%= t 'user.account.contributor terms.agreed_with_pd' %> + <% end %> + <% else %> + <%= t 'user.account.contributor terms.not yet agreed' %> + <%= link_to t('user.account.contributor terms.review link text'), :controller => 'user', :action => 'terms' %> + <% end %> + +
+
+ + <%= f.select :preferred_editor, [[t("editor.default", :name => t("editor.#{DEFAULT_EDITOR}.name")), 'default']] + Editors::ALL_EDITORS.collect { |e| [t("editor.#{e}.description"), e] } %> +
-
- - <%= f.text_field :languages %> -
+
+
+ + <%= richtext_area :user, :description %> +
-
- - <%= f.select :preferred_editor, [[t("editor.default", :name => t("editor.#{DEFAULT_EDITOR}.name")), 'default']] + Editors::ALL_EDITORS.collect { |e| [t("editor.#{e}.description"), e] } %> -
+
+ + <%= f.text_field :languages %> +
-
- -
- <%= user_image @user %> -
+
+ + <%= user_image @user %> +
    <% if @user.image.file? %> -
    +
  • <%= radio_button_tag "image_action", "keep", !@user.image_use_gravatar %> - <%= t 'user.account.keep image' %> -
  • + + <% end %> <% if @user.image.file? || @user.image_use_gravatar? %> -
    +
  • <%= radio_button_tag "image_action", "delete" %> - <%= t 'user.account.delete image' %> -
  • + + <% end %> <% if @user.image.file? %> -
    -
    +
  • <%= radio_button_tag "image_action", "new" %> - <%= t 'user.account.replace image' %> -
  • -
    + <%= f.file_field :image, :onchange => "$('#image_action_new').prop('checked', true)" %> -

    <%= t 'user.account.image size hint' %>

    -
    -
    + <% else %> -
    +
  • <%= radio_button_tag "image_action", "new" %> - <%= t 'user.account.new image' %> -
  • -
    + <%= f.file_field :image, :onchange => "$('#image_action_new').prop('checked', true)" %> -

    <%= t 'user.account.image size hint' %>

    -
    + <% end %> -
    +
  • <%= radio_button_tag "image_action", "gravatar", @user.image_use_gravatar %> - <%= t 'user.account.gravatar.gravatar' %> -

    (<%= t 'user.account.gravatar.link text' %>)

    -
  • -
+ + +
-
-

<%= t 'user.account.home location' %>

-
class="nohome"<%end%> > -

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

-
- - <%= f.text_field :home_lat, :id => "home_lat" %> - - <%= f.text_field :home_lon, :id => "home_lon" %> +
+
+ +
class="nohome"<%end%> > +

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

+
+ + <%= f.text_field :home_lat, :id => "home_lat" %> +
+
+ + <%= f.text_field :home_lon, :id => "home_lon" %> +
+
-
-
-

<%= t 'user.account.update home location on click' %> checked="checked" <% end %> id="updatehome" />

+
+ checked="checked" <% end %> id="updatehome" /> + +
<% content_for :head do %> <%= javascript_include_tag "user" %> <% end %> <%= content_tag "div", "", :id => "map", :class => "content_map settings_map set_location" %> -
-
+
<%= submit_tag t('user.account.save changes button') %> <% end %> diff --git a/app/views/user/login.html.erb b/app/views/user/login.html.erb index d1efa8b2b..699c977b0 100644 --- a/app/views/user/login.html.erb +++ b/app/views/user/login.html.erb @@ -24,9 +24,9 @@ <%= password_field_tag "password", "", :tabindex => 2 %> -

+ <%= link_to t('user.login.lost password link'), :controller => 'user', :action => 'lost_password' %> -

+
@@ -37,7 +37,7 @@ <%= submit_tag t('user.login.login_button'), :tabindex => 4 %>
-
+

<%= t 'user.login.with openid' %>

diff --git a/app/views/user/new.html.erb b/app/views/user/new.html.erb index ab243cbfd..52abb3311 100644 --- a/app/views/user/new.html.erb +++ b/app/views/user/new.html.erb @@ -10,6 +10,7 @@ <%= hidden_field_tag('referer', h(@referer)) unless @referer.nil? %>
+
<%= email_field(:user, :email_confirmation, { :tabindex => 2 }) %>
-

<%= raw(t 'user.new.not displayed publicly') %>

+ <%= raw(t 'user.new.not displayed publicly') %>
@@ -33,16 +34,19 @@ <%= text_field(:user, :display_name, { :tabindex => 3 }) %>
-

<%= t 'user.new.display name description' %> + <%= t 'user.new.display name description' %>

-
+
<%= url_field(:user, :openid_url, { :id => "openid_url", :tabindex => 4, :class => "openid_url" }) %>
+ + <%= t 'user.new.openid no password' %> +
@@ -58,13 +62,12 @@ <%= password_field(:user, :pass_crypt_confirmation, { :tabindex => 6 }) %> - - <%= link_to raw(t("user.new.use openid", :logo => openid_logo)), "#", :id => "openid_enable" %> - - - <%= t 'user.new.openid no password' %> -
+ +
+ <%= link_to raw(t("user.new.use openid", :logo => openid_logo)), "#", :id => "openid_enable" %> +
+ <%= submit_tag t('user.new.continue'), :tabindex => 6 %> <% end %> @@ -74,7 +77,6 @@ function enableOpenID() { $("#openid_prompt").hide(); - $("#openid_spacer").show(); $("#openid_field").show(); $("#openid_note").show(); @@ -85,7 +87,6 @@ function disableOpenID() { $("#openid_prompt").show(); - $("#openid_spacer").hide(); $("#openid_field").hide(); $("#openid_note").hide(); -- 2.43.2