1 <% content_for :head do %>
2 <%= javascript_include_tag "user" %>
5 <% content_for :heading do %>
6 <h1><%= t 'user.account.my settings' %></h1>
7 <ul class='secondary-actions clearfix'>
8 <li><%= link_to t('user.account.return to profile'), :controller => 'user', :action => 'view', :display_name => current_user.display_name %></li>
9 <li><%= link_to t('user.view.oauth settings'), :controller => 'oauth_clients', :action => 'index' %></li>
13 <%= error_messages_for current_user %>
14 <%= form_for current_user, :url => { :action => :account }, :method => :post, :html => { :multipart => true, :id => 'accountForm', :class => 'standard-form', :autocomplete => :off } do |f| %>
16 <div class="form-row">
17 <label class="standard-label"><%= t 'user.new.display name' %></label>
18 <%= f.text_field :display_name %>
23 <div class="form-row">
24 <label class="standard-label"><%= t 'user.account.current email address' %></label>
25 <input type="email" disabled value="<%= current_user.email %>" />
26 <span class="form-help deemphasize"><%= t 'user.account.email never displayed publicly' %></span>
29 <div class="form-row">
30 <label class="standard-label"><%= t 'user.account.new email address' %></label>
31 <%= f.email_field :new_email, :autocomplete => :off %>
32 <span class="form-help deemphasize"><%= t 'user.account.email never displayed publicly' %></span>
37 <div class="form-row">
38 <label class="standard-label"><%= t 'user.new.password' %></label>
39 <%= f.password_field :pass_crypt, {:value => '', :autocomplete => :off} %>
42 <div class="form-row">
43 <label class="standard-label"><%= t 'user.new.confirm password' %></label>
44 <%= f.password_field :pass_crypt_confirmation, {:value => '', :autocomplete => :off} %>
49 <div class="form-row">
50 <label class="standard-label"><%= t 'user.account.external auth' %></label>
51 <%= f.select :auth_provider, Auth::PROVIDERS %>
52 <%= f.text_field :auth_uid %>
53 <span class="form-help deemphasize">(<a href="<%= t 'user.account.openid.link' %>" target="_new"><%= t 'user.account.openid.link text' %></a>)</span>
57 <fieldset class="form-divider">
58 <div class="form-row">
59 <label class="standard-label"><%= t 'user.account.public editing.heading' %></label>
60 <span class="form-help deemphasize">
61 <% if current_user.data_public? %>
62 <%= t 'user.account.public editing.enabled' %>
63 (<a href="<%= t 'user.account.public editing.enabled link' %>" target="_new"><%= t 'user.account.public editing.enabled link text' %></a>)
65 <%= t 'user.account.public editing.disabled' %>
66 (<a href="#public"><%= t 'user.account.public editing.disabled link text' %></a>)
71 <div class="form-row">
72 <label class="standard-label"><%= t 'user.account.contributor terms.heading' %></label>
73 <span class="form-help deemphasize">
74 <% if current_user.terms_agreed? %>
75 <%= t 'user.account.contributor terms.agreed' %>
76 (<a href="<%= t 'user.account.contributor terms.link' %>" target="_new"><%= t 'user.account.contributor terms.link text' %></a>)
77 <% if current_user.consider_pd? %>
78 <%= t 'user.account.contributor terms.agreed_with_pd' %>
81 <%= t 'user.account.contributor terms.not yet agreed' %>
82 <%= link_to t('user.account.contributor terms.review link text'), :controller => 'user', :action => 'terms' %>
86 <div class="form-row">
87 <label class="standard-label"><%= t 'user.account.preferred editor' %></label>
88 <%= f.select :preferred_editor, [[t("editor.default", :name => t("editor.#{DEFAULT_EDITOR}.name")), 'default']] + Editors::ALL_EDITORS.collect { |e| [t("editor.#{e}.description"), e] } %>
92 <fieldset class="form-divider">
93 <div class='form-row'>
94 <label class="standard-label"><%= t 'user.account.profile description' %></label>
95 <%= richtext_area :user, :description, :object => current_user, :cols => 80, :rows => 20 %>
98 <div class="form-row">
99 <label class="standard-label"><%= t 'user.account.preferred languages' %></label>
100 <%= f.text_field :languages %>
103 <div class='form-row accountImage'>
104 <label class="standard-label"><%= t 'user.account.image' %></label>
105 <%= user_image current_user %>
106 <ul class='form-list accountImage-options'>
107 <% if current_user.image.file? %>
109 <%= radio_button_tag "image_action", "keep", !current_user.image_use_gravatar %>
110 <label class='standard-label' for='image_action_keep'><%= t 'user.account.keep image' %></label>
113 <% if current_user.image.file? || current_user.image_use_gravatar? %>
115 <%= radio_button_tag "image_action", "delete" %>
116 <label class='standard-label' for='image_action_delete'><%= t 'user.account.delete image' %></label>
119 <% if current_user.image.file? %>
121 <%= radio_button_tag "image_action", "new" %>
122 <label class='standard-label' for='image_action_new'>
123 <%= t 'user.account.replace image' %>
124 <span class="form-help deemphasize"><%= t 'user.account.image size hint' %></span>
126 <%= f.file_field :image %>
130 <%= radio_button_tag "image_action", "new" %>
131 <label class='standard-label' for='image_action_new'>
132 <%= t 'user.account.new image' %>
133 <span class="form-help deemphasize"><%= t 'user.account.image size hint' %></span>
135 <%= f.file_field :image %>
139 <%= radio_button_tag "image_action", "gravatar", current_user.image_use_gravatar %>
140 <label class='standard-label' for='image_action_gravatar'>
141 <%= t 'user.account.gravatar.gravatar' %>
142 <span class='form-help deemphasize'> (<a href="<%= t 'user.account.gravatar.link' %>" target="_new"><%= t 'user.account.gravatar.link text' %></a>)</span>
149 <fieldset class="form-divider">
150 <div class='form-row location clearfix'>
151 <label class="standard-label"><%= t 'user.account.home location' %></label>
152 <div id="homerow" <% unless current_user.home_lat and current_user.home_lon %>class="nohome"<%end%> >
153 <p class="message form-help deemphasize"><%= t 'user.account.no home location' %></p>
154 <div class='form-column'>
155 <label class="standard-label secondary"><%= t 'user.account.latitude' %></label>
156 <%= f.text_field :home_lat, :id => "home_lat" %>
158 <div class='form-column'>
159 <label class="standard-label secondary"><%= t 'user.account.longitude' %></label>
160 <%= f.text_field :home_lon, :id => "home_lon" %>
165 <div class="form-row">
166 <input type="checkbox" name="updatehome" value="1" <% unless current_user.home_lat and current_user.home_lon %> checked="checked" <% end %> id="updatehome" />
167 <label class="standard-label" for="updatehome"><%= t 'user.account.update home location on click' %></label>
169 <%= content_tag "div", "", :id => "map", :class => "content_map settings_map set_location" %>
172 <%= submit_tag t('user.account.save changes button') %>
175 <% unless current_user.data_public? %>
176 <a name="public"></a>
177 <h2><%= t 'user.account.public editing note.heading' %></h2>
178 <%= raw t 'user.account.public editing note.text' %>
179 <%= button_to t('user.account.make edits public button'), :action => :go_public %>