Commit fe07c737aa3cc493cadef90284340924c4db6c98
Exists in
master
and in
4 other branches
Merge branch 'improve/devise_ui' of /home/git/repositories/gitlab/gitlabhq
Showing
8 changed files
with
59 additions
and
25 deletions
Show diff stats
app/assets/stylesheets/sections/login.scss
app/views/devise/confirmations/new.html.haml
1 | 1 | .login-box |
2 | 2 | %h3.page-title Resend confirmation instructions |
3 | 3 | = form_for(resource, as: resource_name, url: confirmation_path(resource_name), html: { method: :post }) do |f| |
4 | - = devise_error_messages! | |
5 | - = f.email_field :email, placeholder: 'Email' | |
6 | - %div= f.submit "Resend confirmation instructions", class: 'btn btn-success' | |
4 | + .devise-errors | |
5 | + = devise_error_messages! | |
6 | + = f.email_field :email, placeholder: 'Email', class: "text", required: true | |
7 | + .clearfix.append-bottom-10 | |
8 | + = f.submit "Resend confirmation instructions", class: 'btn btn-success' | |
7 | 9 | %hr |
8 | - = link_to "Sign in", new_session_path(resource_name) | |
10 | + %p | |
11 | + %span.light | |
12 | + Already have login and password? | |
13 | + %strong | |
14 | + = link_to "Sign in", new_session_path(resource_name) | ... | ... |
app/views/devise/mailer/confirmation_instructions.html.erb
1 | -<p>Welcome <%= @resource.email %>!</p> | |
1 | +<p>Welcome <%= @resource.name %>!</p> | |
2 | 2 | |
3 | -<p>You can confirm your account through the link below:</p> | |
3 | +<% if @resource.unconfirmed_email.present? %> | |
4 | + <p>You can confirm your email (<%= @resource.unconfirmed_email %>) through the link below:</p> | |
5 | +<% else %> | |
6 | + <p>You can confirm your account through the link below:</p> | |
7 | +<% end %> | |
4 | 8 | |
5 | 9 | <p><%= link_to 'Confirm my account', confirmation_url(@resource, confirmation_token: @resource.confirmation_token) %></p> | ... | ... |
app/views/devise/passwords/edit.html.haml
1 | 1 | = form_for(resource, as: resource_name, url: password_path(resource_name), html: { method: :put, class: "login-box" }) do |f| |
2 | 2 | %h3 Change your password |
3 | - = devise_error_messages! | |
3 | + .devise-errors | |
4 | + = devise_error_messages! | |
4 | 5 | = f.hidden_field :reset_password_token |
5 | 6 | %div |
6 | - = f.password_field :password, class: "text top", placeholder: "New password" | |
7 | + = f.password_field :password, class: "text top", placeholder: "New password", required: true | |
7 | 8 | %div |
8 | - = f.password_field :password_confirmation, class: "text bottom", placeholder: "Confirm new password" | |
9 | + = f.password_field :password_confirmation, class: "text bottom", placeholder: "Confirm new password", required: true | |
9 | 10 | %div |
10 | 11 | .clearfix.append-bottom-10 |
11 | 12 | = f.submit "Change my password", class: "btn btn-primary" | ... | ... |
app/views/devise/passwords/new.html.haml
1 | 1 | = form_for(resource, as: resource_name, url: password_path(resource_name), html: { class: "login-box", method: :post }) do |f| |
2 | 2 | %h3.page-title Reset password |
3 | - = devise_error_messages! | |
4 | - = f.email_field :email, placeholder: "Email", class: "text" | |
5 | - %br/ | |
6 | - %br/ | |
7 | - = f.submit "Reset password", class: "btn-primary btn" | |
8 | - .pull-right | |
9 | - = link_to "Sign in", new_session_path(resource_name), class: "btn" | |
10 | - %br/ | |
3 | + .devise-errors | |
4 | + = devise_error_messages! | |
5 | + = f.email_field :email, placeholder: "Email", class: "text", required: true | |
6 | + .clearfix.append-bottom-10 | |
7 | + = f.submit "Reset password", class: "btn-primary btn" | |
8 | + %hr | |
9 | + %p | |
10 | + %span.light | |
11 | + Already have login and password? | |
12 | + %strong | |
13 | + = link_to "Sign in", new_session_path(resource_name) | ... | ... |
app/views/devise/registrations/new.html.haml
1 | 1 | = form_for(resource, as: resource_name, url: registration_path(resource_name), html: { class: "login-box" }) do |f| |
2 | 2 | %h3.page-title Sign Up |
3 | - %br | |
4 | - = devise_error_messages! | |
3 | + .devise-errors | |
4 | + = devise_error_messages! | |
5 | 5 | %div |
6 | 6 | = f.text_field :name, class: "text top", placeholder: "Name", required: true |
7 | 7 | %div |
... | ... | @@ -15,5 +15,10 @@ |
15 | 15 | %div |
16 | 16 | = f.submit "Sign up", class: "btn-create btn" |
17 | 17 | %hr |
18 | - = link_to "Sign in", new_session_path(resource_name) | |
19 | - = link_to "Forgot your password?", new_password_path(resource_name), class: "pull-right" | |
18 | + %p | |
19 | + %span.light | |
20 | + Have an account? | |
21 | + %strong | |
22 | + = link_to "Sign in", new_session_path(resource_name) | |
23 | + %p | |
24 | + = link_to "Forgot your password?", new_password_path(resource_name) | ... | ... |
app/views/devise/sessions/new.html.haml
... | ... | @@ -17,14 +17,20 @@ |
17 | 17 | |
18 | 18 | |
19 | 19 | = render 'devise/sessions/oauth_providers' if devise_mapping.omniauthable? |
20 | + %hr | |
20 | 21 | |
21 | 22 | - if gitlab_config.signup_enabled |
22 | - %hr | |
23 | - %div | |
24 | - Don't have an account? | |
23 | + %p | |
24 | + %span.light | |
25 | + Don't have an account? | |
25 | 26 | %strong |
26 | 27 | = link_to "Sign up", new_registration_path(resource_name) |
27 | 28 | |
29 | + %p | |
30 | + %span.light Did not receive confirmation email? | |
31 | + = link_to "Send again", new_confirmation_path(resource_name) | |
32 | + | |
33 | + | |
28 | 34 | - if extra_config.has_key?('sign_in_text') |
29 | 35 | %hr |
30 | 36 | = markdown(extra_config.sign_in_text) | ... | ... |
app/views/layouts/devise.html.haml