<td class="fieldName">
<%= t 'user.account.image' %>
</td>
- <td valign="top">
- <table id="accountImage">
+ <td class="accountImage">
+ <%= user_image @user %>
+ <table>
<% if @user.image.file? %>
<tr>
- <td rowspan="4" valign="top"><%= user_image @user %></td>
<td><%= radio_button_tag "image_action", "keep", !@user.image_use_gravatar %></td>
<td><%= t 'user.account.keep image' %></td>
</tr>
+ <% end %>
+ <% if @user.image.file? || @user.image_use_gravatar? %>
<tr>
<td><%= radio_button_tag "image_action", "delete" %></td>
<td><%= t 'user.account.delete image' %></td>
</tr>
+ <% end %>
+ <% if @user.image.file? %>
<tr>
<td><%= radio_button_tag "image_action", "new" %></td>
- <td><%= t 'user.account.replace image' %><br /><%= f.file_field :image, :onchange => "$('image_action_new').prop('checked', true)" %><br /><span class="minorNote"><%= t 'user.account.image size hint' %></span></td>
+ <td><%= t 'user.account.replace image' %><br /><%= f.file_field :image, :onchange => "$('#image_action_new').prop('checked', true)" %><br /><span class="minorNote"><%= t 'user.account.image size hint' %></span></td>
</tr>
<% else %>
<tr>
- <td rowspan="2" valign="top"><%= user_image @user %></td>
- <td><%= radio_button_tag "image_action", "new", !@user.image_use_gravatar %></td>
- <td><%= t 'user.account.new image' %> <%= f.file_field :image %><br /><span class="minorNote"><%= t 'user.account.image size hint' %></span></td>
+ <td><%= radio_button_tag "image_action", "new" %></td>
+ <td><%= t 'user.account.new image' %><br /><%= f.file_field :image, :onchange => "$('#image_action_new').prop('checked', true)" %><br /><span class="minorNote"><%= t 'user.account.image size hint' %></span></td>
</tr>
<% end %>
<tr>