Improves styles for account page, adds user image

This commit is contained in:
Alberto Garcia Cabeza
2015-08-11 19:53:18 +02:00
committed by Juanjo Bazán
parent 94dc53e68c
commit 502920c7f2
6 changed files with 19 additions and 16 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

View File

@@ -370,12 +370,16 @@ form {
line-height: $line-height; line-height: $line-height;
} }
input[type]:not([type=submit]) { input[type]:not([type=submit]):not([type=file]) {
background: $input-bg; background: $input-bg;
height: $line-height*2; height: $line-height*2;
margin-bottom: rem-calc(16); margin-bottom: rem-calc(16);
} }
input[type=file] {
margin: rem-calc(12) 0;
}
.note { .note {
display: block; display: block;
font-size: rem-calc(13); font-size: rem-calc(13);
@@ -390,6 +394,7 @@ form {
.checkbox { .checkbox {
display: inline-block; display: inline-block;
font-size: rem-calc(14); font-size: rem-calc(14);
font-weight: normal;
line-height: $line-height*2; line-height: $line-height*2;
margin: 0 0 0 rem-calc(6); margin: 0 0 0 rem-calc(6);
vertical-align: top; vertical-align: top;

View File

@@ -1,6 +1,8 @@
<div class="row account"> <div class="row account">
<div class="small-12 medium-9 column"> <div class="small-12 column">
<h1><%= t("account.show.title") %></h1> <%= link_to t("account.show.change_credentials_link"), edit_user_registration_path, class: 'button radius small secondary right' %>
<h1 class="inline-block"><%= t("account.show.title") %></h1>
<%= form_for @account, as: :account, url: account_path do |f| %> <%= form_for @account, as: :account, url: account_path do |f| %>
@@ -17,16 +19,13 @@
<div class="row"> <div class="row">
<div class="small-12 medium-6 column"> <div class="small-12 medium-6 column">
<h2><%= t("account.show.personal")%></h2>
<%= f.label :first_name, t("account.show.first_name_label") %> <%= f.label :first_name, t("account.show.first_name_label") %>
<%= f.text_field :first_name, placeholder: t("account.show.first_name_label") %> <%= f.text_field :first_name, placeholder: t("account.show.first_name_label") %>
</div>
<div class="small-12 medium-6 column">
<%= f.label :last_name, t("account.show.last_name_label") %> <%= f.label :last_name, t("account.show.last_name_label") %>
<%= f.text_field :last_name, placeholder: t("account.show.last_name_label") %> <%= f.text_field :last_name, placeholder: t("account.show.last_name_label") %>
</div>
<div class="small-12 medium-6 column">
<%= f.label :nickname, t("account.show.nickname_label") %> <%= f.label :nickname, t("account.show.nickname_label") %>
<%= f.text_field :nickname, placeholder: t("account.show.nickname_label") %> <%= f.text_field :nickname, placeholder: t("account.show.nickname_label") %>
<%= f.label :use_nickname do %> <%= f.label :use_nickname do %>
@@ -44,9 +43,6 @@
<%= f.check_box :email_on_debate_comment %> <%= f.check_box :email_on_debate_comment %>
<span class="checkbox"><%= t("account.show.email_on_debate_comment_label") %></span> <span class="checkbox"><%= t("account.show.email_on_debate_comment_label") %></span>
<% end %> <% end %>
</div>
<div class="small-12 column">
<%= f.label :email_on_comment_reply do %> <%= f.label :email_on_comment_reply do %>
<%= f.check_box :email_on_comment_reply %> <%= f.check_box :email_on_comment_reply %>
<span class="checkbox"><%= t("account.show.email_on_comment_reply_label") %></span> <span class="checkbox"><%= t("account.show.email_on_comment_reply_label") %></span>
@@ -59,8 +55,4 @@
</div> </div>
<% end %> <% end %>
</div> </div>
<div class="small-12 medium-3 column text-center">
<%= link_to t("account.show.change_credentials_link"), edit_user_registration_path, class: 'button radius small secondary' %>
</div>
</div> </div>

View File

@@ -1,5 +1,5 @@
<div class="row"> <div class="row">
<div class="account small-12 medium-9 column small-centered"> <div class="account small-12 medium-5 column small-centered">
<i class="icon-angle-left left"></i>&nbsp;<%= link_to t("devise_views.registrations.edit.back_link"), :back, class: "left back" %> <i class="icon-angle-left left"></i>&nbsp;<%= link_to t("devise_views.registrations.edit.back_link"), :back, class: "left back" %>

View File

@@ -71,10 +71,13 @@ en:
email_on_debate_comment_label: "Receive email when someone comments on my debates" email_on_debate_comment_label: "Receive email when someone comments on my debates"
email_on_comment_reply_label: "Receive email when someone replies to my comments" email_on_comment_reply_label: "Receive email when someone replies to my comments"
change_credentials_link: "Change my credentials" change_credentials_link: "Change my credentials"
avatar: "Avatar"
personal: "Personal data"
first_name_label: "First Name" first_name_label: "First Name"
last_name_label: "Last Name" last_name_label: "Last Name"
use_nickname_label: "Use nickname" use_nickname_label: "Use nickname"
nickname_label: "Nickname" nickname_label: "Nickname"
notifications: Notifications
simple_captcha: simple_captcha:
placeholder: "Enter the image value" placeholder: "Enter the image value"
label: "Enter the code in the box:" label: "Enter the code in the box:"

View File

@@ -71,10 +71,13 @@ es:
change_credentials_link: "Cambiar mis credenciales" change_credentials_link: "Cambiar mis credenciales"
email_on_debate_comment_label: "Recibir un email cuando alguien comenta en mis debates" email_on_debate_comment_label: "Recibir un email cuando alguien comenta en mis debates"
email_on_comment_reply_label: "Recibir un email cuando alguien contesta a mis comentarios" email_on_comment_reply_label: "Recibir un email cuando alguien contesta a mis comentarios"
avatar: "Avatar"
personal: "Datos personales"
first_name_label: "Nombre" first_name_label: "Nombre"
last_name_label: "Apellidos" last_name_label: "Apellidos"
use_nickname_label: "Usar pseudónimo" use_nickname_label: "Usar pseudónimo"
nickname_label: "Pseudónimo" nickname_label: "Pseudónimo"
notifications: Notificaciones
simple_captcha: simple_captcha:
placeholder: "Introduce el texto de la imagen" placeholder: "Introduce el texto de la imagen"
label: "Introduce el texto en la caja:" label: "Introduce el texto en la caja:"